示例#1
0
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
 {
     lobbyManager.DisplayIsConnecting();
     lobbyManager.matchMaker.JoinMatch(networkID, "", lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate = lobbyManager.StopClientClbk;
     lobbyManager.isMatchmaking = true;
 }
示例#2
0
        void Start()
        {
            Singleton = this;
            _lobbyHooks = GetComponent<LobbyHook>();
			currentPanel = startMenu;

            backButton.gameObject.SetActive(false);
            GetComponent<Canvas>().enabled = true;

            DontDestroyOnLoad(gameObject);

            SetServerInfo("Offline", "None");
        }
示例#3
0
        public void Populate(MatchDesc match, LobbyManager lobbyManager, Color c)
        {
            serverInfoText.text = match.name;

            slotInfo.text = match.currentSize.ToString() + "/" + match.maxSize.ToString();

            NetworkID networkID = match.networkId;

            joinButton.onClick.RemoveAllListeners();
            joinButton.onClick.AddListener(() => { JoinMatch(networkID, lobbyManager); });

            GetComponent<Image>().color = c;
        }