public override Chase Play(Chase currentState, UIManager uiManager) { ChaseMutator mutator = new ChaseMutator(currentState, uiManager, $"playing {this.Name}"); mutator.ActivateCard(this); mutator.AddPlayerSpeed(-(currentState.PlayerSpeed - SetSpeedTo)); mutator.AddLead(LeadIncrease); return(mutator.ExhaustFromRoute(this).Done()); }
public override Chase Play(Chase currentState, UIManager uiManager) { ChaseMutator mutator = new ChaseMutator(currentState, uiManager, $"playing {this.Name}"); mutator.ActivateCard(this); if (currentState.PlayerSpeed > SpeedThreshold) { mutator.AddDamageToTopOfDeck(Damage); } return(mutator.DiscardFromRoute(this).Done()); }
public override Chase Play(Chase currentState, UIManager uiManager) { ChaseMutator mutator = new ChaseMutator(currentState, uiManager, $"playing {this.Name}"); if (currentState.Lead >= LeadRequired) { mutator.SetPlayerHasWon(); } return(mutator .ActivateCard(this) .DiscardFromRoute(this) .Done()); }
public override Chase Play(Chase currentState, UIManager uiManager) { ChaseMutator mutator = new ChaseMutator(currentState, uiManager, $"playing {this.Name}"); mutator.ActivateCard(this); bool triggerFirstDecrease = currentState.PlayerSpeed > SpeedThreshold1; bool triggerSecondDecrease = currentState.PlayerSpeed - SpeedDecrease1 > SpeedThreshold2; if (triggerFirstDecrease) { mutator.AddPlayerSpeed(-SpeedDecrease1); } if (triggerSecondDecrease) { mutator.AddPlayerSpeed(-SpeedDecrease2); } return(mutator.DiscardFromRoute(this).Done()); }