Exemple #1
0
 private void RouletteOnSpinCompleted(object sender, RouletteEventArgs rouletteEventArgs)
 {
     if (rouletteEventArgs.Color == Color.Red)
     {
         Log.Info($"Red wins with number {rouletteEventArgs.Number}.");
     }
 }
 private void RouletteOnSpinCompleted(object sender, RouletteEventArgs rouletteEventArgs)
 {
     if (rouletteEventArgs.Number % 2 == 0 && rouletteEventArgs.Number != 0)
     {
         Log.Info($"Even wins with number {rouletteEventArgs.Number} and color {rouletteEventArgs.Color}.");
     }
 }
Exemple #3
0
 /// <summary>
 /// Raises the <see cref="E:SpinCompleted" /> event.
 /// </summary>
 /// <param name="e">The <see cref="RouletteEventArgs"/> instance containing the event data.</param>
 protected virtual void OnSpinComleted(RouletteEventArgs e) => SpinCompleted?.Invoke(this, e);