mirror of
https://github.com/correl/mage.git
synced 2025-04-14 09:09:38 -09:00
[VOW] Implemented Cloaked Cadet
This commit is contained in:
parent
af5a0d12d5
commit
a92100eb1a
2 changed files with 84 additions and 0 deletions
Mage.Sets/src/mage
83
Mage.Sets/src/mage/cards/c/CloakedCadet.java
Normal file
83
Mage.Sets/src/mage/cards/c/CloakedCadet.java
Normal file
|
@ -0,0 +1,83 @@
|
|||
package mage.cards.c;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.TriggeredAbilityImpl;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.abilities.keyword.TrainingAbility;
|
||||
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 mage.game.permanent.Permanent;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class CloakedCadet extends CardImpl {
|
||||
|
||||
public CloakedCadet(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{G}");
|
||||
|
||||
this.subtype.add(SubType.HUMAN);
|
||||
this.subtype.add(SubType.RANGER);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(4);
|
||||
|
||||
// Training
|
||||
this.addAbility(new TrainingAbility());
|
||||
|
||||
// Whenever one or more +1/+1 counters are put on one or more Humans you control, draw a card. This ability triggers only once each turn.
|
||||
this.addAbility(new CloakedCadetTriggeredAbility());
|
||||
}
|
||||
|
||||
private CloakedCadet(final CloakedCadet card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CloakedCadet copy() {
|
||||
return new CloakedCadet(this);
|
||||
}
|
||||
}
|
||||
|
||||
class CloakedCadetTriggeredAbility extends TriggeredAbilityImpl {
|
||||
|
||||
CloakedCadetTriggeredAbility() {
|
||||
super(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1));
|
||||
this.setTriggersOnce(true);
|
||||
}
|
||||
|
||||
private CloakedCadetTriggeredAbility(final CloakedCadetTriggeredAbility ability) {
|
||||
super(ability);
|
||||
}
|
||||
|
||||
@Override
|
||||
public CloakedCadetTriggeredAbility copy() {
|
||||
return new CloakedCadetTriggeredAbility(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkEventType(GameEvent event, Game game) {
|
||||
return event.getType() == GameEvent.EventType.COUNTER_ADDED;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean checkTrigger(GameEvent event, Game game) {
|
||||
Permanent permanent = game.getPermanent(event.getTargetId());
|
||||
return permanent != null
|
||||
&& isControlledBy(permanent.getControllerId())
|
||||
&& permanent.hasSubtype(SubType.HUMAN, game)
|
||||
&& event.getData().equals(CounterType.P1P1.getName());
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getTriggerPhrase() {
|
||||
return "Whenever one or more +1/+1 counters are put on one or more Humans you control, ";
|
||||
}
|
||||
}
|
|
@ -38,6 +38,7 @@ public final class InnistradCrimsonVow extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Archghoul of Thraben", 93, Rarity.UNCOMMON, mage.cards.a.ArchghoulOfThraben.class));
|
||||
cards.add(new SetCardInfo("By Invitation Only", 5, Rarity.RARE, mage.cards.b.ByInvitationOnly.class));
|
||||
cards.add(new SetCardInfo("Change of Fortune", 150, Rarity.RARE, mage.cards.c.ChangeOfFortune.class));
|
||||
cards.add(new SetCardInfo("Cloaked Cadet", 192, Rarity.UNCOMMON, mage.cards.c.CloakedCadet.class));
|
||||
cards.add(new SetCardInfo("Dawnhart Geist", 8, Rarity.UNCOMMON, mage.cards.d.DawnhartGeist.class));
|
||||
cards.add(new SetCardInfo("Deathcap Glade", 261, Rarity.RARE, mage.cards.d.DeathcapGlade.class));
|
||||
cards.add(new SetCardInfo("Demonic Bargain", 103, Rarity.RARE, mage.cards.d.DemonicBargain.class));
|
||||
|
|
Loading…
Add table
Reference in a new issue