Ejemplo n.º 1
0
        void RegistPacketHandler()
        {
            CommonPacketHandler = new PktCommonHandler();
            CommonPacketHandler.Init(ServerNetworkRef, UserManager, LobbyMgr);

            LobbyPacketHandler = new PktLobbyHandler();
            LobbyPacketHandler.Init(ServerNetworkRef, UserManager, LobbyMgr);

            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_LOGIN, CommonPacketHandler.RequestLogin);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_ENTER_LOBBY, LobbyPacketHandler.RequestEnterLobby);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_LEAVE_LOBBY, LobbyPacketHandler.RequestLeaveLobby);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_CHAT, LobbyPacketHandler.RequestChat);
        }
Ejemplo n.º 2
0
        void RegistPacketHandler()
        {
            CommonPacketHandler = new PktCommonHandler();
            CommonPacketHandler.Init(ServerNetworkRef, UserManager, LobbyMgr);

            LobbyPacketHandler = new PktLobbyHandler();
            LobbyPacketHandler.Init(ServerNetworkRef, UserManager, LobbyMgr);

            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_LOGIN, CommonPacketHandler.RequestLogin);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_ENTER_LOBBY, LobbyPacketHandler.RequestEnterLobby);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_LEAVE_LOBBY, LobbyPacketHandler.RequestLeaveLobby);
            PacketHandlerMap.Add((ushort)PACKET_ID.REQUEST_CHAT, LobbyPacketHandler.RequestChat);
        }