Exemplo n.º 1
0
    void _EndTurn()
    {
        activePlayer++;
        if (activePlayer < totalPlayers)
        {
            SetPlayerTurn(activePlayer);
        }
        else
        {
            _turn++;
            board.EnactMetabolism();
            board.EnactProcreation();
            board.EnactMigration();
            board.EnactDiffusion();

            board.RebalanceMetabolism();
            board.SetDominionColors(players[0].playerColor, players[1].playerColor);
            activePlayer = 0;
            Winner winner = winMeters.UpdateWinner(board);
            if (winner != Winner.None)
            {
                UIWinner.SetWinner(winner);
            }
            else
            {
                SetPlayerTurn(activePlayer);
            }
        }
    }
Exemplo n.º 2
0
 // Update is called once per frame
 void Update()
 {
     UIWinner.write(container.Winner);
 }
Exemplo n.º 3
0
 private void Start()
 {
     _instance = this;
 }