CardFactory: fixed RollPlanarDice with unorthodox way

This commit is contained in:
Hanmac
2016-08-07 15:43:12 +00:00
parent ca5a592739
commit e52b6c065a

View File

@@ -365,15 +365,16 @@ public class CardFactory {
triggerSB.append("that planar deck and turn it face up"); triggerSB.append("that planar deck and turn it face up");
StringBuilder saSB = new StringBuilder(); StringBuilder saSB = new StringBuilder();
saSB.append("AB$ RollPlanarDice | Cost$ PlanarDiceCostX | References$ PlanarDiceCostX | SorcerySpeed$ True | AnyPlayer$ True | ActivationZone$ Command | "); saSB.append("AB$ RollPlanarDice | Cost$ X | SorcerySpeed$ True | AnyPlayer$ True | ActivationZone$ Command | ");
saSB.append("SpellDescription$ Roll the planar dice. X is equal to the amount of times the planar die has been rolled this turn."); saSB.append("SpellDescription$ Roll the planar dice. X is equal to the amount of times the planar die has been rolled this turn.");
card.setSVar("RolledWalk", "DB$ Planeswalk | Cost$ 0"); card.setSVar("RolledWalk", "DB$ Planeswalk | Cost$ 0");
Trigger planesWalkTrigger = TriggerHandler.parseTrigger(triggerSB.toString(), card, true); Trigger planesWalkTrigger = TriggerHandler.parseTrigger(triggerSB.toString(), card, true);
card.addTrigger(planesWalkTrigger); card.addTrigger(planesWalkTrigger);
card.setSVar("PlanarDiceCostX", "Count$RolledThisTurn");
SpellAbility planarRoll = AbilityFactory.getAbility(saSB.toString(), card); SpellAbility planarRoll = AbilityFactory.getAbility(saSB.toString(), card);
planarRoll.setSVar("X", "Count$RolledThisTurn");
card.addSpellAbility(planarRoll); card.addSpellAbility(planarRoll);
} }