mirror of
https://github.com/correl/mage.git
synced 2024-12-26 19:16:54 +00:00
[40K] Implemented Nurgle's Conscription
This commit is contained in:
parent
0b9f4000d6
commit
8ceb14c2a4
2 changed files with 72 additions and 0 deletions
71
Mage.Sets/src/mage/cards/n/NurglesConscription.java
Normal file
71
Mage.Sets/src/mage/cards/n/NurglesConscription.java
Normal file
|
@ -0,0 +1,71 @@
|
|||
package mage.cards.n;
|
||||
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.effects.OneShotEffect;
|
||||
import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.Outcome;
|
||||
import mage.constants.TargetController;
|
||||
import mage.constants.Zone;
|
||||
import mage.filter.FilterCard;
|
||||
import mage.filter.common.FilterCreatureCard;
|
||||
import mage.game.Game;
|
||||
import mage.players.Player;
|
||||
import mage.target.common.TargetCardInGraveyard;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class NurglesConscription extends CardImpl {
|
||||
|
||||
private static final FilterCard filter = new FilterCreatureCard("creature card from an opponent's graveyard");
|
||||
|
||||
static {
|
||||
filter.add(TargetController.OPPONENT.getOwnerPredicate());
|
||||
}
|
||||
|
||||
public NurglesConscription(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.INSTANT}, "{4}{B}");
|
||||
|
||||
// Put target creature card from an opponent's graveyard onto the battlefield tapped under your control, then exile that player's graveyard.
|
||||
this.getSpellAbility().addEffect(new ReturnFromGraveyardToBattlefieldTargetEffect());
|
||||
this.getSpellAbility().addEffect(new NurglesConscriptionEffect());
|
||||
this.getSpellAbility().addTarget(new TargetCardInGraveyard(filter));
|
||||
}
|
||||
|
||||
private NurglesConscription(final NurglesConscription card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NurglesConscription copy() {
|
||||
return new NurglesConscription(this);
|
||||
}
|
||||
}
|
||||
|
||||
class NurglesConscriptionEffect extends OneShotEffect {
|
||||
|
||||
NurglesConscriptionEffect() {
|
||||
super(Outcome.Benefit);
|
||||
staticText = ", then exile that player's graveyard";
|
||||
}
|
||||
|
||||
private NurglesConscriptionEffect(final NurglesConscriptionEffect effect) {
|
||||
super(effect);
|
||||
}
|
||||
|
||||
@Override
|
||||
public NurglesConscriptionEffect copy() {
|
||||
return new NurglesConscriptionEffect(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean apply(Game game, Ability source) {
|
||||
Player player = game.getPlayer(game.getOwnerId(getTargetPointer().getFirst(game, source)));
|
||||
return player != null && player.moveCards(player.getGraveyard(), Zone.EXILED, source, game);
|
||||
}
|
||||
}
|
|
@ -177,6 +177,7 @@ public final class Warhammer40000 extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("New Horizons", 218, Rarity.COMMON, mage.cards.n.NewHorizons.class));
|
||||
cards.add(new SetCardInfo("Night Scythe", 162, Rarity.UNCOMMON, mage.cards.n.NightScythe.class));
|
||||
cards.add(new SetCardInfo("Noise Marine", 82, Rarity.UNCOMMON, mage.cards.n.NoiseMarine.class));
|
||||
cards.add(new SetCardInfo("Nurgle's Conscription", 44, Rarity.RARE, mage.cards.n.NurglesConscription.class));
|
||||
cards.add(new SetCardInfo("Nurgle's Rot", 45, Rarity.UNCOMMON, mage.cards.n.NurglesRot.class));
|
||||
cards.add(new SetCardInfo("Old One Eye", 96, Rarity.RARE, mage.cards.o.OldOneEye.class));
|
||||
cards.add(new SetCardInfo("Opal Palace", 286, Rarity.COMMON, mage.cards.o.OpalPalace.class));
|
||||
|
|
Loading…
Reference in a new issue