mirror of
https://github.com/correl/mage.git
synced 2025-01-13 19:11:33 +00:00
[VOW] Implemented Manaform Hellkite
This commit is contained in:
parent
c664051e38
commit
b4f81efef8
3 changed files with 118 additions and 0 deletions
81
Mage.Sets/src/mage/cards/m/ManaformHellkite.java
Normal file
81
Mage.Sets/src/mage/cards/m/ManaformHellkite.java
Normal file
|
@ -0,0 +1,81 @@
|
|||
package mage.cards.m;
|
||||
|
||||
import java.util.UUID;
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.SpellCastControllerTriggeredAbility;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.CreateTokenEffect;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.filter.StaticFilters;
|
||||
import mage.game.Game;
|
||||
import mage.game.permanent.token.DragonIllusionToken;
|
||||
import mage.game.stack.Spell;
|
||||
import mage.watchers.common.ManaPaidSourceWatcher;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author weirddan455
|
||||
*/
|
||||
public final class ManaformHellkite extends CardImpl {
|
||||
|
||||
public ManaformHellkite(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{R}{R}");
|
||||
|
||||
this.subtype.add(SubType.DRAGON);
|
||||
this.power = new MageInt(4);
|
||||
this.toughness = new MageInt(4);
|
||||
|
||||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
|
||||
// Whenever you cast a noncreature spell, create an X/X red Dragon Illusion creature token with flying and haste, where X is the amount of mana spent to cast that spell.
|
||||
// Exile that token at the beginning of the next end step.
|
||||
this.addAbility(new SpellCastControllerTriggeredAbility(new ManaformHellkitEffect(), StaticFilters.FILTER_SPELL_A_NON_CREATURE, false, true));
|
||||
}
|
||||
|
||||
private ManaformHellkite(final ManaformHellkite card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ManaformHellkite copy() {
|
||||
return new ManaformHellkite(this);
|
||||
}
|
||||
}
|
||||
|
||||
class ManaformHellkitEffect extends OneShotEffect {
|
||||
|
||||
public ManaformHellkitEffect() {
|
||||
super(Outcome.PutCreatureInPlay);
|
||||
staticText = "create an X/X red Dragon Illusion creature token with flying and haste, where X is the amount of mana spent to cast that spell. "
|
||||
+ "Exile that token at the beginning of the next end step";
|
||||
}
|
||||
|
||||
private ManaformHellkitEffect(final ManaformHellkitEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public ManaformHellkitEffect copy() {
|
||||
return new ManaformHellkitEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Spell spell = (Spell) getValue("spellCast");
|
||||
if (spell != null) {
|
||||
CreateTokenEffect effect = new CreateTokenEffect(new DragonIllusionToken(ManaPaidSourceWatcher.getTotalPaid(spell.getId(), game)));
|
||||
if (effect.apply(game, source)) {
|
||||
effect.exileTokensCreatedAtNextEndStep(game, source);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
|
@ -94,6 +94,7 @@ public final class InnistradCrimsonVow extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Lantern Bearer", 66, Rarity.COMMON, mage.cards.l.LanternBearer.class));
|
||||
cards.add(new SetCardInfo("Lanterns' Lift", 66, Rarity.COMMON, mage.cards.l.LanternsLift.class));
|
||||
cards.add(new SetCardInfo("Lunar Rejection", 67, Rarity.UNCOMMON, mage.cards.l.LunarRejection.class));
|
||||
cards.add(new SetCardInfo("Manaform Hellkite", 170, Rarity.MYTHIC, mage.cards.m.ManaformHellkite.class));
|
||||
cards.add(new SetCardInfo("Markov Purifier", 241, Rarity.UNCOMMON, mage.cards.m.MarkovPurifier.class));
|
||||
cards.add(new SetCardInfo("Massive Might", 208, Rarity.COMMON, mage.cards.m.MassiveMight.class));
|
||||
cards.add(new SetCardInfo("Mindleech Ghoul", 122, Rarity.COMMON, mage.cards.m.MindleechGhoul.class));
|
||||
|
|
|
@ -0,0 +1,36 @@
|
|||
package mage.game.permanent.token;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.abilities.keyword.HasteAbility;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
|
||||
/**
|
||||
*
|
||||
* @author weirddan455
|
||||
*/
|
||||
public class DragonIllusionToken extends TokenImpl {
|
||||
|
||||
public DragonIllusionToken(int xValue) {
|
||||
super("Dragon Illusion", "X/X red Dragon Illusion creature token with flying and haste");
|
||||
cardType.add(CardType.CREATURE);
|
||||
color.setRed(true);
|
||||
subtype.add(SubType.DRAGON);
|
||||
subtype.add(SubType.ILLUSION);
|
||||
power = new MageInt(xValue);
|
||||
toughness = new MageInt(xValue);
|
||||
|
||||
addAbility(FlyingAbility.getInstance());
|
||||
addAbility(HasteAbility.getInstance());
|
||||
}
|
||||
|
||||
private DragonIllusionToken(final DragonIllusionToken token) {
|
||||
super(token);
|
||||
}
|
||||
|
||||
@Override
|
||||
public DragonIllusionToken copy() {
|
||||
return new DragonIllusionToken(this);
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue