mirror of
https://github.com/magefree/mage.git
synced 2026-01-25 04:39:18 -08:00
- Fixed #5758
This commit is contained in:
parent
7a35a76248
commit
9cab9bc429
1 changed files with 8 additions and 1 deletions
|
|
@ -18,6 +18,8 @@ import mage.target.TargetPermanent;
|
||||||
import mage.util.CardUtil;
|
import mage.util.CardUtil;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
import mage.abilities.mana.ManaAbility;
|
||||||
|
import mage.game.stack.Spell;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author TheElk801
|
* @author TheElk801
|
||||||
|
|
@ -76,7 +78,12 @@ class DovinHandOfControlEffect extends CostModificationEffectImpl {
|
||||||
@Override
|
@Override
|
||||||
public boolean applies(Ability abilityToModify, Ability source, Game game) {
|
public boolean applies(Ability abilityToModify, Ability source, Game game) {
|
||||||
Card card = game.getCard(abilityToModify.getSourceId());
|
Card card = game.getCard(abilityToModify.getSourceId());
|
||||||
return card != null && (card.isInstantOrSorcery() || card.isArtifact())
|
if (!(abilityToModify instanceof SpellAbility)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return card != null
|
||||||
|
&& (card.isInstantOrSorcery()
|
||||||
|
|| card.isArtifact())
|
||||||
&& game.getOpponents(source.getControllerId()).contains(abilityToModify.getControllerId());
|
&& game.getOpponents(source.getControllerId()).contains(abilityToModify.getControllerId());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue