mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-19 04:08:01 +00:00
Fix Standstill
This commit is contained in:
@@ -579,7 +579,7 @@ public class TriggerHandler {
|
||||
sa.setOptionalTrigger(true);
|
||||
decider = AbilityUtils.getDefinedPlayers(host, regtrig.getParam("OptionalDecider"), sa).get(0);
|
||||
}
|
||||
else if (sa instanceof AbilitySub || !sa.hasParam("Cost") || sa.getParam("Cost").equals("0")) {
|
||||
else if (sa instanceof AbilitySub || !sa.hasParam("Cost") || sa.hasParam("CostMandatory") || sa.getParam("Cost").equals("0")) {
|
||||
isMandatory = true;
|
||||
} else { // triggers with a cost can't be mandatory
|
||||
sa.setOptionalTrigger(true);
|
||||
|
||||
@@ -2,9 +2,7 @@ Name:Standstill
|
||||
ManaCost:1 U
|
||||
Types:Enchantment
|
||||
T:Mode$ SpellCast | ValidActivatingPlayer$ Player | TriggerZones$ Battlefield | Execute$ TrigSac | TriggerDescription$ When a player casts a spell, sacrifice CARDNAME. If you do, each of that player's opponents draws three cards.
|
||||
SVar:TrigSac:DB$ Sacrifice | SacValid$ Self | RememberSacrificed$ True | SubAbility$ DrawOpp
|
||||
SVar:DrawOpp:DB$ Draw | NumCards$ 3 | Defined$ TriggeredCardOpponent | ConditionCheckSVar$ X | ConditionSVarCompare$ GE1 | SubAbility$ DBCleanup
|
||||
SVar:DBCleanup:DB$ Cleanup | ClearRemembered$ True
|
||||
SVar:TrigSac:AB$ Draw | NumCards$ 3 | Cost$ Sac<1/CARDNAME> | CostMandatory$ True | Defined$ TriggeredCardOpponent
|
||||
SVar:X:Remembered$Amount
|
||||
SVar:Y:Count$Valid Creature.YouCtrl
|
||||
SVar:Z:Count$Valid Creature.OppCtrl
|
||||
|
||||
@@ -1023,7 +1023,7 @@ public class HumanCostDecision extends CostDecisionMakerBase {
|
||||
|
||||
if (cost.payCostFromSource()) {
|
||||
if (source.getController() == ability.getActivatingPlayer() && source.isInPlay()) {
|
||||
return player.getController().confirmPayment(cost, Localizer.getInstance().getMessage("lblSacrificeCardConfirm", CardTranslation.getTranslatedName(source.getName())), ability) ? PaymentDecision.card(source) : null;
|
||||
return ability.hasParam("CostMandatory") || player.getController().confirmPayment(cost, Localizer.getInstance().getMessage("lblSacrificeCardConfirm", CardTranslation.getTranslatedName(source.getName())), ability) ? PaymentDecision.card(source) : null;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user