mirror of
https://github.com/magefree/mage.git
synced 2026-01-23 11:49:56 -08:00
[EOE] Implement Dawnstrike Vanguard
This commit is contained in:
parent
d8449bf403
commit
f690d48b20
6 changed files with 104 additions and 38 deletions
|
|
@ -0,0 +1,41 @@
|
|||
package mage.abilities.condition.common;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.condition.Condition;
|
||||
import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount;
|
||||
import mage.abilities.hint.Hint;
|
||||
import mage.abilities.hint.ValueHint;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.common.FilterControlledCreaturePermanent;
|
||||
import mage.filter.predicate.permanent.TappedPredicate;
|
||||
import mage.game.Game;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public enum TwoTappedCreaturesCondition implements Condition {
|
||||
instance;
|
||||
private static final FilterPermanent filter = new FilterControlledCreaturePermanent();
|
||||
|
||||
static {
|
||||
filter.add(TappedPredicate.TAPPED);
|
||||
}
|
||||
|
||||
private static final Hint hint = new ValueHint(
|
||||
"Tapped creatures you control", new PermanentsOnBattlefieldCount(filter)
|
||||
);
|
||||
|
||||
public static Hint getHint() {
|
||||
return hint;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
return game.getBattlefield().contains(filter, source.getControllerId(), source, game, 2);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "you control two or more tapped creatures";
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue