Ejemplo n.º 1
0
    private void Resume()
    {
        settingMenu.SetActive(false);
        Time.timeScale = 1.0f;

        backDelegate = ShowBoard;
    }
Ejemplo n.º 2
0
 void Start()
 {
     instance = this;
     DontDestroyOnLoad(gameObject);
     lobbyHook    = GetComponent <LobbyHook>();
     backDelegate = Back_MainScene;
 }
Ejemplo n.º 3
0
        private void BtnAddContact_Click(object sender, EventArgs e)
        {
            BackDelegate backDelegate = new BackDelegate(Back);

            new ContactRegistratonForm(backDelegate).Visible = true;
            this.Visible = false;
        }
Ejemplo n.º 4
0
    private void RefreshAfterDisconnect()
    {
        mainMenu.SetCurrentCanvasGroup(mainMenu.mainGroup, true);
        backDelegate            = Back_MainScene;
        backButton.interactable = true;

        mainMenu.RefreshList(3);
    }
Ejemplo n.º 5
0
    public override void OnClientConnect(NetworkConnection conn)
    {
        base.OnClientConnect(conn);
        Debug.Log("OnClientConnect: " + conn);

        onClientConnect.Invoke(conn);

        if (!NetworkServer.active)
        {
            backDelegate = Back_StopClient;
        }
    }
Ejemplo n.º 6
0
        private void DgbContacts_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            this.Id    = Convert.ToInt32(this.dgvContacts.SelectedCells[0].Value.ToString());
            this.Name  = this.dgvContacts.SelectedCells[1].Value.ToString();
            this.Email = this.dgvContacts.SelectedCells[2].Value.ToString();
            if (this.Email == "-")
            {
                this.Email = "";
            }
            BackDelegate backDelegate = new BackDelegate(Back);

            new ContactInformationForm(backDelegate, this.Id, this.Name, this.Email).Visible = true;
            this.Visible = false;
        }
Ejemplo n.º 7
0
    // Choose control
    public void Yes2Btn()
    {
        Time.timeScale = 1.0f;

        chooseControl.SetActive(false);
        setting.SetActive(true);
        settingMenu.SetActive(false);

        backDelegate = ShowBoard;

        if (PlayerPrefs.GetInt(GameConstants.SOUND, 1) == 1)
        {
            SoundManager.Instance.buttonClick.Play();
        }
    }
Ejemplo n.º 8
0
    // Setting btn is clicked
    public void Setting()
    {
        if (!GameController.Instance.EndMatch)
        {
            settingMenu.SetActive(true);
            Time.timeScale = 0.0f;

            backDelegate = Resume;

            if (PlayerPrefs.GetInt(GameConstants.SOUND, 1) == 1)
            {
                SoundManager.Instance.buttonClick.Play();
            }
        }
    }
Ejemplo n.º 9
0
    private void ShowBoard()
    {
        team.SetActive(false);
        inGameButtons.SetActive(false);
        inGame.SetActive(false);
        teamsBoard.SetActive(true);

        GameController.Instance.SetObjectsInMatch(false);
        RemoveTeams();

        playDelegate = ConfirmTeam;
        backDelegate = RemoveTeams;

        GameController.Instance.ChangeSkyColor();
    }
Ejemplo n.º 10
0
    // Surrender
    public void YesBtn()
    {
        Time.timeScale = 1.0f;

        confirm.SetActive(false);
        setting.SetActive(true);
        settingMenu.SetActive(false);
        GameController.Instance.Surrender();

        backDelegate = ShowBoard;

        if (PlayerPrefs.GetInt(GameConstants.SOUND, 1) == 1)
        {
            SoundManager.Instance.buttonClick.Play();
        }

        AdManager.instance.ShowFullScreenAd(); // Interstitial ad
    }
Ejemplo n.º 11
0
    void OnLevelWasLoaded(int level)
    {
        if (LobbyManager.Instance != this)
        {
            return;
        }

        Debug.Log("OnLevelWasLoaded");

        if (SceneManager.GetActiveScene().name == lobbyScene)
        {
            panelLobby.SetActive(true);

            if (NetworkServer.active)
            {
                backDelegate = Back_StopHost;
            }
            else
            {
                backDelegate = Back_StopClient;
            }
        }
    }
Ejemplo n.º 12
0
 public override void OnStartHost()
 {
     base.OnStartHost();
     Debug.Log("OnStartHost");
     backDelegate = Back_StopHost;
 }