void OnSetPlayerId(int connectionId, int chanelId, int recHostId, Net_PlayerId msg) { if (_isServer) { return; } Debug.Log(string.Format("Set Player id {0}", msg.playerId)); _playerId = msg.playerId; _connectionData.playerId = msg.playerId; //PrintPlayerData(); }
public void SetPlayerId(PlayerConnectionData player, int id) { Net_PlayerId pi = new Net_PlayerId(id); SendToClient(player.hostId, player.connectionId, pi); }