diff --git a/res/card-pictures.txt b/res/card-pictures.txt index 75c31559a48..fae0a201651 100644 --- a/res/card-pictures.txt +++ b/res/card-pictures.txt @@ -38,6 +38,20 @@ snow_covered_mountain.jpg http://www.wizards.com/global/images/magic/gene snow_covered_mountain1.jpg http://www.wizards.com/global/images/magic/general/snow_covered_mountain.jpg snow_covered_mountain2.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg snow_covered_mountain3.jpg http://www.magickartenmarkt.de/img/cards/Ice_Age/snow_covered_mountain.jpg +edgewalker.jpg http://www.wizards.com/global/images/magic/general/edgewalker.jpg +thunderscape_familiar.jpg http://www.wizards.com/global/images/magic/general/thunderscape_familiar.jpg +sphere_of_resistance.jpg http://www.wizards.com/global/images/magic/general/sphere_of_resistance.jpg +training_grounds.jpg http://www.wizards.com/global/images/magic/general/training_grounds.jpg +undead_warchief.jpg http://www.wizards.com/global/images/magic/general/undead_warchief.jpg +grand_arbiter_augustin_iv.jpg http://www.wizards.com/global/images/magic/general/grand_arbiter_augustin_iv.jpg +goblin_warchief.jpg http://www.wizards.com/global/images/magic/general/goblin_warchief.jpg +etherium_sculptor.jpg http://www.wizards.com/global/images/magic/general/etherium_sculptor.jpg +chill.jpg http://www.wizards.com/global/images/magic/general/chill.jpg +centaur_omenreader.jpg http://www.wizards.com/global/images/magic/general/centaur_omenreader.jpg +bosk_banneret.jpg http://www.wizards.com/global/images/magic/general/bosk_banneret.jpg +ballyrush_banneret.jpg http://www.wizards.com/global/images/magic/general/ballyrush_banneret.jpg +andradite_leech.jpg http://www.wizards.com/global/images/magic/general/andradite_leech.jpg +alabaster_leech.jpg http://www.wizards.com/global/images/magic/general/alabaster_leech.jpg leyline_of_singularity.jpg http://www.wizards.com/global/images/magic/general/leyline_of_singularity.jpg cursed_rack.jpg http://www.wizards.com/global/images/magic/general/cursed_rack.jpg gnat_miser.jpg http://www.wizards.com/global/images/magic/general/gnat_miser.jpg diff --git a/res/cards.txt b/res/cards.txt index 9e27e32a888..c87382cb7c0 100644 --- a/res/cards.txt +++ b/res/cards.txt @@ -1,3 +1,103 @@ +Edgewalker +1 W B +Creature Human Cleric +Cleric spells you cast cost W B less to cast. This effect reduces only the amount of colored mana you pay. (For example, if you cast a Cleric spell with mana cost 1 W, it costs 1 to cast.) +2/2 +CostChange:Player:Less:W:Spell:All:Cleric:NoSpecial +CostChange:Player:Less:B:Spell:All:Cleric:NoSpecial + +Thunderscape Familiar +1 R +Creature Kavu +Black spells and green spells you cast cost 1 less to cast. +1/1 +First strike +CostChange:Player:Less:1:Spell:black/green:All:OnlyOneBonus + +Sphere of Resistance +2 +Artifact +Spells cost 1 more to cast. +CostChange:All:More:1:Spell:All:All:NoSpecial + +Training Grounds +U +Enchantment +Activated abilities of creatures you control cost up to 2 less to activate. This effect can't reduce the amount of mana an ability costs to activate to less than one mana. +CostChange:Player:Less:2:Ability:All:Creature:TargetInPlay + +Undead Warchief +2 B B +Creature Zombie +Zombie spells you cast cost 1 less to cast. Zombie creatures you control get +2/+1. +1/1 +CostChange:Player:Less:1:Spell:All:Zombie:NoSpecial + +Grand Arbiter Augustin IV +2 W U +Legendary Creature Human Advisor +White spells you cast cost 1 less to cast. Blue spells you cast cost 1 less to cast. Spells your opponents cast cost 1 more to cast. +2/3 +CostChange:Player:Less:1:Spell:white:All:NoSpecial +CostChange:Player:Less:1:Spell:blue:All:NoSpecial +CostChange:Opponent:More:1:Spell:All:All:NoSpecial + +Goblin Warchief +1 R R +Creature Goblin +Goblin spells you cast cost 1 less to cast. Goblin creatures you control have haste. +2/2 +CostChange:Player:Less:1:Spell:All:Goblin:NoSpecial + +Etherium Sculptor +1 U +Artifact Creature Vedalken Artificer +Artifact spells you cast cost 1 less to cast. +1/2 +CostChange:Player:Less:1:Spell:All:All:NoSpecial + +Chill +1 U +Enchantment +Red spells cost 2 more to cast. +CostChange:All:More:2:Spell:red:All:NoSpecial + +Centaur Omenreader +3 G +Snow Creature Centaur Shaman +As long as Centaur Omenreader is tapped, creature spells you cast cost 2 less to cast. +3/3 +CostChange:Player:Less:2:Spell:All:Creature:CardIsTapped + +Bosk Banneret +1 G +Creature Treefolk Shaman +Treefolk spells and Shaman spells you cast cost 1 less to cast. +1/3 +CostChange:Player:Less:1:Spell:All:Treefolk/Shaman:OnlyOneBonus + +Ballyrush Banneret +1 W +Creature Kithkin Soldier +Kithkin spells and Soldier spells you cast cost 1 less to cast. +2/1 +CostChange:Player:Less:1:Spell:All:Kithkin/Soldier:OnlyOneBonus + +Andradite Leech +2 B +Creature Leech +Black spells you cast cost B more to cast. +2/2 +abPump B:+1/+1 +CostChange:Player:More:B:Spell:black:All:NoSpecial + +Alabaster Leech +W +Creature Leech +White spells you cast cost W more to cast. +1/3 +CostChange:Player:More:W:Spell:white:All:NoSpecial + Volcanic Island no cost Land Mountain Island diff --git a/src/forge/Card.java b/src/forge/Card.java index 6fc654b4dae..1b81f492a02 100644 --- a/src/forge/Card.java +++ b/src/forge/Card.java @@ -510,8 +510,10 @@ public class Card extends MyObservable { StringBuilder sb = new StringBuilder(); ArrayList keyword = getKeyword(); for(int i = 0; i < keyword.size(); i++) { + if(!keyword.get(i).toString().contains("CostChange")) { if(i != 0) sb.append(", "); - sb.append(keyword.get(i).toString()); + sb.append(keyword.get(i).toString()); + } } sb.append("\r\n"); sb.append(text); diff --git a/src/forge/ComputerUtil.java b/src/forge/ComputerUtil.java index 746c9cc3100..e3998963a23 100644 --- a/src/forge/ComputerUtil.java +++ b/src/forge/ComputerUtil.java @@ -158,80 +158,8 @@ public class ComputerUtil { land.remove(sa.getSourceCard()); } - Card originalCard = sa.getSourceCard(); ManaCost cost = new ManaCost(sa.getManaCost()); - if(sa.isSpell() == true) { - if(originalCard.getName().equals("Avatar of Woe")){ - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerGraveyard = AllZone.getZone(Constant.Zone.Graveyard, player); - CardList PlayerCreatureList = new CardList(PlayerGraveyard.getCards()); - PlayerCreatureList = PlayerCreatureList.getType("Creature"); - PlayerZone OpponentGraveyard = AllZone.getZone(Constant.Zone.Graveyard, opponent); - CardList OpponentCreatureList = new CardList(OpponentGraveyard.getCards()); - OpponentCreatureList = OpponentCreatureList.getType("Creature"); - if((PlayerCreatureList.size() + OpponentCreatureList.size()) >= 10) { - ManaCost cost2 = new ManaCost("B B"); - cost = cost2; - } - } // Avatar of Woe - else if(originalCard.getName().equals("Avatar of Will")){ - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentHand = AllZone.getZone(Constant.Zone.Hand, opponent); - CardList OpponentHandList = new CardList(OpponentHand.getCards()); - if(OpponentHandList.size() == 0) { - ManaCost cost2 = new ManaCost("U U"); - cost = cost2; - } - } // Avatar of Will - else if(originalCard.getName().equals("Avatar of Fury")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentLand = new CardList(OpponentPlay.getCards()); - OpponentLand = OpponentLand.getType("Land"); - if(OpponentLand.size() >= 7) { - ManaCost cost2 = new ManaCost("R R"); - cost = cost2; - } - } // Avatar of Fury - else if(originalCard.getName().equals("Avatar of Might")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentCreature = new CardList(OpponentPlay.getCards()); - OpponentCreature = OpponentCreature.getType("Creature"); - if(OpponentCreature.size() - PlayerCreature.size() >= 4) { - ManaCost cost2 = new ManaCost("G G"); - cost = cost2; - } - } // Avatar of Might - else if(originalCard.getName().equals("Khalni Hydra")) { - String player = AllZone.Phase.getActivePlayer(); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerCreature = PlayerCreature.filter(new CardListFilter() { - public boolean addCard(Card c) { - return c.isCreature() && CardUtil.getColors(c).contains(Constant.Color.Green); - } - }); - String Mana = cost + " "; - if(PlayerCreature.size() > 0) { - for(int i = 0; i < PlayerCreature.size(); i++) { - Mana = Mana.replaceFirst("G ", ""); - } - Mana = Mana.trim(); - if(Mana.equals("")) Mana = "0"; - ManaCost cost2 = new ManaCost(Mana); - cost = cost2; - } - } // Khalni Hydra - } // is Spell + cost = AllZone.GameAction.GetSpellCostChange(sa); ArrayList colors; for(int i = 0; i < land.size(); i++) @@ -302,81 +230,8 @@ public class ComputerUtil { land.remove(sa.getSourceCard()); } - - Card originalCard = sa.getSourceCard(); ManaCost cost = new ManaCost(sa.getManaCost()); - if(sa.isSpell() == true) { - if(originalCard.getName().equals("Avatar of Woe")){ - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerGraveyard = AllZone.getZone(Constant.Zone.Graveyard, player); - CardList PlayerCreatureList = new CardList(PlayerGraveyard.getCards()); - PlayerCreatureList = PlayerCreatureList.getType("Creature"); - PlayerZone OpponentGraveyard = AllZone.getZone(Constant.Zone.Graveyard, opponent); - CardList OpponentCreatureList = new CardList(OpponentGraveyard.getCards()); - OpponentCreatureList = OpponentCreatureList.getType("Creature"); - if((PlayerCreatureList.size() + OpponentCreatureList.size()) >= 10) { - ManaCost cost2 = new ManaCost("B B"); - cost = cost2; - } - } // Avatar of Woe - else if(originalCard.getName().equals("Avatar of Will")){ - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentHand = AllZone.getZone(Constant.Zone.Hand, opponent); - CardList OpponentHandList = new CardList(OpponentHand.getCards()); - if(OpponentHandList.size() == 0) { - ManaCost cost2 = new ManaCost("U U"); - cost = cost2; - } - } // Avatar of Will - else if(originalCard.getName().equals("Avatar of Fury")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentLand = new CardList(OpponentPlay.getCards()); - OpponentLand = OpponentLand.getType("Land"); - if(OpponentLand.size() >= 7) { - ManaCost cost2 = new ManaCost("R R"); - cost = cost2; - } - } // Avatar of Fury - else if(originalCard.getName().equals("Avatar of Might")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentCreature = new CardList(OpponentPlay.getCards()); - OpponentCreature = OpponentCreature.getType("Creature"); - if(OpponentCreature.size() - PlayerCreature.size() >= 4) { - ManaCost cost2 = new ManaCost("G G"); - cost = cost2; - } - } // Avatar of Might - else if(originalCard.getName().equals("Khalni Hydra")) { - String player = AllZone.Phase.getActivePlayer(); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerCreature = PlayerCreature.filter(new CardListFilter() { - public boolean addCard(Card c) { - return c.isCreature() && CardUtil.getColors(c).contains(Constant.Color.Green); - } - }); - String Mana = cost + " "; - if(PlayerCreature.size() > 0) { - for(int i = 0; i < PlayerCreature.size(); i++) { - Mana = Mana.replaceFirst("G ", ""); - } - Mana = Mana.trim(); - if(Mana.equals("")) Mana = "0"; - ManaCost cost2 = new ManaCost(Mana); - cost = cost2; - } - } // Khalni Hydra - } // is Spell + cost = AllZone.GameAction.GetSpellCostChange(sa); ArrayList colors; for(int i = 0; i < land.size(); i++) diff --git a/src/forge/GameAction.java b/src/forge/GameAction.java index 25cf8dfc614..bf3eb3e1c3c 100644 --- a/src/forge/GameAction.java +++ b/src/forge/GameAction.java @@ -1175,6 +1175,7 @@ public class GameAction { AllZone.Stack.reset();//this works, it clears the stack of Upkeep effects like Bitterblossom AllZone.InputControl.setInput(new Input_Mulligan()); + Phase.GameBegins = 1; }//newGame() //this is where the computer cheats @@ -1544,14 +1545,280 @@ public class GameAction { } } + int CostCutting_GetMultiMickerManaCostPaid = 0; + String CostCutting_GetMultiMickerManaCostPaid_Colored = ""; + public ManaCost GetSpellCostChange(SpellAbility sa) { + // Beached + Card originalCard = sa.getSourceCard(); + ManaCost manaCost; + SpellAbility spell = sa; + manaCost = new ManaCost(sa.getManaCost()); + if(spell.isSpell() == true) { + if(originalCard.getName().equals("Avatar of Woe")){ + String player = AllZone.Phase.getActivePlayer(); + String opponent = AllZone.GameAction.getOpponent(player); + PlayerZone PlayerGraveyard = AllZone.getZone(Constant.Zone.Graveyard, player); + CardList PlayerCreatureList = new CardList(PlayerGraveyard.getCards()); + PlayerCreatureList = PlayerCreatureList.getType("Creature"); + PlayerZone OpponentGraveyard = AllZone.getZone(Constant.Zone.Graveyard, opponent); + CardList OpponentCreatureList = new CardList(OpponentGraveyard.getCards()); + OpponentCreatureList = OpponentCreatureList.getType("Creature"); + if((PlayerCreatureList.size() + OpponentCreatureList.size()) >= 10) { + manaCost = new ManaCost("B B"); + } // Avatar of Woe + } else if(originalCard.getName().equals("Avatar of Will")) { + String player = AllZone.Phase.getActivePlayer(); + String opponent = AllZone.GameAction.getOpponent(player); + PlayerZone OpponentHand = AllZone.getZone(Constant.Zone.Hand, opponent); + CardList OpponentHandList = new CardList(OpponentHand.getCards()); + if(OpponentHandList.size() == 0) { + manaCost = new ManaCost("U U"); + } // Avatar of Will + } else if(originalCard.getName().equals("Avatar of Fury")) { + String player = AllZone.Phase.getActivePlayer(); + String opponent = AllZone.GameAction.getOpponent(player); + PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); + CardList OpponentLand = new CardList(OpponentPlay.getCards()); + OpponentLand = OpponentLand.getType("Land"); + if(OpponentLand.size() >= 7) { + manaCost = new ManaCost("R R"); + } // Avatar of Fury + } else if(originalCard.getName().equals("Avatar of Might")) { + String player = AllZone.Phase.getActivePlayer(); + String opponent = AllZone.GameAction.getOpponent(player); + PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); + CardList PlayerCreature = new CardList(PlayerPlay.getCards()); + PlayerCreature = PlayerCreature.getType("Creature"); + PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); + CardList OpponentCreature = new CardList(OpponentPlay.getCards()); + OpponentCreature = OpponentCreature.getType("Creature"); + if(OpponentCreature.size() - PlayerCreature.size() >= 4) { + manaCost = new ManaCost("G G"); + } // Avatar of Might + } + } // isSpell + + // Get Cost Reduction + if(Phase.GameBegins == 1) { // Remove GameBegins from Phase and into The starting game code + CardList Cards_In_Play = new CardList(); + Cards_In_Play.addAll(AllZone.getZone(Constant.Zone.Play, Constant.Player.Human).getCards()); + Cards_In_Play.addAll(AllZone.getZone(Constant.Zone.Play, Constant.Player.Computer).getCards()); + Cards_In_Play = Cards_In_Play.filter(new CardListFilter() { + public boolean addCard(Card c) { + if(c.getKeyword().toString().contains("CostChange")) return true; + return false; + } + }); + String Mana = manaCost.toString(); + CardList Player_Play = new CardList(AllZone.getZone(Constant.Zone.Play, sa.getSourceCard().getController()).getCards()); + int XBonus = 0; + int Max = 25; + if(sa.isXCost()) sa.getSourceCard().setXManaCostPaid(0); + if(sa.isMultiKicker()) CostCutting_GetMultiMickerManaCostPaid_Colored = ""; + if(Mana.toString().length() == 0) Mana = "0"; + for(int i = 0; i < Cards_In_Play.size() ; i++) { + Card card = Cards_In_Play.get(i); + ArrayList a = card.getKeyword(); + int CostKeywords = 0; + int CostKeyword_Number[] = new int[a.size()]; + for(int x = 0; x < a.size(); x++) + if(a.get(x).toString().startsWith("CostChange")) { + CostKeyword_Number[CostKeywords] = x; + CostKeywords = CostKeywords + 1; + } + for(int CKeywords = 0; CKeywords < CostKeywords; CKeywords++) { + String parse = card.getKeyword().get(CostKeyword_Number[CKeywords]).toString(); + String k[] = parse.split(":"); + + if(k[2].equals("More")) { + if(k[7].equals("OnlyOneBonus")) { // Only Works for Color and Type + for(int string_no = 5; string_no < 7; string_no++) { + String spilt = k[string_no]; + String color_spilt[] = spilt.split("/"); + + for(int cs_num = 0; cs_num < color_spilt.length; cs_num++) { + k[string_no] = color_spilt[cs_num]; + if(string_no == 5 && CardUtil.getColors(sa.getSourceCard()).contains(k[5])) break; + if(string_no == 6 && (sa.getSourceCard().getType().contains(k[6]))) break; + } + } + } + if((k[1].equals("Player") && card.getController().equals(sa.getSourceCard().getController()) + || (k[1].equals("Opponent") && card.getController().equals(AllZone.GameAction.getOpponent(sa.getSourceCard().getController()))) || k[1].equals("All")) + && ((k[4].equals("Spell") && sa.isSpell() == true) || (k[4].equals("Ability") && sa.isAbility() == true) || k[4].equals("All")) + && ((CardUtil.getColors(sa.getSourceCard()).contains(k[5])) || k[5].equals("All")) + && ((sa.getSourceCard().getType().contains(k[6])) || k[6].equals("All"))) { + if(k[7].equals("CardIsTapped")) { + if(card.isTapped() == false) k[3] = "0"; + } + if(k[7].equals("TargetInPlay")) { + if(Player_Play.contains(sa.getSourceCard())) k[3] = "0"; + } + String[] Numbers = new String[Max]; + if(!"WUGRB".contains(k[3])) { + for(int no = 0; no < Max; no ++) Numbers[no] = String.valueOf(no); + String Number_ManaCost = " "; + if(Mana.toString().length() == 1) Number_ManaCost = Mana.toString().substring(0, 1); + else if(Mana.toString().length() == 0) Number_ManaCost = "0"; // Should Never Occur + else Number_ManaCost = Mana.toString().substring(0, 2); + Number_ManaCost = Number_ManaCost.trim(); + + for(int check = 0; check < Max; check ++) { + if(Number_ManaCost.equals(Numbers[check])) { + Mana = Mana.replaceFirst(String.valueOf(check),String.valueOf(check + Integer.valueOf(k[3]))); + } + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + if(manaCost.toString().equals("W") || manaCost.toString().equals("U") || manaCost.toString().equals("G") + || manaCost.toString().equals("B") || manaCost.toString().equals("R")) { + Mana = k[3] + " " + Mana; + manaCost = new ManaCost(Mana); + } + } else { + Mana = Mana + " " + k[3]; + manaCost = new ManaCost(Mana); + } + } + } + } + } + if(Mana.equals("0") && spell.isAbility()) { + } else { + for(int i = 0; i < Cards_In_Play.size() ; i++) { + Card card = Cards_In_Play.get(i); + ArrayList a = card.getKeyword(); + int CostKeywords = 0; + int CostKeyword_Number[] = new int[a.size()]; + for(int x = 0; x < a.size(); x++) + if(a.get(x).toString().startsWith("CostChange")) { + CostKeyword_Number[CostKeywords] = x; + CostKeywords = CostKeywords + 1; + } + for(int CKeywords = 0; CKeywords < CostKeywords; CKeywords++) { + String parse = card.getKeyword().get(CostKeyword_Number[CKeywords]).toString(); + String k[] = parse.split(":"); + + if(k[2].equals("Less")) { + if(k[7].equals("OnlyOneBonus")) { // Only Works for Color and Type + for(int string_no = 5; string_no < 7; string_no++) { + String spilt = k[string_no]; + String color_spilt[] = spilt.split("/"); + + for(int cs_num = 0; cs_num < color_spilt.length; cs_num++) { + k[string_no] = color_spilt[cs_num]; + if(string_no == 5 && CardUtil.getColors(sa.getSourceCard()).contains(k[5])) break; + if(string_no == 6 && (sa.getSourceCard().getType().contains(k[6]))) break; + } + } + } + if((k[1].equals("Player") && card.getController().equals(sa.getSourceCard().getController()) + || (k[1].equals("Opponent") && card.getController().equals(AllZone.GameAction.getOpponent(sa.getSourceCard().getController()))) || k[1].equals("All")) + && ((k[4].equals("Spell") && sa.isSpell() == true) || (k[4].equals("Ability") && sa.isAbility() == true) || k[4].equals("All")) + && ((CardUtil.getColors(sa.getSourceCard()).contains(k[5])) || k[5].equals("All")) + && ((sa.getSourceCard().getType().contains(k[6])) || k[6].equals("All"))) { + if(k[7].equals("CardIsTapped")) { + if(card.isTapped() == false) k[3] = "0"; + } + if(k[7].equals("TargetInPlay")) { + if(Player_Play.contains(sa.getSourceCard())) k[3] = "0"; + } + + + String[] Numbers = new String[Max]; + if(!"WUGRB".contains(k[3])) { + for(int no = 0; no < Max; no ++) Numbers[no] = String.valueOf(no); + String Number_ManaCost = " "; + if(Mana.toString().length() == 1) Number_ManaCost = Mana.toString().substring(0, 1); + else if(Mana.toString().length() == 0) Number_ManaCost = "0"; // Should Never Occur + else Number_ManaCost = Mana.toString().substring(0, 2); + Number_ManaCost = Number_ManaCost.trim(); + + for(int check = 0; check < Max; check ++) { + if(Number_ManaCost.equals(Numbers[check])) { + if((spell.isXCost()) || (spell.isMultiKicker()) && (check - Integer.valueOf(k[3])) < 0) XBonus = XBonus - check + Integer.valueOf(k[3]); + if(check - Integer.valueOf(k[3]) < 0) k[3] = String.valueOf(check); + Mana = Mana.replaceFirst(String.valueOf(check),String.valueOf(check - Integer.valueOf(k[3]))); + } + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + } else { + if(Mana.equals(Mana.replaceFirst(k[3], ""))) { + // if(sa.isXCost()) sa.getSourceCard().addXManaCostPaid(1); Not Included as X Costs are not in Colored Mana + if(sa.isMultiKicker()) CostCutting_GetMultiMickerManaCostPaid_Colored = CostCutting_GetMultiMickerManaCostPaid_Colored + k[3]; + } else { + Mana = Mana.replaceFirst(k[3], ""); + Mana = Mana.trim(); + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + } + } + Mana = Mana.trim(); + if(Mana.equals("")) { + if(sa.isSpell()) Mana = "0"; + else { + Mana = "1"; + } + } + } + manaCost = new ManaCost(Mana); + } + } + } + + if(sa.isXCost()) { + + for(int XPaid = 0; XPaid < XBonus; XPaid++) sa.getSourceCard().addXManaCostPaid(1); + } + if(sa.isMultiKicker()) { + CostCutting_GetMultiMickerManaCostPaid = 0; + for(int XPaid = 0; XPaid < XBonus; XPaid++) CostCutting_GetMultiMickerManaCostPaid = CostCutting_GetMultiMickerManaCostPaid + 1; + } + /** + if(sa.isMultiKicker()) { + for(int XPaid = 0; XPaid < XBonus ; XPaid++) { + // AllZone.ManaPool.has = AllZone.ManaPool.has.replaceFirst("1", ""); + AllZone.ManaPool.addMana("1");; + } + } + **/ + + } + if(originalCard.getName().equals("Khalni Hydra") && spell.isSpell() == true) { + String player = AllZone.Phase.getActivePlayer(); + PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); + CardList PlayerCreature = new CardList(PlayerPlay.getCards()); + PlayerCreature = PlayerCreature.getType("Creature"); + PlayerCreature = PlayerCreature.filter(new CardListFilter() { + public boolean addCard(Card c) { + return c.isCreature() && CardUtil.getColors(c).contains(Constant.Color.Green); + } + }); + String Mana = manaCost + " "; + if(PlayerCreature.size() > 0) { + for(int i = 0; i < PlayerCreature.size(); i++) { + Mana = Mana.replaceFirst("G ", ""); + } + Mana = Mana.trim(); + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + } // Khalni Hydra + return manaCost; + } + public void playSpellAbility(SpellAbility sa) { - if(sa.getManaCost().equals("0") && sa.getBeforePayMana() == null) { + ManaCost manaCost = GetSpellCostChange(sa); + if(manaCost.isPaid() /**sa.getManaCost().equals("0")**/ && sa.getBeforePayMana() == null) { + CardList HHandList = new CardList(AllZone.getZone(Constant.Zone.Hand, Constant.Player.Human).getCards()); + if(HHandList.contains(sa.getSourceCard())) AllZone.Human_Hand.remove(sa.getSourceCard()); AllZone.Stack.add(sa); if(sa.isTapAbility() && !sa.wasCancelled()) sa.getSourceCard().tap(); if(sa.isUntapAbility()) sa.getSourceCard().untap(); return; } - if(sa.getBeforePayMana() == null) AllZone.InputControl.setInput(new Input_PayManaCost(sa)); else AllZone.InputControl.setInput(sa.getBeforePayMana()); } diff --git a/src/forge/GameActionUtil.java b/src/forge/GameActionUtil.java index 7bd0ca40bef..6c97ab899b2 100644 --- a/src/forge/GameActionUtil.java +++ b/src/forge/GameActionUtil.java @@ -9872,6 +9872,126 @@ public class GameActionUtil { }// execute() }; + public static Command Goblin_Warchief = new Command() { + + private static final long serialVersionUID = -6707183535529395830L; + CardList gloriousAnthemList = new CardList(); + String[] Akroma_Memorial_Controller = new String[10]; // Shouldn't have more than 8 in play, let alone 10. + public void execute() { + String keyword = "Haste"; + CardList list = gloriousAnthemList; + Card c; + + CardList Akroma_List = AllZoneUtil.getCardsInPlay("Goblin Warchief"); + CardList Akroma_Zone = new CardList(); + for(int i = 0; i < Akroma_List.size(); i++) { + Akroma_Zone.clear(); + Akroma_Zone.addAll(AllZone.getZone(Constant.Zone.Play, Akroma_List.get(i).getController()).getCards()); + } + CardList List_Copy = new CardList(); + List_Copy.add(list); + for(int i = 0; i < List_Copy.size(); i++) { + c = List_Copy.get(i); + if(!Akroma_Zone.contains(c)) { + c.removeExtrinsicKeyword(keyword); + list.remove(c); + } + } + + PlayerZone[] zone = getZone("Goblin Warchief"); + if(AllZoneUtil.isCardInPlay("Goblin Warchief")) { + CardList ControllerCheck = AllZoneUtil.getCardsInPlay("Goblin Warchief"); + for(int i = 0; i < ControllerCheck.size(); i++) Akroma_Memorial_Controller[i] = ControllerCheck.get(i).getController(); + for(int outer = 0; outer < zone.length; outer++) { + CardList creature = new CardList( + zone[outer].getCards()); + creature = creature.getType("Creature"); + + for(int i = 0; i < creature.size(); i++) { + c = creature.get(i); + if(!list.contains(c)) { + gloriousAnthemList.add(c); + + if(!c.getIntrinsicKeyword().contains(keyword)) { + c.addExtrinsicKeyword(keyword); + } + } + }// for inner + }// for outer + } + }// execute() +/** + public void execute() { + String keyword = "Haste"; + + CardList list = gloriousAnthemList; + Card c; + // reset all cards in list - aka "old" cards + for(int i = 0; i < list.size(); i++) { + c = list.get(i); + c.removeExtrinsicKeyword(keyword); + } + + list.clear(); + PlayerZone[] zone = getZone("Goblin Warchief"); + + for(int outer = 0; outer < zone.length; outer++) { + CardList creature = new CardList( + zone[outer].getCards()); + creature = creature.getType("Creature"); + + for(int i = 0; i < creature.size(); i++) { + c = creature.get(i); + if(!c.getKeyword().contains(keyword)) { + c.addExtrinsicKeyword(keyword); + gloriousAnthemList.add(c); + } + }// for inner + }// for outer + }// execute() + **/ + }; + + public static Command Undead_Warchief = new Command() { + private static final long serialVersionUID = -3463429634177142721L; + + CardList gloriousAnthemList = new CardList(); + + public void execute() { + int pumpAttack = 2; + int pumpDefense = 1; + + CardList list = gloriousAnthemList; + Card c; + // reset all cards in list - aka "old" cards + for(int i = 0; i < list.size(); i++) { + c = list.get(i); + c.addSemiPermanentAttackBoost(-pumpAttack); + c.addSemiPermanentDefenseBoost(-pumpDefense); + } + + // add +1/+1 to cards + list.clear(); + PlayerZone[] zone = getZone("Undead Warchief"); + + // for each zone found add +1/+1 to each card + for(int outer = 0; outer < zone.length; outer++) { + CardList creature = new CardList(); + creature.addAll(AllZone.Human_Play.getCards()); + creature.addAll(AllZone.Computer_Play.getCards()); + creature = creature.getType("Zombie"); + + for(int i = 0; i < creature.size(); i++) { + c = creature.get(i); + c.addSemiPermanentAttackBoost(pumpAttack); + c.addSemiPermanentDefenseBoost(pumpDefense); + + gloriousAnthemList.add(c); + }// for inner + }// for outer + }// execute() + }; // Undead Warchief + public static Command Leyline_of_Singularity = new Command() { private static final long serialVersionUID = -67071835355151830L; @@ -18257,6 +18377,8 @@ public class GameActionUtil { commands.put("Darksteel_Forge", Darksteel_Forge); commands.put("Akromas_Memorial", Akromas_Memorial); commands.put("Leyline_of_Singularity", Leyline_of_Singularity); + commands.put("Goblin_Warchief", Goblin_Warchief); + commands.put("Undead_Warchief", Undead_Warchief); commands.put("Levitation", Levitation); commands.put("Knighthood", Knighthood); commands.put("Absolute_Law", Absolute_Law); diff --git a/src/forge/Gui_WinLose.java b/src/forge/Gui_WinLose.java index 59d4a1b763b..84574b8debd 100644 --- a/src/forge/Gui_WinLose.java +++ b/src/forge/Gui_WinLose.java @@ -120,7 +120,7 @@ public class Gui_WinLose extends JFrame implements NewConstants { private void setup() { WinLose winLose = Constant.Runtime.WinLose; - + Phase.GameBegins = 0; //3 is the match length, 3 is the number of games //disable buttons if match is up, or human player won 2 or lost 2 games already if((winLose.countWinLose() == 3) || (winLose.getWin() == 2) || (winLose.getLose() == 2)) { diff --git a/src/forge/InputUtil.java b/src/forge/InputUtil.java index 134a8f2f72c..e3e000a0dd9 100644 --- a/src/forge/InputUtil.java +++ b/src/forge/InputUtil.java @@ -46,12 +46,14 @@ public class InputUtil AllZone.GameInfo.setHumanPlayedFirstLandThisTurn(true); } } //land + /** else if(zone.is(Constant.Zone.Hand, Constant.Player.Human) && card.getManaCost().equals("0"))//for Mox Ruby and the like { AllZone.Human_Hand.remove(card); AllZone.Stack.add(card.getSpellAbility()[0]); } + **/ else if (zone.is(Constant.Zone.Hand, Constant.Player.Human) || zone.is(Constant.Zone.Play, Constant.Player.Human) || (zone.is(Constant.Zone.Play, Constant.Player.Computer)) && (card.isEquipment() || card.isAura()) && card.getController().equals(Constant.Player.Human) ) AllZone.GameAction.playCard(card); diff --git a/src/forge/Input_PayManaCost.java b/src/forge/Input_PayManaCost.java index 34d00cda1fd..31340d9a803 100644 --- a/src/forge/Input_PayManaCost.java +++ b/src/forge/Input_PayManaCost.java @@ -19,90 +19,15 @@ public class Input_PayManaCost extends Input { private final SpellAbility spell; public Input_PayManaCost(SpellAbility sa) { - originalManaCost = sa.getManaCost(); + originalManaCost = sa.getSourceCard().getManaCost(); originalCard = sa.getSourceCard(); - + spell = sa; - if(spell.isSpell() == true) { - if(originalCard.getName().equals("Avatar of Woe")){ - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerGraveyard = AllZone.getZone(Constant.Zone.Graveyard, player); - CardList PlayerCreatureList = new CardList(PlayerGraveyard.getCards()); - PlayerCreatureList = PlayerCreatureList.getType("Creature"); - PlayerZone OpponentGraveyard = AllZone.getZone(Constant.Zone.Graveyard, opponent); - CardList OpponentCreatureList = new CardList(OpponentGraveyard.getCards()); - OpponentCreatureList = OpponentCreatureList.getType("Creature"); - if((PlayerCreatureList.size() + OpponentCreatureList.size()) >= 10) { - manaCost = new ManaCost("B B"); - } else { - manaCost = new ManaCost(sa.getManaCost()); - } // Avatar of Woe - } else if(originalCard.getName().equals("Avatar of Will")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentHand = AllZone.getZone(Constant.Zone.Hand, opponent); - CardList OpponentHandList = new CardList(OpponentHand.getCards()); - if(OpponentHandList.size() == 0) { - manaCost = new ManaCost("U U"); - } else { - manaCost = new ManaCost(sa.getManaCost()); - } // Avatar of Will - } else if(originalCard.getName().equals("Avatar of Fury")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentLand = new CardList(OpponentPlay.getCards()); - OpponentLand = OpponentLand.getType("Land"); - if(OpponentLand.size() >= 7) { - manaCost = new ManaCost("R R"); - } else { - manaCost = new ManaCost(sa.getManaCost()); - } // Avatar of Fury - } else if(originalCard.getName().equals("Avatar of Might")) { - String player = AllZone.Phase.getActivePlayer(); - String opponent = AllZone.GameAction.getOpponent(player); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerZone OpponentPlay = AllZone.getZone(Constant.Zone.Play, opponent); - CardList OpponentCreature = new CardList(OpponentPlay.getCards()); - OpponentCreature = OpponentCreature.getType("Creature"); - if(OpponentCreature.size() - PlayerCreature.size() >= 4) { - manaCost = new ManaCost("G G"); - } else { - manaCost = new ManaCost(sa.getManaCost()); - } // Avatar of Might - } else if(originalCard.getName().equals("Khalni Hydra")) { - String player = AllZone.Phase.getActivePlayer(); - PlayerZone PlayerPlay = AllZone.getZone(Constant.Zone.Play, player); - CardList PlayerCreature = new CardList(PlayerPlay.getCards()); - PlayerCreature = PlayerCreature.getType("Creature"); - PlayerCreature = PlayerCreature.filter(new CardListFilter() { - public boolean addCard(Card c) { - return c.isCreature() && CardUtil.getColors(c).contains(Constant.Color.Green); - } - }); - String Mana = originalManaCost + " "; - if(PlayerCreature.size() > 0) { - for(int i = 0; i < PlayerCreature.size(); i++) { - Mana = Mana.replaceFirst("G ", ""); - } - Mana = Mana.trim(); - if(Mana.equals("")) Mana = "0"; - manaCost = new ManaCost(Mana); - } else { - manaCost = new ManaCost(sa.getManaCost()); - } - } // Khalni Hydra - // For all other Spells - else { + manaCost = new ManaCost(sa.getManaCost()); - } - } // isSpell - else { - manaCost = new ManaCost(sa.getManaCost()); - } + if(Phase.GameBegins == 1) { + manaCost = AllZone.GameAction.GetSpellCostChange(sa); + } } private void resetManaCost() { diff --git a/src/forge/MagicStack.java b/src/forge/MagicStack.java index c27712ace18..023e45162ea 100644 --- a/src/forge/MagicStack.java +++ b/src/forge/MagicStack.java @@ -29,6 +29,55 @@ public class MagicStack extends MyObservable } } + public ManaCost GetMultiKickerSpellCostChange(SpellAbility sa) { + int Max = 25; + String[] Numbers = new String[Max]; + for(int no = 0; no < Max; no ++) Numbers[no] = String.valueOf(no); + ManaCost manaCost = new ManaCost(sa.getManaCost()); + String Mana = manaCost.toString(); + int MultiKickerPaid = AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid; + for(int no = 0; no < Max; no ++) Numbers[no] = String.valueOf(no); + String Number_ManaCost = " "; + if(Mana.toString().length() == 1) Number_ManaCost = Mana.toString().substring(0, 1); + else if(Mana.toString().length() == 0) Number_ManaCost = "0"; // Should Never Occur + else Number_ManaCost = Mana.toString().substring(0, 2); + Number_ManaCost = Number_ManaCost.trim(); + + + for(int check = 0; check < Max; check ++) { + if(Number_ManaCost.equals(Numbers[check])) { + + if(check - MultiKickerPaid < 0) { + MultiKickerPaid = MultiKickerPaid - check; + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid = MultiKickerPaid; + Mana = Mana.replaceFirst(String.valueOf(check),"0"); + } else { + Mana = Mana.replaceFirst(String.valueOf(check),String.valueOf(check - MultiKickerPaid)); + MultiKickerPaid = 0; + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid = MultiKickerPaid; + } + } + Mana = Mana.trim(); + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + String Color_cut = AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored; + + for(int Colored_Cut = 0; Colored_Cut < Color_cut.length(); Colored_Cut++) { + if("WUGRB".contains(Color_cut.substring(Colored_Cut, Colored_Cut + 1))) { + if(!Mana.equals(Mana.replaceFirst((Color_cut.substring(Colored_Cut, Colored_Cut + 1)), ""))) { + Mana = Mana.replaceFirst(Color_cut.substring(Colored_Cut, Colored_Cut + 1), ""); + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored = AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored.replaceFirst(Color_cut.substring(Colored_Cut, Colored_Cut + 1), ""); + Mana = Mana.trim(); + if(Mana.equals("")) Mana = "0"; + manaCost = new ManaCost(Mana); + } + } + } + + return manaCost; + } + public void add(SpellAbility sp) { if(sp instanceof Ability_Mana || sp instanceof Ability_Triggered)//TODO make working triggered abilities! @@ -64,17 +113,17 @@ public class MagicStack extends MyObservable private static final long serialVersionUID = -2224875229611007788L; public void execute() { - ability.resolve(); - Card crd = sa.getSourceCard(); - AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Pay X cost for " + crd.getName() + " (X=" +crd.getXManaCostPaid()+")\r\n", - ability.getManaCost(), this, unpaidCommand, true)); - } - }; - - if(sp.getSourceCard().getController().equals(Constant.Player.Human)) { - AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Pay X cost for " + sp.getSourceCard().getName() + " (X=0)\r\n", - ability.getManaCost(), paidCommand, unpaidCommand, true)); - } + ability.resolve(); + Card crd = sa.getSourceCard(); + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Pay X cost for " + crd.getName() + " (X=" +crd.getXManaCostPaid()+")\r\n", + ability.getManaCost(), this, unpaidCommand, true)); + } + }; + Card crd = sa.getSourceCard(); + if(sp.getSourceCard().getController().equals(Constant.Player.Human)) { + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Pay X cost for " + sp.getSourceCard().getName() + " (X=" +crd.getXManaCostPaid()+")\r\n", + ability.getManaCost(), paidCommand, unpaidCommand, true)); + } else //computer { int neededDamage = CardFactoryUtil.getNeededXDamage(sa); @@ -112,14 +161,47 @@ public class MagicStack extends MyObservable private static final long serialVersionUID = -6037161763374971106L; public void execute() { ability.resolve(); - AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sa.getSourceCard() + "\r\n", - ability.getManaCost(), this, unpaidCommand)); + ManaCost manaCost = GetMultiKickerSpellCostChange(ability); + if(manaCost.isPaid()) { + this.execute(); + } else { + if(AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid == 0 + && AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored.equals("")) { + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sa.getSourceCard() + "\r\n" + + "Times Kicked: " + sa.getSourceCard().getMultiKickerMagnitude() + "\r\n", + manaCost.toString(), this, unpaidCommand)); + } else { + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sa.getSourceCard() + "\r\n" + + "Mana in Reserve: " + ((AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid != 0)? + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid:"") + + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored + "\r\n" + + "Times Kicked: " + sa.getSourceCard().getMultiKickerMagnitude() + "\r\n", + manaCost.toString(), this, unpaidCommand)); + } + } } }; if(sp.getSourceCard().getController().equals(Constant.Player.Human)) { - AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sp.getSourceCard() + "\r\n", - ability.getManaCost(), paidCommand, unpaidCommand)); + ManaCost manaCost = GetMultiKickerSpellCostChange(ability); + + if(manaCost.isPaid()) { + paidCommand.execute(); + } else { + if(AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid == 0 + && AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored.equals("")) { + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sa.getSourceCard() + "\r\n" + + "Times Kicked: " + sa.getSourceCard().getMultiKickerMagnitude() + "\r\n", + manaCost.toString(), paidCommand, unpaidCommand)); + } else { + AllZone.InputControl.setInput(new Input_PayManaCost_Ability("Multikicker for " + sa.getSourceCard() + "\r\n" + + "Mana in Reserve: " + ((AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid != 0)? + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid:"") + + AllZone.GameAction.CostCutting_GetMultiMickerManaCostPaid_Colored + "\r\n" + + "Times Kicked: " + sa.getSourceCard().getMultiKickerMagnitude() + "\r\n", + manaCost.toString(), paidCommand, unpaidCommand)); + } + } } else //computer { diff --git a/src/forge/Phase.java b/src/forge/Phase.java index 828cc34242a..9036905fd1c 100644 --- a/src/forge/Phase.java +++ b/src/forge/Phase.java @@ -234,6 +234,7 @@ public class Phase extends MyObservable //if(getPhase().equals(Constant.Phase.Untap)) { if(is(Constant.Phase.Untap, Constant.Player.Human)) { StormCount = 0; + HighTideCount = 0; PlayerSpellCount = 0; PlayerCreatureSpellCount = 0; @@ -265,8 +266,7 @@ public class Phase extends MyObservable */ } if(is(Constant.Phase.Main1, Constant.Player.Human)) { - if(turn == 1) { - GameBegins = 1; // Omnath + if(turn == 1) { StormCount = 0; PlayerSpellCount = 0; PlayerCreatureSpellCount = 0; diff --git a/src/forge/StaticEffects.java b/src/forge/StaticEffects.java index 2331d33d76d..cd7f268c3fc 100644 --- a/src/forge/StaticEffects.java +++ b/src/forge/StaticEffects.java @@ -162,6 +162,8 @@ public class StaticEffects cardToEffectsList.put("Darksteel Forge", new String[] {"Darksteel_Forge"} ); cardToEffectsList.put("Akroma's Memorial", new String[] {"Akromas_Memorial"}); cardToEffectsList.put("Leyline of Singularity", new String[] {"Leyline_of_Singularity"}); + cardToEffectsList.put("Goblin Warchief", new String[] {"Goblin_Warchief"}); + cardToEffectsList.put("Undead Warchief", new String[] {"Undead_Warchief"}); cardToEffectsList.put("Levitation", new String[] {"Levitation"}); cardToEffectsList.put("Knighthood", new String[] {"Knighthood"}); cardToEffectsList.put("Absolute Law", new String[] {"Absolute_Law"});