protected virtual void OnTurnFinished(TurnEventArgs e) { EventHandler <TurnEventArgs> handler = TurnFinished; if (handler != null) { handler(this, e); } }
private void TriggerTurnFinishedEvent(IPlayer player, Int32 round, Int32 orderOfPosition, Int32 goAgainCount) { var turn = new TurnEventArgs() { Doubles = dice.Doubles, GoAgainCount = goAgainCount, OrderOfPosition = orderOfPosition, Player = player, Roll = dice.RollResults, Round = round, }; OnTurnFinished(turn); }