public void Show(GameLogic.Result result) { switch (result) { case GameLogic.Result.HumanWon: this.resultText.text = "You won!"; break; case GameLogic.Result.AiWon: this.resultText.text = "You lost!"; break; case GameLogic.Result.Draw: this.resultText.text = "Draw!"; break; } this.gameObject.SetActive(true); }
private void PrepareNextTurn(TurnType turnType) { GameLogic.Result result = this.gameLogic.CheckGameOver(); if (result != GameLogic.Result.NotOver) { this.grid.PrepareForGameOver(); this.gameOver.Show(result); return; } if (turnType == TurnType.Human) { this.grid.PrepareForHumanTurn(); } else { this.grid.PrepareForAiTurn(); this.PlayAiTurn(); } }