From c8052bd65ab4a6269f8dd599d2da9f9c9a99ff40 Mon Sep 17 00:00:00 2001 From: jendave Date: Sat, 6 Aug 2011 14:08:27 +0000 Subject: [PATCH] add Beacon of Tomorrows (from Fifth Dawn) --- .gitattributes | 1 + res/cardsfolder/beacon_of_tomorrows.txt | 7 +++++++ src/forge/CardFactory_Sorceries.java | 26 +++++++++++++++++++++++++ 3 files changed, 34 insertions(+) create mode 100644 res/cardsfolder/beacon_of_tomorrows.txt diff --git a/.gitattributes b/.gitattributes index 6cb6b497fe5..052a6aa8a32 100644 --- a/.gitattributes +++ b/.gitattributes @@ -442,6 +442,7 @@ res/cardsfolder/bazaar_of_baghdad.txt -text svneol=native#text/plain res/cardsfolder/bazaar_of_wonders.txt -text svneol=native#text/plain res/cardsfolder/beacon_of_creation.txt -text svneol=native#text/plain res/cardsfolder/beacon_of_destruction.txt -text svneol=native#text/plain +res/cardsfolder/beacon_of_tomorrows.txt -text svneol=native#text/plain res/cardsfolder/beacon_of_unrest.txt -text svneol=native#text/plain res/cardsfolder/bear_cub.txt -text svneol=native#text/plain res/cardsfolder/beast_attack.txt -text svneol=native#text/plain diff --git a/res/cardsfolder/beacon_of_tomorrows.txt b/res/cardsfolder/beacon_of_tomorrows.txt new file mode 100644 index 00000000000..6e35b1ebc82 --- /dev/null +++ b/res/cardsfolder/beacon_of_tomorrows.txt @@ -0,0 +1,7 @@ +Name:Beacon of Tomorrows +ManaCost:6 U U +Types:Sorcery +Text:Target player takes an extra turn after this one. Shuffle CARDNAME into its owner's library. +SVar:Rarity:Rare +SVar:Picture:http://www.wizards.com/global/images/magic/general/beacon_of_tomorrows.jpg +End \ No newline at end of file diff --git a/src/forge/CardFactory_Sorceries.java b/src/forge/CardFactory_Sorceries.java index 5564c3c7e88..af96f7a107e 100644 --- a/src/forge/CardFactory_Sorceries.java +++ b/src/forge/CardFactory_Sorceries.java @@ -7279,6 +7279,32 @@ public class CardFactory_Sorceries { card.addSpellAbility(spell); }//*************** END ************ END ************************** + + //*************** START *********** START ************************** + else if(cardName.equals("Beacon of Tomorrows")) { + final SpellAbility spell = new Spell(card) { + private static final long serialVersionUID = 6705046075033727413L; + + @Override + public void resolve() { + Player p = getTargetPlayer(); + AllZone.Phase.addExtraTurn(p); + done(); + }//resolve() + + void done() { + //shuffle card back into the library + AllZone.GameAction.moveToLibrary(card); + card.getController().shuffle(); + } + }; + spell.setChooseTargetAI(CardFactoryUtil.AI_targetComputer()); + spell.setBeforePayMana(CardFactoryUtil.input_targetPlayer(spell)); + + card.clearSpellAbility(); + card.addSpellAbility(spell); + }//*************** END ************ END ************************** + return card; }//getCard }