Beispiel #1
0
    IEnumerator ASyncTurnEnd()
    {
        if (!AnimationInteractionController.AllAnimationsFinished())
        {
            yield return(new WaitForSeconds(AnimationInteractionController.AFTER_KILL));
        }
        Debug.Log("EndTurn");
        //Perform end turn actions
        EndTurnActions();
        //Deselect selected tiles
        BoardProxy.instance.FlushTiles();
        //Play the turn cutscene

        PanelControllerNew.ClearPanels();

        //Switch controller teams
        SwitchTeams();
        //Perform start turn actions
        StartTurn(false);

        //Run AI (if applicable)
        if (currentTeam == BoardProxy.ENEMY_TEAM && !BoardProxy.HUMAN_PLAYER)
        {
            if (hard)
            {
                AdvancedBrain.StartThinking();
            }
            else
            {
                BasicBrain.StartThinking();
            }
        }
    }
Beispiel #2
0
 void Awake()
 {
     instance = this;
     cam      = Camera.main;
 }