mirror of
https://github.com/correl/mage.git
synced 2024-12-25 19:25:41 +00:00
[ZNR] Implemented Goma Fada Vanguard
This commit is contained in:
parent
89b58a3831
commit
af1e33a6c0
2 changed files with 71 additions and 0 deletions
70
Mage.Sets/src/mage/cards/g/GomaFadaVanguard.java
Normal file
70
Mage.Sets/src/mage/cards/g/GomaFadaVanguard.java
Normal file
|
@ -0,0 +1,70 @@
|
|||
package mage.cards.g;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.MageObject;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.AttacksTriggeredAbility;
|
||||
import mage.abilities.effects.common.combat.CantBlockTargetEffect;
|
||||
import mage.cards.s.SpellstutterSprite;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.FilterPermanent;
|
||||
import mage.filter.common.FilterCreaturePermanent;
|
||||
import mage.filter.common.FilterOpponentsCreaturePermanent;
|
||||
import mage.filter.predicate.ObjectSourcePlayer;
|
||||
import mage.filter.predicate.ObjectSourcePlayerPredicate;
|
||||
import mage.game.Game;
|
||||
import mage.target.TargetPermanent;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class GomaFadaVanguard extends CardImpl {
|
||||
|
||||
private static final FilterPermanent filter = new FilterOpponentsCreaturePermanent(
|
||||
"creature an opponent controls with power less than or equal to the number of Warriors you control"
|
||||
);
|
||||
|
||||
static {
|
||||
filter.add(GomaFadaVanguardPredicate.instance);
|
||||
}
|
||||
|
||||
public GomaFadaVanguard(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{1}{R}");
|
||||
|
||||
this.subtype.add(SubType.HUMAN);
|
||||
this.subtype.add(SubType.WARRIOR);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// Whenever Goma Fada Vanguard attacks, target creature an opponent controls with power less than or equal to the number of Warriors you control can't block this turn.
|
||||
Ability ability = new AttacksTriggeredAbility(new CantBlockTargetEffect(Duration.EndOfTurn), false);
|
||||
ability.addTarget(new TargetPermanent(filter));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
private GomaFadaVanguard(final GomaFadaVanguard card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public GomaFadaVanguard copy() {
|
||||
return new GomaFadaVanguard(this);
|
||||
}
|
||||
}
|
||||
|
||||
enum GomaFadaVanguardPredicate implements ObjectSourcePlayerPredicate<ObjectSourcePlayer<MageObject>> {
|
||||
instance;
|
||||
private static final FilterPermanent filter = new FilterPermanent(SubType.WARRIOR, "");
|
||||
|
||||
@Override
|
||||
public boolean apply(ObjectSourcePlayer<MageObject> input, Game game) {
|
||||
return input.getObject().getPower().getValue() <=
|
||||
game.getBattlefield().countAll(filter, game.getControllerId(input.getSourceId()), game);
|
||||
}
|
||||
}
|
|
@ -103,6 +103,7 @@ public final class ZendikarRising extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Fissure Wizard", 140, Rarity.COMMON, mage.cards.f.FissureWizard.class));
|
||||
cards.add(new SetCardInfo("Forest", 278, Rarity.LAND, mage.cards.basiclands.Forest.class, FULL_ART_BFZ_VARIOUS));
|
||||
cards.add(new SetCardInfo("Gnarlid Colony", 185, Rarity.COMMON, mage.cards.g.GnarlidColony.class));
|
||||
cards.add(new SetCardInfo("Goma Fada Vanguard", 141, Rarity.UNCOMMON, mage.cards.g.GomaFadaVanguard.class));
|
||||
cards.add(new SetCardInfo("Grimclimb Pathway", 259, Rarity.RARE, mage.cards.g.GrimclimbPathway.class));
|
||||
cards.add(new SetCardInfo("Grotag Bug-Catcher", 142, Rarity.COMMON, mage.cards.g.GrotagBugCatcher.class));
|
||||
cards.add(new SetCardInfo("Highborn Vampire", 108, Rarity.COMMON, mage.cards.h.HighbornVampire.class));
|
||||
|
|
Loading…
Reference in a new issue