mirror of
https://github.com/correl/mage.git
synced 2024-12-25 11:11:16 +00:00
[BRO] Implement Su-Chi Cave Guard
This commit is contained in:
parent
edda235273
commit
62cc780601
2 changed files with 79 additions and 0 deletions
78
Mage.Sets/src/mage/cards/s/SuChiCaveGuard.java
Normal file
78
Mage.Sets/src/mage/cards/s/SuChiCaveGuard.java
Normal file
|
@ -0,0 +1,78 @@
|
|||
package mage.cards.s;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.Mana;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.DiesSourceTriggeredAbility;
|
||||
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.keyword.VigilanceAbility;
|
||||
import mage.abilities.keyword.WardAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.SubType;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class SuChiCaveGuard extends CardImpl {
|
||||
|
||||
public SuChiCaveGuard(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{8}");
|
||||
|
||||
this.subtype.add(SubType.CONSTRUCT);
|
||||
this.power = new MageInt(8);
|
||||
this.toughness = new MageInt(8);
|
||||
|
||||
// Vigilance
|
||||
this.addAbility(VigilanceAbility.getInstance());
|
||||
|
||||
// Ward {4}
|
||||
this.addAbility(new WardAbility(new ManaCostsImpl<>("{4}")));
|
||||
|
||||
// When Su-Chi Cave Guard dies, add eight {C}. Until end of turn, you don't lose this mana as steps and phases end.
|
||||
this.addAbility(new DiesSourceTriggeredAbility(new SuChiCaveGuardEffect()));
|
||||
}
|
||||
|
||||
private SuChiCaveGuard(final SuChiCaveGuard card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SuChiCaveGuard copy() {
|
||||
return new SuChiCaveGuard(this);
|
||||
}
|
||||
}
|
||||
|
||||
class SuChiCaveGuardEffect extends OneShotEffect {
|
||||
|
||||
SuChiCaveGuardEffect() {
|
||||
super(Outcome.Benefit);
|
||||
staticText = "add eight {C}. Until end of turn, you don't lose this mana as steps and phases end";
|
||||
}
|
||||
|
||||
private SuChiCaveGuardEffect(final SuChiCaveGuardEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public SuChiCaveGuardEffect copy() {
|
||||
return new SuChiCaveGuardEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(source.getControllerId());
|
||||
if (player != null) {
|
||||
player.getManaPool().addMana(Mana.ColorlessMana(8), game, source, true);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
}
|
|
@ -96,6 +96,7 @@ public final class TheBrothersWar extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Skitterbeam Battalion", 165, Rarity.MYTHIC, mage.cards.s.SkitterbeamBattalion.class));
|
||||
cards.add(new SetCardInfo("Splitting the Powerstone", 63, Rarity.UNCOMMON, mage.cards.s.SplittingThePowerstone.class));
|
||||
cards.add(new SetCardInfo("Stern Lesson", 64, Rarity.COMMON, mage.cards.s.SternLesson.class));
|
||||
cards.add(new SetCardInfo("Su-Chi Cave Guard", 249, Rarity.UNCOMMON, mage.cards.s.SuChiCaveGuard.class));
|
||||
cards.add(new SetCardInfo("Surge Engine", 81, Rarity.MYTHIC, mage.cards.s.SurgeEngine.class));
|
||||
cards.add(new SetCardInfo("Survivor of Korlis", 28, Rarity.COMMON, mage.cards.s.SurvivorOfKorlis.class));
|
||||
cards.add(new SetCardInfo("Swamp", 282, Rarity.LAND, mage.cards.basiclands.Swamp.class, FULL_ART_BFZ_VARIOUS));
|
||||
|
|
Loading…
Reference in a new issue