using System; using System.Collections.Generic; public class AllocsRequestToSpawnPlayer { public static void RequestToSpawnPlayer (GameManager manager, int _clientId, string _name, string _playerClassname, string _skinTexture, int _chunkViewDim) { string ip = manager.connectionManager.connectedClients [_clientId].networkPlayer.ipAddress; string name = string.Empty; int entityId = -1; Dictionary d = manager.connectionManager.mapClientToEntity; if (d.ContainsKey (_clientId)) { entityId = d [_clientId]; World w = manager.World; name = w.playerEntities.dict [entityId].EntityName; } Log.Out ("Player connected, clientid=" + _clientId + ", entityid=" + entityId + ", name=" + name + ", steamid=" + SingletonMonoBehaviour.Instance.GetPlayerId (name) + ", ip=" + ip); } }