forked from External/mage
[LTC] Implement Gwaihir, Greatest of the Eagles
This commit is contained in:
parent
e8d833f0ba
commit
599473be12
3 changed files with 102 additions and 0 deletions
57
Mage.Sets/src/mage/cards/g/GwaihirGreatestOfTheEagles.java
Normal file
57
Mage.Sets/src/mage/cards/g/GwaihirGreatestOfTheEagles.java
Normal file
|
|
@ -0,0 +1,57 @@
|
|||
package mage.cards.g;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.AttacksTriggeredAbility;
|
||||
import mage.abilities.common.BeginningOfEndStepTriggeredAbility;
|
||||
import mage.abilities.condition.common.YouGainedLifeCondition;
|
||||
import mage.abilities.dynamicvalue.common.ControllerGotLifeCount;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.*;
|
||||
import mage.game.permanent.token.GwaihirBirdToken;
|
||||
import mage.target.common.TargetAttackingCreature;
|
||||
import mage.watchers.common.PlayerGainedLifeWatcher;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author PurpleCrowbar
|
||||
*/
|
||||
public final class GwaihirGreatestOfTheEagles extends CardImpl {
|
||||
|
||||
public GwaihirGreatestOfTheEagles(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{W}");
|
||||
this.supertype.add(SuperType.LEGENDARY);
|
||||
this.subtype.add(SubType.BIRD, SubType.NOBLE);
|
||||
this.power = new MageInt(5);
|
||||
this.toughness = new MageInt(5);
|
||||
|
||||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
|
||||
// Whenever Gwaihir attacks, target attacking creature gains flying until end of turn.
|
||||
Ability ability = new AttacksTriggeredAbility(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), false);
|
||||
ability.addTarget(new TargetAttackingCreature());
|
||||
this.addAbility(ability);
|
||||
|
||||
// At the beginning of each end step, if you gained 3 or more life this turn, create a 3/3 white Bird creature token
|
||||
// with flying and "Whenever this creature attacks, target attacking creature gains flying until end of turn."
|
||||
this.addAbility(new BeginningOfEndStepTriggeredAbility(
|
||||
Zone.BATTLEFIELD, new CreateTokenEffect(new GwaihirBirdToken()), TargetController.ANY,
|
||||
new YouGainedLifeCondition(ComparisonType.MORE_THAN, 2), false
|
||||
).addHint(ControllerGotLifeCount.getHint()), new PlayerGainedLifeWatcher());
|
||||
}
|
||||
|
||||
private GwaihirGreatestOfTheEagles(final GwaihirGreatestOfTheEagles card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public GwaihirGreatestOfTheEagles copy() {
|
||||
return new GwaihirGreatestOfTheEagles(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -125,6 +125,8 @@ public final class TalesOfMiddleEarthCommander extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Grey Host Reinforcements", 98, Rarity.RARE, mage.cards.g.GreyHostReinforcements.class, NON_FULL_USE_VARIOUS));
|
||||
cards.add(new SetCardInfo("Growth Spiral", 267, Rarity.COMMON, mage.cards.g.GrowthSpiral.class));
|
||||
cards.add(new SetCardInfo("Guttersnipe", 220, Rarity.UNCOMMON, mage.cards.g.Guttersnipe.class));
|
||||
cards.add(new SetCardInfo("Gwaihir, Greatest of the Eagles", 15, Rarity.RARE, mage.cards.g.GwaihirGreatestOfTheEagles.class, NON_FULL_USE_VARIOUS));
|
||||
cards.add(new SetCardInfo("Gwaihir, Greatest of the Eagles", 99, Rarity.RARE, mage.cards.g.GwaihirGreatestOfTheEagles.class, NON_FULL_USE_VARIOUS));
|
||||
cards.add(new SetCardInfo("Haldir, Lorien Lieutenant", 39, Rarity.RARE, mage.cards.h.HaldirLorienLieutenant.class));
|
||||
cards.add(new SetCardInfo("Harmonize", 248, Rarity.UNCOMMON, mage.cards.h.Harmonize.class));
|
||||
cards.add(new SetCardInfo("Harsh Mentor", 221, Rarity.RARE, mage.cards.h.HarshMentor.class));
|
||||
|
|
|
|||
|
|
@ -0,0 +1,43 @@
|
|||
package mage.game.permanent.token;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.AttacksTriggeredAbility;
|
||||
import mage.abilities.effects.common.continuous.GainAbilityTargetEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Duration;
|
||||
import mage.constants.SubType;
|
||||
import mage.target.common.TargetAttackingCreature;
|
||||
|
||||
/**
|
||||
* @author PurpleCrowbar
|
||||
*/
|
||||
public final class GwaihirBirdToken extends TokenImpl {
|
||||
|
||||
public GwaihirBirdToken() {
|
||||
super("Bird Token", "3/3 white Bird creature token with flying and \"Whenever this creature attacks, target attacking creature gains flying until end of turn.\"");
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setWhite(true);
|
||||
subtype.add(SubType.BIRD);
|
||||
power = new MageInt(3);
|
||||
toughness = new MageInt(3);
|
||||
|
||||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
|
||||
// Whenever this creature attacks, target attacking creature gains flying until end of turn.
|
||||
Ability ability = new AttacksTriggeredAbility(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), false);
|
||||
ability.addTarget(new TargetAttackingCreature());
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
private GwaihirBirdToken(final GwaihirBirdToken token) {
|
||||
super(token);
|
||||
}
|
||||
|
||||
@Override
|
||||
public GwaihirBirdToken copy() {
|
||||
return new GwaihirBirdToken(this);
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue