コード例 #1
0
        //

		public GameNetworkServer( string serverName, string serverVersion, int maxConnections,
            bool entitySystemServiceEnabled)
            : base(serverName, serverVersion, maxConnections)
        {
            if (instance != null)
                Log.Fatal("GameNetworkServer.GameNetworkServer: instance != null.");
            instance = this;

            //register network services

            //register user management service
            userManagementService = new UserManagementServerNetworkService();
            RegisterService(userManagementService);

            //register custom messages service
            customMessagesService = new CustomMessagesServerNetworkService();
            RegisterService(customMessagesService);

            //register chat service
            chatService = new ChatServerNetworkService(userManagementService);
            RegisterService(chatService);

            //register entity system service
            if (entitySystemServiceEnabled)
            {
                entitySystemService = new EntitySystemServerNetworkService(userManagementService);
                RegisterService(entitySystemService);
            }
        }
コード例 #2
0
        //

        public GameNetworkServer(string serverName, string serverVersion, int maxConnections,
                                 bool entitySystemServiceEnabled)
            : base(serverName, serverVersion, maxConnections)
        {
            if (instance != null)
            {
                Log.Fatal("GameNetworkServer.GameNetworkServer: instance != null.");
            }
            instance = this;

            //register network services

            //register user management service
            userManagementService = new UserManagementServerNetworkService();
            RegisterService(userManagementService);

            //register custom messages service
            customMessagesService = new CustomMessagesServerNetworkService();
            RegisterService(customMessagesService);

            //register chat service
            chatService = new ChatServerNetworkService(userManagementService);
            RegisterService(chatService);

            //register entity system service
            if (entitySystemServiceEnabled)
            {
                entitySystemService = new EntitySystemServerNetworkService(userManagementService);
                RegisterService(entitySystemService);
            }
        }
コード例 #3
0
                new List<NetworkNode.ConnectedNode>();//for OnBeginEntitySystemMessage()

            //

            public ServerEntitySystemNetworkingInterface(EntitySystemServerNetworkService service)
            {
                this.service = service;
            }
コード例 #4
0
                new List <NetworkNode.ConnectedNode>();//for OnBeginEntitySystemMessage()

            //

            public ServerEntitySystemNetworkingInterface(EntitySystemServerNetworkService service)
            {
                this.service = service;
            }