コード例 #1
0
        private void Client_OnReceivedData(TSOClient.Network.PacketStream Packet)
        {
            switch (Packet.PacketID)
            {
            case 0x01:
                UIPacketHandlers.OnInitLoginNotify(NetworkFacade.Client, Packet);
                NetworkFacade.UpdateLoginProgress(2);
                break;

            case 0x02:
                NetworkFacade.LoginWait.Set();
                UIPacketHandlers.OnLoginFailResponse(ref NetworkFacade.Client, Packet);
                break;

            case 0x05:
                NetworkFacade.LoginOK = true;
                NetworkFacade.LoginWait.Set();

                NetworkFacade.UpdateLoginProgress(3);

                UIPacketHandlers.OnCharacterInfoResponse(Packet, NetworkFacade.Client);
                break;

            case 0x06:
                UIPacketHandlers.OnCityInfoResponse(Packet);
                break;
            }
        }
コード例 #2
0
 public void _OnLoginFailure(NetworkClient Client, ProcessedPacket packet)
 {
     UIPacketHandlers.OnLoginFailResponse(ref NetworkFacade.Client, packet);
     OnLoginStatus(new LoginEvent(EventCodes.LOGIN_RESULT)
     {
         Success = false, VersionOK = true
     });
 }