Ejemplo n.º 1
0
    public void Start()
    {
        playerDatabaseScript = GameObject.Find("GameManager_mn").GetComponent <PlayerDatabase>();
        GameObject PickSelectionObj = GameObject.Find("Window_PickSelection_mn");

        pickSelectionScript = PickSelectionObj.GetComponent <PickSelection>();

        uZone.InstanceManager.Server.AddListener(this.gameObject);
        //StartServer();
    }
Ejemplo n.º 2
0
    void OnJoinedRoom()
    {
        mainMenuManager.ShowMenu(windowPickSelection.GetComponent <Menu>());
        mainMenuManager.loadingScreenObj.SetActive(false);

        // GIVE THE NAME OF THE PLAYER TO THE PICK SELECTION WINDOW
        GameObject PickSelectionObj = GameObject.Find("Window_PickSelection_mn");

        PickSelection pickSelScript = PickSelectionObj.GetComponent <PickSelection>();

        //pickSelScript.PlayerName = PlayerPrefs.GetString("playername");
        pickSelScript.CreateLayout();
        pickSelScript.CreatePickLayout();
    }
Ejemplo n.º 3
0
    public void uLink_OnConnectedToServer()
    {
        introSource.Stop();
        mainMenuManager.ShowMenu(windowPickSelection.GetComponent <Menu>());
        mainMenuManager.loadingScreenObj.SetActive(false);

        // GIVE THE NAME OF THE PLAYER TO THE PICK SELECTION WINDOW
        GameObject PickSelectionObj = GameObject.Find("Window_PickSelection_mn");

        PickSelection pickSelScript = PickSelectionObj.GetComponent <PickSelection>();

        pickSelScript.PlayerName = PlayerPrefs.GetString("playername");
        pickSelScript.CreateLayout();
        pickSelScript.CreatePickLayout();
    }
Ejemplo n.º 4
0
    void uZone_OnConnected(string id)
    {
        serverName = uZone.InstanceManager.Server.cmdArgs[1];
        maxPlayers = Convert.ToInt32(uZone.InstanceManager.Server.cmdArgs[2]);
        UnityEngine.Debug.Log("Instance connected.");
        gameServerPort = uZone.InstanceManager.Server.gameServerPort;
        uLink.Network.InitializeServer(32, uZone.InstanceManager.Server.gameServerPort);
        //ServerRegistry.AddServer(gameServerIP, uZone.InstanceManager.Server.gameServerPort, numPlayers, maxPlayers, serverName);

        Lobby.AddListener(this);
        Lobby.ConnectAsServer(lobbyIP, lobbyPort);

        GameObject PickSelectionObj = GameObject.Find("Window_PickSelection");

        mainMenuManager.ShowMenu(windowPickSelection.GetComponent <Menu>());
        PickSelection pickSelScript = PickSelectionObj.GetComponent <PickSelection>();

        pickSelScript.CreateLayout();
        pickSelScript.CreatePickLayout();
    }
Ejemplo n.º 5
0
 // Use this for initialization
 void Start()
 {
     characters       = new Stack <Char_Pick>();
     playerPickObj    = GameObject.Find("Window_PickSelection_mn");
     playerPickScript = playerPickObj.GetComponent <PickSelection>();
 }
Ejemplo n.º 6
0
    // Use this for initialization

    void Start()
    {
        playerPickObj    = GameObject.Find("Window_PickSelection_mn");
        playerPickScript = playerPickObj.GetComponent <PickSelection>();
    }