mirror of
https://github.com/correl/mage.git
synced 2024-12-25 19:25:41 +00:00
Fixed Blazing Torch
This commit is contained in:
parent
38cfa14b34
commit
c3671b4c71
1 changed files with 12 additions and 3 deletions
|
@ -43,7 +43,7 @@ import mage.abilities.costs.CostImpl;
|
|||
import mage.abilities.costs.common.TapSourceCost;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CantBlockSourceEffect;
|
||||
import mage.abilities.effects.RestrictionEffect;
|
||||
import mage.abilities.effects.common.continious.GainAbilityAttachedEffect;
|
||||
import mage.abilities.keyword.EquipAbility;
|
||||
import mage.cards.CardImpl;
|
||||
|
@ -105,7 +105,8 @@ class BlazingTorchEvasionAbility extends EvasionAbility<BlazingTorchEvasionAbili
|
|||
}
|
||||
}
|
||||
|
||||
class BlazingTorchEvasionEffect extends CantBlockSourceEffect {
|
||||
|
||||
class BlazingTorchEvasionEffect extends RestrictionEffect<BlazingTorchEvasionEffect> {
|
||||
|
||||
public BlazingTorchEvasionEffect() {
|
||||
super(Duration.WhileOnBattlefield);
|
||||
|
@ -115,6 +116,14 @@ class BlazingTorchEvasionEffect extends CantBlockSourceEffect {
|
|||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean applies(Permanent permanent, Ability source, Game game) {
|
||||
if (permanent.getId().equals(source.getSourceId())) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) {
|
||||
return !blocker.hasSubtype("Vampire") && !blocker.hasSubtype("Zombie");
|
||||
|
@ -198,4 +207,4 @@ class BlazingTorchDamageEffect extends OneShotEffect<BlazingTorchDamageEffect> {
|
|||
public void setSourceId(UUID sourceId) {
|
||||
this.sourceId = sourceId;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue