mirror of
https://github.com/correl/mage.git
synced 2024-12-26 11:09:27 +00:00
added Scrabbling Claws to RNA set file
This commit is contained in:
parent
0677ad0212
commit
fd043fa913
2 changed files with 30 additions and 22 deletions
|
@ -1,7 +1,6 @@
|
||||||
|
|
||||||
package mage.cards.s;
|
package mage.cards.s;
|
||||||
|
|
||||||
import java.util.UUID;
|
|
||||||
import mage.abilities.Ability;
|
import mage.abilities.Ability;
|
||||||
import mage.abilities.common.SimpleActivatedAbility;
|
import mage.abilities.common.SimpleActivatedAbility;
|
||||||
import mage.abilities.costs.common.SacrificeSourceCost;
|
import mage.abilities.costs.common.SacrificeSourceCost;
|
||||||
|
@ -23,8 +22,9 @@ import mage.players.Player;
|
||||||
import mage.target.TargetPlayer;
|
import mage.target.TargetPlayer;
|
||||||
import mage.target.common.TargetCardInGraveyard;
|
import mage.target.common.TargetCardInGraveyard;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
|
||||||
* @author fireshoes
|
* @author fireshoes
|
||||||
*/
|
*/
|
||||||
public final class ScrabblingClaws extends CardImpl {
|
public final class ScrabblingClaws extends CardImpl {
|
||||||
|
@ -33,18 +33,27 @@ public final class ScrabblingClaws extends CardImpl {
|
||||||
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}");
|
super(ownerId, setInfo, new CardType[]{CardType.ARTIFACT}, "{1}");
|
||||||
|
|
||||||
// {tap}: Target player exiles a card from their graveyard.
|
// {tap}: Target player exiles a card from their graveyard.
|
||||||
Ability firstAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ScrabblingClawsEffect(), new TapSourceCost());
|
Ability ability = new SimpleActivatedAbility(
|
||||||
firstAbility.addTarget(new TargetPlayer());
|
Zone.BATTLEFIELD,
|
||||||
this.addAbility(firstAbility);
|
new ScrabblingClawsEffect(), new
|
||||||
|
TapSourceCost()
|
||||||
|
);
|
||||||
|
ability.addTarget(new TargetPlayer());
|
||||||
|
this.addAbility(ability);
|
||||||
|
|
||||||
// {1}, Sacrifice Scrabbling Claws: Exile target card from a graveyard. Draw a card.
|
// {1}, Sacrifice Scrabbling Claws: Exile target card from a graveyard. Draw a card.
|
||||||
SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new SacrificeSourceCost());
|
ability = new SimpleActivatedAbility(
|
||||||
ability.addCost(new GenericManaCost(1));
|
Zone.BATTLEFIELD,
|
||||||
|
new ExileTargetEffect(),
|
||||||
|
new GenericManaCost(1)
|
||||||
|
);
|
||||||
|
ability.addCost(new SacrificeSourceCost());
|
||||||
ability.addTarget(new TargetCardInGraveyard());
|
ability.addTarget(new TargetCardInGraveyard());
|
||||||
ability.addEffect(new DrawCardSourceControllerEffect(1));
|
ability.addEffect(new DrawCardSourceControllerEffect(1));
|
||||||
this.addAbility(ability);
|
this.addAbility(ability);
|
||||||
}
|
}
|
||||||
|
|
||||||
public ScrabblingClaws(final ScrabblingClaws card) {
|
private ScrabblingClaws(final ScrabblingClaws card) {
|
||||||
super(card);
|
super(card);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -56,12 +65,12 @@ public final class ScrabblingClaws extends CardImpl {
|
||||||
|
|
||||||
class ScrabblingClawsEffect extends OneShotEffect {
|
class ScrabblingClawsEffect extends OneShotEffect {
|
||||||
|
|
||||||
public ScrabblingClawsEffect() {
|
ScrabblingClawsEffect() {
|
||||||
super(Outcome.Exile);
|
super(Outcome.Exile);
|
||||||
this.staticText = "Target player exiles a card from their graveyard";
|
this.staticText = "Target player exiles a card from their graveyard";
|
||||||
}
|
}
|
||||||
|
|
||||||
public ScrabblingClawsEffect(final ScrabblingClawsEffect effect) {
|
private ScrabblingClawsEffect(final ScrabblingClawsEffect effect) {
|
||||||
super(effect);
|
super(effect);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -73,18 +82,16 @@ class ScrabblingClawsEffect extends OneShotEffect {
|
||||||
@Override
|
@Override
|
||||||
public boolean apply(Game game, Ability source) {
|
public boolean apply(Game game, Ability source) {
|
||||||
Player targetPlayer = game.getPlayer(source.getFirstTarget());
|
Player targetPlayer = game.getPlayer(source.getFirstTarget());
|
||||||
if (targetPlayer != null) {
|
if (targetPlayer == null) {
|
||||||
FilterCard filter = new FilterCard("card from your graveyard");
|
return false;
|
||||||
filter.add(new OwnerIdPredicate(targetPlayer.getId()));
|
|
||||||
TargetCardInGraveyard target = new TargetCardInGraveyard(filter);
|
|
||||||
if (targetPlayer.chooseTarget(Outcome.Exile, target, source, game)) {
|
|
||||||
Card card = game.getCard(target.getFirstTarget());
|
|
||||||
if (card != null) {
|
|
||||||
targetPlayer.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.GRAVEYARD, true);
|
|
||||||
}
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return false;
|
FilterCard filter = new FilterCard("card from your graveyard");
|
||||||
|
filter.add(new OwnerIdPredicate(targetPlayer.getId()));
|
||||||
|
TargetCardInGraveyard target = new TargetCardInGraveyard(filter);
|
||||||
|
if (!targetPlayer.chooseTarget(Outcome.Exile, target, source, game)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
Card card = game.getCard(target.getFirstTarget());
|
||||||
|
return card != null && targetPlayer.moveCards(card, Zone.EXILED, source, game);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -128,6 +128,7 @@ public final class RavnicaAllegiance extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Rix Maadi Reveler", 109, Rarity.RARE, mage.cards.r.RixMaadiReveler.class));
|
cards.add(new SetCardInfo("Rix Maadi Reveler", 109, Rarity.RARE, mage.cards.r.RixMaadiReveler.class));
|
||||||
cards.add(new SetCardInfo("Sauroform Hybrid", 140, Rarity.COMMON, mage.cards.s.SauroformHybrid.class));
|
cards.add(new SetCardInfo("Sauroform Hybrid", 140, Rarity.COMMON, mage.cards.s.SauroformHybrid.class));
|
||||||
cards.add(new SetCardInfo("Savage Smash", 203, Rarity.COMMON, mage.cards.s.SavageSmash.class));
|
cards.add(new SetCardInfo("Savage Smash", 203, Rarity.COMMON, mage.cards.s.SavageSmash.class));
|
||||||
|
cards.add(new SetCardInfo("Scrabbling Claws", 238, Rarity.UNCOMMON, mage.cards.s.ScrabblingClaws.class));
|
||||||
cards.add(new SetCardInfo("Senate Guildmage", 204, Rarity.UNCOMMON, mage.cards.s.SenateGuildmage.class));
|
cards.add(new SetCardInfo("Senate Guildmage", 204, Rarity.UNCOMMON, mage.cards.s.SenateGuildmage.class));
|
||||||
cards.add(new SetCardInfo("Seraph of the Scales", 205, Rarity.MYTHIC, mage.cards.s.SeraphOfTheScales.class));
|
cards.add(new SetCardInfo("Seraph of the Scales", 205, Rarity.MYTHIC, mage.cards.s.SeraphOfTheScales.class));
|
||||||
cards.add(new SetCardInfo("Sharktocrab", 206, Rarity.UNCOMMON, mage.cards.s.Sharktocrab.class));
|
cards.add(new SetCardInfo("Sharktocrab", 206, Rarity.UNCOMMON, mage.cards.s.Sharktocrab.class));
|
||||||
|
|
Loading…
Reference in a new issue