コード例 #1
0
ファイル: ProcessSpawner.cs プロジェクト: silverair/Insight
 void RegisterHandlers()
 {
     if (client)
     {
         client.RegisterHandler((short)MsgId.RequestSpawnStart, HandleRequestSpawnStart);
         client.RegisterHandler((short)MsgId.KillSpawn, HandleKillSpawn);
     }
     if (server)
     {
         server.RegisterHandler((short)MsgId.RequestSpawnStart, HandleRequestSpawnStart);
         server.RegisterHandler((short)MsgId.KillSpawn, HandleKillSpawn);
     }
 }
コード例 #2
0
ファイル: ProcessSpawner.cs プロジェクト: Laur3nt1u/Insight
 void RegisterHandlers()
 {
     if (client)
     {
         client.RegisterHandler <RequestSpawnStartMsg>(HandleRequestSpawnStart);
         client.RegisterHandler <KillSpawnMsg>(HandleKillSpawn);
     }
     if (server)
     {
         server.RegisterHandler <RequestSpawnStartMsg>(HandleRequestSpawnStart);
         server.RegisterHandler <KillSpawnMsg>(HandleKillSpawn);
     }
 }
コード例 #3
0
        private void RegisterHandlers()
        {
            if (client)
            {
                client.OnConnected    += RegisterSpawner;
                client.OnDisconnected += HandleDisconnect;

                client.RegisterHandler <RequestSpawnStartToSpawnerMsg>(HandleRequestSpawnStart);
                client.RegisterHandler <KillSpawnMsg>(HandleKillSpawn);
            }

            if (server)
            {
                server.RegisterHandler <RequestSpawnStartToSpawnerMsg>(HandleRequestSpawnStart);
                server.RegisterHandler <KillSpawnMsg>(HandleKillSpawn);
            }
        }
コード例 #4
0
 void RegisterHandlers()
 {
     client.RegisterHandler <ChangeServerMsg>(HandleChangeServersMsg);
     client.RegisterHandler <GameListMsg>(HandleGameListMsg);
 }
コード例 #5
0
 private void RegisterHandlers()
 {
     client.RegisterHandler <ChatMsg>(HandleChatMsg);
 }
コード例 #6
0
 void RegisterHandlers()
 {
     client.RegisterHandler((short)MsgId.ChangeServers, HandleChangeServersMsg);
     client.RegisterHandler((short)MsgId.GameList, HandleGameListMsg);
 }