void Start() { lobby = PlayerClassInitLobbyManager.Instance; ShowMainPanel(); lobbyPlayerName.onValueChanged.AddListener(name => { MockPlayer.LocalMockPlayer.PlayerName = name; }); DontDestroyOnLoad(this.gameObject); lobby.StartMatchMaker(); }
void Awake() { if (Instance != null) { Destroy(this.gameObject); Debug.Log("Destroyed this PlayerClassInitLobbyManagerObject because one already exists!"); return; } Instance = this; /*this.matchHost = Host; * this.matchPort = Port; * this.StartClient();*/ }