diff --git a/.gitattributes b/.gitattributes index 2443672758f..b726c6d32d5 100644 --- a/.gitattributes +++ b/.gitattributes @@ -9470,6 +9470,7 @@ res/cardsfolder/s/skyreach_manta.txt svneol=native#text/plain res/cardsfolder/s/skyrider_trainee.txt svneol=native#text/plain res/cardsfolder/s/skyscribing.txt svneol=native#text/plain res/cardsfolder/s/skyshaper.txt svneol=native#text/plain +res/cardsfolder/s/skyship_weatherlight.txt -text res/cardsfolder/s/skyshooter.txt svneol=native#text/plain res/cardsfolder/s/skyshroud_archer.txt svneol=native#text/plain res/cardsfolder/s/skyshroud_behemoth.txt svneol=native#text/plain @@ -9782,6 +9783,7 @@ res/cardsfolder/s/spellbook.txt svneol=native#text/plain res/cardsfolder/s/spellbound_dragon.txt -text svneol=unset#text/plain res/cardsfolder/s/spellbreaker_behemoth.txt svneol=native#text/plain res/cardsfolder/s/spellgorger_barbarian.txt svneol=native#text/plain +res/cardsfolder/s/spelljack.txt -text res/cardsfolder/s/spellshock.txt svneol=native#text/plain res/cardsfolder/s/spellstutter_sprite.txt svneol=native#text/plain res/cardsfolder/s/spelltithe_enforcer.txt -text diff --git a/res/cardsfolder/s/skyship_weatherlight.txt b/res/cardsfolder/s/skyship_weatherlight.txt new file mode 100644 index 00000000000..71978ac1048 --- /dev/null +++ b/res/cardsfolder/s/skyship_weatherlight.txt @@ -0,0 +1,16 @@ +Name:Skyship Weatherlight +ManaCost:4 +Types:Legendary Artifact +Text:no text +T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigSearch | TriggerDescription$ When CARDNAME enters the battlefield, search your library for any number of artifact and/or creature cards and exile them. Then shuffle your library. +SVar:TrigSearch:AB$ ChangeZone | Cost$ 0 | ChangeType$ Creature.YouOwn,Artifact.YouOwn | ChangeNum$ Z | Origin$ Library | Destination$ Exile | RememberChanged$ True | References$ X,Y,Z +A:AB$ ChooseCard | Cost$ 4 T | Defined$ You | Amount$ 1 | AtRandom$ True | Choices$ Card.IsRemembered | ChoiceZone$ Exile | SubAbility$ DBChange | SpellDescription$ Choose a card at random that was exiled with CARDNAME. Put that card into its owner's hand. +SVar:DBChange:DB$ ChangeZone | Defined$ ChosenCard | Origin$ Exile | Destination$ Hand | ForgetChanged$ True | Hidden$ True +SVar:X:Count$TypeInYourLibrary.Creature +SVar:Y:Count$TypeInYourLibrary.Artiifact +SVar:Z:SVar$X/Plus.Y +SVar:Rarity:Rare +SVar:Picture:http://www.wizards.com/global/images/magic/general/skyship_weatherlight.jpg +SetInfo:PLS|Rare|http://magiccards.info/scans/en/ps/133a.jpg +Oracle:When Skyship Weatherlight enters the battlefield, search your library for any number of artifact and/or creature cards and exile them. Then shuffle your library.\n{4}, {T}: Choose a card at random that was exiled with Skyship Weatherlight. Put that card into its owner's hand. +End \ No newline at end of file diff --git a/res/cardsfolder/s/spelljack.txt b/res/cardsfolder/s/spelljack.txt new file mode 100644 index 00000000000..d4559d0c7f5 --- /dev/null +++ b/res/cardsfolder/s/spelljack.txt @@ -0,0 +1,15 @@ +Name:Spelljack +ManaCost:3 U U U +Types:Instant +Text:no text +A:SP$ Counter | Cost$ 3 U U U | TargetType$ Spell | TgtPrompt$ Select target spell | ValidTgts$ Card | RememberTargets$ True | ForgetOtherTargets$ True | Destination$ Exile | SubAbility$ DBEffect | SpellDescription$ Counter target spell. If that spell is countered this way, exile it instead of putting it into its owner's graveyard. You may play it without paying its mana cost for as long as it remains exiled. (If it has X in its mana cost, X is 0.) +SVar:DBEffect:DB$ Effect | Name$ Spelljack Effect | RememberObjects$ Remembered | StaticAbilities$ PlayOpp,PlayYou | Duration$ Permanent | Triggers$ TrigCleanup | SVars$ DBCleanup | References$ PlayOpp,PlayYou,TrigCleanup,DBCleanup +SVar:PlayOpp:Mode$ Continuous | EffectZone$ Command | Affected$ Card.IsRemembered+OppOwn | AffectedZone$ Exile | AddHiddenKeyword$ May be played by your opponent without paying its mana cost | Description$ You may play cards exiled with Spelljack. +SVar:PlayYou:Mode$ Continuous | EffectZone$ Command | Affected$ Card.IsRemembered+YouOwn | AffectedZone$ Exile | AddHiddenKeyword$ May be played without paying its mana cost +SVar:TrigCleanup:Mode$ ChangesZone | ValidCard$ Card.IsRemembered | Origin$ Exile | Destination$ Any | TriggerZones$ Command | Execute$ DBCleanup | Static$ True +SVar:DBCleanup:DB$ ChangeZone | Defined$ Self | Origin$ Command | Destination$ Exile +SVar:Rarity:Rare +SVar:Picture:http://www.wizards.com/global/images/magic/general/spelljack.jpg +SetInfo:JUD|Rare|http://magiccards.info/scans/en/ju/51.jpg +Oracle:Counter target spell. If that spell is countered this way, exile it instead of putting it into its owner's graveyard. You may play it without paying its mana cost for as long as it remains exiled. (If it has X in its mana cost, X is 0.) +End \ No newline at end of file diff --git a/src/main/java/forge/card/abilityfactory/effects/ChooseCardEffect.java b/src/main/java/forge/card/abilityfactory/effects/ChooseCardEffect.java index 394ec3d45af..ae911714a83 100644 --- a/src/main/java/forge/card/abilityfactory/effects/ChooseCardEffect.java +++ b/src/main/java/forge/card/abilityfactory/effects/ChooseCardEffect.java @@ -78,7 +78,9 @@ public class ChooseCardEffect extends SpellEffect { if (p.isHuman()) { final String choiceTitle = sa.hasParam("ChoiceTitle") ? sa.getParam("ChoiceTitle") : "Choose a card "; Card o; - if (sa.hasParam("Mandatory")) { + if (sa.hasParam("AtRandom")) { + o = CardUtil.getRandom(choices); + } else if (sa.hasParam("Mandatory")) { o = GuiChoose.one(choiceTitle, choices); } else { o = GuiChoose.oneOrNone(choiceTitle, choices);