diff --git a/forge-ai/src/main/java/forge/ai/PlayerControllerAi.java b/forge-ai/src/main/java/forge/ai/PlayerControllerAi.java index 3cb65581073..ae767b3b994 100644 --- a/forge-ai/src/main/java/forge/ai/PlayerControllerAi.java +++ b/forge-ai/src/main/java/forge/ai/PlayerControllerAi.java @@ -941,6 +941,11 @@ public class PlayerControllerAi extends PlayerController { return SpellApiToAi.Converter.get(api).chooseCounterType(options, sa, params); } + @Override + public String chooseKeywordForPump(final List options, final SpellAbility sa, final String prompt) { + return Iterables.getFirst(options, null); + } + @Override public boolean confirmPayment(CostPart costPart, String prompt, SpellAbility sa) { return brains.confirmPayment(costPart); // AI is expected to know what it is paying for at the moment (otherwise add another parameter to this method) diff --git a/forge-game/src/main/java/forge/game/ability/effects/PumpEffect.java b/forge-game/src/main/java/forge/game/ability/effects/PumpEffect.java index 01e0890a7a3..3f864542c54 100644 --- a/forge-game/src/main/java/forge/game/ability/effects/PumpEffect.java +++ b/forge-game/src/main/java/forge/game/ability/effects/PumpEffect.java @@ -270,13 +270,19 @@ public class PumpEffect extends SpellAbilityEffect { @Override public void resolve(final SpellAbility sa) { - final Game game = sa.getActivatingPlayer().getGame(); + final Player activator = sa.getActivatingPlayer(); + final Game game = activator.getGame(); final Card host = sa.getHostCard(); final long timestamp = game.getNextTimestamp(); List keywords = Lists.newArrayList(); if (sa.hasParam("KW")) { keywords.addAll(Arrays.asList(sa.getParam("KW").split(" & "))); + } else if (sa.hasParam("KWChoice")) { + List options = Arrays.asList(sa.getParam("KWChoice").split(",")); + String chosen = activator.getController().chooseKeywordForPump(options, sa, + Localizer.getInstance().getMessage("lblChooseKeyword")); + keywords.add(chosen); } final int a = AbilityUtils.calculateAmount(host, sa.getParam("NumAtt"), sa, !sa.hasParam("Double")); final int d = AbilityUtils.calculateAmount(host, sa.getParam("NumDef"), sa, !sa.hasParam("Double")); @@ -301,7 +307,7 @@ public class PumpEffect extends SpellAbilityEffect { if (defined.equals("ChosenType")) { replaced = host.getChosenType(); } else if (defined.equals("ActivatorName")) { - replaced = sa.getActivatingPlayer().getName(); + replaced = activator.getName(); } else if (defined.equals("ChosenPlayer")) { replaced = host.getChosenPlayer().getName(); } else if (defined.endsWith("Player")) { @@ -369,7 +375,7 @@ public class PumpEffect extends SpellAbilityEffect { ? TextUtil.fastReplace(sa.getParam("OptionQuestion"), "TARGETS", targets) : Localizer.getInstance().getMessage("lblApplyPumpToTarget", targets); - if (!sa.getActivatingPlayer().getController().confirmAction(sa, null, message, null)) { + if (!activator.getController().confirmAction(sa, null, message, null)) { return; } } diff --git a/forge-game/src/main/java/forge/game/player/PlayerController.java b/forge-game/src/main/java/forge/game/player/PlayerController.java index 4a0dac41aa8..79d93efc85e 100644 --- a/forge-game/src/main/java/forge/game/player/PlayerController.java +++ b/forge-game/src/main/java/forge/game/player/PlayerController.java @@ -227,6 +227,8 @@ public abstract class PlayerController { public abstract CounterType chooseCounterType(List options, SpellAbility sa, String prompt, Map params); + public abstract String chooseKeywordForPump(List options, SpellAbility sa, String prompt); + public abstract boolean confirmPayment(CostPart costPart, String string, SpellAbility sa); public abstract ReplacementEffect chooseSingleReplacementEffect(String prompt, List possibleReplacers); public abstract String chooseProtectionType(String string, SpellAbility sa, List choices); diff --git a/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java b/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java index b8444645190..7fb4922da42 100644 --- a/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java +++ b/forge-gui-desktop/src/test/java/forge/gamesimulationtests/util/PlayerControllerForTests.java @@ -47,6 +47,7 @@ import forge.gamesimulationtests.util.player.PlayerSpecificationHandler; import forge.gamesimulationtests.util.playeractions.*; import forge.item.PaperCard; import forge.player.HumanPlay; +import forge.util.Aggregates; import forge.util.ITriggerEvent; import forge.util.MyRandom; import forge.util.collect.FCollectionView; @@ -510,6 +511,14 @@ public class PlayerControllerForTests extends PlayerController { return Iterables.getFirst(options, CounterType.get(CounterEnumType.P1P1)); } + @Override + public String chooseKeywordForPump(final List options, final SpellAbility sa, final String prompt) { + if (options.size() <= 1) { + return Iterables.getFirst(options, null); + } + return Aggregates.random(options); + } + @Override public boolean confirmPayment(CostPart costPart, String string, SpellAbility ability) { return true; diff --git a/forge-gui/res/cardsfolder/a/alchemists_gift.txt b/forge-gui/res/cardsfolder/a/alchemists_gift.txt index 0c165022ce2..5797814a6fb 100644 --- a/forge-gui/res/cardsfolder/a/alchemists_gift.txt +++ b/forge-gui/res/cardsfolder/a/alchemists_gift.txt @@ -1,8 +1,6 @@ Name:Alchemist's Gift ManaCost:B Types:Instant -A:SP$ Pump | Cost$ B | ValidTgts$ Creature | TgtPrompt$ Select target creature | NumAtt$ +1 | NumDef$ +1 | SubAbility$ DBChoose | StackDescription$ SpellDescription | SpellDescription$ Target creature gets +1/+1 and gains your choice of deathtouch or lifelink until end of turn. -SVar:DBChoose:DB$ GenericChoice | Defined$ You | Choices$ DBDeathtouch,DBLifelink | StackDescription$ None -SVar:DBDeathtouch:DB$ Pump | KW$ Deathtouch | Defined$ Targeted | SpellDescription$ Target creature gains deathtouch until end of turn. -SVar:DBLifelink:DB$ Pump | KW$ Lifelink | Defined$ Targeted | SpellDescription$ Target creature gains lifelink until end of turn. +A:SP$ Pump | ValidTgts$ Creature | NumAtt$ +1 | NumDef$ +1 | KWChoice$ Deathtouch,Lifelink | StackDescription$ {c:Targeted} gets +1/+1 and gains your choice of deathtouch or lifelink until end of turn. | SpellDescription$ Target creature gets +1/+1 and gains your choice of deathtouch or lifelink until end of turn. (Any amount of damage a creature with deathtouch deals to a creature is enough to destroy it. Damage dealt by a creature with lifelink also causes its controller to gain that much life.) +DeckHas:Ability$LifeGain Oracle:Target creature gets +1/+1 and gains your choice of deathtouch or lifelink until end of turn. (Any amount of damage a creature with deathtouch deals to a creature is enough to destroy it. Damage dealt by a creature with lifelink also causes its controller to gain that much life.) diff --git a/forge-gui/res/cardsfolder/b/butcher_of_the_horde.txt b/forge-gui/res/cardsfolder/b/butcher_of_the_horde.txt index fc1030bcb56..391abbd0af2 100644 --- a/forge-gui/res/cardsfolder/b/butcher_of_the_horde.txt +++ b/forge-gui/res/cardsfolder/b/butcher_of_the_horde.txt @@ -3,8 +3,6 @@ ManaCost:1 R W B Types:Creature Demon PT:5/4 K:Flying -A:AB$ GenericChoice | Cost$ Sac<1/Creature.Other/another creature> | Choices$ DBVigilance,DBLifelink,DBHaste | SpellDescription$ CARDNAME gains your choice of Vigilance, lifelink, or haste until end of turn. -SVar:DBVigilance:DB$ Pump | Defined$ Self | KW$ Vigilance | SpellDescription$ CARDNAME gains vigilance until end of turn. -SVar:DBLifelink:DB$ Pump | Defined$ Self | KW$ Lifelink | SpellDescription$ CARDNAME gains lifelink until end of turn. -SVar:DBHaste:DB$ Pump | Defined$ Self | KW$ Haste | SpellDescription$ CARDNAME gains haste until end of turn. +A:AB$ Pump | Cost$ Sac<1/Creature.Other/another creature> | KWChoice$ Vigilance,Lifelink,Haste | SpellDescription$ CARDNAME gains your choice of vigilance, lifelink, or haste until end of turn. +DeckHas:Ability$Sacrifice|LifeGain Oracle:Flying\nSacrifice another creature: Butcher of the Horde gains your choice of vigilance, lifelink, or haste until end of turn. diff --git a/forge-gui/res/cardsfolder/g/gideon_blackblade.txt b/forge-gui/res/cardsfolder/g/gideon_blackblade.txt index 4a4508991cf..95b13698a24 100644 --- a/forge-gui/res/cardsfolder/g/gideon_blackblade.txt +++ b/forge-gui/res/cardsfolder/g/gideon_blackblade.txt @@ -4,10 +4,7 @@ Types:Legendary Planeswalker Gideon Loyalty:4 S:Mode$ Continuous | Affected$ Card.Self | EffectZone$ Battlefield | Condition$ PlayerTurn | SetPower$ 4 | SetToughness$ 4 | AddType$ Creature & Human & Soldier | AddKeyword$ Indestructible | Description$ As long as it's your turn, CARDNAME is a 4/4 Human Soldier creature with indestructible that's still a planeswalker. R:Event$ DamageDone | Prevent$ True | ValidTarget$ Card.Self | PlayerTurn$ True | Description$ Prevent all damage that would be dealt to CARDNAME during your turn. -A:AB$ GenericChoice | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | TargetMin$ 0 | TargetMax$ 1 | ValidTgts$ Creature.YouCtrl+Other | TgtPrompt$ Select up to one target creature you control | Choices$ DBVigilance,DBLifelink,DBIndestructible | Defined$ You | ConditionDefined$ Targeted | ConditionPresent$ Card | ConditionCompare$ GE1 | AILogic$ GideonBlackblade | SpellDescription$ Up to one other target creature you control gains your choice of vigilance, lifelink, or indestructible until end of turn. | StackDescription$ SpellDescription -SVar:DBVigilance:DB$ Pump | Defined$ Targeted | KW$ Vigilance | SpellDescription$ Targeted creature gains Vigilance until end of turn. -SVar:DBLifelink:DB$ Pump | Defined$ Targeted | KW$ Lifelink | SpellDescription$ Targeted creature gains Lifelink until end of turn. -SVar:DBIndestructible:DB$ Pump | Defined$ Targeted | KW$ Indestructible | SpellDescription$ Targeted creature gains Indestructible until end of turn. +A:AB$ Pump | Cost$ AddCounter<1/LOYALTY> | Planeswalker$ True | TargetMin$ 0 | TargetMax$ 1 | ValidTgts$ Creature.YouCtrl+Other | TgtPrompt$ Select up to one target creature you control | KWChoice$ Vigilance,Lifelink,Indestructible | ConditionDefined$ Targeted | ConditionPresent$ Card | ConditionCompare$ GE1 | AILogic$ GideonBlackblade | SpellDescription$ Up to one other target creature you control gains your choice of vigilance, lifelink, or indestructible until end of turn. | StackDescription$ SpellDescription A:AB$ ChangeZone | Cost$ SubCounter<6/LOYALTY> | Planeswalker$ True | Ultimate$ True | ValidTgts$ Permanent.nonLand | TgtPrompt$ Select target nonland permanent | Origin$ Battlefield | Destination$ Exile | SpellDescription$ Exile target nonland permanent. DeckHints:Ability$LifeGain Oracle:As long as it's your turn, Gideon Blackblade is a 4/4 Human Soldier creature with indestructible that's still a planeswalker.\nPrevent all damage that would be dealt to Gideon Blackblade during your turn.\n[+1]: Up to one other target creature you control gains your choice of vigilance, lifelink, or indestructible until end of turn.\n[-6]: Exile target nonland permanent. diff --git a/forge-gui/res/cardsfolder/g/golem_artisan.txt b/forge-gui/res/cardsfolder/g/golem_artisan.txt index 1097abd2ddf..2b5f4ce3f95 100644 --- a/forge-gui/res/cardsfolder/g/golem_artisan.txt +++ b/forge-gui/res/cardsfolder/g/golem_artisan.txt @@ -2,9 +2,6 @@ Name:Golem Artisan ManaCost:5 Types:Artifact Creature Golem PT:3/3 -A:AB$ Pump | Cost$ 2 | ValidTgts$ Creature.Artifact | NumAtt$ +1 | NumDef$ +1 | SpellDescription$ Target artifact creature gets +1/+1 until end of turn. | TgtPrompt$ Select target artifact creature. -A:AB$ GenericChoice | Cost$ 2 | ValidTgts$ Creature.Artifact | TgtPrompt$ Select target artifact creature. | Choices$ DBFlying,DBTrample,DBHaste | Defined$ You | SpellDescription$ Target artifact creature gains your choice of flying, trample, or haste until end of turn. -SVar:DBFlying:DB$ Pump | Defined$ Targeted | KW$ Flying | SpellDescription$ Target artifact creature gains flying until end of turn. -SVar:DBTrample:DB$ Pump | Defined$ Targeted | KW$ Trample | SpellDescription$ Target artifact creature gains trample until end of turn. -SVar:DBHaste:DB$ Pump | Defined$ Targeted | KW$ Haste | SpellDescription$ Target artifact creature gains haste until end of turn. +A:AB$ Pump | Cost$ 2 | ValidTgts$ Creature.Artifact | NumAtt$ +1 | NumDef$ +1 | SpellDescription$ Target artifact creature gets +1/+1 until end of turn. | TgtPrompt$ Select target artifact creature +A:AB$ Pump | Cost$ 2 | ValidTgts$ Creature.Artifact | TgtPrompt$ Select target artifact creature | KWChoice$ Flying,Trample,Haste | StackDescription$ {c:Targeted} gains your choice of flying, trample, or haste until end of turn. | SpellDescription$ Target artifact creature gains your choice of flying, trample, or haste until end of turn. Oracle:{2}: Target artifact creature gets +1/+1 until end of turn.\n{2}: Target artifact creature gains your choice of flying, trample, or haste until end of turn. diff --git a/forge-gui/res/cardsfolder/j/jodahs_avenger.txt b/forge-gui/res/cardsfolder/j/jodahs_avenger.txt index 3df5c054f9a..a3aac0e874c 100644 --- a/forge-gui/res/cardsfolder/j/jodahs_avenger.txt +++ b/forge-gui/res/cardsfolder/j/jodahs_avenger.txt @@ -2,9 +2,5 @@ Name:Jodah's Avenger ManaCost:5 U Types:Creature Shapeshifter PT:4/4 -A:AB$ GenericChoice | Cost$ 0 | Choices$ DBDoubleStrike,DBProtection,DBVigilance,DBShadow | SpellDescription$ Until end of turn, CARDNAME gets -1/-1 and gains your choice of double strike, protection from red, vigilance, or shadow. -SVar:DBDoubleStrike:DB$ Pump | Defined$ Self | NumAtt$ -1 | NumDef$ -1 | KW$ Double Strike | SpellDescription$ CARDNAME gets -1/-1 and gains double strike until end of turn. -SVar:DBProtection:DB$ Pump | Defined$ Self | NumAtt$ -1 | NumDef$ -1 | KW$ Protection from red | SpellDescription$ CARDNAME gets -1/-1 and gains protection from red until end of turn. -SVar:DBVigilance:DB$ Pump | Defined$ Self | NumAtt$ -1 | NumDef$ -1 | KW$ Vigilance | SpellDescription$ CARDNAME gets -1/-1 and gains vigilance until end of turn. -SVar:DBShadow:DB$ Pump | Defined$ Self | NumAtt$ -1 | NumDef$ -1 | KW$ Shadow | SpellDescription$ CARDNAME gets -1/-1 and gains shadow until end of turn. +A:AB$ Pump | Cost$ 0 | NumAtt$ -1 | NumDef$ -1 | KWChoice$ Double Strike,Protection from red,Vigilance,Shadow | StackDescription$ SpellDescription | SpellDescription$ Until end of turn, CARDNAME gets -1/-1 and gains your choice of double strike, protection from red, vigilance, or shadow. Oracle:{0}: Until end of turn, Jodah's Avenger gets -1/-1 and gains your choice of double strike, protection from red, vigilance, or shadow. (A creature with shadow can block or be blocked by only creatures with shadow.) diff --git a/forge-gui/res/cardsfolder/l/lunar_avenger.txt b/forge-gui/res/cardsfolder/l/lunar_avenger.txt index d0d4724698e..17a8a80a574 100644 --- a/forge-gui/res/cardsfolder/l/lunar_avenger.txt +++ b/forge-gui/res/cardsfolder/l/lunar_avenger.txt @@ -3,10 +3,7 @@ ManaCost:7 Types:Artifact Creature Golem PT:2/2 K:Sunburst -A:AB$ GenericChoice | Cost$ SubCounter<1/P1P1> | Choices$ DBFlying,DBFirstStrike,DBHaste | Defined$ You | SpellDescription$ CARDNAME gains your choice of flying, first strike, or haste until end of turn. -SVar:DBFlying:DB$ Pump | Defined$ Self | KW$ Flying | SpellDescription$ gains flying until end of turn. -SVar:DBFirstStrike:DB$ Pump | Defined$ Self | KW$ First Strike | SpellDescription$ gains first strike until end of turn. -SVar:DBHaste:DB$ Pump | Defined$ Self | KW$ Haste | SpellDescription$ gains haste until end of turn. +A:AB$ Pump | Cost$ SubCounter<1/P1P1> | KWChoice$ Flying,First Strike,Haste | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gains your choice of flying, first strike, or haste until end of turn. AI:RemoveDeck:Random SVar:NeedsToPlayVar:Z GE2 SVar:Z:Count$UniqueManaColorsProduced.ByUntappedSources diff --git a/forge-gui/res/cardsfolder/m/multiform_wonder.txt b/forge-gui/res/cardsfolder/m/multiform_wonder.txt index 99d6f7c721e..0e9254cf727 100644 --- a/forge-gui/res/cardsfolder/m/multiform_wonder.txt +++ b/forge-gui/res/cardsfolder/m/multiform_wonder.txt @@ -4,11 +4,8 @@ Types:Artifact Creature Construct PT:3/3 T:Mode$ ChangesZone | Origin$ Any | Destination$ Battlefield | ValidCard$ Card.Self | Execute$ TrigEnergy | TriggerDescription$ When CARDNAME enters the battlefield, you get {E}{E}{E} (three energy counters). SVar:TrigEnergy:DB$ PutCounter | Defined$ You | CounterType$ ENERGY | CounterNum$ 3 -A:AB$ GenericChoice | Cost$ PayEnergy<1> | Choices$ DBFlying,DBVigilance,DBLifelink | SpellDescription$ CARDNAME gains your choice of flying, vigilance, or lifelink until end of turn. -SVar:DBFlying:DB$ Pump | Defined$ Self | KW$ Flying | SpellDescription$ CARDNAME gains flying until end of turn. -SVar:DBVigilance:DB$ Pump | Defined$ Self | KW$ Vigilance | SpellDescription$ CARDNAME gains vigilance until end of turn. -SVar:DBLifelink:DB$ Pump | Defined$ Self | KW$ Lifelink | SpellDescription$ CARDNAME gains lifelink until end of turn. -A:AB$ Pump | Cost$ PayEnergy<1> | Subability$ ABChoice | SpellDescription$ CARDNAME gets +2/-2 or -2/+2 until end of turn. +A:AB$ Pump | Cost$ PayEnergy<1> | KWChoice$ Flying,Vigilance,Lifelink | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gains your choice of flying, vigilance, or lifelink until end of turn. +A:AB$ Pump | Cost$ PayEnergy<1> | Subability$ ABChoice | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gets +2/-2 or -2/+2 until end of turn. SVar:ABChoice:DB$ GenericChoice | Defined$ You | Choices$ ABPump1,ABPump2 SVar:ABPump1:DB$ Pump | Defined$ Self | NumAtt$ +2 | NumDef$ -2 | SpellDescription$ +2/-2 SVar:ABPump2:DB$ Pump | Defined$ Self | NumAtt$ -2 | NumDef$ +2 | SpellDescription$ -2/+2 diff --git a/forge-gui/res/cardsfolder/s/shifting_ceratops.txt b/forge-gui/res/cardsfolder/s/shifting_ceratops.txt index c17a05a5c9d..96bc46abd6f 100644 --- a/forge-gui/res/cardsfolder/s/shifting_ceratops.txt +++ b/forge-gui/res/cardsfolder/s/shifting_ceratops.txt @@ -4,8 +4,5 @@ Types:Creature Dinosaur PT:5/4 K:This spell can't be countered. K:Protection from blue -A:AB$ GenericChoice | Cost$ G | Choices$ DBReach,DBTrample,DBHaste | SpellDescription$ CARDNAME gains your choice of reach, trample, or haste until end of turn. -SVar:DBReach:DB$ Pump | Defined$ Self | KW$ Reach | SpellDescription$ CARDNAME gains reach until end of turn. -SVar:DBTrample:DB$ Pump | Defined$ Self | KW$ Trample | SpellDescription$ CARDNAME gains trample until end of turn. -SVar:DBHaste:DB$ Pump | Defined$ Self | KW$ Haste | SpellDescription$ CARDNAME gains haste until end of turn. +A:AB$ Pump | Cost$ G | KWChoice$ Reach,Trample,Haste | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gains your choice of reach, trample, or haste until end of turn. Oracle:This spell can't be countered.\nProtection from blue (This creature can't be blocked, targeted, dealt damage, enchanted, or equipped by anything blue.)\n{G}: Shifting Ceratops gains your choice of reach, trample, or haste until end of turn. diff --git a/forge-gui/res/cardsfolder/s/silverquill_pledgemage.txt b/forge-gui/res/cardsfolder/s/silverquill_pledgemage.txt index 105809e7811..b89376fa2f4 100644 --- a/forge-gui/res/cardsfolder/s/silverquill_pledgemage.txt +++ b/forge-gui/res/cardsfolder/s/silverquill_pledgemage.txt @@ -2,8 +2,8 @@ Name:Silverquill Pledgemage ManaCost:1 W/B W/B Types:Creature Vampire Cleric PT:3/1 -T:Mode$ SpellCastOrCopy | ValidCard$ Instant,Sorcery | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigChoice | TriggerDescription$ Magecraft — Whenever you cast or copy an instant or sorcery spell, Silverquill Pledgemage gains your choice of flying or lifelink until end of turn. -SVar:TrigChoice:DB$ GenericChoice | Choices$ DBFlying,DBLifelink | SpellDescription$ CARDNAME gains your choice of flying or lifelink until end of turn. -SVar:DBFlying:DB$ Pump | Defined$ Self | KW$ Flying | SpellDescription$ CARDNAME gains flying until end of turn. -SVar:DBLifelink:DB$ Pump | Defined$ Self | KW$ Lifelink | SpellDescription$ CARDNAME gains lifelink until end of turn. +T:Mode$ SpellCastOrCopy | ValidCard$ Instant,Sorcery | ValidActivatingPlayer$ You | TriggerZones$ Battlefield | Execute$ TrigChoice | TriggerDescription$ Magecraft — Whenever you cast or copy an instant or sorcery spell, CARDNAME gains your choice of flying or lifelink until end of turn. +SVar:TrigChoice:DB$ Pump | KWChoice$ Flying,Lifelink +DeckHas:Ability$LifeGain +DeckNeeds:Type$Instant|Sorcery Oracle:Magecraft — Whenever you cast or copy an instant or sorcery spell, Silverquill Pledgemage gains your choice of flying or lifelink until end of turn. diff --git a/forge-gui/res/cardsfolder/u/urzas_avenger.txt b/forge-gui/res/cardsfolder/u/urzas_avenger.txt index 706a3598ea5..029c323ed61 100644 --- a/forge-gui/res/cardsfolder/u/urzas_avenger.txt +++ b/forge-gui/res/cardsfolder/u/urzas_avenger.txt @@ -2,11 +2,6 @@ Name:Urza's Avenger ManaCost:6 Types:Artifact Creature Shapeshifter PT:4/4 -A:AB$ Pump | Cost$ 0 | Defined$ Self | NumAtt$ -1 | NumDef$ -1 | SubAbility$ DBChoose | SpellDescription$ CARDNAME gets -1/-1 and gains your choice of banding, flying, first strike, or trample until end of turn. -SVar:DBChoose:DB$ GenericChoice | Defined$ You | Choices$ DBFlying,DBBanding,DBFirstStrike,DBTrample -SVar:DBFlying:DB$ Pump | KW$ Flying | Defined$ Self | SpellDescription$ Target creature gains Flying until end of turn. -SVar:DBBanding:DB$ Pump | KW$ Banding | Defined$ Self | SpellDescription$ Target creature gains Banding until end of turn. -SVar:DBFirstStrike:DB$ Pump | KW$ First Strike | Defined$ Self | SpellDescription$ Target creature gains first strike until end of turn. -SVar:DBTrample:DB$ Pump | KW$ Trample | Defined$ Self | SpellDescription$ Target creature gains Trample until end of turn. +A:AB$ Pump | Cost$ 0 | NumAtt$ -1 | NumDef$ -1 | KWChoice$ Flying,Banding,First Strike,Trample | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gets -1/-1 and gains your choice of banding, flying, first strike, or trample until end of turn. AI:RemoveDeck:All Oracle:{0}: Urza's Avenger gets -1/-1 and gains your choice of banding, flying, first strike, or trample until end of turn. (Any creatures with banding, and up to one without, can attack in a band. Bands are blocked as a group. If any creatures with banding you control are blocking or being blocked by a creature, you divide that creature's combat damage, not its controller, among any of the creatures it's being blocked by or is blocking.) diff --git a/forge-gui/res/cardsfolder/v/veteran_warleader.txt b/forge-gui/res/cardsfolder/v/veteran_warleader.txt index 9f2b1eb80cb..8c2b253fe1f 100644 --- a/forge-gui/res/cardsfolder/v/veteran_warleader.txt +++ b/forge-gui/res/cardsfolder/v/veteran_warleader.txt @@ -4,10 +4,7 @@ Types:Creature Human Soldier Ally PT:*/* S:Mode$ Continuous | EffectZone$ All | CharacteristicDefining$ True | SetPower$ X | SetToughness$ X | Description$ CARDNAME's power and toughness are each equal to the number of creatures you control. SVar:X:Count$Valid Creature.YouCtrl -A:AB$ GenericChoice | Cost$ tapXType<1/Ally.Other> | Choices$ ChooseFirstStrike,ChooseVigilance,ChooseTrample | SpellDescription$ CARDNAME gains your choice of first strike, vigilance, or trample until end of turn. -SVar:ChooseFirstStrike:DB$ Pump | Defined$ Self | KW$ First Strike | SpellDescription$ CARDNAME gains first strike until end of turn. -SVar:ChooseVigilance:DB$ Pump | Defined$ Self | KW$ Vigilance | SpellDescription$ CARDNAME gains vigilance until end of turn. -SVar:ChooseTrample:DB$ Pump | Defined$ Self | KW$ Trample | SpellDescription$ CARDNAME gains trample until end of turn. +A:AB$ Pump | Cost$ tapXType<1/Ally.Other> | KWChoice$ First Strike,Vigilance,Trample | StackDescription$ SpellDescription | SpellDescription$ CARDNAME gains your choice of first strike, vigilance, or trample until end of turn. SVar:BuffedBy:Creature SVar:NoZeroToughnessAI:True DeckHints:Type$Ally diff --git a/forge-gui/res/languages/de-DE.properties b/forge-gui/res/languages/de-DE.properties index 634c2ff2e49..a338e501c08 100644 --- a/forge-gui/res/languages/de-DE.properties +++ b/forge-gui/res/languages/de-DE.properties @@ -2012,6 +2012,7 @@ lblSelectCardToPlay=Wähle Karte zum Spielen lblChooseAProtection=Wähle eine Schutz #PumpEffect.java lblApplyPumpToTarget=Verstärke {0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=Möchtest du deine Bibliothek mischen? #RepeatEffect.java diff --git a/forge-gui/res/languages/en-US.properties b/forge-gui/res/languages/en-US.properties index da704b10d4a..fc334ebe981 100644 --- a/forge-gui/res/languages/en-US.properties +++ b/forge-gui/res/languages/en-US.properties @@ -2013,6 +2013,7 @@ lblSelectCardToPlay=Select a card to play lblChooseAProtection=Choose a protection #PumpEffect.java lblApplyPumpToTarget=Apply pump to {0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=Do you want to shuffle the library? #RepeatEffect.java diff --git a/forge-gui/res/languages/es-ES.properties b/forge-gui/res/languages/es-ES.properties index 2d4a9f18cb4..69e5bd4ab8f 100644 --- a/forge-gui/res/languages/es-ES.properties +++ b/forge-gui/res/languages/es-ES.properties @@ -2011,6 +2011,7 @@ lblSelectCardToPlay=Selecciona una carta para jugar lblChooseAProtection=Elige una protección #PumpEffect.java lblApplyPumpToTarget=¿Aplicar la bomba a {0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=¿Quieres barajar la biblioteca? #RepeatEffect.java diff --git a/forge-gui/res/languages/fr-FR.properties b/forge-gui/res/languages/fr-FR.properties index 5cb8552ba91..07eadf4359b 100644 --- a/forge-gui/res/languages/fr-FR.properties +++ b/forge-gui/res/languages/fr-FR.properties @@ -2015,6 +2015,7 @@ lblSelectCardToPlay=Sélectionnez une carte à jouer lblChooseAProtection=Choisir une protection #PumpEffect.java lblApplyPumpToTarget=Appliquer la pompe à {0} ? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=Voulez-vous mélanger la bibliothèque ? #RepeatEffect.java diff --git a/forge-gui/res/languages/it-IT.properties b/forge-gui/res/languages/it-IT.properties index 4f29ed4046c..8057e4b9847 100644 --- a/forge-gui/res/languages/it-IT.properties +++ b/forge-gui/res/languages/it-IT.properties @@ -2010,6 +2010,7 @@ lblSelectCardToPlay=Seleziona una carta da giocare lblChooseAProtection=Scegli una protezione #PumpEffect.java lblApplyPumpToTarget=Applica il potenziamento a {0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=Vuoi mescolare il grimorio? #RepeatEffect.java diff --git a/forge-gui/res/languages/ja-JP.properties b/forge-gui/res/languages/ja-JP.properties index ab18b9806ff..1d708a81557 100644 --- a/forge-gui/res/languages/ja-JP.properties +++ b/forge-gui/res/languages/ja-JP.properties @@ -2010,6 +2010,7 @@ lblSelectCardToPlay=プレイするカードを選ぶ lblChooseAProtection=プロテクションを 1つ選択 #PumpEffect.java lblApplyPumpToTarget={0}を強化しますか? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=ライブラリーをシャッフルしますか? #RepeatEffect.java diff --git a/forge-gui/res/languages/pt-BR.properties b/forge-gui/res/languages/pt-BR.properties index dce3de3002d..4effa58683f 100644 --- a/forge-gui/res/languages/pt-BR.properties +++ b/forge-gui/res/languages/pt-BR.properties @@ -2072,6 +2072,7 @@ lblSelectCardToPlay=Escolha uma carta para jogar lblChooseAProtection=Escolha a proteção #PumpEffect.java lblApplyPumpToTarget=Aplicar bomba a {0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=Quer embaralhar o grimório? #RepeatEffect.java diff --git a/forge-gui/res/languages/zh-CN.properties b/forge-gui/res/languages/zh-CN.properties index 3cef5f98e9b..da05f71fffa 100644 --- a/forge-gui/res/languages/zh-CN.properties +++ b/forge-gui/res/languages/zh-CN.properties @@ -2014,6 +2014,7 @@ lblSelectCardToPlay=选择要使用的牌 lblChooseAProtection=选择一个保护 #PumpEffect.java lblApplyPumpToTarget=将pump用于{0}? +lblChooseKeyword=Choose keyword to grant #RearrangeTopOfLibraryEffect.java lblDoyouWantShuffleTheLibrary=你想要洗这个牌库吗? #RepeatEffect.java diff --git a/forge-gui/src/main/java/forge/player/PlayerControllerHuman.java b/forge-gui/src/main/java/forge/player/PlayerControllerHuman.java index 3cdc91f802f..04966d5de68 100644 --- a/forge-gui/src/main/java/forge/player/PlayerControllerHuman.java +++ b/forge-gui/src/main/java/forge/player/PlayerControllerHuman.java @@ -1785,6 +1785,14 @@ public class PlayerControllerHuman extends PlayerController implements IGameCont return getGui().one(prompt, options); } + @Override + public String chooseKeywordForPump(final List options, final SpellAbility sa, final String prompt) { + if (options.size() <= 1) { + return Iterables.getFirst(options, null); + } + return getGui().one(prompt, options); + } + @Override public boolean confirmPayment(final CostPart costPart, final String question, SpellAbility sa) { if (GuiBase.getInterface().isLibgdxPort()) {