private void End() { if (this.State != GameState.Aborted) { this.State = GameState.Ended; } Reset(); _ActivePlayer = null; foreach (Player player in _Players) { lock (player) player.End(); } if (GameEndedEvent != null) { GameEndedEventArgs geea = new GameEndedEventArgs(); GameEndedEvent(this, geea); } }
private void End() { if (this.State != GameState.Aborted) this.State = GameState.Ended; Reset(); _ActivePlayer = null; foreach (Player player in _Players) { lock(player) player.End(); } if (GameEndedEvent != null) { GameEndedEventArgs geea = new GameEndedEventArgs(); GameEndedEvent(this, geea); } }