From b8a73f8ac669fc69aa8cb02956747bd2c5cad560 Mon Sep 17 00:00:00 2001 From: Sloth Date: Mon, 7 Nov 2011 17:33:03 +0000 Subject: [PATCH] - Added an optional "Sacrifice" parameter to AF Destroy. - Added Shape Anew. --- .gitattributes | 1 + res/cardsfolder/d/deftblade_elite.txt | 2 ++ res/cardsfolder/o/ovinomancer.txt | 5 ++++- res/cardsfolder/s/shape_anew.txt | 11 +++++++++++ res/cardsfolder/s/snapping_thragg.txt | 2 ++ res/cardsfolder/s/standardize.txt | 2 ++ res/cardsfolder/t/trickery_charm.txt | 2 ++ .../abilityfactory/AbilityFactoryDestroy.java | 18 ++++++++++++++---- 8 files changed, 38 insertions(+), 5 deletions(-) create mode 100644 res/cardsfolder/s/shape_anew.txt diff --git a/.gitattributes b/.gitattributes index fe7344776bb..40db25b241c 100644 --- a/.gitattributes +++ b/.gitattributes @@ -7214,6 +7214,7 @@ res/cardsfolder/s/shambling_remains.txt svneol=native#text/plain res/cardsfolder/s/shambling_shell.txt svneol=native#text/plain res/cardsfolder/s/shambling_strider.txt svneol=native#text/plain res/cardsfolder/s/shanodin_dryads.txt svneol=native#text/plain +res/cardsfolder/s/shape_anew.txt -text res/cardsfolder/s/shaper_guildmage.txt svneol=native#text/plain res/cardsfolder/s/shapeshifter.txt svneol=native#text/plain res/cardsfolder/s/shard_convergence.txt svneol=native#text/plain diff --git a/res/cardsfolder/d/deftblade_elite.txt b/res/cardsfolder/d/deftblade_elite.txt index 8847d64b60d..3eefdf66fff 100644 --- a/res/cardsfolder/d/deftblade_elite.txt +++ b/res/cardsfolder/d/deftblade_elite.txt @@ -8,4 +8,6 @@ A:AB$ Pump | Cost$ 1 W | KW$ HIDDEN Prevent all damage that would be dealt to CA SVar:RemAIDeck:True SVar:Rarity:Common SVar:Picture:http://www.wizards.com/global/images/magic/general/deftblade_elite.jpg +SetInfo:LGN|Common|http://magiccards.info/scans/en/le/12.jpg +Oracle:Provoke (When this attacks, you may have target creature defending player controls untap and block it if able.)\n{1}{W}: Prevent all combat damage that would be dealt to and dealt by Deftblade Elite this turn. End \ No newline at end of file diff --git a/res/cardsfolder/o/ovinomancer.txt b/res/cardsfolder/o/ovinomancer.txt index 83347c6e737..564cadd59fb 100644 --- a/res/cardsfolder/o/ovinomancer.txt +++ b/res/cardsfolder/o/ovinomancer.txt @@ -10,4 +10,7 @@ SVar:DBCleanUp:DB$Cleanup | ClearRemembered$ True A:AB$ Destroy | Cost$ Return<1/CARDNAME> T | ValidTgts$ Creature | TgtPrompt$ Select target creature | NoRegen$ True | SubAbility$ DBToken | SpellDescription$ Destroy target creature. It can't be regenerated. SVar:DBToken:DB$Token | TokenAmount$ 1 | TokenName$ Sheep | TokenTypes$ Creature,Sheep | TokenOwner$ TargetedController | TokenColors$ Green | TokenPower$ 0 | TokenToughness$ 1 | SpellDescription$ That creature's controller puts a 0/1 green Sheep creature token onto the battlefield. SVar:Rarity:Uncommon -End +SetInfo:VIS|Uncommon|http://magiccards.info/scans/en/vi/39.jpg +SetInfo:TSB|Special|http://magiccards.info/scans/en/tsts/27.jpg +Oracle:When Ovinomancer enters the battlefield, sacrifice it unless you return three basic lands you control to their owner's hand.\n{T}, Return Ovinomancer to its owner's hand: Destroy target creature. It can't be regenerated. That creature's controller puts a 0/1 green Sheep creature token onto the battlefield. +End \ No newline at end of file diff --git a/res/cardsfolder/s/shape_anew.txt b/res/cardsfolder/s/shape_anew.txt new file mode 100644 index 00000000000..d9eb8bdc259 --- /dev/null +++ b/res/cardsfolder/s/shape_anew.txt @@ -0,0 +1,11 @@ +Name:Shape Anew +ManaCost:3 U +Types:Sorcery +Text:no text +A:SP$ Destroy | Cost$ 3 U | ValidTgts$ Artifact | TgtPrompt$ Select target artifact | Sacrifice$ True | SubAbility$ DBDig | SpellDescription$ The controller of target artifact sacrifices it, then reveals cards from the top of his or her library until he or she reveals an artifact card. That player puts that card onto the battlefield, then shuffles all other cards revealed this way into his or her library. +SVar:DBDig:DB$ DigUntil | Defined$ TargetedController | Valid$ Artifact | ValidDescription$ artifact | FoundDestination$ Battlefield | RevealedDestination$ Library | Shuffle$ True +SVar:Rarity:Rare +SVar:Picture:http://www.wizards.com/global/images/magic/general/shape_anew.jpg +SetInfo:SOM|Rare|http://magiccards.info/scans/en/som/43.jpg +Oracle:The controller of target artifact sacrifices it, then reveals cards from the top of his or her library until he or she reveals an artifact card. That player puts that card onto the battlefield, then shuffles all other cards revealed this way into his or her library. +End \ No newline at end of file diff --git a/res/cardsfolder/s/snapping_thragg.txt b/res/cardsfolder/s/snapping_thragg.txt index b4ad4c61a83..56131d13c02 100644 --- a/res/cardsfolder/s/snapping_thragg.txt +++ b/res/cardsfolder/s/snapping_thragg.txt @@ -8,4 +8,6 @@ T:Mode$ DamageDone | ValidCard$ Card.Self+faceUp | ValidTarget$ Opponent | Execu SVar:TrigDamage:AB$ DealDamage | Cost$ 0 | ValidTgts$ Creature.YouDontCtrl | TgtPrompt$ Select target creature opponent controls | NumDmg$ 3 SVar:Rarity:Uncommon SVar:Picture:http://www.wizards.com/global/images/magic/general/snapping_thragg.jpg +SetInfo:ONS|Uncommon|http://magiccards.info/scans/en/on/233.jpg +Oracle:Whenever Snapping Thragg deals combat damage to a player, you may have it deal 3 damage to target creature that player controls.\nMorph {4}{R}{R} (You may cast this face down as a 2/2 creature for {3}. Turn it face up any time for its morph cost.) End \ No newline at end of file diff --git a/res/cardsfolder/s/standardize.txt b/res/cardsfolder/s/standardize.txt index 1eefda65b2e..44ea3f46b46 100644 --- a/res/cardsfolder/s/standardize.txt +++ b/res/cardsfolder/s/standardize.txt @@ -7,4 +7,6 @@ SVar:DBAnimateAll:DB$ AnimateAll | ValidCards$ Creature | Types$ ChosenType | Ov SVar:RemAIDeck:True SVar:Rarity:Rare SVar:Picture:http://www.wizards.com/global/images/magic/general/standardize.jpg +SetInfo:ONS|Rare|http://magiccards.info/scans/en/on/116.jpg +Oracle:Choose a creature type other than Wall. Each creature becomes that type until end of turn. End \ No newline at end of file diff --git a/res/cardsfolder/t/trickery_charm.txt b/res/cardsfolder/t/trickery_charm.txt index bdfbbcdd4d4..f24fb51121e 100644 --- a/res/cardsfolder/t/trickery_charm.txt +++ b/res/cardsfolder/t/trickery_charm.txt @@ -10,4 +10,6 @@ SVar:DBRearrage:DB$ RearrangeTopOfLibrary | Defined$ You | NumCards$ 4 | SpellDe SVar:RemAIDeck:True SVar:Rarity:Common SVar:Picture:http://www.wizards.com/global/images/magic/general/trickery_charm.jpg +SetInfo:ONS|Common|http://magiccards.info/scans/en/on/119.jpg +Oracle:Choose one - Target creature gains flying until end of turn; or target creature becomes the creature type of your choice until end of turn; or look at the top four cards of your library, then put them back in any order. End \ No newline at end of file diff --git a/src/main/java/forge/card/abilityfactory/AbilityFactoryDestroy.java b/src/main/java/forge/card/abilityfactory/AbilityFactoryDestroy.java index cc23c997acd..d49021a77b0 100644 --- a/src/main/java/forge/card/abilityfactory/AbilityFactoryDestroy.java +++ b/src/main/java/forge/card/abilityfactory/AbilityFactoryDestroy.java @@ -414,8 +414,13 @@ public class AbilityFactoryDestroy { } else { sb.append(host).append(" - "); } - - sb.append("Destroy "); + + if(params.containsKey("Sacrifice")) { + sb.append("Sacrifice "); + } + else { + sb.append("Destroy "); + } final Iterator it = tgtCards.iterator(); while (it.hasNext()) { @@ -474,6 +479,7 @@ public class AbilityFactoryDestroy { final HashMap params = af.getMapParams(); final boolean noRegen = params.containsKey("NoRegen"); + final boolean sac = params.containsKey("Sacrifice"); final Card card = sa.getSourceCard(); ArrayList tgtCards; @@ -495,7 +501,9 @@ public class AbilityFactoryDestroy { for (final Card tgtC : tgtCards) { if (AllZoneUtil.isCardInPlay(tgtC) && ((tgt == null) || CardFactoryUtil.canTarget(card, tgtC))) { - if (noRegen) { + if (sac) { + AllZone.getGameAction().sacrifice(tgtC); + } else if (noRegen) { AllZone.getGameAction().destroyNoRegeneration(tgtC); } else { AllZone.getGameAction().destroy(tgtC); @@ -505,7 +513,9 @@ public class AbilityFactoryDestroy { for (final Card unTgtC : untargetedCards) { if (AllZoneUtil.isCardInPlay(unTgtC)) { - if (noRegen) { + if (sac) { + AllZone.getGameAction().sacrifice(unTgtC); + } else if (noRegen) { AllZone.getGameAction().destroyNoRegeneration(unTgtC); } else { AllZone.getGameAction().destroy(unTgtC);