Пример #1
0
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();
        }
Пример #2
0
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);


            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();
        }
Пример #3
0
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
Пример #4
0
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
            m_soundManager.PlaySound(SoundManager.AudioClipList.AC_clickBtnMenu);
        }
Пример #5
0
        public void OnClickCreateMatchmakingGame()
        {
            lobbyManager.StartMatchMaker();
            lobbyManager.matchMaker.CreateMatch(
                GenerateMatchName(),
                (uint)lobbyManager.maxPlayers,
                true,
                "", "", "", 0, 0,
                lobbyManager.OnMatchCreate);

            lobbyManager.backDelegate = lobbyManager.StopHost;
            lobbyManager.DisplayIsConnecting();
        }
Пример #6
0
        public void OnClickJoin()
        {
            SoundManager.instance.PlaySound(5, 1.0f, AudioType.SFX);
            DataManager.instance.localPlayerName = nameInput.text;
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);
            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);


            lobbyManager.GetComponent <NetworkDiscovery>().isClient = true;
        }
Пример #8
0
        public void OnClickJoin(LanConnectionInfo match)
        {
            NDiscovery.instance.StopDiscovery();

            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = match.ipAddress;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
Пример #9
0
        public void OnClickHotJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);


            lobbyManager.networkAddress = ipInput.text;

            Network.Connect(lobbyManager.networkAddress, 7777);

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
            //Debug.LogError("goto: " + lobbyManager.networkAddress);
        }
