forked from External/mage
[FDN] Implement Exemplar of Light
This commit is contained in:
parent
9629551f43
commit
85f3c4ec83
2 changed files with 84 additions and 0 deletions
83
Mage.Sets/src/mage/cards/e/ExemplarOfLight.java
Normal file
83
Mage.Sets/src/mage/cards/e/ExemplarOfLight.java
Normal file
|
|
@ -0,0 +1,83 @@
|
|||
package mage.cards.e;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.common.GainLifeControllerTriggeredAbility;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.constants.Zone;
|
||||
import mage.counters.CounterType;
|
||||
import mage.game.Game;
|
||||
import mage.game.events.GameEvent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class ExemplarOfLight extends CardImpl {
|
||||
|
||||
public ExemplarOfLight(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{W}{W}");
|
||||
|
||||
this.subtype.add(SubType.ANGEL);
|
||||
this.power = new MageInt(3);
|
||||
this.toughness = new MageInt(3);
|
||||
|
||||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
|
||||
// Whenever you gain life, put a +1/+1 counter on this creature.
|
||||
this.addAbility(new GainLifeControllerTriggeredAbility(
|
||||
new AddCountersSourceEffect(CounterType.P1P1.createInstance())
|
||||
));
|
||||
|
||||
// Whenever you put one or more +1/+1 counters on this creature, draw a card. This ability triggers only once each turn.
|
||||
this.addAbility(new ExemplarOfLightTriggeredAbility());
|
||||
}
|
||||
|
||||
private ExemplarOfLight(final ExemplarOfLight card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ExemplarOfLight copy() {
|
||||
return new ExemplarOfLight(this);
|
||||
}
|
||||
}
|
||||
|
||||
class ExemplarOfLightTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
ExemplarOfLightTriggeredAbility() {
|
||||
super(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1));
|
||||
this.setTriggerPhrase("Whenever you put one or more +1/+1 counters on this creature, ");
|
||||
this.setTriggersLimitEachTurn(1);
|
||||
}
|
||||
|
||||
private ExemplarOfLightTriggeredAbility(final ExemplarOfLightTriggeredAbility ability) {
|
||||
super(ability);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ExemplarOfLightTriggeredAbility copy() {
|
||||
return new ExemplarOfLightTriggeredAbility(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkEventType(GameEvent event, Game game) {
|
||||
return event.getType() == GameEvent.EventType.COUNTERS_ADDED;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
return event.getData().equals(CounterType.P1P1.getName())
|
||||
&& isControlledBy(event.getPlayerId())
|
||||
&& event.getTargetId().equals(getSourceId());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -107,6 +107,7 @@ public final class Foundations extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Erudite Wizard", 37, Rarity.COMMON, mage.cards.e.EruditeWizard.class));
|
||||
cards.add(new SetCardInfo("Essence Scatter", 153, Rarity.UNCOMMON, mage.cards.e.EssenceScatter.class));
|
||||
cards.add(new SetCardInfo("Etali, Primal Storm", 194, Rarity.RARE, mage.cards.e.EtaliPrimalStorm.class));
|
||||
cards.add(new SetCardInfo("Exemplar of Light", 11, Rarity.RARE, mage.cards.e.ExemplarOfLight.class));
|
||||
cards.add(new SetCardInfo("Expedition Map", 724, Rarity.COMMON, mage.cards.e.ExpeditionMap.class));
|
||||
cards.add(new SetCardInfo("Exsanguinate", 173, Rarity.UNCOMMON, mage.cards.e.Exsanguinate.class));
|
||||
cards.add(new SetCardInfo("Extravagant Replication", 154, Rarity.RARE, mage.cards.e.ExtravagantReplication.class));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue