Exemple #1
0
    public void ShowQuestionsPanel(QuestionData.question q)
    {
        SetButtonEnabled(true);

        MainGameController.ShowHud(false);
        UINavigationController.PushBackground("/MainBackground");
        UINavigationController.PushController(questionDialog);

        PrepareQuestion(q);
    }
Exemple #2
0
    /// <summary>
    /// Called after a player is succesfully landed on the target block and the player is correctly answers
    /// </summary>
    /// <param name="player">Player.</param>
    private void ProcessAfterPlayerMoved(PlayerController player)
    {
        if (activeNode != null)
        {
            currentPlayerGotPillar = player;

            Debug.Log("Player has moved to " + activeNode);
            if (activeNode.isPillar)
            {
                var pillar = GameData.GetColorTypeFromNodeType(activeNode.nodeType);

                UINavigationController.PushController("/WinPillar", (c) => {
                    WinPillarController pillarController = (WinPillarController)c;
                    if (pillarController)
                    {
                        pillarController.PillarWon(pillar);
                        pillarController.target = this.gameObject;
                        pillarController.func   = "AddPillar";
                    }
                }, null);
            }
            else
            {
                switch (activeNode.nodeType)
                {
                case NodeType.Root:
                    ShowHud(false);
                    UINavigationController.PushBackground("/MainBackground");
                    UINavigationController.PushController("/GameOver");
                    break;

                default:
                    GameClientPlugin.EndTurn(null);
                    break;
                }
            }
        }
    }
Exemple #3
0
 public void ShowCategory(Node node)
 {
     MainGameController.ShowHud(false);
     UINavigationController.PushBackground("/MainBackground");
     UINavigationController.PushController(questionCategoryDialog);
 }