mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
add Sanctum Gargoyle (from Shards of Alara)
This commit is contained in:
1
.gitattributes
vendored
1
.gitattributes
vendored
@@ -3367,6 +3367,7 @@ res/cardsfolder/salt_marsh.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/saltblast.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/salvage.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/samurai_enforcers.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/sanctum_gargoyle.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/sanctum_plowbeast.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/sandbar_merfolk.txt -text svneol=native#text/plain
|
||||
res/cardsfolder/sandbar_serpent.txt -text svneol=native#text/plain
|
||||
|
||||
9
res/cardsfolder/sanctum_gargoyle.txt
Normal file
9
res/cardsfolder/sanctum_gargoyle.txt
Normal file
@@ -0,0 +1,9 @@
|
||||
Name:Sanctum Gargoyle
|
||||
ManaCost:3 W
|
||||
Types:Artifact Creature Gargoyle
|
||||
Text:When Sanctum Gargoyle enters the battlefield, you may return target artifact card from your graveyard to your hand.
|
||||
PT:2/3
|
||||
K:Flying
|
||||
SVar:Rarity:Common
|
||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/sanctum_gargoyle.jpg
|
||||
End
|
||||
@@ -20307,6 +20307,56 @@ public class CardFactory_Creatures {
|
||||
//ability.setBeforePayMana(runtime);
|
||||
}//*************** END ************ END **************************
|
||||
|
||||
//*************** START *********** START ************************
|
||||
if(cardName.equals("Sanctum Gargoyle")) {
|
||||
final SpellAbility ability = new Ability(card, "0") {
|
||||
|
||||
@Override
|
||||
public void chooseTargetAI() {
|
||||
CardList grave = getGraveArts();
|
||||
Card target = CardFactoryUtil.AI_getBestArtifact(grave);
|
||||
setTargetCard(target);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void resolve() {
|
||||
if(card.getController().equals(Constant.Player.Human)) {
|
||||
Card c = AllZone.Display.getChoice("Select card", getGraveArts().toArray());
|
||||
setTargetCard(c);
|
||||
}
|
||||
|
||||
Card target = getTargetCard();
|
||||
|
||||
PlayerZone grave = AllZone.getZone(Constant.Zone.Graveyard, card.getController());
|
||||
if(AllZone.GameAction.isCardInZone(target, grave)
|
||||
&& CardFactoryUtil.canTarget(card, target))
|
||||
AllZone.GameAction.moveToHand(target);
|
||||
}//resolve()
|
||||
|
||||
CardList getGraveArts() {
|
||||
CardList list = AllZoneUtil.getPlayerGraveyard(card.getController());
|
||||
return list.filter(AllZoneUtil.artifacts);
|
||||
}
|
||||
};//SpellAbility
|
||||
|
||||
final Command cip = new Command() {
|
||||
private static final long serialVersionUID = -8905934905046258175L;
|
||||
|
||||
CardList getGraveArts() {
|
||||
CardList list = AllZoneUtil.getPlayerGraveyard(card.getController());
|
||||
return list.filter(AllZoneUtil.artifacts);
|
||||
}
|
||||
|
||||
public void execute() {
|
||||
if(getGraveArts().size() > 0)
|
||||
AllZone.Stack.add(ability);
|
||||
}
|
||||
};
|
||||
|
||||
ability.setStackDescription(cardName + " - return target artifact from your graveyard to your hand.");
|
||||
card.addComesIntoPlayCommand(cip);
|
||||
}//*************** END ************ END **************************
|
||||
|
||||
|
||||
// Cards with Cycling abilities
|
||||
// -1 means keyword "Cycling" not found
|
||||
|
||||
Reference in New Issue
Block a user