mirror of
https://github.com/correl/mage.git
synced 2024-12-27 03:00:13 +00:00
[DTK] Fixed Dash cost reduction effect of Warbringer.
This commit is contained in:
parent
325aab10a2
commit
9f1cf7993c
1 changed files with 2 additions and 7 deletions
|
@ -32,6 +32,7 @@ import mage.MageInt;
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.SpellAbility;
|
import mage.abilities.SpellAbility;
|
||||||
import mage.abilities.common.SimpleStaticAbility;
|
import mage.abilities.common.SimpleStaticAbility;
|
||||||
|
import mage.abilities.condition.common.DashedCondition;
|
||||||
import mage.abilities.effects.common.cost.CostModificationEffectImpl;
|
import mage.abilities.effects.common.cost.CostModificationEffectImpl;
|
||||||
import mage.abilities.keyword.DashAbility;
|
import mage.abilities.keyword.DashAbility;
|
||||||
import mage.cards.CardImpl;
|
import mage.cards.CardImpl;
|
||||||
|
@ -99,13 +100,7 @@ class WarbringerSpellsCostReductionEffect extends CostModificationEffectImpl {
|
||||||
if (abilityToModify.getControllerId().equals(source.getControllerId())) {
|
if (abilityToModify.getControllerId().equals(source.getControllerId())) {
|
||||||
Spell spell = (Spell) game.getStack().getStackObject(abilityToModify.getId());
|
Spell spell = (Spell) game.getStack().getStackObject(abilityToModify.getId());
|
||||||
if (spell != null) {
|
if (spell != null) {
|
||||||
for (Ability ability : spell.getCard().getAbilities()) {
|
return DashedCondition.getInstance().apply(game, abilityToModify);
|
||||||
if (ability instanceof DashAbility) {
|
|
||||||
if (((DashAbility) ability).isActivated()) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue