Пример #1
0
    private void CheckInfra()
    {
        List <int> buttonTypes = new List <int>();

        if (_select is Flag || _select is HQ)
        {
            PopUp();
            buttonTypes.Add((int)ObjectNum.Comb);
            buttonTypes.Add((int)ObjectNum.Farm);
            buttonTypes.Add((int)ObjectNum.Flag);
            menu.SetButton(buttonTypes, _coins[currentTeam]);
        }

        if (_select is Comb)
        {
            PopUp();
            buttonTypes.Add((int)ObjectNum.Red);
            buttonTypes.Add((int)ObjectNum.Blue);
            menu.SetButton(buttonTypes, _coins[currentTeam]);
        }

        if (Input.GetMouseButtonDown(1))
        {
            _state = GameState.Select;
            _select.Highlight(false);
        }
    }