namespace ACE.Server.Network.Enum { public enum SessionTerminationReason { None, PacketHeaderDisconnect, AccountInformationInvalid, AccountSelectCallbackException, NetworkTimeout, /// /// a trusted packet had PacketHeaderFlags.NetErrorDisconnect header flag /// ClientSentNetworkErrorDisconnect, AccountBooted, BadHandshake, PongSentClosingConnection, NotAuthorizedNoPasswordOrGlsTicketIncludedInLoginReq, NotAuthorizedAccountNotFound, AccountInUse, NotAuthorizedPasswordMismatch, NotAuthorizedGlsTicketNotImplementedToProcLoginReq, /// /// The client connection is no longer able to send us packets with encrypted CRC /// ClientConnectionFailure, SendToSocketException, WorldClosed, AbnormalSequenceReceived, AccountLoggedIn, ServerShuttingDown, AccountBanned, ClientVersionIncorrect, ForcedLogOffRequested, AutoForcedLogOff, CharacterSaveFailed, BiotaSaveFailed, DATsPatchingDisabled, DATsNewerThanServer } public static class SessionTerminationReasonHelper { public static readonly string[] SessionTerminationReasonDescriptions = { "", "PacketHeader Disconnect", "Account Information Invalid", "AccountSelectCallback threw an exception", "Network Timeout", "client sent network error disconnect", "Account Booted", "Bad handshake", "Pong sent, closing connection.", "Not Authorized: No password or GlsTicket included in login request", "Not Authorized: Account Not Found", "Account In Use: Found another session already logged in for this account", "Not Authorized: Password does not match", "Not Authorized: GlsTicket is not implemented to process login request", "Client connection failure", "MainSocket.SendTo exception occured", "World is closed", "Client supplied an abnormal sequence", "Account was logged in, booting currently connected account in favor of new connection", "Server is shutting down", "Account is banned", "Client is not up to date", "Forced log off requested by Admin", "Forced log off by PlayerManager", "Character Save Failed", "Biota Save Failed", "Client has older DATs than server and patching is disabled", "Client has newer DATs than server and cannot be downgraded" }; public static string GetDescription(this SessionTerminationReason reason) { if ((int)reason > SessionTerminationReasonDescriptions.Length - 1) { return ""; } return SessionTerminationReasonDescriptions[(int)reason]; } } }