public void TranslateMessage(int clientID, MessageGetGameRoomHostRequest message) { if (TranslatedMessageGetGameRoomHostRequest != null) { TranslatedMessageGetGameRoomHostRequest(clientID, message); } }
public void OnClientMessage_MessageGetGameRoomHostRequest(int clientID, MessageGetGameRoomHostRequest message, GameRoomManager gameRoomManager, GameClientManager gameClientManager) { var roomHostClientID = gameRoomManager.GetGameRoomHostClientIDFromGameRoomID(message.RoomID); var client = gameClientManager.GetGameClientFromClientID(roomHostClientID); var gameRoomHost = new NetworkPlayer(client.ID, client.Name, 0); var messageResponse = new MessageGetGameRoomHostResponse(gameRoomHost); var gameClient = gameClientManager.GetGameClientFromClientID(clientID); SendDataToClient(gameClient, messageResponse); }
private void TheClientToServerMeossageTranslator_TranslatedMessageGetGameRoomHostRequest(object clientID, MessageGetGameRoomHostRequest e) { TheClientToServerMessenger.OnClientMessage_MessageGetGameRoomHostRequest((int)clientID, e, TheGameRoomManager, TheGameClientManager); }