Implemented Giant Killer

This commit is contained in:
Evan Kranzler 2019-09-09 18:23:35 -04:00
parent c870f32b31
commit f7ebf80627
3 changed files with 64 additions and 0 deletions

View file

@ -0,0 +1,62 @@
package mage.cards.g;
import mage.MageInt;
import mage.abilities.Ability;
import mage.abilities.common.SimpleActivatedAbility;
import mage.abilities.costs.common.TapSourceCost;
import mage.abilities.costs.mana.ManaCostsImpl;
import mage.abilities.effects.common.DestroyTargetEffect;
import mage.abilities.effects.common.TapTargetEffect;
import mage.cards.AdventureCard;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.ComparisonType;
import mage.constants.SubType;
import mage.filter.FilterPermanent;
import mage.filter.common.FilterCreaturePermanent;
import mage.filter.predicate.mageobject.PowerPredicate;
import mage.target.TargetPermanent;
import mage.target.common.TargetCreaturePermanent;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class GiantKiller extends AdventureCard {
private static final FilterPermanent filter = new FilterCreaturePermanent("creature with power 4 or greater");
static {
filter.add(new PowerPredicate(ComparisonType.MORE_THAN, 3));
}
public GiantKiller(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, new CardType[]{CardType.INSTANT}, "{W}", "Chop Down", "{2}{W}");
this.subtype.add(SubType.HUMAN);
this.subtype.add(SubType.PEASANT);
this.power = new MageInt(1);
this.toughness = new MageInt(2);
// {1}{W}, {T}: Tap target creature.
Ability ability = new SimpleActivatedAbility(new TapTargetEffect(), new ManaCostsImpl("{1}{W}"));
ability.addCost(new TapSourceCost());
ability.addTarget(new TargetCreaturePermanent());
this.addAbility(ability);
// Chop Down
// Destroy target creature with power 4 or greater.
this.getAdventureSpellAbility().addEffect(new DestroyTargetEffect());
this.getAdventureSpellAbility().addTarget(new TargetPermanent(filter));
}
private GiantKiller(final GiantKiller card) {
super(card);
}
@Override
public GiantKiller copy() {
return new GiantKiller(this);
}
}

View file

@ -60,6 +60,7 @@ public final class ThroneOfEldraine extends ExpansionSet {
cards.add(new SetCardInfo("Frogify", 47, Rarity.UNCOMMON, mage.cards.f.Frogify.class));
cards.add(new SetCardInfo("Garrison Griffin", 305, Rarity.COMMON, mage.cards.g.GarrisonGriffin.class));
cards.add(new SetCardInfo("Garruk, Cursed Huntsman", 191, Rarity.MYTHIC, mage.cards.g.GarrukCursedHuntsman.class));
cards.add(new SetCardInfo("Giant Killer", 14, Rarity.RARE, mage.cards.g.GiantKiller.class));
cards.add(new SetCardInfo("Gilded Goose", 160, Rarity.RARE, mage.cards.g.GildedGoose.class));
cards.add(new SetCardInfo("Gluttonous Troll", 327, Rarity.RARE, mage.cards.g.GluttonousTroll.class));
cards.add(new SetCardInfo("Golden Egg", 220, Rarity.COMMON, mage.cards.g.GoldenEgg.class));

View file

@ -258,6 +258,7 @@ public enum SubType {
OYSTER("Oyster", SubTypeSet.CreatureType),
// P
PANGOLIN("Pangolin", SubTypeSet.CreatureType),
PEASANT("Peasant", SubTypeSet.CreatureType),
PEGASUS("Pegasus", SubTypeSet.CreatureType),
PENTAVITE("Pentavite", SubTypeSet.CreatureType),
PEST("Pest", SubTypeSet.CreatureType),