Пример #10
0
        public void OnClickJoin()
        {
            Debug.Log("clienta se encuntra conectado");

            //se abre panel lobby
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
 {
     lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
        public void OnClickJoin(string ip)
        {
            //Change the canvas to lobby panel
            lobbyManager.ChangeTo(lobbyPanel);

            //if an ip address is called as a parameter of this method assume
            //that the connection should be made with this ip
            //if not then use the IP address typed in by the user
            if (ip != null)
            {
                lobbyManager.networkAddress = ip;
            }
            else
            {
                //this will retreive the text from the input field
                //the user can enter any ip address here.
                //must enter a local network IP address if on the same network
                lobbyManager.networkAddress = ipInput.text;
            }

            //Start a client connection
            lobbyManager.StartClient();

            //stops the client from using callback later
            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            //show a connecting menu, so the user knows its connecting
            //This will fail or timeout if the ipaddress is abandoned or incorrect
            lobbyManager.DisplayIsConnecting();
            //connect using the network address
            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
 {
     lobbyManager.matchMaker.JoinMatch(networkID, "", lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
Пример #14
0
        public void OnClickJoin()
        {
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
            _gGame_Name.SetActive(true);
            _gMenu_Name.SetActive(false);
            _gSer_Name.SetActive(true);
            _gRoom_Panel.SetActive(true);
            _gRoom_Game_Name.SetActive(true);
        }
Пример #15
0
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager, int max)
 {
     GameLogic.kolvoPlayers = max;
     lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
Пример #16
0
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager, string name)
 {
     lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.lobbyPanel.GetComponent <LobbyPlayerList> ().ChangeTitle(name);
     lobbyManager.DisplayIsConnecting();
 }
Пример #17
0
 void JoinMatch(string networkID, LobbyManager lobbyManager)
 {
     NetworkManager.singleton.networkAddress = networkID;
     NetworkManager.singleton.networkPort    = 7777;
     NetworkManager.singleton.StartClient();
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
Пример #18
0
        public void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
        {
            lobbyManager.StartMatchMaker();
            Debug.Log("Me uno a este ID MATCH!!!: " + networkID);

            lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
            lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
            lobbyManager._isMatchmaking = true;
            lobbyManager.DisplayIsConnecting();
        }
Пример #19
0
        void JoinMatch()
        {
            string password = lobbyServerList.passwordInput.text;

            lobbyServerList.passwordInput.text = "";

            lobbyManager.matchMaker.JoinMatch((NetworkID)networkID, password, "", "", 0, 0, lobbyManager.OnMatchJoined);
            lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
            lobbyManager._isMatchmaking = true;
            lobbyManager.DisplayIsConnecting();
        }
Пример #20
0
 public void OnClickJoin()
 {
     //ChooseScene.SetActive (false);
     lobbyManager.ChangeTo(lobbyPanel);
     print(ipInput.text);
     print(Convert.HashToIP(ipInput.text));
     lobbyManager.networkAddress = Convert.HashToIP(ipInput.text);
     lobbyManager.StartClient();
     lobbyManager.backDelegate = lobbyManager.StopClientClbk;
     lobbyManager.DisplayIsConnecting();
     lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
 }
Пример #21
0
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
 {
     Debug.Log("JoinMatch triggered " + networkID);
     if (!lobbyManager._isMatchmaking)
     {
         Debug.Log("not matchmaking", lobbyManager);
         lobbyManager.StartMatchMaker();
     }
     lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
Пример #22
0
        public void OnClickJoin()
        {
            /*
             * if (Time.time < lobbyManager.startTime + 45f)
             * {
             *  lobbyManager.infoPanel.Display("Please wait while loading.\n"
             + (int)(lobbyManager.startTime + 45f - Time.time) + " seconds left.", "Close", null);
             +  return;
             + }
             */
            lobbyManager.ChangeTo(lobbyPanel);

            lobbyManager.minPlayers        = 2;
            lobbyManager.maxPlayers        = 5;
            lobbyManager.prematchCountdown = 5f;
            lobbyManager.networkAddress    = "uriel.upnl.org"; //ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }
Пример #23
0
        public void OnClickCreateMatchmakingGame()
        {
            lobbyManager.roomName = matchNameInput.text;
            this.gameObject.SetActive(false);
//			lobbyManager.StartMatchMaker();
            lobbyManager.matchMaker.CreateMatch(
                matchNameInput.text,
                (uint)lobbyManager.maxPlayers,
                true,
                "", "", "", 0, 0,
                lobbyManager.OnMatchCreate);

            lobbyManager.DisplayIsConnecting();
        }
Пример #24
0
        public void OnClickJoin()
        {
            _callback = () =>
            {
                NetClientSingleton.Instance.StartClient(OnReceivedBroadcast);

                _lobbyManager.ChangeTo(_lobbyPanel);
                _lobbyPanel.GetComponent <LobbyPlayerList>().Init(_lobbyManager.GameType);

                _lobbyManager.backDelegate = BackFromJoint;
                _lobbyManager.DisplayIsConnecting();
            };

            _gameTypeSelect.gameObject.SetActive(true);
        }
Пример #25
0
 void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
 {
     _gDefense_Panel.SetActive(true);
     _gBack_Btn.GetComponent <Button>().interactable = false;
     Invoke("Defense_Panel_Off", 2.0f);
     _gRoom_Name.SetActive(false);
     _gSerRoom_Name.SetActive(true);
     _gRoom_Panel.SetActive(true);
     _gRoom_Game_Name.SetActive(true);
     _gSerRoom_Name.GetComponent <Text>().text = serverInfoText.text;
     lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
     lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
     lobbyManager._isMatchmaking = true;
     lobbyManager.DisplayIsConnecting();
 }
        void bSubmitOnClick()
        {
            lobbyManager.StartMatchMaker();
            lobbyManager.matchMaker.CreateMatch(
                matchNameInput.text,
                (uint)lobbyManager.maxPlayers,
                true,
                "", "", "", 0, 0,
                lobbyManager.OnMatchCreate);

            lobbyManager.backDelegate   = lobbyManager.StopHost;
            lobbyManager._isMatchmaking = true;
            lobbyManager.lobbyPanel.GetComponent <LobbyPlayerList> ().ChangeTitle(matchNameInput.text);
            lobbyManager.DisplayIsConnecting();
        }
        public void OnClickJoin()
        {
            if (achivementController.GetPlayer() != null)
            {
                lobbyManager.ChangeTo(lobbyPanel);

                lobbyManager.networkAddress = ipInput.text;
                lobbyManager.StartClient();

                lobbyManager.backDelegate = lobbyManager.StopClientClbk;
                lobbyManager.DisplayIsConnecting();

                lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
            }
        }
        public void OnClickCreateMatchmakingGame()
        {
            lobbyManager.StartMatchMaker();
            lobbyManager.matchMaker.CreateMatch(
                matchNameInput.text,
                (uint)lobbyManager.maxPlayers,
                true,
                "", "", "", 0, 0,
                lobbyManager.OnMatchCreate);

            lobbyManager.backDelegate   = lobbyManager.StopHost;
            lobbyManager._isMatchmaking = true;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Matchmaker Host", lobbyManager.matchHost);
        }
Пример #29
0
        public void OnGUIMatchList(bool success, string extendedInfo, List <MatchInfoSnapshot> matches)
        {
            if (matches.Count == 0)
            {
                string roomName = GameObject.Find("UserDetailsInfo").GetComponent <LogonManager>().GetUsername();
                if (roomName == "")
                {
                    roomName = "emptyRoom";
                }

                lobbyManager.matchMaker.CreateMatch(
                    roomName,
                    (uint)lobbyManager.maxPlayers,
                    true,
                    "", "", "", 0, 0,
                    lobbyManager.OnMatchCreate);

                lobbyManager.backDelegate   = lobbyManager.StopHost;
                lobbyManager._isMatchmaking = true;
                lobbyManager.DisplayIsConnecting();

                lobbyManager.SetServerInfo("Matchmaker Host", lobbyManager.matchHost);
                return;
            }

            noServerFound.SetActive(false);
            foreach (Transform t in serverListRect)
            {
                Destroy(t.gameObject);
            }

            for (int i = 0; i < matches.Count; ++i)
            {
                if (matches[0].currentSize == 1) //one player in game
                {
                    lobbyManager.matchMaker.JoinMatch(matches[i].networkId, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
                    return;
                }
            }

            ++currentPage;
            RequestPage(currentPage);
        }
Пример #30
0
        void JoinMatch(NetworkID networkID, LobbyManager lobbyManager)
        {
            lobbyManager.matchMaker.JoinMatch(networkID, "", "", "", 0, 0, lobbyManager.OnMatchJoined);
            lobbyManager.backDelegate   = lobbyManager.StopClientClbk;
            lobbyManager._isMatchmaking = true;
            lobbyManager.DisplayIsConnecting();

            Text[] lists = GameObject.Find("LobbyManager").GetComponentsInChildren <Text>(true);
            Text   LobbyRoomName;

            for (int i = 0; i < lists.Length; i++)
            {
                if (lists[i].gameObject.name == "RoomNameDisplay")
                {
                    LobbyRoomName      = lists [i];
                    LobbyRoomName.text = roomInfoText.text;
                    break;
                }
            }
        }
Пример #31
0
        public void OnClickJoin()
        {
            if (!MainMenuManager.isMultiplayerButtonClicked)
            {
                return;
            }
            MainMenuManager.isPlayerConnected = true;
            otherCanvasAnimator.Play("Host_Join");

            lobbyManager.ChangeTo(lobbyPanel);

            if (ipInput.Equals(string.Empty))
            {
                ipInput.text = "localhost";
            }
            lobbyManager.networkAddress = ipInput.text;
            lobbyManager.StartClient();

            lobbyManager.backDelegate = lobbyManager.StopClientClbk;
            lobbyManager.DisplayIsConnecting();

            lobbyManager.SetServerInfo("Connecting...", lobbyManager.networkAddress);
        }