public void InitGame() { // 決定順序 playersGameStatus = new PlayersGameStatus(); for (int i = 0; i < Constants.maxPlayer; i++) { Guest.Player player = serverController.playerList.players[i]; playersGameStatus.AddPlayer(new Player(player.nick, player.clientSocket, i)); } for (int i = 0; i < Constants.maxPlayer; i++) { serverController.SendToClient(true, new Packet(Command.M2C_START_GAME, new int[1] { i }), playersGameStatus.players[i].clientSocket); } }
void C2M_CHANGE_NICK(Packet packet, string endPoint) { Guest.Player player = serverController.playerList.FindPlayer(endPoint); player.nick = packet.s_datas[0]; serverController.SendHubList(); }