private IEnumerator Start() { PlayerProperties.CreatePlayerHashtable(); // initialize Transform t; t = transform.Find("Players"); playerTranformLeft = t.Find("Clients_Left"); playerTransformRight = t.Find("Clients_Right"); playerPrefab = playerTranformLeft.GetChild(0).gameObject; playerPrefab.SetActive(false); playerDictionary = new Dictionary <int, CharacterSelectPortrait>(); // wait for mode choice while (ModeSelect.Mode == 0) { yield return(null); } // Online // Create portraits based on who's connected if (ModeSelect.Mode == 2) { var players = NetworkManager.getSortedPlayers; foreach (var p in players) { AddPlayer(p.ID); } } }
public bool OpCreateRoomWithProperties(string roomName, RoomOptions options, TypedLobby lobby) { PlayerProperties.CreatePlayerHashtable(); options.CustomRoomProperties = RoomProperties.GetRoomHashtable(); return(OpCreateRoom(roomName, options, lobby)); }
public bool OpCreateRoomWithProperties(string roomName, RoomOptions options, TypedLobby lobby, string startingScene = "lobby") { options.CustomRoomPropertiesForLobby = new[] { PhotonConstants.propScene }; options.CustomRoomProperties = new Hashtable() { { PhotonConstants.propScene, startingScene } }; PlayerProperties.CreatePlayerHashtable(); return(OpCreateRoom(roomName, options, lobby)); }
public bool OpJoinRoomWithProperties(string roomName) { PlayerProperties.CreatePlayerHashtable(); return(OpJoinRoom(roomName)); }