mirror of
https://github.com/correl/mage.git
synced 2024-12-26 11:09:27 +00:00
[KHM] Implemented Tundra Fumarole
This commit is contained in:
parent
ede616d233
commit
80412ffd6e
2 changed files with 74 additions and 0 deletions
73
Mage.Sets/src/mage/cards/t/TundraFumarole.java
Normal file
73
Mage.Sets/src/mage/cards/t/TundraFumarole.java
Normal file
|
@ -0,0 +1,73 @@
|
|||
package mage.cards.t;
|
||||
|
||||
import mage.Mana;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.DamageTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.ManaType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SuperType;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.common.TargetCreatureOrPlaneswalker;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class TundraFumarole extends CardImpl {
|
||||
|
||||
public TundraFumarole(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{R}{R}");
|
||||
|
||||
this.addSuperType(SuperType.SNOW);
|
||||
|
||||
// Tundra Fumarole deals 4 damage to target creature or planeswalker. Add {C} for each {S} spent to cast this spell. Until end of turn, you don't lose this mana as steps and phases end.
|
||||
this.getSpellAbility().addEffect(new DamageTargetEffect(4));
|
||||
this.getSpellAbility().addEffect(new TundraFumaroleEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCreatureOrPlaneswalker());
|
||||
}
|
||||
|
||||
private TundraFumarole(final TundraFumarole card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TundraFumarole copy() {
|
||||
return new TundraFumarole(this);
|
||||
}
|
||||
}
|
||||
|
||||
class TundraFumaroleEffect extends OneShotEffect {
|
||||
|
||||
TundraFumaroleEffect() {
|
||||
super(Outcome.Benefit);
|
||||
staticText = "Add {C} for each {S} spent to cast this spell. " +
|
||||
"Until end of turn, you don't lose this mana as steps and phases end.";
|
||||
}
|
||||
|
||||
private TundraFumaroleEffect(final TundraFumaroleEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public TundraFumaroleEffect copy() {
|
||||
return new TundraFumaroleEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(source.getControllerId());
|
||||
if (player == null) {
|
||||
return false;
|
||||
}
|
||||
player.getManaPool().addMana(new Mana(
|
||||
ManaType.COLORLESS, source.getManaCostsToPay().getUsedManaToPay().getSnow()
|
||||
), game, source, true);
|
||||
return true;
|
||||
}
|
||||
}
|
|
@ -318,6 +318,7 @@ public final class Kaldheim extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Toralf, God of Fury", 154, Rarity.MYTHIC, mage.cards.t.ToralfGodOfFury.class));
|
||||
cards.add(new SetCardInfo("Tormentor's Helm", 155, Rarity.COMMON, mage.cards.t.TormentorsHelm.class));
|
||||
cards.add(new SetCardInfo("Toski, Bearer of Secrets", 197, Rarity.RARE, mage.cards.t.ToskiBearerOfSecrets.class));
|
||||
cards.add(new SetCardInfo("Tundra Fumarole", 156, Rarity.RARE, mage.cards.t.TundraFumarole.class));
|
||||
cards.add(new SetCardInfo("Tuskeri Firewalker", 157, Rarity.COMMON, mage.cards.t.TuskeriFirewalker.class));
|
||||
cards.add(new SetCardInfo("Tyrite Sanctum", 272, Rarity.RARE, mage.cards.t.TyriteSanctum.class));
|
||||
cards.add(new SetCardInfo("Tyvar Kell", 198, Rarity.MYTHIC, mage.cards.t.TyvarKell.class));
|
||||
|
|
Loading…
Reference in a new issue