Beispiel #1
0
    private void InputExit(int playerId)
    {
        PlayerBuild player = GetPlayerBuild(playerId);

        player.SetSelected(null);
        player.SetBuilding(false);
        ExitPanel();
    }
Beispiel #2
0
    private void MoveDown(int playerId)
    {
        PlayerBuild player = GetPlayerBuild(playerId);
        //Debug.Log ("Input Down");
        UIObject temp;

        //Debug.Log ("Selected: " + player.GetSelected ());
        temp = player.GetSelected();
        if (temp != null)
        {
            //Debug.Log ("Down: " + temp.GetDown());
            temp = temp.GetDown();
            if (temp != null)
            {
                player.SetSelected(temp);
            }
        }
    }
Beispiel #3
0
    private void OpenBuildPanel(int playerId)
    {
        canvas.SetActive(true);
        PlayerBuild player = GetPlayerBuild(playerId);

        player.SetBuilding(true);
        if (player.GetSelected() == null)
        {
            if (uiObjects.Count > 0)
            {
                player.SetSelected(uiObjects [0]);
            }
            else
            {
                Debug.Log("UiObjects for Build Panel is Empty");
            }
        }
    }