private void WinGame() { m_gameComplete = true; foreach (PlayerController player in m_allPlayers) { player.enabled = false; } m_gameCompleteEvent.Invoke(); if (m_winAnim != null) { m_winAnim.ShowWinAnimation(m_winningPlayer.transform, m_winningPlayer.m_winningCameraPos); } }
private void PublishGameComplete() { LogInfo("Game has ended, the winnig player is " + (Winner == null ? "no one, game ended in a draw" : Winner.Name)); LogInfo("Leader Board"); for (int i = 0; i < LeaderBoard.Count; i++) { LogInfo(i + ": " + LeaderBoard[i]); } foreach (var player in _players) { player.GameEnded(_gameMap); } _gameComplete = true; GameComplete?.Invoke(_gameMap, LeaderBoard); }
private void InternalGameComplete(object sender, GameCompleteEventArgs e) { GameComplete?.Invoke(this, e); }
private void RaiseGameComplete() { GameComplete?.Invoke(this, new GameCompleteEventArgs { ElapsedTime = CurrentPresenter.ElapsedTime }); }