mirror of
https://github.com/correl/mage.git
synced 2024-11-15 19:19:33 +00:00
[refactoring] minor
This commit is contained in:
parent
b12c3530af
commit
9a5525ab24
2 changed files with 3 additions and 8 deletions
|
@ -95,11 +95,11 @@ class BeguilerOfWillsTarget extends TargetPermanent {
|
|||
@Override
|
||||
public boolean canTarget(UUID controllerId, UUID id, Ability source, Game game) {
|
||||
Permanent permanent = game.getPermanent(id);
|
||||
int count = game.getBattlefield().countAll(new FilterCreaturePermanent(), source.getControllerId());
|
||||
int count = game.getBattlefield().countAll(this.filter, source.getControllerId());
|
||||
|
||||
if (permanent != null && permanent.getPower().getValue() <= count) {
|
||||
return super.canTarget(controllerId, id, source, game);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -38,14 +38,11 @@ import mage.MageInt;
|
|||
import mage.abilities.Ability;
|
||||
import mage.abilities.ActivatedAbility;
|
||||
import mage.abilities.DelayedTriggeredAbility;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.common.SimpleActivatedAbility;
|
||||
import mage.abilities.costs.mana.GenericManaCost;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.AsThoughEffectImpl;
|
||||
import mage.abilities.effects.ContinuousEffectImpl;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CounterUnlessPaysEffect;
|
||||
import mage.cards.Card;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.filter.FilterCard;
|
||||
|
@ -53,9 +50,7 @@ import mage.filter.common.FilterCreatureCard;
|
|||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
import mage.game.permanent.Permanent;
|
||||
import mage.game.stack.Spell;
|
||||
import mage.target.common.TargetCardInGraveyard;
|
||||
import mage.target.targetpointer.FixedTarget;
|
||||
|
||||
/**
|
||||
*
|
||||
|
@ -215,4 +210,4 @@ class HavengulLichEffect extends ContinuousEffectImpl<HavengulLichEffect> {
|
|||
}
|
||||
return false;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue