diff --git a/Mage.Client/pom.xml b/Mage.Client/pom.xml index 1263c097b42..04b1642260a 100644 --- a/Mage.Client/pom.xml +++ b/Mage.Client/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 org.mage diff --git a/Mage.Client/release/sample-decks/Commander/Zurgo Helmsmasher RWB.dck b/Mage.Client/release/sample-decks/Commander/Zurgo Helmsmasher RWB.dck new file mode 100644 index 00000000000..2e5fce7b615 --- /dev/null +++ b/Mage.Client/release/sample-decks/Commander/Zurgo Helmsmasher RWB.dck @@ -0,0 +1,90 @@ +1 [M15:36] Spectra Ward +1 [MBS:43] Go for the Throat +1 [8ED:204] Obliterate +1 [BNG:4] Archetype of Courage +1 [EVE:176] Fetid Heath +1 [AVR:6] Avacyn, Angel of Hope +1 [10E:61] Wrath of God +1 [CHK:283] Shizo, Death's Storehouse +1 [M11:221] Whispersilk Cloak +1 [PLC:85] Damnation +1 [M15:110] Ob Nixilis, Unshackled +1 [M15:100] In Garruk's Wake +1 [M14:210] Fireshrieker +1 [AVR:209] Gisela, Blade of Goldnight +1 [M12:160] Warstorm Surge +1 [BNG:93] Fall of the Hammer +1 [TSB:117] Arena +5 [ORI:261] Swamp +1 [GTC:17] Holy Mantle +1 [M15:225] Phyrexian Revoker +1 [TOR:139] Cabal Coffers +1 [NPH:9] Elesh Norn, Grand Cenobite +1 [BNG:58] Archetype of Finality +1 [MBS:39] Black Sun's Zenith +1 [M12:98] Grave Titan +1 [GTC:245] Sacred Foundry +1 [ALA:217] Quietus Spike +1 [WWK:20] Stoneforge Mystic +1 [M12:12] Day of Judgment +1 [ULG:63] Phyrexian Reclamation +1 [GTC:242] Godless Shrine +4 [ORI:265] Mountain +1 [GTC:6] Blind Obedience +1 [M14:1] Ajani, Caller of the Pride +1 [M12:109] Sorin Markov +1 [M12:147] Inferno Titan +1 [ICE:278] Swords to Plowshares +1 [CMD:269] Command Tower +1 [M12:222] Worldslayer +1 [M15:133] Burning Anger +1 [ORI:250] Rogue's Passage +1 [10E:359] Sulfurous Springs +1 [M14:209] Elixir of Immortality +1 [GTC:61] Crypt Ghast +1 [BNG:151] Mogis, God of Slaughter +4 [ORI:253] Plains +1 [M12:39] Sun Titan +1 [CHK:268] Sensei's Divining Top +1 [SOM:25] True Conviction +1 [THS:187] Ashen Rider +1 [9ED:152] Phyrexian Arena +1 [AVR:86] Blood Artist +1 [SHM:278] Reflecting Pool +1 [SHM:272] Graven Cairns +1 [M13:222] Dragonskull Summit +1 [THS:227] Temple of Silence +1 [THS:228] Temple of Triumph +1 [3ED:274] Sol Ring +1 [MOR:24] Stonehewer Giant +1 [NPH:73] Sheoldred, Whispering One +1 [C13:310] Opal Palace +1 [CON:15] Path to Exile +1 [ZEN:208] Trailblazer's Boots +1 [ISD:242] Isolated Chapel +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [ZEN:203] Grappling Hook +1 [ORI:244] Battlefield Forge +1 [ORI:245] Caves of Koilos +1 [3ED:13] Demonic Tutor +1 [GTC:143] Aurelia, the Warleader +1 [AVR:36] Silverblade Paladin +1 [THS:85] Erebos, God of the Dead +1 [LRW:3] Austere Command +1 [ULG:14] Mother of Runes +1 [ALA:154] Ajani Vengeant +1 [ZEN:131] Hellkite Charger +1 [THS:219] Prowler's Helm +1 [GPT:122] Mortify +1 [DKA:158] Vault of the Archangel +1 [RTR:238] Blood Crypt +1 [ORI:21] Knight of the White Orchid +1 [MBS:104] Darksteel Plate +1 [MRD:199] Lightning Greaves +1 [DGM:135] Wear // Tear +1 [5ED:246] Jokulhaups +1 [BNG:88] Archetype of Aggression +1 [JOU:93] Dictate of the Twin Gods +1 [GTC:177] Merciless Eviction +1 [CNS:35] Scourge of the Throne +SB: 1 [KTK:214] Zurgo Helmsmasher diff --git a/Mage.Client/release/sample-decks/Decks to Beat/4c Solar Flare TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/4c Solar Flare TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..2387cf5b127 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/4c Solar Flare TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,36 @@ +1 [M15:51] Dissipate +1 [UNH:138] Swamp +4 [UNH:137] Island +2 [UNH:136] Plains +2 [M12:73] Ponder +2 [M12:72] Phantasmal Image +4 [ISD:55] Forbidden Alchemy +1 [UNH:139] Mountain +3 [NPH:86] Gut Shot +4 [ISD:139] Desperate Ravings +3 [C14:91] Sun Titan +3 [M13:22] Oblivion Ring +1 [C14:298] Ghost Quarter +3 [M14:229] Shimmering Grotto +4 [ISD:248] Sulfur Falls +1 [ISD:122] Unburial Rites +4 [M12:63] Mana Leak +1 [NPH:9] Elesh Norn, Grand Cenobite +4 [SOM:229] Seachrome Coast +1 [M14:215] Ratchet Bomb +4 [M13:225] Glacial Fortress +3 [C14:264] Pristine Talisman +1 [M14:25] Pacifism +1 [SOM:224] Blackcleave Cliffs +1 [C13:32] Blue Sun's Zenith +1 [M12:12] Day of Judgment +SB: 2 [M12:40] Timely Reinforcements +SB: 1 [M15:51] Dissipate +SB: 2 [C13:249] Nihil Spellbomb +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [M12:72] Phantasmal Image +SB: 2 [ISD:127] Ancient Grudge +SB: 1 [C14:298] Ghost Quarter +SB: 1 [M12:12] Day of Judgment +SB: 1 [C13:32] Blue Sun's Zenith +SB: 3 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Control TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Control TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..f249e97c249 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Control TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,31 @@ +4 [KTK:248] Windswept Heath +2 [M15:241] Caves of Koilos +3 [BNG:61] Bile Blight +1 [FRF:87] Tasigur, the Golden Fang +2 [UNH:136] Plains +4 [JOU:165] Temple of Malady +4 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +1 [M15:103] Liliana Vess +2 [C14:158] Read the Bones +4 [THS:107] Thoughtseize +4 [KTK:241] Sandsteppe Citadel +2 [KTK:8] End Hostilities +3 [THS:90] Hero's Downfall +1 [KTK:81] Murderous Cut +1 [M15:248] Urborg, Tomb of Yawgmoth +3 [THS:9] Elspeth, Sun's Champion +1 [FRF:1] Ugin, the Spirit Dragon +1 [KTK:210] Utter End +2 [UNH:140] Forest +3 [M15:244] Llanowar Wastes +4 [BNG:119] Courser of Kruphix +4 [THS:227] Temple of Silence +SB: 4 [THS:193] Fleecemane Lion +SB: 1 [FRF:87] Tasigur, the Golden Fang +SB: 1 [C14:158] Read the Bones +SB: 1 [KTK:9] Erase +SB: 2 [THS:15] Glare of Heresy +SB: 1 [M15:210] Garruk, Apex Predator +SB: 2 [KTK:202] Sorin, Solemn Visitor +SB: 3 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..31c07138b14 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,29 @@ +4 [KTK:248] Windswept Heath +2 [M15:241] Caves of Koilos +2 [BNG:61] Bile Blight +2 [FRF:87] Tasigur, the Golden Fang +2 [UNH:136] Plains +4 [JOU:165] Temple of Malady +1 [DTK:221] Dromoka's Command +4 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +1 [KTK:202] Sorin, Solemn Visitor +4 [THS:193] Fleecemane Lion +1 [DTK:124] Ultimate Price +4 [THS:107] Thoughtseize +4 [KTK:241] Sandsteppe Citadel +4 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +3 [THS:9] Elspeth, Sun's Champion +2 [UNH:140] Forest +3 [M15:244] Llanowar Wastes +4 [BNG:119] Courser of Kruphix +4 [THS:227] Temple of Silence +SB: 2 [C14:158] Read the Bones +SB: 1 [M15:187] Nissa, Worldwaker +SB: 1 [DTK:221] Dromoka's Command +SB: 2 [KTK:8] End Hostilities +SB: 1 [FRF:1] Ugin, the Spirit Dragon +SB: 3 [DTK:98] Duress +SB: 1 [KTK:202] Sorin, Solemn Visitor +SB: 4 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..0115fc7ca68 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,44 @@ +4 [KTK:248] Windswept Heath +1 [TPR:267] Forest +2 [JOU:165] Temple of Malady +1 [PLC:165] Urborg, Tomb of Yawgmoth +1 [JOU:5] Banishing Light +4 [KTK:200] Siege Rhino +2 [M15:34] Soul of Theros +2 [C14:191] Elvish Mystic +1 [FNMP:172] Banishing Light +1 [M11:233] Plains +1 [LRW:299] Forest +4 [KTK:241] Sandsteppe Citadel +1 [10E:355] Llanowar Wastes +1 [M15:178] Hornet Queen +1 [UNH:140] Forest +1 [APC:140] Caves of Koilos +1 [M15:173] Elvish Mystic +2 [BNG:136] Satyr Wayfinder +4 [BNG:119] Courser of Kruphix +1 [RAV:287] Plains +2 [THS:227] Temple of Silence +1 [APC:141] Llanowar Wastes +4 [KTK:31] Wingmate Roc +2 [M15:198] Satyr Wayfinder +2 [THS:155] Commune with the Gods +2 [THS:180] Sylvan Caryatid +1 [MBP:77] Sylvan Caryatid +2 [THS:110] Whip of Erebos +1 [FNMP:165] Elvish Mystic +3 [KTK:81] Murderous Cut +2 [CMD:159] Hornet Queen +2 [M15:244] Llanowar Wastes +SB: 1 [M15:194] Reclamation Sage +SB: 1 [PTC:80] Doomwake Giant +SB: 2 [LRW:145] Thoughtseize +SB: 1 [KTK:174] Duneblast +SB: 1 [M15:187] Nissa, Worldwaker +SB: 1 [THS:110] Whip of Erebos +SB: 2 [THS:15] Glare of Heresy +SB: 2 [KTK:8] End Hostilities +SB: 1 [JOU:66] Doomwake Giant +SB: 1 [C14:213] Reclamation Sage +SB: 1 [THS:101] Read the Bones +SB: 1 [MBP:103] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..06c3dfdfb0e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,31 @@ +4 [KTK:248] Windswept Heath +3 [M15:241] Caves of Koilos +3 [BNG:61] Bile Blight +2 [FRF:87] Tasigur, the Golden Fang +4 [KTK:192] Rakshasa Deathdealer +2 [UNH:136] Plains +3 [JOU:165] Temple of Malady +1 [BNG:165] Temple of Plenty +3 [KTK:163] Anafenza, the Foremost +2 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +1 [KTK:202] Sorin, Solemn Visitor +4 [THS:193] Fleecemane Lion +2 [THS:107] Thoughtseize +4 [KTK:241] Sandsteppe Citadel +4 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [UNH:140] Forest +3 [BNG:119] Courser of Kruphix +4 [M15:244] Llanowar Wastes +3 [KTK:31] Wingmate Roc +2 [THS:227] Temple of Silence +SB: 2 [FRF:143] Warden of the First Tree +SB: 1 [BNG:61] Bile Blight +SB: 1 [M15:187] Nissa, Worldwaker +SB: 1 [THS:107] Thoughtseize +SB: 3 [THS:15] Glare of Heresy +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 1 [BNG:119] Courser of Kruphix +SB: 4 [BNG:65] Drown in Sorrow +SB: 1 [KTK:202] Sorin, Solemn Visitor diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..92f4be60ebc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,27 @@ +4 [KTK:248] Windswept Heath +2 [M15:241] Caves of Koilos +4 [BNG:61] Bile Blight +4 [KTK:192] Rakshasa Deathdealer +1 [JOU:163] Mana Confluence +1 [UNH:136] Plains +2 [JOU:165] Temple of Malady +4 [KTK:163] Anafenza, the Foremost +3 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +1 [KTK:202] Sorin, Solemn Visitor +4 [THS:193] Fleecemane Lion +4 [THS:107] Thoughtseize +4 [KTK:241] Sandsteppe Citadel +3 [THS:90] Hero's Downfall +2 [M15:248] Urborg, Tomb of Yawgmoth +2 [UNH:140] Forest +3 [M15:244] Llanowar Wastes +4 [KTK:31] Wingmate Roc +4 [THS:227] Temple of Silence +SB: 3 [M15:169] Back to Nature +SB: 3 [THS:15] Glare of Heresy +SB: 2 [JOU:145] Ajani, Mentor of Heroes +SB: 1 [KTK:81] Murderous Cut +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 3 [BNG:65] Drown in Sorrow +SB: 1 [KTK:202] Sorin, Solemn Visitor diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..d2096c453c4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,27 @@ +4 [KTK:248] Windswept Heath +3 [M15:241] Caves of Koilos +4 [KTK:192] Rakshasa Deathdealer +1 [JOU:163] Mana Confluence +2 [UNH:136] Plains +3 [JOU:165] Temple of Malady +3 [DTK:221] Dromoka's Command +4 [KTK:163] Anafenza, the Foremost +4 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +2 [KTK:202] Sorin, Solemn Visitor +2 [FRF:143] Warden of the First Tree +4 [THS:193] Fleecemane Lion +3 [THS:107] Thoughtseize +4 [KTK:241] Sandsteppe Citadel +2 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [UNH:140] Forest +3 [M15:244] Llanowar Wastes +3 [THS:227] Temple of Silence +2 [KTK:31] Wingmate Roc +SB: 3 [DTK:124] Ultimate Price +SB: 1 [THS:107] Thoughtseize +SB: 3 [DTK:117] Self-Inflicted Wound +SB: 3 [DTK:181] Den Protector +SB: 2 [DTK:98] Duress +SB: 3 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..d21efee1f93 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,39 @@ +2 [ONS:328] Windswept Heath +1 [KTK:248] Windswept Heath +2 [M15:241] Caves of Koilos +4 [JOU:165] Temple of Malady +1 [PLC:165] Urborg, Tomb of Yawgmoth +4 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +2 [KTK:202] Sorin, Solemn Visitor +2 [THS:107] Thoughtseize +1 [9ED:334] Plains +1 [ONS:347] Forest +1 [KTK:241] Sandsteppe Citadel +2 [KTK:8] End Hostilities +4 [THS:90] Hero's Downfall +2 [JOU:145] Ajani, Mentor of Heroes +3 [THS:9] Elspeth, Sun's Champion +1 [PTK:168] Plains +4 [BNG:119] Courser of Kruphix +3 [THS:227] Temple of Silence +1 [APC:141] Llanowar Wastes +2 [KTK:31] Wingmate Roc +1 [JR:46] Windswept Heath +1 [JOU:163] Mana Confluence +1 [BNG:165] Temple of Plenty +2 [LRW:145] Thoughtseize +1 [DDO:64] Forest +2 [9ED:322] Llanowar Wastes +4 [THS:180] Sylvan Caryatid +1 [ARC:150] Forest +SB: 1 [MBP:101] Liliana Vess +SB: 2 [M15:169] Back to Nature +SB: 1 [FNMP:171] Bile Blight +SB: 2 [BNG:61] Bile Blight +SB: 1 [C14:158] Read the Bones +SB: 1 [M15:187] Nissa, Worldwaker +SB: 1 [KTK:8] End Hostilities +SB: 2 [KTK:163] Anafenza, the Foremost +SB: 1 [MBP:103] Nissa, Worldwaker +SB: 3 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Oct 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Oct 2014.mwDeck.dck new file mode 100644 index 00000000000..a89c781067d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Abzan Midrange TDtB ST Oct 2014.mwDeck.dck @@ -0,0 +1,33 @@ +4 [KTK:248] Windswept Heath +2 [BNG:61] Bile Blight +1 [UNH:138] Swamp +1 [JOU:163] Mana Confluence +2 [UNH:136] Plains +1 [JOU:165] Temple of Malady +1 [BNG:165] Temple of Plenty +1 [KTK:163] Anafenza, the Foremost +3 [KTK:161] Abzan Charm +4 [KTK:200] Siege Rhino +1 [BNG:65] Drown in Sorrow +2 [KTK:202] Sorin, Solemn Visitor +4 [THS:180] Sylvan Caryatid +4 [THS:193] Fleecemane Lion +1 [THS:107] Thoughtseize +1 [THS:110] Whip of Erebos +4 [KTK:241] Sandsteppe Citadel +4 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [UNH:140] Forest +4 [BNG:119] Courser of Kruphix +4 [M15:244] Llanowar Wastes +4 [KTK:31] Wingmate Roc +4 [THS:227] Temple of Silence +SB: 1 [M15:169] Back to Nature +SB: 3 [THS:107] Thoughtseize +SB: 1 [KTK:9] Erase +SB: 4 [KTK:8] End Hostilities +SB: 1 [KTK:163] Anafenza, the Foremost +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 1 [JOU:59] Agent of Erebos +SB: 1 [KTK:210] Utter End +SB: 1 [M15:117] Stain the Mind diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..8430324756a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,25 @@ +4 [CNS:69] Doomed Traveler +2 [UNH:136] Plains +4 [RTR:238] Blood Crypt +4 [GTC:242] Godless Shrine +4 [GTC:150] Cartel Aristocrat +1 [ISD:238] Clifftop Retreat +4 [DKA:12] Lingering Souls +4 [ISD:242] Isolated Chapel +4 [GTC:245] Sacred Foundry +4 [C14:167] Tragic Slip +4 [M13:222] Dragonskull Summit +4 [C14:163] Skirsdag High Priest +4 [GTC:215] Boros Reckoner +3 [C14:172] Blasphemous Act +1 [DKA:142] Sorin, Lord of Innistrad +4 [DKA:138] Falkenrath Aristocrat +1 [C13:312] Orzhov Guildgate +4 [AVR:86] Blood Artist +SB: 3 [M14:97] Duress +SB: 1 [GTC:182] Obzedat, Ghost Council +SB: 1 [RTR:157] Dreadbore +SB: 3 [CNS:72] Intangible Virtue +SB: 1 [C14:172] Blasphemous Act +SB: 3 [DKA:142] Sorin, Lord of Innistrad +SB: 3 [C14:278] Tormod's Crypt diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..a0585c1f3fa --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,28 @@ +4 [CNS:69] Doomed Traveler +2 [UNH:136] Plains +4 [RTR:238] Blood Crypt +4 [GTC:242] Godless Shrine +4 [GTC:150] Cartel Aristocrat +1 [ISD:238] Clifftop Retreat +4 [DKA:12] Lingering Souls +4 [ISD:242] Isolated Chapel +4 [GTC:245] Sacred Foundry +4 [C14:167] Tragic Slip +4 [M13:222] Dragonskull Summit +2 [C14:163] Skirsdag High Priest +4 [GTC:215] Boros Reckoner +3 [C14:172] Blasphemous Act +2 [DKA:142] Sorin, Lord of Innistrad +4 [DKA:138] Falkenrath Aristocrat +1 [GTC:185] Orzhov Charm +1 [AVR:226] Cavern of Souls +4 [AVR:86] Blood Artist +SB: 2 [RTR:93] Electrickery +SB: 1 [M13:22] Oblivion Ring +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 1 [M14:97] Duress +SB: 2 [AVR:166] Zealous Conscripts +SB: 1 [C14:172] Blasphemous Act +SB: 3 [M13:141] Mark of Mutiny +SB: 2 [AVR:84] Appetite for Brains +SB: 1 [AVR:226] Cavern of Souls diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..3971eba7b95 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Aristocrats TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,28 @@ +4 [CNS:69] Doomed Traveler +2 [UNH:136] Plains +4 [RTR:238] Blood Crypt +4 [GTC:242] Godless Shrine +4 [GTC:150] Cartel Aristocrat +4 [DKA:12] Lingering Souls +4 [ISD:242] Isolated Chapel +4 [GTC:245] Sacred Foundry +4 [C14:167] Tragic Slip +4 [M13:222] Dragonskull Summit +3 [C14:163] Skirsdag High Priest +1 [DKA:158] Vault of the Archangel +4 [GTC:215] Boros Reckoner +3 [C14:172] Blasphemous Act +2 [DKA:142] Sorin, Lord of Innistrad +4 [DKA:138] Falkenrath Aristocrat +1 [AVR:226] Cavern of Souls +4 [AVR:86] Blood Artist +SB: 1 [GTC:142] Assemble the Legion +SB: 2 [RTR:93] Electrickery +SB: 1 [M14:97] Duress +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 1 [RTR:197] Slaughter Games +SB: 1 [AVR:166] Zealous Conscripts +SB: 3 [RTR:157] Dreadbore +SB: 1 [CNS:72] Intangible Virtue +SB: 1 [DKA:142] Sorin, Lord of Innistrad +SB: 2 [M13:141] Mark of Mutiny diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..685feb5db07 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,31 @@ +1 [THS:39] Aqueous Form +4 [THS:58] Ordeal of Thassa +1 [JOU:163] Mana Confluence +3 [UNH:137] Island +2 [KTK:246] Tranquil Cove +4 [KTK:233] Flooded Strand +8 [UNH:136] Plains +1 [KTK:56] Stubborn Denial +4 [THS:189] Battlewise Hoplite +1 [JOU:2] Ajani's Presence +4 [BNG:163] Temple of Enlightenment +4 [BNG:17] Hero of Iroas +2 [BNG:52] Stratus Walk +4 [M15:14] Heliod's Pilgrim +4 [KTK:7] Defiant Strike +1 [KTK:10] Feat of Resistance +1 [THS:25] Ordeal of Heliod +4 [THS:13] Favored Hoplite +4 [THS:16] Gods Willing +3 [KTK:22] Seeker of the Way +SB: 1 [THS:39] Aqueous Form +SB: 1 [JOU:17] Mortal Obstinacy +SB: 1 [KTK:59] Treasure Cruise +SB: 2 [JOU:14] Lagonna-Band Trailblazer +SB: 3 [KTK:56] Stubborn Denial +SB: 1 [KTK:9] Erase +SB: 2 [BNG:5] Brimaz, King of Oreskos +SB: 1 [THS:15] Glare of Heresy +SB: 1 [KTK:36] Dig Through Time +SB: 1 [THS:71] Triton Tactics +SB: 1 [JOU:2] Ajani's Presence diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..310e00fc7be --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,25 @@ +2 [THS:39] Aqueous Form +4 [THS:58] Ordeal of Thassa +3 [UNH:137] Island +3 [JOU:163] Mana Confluence +4 [KTK:233] Flooded Strand +6 [UNH:136] Plains +4 [THS:189] Battlewise Hoplite +3 [JOU:2] Ajani's Presence +4 [BNG:163] Temple of Enlightenment +4 [BNG:17] Hero of Iroas +2 [BNG:52] Stratus Walk +2 [JOU:14] Lagonna-Band Trailblazer +4 [KTK:7] Defiant Strike +1 [KTK:10] Feat of Resistance +3 [THS:25] Ordeal of Heliod +1 [THS:71] Triton Tactics +4 [THS:13] Favored Hoplite +4 [THS:16] Gods Willing +2 [KTK:22] Seeker of the Way +SB: 2 [KTK:59] Treasure Cruise +SB: 3 [KTK:56] Stubborn Denial +SB: 1 [KTK:9] Erase +SB: 3 [KTK:37] Disdainful Stroke +SB: 4 [THS:15] Glare of Heresy +SB: 2 [KTK:22] Seeker of the Way diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..642aa77eb24 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Heroic TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,24 @@ +2 [THS:39] Aqueous Form +4 [THS:58] Ordeal of Thassa +6 [UNH:137] Island +4 [KTK:246] Tranquil Cove +10 [UNH:136] Plains +1 [KTK:56] Stubborn Denial +4 [THS:189] Battlewise Hoplite +2 [BNG:163] Temple of Enlightenment +4 [BNG:17] Hero of Iroas +4 [M15:14] Heliod's Pilgrim +4 [KTK:7] Defiant Strike +2 [KTK:10] Feat of Resistance +2 [THS:25] Ordeal of Heliod +1 [THS:71] Triton Tactics +4 [THS:13] Favored Hoplite +4 [THS:16] Gods Willing +2 [KTK:22] Seeker of the Way +SB: 2 [KTK:59] Treasure Cruise +SB: 3 [KTK:56] Stubborn Denial +SB: 2 [KTK:9] Erase +SB: 3 [THS:15] Glare of Heresy +SB: 1 [THS:19] Hopeful Eidolon +SB: 2 [JOU:2] Ajani's Presence +SB: 2 [BNG:7] Eidolon of Countless Battles diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Azorius Human TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Human TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..5f605bde9fe --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Azorius Human TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,26 @@ +2 [DKA:7] Faith's Shield +1 [UNH:137] Island +9 [UNH:136] Plains +4 [C14:88] Silverblade Paladin +4 [ISD:213] Geist of Saint Traft +4 [M13:36] Sublime Archangel +2 [RTR:179] Lyev Skyknight +4 [M13:38] War Falcon +3 [DKA:24] Thalia, Guardian of Thraben +4 [RTR:17] Precinct Captain +1 [M14:1] Ajani, Caller of the Pride +4 [ISD:6] Champion of the Parish +4 [M13:21] Knight of Glory +4 [M13:225] Glacial Fortress +1 [ISD:14] Feeling of Dread +1 [ISD:13] Elite Inquisitor +4 [AVR:226] Cavern of Souls +4 [RTR:241] Hallowed Fountain +SB: 3 [RTR:214] Dryad Militant +SB: 3 [M15:71] Negate +SB: 2 [RTR:155] Detention Sphere +SB: 2 [AVR:33] Riders of Gavony +SB: 1 [ISD:14] Feeling of Dread +SB: 2 [C13:11] Fiend Hunter +SB: 1 [DKA:24] Thalia, Guardian of Thraben +SB: 1 [M13:39] War Priest of Thune diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BR Vampires TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BR Vampires TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..1e5e302ef67 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BR Vampires TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,28 @@ +2 [MBS:43] Go for the Throat +2 [MBS:66] Hero of Oxid Ridge +2 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +1 [M11:90] Dark Tutelage +2 [ZEN:229] Verdant Catacombs +2 [C14:168] Vampire Hexmage +1 [ZEN:119] Burst Lightning +3 [ZEN:219] Marsh Flats +4 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +1 [M14:96] Doom Blade +4 [SOM:224] Blackcleave Cliffs +2 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +6 [UNH:138] Swamp +SB: 1 [M11:90] Dark Tutelage +SB: 2 [M12:151] Manic Vandal +SB: 3 [M13:141] Mark of Mutiny +SB: 1 [C14:168] Vampire Hexmage +SB: 3 [M11:92] Demon of Death's Gate +SB: 2 [SOM:78] Skinrender +SB: 1 [M14:96] Doom Blade +SB: 2 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..1e99a5d8faf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,25 @@ +2 [MBS:43] Go for the Throat +4 [AVR:86] Blood Artist +3 [CNS:138] Brimstone Volley +4 [M13:222] Dragonskull Summit +4 [ISD:97] Diregraf Ghoul +3 [C14:167] Tragic Slip +2 [NPH:42] Phyrexian Metamorph +3 [DKA:138] Falkenrath Aristocrat +3 [AVR:226] Cavern of Souls +4 [DKA:63] Geralf's Messenger +2 [SOM:63] Fume Spitter +4 [DKA:64] Gravecrawler +4 [C14:161] Sign in Blood +2 [MBS:115] Mortarpod +4 [SOM:224] Blackcleave Cliffs +12 [UNH:138] Swamp +SB: 2 [NPH:61] Geth's Verdict +SB: 2 [M14:156] Smelt +SB: 1 [NPH:74] Surgical Extraction +SB: 1 [NPH:42] Phyrexian Metamorph +SB: 2 [AVR:149] Pillar of Flame +SB: 2 [SOM:81] Arc Trail +SB: 2 [C13:249] Nihil Spellbomb +SB: 1 [M12:94] Distress +SB: 2 [KTK:69] Despise diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..0392fffa64d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BR Zombies TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,22 @@ +4 [AVR:86] Blood Artist +3 [M13:147] Searing Spear +4 [M13:222] Dragonskull Summit +4 [C13:314] Rakdos Guildgate +2 [M13:141] Mark of Mutiny +4 [ISD:97] Diregraf Ghoul +4 [RTR:220] Rakdos Cackler +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +1 [AVR:226] Cavern of Souls +4 [AVR:149] Pillar of Flame +4 [DKA:63] Geralf's Messenger +1 [M14:139] Flames of the Firebrand +4 [M13:96] Knight of Infamy +4 [DKA:64] Gravecrawler +9 [UNH:138] Swamp +SB: 1 [M13:141] Mark of Mutiny +SB: 3 [C13:97] Vampire Nighthawk +SB: 2 [M14:139] Flames of the Firebrand +SB: 3 [RTR:213] Deathrite Shaman +SB: 3 [M15:92] Crippling Blight +SB: 3 [RTR:184] Rakdos Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BUG Control TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BUG Control TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..8c38fc526f8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BUG Control TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,27 @@ +1 [MBS:43] Go for the Throat +1 [SOM:69] Memoricide +4 [WWK:134] Creeping Tar Pit +6 [UNH:140] Forest +2 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +3 [ZEN:172] Oracle of Mul Daya +1 [C13:135] Avenger of Zendikar +4 [ZEN:229] Verdant Catacombs +4 [M11:70] Preordain +2 [C14:112] Frost Titan +3 [C14:145] Grave Titan +4 [ZEN:168] Lotus Cobra +2 [ZEN:87] Disfigure +4 [WWK:99] Explore +3 [SOM:226] Darkslick Shores +4 [WWK:31] Jace, the Mind Sculptor +2 [UNH:137] Island +2 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 1 [MBS:43] Go for the Throat +SB: 2 [C14:136] Black Sun's Zenith +SB: 3 [SOM:69] Memoricide +SB: 2 [SOM:194] Precursor Golem +SB: 2 [ZEN:87] Disfigure +SB: 3 [M14:116] Shrivel +SB: 2 [M11:188] Obstinate Baloth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BW Tokens TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BW Tokens TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..58171def5da --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BW Tokens TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,24 @@ +1 [SOM:6] Elspeth Tirel +2 [NPH:161] Sword of War and Peace +3 [DKA:158] Vault of the Archangel +4 [ISD:242] Isolated Chapel +4 [CNS:72] Intangible Virtue +1 [M14:229] Shimmering Grotto +4 [C14:80] Midnight Haunting +4 [DKA:12] Lingering Souls +3 [M13:22] Oblivion Ring +4 [M12:23] Honor of the Pure +13 [UNH:136] Plains +2 [DKA:142] Sorin, Lord of Innistrad +4 [ISD:6] Champion of the Parish +4 [DKA:8] Gather the Townsfolk +3 [UNH:138] Swamp +4 [CNS:69] Doomed Traveler +SB: 1 [MBS:43] Go for the Throat +SB: 1 [MBS:5] Divine Offering +SB: 2 [NPH:74] Surgical Extraction +SB: 3 [M12:3] Angelic Destiny +SB: 2 [BNG:25] Revoke Existence +SB: 1 [M14:96] Doom Blade +SB: 4 [MBS:8] Hero of Bladehold +SB: 1 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..41690e95a55 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,32 @@ +2 [RTR:82] Ultimate Price +2 [THS:110] Whip of Erebos +2 [RTR:73] Pack Rat +2 [RTR:63] Desecration Demon +4 [GTC:215] Boros Reckoner +3 [THS:112] Anger of the Gods +4 [THS:227] Temple of Silence +4 [THS:228] Temple of Triumph +2 [THS:107] Thoughtseize +1 [UNH:139] Mountain +2 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +1 [RTR:232] Rakdos Keyrune +1 [RTR:188] Rakdos's Return +2 [GTC:182] Obzedat, Ghost Council +4 [RTR:238] Blood Crypt +4 [THS:90] Hero's Downfall +1 [M14:96] Doom Blade +4 [GTC:245] Sacred Foundry +2 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +3 [UNH:138] Swamp +2 [GTC:142] Assemble the Legion +SB: 2 [RTR:157] Dreadbore +SB: 2 [THS:15] Glare of Heresy +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 1 [RTR:231] Pithing Needle +SB: 1 [THS:112] Anger of the Gods +SB: 3 [M14:97] Duress +SB: 2 [DGM:135] Wear // Tear +SB: 2 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..9ffe3a9b39e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/BWR Control TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,34 @@ +1 [THS:110] Whip of Erebos +4 [GTC:215] Boros Reckoner +4 [RTR:63] Desecration Demon +3 [THS:112] Anger of the Gods +4 [THS:227] Temple of Silence +3 [THS:228] Temple of Triumph +2 [THS:107] Thoughtseize +1 [C13:314] Rakdos Guildgate +3 [UNH:139] Mountain +2 [RTR:157] Dreadbore +2 [C14:158] Read the Bones +2 [RTR:232] Rakdos Keyrune +2 [THS:4] Chained to the Rocks +2 [RTR:188] Rakdos's Return +2 [DGM:57] Blood Baron of Vizkopa +2 [GTC:182] Obzedat, Ghost Council +4 [RTR:238] Blood Crypt +2 [THS:90] Hero's Downfall +1 [M14:96] Doom Blade +3 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +4 [GTC:242] Godless Shrine +1 [THS:9] Elspeth, Sun's Champion +2 [UNH:138] Swamp +SB: 1 [M15:134] Chandra, Pyromaster +SB: 1 [RTR:101] Mizzium Mortars +SB: 3 [M14:155] Shock +SB: 2 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [THS:15] Glare of Heresy +SB: 1 [M14:101] Lifebane Zombie +SB: 1 [THS:112] Anger of the Gods +SB: 2 [THS:107] Thoughtseize +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..5c48e826754 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,33 @@ +3 [RTR:145] Azorius Charm +2 [ISD:245] Nephalia Drownyard +2 [RTR:243] Overgrown Tomb +4 [M15:51] Dissipate +1 [RTR:155] Detention Sphere +4 [M13:170] Farseek +2 [UNH:137] Island +3 [RTR:248] Temple Garden +1 [AVR:32] Restoration Angel +4 [M13:193] Thragtusk +1 [AVR:43] Amass the Components +4 [RTR:200] Sphinx's Revelation +3 [RTR:201] Supreme Verdict +4 [ISD:241] Hinterland Harbor +4 [ISD:83] Think Twice +1 [RTR:18] Rest in Peace +4 [M13:225] Glacial Fortress +1 [AVR:38] Terminus +3 [C13:30] Augur of Bolas +4 [M13:229] Sunpetal Grove +1 [AVR:225] Alchemist's Refuge +4 [RTR:241] Hallowed Fountain +SB: 1 [RTR:231] Pithing Needle +SB: 2 [M15:71] Negate +SB: 1 [RTR:145] Azorius Charm +SB: 1 [RTR:155] Detention Sphere +SB: 1 [AVR:32] Restoration Angel +SB: 2 [RTR:36] Dispel +SB: 2 [M13:29] Rhox Faithmender +SB: 2 [AVR:38] Terminus +SB: 1 [C14:214] Silklash Spider +SB: 1 [M14:60] Jace, Memory Adept +SB: 1 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..22c946ebd8c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,28 @@ +4 [RTR:145] Azorius Charm +2 [ISD:245] Nephalia Drownyard +2 [RTR:44] Jace, Architect of Thought +2 [RTR:243] Overgrown Tomb +3 [M15:51] Dissipate +2 [RTR:155] Detention Sphere +4 [M13:170] Farseek +2 [UNH:137] Island +4 [RTR:248] Temple Garden +1 [AVR:32] Restoration Angel +4 [M13:193] Thragtusk +3 [RTR:200] Sphinx's Revelation +4 [RTR:201] Supreme Verdict +4 [ISD:241] Hinterland Harbor +4 [ISD:83] Think Twice +4 [M13:225] Glacial Fortress +2 [C13:30] Augur of Bolas +1 [AVR:79] Tamiyo, the Moon Sage +3 [M13:229] Sunpetal Grove +1 [AVR:225] Alchemist's Refuge +4 [RTR:241] Hallowed Fountain +SB: 1 [RTR:231] Pithing Needle +SB: 3 [M15:71] Negate +SB: 1 [RTR:36] Dispel +SB: 3 [AVR:38] Terminus +SB: 3 [M13:29] Rhox Faithmender +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..a65e81c9139 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,28 @@ +4 [RTR:145] Azorius Charm +3 [RTR:44] Jace, Architect of Thought +4 [M15:51] Dissipate +3 [RTR:155] Detention Sphere +4 [M13:170] Farseek +1 [UNH:137] Island +4 [RTR:248] Temple Garden +2 [UNH:136] Plains +4 [M13:193] Thragtusk +4 [RTR:200] Sphinx's Revelation +4 [RTR:201] Supreme Verdict +4 [ISD:241] Hinterland Harbor +4 [M13:225] Glacial Fortress +1 [AVR:38] Terminus +1 [M14:209] Elixir of Immortality +1 [M13:217] Staff of Nin +4 [M13:229] Sunpetal Grove +1 [UNH:140] Forest +1 [RTR:54] Syncopate +2 [AVR:226] Cavern of Souls +4 [RTR:241] Hallowed Fountain +SB: 2 [M15:71] Negate +SB: 1 [DKA:17] Ray of Revelation +SB: 3 [AVR:32] Restoration Angel +SB: 4 [RTR:148] Centaur Healer +SB: 2 [RTR:36] Dispel +SB: 2 [M13:176] Ground Seal +SB: 1 [AVR:79] Tamiyo, the Moon Sage diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..05033f59ce5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Control TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,28 @@ +2 [RTR:1] Angel of Serenity +4 [RTR:145] Azorius Charm +3 [RTR:155] Detention Sphere +2 [UNH:137] Island +4 [RTR:248] Temple Garden +4 [AVR:32] Restoration Angel +4 [M13:193] Thragtusk +3 [UNH:136] Plains +4 [RTR:178] Loxodon Smiter +2 [C14:104] Cyclonic Rift +4 [ISD:241] Hinterland Harbor +1 [ISD:181] Garruk Relentless +1 [C13:236] Azorius Keyrune +3 [M13:225] Glacial Fortress +3 [AVR:38] Terminus +2 [AVR:79] Tamiyo, the Moon Sage +4 [M13:229] Sunpetal Grove +2 [C13:42] Dungeon Geists +1 [UNH:140] Forest +3 [RTR:54] Syncopate +4 [RTR:241] Hallowed Fountain +SB: 3 [M13:21] Knight of Glory +SB: 1 [RTR:206] Trostani, Selesnya's Voice +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 2 [RTR:201] Supreme Verdict +SB: 4 [ISD:213] Geist of Saint Traft +SB: 1 [C13:42] Dungeon Geists +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..e4bb3c1bdf7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,24 @@ +4 [ISD:79] Spectral Flight +4 [RTR:248] Temple Garden +4 [M13:185] Rancor +4 [RTR:9] Ethereal Armor +1 [C14:88] Silverblade Paladin +4 [ISD:213] Geist of Saint Traft +4 [GTC:240] Breeding Pool +4 [M14:176] Gladecover Scout +4 [ISD:60] Invisible Stalker +1 [C13:211] Selesnya Charm +4 [ISD:241] Hinterland Harbor +4 [ISD:170] Avacyn's Pilgrim +1 [DKA:120] Increasing Savagery +1 [GTC:195] Simic Charm +2 [M13:225] Glacial Fortress +4 [DGM:111] Unflinching Courage +4 [M13:229] Sunpetal Grove +2 [M14:18] Fiendslayer Paladin +4 [RTR:241] Hallowed Fountain +SB: 2 [DGM:44] Mending Touch +SB: 2 [M14:171] Fog +SB: 4 [DGM:114] Voice of Resurgence +SB: 4 [DGM:51] Advent of the Wurm +SB: 3 [GTC:52] Spell Rupture diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..e6a926ac049 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,26 @@ +4 [ISD:79] Spectral Flight +1 [UNH:137] Island +4 [RTR:248] Temple Garden +4 [M13:185] Rancor +4 [RTR:9] Ethereal Armor +3 [C14:88] Silverblade Paladin +4 [ISD:213] Geist of Saint Traft +4 [ISD:60] Invisible Stalker +4 [C13:211] Selesnya Charm +4 [ISD:241] Hinterland Harbor +4 [ISD:170] Avacyn's Pilgrim +2 [DKA:120] Increasing Savagery +4 [AVR:167] Abundant Growth +1 [M13:225] Glacial Fortress +2 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +3 [AVR:226] Cavern of Souls +4 [RTR:241] Hallowed Fountain +SB: 1 [M15:71] Negate +SB: 1 [RTR:19] Rootborn Defenses +SB: 3 [AVR:31] Nearheath Pilgrim +SB: 1 [ISD:3] Angelic Overseer +SB: 2 [RTR:178] Loxodon Smiter +SB: 2 [ISD:14] Feeling of Dread +SB: 2 [ISD:25] Nevermore +SB: 3 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..78a7517faec --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,26 @@ +4 [ISD:79] Spectral Flight +4 [RTR:248] Temple Garden +4 [M13:185] Rancor +4 [RTR:9] Ethereal Armor +4 [ISD:213] Geist of Saint Traft +4 [GTC:240] Breeding Pool +4 [RTR:178] Loxodon Smiter +4 [ISD:60] Invisible Stalker +2 [C13:211] Selesnya Charm +4 [ISD:241] Hinterland Harbor +4 [ISD:170] Avacyn's Pilgrim +4 [DGM:114] Voice of Resurgence +2 [M13:225] Glacial Fortress +4 [DGM:111] Unflinching Courage +3 [M13:229] Sunpetal Grove +1 [UNH:140] Forest +4 [RTR:241] Hallowed Fountain +SB: 1 [RTR:19] Rootborn Defenses +SB: 2 [AVR:31] Nearheath Pilgrim +SB: 2 [GTC:219] Gift of Orzhova +SB: 1 [AVR:32] Restoration Angel +SB: 2 [M13:29] Rhox Faithmender +SB: 2 [GTC:212] Beckon Apparition +SB: 2 [M14:25] Pacifism +SB: 1 [ISD:25] Nevermore +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..c94fac6cf39 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,23 @@ +4 [ISD:79] Spectral Flight +4 [RTR:248] Temple Garden +4 [M13:185] Rancor +4 [RTR:9] Ethereal Armor +4 [ISD:213] Geist of Saint Traft +4 [GTC:240] Breeding Pool +4 [ISD:60] Invisible Stalker +4 [C13:211] Selesnya Charm +4 [ISD:241] Hinterland Harbor +2 [M14:1] Ajani, Caller of the Pride +3 [ISD:170] Avacyn's Pilgrim +4 [DGM:114] Voice of Resurgence +4 [DGM:111] Unflinching Courage +4 [M13:229] Sunpetal Grove +1 [UNH:140] Forest +2 [DKA:127] Strangleroot Geist +4 [RTR:241] Hallowed Fountain +SB: 1 [RTR:145] Azorius Charm +SB: 3 [RTR:19] Rootborn Defenses +SB: 4 [RTR:148] Centaur Healer +SB: 4 [DGM:51] Advent of the Wurm +SB: 2 [AVR:210] Sigarda, Host of Herons +SB: 1 [UNH:140] Forest diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..febb10bcb40 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Hexproof TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,23 @@ +4 [ISD:79] Spectral Flight +4 [RTR:248] Temple Garden +4 [M13:185] Rancor +4 [RTR:9] Ethereal Armor +4 [RTR:11] Fencing Ace +4 [ISD:213] Geist of Saint Traft +4 [GTC:240] Breeding Pool +4 [ISD:60] Invisible Stalker +4 [ISD:241] Hinterland Harbor +4 [ISD:170] Avacyn's Pilgrim +4 [DGM:114] Voice of Resurgence +2 [GTC:195] Simic Charm +2 [M13:225] Glacial Fortress +4 [DGM:111] Unflinching Courage +4 [M13:229] Sunpetal Grove +4 [RTR:241] Hallowed Fountain +SB: 2 [M15:71] Negate +SB: 2 [M14:171] Fog +SB: 2 [AVR:31] Nearheath Pilgrim +SB: 2 [M13:176] Ground Seal +SB: 1 [ISD:14] Feeling of Dread +SB: 2 [ISD:25] Nevermore +SB: 4 [DKA:127] Strangleroot Geist diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Megamorph TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Megamorph TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..fd9481d5443 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Megamorph TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,31 @@ +4 [KTK:248] Windswept Heath +2 [FRF:19] Mastery of the Unseen +3 [FRF:28] Valorous Stance +1 [UNH:137] Island +2 [JOU:163] Mana Confluence +2 [UNH:136] Plains +3 [KTK:233] Flooded Strand +2 [DTK:219] Dragonlord Ojutai +3 [DTK:221] Dromoka's Command +4 [BNG:165] Temple of Plenty +1 [DTK:23] Hidden Dragonslayer +2 [DTK:210] Surrak, the Hunt Caller +1 [THS:226] Temple of Mystery +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +4 [THS:193] Fleecemane Lion +1 [THS:172] Polukranos, World Eater +3 [M15:249] Yavimaya Coast +1 [DTK:181] Den Protector +4 [DTK:180] Deathmist Raptor +4 [UNH:140] Forest +3 [BNG:119] Courser of Kruphix +2 [FRF:145] Whisperwood Elemental +SB: 2 [DTK:54] Encase in Ice +SB: 2 [DTK:65] Negate +SB: 2 [M15:177] Hornet Nest +SB: 1 [THS:15] Glare of Heresy +SB: 3 [KTK:37] Disdainful Stroke +SB: 2 [DTK:80] Stratus Dancer +SB: 2 [THS:150] Arbor Colossus +SB: 1 [DTK:70] Profaner of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..20025d07b86 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,36 @@ +2 [UNH:137] Island +2 [UNH:136] Plains +1 [ISD:77] Skaab Ruinator +1 [M12:6] Archon of Justice +4 [MBS:95] Viridian Emissary +2 [M12:72] Phantasmal Image +1 [C14:112] Frost Titan +1 [SOM:135] Venser, the Sojourner +2 [M13:22] Oblivion Ring +1 [C14:91] Sun Titan +2 [C14:271] Solemn Simulacrum +6 [UNH:140] Forest +4 [NPH:104] Birthing Pod +4 [M12:165] Birds of Paradise +1 [NPH:9] Elesh Norn, Grand Cenobite +4 [ISD:241] Hinterland Harbor +2 [NPH:4] Blade Splicer +1 [C14:283] Wurmcoil Engine +3 [SOM:229] Seachrome Coast +2 [ISD:170] Avacyn's Pilgrim +4 [SOM:228] Razorverge Thicket +1 [C13:11] Fiend Hunter +3 [M13:229] Sunpetal Grove +2 [NPH:42] Phyrexian Metamorph +2 [SOM:175] Mimic Vat +2 [C13:134] Acidic Slime +SB: 1 [M12:64] Master Thief +SB: 2 [MBS:14] Mirran Crusader +SB: 3 [M12:40] Timely Reinforcements +SB: 1 [SOM:209] Sylvok Lifestaff +SB: 1 [ISD:188] Hollowhenge Scavenger +SB: 1 [SOM:48] Trinket Mage +SB: 2 [C13:249] Nihil Spellbomb +SB: 2 [MBS:78] Creeping Corrosion +SB: 1 [M12:6] Archon of Justice +SB: 1 [MBS:92] Thrun, the Last Troll diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..e0f57b47650 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bant Pod TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,40 @@ +2 [UNH:137] Island +2 [UNH:136] Plains +3 [MBS:95] Viridian Emissary +1 [M12:6] Archon of Justice +1 [ISD:77] Skaab Ruinator +2 [M12:72] Phantasmal Image +1 [C14:112] Frost Titan +2 [M13:22] Oblivion Ring +1 [C14:91] Sun Titan +1 [MBS:8] Hero of Bladehold +1 [C14:271] Solemn Simulacrum +6 [UNH:140] Forest +4 [NPH:104] Birthing Pod +4 [M12:165] Birds of Paradise +1 [C14:79] Mentor of the Meek +1 [NPH:9] Elesh Norn, Grand Cenobite +4 [ISD:241] Hinterland Harbor +1 [ISD:207] Tree of Redemption +1 [FNMP:147] Avacyn's Pilgrim +1 [ISD:193] Mayor of Avabruck +1 [NPH:4] Blade Splicer +1 [C14:283] Wurmcoil Engine +1 [ISD:170] Avacyn's Pilgrim +3 [SOM:229] Seachrome Coast +4 [SOM:228] Razorverge Thicket +2 [NPH:42] Phyrexian Metamorph +3 [M13:229] Sunpetal Grove +1 [C13:11] Fiend Hunter +2 [SOM:175] Mimic Vat +2 [C13:134] Acidic Slime +SB: 1 [M12:64] Master Thief +SB: 2 [MBS:14] Mirran Crusader +SB: 3 [M12:40] Timely Reinforcements +SB: 1 [SOM:209] Sylvok Lifestaff +SB: 1 [SOM:48] Trinket Mage +SB: 1 [ISD:188] Hollowhenge Scavenger +SB: 1 [MBS:8] Hero of Bladehold +SB: 2 [C13:249] Nihil Spellbomb +SB: 2 [MBS:78] Creeping Corrosion +SB: 1 [ISD:207] Tree of Redemption diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bg Zombie TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bg Zombie TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..7d393a4a789 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bg Zombie TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,23 @@ +2 [UNH:140] Forest +2 [RTR:120] Deadbridge Goliath +2 [RTR:164] Golgari Charm +4 [M13:185] Rancor +4 [RTR:243] Overgrown Tomb +3 [RTR:221] Rakdos Shred-Freak +4 [RTR:177] Lotleth Troll +4 [ISD:97] Diregraf Ghoul +3 [C14:167] Tragic Slip +4 [AVR:226] Cavern of Souls +4 [DKA:63] Geralf's Messenger +4 [RTR:158] Dreg Mangler +4 [DKA:64] Gravecrawler +4 [ISD:249] Woodland Cemetery +3 [M15:92] Crippling Blight +9 [UNH:138] Swamp +SB: 1 [M13:193] Thragtusk +SB: 3 [C13:97] Vampire Nighthawk +SB: 3 [AVR:84] Appetite for Brains +SB: 2 [RTR:213] Deathrite Shaman +SB: 2 [ISD:115] Sever the Bloodline +SB: 2 [RTR:120] Deadbridge Goliath +SB: 2 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Birthing Pod TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Birthing Pod TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..51b66b4fa5e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Birthing Pod TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,31 @@ +4 [M13:229] Sunpetal Grove +1 [M13:228] Rootbound Crag +8 [UNH:140] Forest +4 [MBS:95] Viridian Emissary +1 [NPH:4] Blade Splicer +4 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +4 [M12:165] Birds of Paradise +2 [NPH:104] Birthing Pod +1 [UNH:139] Mountain +1 [C14:258] Palladium Myr +2 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [NPH:9] Elesh Norn, Grand Cenobite +4 [SOM:228] Razorverge Thicket +2 [C14:283] Wurmcoil Engine +2 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +2 [M12:12] Day of Judgment +3 [UNH:136] Plains +SB: 2 [NPH:86] Gut Shot +SB: 1 [C14:298] Ghost Quarter +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [M12:12] Day of Judgment +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 2 [NPH:103] Beast Within +SB: 2 [M12:40] Timely Reinforcements +SB: 2 [M12:164] Autumn's Veil +SB: 1 [M12:197] Stingerfling Spider +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Black Kessig TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Black Kessig TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..fd9a777682e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Black Kessig TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,32 @@ +1 [MBS:43] Go for the Throat +6 [UNH:140] Forest +1 [MBS:96] Glissa, the Traitor +2 [MBS:81] Green Sun's Zenith +1 [M13:222] Dragonskull Summit +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +1 [UNH:139] Mountain +3 [C14:136] Black Sun's Zenith +2 [C13:134] Acidic Slime +4 [C14:145] Grave Titan +1 [C14:298] Ghost Quarter +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +2 [M14:215] Ratchet Bomb +2 [C14:295] Evolving Wilds +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +3 [M14:96] Doom Blade +4 [ISD:249] Woodland Cemetery +4 [UNH:138] Swamp +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 1 [C14:136] Black Sun's Zenith +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [NPH:130] Batterskull +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [ISD:207] Tree of Redemption +SB: 2 [C13:249] Nihil Spellbomb +SB: 2 [ISD:94] Curse of Death's Hold +SB: 1 [ISD:105] Liliana of the Veil +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Bolt Caw-Blade TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Bolt Caw-Blade TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..6fef8d58c9d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Bolt Caw-Blade TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,31 @@ +3 [WWK:133] Celestial Colonnade +1 [WWK:122] Basilisk Collar +2 [M12:16] Gideon Jura +3 [M11:149] Lightning Bolt +1 [M13:225] Glacial Fortress +4 [ZEN:211] Arid Mesa +4 [UNH:139] Mountain +1 [C13:114] Inferno Titan +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +1 [MBS:138] Sword of Feast and Famine +1 [C14:295] Evolving Wilds +4 [SOM:229] Seachrome Coast +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +2 [SOM:81] Arc Trail +2 [UNH:136] Plains +3 [UNH:137] Island +3 [WWK:79] Cunning Sparkmage +2 [M12:63] Mana Leak +SB: 1 [C13:114] Inferno Titan +SB: 1 [MBS:5] Divine Offering +SB: 1 [ROE:59] Deprive +SB: 1 [SOM:208] Sword of Body and Mind +SB: 2 [SOM:50] Twisted Image +SB: 2 [M11:154] Pyroclasm +SB: 1 [WWK:79] Cunning Sparkmage +SB: 2 [M12:63] Mana Leak +SB: 4 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..6713536ffa1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,27 @@ +2 [FRF:110] Outpost Siege +1 [FRF:175] Wind-Scarred Crag +2 [BNG:5] Brimaz, King of Oreskos +4 [THS:143] Stormbreath Dragon +2 [FRF:118] Wild Slash +4 [KTK:22] Seeker of the Way +4 [M15:240] Battlefield Forge +4 [THS:228] Temple of Triumph +4 [M15:164] Stoke the Flames +10 [UNH:139] Mountain +3 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +2 [M15:134] Chandra, Pyromaster +4 [KTK:111] Hordeling Outburst +4 [THS:4] Chained to the Rocks +1 [C14:295] Evolving Wilds +4 [UNH:136] Plains +1 [FRF:27] Soulfire Grand Master +SB: 2 [FRF:28] Valorous Stance +SB: 2 [M15:15] Hushwing Gryff +SB: 1 [M15:135] Circle of Flame +SB: 3 [THS:15] Glare of Heresy +SB: 1 [KTK:9] Erase +SB: 2 [KTK:97] Arc Lightning +SB: 1 [FRF:2] Abzan Advantage +SB: 1 [BNG:110] Scouring Sands +SB: 2 [KTK:119] Sarkhan, the Dragonspeaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..ea58c669a62 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,24 @@ +4 [RTR:86] Ash Zealot +1 [THS:143] Stormbreath Dragon +4 [THS:122] Firedrinker Satyr +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +3 [M14:163] Young Pyromancer +11 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:134] Chandra, Pyromaster +3 [M14:155] Shock +1 [DGM:36] Pyrewild Shaman +4 [M14:134] Chandra's Phoenix +2 [THS:4] Chained to the Rocks +4 [RTR:220] Rakdos Cackler +1 [M14:139] Flames of the Firebrand +4 [M14:228] Mutavault +4 [GTC:245] Sacred Foundry +SB: 2 [RTR:101] Mizzium Mortars +SB: 2 [THS:4] Chained to the Rocks +SB: 1 [THS:143] Stormbreath Dragon +SB: 2 [THS:121] Fanatic of Mogis +SB: 4 [GTC:215] Boros Reckoner +SB: 3 [GTC:106] Skullcrack +SB: 1 [M14:217] Rod of Ruin diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..02bea981684 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,23 @@ +4 [GTC:106] Skullcrack +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +4 [M14:163] Young Pyromancer +9 [UNH:139] Mountain +4 [M15:155] Lightning Strike +3 [M14:155] Shock +4 [C13:179] Boros Charm +4 [M14:134] Chandra's Phoenix +2 [THS:4] Chained to the Rocks +4 [M14:228] Mutavault +4 [DGM:116] Warleader's Helix +2 [C13:280] Boros Guildgate +4 [GTC:245] Sacred Foundry +4 [BNG:111] Searing Blood +SB: 2 [THS:124] Hammer of Purphoros +SB: 2 [JOU:18] Nyx-Fleece Ram +SB: 1 [RTR:101] Mizzium Mortars +SB: 2 [THS:4] Chained to the Rocks +SB: 4 [GTC:215] Boros Reckoner +SB: 2 [JOU:5] Banishing Light +SB: 1 [THS:112] Anger of the Gods +SB: 1 [THS:9] Elspeth, Sun's Champion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..bc31e4cf728 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [RTR:86] Ash Zealot +2 [THS:143] Stormbreath Dragon +4 [GTC:215] Boros Reckoner +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +11 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:134] Chandra, Pyromaster +4 [C13:179] Boros Charm +4 [M14:134] Chandra's Phoenix +3 [THS:4] Chained to the Rocks +3 [M14:228] Mutavault +2 [DGM:116] Warleader's Helix +2 [C13:280] Boros Guildgate +4 [GTC:245] Sacred Foundry +3 [BNG:111] Searing Blood +SB: 2 [BNG:94] Fated Conflagration +SB: 2 [RTR:101] Mizzium Mortars +SB: 1 [THS:4] Chained to the Rocks +SB: 4 [THS:122] Firedrinker Satyr +SB: 4 [GTC:106] Skullcrack +SB: 2 [GTC:199] Spark Trooper diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..3537da50af4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Aggro TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,29 @@ +4 [FRF:110] Outpost Siege +3 [FRF:118] Wild Slash +2 [KTK:237] Nomad Outpost +4 [KTK:22] Seeker of the Way +1 [KTK:202] Sorin, Solemn Visitor +3 [THS:228] Temple of Triumph +4 [M15:240] Battlefield Forge +4 [M15:164] Stoke the Flames +5 [UNH:139] Mountain +2 [M15:155] Lightning Strike +3 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +4 [THS:4] Chained to the Rocks +4 [KTK:230] Bloodstained Mire +2 [DTK:248] Evolving Wilds +3 [KTK:171] Crackling Doom +3 [UNH:136] Plains +1 [UNH:138] Swamp +4 [FRF:27] Soulfire Grand Master +SB: 1 [FRF:28] Valorous Stance +SB: 1 [KTK:210] Utter End +SB: 2 [KTK:186] Mardu Charm +SB: 1 [KTK:9] Erase +SB: 3 [THS:143] Stormbreath Dragon +SB: 1 [KTK:171] Crackling Doom +SB: 2 [KTK:97] Arc Lightning +SB: 1 [KTK:119] Sarkhan, the Dragonspeaker +SB: 2 [KTK:99] Ashcloud Phoenix +SB: 1 [KTK:202] Sorin, Solemn Visitor diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..c83d2436096 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [GTC:106] Skullcrack +2 [THS:227] Temple of Silence +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +5 [UNH:139] Mountain +4 [M15:155] Lightning Strike +3 [M14:155] Shock +4 [C13:179] Boros Charm +4 [M14:134] Chandra's Phoenix +2 [THS:4] Chained to the Rocks +4 [DGM:133] Toil // Trouble +4 [RTR:238] Blood Crypt +4 [M14:228] Mutavault +4 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +4 [BNG:111] Searing Blood +SB: 2 [GTC:6] Blind Obedience +SB: 1 [M15:134] Chandra, Pyromaster +SB: 2 [THS:4] Chained to the Rocks +SB: 4 [BNG:108] Satyr Firedancer +SB: 4 [THS:122] Firedrinker Satyr +SB: 2 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..d8c572cbd7b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,21 @@ +1 [THS:224] Temple of Abandon +3 [THS:143] Stormbreath Dragon +4 [THS:112] Anger of the Gods +4 [THS:227] Temple of Silence +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +10 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:134] Chandra, Pyromaster +4 [C13:179] Boros Charm +4 [M14:155] Shock +2 [RTR:101] Mizzium Mortars +4 [M14:134] Chandra's Phoenix +4 [THS:4] Chained to the Rocks +3 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +SB: 1 [RTR:101] Mizzium Mortars +SB: 4 [DGM:133] Toil // Trouble +SB: 4 [GTC:215] Boros Reckoner +SB: 4 [GTC:106] Skullcrack +SB: 2 [GTC:142] Assemble the Legion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..26d7627c38e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,25 @@ +4 [GTC:106] Skullcrack +1 [THS:227] Temple of Silence +4 [THS:128] Magma Jet +4 [THS:228] Temple of Triumph +4 [M14:163] Young Pyromancer +8 [UNH:139] Mountain +4 [M15:155] Lightning Strike +3 [M14:155] Shock +4 [C13:179] Boros Charm +4 [M14:134] Chandra's Phoenix +3 [THS:4] Chained to the Rocks +1 [BNG:164] Temple of Malice +3 [M14:228] Mutavault +2 [JOU:163] Mana Confluence +4 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +3 [BNG:111] Searing Blood +SB: 1 [BNG:94] Fated Conflagration +SB: 3 [RTR:101] Mizzium Mortars +SB: 1 [M15:134] Chandra, Pyromaster +SB: 1 [THS:4] Chained to the Rocks +SB: 2 [THS:15] Glare of Heresy +SB: 3 [DGM:133] Toil // Trouble +SB: 2 [JOU:5] Banishing Light +SB: 2 [JOU:94] Eidolon of the Great Revel diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..4367eed457f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Burn TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [GTC:106] Skullcrack +4 [THS:128] Magma Jet +2 [M14:161] Wild Guess +4 [THS:228] Temple of Triumph +9 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M14:155] Shock +4 [C13:179] Boros Charm +4 [M14:134] Chandra's Phoenix +2 [THS:4] Chained to the Rocks +4 [M14:228] Mutavault +2 [JOU:163] Mana Confluence +4 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +3 [BNG:111] Searing Blood +4 [JOU:94] Eidolon of the Great Revel +SB: 2 [THS:4] Chained to the Rocks +SB: 4 [BNG:108] Satyr Firedancer +SB: 4 [THS:122] Firedrinker Satyr +SB: 2 [KTK:95] Act of Treason +SB: 2 [DGM:135] Wear // Tear +SB: 1 [JOU:93] Dictate of the Twin Gods diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..dd67fb5626a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,28 @@ +1 [MBS:66] Hero of Oxid Ridge +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +1 [C14:229] Bonehoard +2 [C14:315] Terramorphic Expanse +1 [ZEN:195] Adventuring Gear +4 [ZEN:141] Plated Geopede +5 [UNH:139] Mountain +4 [ZEN:36] Steppe Lynx +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +2 [CMD:17] Journey to Nowhere +4 [ZEN:126] Goblin Guide +1 [SOM:208] Sword of Body and Mind +2 [ZEN:226] Teetering Peaks +4 [M11:33] Squadron Hawk +3 [SOM:94] Koth of the Hammer +2 [SOM:104] Spikeshot Elder +3 [WWK:20] Stoneforge Mystic +5 [UNH:136] Plains +SB: 2 [M13:141] Mark of Mutiny +SB: 1 [C13:114] Inferno Titan +SB: 1 [MBS:5] Divine Offering +SB: 1 [WWK:122] Basilisk Collar +SB: 2 [M12:16] Gideon Jura +SB: 4 [WWK:11] Kor Firewalker +SB: 1 [SOM:94] Koth of the Hammer +SB: 3 [WWK:79] Cunning Sparkmage diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..11d07714d3a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,28 @@ +2 [MBS:66] Hero of Oxid Ridge +3 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +2 [ZEN:195] Adventuring Gear +4 [ZEN:141] Plated Geopede +5 [UNH:139] Mountain +4 [ZEN:36] Steppe Lynx +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +2 [CMD:17] Journey to Nowhere +1 [MBS:138] Sword of Feast and Famine +4 [ZEN:126] Goblin Guide +1 [SOM:208] Sword of Body and Mind +1 [ZEN:226] Teetering Peaks +3 [C14:295] Evolving Wilds +4 [M11:33] Squadron Hawk +1 [SOM:94] Koth of the Hammer +1 [SOM:104] Spikeshot Elder +3 [WWK:20] Stoneforge Mystic +5 [UNH:136] Plains +2 [MBS:14] Mirran Crusader +SB: 1 [M13:141] Mark of Mutiny +SB: 1 [WWK:122] Basilisk Collar +SB: 3 [WWK:11] Kor Firewalker +SB: 1 [SOM:94] Koth of the Hammer +SB: 4 [SOM:81] Arc Trail +SB: 1 [MBS:14] Mirran Crusader +SB: 4 [WWK:79] Cunning Sparkmage diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..f5d673e0fa2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,22 @@ +3 [MBS:97] Tezzeret, Agent of Bolas +2 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +4 [NPH:162] Torpor Orb +4 [M13:223] Drowned Catacomb +3 [ROE:115] Inquisition of Kozilek +4 [C14:239] Everflowing Chalice +2 [KTK:69] Despise +1 [ROE:100] Consume the Meek +3 [C14:313] Tectonic Edge +1 [C14:136] Black Sun's Zenith +4 [M11:70] Preordain +2 [ZEN:87] Disfigure +3 [SOM:218] Tumble Magnet +1 [C14:283] Wurmcoil Engine +2 [MBS:145] Inkmoth Nexus +2 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +2 [WWK:31] Jace, the Mind Sculptor +4 [UNH:137] Island +3 [UNH:138] Swamp +2 [M12:63] Mana Leak diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..c89544ffeb7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Landfall TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,29 @@ +2 [MBS:66] Hero of Oxid Ridge +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +1 [C14:229] Bonehoard +3 [C14:315] Terramorphic Expanse +2 [ZEN:195] Adventuring Gear +4 [ZEN:141] Plated Geopede +5 [UNH:139] Mountain +4 [ZEN:36] Steppe Lynx +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +2 [CMD:17] Journey to Nowhere +4 [ZEN:126] Goblin Guide +1 [SOM:208] Sword of Body and Mind +1 [ZEN:226] Teetering Peaks +4 [M11:33] Squadron Hawk +1 [SOM:94] Koth of the Hammer +1 [SOM:104] Spikeshot Elder +3 [WWK:20] Stoneforge Mystic +5 [UNH:136] Plains +1 [MBS:14] Mirran Crusader +SB: 2 [M13:141] Mark of Mutiny +SB: 2 [MBS:5] Divine Offering +SB: 1 [M12:16] Gideon Jura +SB: 3 [WWK:11] Kor Firewalker +SB: 1 [M11:7] Baneslayer Angel +SB: 1 [SOM:94] Koth of the Hammer +SB: 4 [SOM:81] Arc Trail +SB: 1 [ROE:146] Forked Bolt diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Boros Midrange TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Boros Midrange TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..28564958291 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Boros Midrange TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,24 @@ +1 [M15:15] Hushwing Gryff +3 [BNG:5] Brimaz, King of Oreskos +4 [THS:143] Stormbreath Dragon +1 [KTK:99] Ashcloud Phoenix +4 [KTK:22] Seeker of the Way +1 [THS:128] Magma Jet +4 [M15:240] Battlefield Forge +4 [THS:228] Temple of Triumph +4 [M15:164] Stoke the Flames +10 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +2 [M15:134] Chandra, Pyromaster +4 [KTK:111] Hordeling Outburst +4 [THS:4] Chained to the Rocks +1 [C14:295] Evolving Wilds +5 [UNH:136] Plains +SB: 3 [M15:15] Hushwing Gryff +SB: 1 [M15:134] Chandra, Pyromaster +SB: 3 [THS:15] Glare of Heresy +SB: 3 [KTK:9] Erase +SB: 1 [JOU:5] Banishing Light +SB: 2 [KTK:119] Sarkhan, the Dragonspeaker +SB: 2 [BNG:110] Scouring Sands diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..b7f33f4df0c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,22 @@ +4 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +2 [M11:90] Dark Tutelage +2 [M13:141] Mark of Mutiny +2 [ZEN:119] Burst Lightning +4 [WWK:62] Pulse Tracker +2 [ZEN:115] Vampire Lacerator +2 [SOM:208] Sword of Body and Mind +4 [SOM:224] Blackcleave Cliffs +2 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +12 [UNH:138] Swamp +SB: 1 [M13:141] Mark of Mutiny +SB: 1 [M11:90] Dark Tutelage +SB: 3 [M12:151] Manic Vandal +SB: 4 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 2 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..3ee00a7f902 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,25 @@ +2 [MBS:43] Go for the Throat +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +2 [M11:90] Dark Tutelage +1 [C14:168] Vampire Hexmage +3 [ZEN:219] Marsh Flats +4 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +2 [M11:87] Captivating Vampire +4 [SOM:224] Blackcleave Cliffs +3 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +8 [UNH:138] Swamp +SB: 1 [M11:90] Dark Tutelage +SB: 2 [M13:141] Mark of Mutiny +SB: 1 [C14:168] Vampire Hexmage +SB: 3 [M11:92] Demon of Death's Gate +SB: 2 [SOM:78] Skinrender +SB: 2 [C13:97] Vampire Nighthawk +SB: 2 [M14:97] Duress +SB: 2 [ROE:146] Forked Bolt diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..ee4774b5cd7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,26 @@ +1 [MBS:43] Go for the Throat +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +2 [M12:145] Grim Lavamancer +3 [ROE:115] Inquisition of Kozilek +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +3 [ZEN:229] Verdant Catacombs +2 [ZEN:219] Marsh Flats +3 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +3 [NPH:57] Dismember +2 [M14:96] Doom Blade +4 [SOM:224] Blackcleave Cliffs +4 [WWK:59] Kalastria Highborn +6 [UNH:138] Swamp +SB: 4 [M12:151] Manic Vandal +SB: 1 [MBS:43] Go for the Throat +SB: 3 [M11:92] Demon of Death's Gate +SB: 2 [NPH:78] Act of Aggression +SB: 1 [M14:97] Duress +SB: 1 [M12:145] Grim Lavamancer +SB: 1 [KTK:69] Despise +SB: 2 [M12:110] Sorin's Thirst diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..0edede07f74 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,22 @@ +4 [MBS:43] Go for the Throat +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +3 [M12:151] Manic Vandal +4 [ZEN:89] Gatekeeper of Malakir +4 [ZEN:229] Verdant Catacombs +1 [ZEN:219] Marsh Flats +4 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +3 [NPH:57] Dismember +4 [SOM:224] Blackcleave Cliffs +4 [WWK:59] Kalastria Highborn +6 [UNH:138] Swamp +SB: 3 [M13:141] Mark of Mutiny +SB: 3 [M11:90] Dark Tutelage +SB: 2 [SOM:78] Skinrender +SB: 2 [MBS:61] Crush +SB: 1 [M14:96] Doom Blade +SB: 4 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..82dc53721dc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,24 @@ +3 [MBS:43] Go for the Throat +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +4 [ZEN:229] Verdant Catacombs +4 [C14:168] Vampire Hexmage +1 [ZEN:219] Marsh Flats +3 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +4 [SOM:224] Blackcleave Cliffs +4 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +6 [UNH:138] Swamp +SB: 2 [M11:90] Dark Tutelage +SB: 1 [M13:141] Mark of Mutiny +SB: 2 [M11:92] Demon of Death's Gate +SB: 3 [SOM:78] Skinrender +SB: 2 [MBS:61] Crush +SB: 1 [M14:96] Doom Blade +SB: 2 [M14:97] Duress +SB: 2 [ROE:115] Inquisition of Kozilek diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..043194e4554 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Br Vampires TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,30 @@ +1 [MBS:43] Go for the Throat +4 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [ROE:115] Inquisition of Kozilek +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +1 [M13:141] Mark of Mutiny +2 [ZEN:229] Verdant Catacombs +2 [C14:168] Vampire Hexmage +3 [ZEN:219] Marsh Flats +4 [ZEN:115] Vampire Lacerator +2 [NPH:78] Act of Aggression +1 [NPH:57] Dismember +4 [SOM:224] Blackcleave Cliffs +2 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +1 [M13:83] Bloodthrone Vampire +5 [UNH:138] Swamp +SB: 1 [M13:141] Mark of Mutiny +SB: 2 [M11:90] Dark Tutelage +SB: 3 [M12:151] Manic Vandal +SB: 1 [MBS:43] Go for the Throat +SB: 2 [NPH:74] Surgical Extraction +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [NPH:78] Act of Aggression +SB: 2 [NPH:68] Phyrexian Obliterator +SB: 1 [SOM:81] Arc Trail +SB: 1 [KTK:69] Despise diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..3dccdaff9e1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,32 @@ +4 [WWK:133] Celestial Colonnade +3 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +2 [C14:69] Condemn +4 [C14:313] Tectonic Edge +1 [C14:115] Into the Roil +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [ZEN:223] Scalding Tarn +1 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [SOM:218] Tumble Magnet +1 [MBS:145] Inkmoth Nexus +4 [M11:33] Squadron Hawk +1 [MBS:115] Mortarpod +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +2 [M12:12] Day of Judgment +4 [UNH:136] Plains +4 [UNH:137] Island +3 [M12:63] Mana Leak +SB: 2 [MBS:5] Divine Offering +SB: 2 [CMD:17] Journey to Nowhere +SB: 1 [ROE:59] Deprive +SB: 1 [MBS:138] Sword of Feast and Famine +SB: 1 [SOM:209] Sylvok Lifestaff +SB: 1 [C14:91] Sun Titan +SB: 1 [M11:7] Baneslayer Angel +SB: 2 [SOM:53] Volition Reins +SB: 1 [M12:12] Day of Judgment +SB: 1 [C14:69] Condemn +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..16ca9516195 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,29 @@ +2 [MBS:21] Consecrated Sphinx +4 [WWK:133] Celestial Colonnade +1 [M11:58] Jace Beleren +3 [M12:16] Gideon Jura +3 [M13:225] Glacial Fortress +1 [ZEN:211] Arid Mesa +4 [C14:313] Tectonic Edge +2 [ZEN:67] Spell Pierce +3 [C14:115] Into the Roil +4 [M11:70] Preordain +2 [ZEN:223] Scalding Tarn +2 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [ZEN:11] Emeria Angel +3 [NPH:57] Dismember +2 [MBS:145] Inkmoth Nexus +4 [M11:33] Squadron Hawk +2 [M12:12] Day of Judgment +3 [UNH:136] Plains +4 [UNH:137] Island +2 [M12:40] Timely Reinforcements +3 [M12:63] Mana Leak +SB: 2 [C14:98] Azure Mage +SB: 1 [M11:58] Jace Beleren +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M12:12] Day of Judgment +SB: 3 [NPH:38] Mental Misstep +SB: 2 [M12:40] Timely Reinforcements +SB: 4 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..0d6129c72bb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,26 @@ +4 [WWK:133] Celestial Colonnade +1 [ROE:59] Deprive +1 [SOM:46] Stoic Rebuttal +3 [M12:16] Gideon Jura +1 [ZEN:220] Misty Rainforest +4 [M13:225] Glacial Fortress +4 [C14:313] Tectonic Edge +4 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [SOM:209] Sylvok Lifestaff +1 [SOM:208] Sword of Body and Mind +4 [SOM:229] Seachrome Coast +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:12] Day of Judgment +4 [UNH:136] Plains +5 [UNH:137] Island +3 [M12:63] Mana Leak +SB: 2 [MBS:5] Divine Offering +SB: 1 [SOM:208] Sword of Body and Mind +SB: 3 [M14:215] Ratchet Bomb +SB: 2 [M11:7] Baneslayer Angel +SB: 4 [ROE:40] Oust +SB: 2 [M12:52] Flashfreeze +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..b6daf16052c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,28 @@ +4 [WWK:133] Celestial Colonnade +2 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +4 [NPH:4] Blade Splicer +4 [C14:313] Tectonic Edge +1 [C14:115] Into the Roil +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +3 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [NPH:57] Dismember +3 [MBS:145] Inkmoth Nexus +1 [C14:91] Sun Titan +4 [M11:33] Squadron Hawk +1 [M13:22] Oblivion Ring +1 [M12:12] Day of Judgment +4 [UNH:136] Plains +4 [UNH:137] Island +3 [MBS:8] Hero of Bladehold +4 [M12:63] Mana Leak +SB: 1 [C14:115] Into the Roil +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [WWK:11] Kor Firewalker +SB: 2 [M12:12] Day of Judgment +SB: 1 [M13:22] Oblivion Ring +SB: 2 [NPH:159] Spellskite +SB: 2 [M12:40] Timely Reinforcements +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..761ef03abb7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,31 @@ +1 [MBS:21] Consecrated Sphinx +4 [WWK:133] Celestial Colonnade +1 [M11:58] Jace Beleren +1 [NPH:161] Sword of War and Peace +3 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [MBS:5] Divine Offering +1 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +3 [NPH:57] Dismember +2 [MBS:145] Inkmoth Nexus +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +4 [UNH:136] Plains +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 2 [MBS:5] Divine Offering +SB: 1 [ROE:59] Deprive +SB: 1 [NPH:57] Dismember +SB: 1 [C14:91] Sun Titan +SB: 1 [NPH:130] Batterskull +SB: 1 [M12:11] Celestial Purge +SB: 1 [M12:12] Day of Judgment +SB: 3 [ROE:40] Oust +SB: 2 [C14:69] Condemn +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..fef58719256 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,27 @@ +4 [WWK:133] Celestial Colonnade +1 [ROE:59] Deprive +3 [M12:16] Gideon Jura +1 [ZEN:220] Misty Rainforest +4 [M13:225] Glacial Fortress +4 [C14:313] Tectonic Edge +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [MBS:138] Sword of Feast and Famine +1 [SOM:209] Sylvok Lifestaff +1 [SOM:208] Sword of Body and Mind +4 [SOM:229] Seachrome Coast +1 [C14:91] Sun Titan +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:12] Day of Judgment +4 [UNH:136] Plains +5 [UNH:137] Island +3 [M12:63] Mana Leak +SB: 3 [MBS:5] Divine Offering +SB: 1 [C14:91] Sun Titan +SB: 2 [M11:7] Baneslayer Angel +SB: 1 [MBS:115] Mortarpod +SB: 3 [ROE:40] Oust +SB: 2 [C14:69] Condemn +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..4f3c624f75d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,25 @@ +4 [WWK:133] Celestial Colonnade +2 [M11:58] Jace Beleren +1 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +2 [C14:69] Condemn +4 [C14:313] Tectonic Edge +3 [C14:115] Into the Roil +4 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [MBS:145] Inkmoth Nexus +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +3 [UNH:136] Plains +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 3 [MBS:5] Divine Offering +SB: 4 [M11:21] Leyline of Sanctity +SB: 2 [C14:91] Sun Titan +SB: 1 [MBS:115] Mortarpod +SB: 2 [M12:12] Day of Judgment +SB: 3 [ROE:40] Oust diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..bd01e2df5f4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Caw-Blade TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,29 @@ +4 [WWK:133] Celestial Colonnade +2 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +3 [NPH:4] Blade Splicer +1 [ZEN:211] Arid Mesa +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +1 [ZEN:223] Scalding Tarn +3 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [ZEN:11] Emeria Angel +2 [NPH:57] Dismember +2 [MBS:145] Inkmoth Nexus +1 [C14:91] Sun Titan +4 [M11:33] Squadron Hawk +2 [M13:22] Oblivion Ring +3 [UNH:136] Plains +2 [M12:72] Phantasmal Image +3 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 1 [M11:58] Jace Beleren +SB: 1 [C14:91] Sun Titan +SB: 2 [NPH:38] Mental Misstep +SB: 1 [M12:72] Phantasmal Image +SB: 2 [C14:69] Condemn +SB: 4 [M12:40] Timely Reinforcements +SB: 4 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Cawless UW Control TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Cawless UW Control TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..ab90f6f0f40 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Cawless UW Control TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,29 @@ +4 [WWK:133] Celestial Colonnade +2 [M11:58] Jace Beleren +2 [SOM:46] Stoic Rebuttal +2 [M12:16] Gideon Jura +2 [ZEN:70] Spreading Seas +1 [ZEN:220] Misty Rainforest +4 [M13:225] Glacial Fortress +2 [M11:7] Baneslayer Angel +3 [CMD:37] Wall of Omens +2 [C14:69] Condemn +4 [C14:313] Tectonic Edge +3 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +2 [CMD:17] Journey to Nowhere +3 [SOM:229] Seachrome Coast +2 [C14:91] Sun Titan +3 [WWK:31] Jace, the Mind Sculptor +2 [M12:12] Day of Judgment +4 [UNH:136] Plains +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 4 [ZEN:25] Luminarch Ascension +SB: 1 [M11:58] Jace Beleren +SB: 2 [M14:215] Ratchet Bomb +SB: 2 [ZEN:70] Spreading Seas +SB: 1 [M11:7] Baneslayer Angel +SB: 1 [M12:12] Day of Judgment +SB: 2 [M12:52] Flashfreeze +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Charmed TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Charmed TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..ba172b550cf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Charmed TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,30 @@ +3 [AVR:32] Restoration Angel +4 [C13:30] Augur of Bolas +4 [GTC:215] Boros Reckoner +2 [M13:225] Glacial Fortress +3 [M13:147] Searing Spear +2 [RTR:241] Hallowed Fountain +2 [RTR:172] Izzet Charm +3 [ISD:78] Snapcaster Mage +1 [CNS:74] Moment of Heroism +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +4 [C13:179] Boros Charm +2 [AVR:226] Cavern of Souls +2 [AVR:149] Pillar of Flame +4 [RTR:247] Steam Vents +1 [M13:75] Unsummon +2 [C14:172] Blasphemous Act +4 [GTC:245] Sacred Foundry +1 [UNH:136] Plains +1 [UNH:137] Island +4 [ISD:238] Clifftop Retreat +4 [ISD:248] Sulfur Falls +SB: 2 [RTR:201] Supreme Verdict +SB: 2 [M13:150] Thundermaw Hellkite +SB: 2 [C14:278] Tormod's Crypt +SB: 1 [AVR:149] Pillar of Flame +SB: 1 [RTR:47] Psychic Spiral +SB: 4 [ISD:213] Geist of Saint Traft +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Cobra Valakut TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Cobra Valakut TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..a506899b5de --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Cobra Valakut TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,22 @@ +5 [UNH:140] Forest +3 [ZEN:220] Misty Rainforest +4 [ROE:203] Overgrown Battlement +3 [ZEN:167] Khalni Heart Expedition +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +3 [C14:315] Terramorphic Expanse +4 [ZEN:184] Summoning Trap +1 [C13:302] Khalni Garden +11 [UNH:139] Mountain +3 [C13:114] Inferno Titan +4 [ZEN:228] Valakut, the Molten Pinnacle +4 [ZEN:168] Lotus Cobra +4 [C14:199] Harrow +1 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 2 [C13:134] Acidic Slime +SB: 3 [CNS:171] Nature's Claim +SB: 2 [KTK:95] Act of Treason +SB: 3 [M11:188] Obstinate Baloth +SB: 1 [MBS:81] Green Sun's Zenith +SB: 4 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Darkblade TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Darkblade TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..b5c85577224 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Darkblade TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,31 @@ +3 [MBS:43] Go for the Throat +1 [NPH:161] Sword of War and Peace +4 [WWK:134] Creeping Tar Pit +3 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +2 [ZEN:211] Arid Mesa +4 [ROE:115] Inquisition of Kozilek +1 [KTK:69] Despise +1 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [ZEN:219] Marsh Flats +1 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [ZEN:11] Emeria Angel +4 [M11:33] Squadron Hawk +4 [SOM:226] Darkslick Shores +1 [M14:97] Duress +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +4 [UNH:136] Plains +2 [UNH:138] Swamp +2 [M12:63] Mana Leak +SB: 3 [MBS:5] Divine Offering +SB: 2 [NPH:74] Surgical Extraction +SB: 1 [C13:97] Vampire Nighthawk +SB: 1 [ZEN:11] Emeria Angel +SB: 1 [NPH:57] Dismember +SB: 1 [M14:97] Duress +SB: 1 [NPH:130] Batterskull +SB: 3 [NPH:159] Spellskite +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Delver Blade TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Delver Blade TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..6569d1f9c4a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Delver Blade TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,27 @@ +4 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +2 [NPH:86] Gut Shot +2 [ISD:231] Runechanter's Pike +4 [SOM:229] Seachrome Coast +3 [NPH:35] Gitaxian Probe +2 [M12:65] Merfolk Looter +3 [ISD:213] Geist of Saint Traft +2 [C14:80] Midnight Haunting +4 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +9 [UNH:137] Island +4 [M12:73] Ponder +3 [ISD:60] Invisible Stalker +4 [M12:63] Mana Leak +SB: 2 [MBS:5] Divine Offering +SB: 1 [NPH:86] Gut Shot +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M15:51] Dissipate +SB: 1 [M12:11] Celestial Purge +SB: 2 [M13:22] Oblivion Ring +SB: 2 [M12:72] Phantasmal Image +SB: 2 [M12:40] Timely Reinforcements +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..6688b64a1a5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,21 @@ +1 [RTR:82] Ultimate Price +4 [RTR:83] Underworld Connections +1 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +1 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +1 [BNG:61] Bile Blight +4 [C14:146] Gray Merchant of Asphodel +4 [M14:101] Lifebane Zombie +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +1 [M14:97] Duress +4 [GTC:63] Devour Flesh +19 [UNH:138] Swamp +SB: 4 [M15:232] Staff of the Death Magus +SB: 1 [BNG:61] Bile Blight +SB: 2 [C14:158] Read the Bones +SB: 3 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..095418fea55 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,21 @@ +2 [RTR:82] Ultimate Price +4 [RTR:83] Underworld Connections +3 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:107] Thoughtseize +4 [C14:146] Gray Merchant of Asphodel +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +1 [M14:96] Doom Blade +4 [GTC:222] Nightveil Specter +2 [GTC:63] Devour Flesh +1 [THS:85] Erebos, God of the Dead +19 [UNH:138] Swamp +SB: 3 [M14:101] Lifebane Zombie +SB: 2 [THS:100] Pharika's Cure +SB: 1 [M14:116] Shrivel +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 3 [THS:83] Dark Betrayal +SB: 1 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..e9ddb6bebd6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,19 @@ +1 [RTR:82] Ultimate Price +4 [RTR:83] Underworld Connections +4 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:107] Thoughtseize +3 [BNG:61] Bile Blight +4 [C14:146] Gray Merchant of Asphodel +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:222] Nightveil Specter +2 [GTC:63] Devour Flesh +18 [UNH:138] Swamp +SB: 3 [M14:101] Lifebane Zombie +SB: 2 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 2 [THS:83] Dark Betrayal +SB: 2 [BNG:65] Drown in Sorrow +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..2df4cd11510 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,20 @@ +1 [RTR:82] Ultimate Price +4 [RTR:83] Underworld Connections +3 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +2 [THS:100] Pharika's Cure +4 [RTR:63] Desecration Demon +1 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [C14:146] Gray Merchant of Asphodel +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:222] Nightveil Specter +3 [GTC:63] Devour Flesh +18 [UNH:138] Swamp +SB: 3 [M14:101] Lifebane Zombie +SB: 2 [THS:100] Pharika's Cure +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 3 [THS:83] Dark Betrayal +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..62202237046 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,23 @@ +1 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +2 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:107] Thoughtseize +3 [BNG:61] Bile Blight +4 [C14:146] Gray Merchant of Asphodel +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +2 [C14:161] Sign in Blood +4 [GTC:222] Nightveil Specter +2 [GTC:63] Devour Flesh +18 [UNH:138] Swamp +SB: 1 [RTR:82] Ultimate Price +SB: 1 [RTR:83] Underworld Connections +SB: 3 [M14:101] Lifebane Zombie +SB: 1 [M15:103] Liliana Vess +SB: 2 [THS:100] Pharika's Cure +SB: 2 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 1 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..f8114ec83b8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,19 @@ +1 [BNG:61] Bile Blight +1 [RTR:82] Ultimate Price +4 [RTR:83] Underworld Connections +4 [C14:146] Gray Merchant of Asphodel +4 [M14:101] Lifebane Zombie +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:63] Devour Flesh +4 [THS:107] Thoughtseize +22 [UNH:138] Swamp +SB: 1 [BNG:61] Bile Blight +SB: 1 [C14:158] Read the Bones +SB: 1 [RTR:231] Pithing Needle +SB: 4 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 2 [THS:83] Dark Betrayal +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..592d047014e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,17 @@ +4 [RTR:83] Underworld Connections +4 [C14:146] Gray Merchant of Asphodel +2 [THS:110] Whip of Erebos +3 [RTR:73] Pack Rat +4 [THS:100] Pharika's Cure +4 [RTR:63] Desecration Demon +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:222] Nightveil Specter +2 [THS:85] Erebos, God of the Dead +4 [THS:107] Thoughtseize +21 [UNH:138] Swamp +SB: 3 [RTR:82] Ultimate Price +SB: 4 [M14:215] Ratchet Bomb +SB: 1 [RTR:73] Pack Rat +SB: 3 [M14:97] Duress +SB: 4 [M14:98] Festering Newt diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..f2523f433eb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Black TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,21 @@ +1 [THS:223] Nykthos, Shrine to Nyx +4 [RTR:83] Underworld Connections +2 [THS:110] Whip of Erebos +2 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [C14:146] Gray Merchant of Asphodel +4 [M14:101] Lifebane Zombie +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [M14:96] Doom Blade +2 [GTC:63] Devour Flesh +1 [THS:85] Erebos, God of the Dead +16 [UNH:138] Swamp +SB: 4 [M14:123] Xathrid Necromancer +SB: 1 [RTR:231] Pithing Needle +SB: 4 [THS:100] Pharika's Cure +SB: 4 [M14:97] Duress +SB: 1 [GTC:63] Devour Flesh +SB: 1 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..5ffc130cefc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,23 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +3 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [C14:104] Cyclonic Rift +SB: 2 [THS:47] Dissolve +SB: 3 [THS:49] Gainsay +SB: 1 [GTC:44] Rapid Hybridization +SB: 2 [RTR:36] Dispel +SB: 1 [M14:53] Domestication +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..5c4037a895c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,23 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +3 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [JOU:162] Hall of Triumph +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [C14:104] Cyclonic Rift +SB: 2 [THS:47] Dissolve +SB: 3 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 1 [RTR:36] Dispel +SB: 2 [M14:53] Domestication +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 1 [M15:75] Polymorphist's Jest +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..3a8e3daf931 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,23 @@ +1 [THS:223] Nykthos, Shrine to Nyx +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [RTR:44] Jace, Architect of Thought +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [C14:104] Cyclonic Rift +SB: 1 [THS:46] Curse of the Swine +SB: 4 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 2 [GTC:44] Rapid Hybridization +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 3 [M14:53] Domestication +SB: 1 [THS:42] Bident of Thassa +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..ebc2ac9a9e6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,24 @@ +1 [THS:223] Nykthos, Shrine to Nyx +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [RTR:44] Jace, Architect of Thought +2 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 2 [C14:104] Cyclonic Rift +SB: 1 [THS:47] Dissolve +SB: 3 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 1 [GTC:44] Rapid Hybridization +SB: 1 [RTR:36] Dispel +SB: 2 [M14:53] Domestication +SB: 1 [THS:42] Bident of Thassa +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..4a725d14144 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [RTR:44] Jace, Architect of Thought +1 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [C14:104] Cyclonic Rift +SB: 1 [THS:46] Curse of the Swine +SB: 2 [THS:47] Dissolve +SB: 4 [THS:49] Gainsay +SB: 2 [GTC:44] Rapid Hybridization +SB: 1 [RTR:36] Dispel +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 1 [M14:53] Domestication +SB: 1 [THS:42] Bident of Thassa +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..33d00defc04 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +2 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 2 [THS:47] Dissolve +SB: 1 [THS:38] Annul +SB: 4 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 1 [GTC:44] Rapid Hybridization +SB: 1 [RTR:36] Dispel +SB: 1 [M14:53] Domestication +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 1 [RTR:45] Mizzium Skin +SB: 1 [M15:75] Polymorphist's Jest +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..3bb0b6321d7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:223] Nykthos, Shrine to Nyx +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [RTR:44] Jace, Architect of Thought +3 [JOU:162] Hall of Triumph +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 2 [C14:104] Cyclonic Rift +SB: 1 [THS:223] Nykthos, Shrine to Nyx +SB: 1 [THS:47] Dissolve +SB: 2 [THS:49] Gainsay +SB: 2 [DGM:11] AEtherling +SB: 1 [RTR:36] Dispel +SB: 1 [GTC:44] Rapid Hybridization +SB: 1 [M14:53] Domestication +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 1 [THS:42] Bident of Thassa +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..87b9f501c30 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,20 @@ +1 [THS:223] Nykthos, Shrine to Nyx +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +3 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 3 [THS:47] Dissolve +SB: 3 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 2 [M14:46] Claustrophobia +SB: 3 [M14:53] Domestication +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..ae1cbf30491 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [JOU:42] Hypnotic Siren +1 [GTC:44] Rapid Hybridization +3 [RTR:218] Judge's Familiar +4 [GTC:32] Cloudfin Raptor +2 [JOU:162] Hall of Triumph +1 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [C14:104] Cyclonic Rift +SB: 1 [THS:47] Dissolve +SB: 1 [RTR:231] Pithing Needle +SB: 2 [THS:49] Gainsay +SB: 2 [DGM:11] AEtherling +SB: 2 [GTC:44] Rapid Hybridization +SB: 2 [RTR:36] Dispel +SB: 2 [M14:53] Domestication +SB: 2 [M14:60] Jace, Memory Adept diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..e1179110f00 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:223] Nykthos, Shrine to Nyx +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [RTR:44] Jace, Architect of Thought +1 [M14:53] Domestication +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [THS:46] Curse of the Swine +SB: 1 [C14:104] Cyclonic Rift +SB: 1 [THS:47] Dissolve +SB: 4 [THS:49] Gainsay +SB: 2 [GTC:44] Rapid Hybridization +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 1 [M14:53] Domestication +SB: 1 [THS:42] Bident of Thassa +SB: 2 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..3bf028754aa --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Blue TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,22 @@ +2 [THS:57] Omenspeaker +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +3 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [M14:51] Disperse +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [RTR:44] Jace, Architect of Thought +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +1 [THS:42] Bident of Thassa +21 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [RTR:231] Pithing Needle +SB: 2 [DGM:11] AEtherling +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M14:228] Mutavault +SB: 1 [THS:71] Triton Tactics +SB: 3 [M15:83] Wall of Frost +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 3 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Boros TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Boros TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..ba49079ea00 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Boros TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,23 @@ +4 [THS:223] Nykthos, Shrine to Nyx +3 [THS:124] Hammer of Purphoros +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [THS:143] Stormbreath Dragon +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [THS:228] Temple of Triumph +12 [UNH:139] Mountain +2 [M15:134] Chandra, Pyromaster +3 [RTR:101] Mizzium Mortars +3 [THS:4] Chained to the Rocks +4 [RTR:215] Frostburn Weird +1 [C13:280] Boros Guildgate +4 [GTC:245] Sacred Foundry +SB: 1 [THS:135] Purphoros, God of the Forge +SB: 1 [RTR:101] Mizzium Mortars +SB: 3 [C13:179] Boros Charm +SB: 1 [THS:4] Chained to the Rocks +SB: 4 [THS:112] Anger of the Gods +SB: 2 [DGM:135] Wear // Tear +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 2 [GTC:142] Assemble the Legion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Dimir TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Dimir TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..ceeca050b03 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Dimir TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,20 @@ +4 [RTR:83] Underworld Connections +4 [THS:225] Temple of Deceit +2 [GTC:249] Watery Grave +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:107] Thoughtseize +2 [BNG:61] Bile Blight +4 [C14:146] Gray Merchant of Asphodel +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:222] Nightveil Specter +4 [GTC:63] Devour Flesh +16 [UNH:138] Swamp +SB: 4 [M14:101] Lifebane Zombie +SB: 1 [DGM:88] Notion Thief +SB: 2 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 1 [THS:83] Dark Betrayal +SB: 1 [BNG:65] Drown in Sorrow +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..b64425f1a58 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +1 [UNH:140] Forest +4 [RTR:73] Pack Rat +4 [JOU:165] Temple of Malady +4 [RTR:63] Desecration Demon +3 [RTR:141] Abrupt Decay +4 [THS:107] Thoughtseize +2 [BNG:61] Bile Blight +4 [M15:244] Llanowar Wastes +4 [RTR:243] Overgrown Tomb +4 [C14:146] Gray Merchant of Asphodel +4 [M14:101] Lifebane Zombie +2 [M15:248] Urborg, Tomb of Yawgmoth +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +2 [C14:161] Sign in Blood +6 [UNH:138] Swamp +SB: 1 [RTR:83] Underworld Connections +SB: 2 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 2 [RTR:164] Golgari Charm +SB: 2 [BNG:65] Drown in Sorrow +SB: 3 [M14:195] Scavenging Ooze +SB: 1 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..33fb10e79a3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,25 @@ +3 [RTR:83] Underworld Connections +2 [THS:225] Temple of Deceit +4 [RTR:73] Pack Rat +4 [JOU:165] Temple of Malady +4 [RTR:63] Desecration Demon +2 [RTR:141] Abrupt Decay +4 [THS:107] Thoughtseize +2 [BNG:61] Bile Blight +4 [RTR:243] Overgrown Tomb +3 [M14:101] Lifebane Zombie +4 [C14:146] Gray Merchant of Asphodel +3 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +3 [GTC:222] Nightveil Specter +3 [GTC:63] Devour Flesh +11 [UNH:138] Swamp +SB: 1 [RTR:83] Underworld Connections +SB: 1 [M14:101] Lifebane Zombie +SB: 2 [THS:100] Pharika's Cure +SB: 1 [RTR:208] Vraska the Unseen +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 1 [GTC:63] Devour Flesh +SB: 2 [RTR:164] Golgari Charm +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..f500aa60197 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Golgari TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,24 @@ +4 [THS:223] Nykthos, Shrine to Nyx +1 [THS:110] Whip of Erebos +9 [UNH:140] Forest +1 [THS:166] Nylea, God of the Hunt +3 [JOU:122] Eidolon of Blossoms +4 [JOU:165] Temple of Malady +1 [JOU:154] Pharika, God of Affliction +4 [JOU:66] Doomwake Giant +4 [M15:176] Genesis Hydra +4 [M15:244] Llanowar Wastes +2 [M15:178] Hornet Queen +4 [BNG:119] Courser of Kruphix +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [THS:182] Voyaging Satyr +1 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +1 [UNH:138] Swamp +SB: 1 [M15:210] Garruk, Apex Predator +SB: 4 [THS:167] Nylea's Disciple +SB: 3 [JOU:140] Setessan Tactics +SB: 3 [THS:162] Mistcutter Hydra +SB: 4 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..2bb1657d96d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +19 [UNH:140] Forest +1 [THS:166] Nylea, God of the Hunt +4 [GTC:216] Burning-Tree Emissary +4 [JOU:122] Eidolon of Blossoms +3 [M15:172] Chord of Calling +3 [M14:172] Garruk, Caller of Beasts +2 [M15:187] Nissa, Worldwaker +1 [M15:178] Hornet Queen +4 [BNG:119] Courser of Kruphix +1 [GTC:136] Sylvan Primordial +4 [THS:182] Voyaging Satyr +4 [THS:172] Polukranos, World Eater +4 [C14:191] Elvish Mystic +2 [THS:180] Sylvan Caryatid +SB: 1 [M15:178] Hornet Queen +SB: 3 [THS:167] Nylea's Disciple +SB: 1 [GTC:136] Sylvan Primordial +SB: 2 [THS:150] Arbor Colossus +SB: 3 [THS:162] Mistcutter Hydra +SB: 4 [JOU:140] Setessan Tactics +SB: 1 [M14:195] Scavenging Ooze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..0e0e10a7a33 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,23 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +10 [UNH:140] Forest +4 [JOU:122] Eidolon of Blossoms +4 [KTK:249] Wooded Foothills +4 [KTK:106] Crater's Claws +2 [M15:176] Genesis Hydra +4 [FRF:145] Whisperwood Elemental +1 [UNH:139] Mountain +4 [BNG:119] Courser of Kruphix +2 [FRF:1] Ugin, the Spirit Dragon +4 [THS:182] Voyaging Satyr +4 [THS:172] Polukranos, World Eater +1 [THS:152] Boon Satyr +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 2 [C14:213] Reclamation Sage +SB: 3 [THS:167] Nylea's Disciple +SB: 2 [THS:150] Arbor Colossus +SB: 2 [JOU:140] Setessan Tactics +SB: 1 [BNG:156] Xenagos, God of Revels +SB: 2 [M15:176] Genesis Hydra +SB: 3 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..e25614f212c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Green TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,25 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +9 [UNH:140] Forest +2 [THS:166] Nylea, God of the Hunt +4 [GTC:216] Burning-Tree Emissary +2 [THS:209] Xenagos, the Reveler +4 [M14:172] Garruk, Caller of Beasts +3 [M14:195] Scavenging Ooze +2 [UNH:139] Mountain +4 [GTC:247] Stomping Ground +4 [THS:182] Voyaging Satyr +3 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +3 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 3 [RTR:101] Mizzium Mortars +SB: 2 [M15:134] Chandra, Pyromaster +SB: 2 [THS:167] Nylea's Disciple +SB: 2 [GTC:139] Wasteland Viper +SB: 1 [THS:209] Xenagos, the Reveler +SB: 1 [GTC:136] Sylvan Primordial +SB: 1 [THS:162] Mistcutter Hydra +SB: 2 [M14:130] Burning Earth +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..44f9b6e4faa --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +9 [UNH:140] Forest +1 [THS:166] Nylea, God of the Hunt +4 [GTC:216] Burning-Tree Emissary +2 [THS:209] Xenagos, the Reveler +4 [M14:172] Garruk, Caller of Beasts +2 [M14:195] Scavenging Ooze +2 [UNH:139] Mountain +1 [DGM:99] Ruric Thar, the Unbowed +4 [GTC:247] Stomping Ground +4 [THS:182] Voyaging Satyr +3 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +4 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 4 [THS:167] Nylea's Disciple +SB: 3 [GTC:139] Wasteland Viper +SB: 4 [THS:162] Mistcutter Hydra +SB: 3 [M14:130] Burning Earth +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..1ecf6e4e653 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +3 [THS:135] Purphoros, God of the Forge +2 [THS:124] Hammer of Purphoros +4 [THS:224] Temple of Abandon +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [THS:143] Stormbreath Dragon +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +2 [THS:209] Xenagos, the Reveler +11 [UNH:139] Mountain +4 [RTR:215] Frostburn Weird +2 [C13:294] Gruul Guildgate +4 [GTC:247] Stomping Ground +4 [GTC:156] Domri Rade +SB: 2 [M15:134] Chandra, Pyromaster +SB: 4 [RTR:101] Mizzium Mortars +SB: 2 [M14:155] Shock +SB: 2 [THS:120] Ember Swallower +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [THS:112] Anger of the Gods +SB: 2 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2014.mwDeck.dck new file mode 100644 index 00000000000..8c0689faa37 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul TDtB ST Oct 2014.mwDeck.dck @@ -0,0 +1,25 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +9 [UNH:140] Forest +2 [THS:166] Nylea, God of the Hunt +2 [THS:209] Xenagos, the Reveler +4 [KTK:249] Wooded Foothills +2 [M15:172] Chord of Calling +2 [KTK:106] Crater's Claws +4 [M15:176] Genesis Hydra +1 [M15:187] Nissa, Worldwaker +2 [UNH:139] Mountain +2 [M15:178] Hornet Queen +4 [KTK:144] Rattleclaw Mystic +4 [BNG:119] Courser of Kruphix +2 [THS:150] Arbor Colossus +3 [THS:172] Polukranos, World Eater +1 [THS:173] Reverent Hunter +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [C14:213] Reclamation Sage +SB: 2 [THS:143] Stormbreath Dragon +SB: 3 [M15:229] Scuttling Doom Engine +SB: 2 [KTK:206] Surrak Dragonclaw +SB: 4 [THS:162] Mistcutter Hydra +SB: 3 [JOU:140] Setessan Tactics diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(1) TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(1) TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..464c3582227 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(1) TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +2 [THS:135] Purphoros, God of the Forge +4 [THS:224] Temple of Abandon +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [THS:143] Stormbreath Dragon +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +1 [THS:228] Temple of Triumph +12 [UNH:139] Mountain +2 [M15:134] Chandra, Pyromaster +3 [RTR:101] Mizzium Mortars +4 [RTR:215] Frostburn Weird +4 [GTC:247] Stomping Ground +4 [GTC:156] Domri Rade +SB: 1 [RTR:101] Mizzium Mortars +SB: 2 [RTR:231] Pithing Needle +SB: 3 [THS:112] Anger of the Gods +SB: 2 [THS:209] Xenagos, the Reveler +SB: 2 [M15:192] Plummet +SB: 3 [THS:162] Mistcutter Hydra +SB: 2 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(2) TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(2) TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..3dd033549f4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Gruul(2) TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +9 [UNH:140] Forest +1 [THS:166] Nylea, God of the Hunt +4 [GTC:216] Burning-Tree Emissary +2 [THS:209] Xenagos, the Reveler +4 [M14:172] Garruk, Caller of Beasts +2 [M14:195] Scavenging Ooze +2 [UNH:139] Mountain +1 [DGM:99] Ruric Thar, the Unbowed +4 [GTC:247] Stomping Ground +4 [THS:182] Voyaging Satyr +3 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +4 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 3 [GTC:139] Wasteland Viper +SB: 4 [THS:167] Nylea's Disciple +SB: 4 [THS:162] Mistcutter Hydra +SB: 3 [M14:130] Burning Earth +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Red TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Red TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..b93a8a226f0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Red TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:223] Nykthos, Shrine to Nyx +2 [THS:135] Purphoros, God of the Forge +3 [THS:124] Hammer of Purphoros +2 [THS:224] Temple of Abandon +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [THS:143] Stormbreath Dragon +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [THS:228] Temple of Triumph +11 [UNH:139] Mountain +3 [RTR:101] Mizzium Mortars +3 [THS:4] Chained to the Rocks +4 [RTR:215] Frostburn Weird +4 [GTC:245] Sacred Foundry +SB: 1 [THS:135] Purphoros, God of the Forge +SB: 1 [RTR:101] Mizzium Mortars +SB: 4 [C13:179] Boros Charm +SB: 1 [THS:4] Chained to the Rocks +SB: 3 [THS:112] Anger of the Gods +SB: 2 [DGM:135] Wear // Tear +SB: 3 [GTC:142] Assemble the Legion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..2df29717f04 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,25 @@ +4 [THS:223] Nykthos, Shrine to Nyx +2 [DTK:180] Deathmist Raptor +4 [FRF:19] Mastery of the Unseen +1 [FRF:141] Temur Sabertooth +4 [UNH:140] Forest +4 [KTK:248] Windswept Heath +4 [KTK:249] Wooded Foothills +3 [M15:176] Genesis Hydra +4 [FRF:145] Whisperwood Elemental +1 [UNH:139] Mountain +4 [BNG:119] Courser of Kruphix +3 [THS:182] Voyaging Satyr +4 [BNG:165] Temple of Plenty +2 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +2 [DTK:221] Dromoka's Command +4 [C14:191] Elvish Mystic +2 [UNH:136] Plains +4 [THS:180] Sylvan Caryatid +SB: 3 [THS:167] Nylea's Disciple +SB: 4 [THS:193] Fleecemane Lion +SB: 3 [THS:209] Xenagos, the Reveler +SB: 2 [THS:150] Arbor Colossus +SB: 1 [DTK:221] Dromoka's Command +SB: 2 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..7744577cadc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,27 @@ +1 [FRF:166] Blossoming Sands +4 [THS:223] Nykthos, Shrine to Nyx +4 [FRF:19] Mastery of the Unseen +1 [FRF:141] Temur Sabertooth +9 [UNH:140] Forest +1 [JOU:5] Banishing Light +4 [KTK:248] Windswept Heath +4 [M15:176] Genesis Hydra +4 [FRF:145] Whisperwood Elemental +4 [BNG:119] Courser of Kruphix +2 [THS:193] Fleecemane Lion +4 [THS:182] Voyaging Satyr +4 [BNG:165] Temple of Plenty +4 [THS:172] Polukranos, World Eater +4 [C14:191] Elvish Mystic +2 [UNH:136] Plains +4 [THS:180] Sylvan Caryatid +SB: 2 [M15:177] Hornet Nest +SB: 1 [FRF:28] Valorous Stance +SB: 2 [C14:213] Reclamation Sage +SB: 1 [M15:178] Hornet Queen +SB: 2 [THS:159] Hunt the Hunter +SB: 1 [THS:15] Glare of Heresy +SB: 2 [THS:193] Fleecemane Lion +SB: 1 [JOU:140] Setessan Tactics +SB: 1 [THS:22] Last Breath +SB: 2 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..3f7f5b4d04d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Devotion to Selesnya TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,23 @@ +1 [FRF:166] Blossoming Sands +4 [THS:223] Nykthos, Shrine to Nyx +4 [FRF:19] Mastery of the Unseen +1 [DTK:181] Den Protector +9 [UNH:140] Forest +4 [KTK:248] Windswept Heath +3 [M15:176] Genesis Hydra +4 [FRF:145] Whisperwood Elemental +2 [DTK:217] Dragonlord Dromoka +4 [BNG:119] Courser of Kruphix +2 [FRF:1] Ugin, the Spirit Dragon +4 [THS:182] Voyaging Satyr +4 [BNG:165] Temple of Plenty +4 [THS:172] Polukranos, World Eater +4 [C14:191] Elvish Mystic +2 [UNH:136] Plains +4 [THS:180] Sylvan Caryatid +SB: 3 [DTK:181] Den Protector +SB: 2 [JOU:145] Ajani, Mentor of Heroes +SB: 3 [THS:167] Nylea's Disciple +SB: 4 [THS:193] Fleecemane Lion +SB: 2 [THS:150] Arbor Colossus +SB: 1 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Domri Naya TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Domri Naya TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..4499cd2970e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Domri Naya TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,31 @@ +3 [M13:229] Sunpetal Grove +1 [UNH:140] Forest +4 [M13:228] Rootbound Crag +4 [GTC:215] Boros Reckoner +3 [M14:195] Scavenging Ooze +3 [RTR:178] Loxodon Smiter +1 [RTR:101] Mizzium Mortars +4 [M13:150] Thundermaw Hellkite +2 [C13:211] Selesnya Charm +1 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +1 [ISD:243] Kessig Wolf Run +4 [RTR:248] Temple Garden +3 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [GTC:245] Sacred Foundry +2 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +1 [DKA:140] Huntmaster of the Fells +3 [ISD:238] Clifftop Retreat +4 [DGM:114] Voice of Resurgence +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [DKA:17] Ray of Revelation +SB: 2 [C13:179] Boros Charm +SB: 2 [DGM:111] Unflinching Courage +SB: 1 [AVR:149] Pillar of Flame +SB: 1 [M14:12] Celestial Flare +SB: 2 [DGM:99] Ruric Thar, the Unbowed +SB: 2 [M13:22] Oblivion Ring +SB: 1 [RTR:18] Rest in Peace +SB: 2 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Eldrazi Green-Black TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Eldrazi Green-Black TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..68569150f3d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Eldrazi Green-Black TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,25 @@ +1 [ROE:12] Ulamog, the Infinite Gyre +3 [ROE:186] Growth Spasm +10 [UNH:140] Forest +4 [ROE:190] Joraga Treespeaker +1 [ROE:6] Kozilek, Butcher of Truth +4 [ROE:227] Eldrazi Temple +1 [ROE:4] Emrakul, the Aeons Torn +1 [WWK:136] Eye of Ugin +4 [ROE:203] Overgrown Battlement +4 [M12:188] Primeval Titan +4 [C14:239] Everflowing Chalice +4 [ZEN:184] Summoning Trap +3 [C13:302] Khalni Garden +2 [ROE:1] All Is Dust +4 [C14:313] Tectonic Edge +4 [ZEN:229] Verdant Catacombs +2 [C14:283] Wurmcoil Engine +3 [WWK:99] Explore +1 [UNH:138] Swamp +SB: 3 [SOM:69] Memoricide +SB: 4 [M14:96] Doom Blade +SB: 4 [M11:188] Obstinate Baloth +SB: 1 [WWK:136] Eye of Ugin +SB: 2 [C14:218] Terastodon +SB: 1 [ROE:1] All Is Dust diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..b3d60e24e22 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,20 @@ +3 [ZEN:170] Nissa Revane +15 [UNH:140] Forest +3 [ROE:190] Joraga Treespeaker +3 [ZEN:199] Eldrazi Monument +4 [ZEN:171] Nissa's Chosen +4 [C14:305] Oran-Rief, the Vastwood +3 [ROE:212] Vengevine +2 [C14:216] Sylvan Ranger +4 [C14:204] Llanowar Elves +3 [C14:203] Joraga Warcaller +3 [M11:172] Fauna Shaman +4 [M13:160] Arbor Elf +3 [C14:195] Ezuri, Renegade Leader +4 [C14:190] Elvish Archdruid +2 [SOM:122] Genesis Wave +SB: 4 [M11:183] Leyline of Vitality +SB: 3 [C13:134] Acidic Slime +SB: 2 [CMD:157] Garruk Wildspeaker +SB: 3 [M11:202] Brittle Effigy +SB: 3 [ROE:211] Tajuru Preserver diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..d8a92dea12c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Elves TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,20 @@ +4 [CNS:170] Lead the Stampede +4 [CNS:160] Copperhorn Scout +20 [UNH:140] Forest +4 [ROE:190] Joraga Treespeaker +3 [ROE:212] Vengevine +2 [C14:216] Sylvan Ranger +4 [C14:204] Llanowar Elves +1 [C14:225] Wolfbriar Elemental +2 [C14:203] Joraga Warcaller +4 [M11:172] Fauna Shaman +4 [M13:160] Arbor Elf +4 [C14:195] Ezuri, Renegade Leader +4 [C14:190] Elvish Archdruid +SB: 4 [M11:183] Leyline of Vitality +SB: 1 [MBS:78] Creeping Corrosion +SB: 3 [CNS:171] Nature's Claim +SB: 2 [MBS:94] Viridian Corrupter +SB: 1 [M11:188] Obstinate Baloth +SB: 3 [NPH:159] Spellskite +SB: 1 [WWK:107] Leatherback Baloth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..0378a406691 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,31 @@ +2 [MBS:21] Consecrated Sphinx +1 [MBS:43] Go for the Throat +2 [M12:16] Gideon Jura +2 [M13:225] Glacial Fortress +2 [M13:223] Drowned Catacomb +2 [ISD:78] Snapcaster Mage +2 [ISD:55] Forbidden Alchemy +4 [ISD:242] Isolated Chapel +3 [C14:295] Evolving Wilds +4 [SOM:229] Seachrome Coast +1 [M14:96] Doom Blade +1 [SOM:226] Darkslick Shores +2 [MBS:115] Mortarpod +4 [DKA:12] Lingering Souls +3 [M12:12] Day of Judgment +3 [UNH:136] Plains +2 [DKA:142] Sorin, Lord of Innistrad +2 [UNH:137] Island +3 [ISD:94] Curse of Death's Hold +3 [ISD:83] Think Twice +5 [UNH:138] Swamp +3 [ISD:105] Liliana of the Veil +4 [M12:63] Mana Leak +SB: 1 [C14:136] Black Sun's Zenith +SB: 3 [M14:215] Ratchet Bomb +SB: 2 [CNS:72] Intangible Virtue +SB: 1 [SOM:53] Volition Reins +SB: 1 [NPH:130] Batterskull +SB: 3 [M12:11] Celestial Purge +SB: 3 [KTK:69] Despise +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..760326eaa92 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,33 @@ +2 [AVR:32] Restoration Angel +1 [RTR:82] Ultimate Price +4 [C13:30] Augur of Bolas +3 [RTR:54] Syncopate +4 [GTC:249] Watery Grave +4 [M13:225] Glacial Fortress +2 [M13:223] Drowned Catacomb +4 [RTR:241] Hallowed Fountain +2 [ISD:78] Snapcaster Mage +4 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [ISD:242] Isolated Chapel +1 [M15:51] Dissipate +4 [ISD:245] Nephalia Drownyard +1 [M13:22] Oblivion Ring +1 [GTC:154] Dimir Charm +2 [GTC:63] Devour Flesh +3 [GTC:242] Godless Shrine +1 [UNH:137] Island +1 [M14:60] Jace, Memory Adept +4 [ISD:83] Think Twice +SB: 3 [C14:167] Tragic Slip +SB: 1 [ISD:27] Purify the Grave +SB: 1 [AVR:84] Appetite for Brains +SB: 1 [ISD:236] Witchbane Orb +SB: 1 [RTR:47] Psychic Spiral +SB: 1 [RTR:36] Dispel +SB: 1 [M14:97] Duress +SB: 2 [ISD:212] Evil Twin +SB: 2 [RTR:18] Rest in Peace +SB: 1 [ISD:94] Curse of Death's Hold +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..4af6e626cb3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,29 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +2 [RTR:54] Syncopate +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +2 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +1 [DGM:11] AEtherling +2 [M14:228] Mutavault +1 [BNG:25] Revoke Existence +2 [M14:96] Doom Blade +4 [RTR:44] Jace, Architect of Thought +2 [GTC:242] Godless Shrine +2 [UNH:136] Plains +3 [THS:9] Elspeth, Sun's Champion +5 [UNH:137] Island +2 [THS:22] Last Breath +4 [BNG:163] Temple of Enlightenment +SB: 2 [RTR:82] Ultimate Price +SB: 2 [GTC:6] Blind Obedience +SB: 1 [RTR:231] Pithing Needle +SB: 2 [M14:18] Fiendslayer Paladin +SB: 2 [THS:49] Gainsay +SB: 1 [BNG:25] Revoke Existence +SB: 1 [THS:83] Dark Betrayal +SB: 2 [THS:107] Thoughtseize +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..50d8674ab22 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,37 @@ +4 [M13:225] Glacial Fortress +4 [M13:223] Drowned Catacomb +1 [C14:104] Cyclonic Rift +2 [RTR:201] Supreme Verdict +1 [ISD:55] Forbidden Alchemy +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [ISD:242] Isolated Chapel +2 [M15:51] Dissipate +4 [ISD:245] Nephalia Drownyard +2 [DKA:12] Lingering Souls +1 [UNH:136] Plains +1 [DKA:142] Sorin, Lord of Innistrad +3 [UNH:137] Island +1 [ISD:94] Curse of Death's Hold +3 [AVR:38] Terminus +2 [UNH:138] Swamp +1 [M15:71] Negate +2 [RTR:82] Ultimate Price +1 [AVR:79] Tamiyo, the Moon Sage +4 [RTR:241] Hallowed Fountain +2 [RTR:155] Detention Sphere +1 [C14:298] Ghost Quarter +1 [C14:295] Evolving Wilds +2 [RTR:44] Jace, Architect of Thought +1 [M14:60] Jace, Memory Adept +3 [ISD:83] Think Twice +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [RTR:155] Detention Sphere +SB: 2 [ISD:14] Feeling of Dread +SB: 1 [ISD:115] Sever the Bloodline +SB: 1 [RTR:36] Dispel +SB: 3 [RTR:18] Rest in Peace +SB: 1 [AVR:38] Terminus +SB: 1 [M14:60] Jace, Memory Adept +SB: 1 [ISD:94] Curse of Death's Hold +SB: 3 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..1e16ccf56bc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,30 @@ +1 [RTR:82] Ultimate Price +4 [THS:225] Temple of Deceit +2 [THS:47] Dissolve +1 [RTR:54] Syncopate +4 [GTC:249] Watery Grave +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +2 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +3 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +2 [DGM:11] AEtherling +2 [THS:90] Hero's Downfall +1 [M14:96] Doom Blade +1 [DGM:127] Far // Away +4 [RTR:44] Jace, Architect of Thought +1 [GTC:63] Devour Flesh +1 [GTC:154] Dimir Charm +3 [GTC:242] Godless Shrine +4 [UNH:136] Plains +4 [UNH:137] Island +SB: 1 [RTR:231] Pithing Needle +SB: 3 [M14:18] Fiendslayer Paladin +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 3 [THS:49] Gainsay +SB: 3 [RTR:73] Pack Rat +SB: 1 [M14:116] Shrivel +SB: 1 [M14:96] Doom Blade +SB: 1 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..4eea2bbab98 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,30 @@ +3 [AVR:32] Restoration Angel +1 [RTR:82] Ultimate Price +2 [M14:29] Planar Cleansing +4 [C13:30] Augur of Bolas +2 [GTC:249] Watery Grave +4 [M13:225] Glacial Fortress +4 [M13:223] Drowned Catacomb +4 [RTR:241] Hallowed Fountain +2 [ISD:78] Snapcaster Mage +4 [RTR:201] Supreme Verdict +1 [RTR:156] Dramatic Rescue +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [ISD:242] Isolated Chapel +2 [M15:51] Dissipate +4 [ISD:245] Nephalia Drownyard +2 [GTC:63] Devour Flesh +1 [UNH:136] Plains +2 [GTC:242] Godless Shrine +2 [UNH:137] Island +4 [ISD:83] Think Twice +SB: 3 [AVR:104] Gloom Surgeon +SB: 2 [RTR:1] Angel of Serenity +SB: 2 [ISD:236] Witchbane Orb +SB: 1 [RTR:47] Psychic Spiral +SB: 1 [RTR:36] Dispel +SB: 2 [M14:97] Duress +SB: 1 [RTR:18] Rest in Peace +SB: 2 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..4eea2bbab98 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,30 @@ +3 [AVR:32] Restoration Angel +1 [RTR:82] Ultimate Price +2 [M14:29] Planar Cleansing +4 [C13:30] Augur of Bolas +2 [GTC:249] Watery Grave +4 [M13:225] Glacial Fortress +4 [M13:223] Drowned Catacomb +4 [RTR:241] Hallowed Fountain +2 [ISD:78] Snapcaster Mage +4 [RTR:201] Supreme Verdict +1 [RTR:156] Dramatic Rescue +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [ISD:242] Isolated Chapel +2 [M15:51] Dissipate +4 [ISD:245] Nephalia Drownyard +2 [GTC:63] Devour Flesh +1 [UNH:136] Plains +2 [GTC:242] Godless Shrine +2 [UNH:137] Island +4 [ISD:83] Think Twice +SB: 3 [AVR:104] Gloom Surgeon +SB: 2 [RTR:1] Angel of Serenity +SB: 2 [ISD:236] Witchbane Orb +SB: 1 [RTR:47] Psychic Spiral +SB: 1 [RTR:36] Dispel +SB: 2 [M14:97] Duress +SB: 1 [RTR:18] Rest in Peace +SB: 2 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..d109f21d9c9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,30 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +2 [RTR:54] Syncopate +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +1 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +1 [DGM:11] AEtherling +2 [M14:228] Mutavault +1 [BNG:25] Revoke Existence +2 [M14:96] Doom Blade +4 [RTR:44] Jace, Architect of Thought +2 [GTC:242] Godless Shrine +2 [UNH:136] Plains +3 [THS:9] Elspeth, Sun's Champion +5 [UNH:137] Island +2 [THS:22] Last Breath +4 [BNG:163] Temple of Enlightenment +1 [M15:71] Negate +SB: 2 [RTR:82] Ultimate Price +SB: 2 [GTC:6] Blind Obedience +SB: 1 [RTR:231] Pithing Needle +SB: 1 [M14:18] Fiendslayer Paladin +SB: 2 [THS:49] Gainsay +SB: 1 [BNG:25] Revoke Existence +SB: 2 [THS:83] Dark Betrayal +SB: 3 [THS:107] Thoughtseize +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..286545eace3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,32 @@ +3 [RTR:82] Ultimate Price +4 [THS:225] Temple of Deceit +3 [THS:47] Dissolve +1 [JOU:7] Deicide +3 [RTR:54] Syncopate +3 [GTC:249] Watery Grave +1 [M14:68] Quicken +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +4 [RTR:201] Supreme Verdict +1 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +3 [RTR:155] Detention Sphere +1 [DGM:11] AEtherling +3 [THS:90] Hero's Downfall +1 [M14:228] Mutavault +4 [RTR:44] Jace, Architect of Thought +1 [UNH:136] Plains +3 [GTC:242] Godless Shrine +3 [THS:9] Elspeth, Sun's Champion +2 [UNH:137] Island +4 [BNG:163] Temple of Enlightenment +SB: 2 [JOU:18] Nyx-Fleece Ram +SB: 1 [JOU:7] Deicide +SB: 1 [THS:49] Gainsay +SB: 1 [M14:5] Archangel of Thune +SB: 1 [M14:96] Doom Blade +SB: 3 [GTC:222] Nightveil Specter +SB: 1 [GTC:154] Dimir Charm +SB: 2 [THS:107] Thoughtseize +SB: 2 [DGM:103] Sin Collector +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..d81b73202c7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,32 @@ +4 [THS:225] Temple of Deceit +2 [THS:47] Dissolve +1 [THS:188] Ashiok, Nightmare Weaver +4 [KTK:239] Polluted Delta +4 [KTK:36] Dig Through Time +3 [THS:107] Thoughtseize +1 [KTK:233] Flooded Strand +2 [M15:241] Caves of Koilos +4 [FRF:168] Dismal Backwater +1 [FRF:157] Silumgar, the Drifting Death +2 [DTK:249] Haven of the Spirit Dragon +3 [BNG:61] Bile Blight +4 [DTK:219] Dragonlord Ojutai +3 [DTK:102] Foul-Tongue Invocation +1 [M15:248] Urborg, Tomb of Yawgmoth +3 [THS:90] Hero's Downfall +1 [DTK:220] Dragonlord Silumgar +2 [DTK:45] Anticipate +4 [DTK:78] Silumgar's Scorn +2 [FRF:65] Crux of Fate +3 [UNH:137] Island +2 [UNH:138] Swamp +4 [BNG:163] Temple of Enlightenment +SB: 1 [BNG:61] Bile Blight +SB: 2 [DTK:124] Ultimate Price +SB: 2 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [DTK:80] Stratus Dancer +SB: 1 [DTK:220] Dragonlord Silumgar +SB: 2 [FRF:87] Tasigur, the Golden Fang +SB: 3 [BNG:65] Drown in Sorrow +SB: 1 [THS:107] Thoughtseize +SB: 2 [DTK:52] Dragonlord's Prerogative diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..32518090e1d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:225] Temple of Deceit +3 [THS:47] Dissolve +4 [GTC:249] Watery Grave +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +2 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +2 [DGM:57] Blood Baron of Vizkopa +1 [DGM:11] AEtherling +2 [THS:90] Hero's Downfall +4 [RTR:44] Jace, Architect of Thought +2 [M15:52] Divination +3 [UNH:136] Plains +4 [GTC:242] Godless Shrine +1 [THS:9] Elspeth, Sun's Champion +4 [UNH:137] Island +SB: 1 [RTR:82] Ultimate Price +SB: 1 [RTR:231] Pithing Needle +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 4 [THS:49] Gainsay +SB: 2 [M14:96] Doom Blade +SB: 1 [THS:83] Dark Betrayal +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..ca6badb6c3b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Control TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:225] Temple of Deceit +3 [THS:47] Dissolve +4 [GTC:249] Watery Grave +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +2 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +1 [RTR:155] Detention Sphere +1 [DGM:11] AEtherling +4 [THS:90] Hero's Downfall +4 [M14:96] Doom Blade +4 [RTR:44] Jace, Architect of Thought +2 [M15:52] Divination +2 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +4 [UNH:137] Island +SB: 2 [RTR:155] Detention Sphere +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 1 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 1 [THS:107] Thoughtseize +SB: 2 [M15:71] Negate +SB: 2 [DGM:103] Sin Collector +SB: 4 [THS:32] Soldier of the Pantheon diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Dragon TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Dragon TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..a2d0b26172d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Dragon TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,30 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +4 [KTK:239] Polluted Delta +4 [KTK:36] Dig Through Time +1 [THS:107] Thoughtseize +1 [KTK:233] Flooded Strand +4 [FRF:168] Dismal Backwater +2 [FRF:157] Silumgar, the Drifting Death +2 [DTK:249] Haven of the Spirit Dragon +2 [DTK:219] Dragonlord Ojutai +1 [DTK:102] Foul-Tongue Invocation +2 [DTK:124] Ultimate Price +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [FRF:1] Ugin, the Spirit Dragon +4 [THS:90] Hero's Downfall +4 [DTK:45] Anticipate +4 [DTK:78] Silumgar's Scorn +3 [FRF:65] Crux of Fate +2 [M15:63] Jace's Ingenuity +3 [UNH:137] Island +3 [UNH:138] Swamp +4 [BNG:163] Temple of Enlightenment +SB: 1 [BNG:61] Bile Blight +SB: 2 [DTK:102] Foul-Tongue Invocation +SB: 2 [FRF:87] Tasigur, the Golden Fang +SB: 2 [DTK:220] Dragonlord Silumgar +SB: 3 [BNG:65] Drown in Sorrow +SB: 2 [THS:107] Thoughtseize +SB: 2 [DTK:52] Dragonlord's Prerogative +SB: 1 [DTK:65] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..9c5f2004b48 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,26 @@ +2 [RTR:82] Ultimate Price +4 [THS:225] Temple of Deceit +4 [M14:22] Imposing Sovereign +2 [THS:110] Whip of Erebos +3 [GTC:249] Watery Grave +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +4 [RTR:179] Lyev Skyknight +2 [RTR:201] Supreme Verdict +3 [M14:123] Xathrid Necromancer +4 [RTR:155] Detention Sphere +3 [GTC:182] Obzedat, Ghost Council +2 [M14:228] Mutavault +1 [DGM:127] Far // Away +2 [BNG:145] Ephara, God of the Polis +3 [RTR:17] Precinct Captain +4 [GTC:242] Godless Shrine +4 [UNH:136] Plains +1 [THS:33] Spear of Heliod +4 [THS:32] Soldier of the Pantheon +SB: 2 [THS:15] Glare of Heresy +SB: 3 [DGM:57] Blood Baron of Vizkopa +SB: 2 [THS:49] Gainsay +SB: 2 [M14:96] Doom Blade +SB: 2 [THS:83] Dark Betrayal +SB: 4 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..aeceb56e394 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Esper Midrange TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,32 @@ +4 [AVR:32] Restoration Angel +2 [MBS:43] Go for the Throat +1 [AVR:79] Tamiyo, the Moon Sage +2 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +3 [NPH:4] Blade Splicer +1 [M13:223] Drowned Catacomb +4 [ISD:78] Snapcaster Mage +2 [DKA:158] Vault of the Archangel +1 [MBS:5] Divine Offering +2 [NPH:86] Gut Shot +4 [DKA:52] Thought Scour +2 [C14:295] Evolving Wilds +4 [SOM:229] Seachrome Coast +2 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +4 [DKA:12] Lingering Souls +2 [UNH:136] Plains +2 [M12:72] Phantasmal Image +3 [UNH:137] Island +4 [M12:73] Ponder +1 [UNH:138] Swamp +2 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [C14:298] Ghost Quarter +SB: 2 [M15:51] Dissipate +SB: 2 [C14:91] Sun Titan +SB: 2 [M12:11] Celestial Purge +SB: 2 [M12:12] Day of Judgment +SB: 1 [M13:22] Oblivion Ring +SB: 2 [C13:249] Nihil Spellbomb +SB: 2 [M12:72] Phantasmal Image diff --git a/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..d492fda3016 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,26 @@ +1 [M13:228] Rootbound Crag +6 [UNH:140] Forest +4 [M12:165] Birds of Paradise +1 [C14:204] Llanowar Elves +1 [UNH:139] Mountain +2 [C13:114] Inferno Titan +4 [ISD:170] Avacyn's Pilgrim +4 [ISD:122] Unburial Rites +4 [DKA:128] Tracker's Instincts +4 [C14:175] Faithless Looting +4 [NPH:9] Elesh Norn, Grand Cenobite +4 [ISD:196] Mulch +4 [SOM:228] Razorverge Thicket +2 [C14:283] Wurmcoil Engine +2 [SOM:226] Darkslick Shores +4 [DKA:12] Lingering Souls +4 [SOM:225] Copperline Gorge +4 [SOM:224] Blackcleave Cliffs +1 [UNH:136] Plains +SB: 3 [DKA:17] Ray of Revelation +SB: 2 [ISD:66] Memory's Journey +SB: 1 [ISD:27] Purify the Grave +SB: 2 [ISD:122] Unburial Rites +SB: 2 [NPH:37] Jin-Gitaxias, Core Augur +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 4 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..85d1b018cd9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/FRites TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,29 @@ +4 [AVR:32] Restoration Angel +3 [M13:229] Sunpetal Grove +5 [UNH:140] Forest +4 [RTR:1] Angel of Serenity +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +3 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +4 [RTR:248] Temple Garden +1 [RTR:148] Centaur Healer +1 [RTR:213] Deathrite Shaman +4 [ISD:196] Mulch +2 [DKA:12] Lingering Souls +2 [AVR:169] Borderland Ranger +1 [ISD:239] Gavony Township +2 [UNH:136] Plains +2 [ISD:249] Woodland Cemetery +1 [UNH:138] Swamp +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 2 [ISD:10] Divine Reckoning +SB: 2 [RTR:148] Centaur Healer +SB: 2 [RTR:213] Deathrite Shaman +SB: 1 [ISD:115] Sever the Bloodline +SB: 2 [M14:97] Duress +SB: 2 [M13:22] Oblivion Ring +SB: 2 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..bfb6b0277e5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,26 @@ +4 [SOM:174] Memnite +3 [WWK:144] Stirring Wildwood +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +1 [SOM:10] Glint Hawk +4 [ROE:212] Vengevine +2 [C14:228] Argentum Armor +4 [ZEN:23] Kor Skyfisher +4 [M11:172] Fauna Shaman +4 [M15:223] Ornithopter +1 [ZEN:21] Kor Outfitter +1 [SOM:208] Sword of Body and Mind +4 [ZEN:33] Quest for the Holy Relic +4 [SOM:228] Razorverge Thicket +4 [M11:33] Squadron Hawk +1 [WWK:20] Stoneforge Mystic +8 [UNH:136] Plains +3 [SOM:156] Glint Hawk Idol +SB: 1 [ROE:33] Linvala, Keeper of Silence +SB: 1 [MBS:10] Leonin Relic-Warder +SB: 1 [M13:39] War Priest of Thune +SB: 4 [SOM:14] Leonin Arbiter +SB: 2 [WWK:17] Refraction Trap +SB: 4 [ZEN:10] Devout Lightcaster +SB: 1 [WWK:11] Kor Firewalker +SB: 1 [M11:7] Baneslayer Angel diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..87e7104deeb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Fauna Quest TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,27 @@ +4 [SOM:174] Memnite +3 [WWK:144] Stirring Wildwood +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +1 [SOM:10] Glint Hawk +4 [ROE:212] Vengevine +2 [C14:228] Argentum Armor +4 [ZEN:23] Kor Skyfisher +4 [M11:172] Fauna Shaman +4 [M15:223] Ornithopter +1 [ZEN:21] Kor Outfitter +1 [SOM:208] Sword of Body and Mind +4 [ZEN:33] Quest for the Holy Relic +4 [SOM:228] Razorverge Thicket +4 [M11:33] Squadron Hawk +1 [WWK:20] Stoneforge Mystic +8 [UNH:136] Plains +3 [SOM:156] Glint Hawk Idol +SB: 1 [ROE:33] Linvala, Keeper of Silence +SB: 1 [M13:39] War Priest of Thune +SB: 1 [MBS:10] Leonin Relic-Warder +SB: 2 [SOM:14] Leonin Arbiter +SB: 2 [WWK:17] Refraction Trap +SB: 2 [CMD:17] Journey to Nowhere +SB: 2 [ZEN:10] Devout Lightcaster +SB: 2 [WWK:11] Kor Firewalker +SB: 2 [M11:7] Baneslayer Angel diff --git a/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..db90f390e90 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,28 @@ +1 [C13:11] Fiend Hunter +2 [SOM:6] Elspeth Tirel +4 [M13:229] Sunpetal Grove +8 [UNH:140] Forest +2 [C14:72] Geist-Honored Monk +1 [M12:16] Gideon Jura +2 [NPH:4] Blade Splicer +2 [MBS:92] Thrun, the Last Troll +4 [M12:165] Birds of Paradise +2 [NPH:116] Mutagenic Growth +4 [ISD:170] Avacyn's Pilgrim +4 [ISD:181] Garruk Relentless +1 [NPH:9] Elesh Norn, Grand Cenobite +4 [SOM:228] Razorverge Thicket +2 [MBS:115] Mortarpod +3 [M13:22] Oblivion Ring +4 [ISD:239] Gavony Township +4 [UNH:136] Plains +3 [MBS:14] Mirran Crusader +3 [MBS:8] Hero of Bladehold +SB: 2 [KTK:142] Naturalize +SB: 2 [MBS:78] Creeping Corrosion +SB: 2 [NPH:86] Gut Shot +SB: 2 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [M12:16] Gideon Jura +SB: 1 [M13:22] Oblivion Ring +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..fd44a2e814d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,23 @@ +1 [NPH:161] Sword of War and Peace +4 [M13:229] Sunpetal Grove +7 [UNH:140] Forest +3 [M12:16] Gideon Jura +3 [NPH:4] Blade Splicer +4 [M12:165] Birds of Paradise +2 [ISD:23] Mikaeus, the Lunarch +4 [ISD:170] Avacyn's Pilgrim +3 [ISD:181] Garruk Relentless +2 [NPH:86] Gut Shot +4 [SOM:228] Razorverge Thicket +2 [MBS:115] Mortarpod +4 [M13:22] Oblivion Ring +4 [ISD:239] Gavony Township +5 [UNH:136] Plains +4 [MBS:14] Mirran Crusader +4 [MBS:8] Hero of Bladehold +SB: 2 [NPH:86] Gut Shot +SB: 2 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 3 [MBS:92] Thrun, the Last Troll +SB: 2 [C13:249] Nihil Spellbomb +SB: 4 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..f9eee806beb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/GW Aggro TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,24 @@ +3 [SOM:6] Elspeth Tirel +4 [M13:229] Sunpetal Grove +8 [UNH:140] Forest +1 [C14:72] Geist-Honored Monk +4 [NPH:4] Blade Splicer +4 [M12:165] Birds of Paradise +4 [ISD:170] Avacyn's Pilgrim +4 [ISD:181] Garruk Relentless +2 [NPH:86] Gut Shot +4 [SOM:228] Razorverge Thicket +3 [MBS:115] Mortarpod +4 [M13:22] Oblivion Ring +4 [ISD:239] Gavony Township +5 [UNH:136] Plains +2 [MBS:14] Mirran Crusader +4 [MBS:8] Hero of Bladehold +SB: 1 [ISD:23] Mikaeus, the Lunarch +SB: 2 [KTK:142] Naturalize +SB: 2 [NPH:86] Gut Shot +SB: 1 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 2 [M12:11] Celestial Purge +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/GW Token TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/GW Token TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..3913457da79 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/GW Token TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,22 @@ +3 [SOM:6] Elspeth Tirel +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +1 [M12:16] Gideon Jura +4 [NPH:155] Shrine of Loyal Legions +2 [ISD:181] Garruk Relentless +4 [CNS:72] Intangible Virtue +3 [SOM:228] Razorverge Thicket +2 [NPH:57] Dismember +4 [C14:80] Midnight Haunting +2 [M12:23] Honor of the Pure +3 [M13:22] Oblivion Ring +3 [M12:12] Day of Judgment +4 [ISD:239] Gavony Township +10 [UNH:136] Plains +4 [MBS:8] Hero of Bladehold +3 [M12:40] Timely Reinforcements +SB: 3 [ISD:193] Mayor of Avabruck +SB: 4 [MBS:5] Divine Offering +SB: 3 [NPH:74] Surgical Extraction +SB: 2 [ISD:27] Purify the Grave +SB: 3 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/GWb Tokens TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/GWb Tokens TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..8ca4d6de5f3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/GWb Tokens TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,31 @@ +1 [M13:229] Sunpetal Grove +5 [UNH:140] Forest +1 [RTR:1] Angel of Serenity +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +2 [C13:211] Selesnya Charm +1 [RTR:143] Armada Wurm +4 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +3 [ISD:181] Garruk Relentless +2 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +3 [CNS:72] Intangible Virtue +1 [ISD:115] Sever the Bloodline +4 [DKA:12] Lingering Souls +4 [AVR:169] Borderland Ranger +1 [M13:22] Oblivion Ring +2 [UNH:136] Plains +3 [ISD:239] Gavony Township +3 [DKA:142] Sorin, Lord of Innistrad +2 [ISD:249] Woodland Cemetery +1 [UNH:138] Swamp +SB: 1 [DKA:17] Ray of Revelation +SB: 2 [AVR:84] Appetite for Brains +SB: 4 [RTR:148] Centaur Healer +SB: 2 [RTR:1] Angel of Serenity +SB: 3 [RTR:213] Deathrite Shaman +SB: 1 [ISD:115] Sever the Bloodline +SB: 1 [RTR:208] Vraska the Unseen +SB: 1 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Goblins Deck Wins TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Goblins Deck Wins TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..0d338274f16 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Goblins Deck Wins TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,46 @@ +1 [POR:214] Mountain +4 [MBS:64] Goblin Wardriver +1 [WWK:145] Tectonic Edge +3 [M10:139] Goblin Chieftain +1 [M12:138] Goblin Chieftain +1 [SHM:296] Mountain +1 [ARC:147] Mountain +1 [RTR:267] Mountain +1 [C13:352] Mountain +4 [ZEN:125] Goblin Bushwhacker +1 [DDE:69] Mountain +2 [ZEN:126] Goblin Guide +3 [MPRP:47] Burst Lightning +1 [ZEN:226] Teetering Peaks +1 [SOM:81] Arc Trail +1 [S00:102] Mountain +2 [MM2:127] Spikeshot Elder +1 [LEA:283] Mountain +1 [MMQ:345] Mountain +1 [RAV:300] Mountain +2 [GPX:6] Goblin Guide +4 [M11:135] Ember Hauler +2 [JR:1] Lightning Bolt +1 [M10:146] Lightning Bolt +1 [M10:243] Mountain +1 [M12:242] Mountain +2 [ROE:166] Staggershock +1 [C14:313] Tectonic Edge +1 [MIR:301] Mountain +1 [DDL:77] Mountain +2 [GRC:48] Staggershock +1 [ZEN:119] Burst Lightning +1 [DD3B:60] Mountain +3 [FNMP:136] Teetering Peaks +2 [SOM:104] Spikeshot Elder +1 [HOP:163] Mountain +1 [LEB:163] Lightning Bolt +1 [SOM:243] Mountain +SB: 2 [M12:151] Manic Vandal +SB: 2 [M13:141] Mark of Mutiny +SB: 1 [DDN:23] Arc Trail +SB: 1 [SOM:196] Ratchet Bomb +SB: 2 [PC2:39] Arc Trail +SB: 2 [PC2:47] Mark of Mutiny +SB: 3 [M14:215] Ratchet Bomb +SB: 2 [M11:151] Manic Vandal diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Golgari Constellation TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Golgari Constellation TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..aa1635ddd97 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Golgari Constellation TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,28 @@ +2 [THS:223] Nykthos, Shrine to Nyx +3 [THS:110] Whip of Erebos +5 [UNH:140] Forest +4 [JOU:122] Eidolon of Blossoms +2 [THS:155] Commune with the Gods +4 [JOU:165] Temple of Malady +2 [JOU:154] Pharika, God of Affliction +3 [JOU:66] Doomwake Giant +2 [KTK:248] Windswept Heath +2 [KTK:235] Jungle Hollow +2 [THS:107] Thoughtseize +4 [M15:198] Satyr Wayfinder +4 [M15:244] Llanowar Wastes +3 [M15:178] Hornet Queen +4 [BNG:119] Courser of Kruphix +4 [KTK:81] Murderous Cut +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [THS:90] Hero's Downfall +1 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +2 [UNH:138] Swamp +SB: 2 [C14:158] Read the Bones +SB: 2 [C14:213] Reclamation Sage +SB: 1 [JOU:154] Pharika, God of Affliction +SB: 2 [THS:90] Hero's Downfall +SB: 2 [THS:150] Arbor Colossus +SB: 4 [BNG:65] Drown in Sorrow +SB: 2 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Golgari Control TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Golgari Control TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..e64a0145eee --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Golgari Control TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,32 @@ +1 [RTR:83] Underworld Connections +1 [UNH:140] Forest +4 [RTR:63] Desecration Demon +3 [M14:195] Scavenging Ooze +2 [RTR:141] Abrupt Decay +4 [RTR:243] Overgrown Tomb +3 [M14:101] Lifebane Zombie +4 [M13:193] Thragtusk +2 [C14:167] Tragic Slip +1 [C14:295] Evolving Wilds +3 [M14:228] Mutavault +2 [C14:140] Disciple of Bolas +1 [RTR:208] Vraska the Unseen +1 [M14:96] Doom Blade +3 [C14:150] Mutilate +3 [C14:161] Sign in Blood +1 [DGM:93] Putrefy +2 [GTC:63] Devour Flesh +4 [ISD:249] Woodland Cemetery +13 [UNH:138] Swamp +3 [ISD:105] Liliana of the Veil +SB: 1 [RTR:83] Underworld Connections +SB: 1 [M14:101] Lifebane Zombie +SB: 2 [AVR:94] Demonic Rising +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M14:190] Primeval Bounty +SB: 1 [C14:150] Mutilate +SB: 1 [RTR:208] Vraska the Unseen +SB: 3 [M14:97] Duress +SB: 1 [RTR:164] Golgari Charm +SB: 1 [RTR:141] Abrupt Decay +SB: 1 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..67b764d8098 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,29 @@ +4 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +10 [UNH:140] Forest +2 [CNS:138] Brimstone Volley +4 [MBS:81] Green Sun's Zenith +4 [M12:165] Birds of Paradise +4 [C14:204] Llanowar Elves +3 [UNH:139] Mountain +1 [C13:134] Acidic Slime +1 [ISD:170] Avacyn's Pilgrim +1 [ISD:181] Garruk Relentless +2 [ISD:243] Kessig Wolf Run +3 [NPH:42] Phyrexian Metamorph +4 [DKA:127] Strangleroot Geist +2 [ISD:176] Daybreak Ranger +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +3 [SOM:91] Galvanic Blast +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [M12:150] Manabarbs +SB: 1 [C13:134] Acidic Slime +SB: 1 [MBS:138] Sword of Feast and Famine +SB: 1 [NPH:78] Act of Aggression +SB: 1 [NPH:130] Batterskull +SB: 2 [SOM:81] Arc Trail +SB: 1 [M12:188] Primeval Titan +SB: 2 [DKA:120] Increasing Savagery +SB: 1 [M12:197] Stingerfling Spider +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..554e6e18363 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,27 @@ +2 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +9 [UNH:140] Forest +2 [MBS:95] Viridian Emissary +4 [M12:165] Birds of Paradise +3 [C14:204] Llanowar Elves +2 [UNH:139] Mountain +3 [M13:185] Rancor +1 [M13:150] Thundermaw Hellkite +4 [ISD:243] Kessig Wolf Run +4 [DKA:127] Strangleroot Geist +2 [MBS:138] Sword of Feast and Famine +2 [AVR:149] Pillar of Flame +2 [AVR:206] Wolfir Silverheart +4 [AVR:129] Bonfire of the Damned +4 [SOM:225] Copperline Gorge +3 [AVR:169] Borderland Ranger +3 [DKA:140] Huntmaster of the Fells +2 [AVR:141] Hound of Griselbrand +SB: 1 [M13:185] Rancor +SB: 2 [AVR:149] Pillar of Flame +SB: 2 [M12:128] Combust +SB: 3 [AVR:166] Zealous Conscripts +SB: 2 [C14:184] Whipflare +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [DKA:110] Crushing Vines +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..98ede8517fa --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,25 @@ +2 [MBS:66] Hero of Oxid Ridge +4 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +7 [UNH:140] Forest +1 [CNS:138] Brimstone Volley +4 [M12:146] Incinerate +1 [MBS:92] Thrun, the Last Troll +4 [M12:165] Birds of Paradise +4 [C14:204] Llanowar Elves +6 [UNH:139] Mountain +2 [ISD:243] Kessig Wolf Run +1 [NPH:42] Phyrexian Metamorph +4 [DKA:127] Strangleroot Geist +4 [NPH:86] Gut Shot +4 [DKA:93] Hellrider +4 [SOM:225] Copperline Gorge +2 [DKA:140] Huntmaster of the Fells +2 [SOM:91] Galvanic Blast +SB: 2 [KTK:142] Naturalize +SB: 2 [ISD:166] Traitorous Blood +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 3 [NPH:57] Dismember +SB: 2 [NPH:38] Mental Misstep +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..63456e38ea9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,28 @@ +1 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +8 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +4 [MBS:81] Green Sun's Zenith +4 [M12:165] Birds of Paradise +4 [C14:204] Llanowar Elves +2 [UNH:139] Mountain +4 [ISD:243] Kessig Wolf Run +3 [DKA:127] Strangleroot Geist +2 [AVR:226] Cavern of Souls +3 [MBS:138] Sword of Feast and Famine +3 [AVR:206] Wolfir Silverheart +4 [AVR:129] Bonfire of the Damned +2 [NPH:57] Dismember +4 [SOM:225] Copperline Gorge +3 [AVR:169] Borderland Ranger +4 [DKA:140] Huntmaster of the Fells +SB: 1 [NPH:161] Sword of War and Peace +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [M12:128] Combust +SB: 1 [AVR:206] Wolfir Silverheart +SB: 2 [C14:283] Wurmcoil Engine +SB: 2 [AVR:166] Zealous Conscripts +SB: 1 [M15:192] Plummet +SB: 1 [NPH:103] Beast Within +SB: 2 [DKA:110] Crushing Vines +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..b926075697f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gr Aggro TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,28 @@ +3 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +9 [UNH:140] Forest +1 [M12:146] Incinerate +4 [MBS:81] Green Sun's Zenith +4 [M12:165] Birds of Paradise +4 [C14:204] Llanowar Elves +3 [UNH:139] Mountain +1 [C13:134] Acidic Slime +2 [ISD:181] Garruk Relentless +2 [ISD:243] Kessig Wolf Run +4 [DKA:127] Strangleroot Geist +1 [ISD:176] Daybreak Ranger +2 [DKA:93] Hellrider +1 [AVR:149] Pillar of Flame +3 [AVR:205] Wolfir Avenger +1 [AVR:206] Wolfir Silverheart +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +3 [SOM:91] Galvanic Blast +SB: 3 [KTK:142] Naturalize +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [MBS:138] Sword of Feast and Famine +SB: 2 [NPH:78] Act of Aggression +SB: 2 [AVR:166] Zealous Conscripts +SB: 2 [NPH:130] Batterskull +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 3 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Grixis Control TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Control TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..10547d5c10d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Control TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,33 @@ +2 [MBS:75] Slagstorm +1 [MBS:43] Go for the Throat +1 [NPH:130] Batterskull +3 [M13:223] Drowned Catacomb +3 [M13:222] Dragonskull Summit +2 [M12:111] Sorin's Vengeance +2 [UNH:139] Mountain +4 [ISD:78] Snapcaster Mage +4 [ISD:55] Forbidden Alchemy +2 [C14:136] Black Sun's Zenith +1 [ISD:247] Stensia Bloodhall +2 [M15:51] Dissipate +3 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +1 [SOM:224] Blackcleave Cliffs +1 [ISD:119] Tribute to Hunger +4 [UNH:137] Island +3 [ISD:139] Desperate Ravings +4 [ISD:248] Sulfur Falls +4 [UNH:138] Swamp +2 [ISD:215] Olivia Voldaren +3 [SOM:91] Galvanic Blast +4 [M12:63] Mana Leak +SB: 1 [C14:136] Black Sun's Zenith +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [MBS:74] Red Sun's Zenith +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [M14:96] Doom Blade +SB: 1 [M15:51] Dissipate +SB: 2 [M12:72] Phantasmal Image +SB: 2 [NPH:159] Spellskite +SB: 2 [M15:71] Negate +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Grixis Tezzeret TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Tezzeret TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..fe801c19751 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Tezzeret TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,31 @@ +4 [MBS:97] Tezzeret, Agent of Bolas +1 [SOM:176] Mindslaver +2 [MBS:75] Slagstorm +1 [MBS:34] Treasure Mage +4 [WWK:134] Creeping Tar Pit +2 [SOM:46] Stoic Rebuttal +4 [C14:239] Everflowing Chalice +2 [M11:154] Pyroclasm +2 [UNH:139] Mountain +3 [C14:313] Tectonic Edge +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +3 [SOM:218] Tumble Magnet +1 [C14:283] Wurmcoil Engine +2 [MBS:145] Inkmoth Nexus +3 [MBS:134] Sphere of the Suns +3 [SOM:226] Darkslick Shores +4 [GTC:234] Prophetic Prism +3 [WWK:31] Jace, the Mind Sculptor +1 [SOM:224] Blackcleave Cliffs +2 [SOM:179] Mox Opal +3 [UNH:137] Island +2 [SOM:91] Galvanic Blast +SB: 2 [SOM:46] Stoic Rebuttal +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [SOM:96] Kuldotha Rebirth +SB: 4 [ZEN:70] Spreading Seas +SB: 3 [M14:97] Duress +SB: 1 [WWK:31] Jace, the Mind Sculptor +SB: 2 [M11:154] Pyroclasm +SB: 1 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Grixis Twin Exarch TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Twin Exarch TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..71e8b6147e2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Grixis Twin Exarch TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,25 @@ +1 [MBS:21] Consecrated Sphinx +2 [MBS:43] Go for the Throat +4 [WWK:134] Creeping Tar Pit +2 [WWK:137] Halimar Depths +4 [ROE:115] Inquisition of Kozilek +3 [NPH:159] Spellskite +4 [C13:37] Deceiver Exarch +4 [ROE:165] Splinter Twin +2 [UNH:139] Mountain +2 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +2 [NPH:57] Dismember +4 [SOM:226] Darkslick Shores +3 [M14:97] Duress +3 [WWK:31] Jace, the Mind Sculptor +4 [SOM:224] Blackcleave Cliffs +4 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 1 [MBS:21] Consecrated Sphinx +SB: 2 [KTK:120] Shatter +SB: 2 [M12:128] Combust +SB: 3 [SOM:50] Twisted Image +SB: 4 [WWK:25] Calcite Snapper +SB: 3 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..422f066eea4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [M13:147] Searing Spear +12 [UNH:139] Mountain +2 [M13:185] Rancor +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +1 [RTR:248] Temple Garden +3 [DKA:93] Hellrider +2 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +4 [AVR:144] Lightning Mauler +4 [GTC:167] Ghor-Clan Rampager +SB: 1 [RTR:93] Electrickery +SB: 2 [C14:278] Tormod's Crypt +SB: 2 [ISD:166] Traitorous Blood +SB: 1 [AVR:149] Pillar of Flame +SB: 3 [GTC:106] Skullcrack +SB: 2 [C14:172] Blasphemous Act +SB: 4 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..95a460a583a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,20 @@ +4 [RTR:86] Ash Zealot +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [M13:147] Searing Spear +2 [M13:155] Volcanic Strength +10 [UNH:139] Mountain +4 [M13:185] Rancor +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +4 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +4 [AVR:144] Lightning Mauler +SB: 3 [RTR:101] Mizzium Mortars +SB: 1 [DKA:93] Hellrider +SB: 4 [GTC:106] Skullcrack +SB: 2 [C14:172] Blasphemous Act +SB: 3 [GTC:156] Domri Rade +SB: 2 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..9a1d3c60ef2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,19 @@ +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [M13:147] Searing Spear +12 [UNH:139] Mountain +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +2 [RTR:248] Temple Garden +4 [DKA:93] Hellrider +3 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:98] Madcap Skills +SB: 3 [M13:141] Mark of Mutiny +SB: 2 [RTR:93] Electrickery +SB: 3 [RTR:101] Mizzium Mortars +SB: 3 [GTC:106] Skullcrack +SB: 4 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..d6e8c775023 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,23 @@ +3 [GTC:90] Firefist Striker +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +3 [M13:147] Searing Spear +12 [UNH:139] Mountain +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +1 [RTR:248] Temple Garden +3 [DKA:93] Hellrider +4 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +3 [AVR:144] Lightning Mauler +3 [GTC:167] Ghor-Clan Rampager +SB: 2 [RTR:101] Mizzium Mortars +SB: 1 [C14:278] Tormod's Crypt +SB: 3 [RTR:86] Ash Zealot +SB: 2 [ISD:166] Traitorous Blood +SB: 2 [GTC:106] Skullcrack +SB: 2 [C14:172] Blasphemous Act +SB: 1 [M13:147] Searing Spear +SB: 2 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..7bd7ad080dc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,20 @@ +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [CNS:138] Brimstone Volley +4 [M13:147] Searing Spear +12 [UNH:139] Mountain +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +4 [DKA:93] Hellrider +1 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +4 [AVR:144] Lightning Mauler +3 [GTC:167] Ghor-Clan Rampager +SB: 1 [RTR:101] Mizzium Mortars +SB: 3 [DKA:149] Grafdigger's Cage +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [GTC:106] Skullcrack +SB: 2 [C14:172] Blasphemous Act +SB: 3 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..17ef7447b2d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Aggro TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,18 @@ +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +3 [M13:147] Searing Spear +13 [UNH:139] Mountain +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +4 [DKA:93] Hellrider +4 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:247] Stomping Ground +4 [AVR:144] Lightning Mauler +4 [GTC:167] Ghor-Clan Rampager +SB: 3 [DKA:101] Pyreheart Wolf +SB: 2 [RTR:101] Mizzium Mortars +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [GTC:106] Skullcrack +SB: 4 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..fe36ef1f747 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:224] Temple of Abandon +1 [UNH:140] Forest +4 [KTK:118] Monastery Swiftspear +4 [FRF:118] Wild Slash +4 [KTK:249] Wooded Foothills +4 [M15:141] Foundry Street Denizen +1 [M15:142] Frenzied Goblin +4 [M15:164] Stoke the Flames +10 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +1 [KTK:130] Become Immense +1 [DTK:146] Lightning Berserker +4 [DTK:135] Dragon Fodder +3 [DTK:169] Zurgo Bellstriker +4 [DTK:213] Atarka's Command +4 [JOU:163] Mana Confluence +SB: 2 [M15:145] Goblin Rabblemaster +SB: 1 [BNG:110] Scouring Sands +SB: 2 [JOU:162] Hall of Triumph +SB: 4 [JOU:94] Eidolon of the Great Revel +SB: 4 [DTK:151] Roast +SB: 1 [FRF:102] Goblin Heelcutter +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..8b77597ad7e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Deck Wins TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,25 @@ +1 [THS:224] Temple of Abandon +1 [UNH:140] Forest +4 [KTK:118] Monastery Swiftspear +4 [FRF:118] Wild Slash +4 [KTK:249] Wooded Foothills +4 [M15:141] Foundry Street Denizen +4 [M15:164] Stoke the Flames +10 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +1 [KTK:130] Become Immense +2 [DTK:146] Lightning Berserker +4 [DTK:135] Dragon Fodder +3 [DTK:169] Zurgo Bellstriker +4 [DTK:213] Atarka's Command +4 [JOU:163] Mana Confluence +SB: 2 [M15:145] Goblin Rabblemaster +SB: 1 [JOU:100] Harness by Force +SB: 1 [BNG:110] Scouring Sands +SB: 4 [JOU:94] Eidolon of the Great Revel +SB: 1 [DTK:150] Rending Volley +SB: 1 [FRF:102] Goblin Heelcutter +SB: 4 [DTK:151] Roast +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Dragons TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Dragons TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..9ae5cd7287b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Dragons TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,25 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +6 [UNH:140] Forest +1 [FRF:170] Rugged Highlands +4 [KTK:249] Wooded Foothills +4 [KTK:106] Crater's Claws +3 [KTK:134] Heir of the Wilds +1 [DTK:249] Haven of the Spirit Dragon +5 [UNH:139] Mountain +4 [M15:145] Goblin Rabblemaster +4 [KTK:144] Rattleclaw Mystic +2 [JOU:163] Mana Confluence +3 [DTK:210] Surrak, the Hunt Caller +4 [THS:152] Boon Satyr +2 [DTK:134] Draconic Roar +4 [C14:191] Elvish Mystic +4 [DTK:162] Thunderbreak Regent +1 [DTK:151] Roast +SB: 3 [M15:177] Hornet Nest +SB: 3 [THS:209] Xenagos, the Reveler +SB: 2 [KTK:97] Arc Lightning +SB: 1 [M15:192] Plummet +SB: 3 [FRF:118] Wild Slash +SB: 1 [DTK:151] Roast +SB: 2 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Midrange TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Midrange TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..6784a59698a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Midrange TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,21 @@ +4 [M13:228] Rootbound Crag +9 [UNH:140] Forest +3 [M14:195] Scavenging Ooze +6 [UNH:139] Mountain +3 [RTR:101] Mizzium Mortars +4 [M13:150] Thundermaw Hellkite +4 [M13:160] Arbor Elf +4 [M13:171] Flinthoof Boar +4 [DKA:127] Strangleroot Geist +4 [DKA:93] Hellrider +1 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +2 [C14:191] Elvish Mystic +SB: 2 [M15:134] Chandra, Pyromaster +SB: 2 [AVR:149] Pillar of Flame +SB: 2 [AVR:129] Bonfire of the Damned +SB: 2 [M14:171] Fog +SB: 3 [M13:155] Volcanic Strength +SB: 4 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Monsters TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Monsters TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..405ab3acdce --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Monsters TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,26 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +8 [UNH:140] Forest +2 [THS:209] Xenagos, the Reveler +1 [M14:195] Scavenging Ooze +5 [UNH:139] Mountain +3 [RTR:101] Mizzium Mortars +4 [BNG:119] Courser of Kruphix +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +1 [DGM:128] Flesh // Blood +4 [THS:172] Polukranos, World Eater +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +2 [BNG:156] Xenagos, God of Revels +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [M15:134] Chandra, Pyromaster +SB: 2 [M14:155] Shock +SB: 1 [THS:153] Bow of Nylea +SB: 1 [DGM:99] Ruric Thar, the Unbowed +SB: 1 [THS:150] Arbor Colossus +SB: 2 [M15:192] Plummet +SB: 4 [THS:162] Mistcutter Hydra +SB: 2 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Gruul Team TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Team TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..4d48da0b7fe --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Gruul Team TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,21 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +10 [UNH:140] Forest +2 [THS:209] Xenagos, the Reveler +4 [M14:182] Kalonian Tusker +6 [UNH:139] Mountain +3 [M14:202] Witchstalker +4 [GTC:247] Stomping Ground +2 [DGM:128] Flesh // Blood +3 [THS:172] Polukranos, World Eater +3 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +4 [THS:152] Boon Satyr +4 [C14:191] Elvish Mystic +3 [THS:180] Sylvan Caryatid +SB: 2 [THS:157] Fade into Antiquity +SB: 3 [RTR:101] Mizzium Mortars +SB: 2 [RTR:231] Pithing Needle +SB: 2 [DGM:99] Ruric Thar, the Unbowed +SB: 2 [M15:192] Plummet +SB: 4 [THS:162] Mistcutter Hydra diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Hoof there it is TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Hoof there it is TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..6709a67d85c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Hoof there it is TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,22 @@ +4 [AVR:172] Craterhoof Behemoth +4 [AVR:194] Somberwald Sage +6 [UNH:140] Forest +2 [RTR:241] Hallowed Fountain +4 [RTR:243] Overgrown Tomb +4 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [RTR:165] Grisly Salvage +3 [ISD:122] Unburial Rites +4 [RTR:248] Temple Garden +4 [DKA:128] Tracker's Instincts +3 [RTR:213] Deathrite Shaman +3 [ISD:196] Mulch +1 [M14:229] Shimmering Grotto +4 [DKA:12] Lingering Souls +2 [ISD:239] Gavony Township +4 [ISD:249] Woodland Cemetery +SB: 2 [AVR:32] Restoration Angel +SB: 3 [RTR:178] Loxodon Smiter +SB: 4 [M13:193] Thragtusk +SB: 2 [AVR:226] Cavern of Souls +SB: 4 [RTR:1] Angel of Serenity diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..01acdbfab33 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,26 @@ +4 [C13:11] Fiend Hunter +3 [M13:229] Sunpetal Grove +4 [AVR:1] Angel of Glory's Rise +1 [RTR:141] Abrupt Decay +4 [GTC:150] Cartel Aristocrat +1 [RTR:243] Overgrown Tomb +4 [RTR:165] Grisly Salvage +1 [RTR:238] Blood Crypt +4 [M13:170] Farseek +4 [ISD:122] Unburial Rites +2 [RTR:248] Temple Garden +4 [AVR:226] Cavern of Souls +4 [C14:175] Faithless Looting +4 [ISD:196] Mulch +4 [GTC:247] Stomping Ground +1 [GTC:245] Sacred Foundry +4 [DKA:140] Huntmaster of the Fells +1 [GTC:242] Godless Shrine +2 [ISD:238] Clifftop Retreat +4 [ISD:249] Woodland Cemetery +SB: 2 [ISD:161] Rolling Temblor +SB: 3 [M13:193] Thragtusk +SB: 2 [ISD:27] Purify the Grave +SB: 3 [RTR:148] Centaur Healer +SB: 2 [M14:97] Duress +SB: 3 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..c3347d8770e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Human Reanimator TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,26 @@ +4 [C13:11] Fiend Hunter +2 [M13:228] Rootbound Crag +3 [GTC:216] Burning-Tree Emissary +4 [AVR:1] Angel of Glory's Rise +2 [GTC:150] Cartel Aristocrat +4 [RTR:243] Overgrown Tomb +4 [RTR:165] Grisly Salvage +4 [RTR:238] Blood Crypt +4 [ISD:122] Unburial Rites +2 [AVR:226] Cavern of Souls +3 [RTR:248] Temple Garden +4 [ISD:242] Isolated Chapel +4 [C14:175] Faithless Looting +4 [ISD:196] Mulch +2 [GTC:247] Stomping Ground +3 [DKA:140] Huntmaster of the Fells +1 [ISD:238] Clifftop Retreat +1 [ISD:249] Woodland Cemetery +2 [GTC:82] Undercity Informer +3 [ISD:105] Liliana of the Veil +SB: 2 [ISD:161] Rolling Temblor +SB: 3 [M13:193] Thragtusk +SB: 3 [DKA:138] Falkenrath Aristocrat +SB: 2 [AVR:166] Zealous Conscripts +SB: 1 [DKA:140] Huntmaster of the Fells +SB: 4 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..cb1a72c47ef --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,25 @@ +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +4 [M12:70] Phantasmal Bear +3 [NPH:86] Gut Shot +4 [SOM:229] Seachrome Coast +4 [NPH:35] Gitaxian Probe +2 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +3 [M12:72] Phantasmal Image +4 [ISD:51] Delver of Secrets +9 [UNH:137] Island +4 [M12:62] Lord of the Unreal +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [NPH:86] Gut Shot +SB: 2 [M15:51] Dissipate +SB: 1 [MBS:115] Mortarpod +SB: 1 [ISD:244] Moorland Haunt +SB: 3 [NPH:38] Mental Misstep +SB: 2 [M13:22] Oblivion Ring +SB: 1 [M12:72] Phantasmal Image +SB: 1 [M15:71] Negate +SB: 2 [M12:52] Flashfreeze +SB: 1 [C14:79] Mentor of the Meek diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..71da5971513 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,26 @@ +2 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +4 [M12:70] Phantasmal Bear +3 [NPH:86] Gut Shot +4 [SOM:229] Seachrome Coast +3 [NPH:35] Gitaxian Probe +3 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +4 [ISD:244] Moorland Haunt +3 [M12:72] Phantasmal Image +4 [ISD:51] Delver of Secrets +8 [UNH:137] Island +2 [M12:62] Lord of the Unreal +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [ISD:80] Stitched Drake +SB: 2 [M15:51] Dissipate +SB: 2 [M13:75] Unsummon +SB: 2 [M13:22] Oblivion Ring +SB: 1 [M12:72] Phantasmal Image +SB: 3 [M12:40] Timely Reinforcements +SB: 1 [M12:52] Flashfreeze +SB: 1 [M15:71] Negate +SB: 1 [C14:79] Mentor of the Meek diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..e9843d65ae4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Illusions TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,25 @@ +3 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +4 [M12:70] Phantasmal Bear +3 [NPH:86] Gut Shot +4 [SOM:229] Seachrome Coast +2 [NPH:57] Dismember +4 [NPH:35] Gitaxian Probe +1 [ISD:80] Stitched Drake +2 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +4 [ISD:51] Delver of Secrets +4 [M12:72] Phantasmal Image +10 [UNH:137] Island +4 [M12:62] Lord of the Unreal +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 3 [ISD:80] Stitched Drake +SB: 2 [M15:51] Dissipate +SB: 1 [MBS:115] Mortarpod +SB: 1 [ISD:244] Moorland Haunt +SB: 2 [NPH:38] Mental Misstep +SB: 1 [NPH:159] Spellskite +SB: 2 [M12:40] Timely Reinforcements +SB: 1 [M15:71] Negate +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Ascendancy TDtB ST Oct 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Ascendancy TDtB ST Oct 2014.mwDeck.dck new file mode 100644 index 00000000000..8fc729be8c2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Ascendancy TDtB ST Oct 2014.mwDeck.dck @@ -0,0 +1,29 @@ +2 [THS:224] Temple of Abandon +2 [JOU:115] Twinflame +2 [THS:226] Temple of Mystery +1 [UNH:140] Forest +4 [BNG:49] Retraction Helix +4 [THS:155] Commune with the Gods +2 [KTK:217] Briber's Purse +2 [KTK:249] Wooded Foothills +3 [KTK:36] Dig Through Time +2 [KTK:233] Flooded Strand +4 [THS:119] Dragon Mantle +3 [KTK:123] Tormenting Voice +2 [KTK:234] Frontier Bivouac +1 [M15:187] Nissa, Worldwaker +1 [UNH:139] Mountain +4 [KTK:144] Rattleclaw Mystic +2 [M15:249] Yavimaya Coast +2 [BNG:165] Temple of Plenty +4 [JOU:163] Mana Confluence +4 [KTK:180] Jeskai Ascendancy +1 [UNH:136] Plains +3 [BNG:150] Kiora's Follower +1 [UNH:137] Island +4 [THS:180] Sylvan Caryatid +SB: 3 [M15:155] Lightning Strike +SB: 4 [KTK:197] Savage Knuckleblade +SB: 3 [KTK:97] Arc Lightning +SB: 2 [THS:172] Polukranos, World Eater +SB: 3 [THS:65] Swan Song diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..54744e25718 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,29 @@ +3 [FRF:28] Valorous Stance +1 [FRF:110] Outpost Siege +3 [THS:143] Stormbreath Dragon +3 [FRF:118] Wild Slash +4 [KTK:22] Seeker of the Way +2 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +1 [KTK:36] Dig Through Time +4 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +3 [KTK:59] Treasure Cruise +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +2 [JOU:164] Temple of Epiphany +1 [FRF:2] Abzan Advantage +2 [UNH:136] Plains +2 [UNH:137] Island +1 [FRF:27] Soulfire Grand Master +SB: 1 [FRF:28] Valorous Stance +SB: 1 [FRF:110] Outpost Siege +SB: 1 [THS:15] Glare of Heresy +SB: 2 [BNG:5] Brimaz, King of Oreskos +SB: 3 [THS:112] Anger of the Gods +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 3 [KTK:37] Disdainful Stroke +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..09b579052cf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Midrange TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,32 @@ +3 [FRF:28] Valorous Stance +1 [FRF:110] Outpost Siege +2 [KTK:119] Sarkhan, the Dragonspeaker +3 [FRF:118] Wild Slash +4 [KTK:22] Seeker of the Way +2 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +3 [KTK:36] Dig Through Time +4 [KTK:233] Flooded Strand +1 [KTK:37] Disdainful Stroke +4 [M15:164] Stoke the Flames +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +2 [JOU:164] Temple of Epiphany +2 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +2 [UNH:137] Island +2 [FRF:27] Soulfire Grand Master +SB: 1 [FRF:28] Valorous Stance +SB: 1 [FRF:110] Outpost Siege +SB: 1 [THS:15] Glare of Heresy +SB: 1 [KTK:9] Erase +SB: 1 [KTK:8] End Hostilities +SB: 2 [BNG:5] Brimaz, King of Oreskos +SB: 2 [THS:112] Anger of the Gods +SB: 1 [FRF:2] Abzan Advantage +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 2 [KTK:37] Disdainful Stroke +SB: 2 [DTK:65] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..eb6306732e2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,26 @@ +4 [KTK:22] Seeker of the Way +3 [THS:128] Magma Jet +2 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [KTK:36] Dig Through Time +4 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +1 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +2 [JOU:164] Temple of Epiphany +1 [THS:60] Prognostic Sphinx +1 [JOU:163] Mana Confluence +4 [BNG:45] Nullify +2 [UNH:136] Plains +2 [UNH:137] Island +2 [BNG:163] Temple of Enlightenment +SB: 2 [JOU:103] Magma Spray +SB: 3 [BNG:5] Brimaz, King of Oreskos +SB: 1 [JOU:5] Banishing Light +SB: 4 [KTK:25] Suspension Field +SB: 3 [KTK:37] Disdainful Stroke +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..24e4878ad66 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,29 @@ +3 [BNG:5] Brimaz, King of Oreskos +1 [THS:16] Gods Willing +1 [JOU:5] Banishing Light +2 [KTK:119] Sarkhan, the Dragonspeaker +2 [KTK:99] Ashcloud Phoenix +4 [KTK:22] Seeker of the Way +3 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +1 [KTK:36] Dig Through Time +3 [KTK:233] Flooded Strand +3 [M15:164] Stoke the Flames +2 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +3 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +1 [JOU:164] Temple of Epiphany +2 [UNH:136] Plains +2 [UNH:137] Island +SB: 3 [JOU:103] Magma Spray +SB: 1 [THS:16] Gods Willing +SB: 2 [KTK:97] Arc Lightning +SB: 1 [JOU:151] Keranos, God of Storms +SB: 3 [KTK:25] Suspension Field +SB: 3 [KTK:37] Disdainful Stroke +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Oct 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Oct 2014.mwDeck.dck new file mode 100644 index 00000000000..26f8c23a1e4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tempo TDtB ST Oct 2014.mwDeck.dck @@ -0,0 +1,25 @@ +3 [BNG:5] Brimaz, King of Oreskos +2 [THS:16] Gods Willing +3 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:22] Seeker of the Way +4 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +3 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +3 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +3 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +2 [UNH:136] Plains +2 [UNH:137] Island +SB: 1 [M15:134] Chandra, Pyromaster +SB: 3 [JOU:103] Magma Spray +SB: 1 [THS:16] Gods Willing +SB: 2 [THS:60] Prognostic Sphinx +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 4 [KTK:25] Suspension Field +SB: 3 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Token TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Token TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..9353431d875 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Token TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,28 @@ +4 [M15:26] Raise the Alarm +4 [KTK:22] Seeker of the Way +1 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +3 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +4 [KTK:59] Treasure Cruise +2 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +2 [M15:134] Chandra, Pyromaster +4 [KTK:111] Hordeling Outburst +3 [M15:246] Shivan Reef +1 [KTK:181] Jeskai Charm +2 [JOU:164] Temple of Epiphany +4 [KTK:180] Jeskai Ascendancy +2 [UNH:136] Plains +1 [UNH:137] Island +SB: 2 [M15:15] Hushwing Gryff +SB: 2 [THS:15] Glare of Heresy +SB: 2 [KTK:9] Erase +SB: 3 [KTK:8] End Hostilities +SB: 1 [JOU:23] Reprisal +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 3 [KTK:37] Disdainful Stroke +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tokens TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tokens TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..3271b205706 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jeskai Tokens TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,29 @@ +2 [FRF:28] Valorous Stance +3 [M15:26] Raise the Alarm +1 [KTK:119] Sarkhan, the Dragonspeaker +4 [FRF:118] Wild Slash +4 [KTK:22] Seeker of the Way +3 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +4 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +4 [KTK:59] Treasure Cruise +2 [UNH:139] Mountain +2 [M15:155] Lightning Strike +4 [KTK:111] Hordeling Outburst +3 [M15:246] Shivan Reef +1 [DTK:135] Dragon Fodder +1 [KTK:184] Mantis Rider +1 [JOU:164] Temple of Epiphany +4 [KTK:180] Jeskai Ascendancy +2 [DTK:36] Secure the Wastes +1 [UNH:136] Plains +2 [UNH:137] Island +SB: 1 [THS:15] Glare of Heresy +SB: 2 [DTK:27] Ojutai Exemplars +SB: 2 [KTK:8] End Hostilities +SB: 2 [DTK:156] Seismic Rupture +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 4 [KTK:37] Disdainful Stroke +SB: 2 [DTK:65] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..cea274efcc6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,28 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +4 [UNH:140] Forest +2 [THS:209] Xenagos, the Reveler +3 [M14:195] Scavenging Ooze +3 [RTR:157] Dreadbore +1 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +3 [BNG:119] Courser of Kruphix +4 [RTR:238] Blood Crypt +1 [BNG:164] Temple of Malice +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +4 [THS:172] Polukranos, World Eater +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +1 [DGM:104] Sire of Insanity +4 [THS:180] Sylvan Caryatid +SB: 2 [RTR:82] Ultimate Price +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [M15:134] Chandra, Pyromaster +SB: 1 [RTR:208] Vraska the Unseen +SB: 3 [THS:162] Mistcutter Hydra +SB: 2 [RTR:164] Golgari Charm +SB: 2 [THS:107] Thoughtseize +SB: 2 [RTR:141] Abrupt Decay +SB: 1 [DGM:104] Sire of Insanity diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..6d0c16098f5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Aggro TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,27 @@ +4 [GTC:119] Experiment One +2 [UNH:140] Forest +3 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +2 [M13:147] Searing Spear +2 [M13:222] Dragonskull Summit +2 [RTR:141] Abrupt Decay +4 [M13:143] Mogg Flunkies +1 [UNH:139] Mountain +3 [RTR:157] Dreadbore +4 [RTR:243] Overgrown Tomb +4 [M13:171] Flinthoof Boar +4 [RTR:220] Rakdos Cackler +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +3 [RTR:158] Dreg Mangler +4 [GTC:247] Stomping Ground +4 [GTC:167] Ghor-Clan Rampager +2 [ISD:249] Woodland Cemetery +SB: 1 [ISD:243] Kessig Wolf Run +SB: 3 [C13:97] Vampire Nighthawk +SB: 2 [AVR:206] Wolfir Silverheart +SB: 1 [M13:147] Searing Spear +SB: 2 [GTC:156] Domri Rade +SB: 1 [RTR:141] Abrupt Decay +SB: 3 [RTR:59] Cremate +SB: 2 [ISD:215] Olivia Voldaren diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..4fbb154180a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,35 @@ +2 [C13:97] Vampire Nighthawk +1 [M13:228] Rootbound Crag +2 [UNH:140] Forest +4 [M13:222] Dragonskull Summit +1 [M13:101] Murder +2 [M13:174] Garruk, Primal Hunter +1 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [C14:167] Tragic Slip +2 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +2 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +1 [ISD:124] Victim of Night +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +1 [ISD:105] Liliana of the Veil +1 [RTR:141] Abrupt Decay +2 [M13:176] Ground Seal +1 [RTR:157] Dreadbore +2 [M13:160] Arbor Elf +4 [RTR:238] Blood Crypt +3 [ISD:215] Olivia Voldaren +SB: 1 [RTR:101] Mizzium Mortars +SB: 2 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [DKA:149] Grafdigger's Cage +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [AVR:129] Bonfire of the Damned +SB: 1 [RTR:208] Vraska the Unseen +SB: 2 [M14:97] Duress +SB: 2 [RTR:197] Slaughter Games +SB: 2 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..0dbbe145813 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,24 @@ +4 [M13:228] Rootbound Crag +4 [RTR:173] Izzet Staticaster +4 [RTR:243] Overgrown Tomb +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +1 [ISD:243] Kessig Wolf Run +3 [RTR:238] Blood Crypt +4 [M13:170] Farseek +2 [AVR:226] Cavern of Souls +4 [DKA:128] Tracker's Instincts +3 [RTR:247] Steam Vents +4 [ISD:241] Hinterland Harbor +4 [RTR:213] Deathrite Shaman +1 [AVR:129] Bonfire of the Damned +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +4 [AVR:187] Nightshade Peddler +4 [ISD:215] Olivia Voldaren +SB: 3 [ISD:78] Snapcaster Mage +SB: 3 [AVR:84] Appetite for Brains +SB: 4 [AVR:149] Pillar of Flame +SB: 1 [AVR:129] Bonfire of the Damned +SB: 1 [M14:97] Duress +SB: 3 [RTR:197] Slaughter Games diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..d89a80d4c4d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,32 @@ +1 [RTR:82] Ultimate Price +1 [M13:228] Rootbound Crag +3 [UNH:140] Forest +3 [M13:222] Dragonskull Summit +1 [M13:101] Murder +2 [RTR:141] Abrupt Decay +2 [M13:174] Garruk, Primal Hunter +1 [RTR:157] Dreadbore +4 [RTR:243] Overgrown Tomb +2 [RTR:188] Rakdos's Return +3 [M13:160] Arbor Elf +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +2 [AVR:149] Pillar of Flame +4 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +2 [ISD:215] Olivia Voldaren +3 [ISD:105] Liliana of the Veil +SB: 2 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [C14:167] Tragic Slip +SB: 2 [DKA:149] Grafdigger's Cage +SB: 2 [DKA:127] Strangleroot Geist +SB: 1 [AVR:149] Pillar of Flame +SB: 2 [M13:217] Staff of Nin +SB: 2 [M14:97] Duress +SB: 1 [M13:101] Murder +SB: 1 [ISD:215] Olivia Voldaren diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..f45f86d438f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,29 @@ +3 [RTR:82] Ultimate Price +4 [C13:97] Vampire Nighthawk +2 [UNH:140] Forest +4 [M13:228] Rootbound Crag +3 [M13:147] Searing Spear +1 [M13:222] Dragonskull Summit +1 [UNH:139] Mountain +1 [M13:174] Garruk, Primal Hunter +4 [RTR:243] Overgrown Tomb +2 [M13:150] Thundermaw Hellkite +1 [RTR:232] Rakdos Keyrune +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +3 [AVR:226] Cavern of Souls +2 [AVR:149] Pillar of Flame +2 [AVR:129] Bonfire of the Damned +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +3 [ISD:215] Olivia Voldaren +SB: 1 [ISD:161] Rolling Temblor +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [M13:217] Staff of Nin +SB: 4 [RTR:213] Deathrite Shaman +SB: 3 [RTR:197] Slaughter Games +SB: 2 [ISD:94] Curse of Death's Hold +SB: 3 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..96fa68585dc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,31 @@ +2 [C13:97] Vampire Nighthawk +3 [M13:228] Rootbound Crag +3 [M13:222] Dragonskull Summit +1 [RTR:141] Abrupt Decay +2 [M13:176] Ground Seal +2 [M13:174] Garruk, Primal Hunter +4 [RTR:243] Overgrown Tomb +1 [RTR:232] Rakdos Keyrune +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [C14:167] Tragic Slip +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +1 [AVR:226] Cavern of Souls +2 [AVR:149] Pillar of Flame +4 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +2 [DGM:93] Putrefy +4 [ISD:249] Woodland Cemetery +3 [ISD:215] Olivia Voldaren +SB: 1 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 2 [C14:167] Tragic Slip +SB: 2 [DGM:99] Ruric Thar, the Unbowed +SB: 1 [AVR:149] Pillar of Flame +SB: 2 [M14:97] Duress +SB: 1 [ISD:94] Curse of Death's Hold +SB: 2 [M13:176] Ground Seal +SB: 3 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..eceb4d98e7f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,34 @@ +3 [M13:228] Rootbound Crag +2 [M13:222] Dragonskull Summit +1 [RTR:141] Abrupt Decay +2 [M13:176] Ground Seal +2 [M13:174] Garruk, Primal Hunter +1 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +1 [RTR:232] Rakdos Keyrune +1 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [C14:167] Tragic Slip +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +2 [AVR:226] Cavern of Souls +3 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +2 [DGM:93] Putrefy +4 [ISD:249] Woodland Cemetery +2 [DGM:104] Sire of Insanity +3 [ISD:215] Olivia Voldaren +1 [ISD:105] Liliana of the Veil +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [RTR:188] Rakdos's Return +SB: 2 [C14:167] Tragic Slip +SB: 2 [C13:97] Vampire Nighthawk +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [DGM:63] Deadbridge Chant +SB: 2 [RTR:208] Vraska the Unseen +SB: 1 [M14:97] Duress +SB: 1 [M13:176] Ground Seal +SB: 2 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..010b7a10f81 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Control TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,31 @@ +1 [C13:97] Vampire Nighthawk +3 [UNH:140] Forest +3 [M13:228] Rootbound Crag +3 [M13:222] Dragonskull Summit +2 [UNH:139] Mountain +3 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +3 [M13:150] Thundermaw Hellkite +2 [RTR:232] Rakdos Keyrune +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +1 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +3 [AVR:149] Pillar of Flame +2 [AVR:129] Bonfire of the Damned +1 [RTR:208] Vraska the Unseen +4 [DKA:140] Huntmaster of the Fells +2 [ISD:249] Woodland Cemetery +2 [UNH:138] Swamp +2 [ISD:215] Olivia Voldaren +3 [ISD:105] Liliana of the Veil +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 1 [RTR:83] Underworld Connections +SB: 1 [RTR:101] Mizzium Mortars +SB: 3 [C13:97] Vampire Nighthawk +SB: 3 [AVR:84] Appetite for Brains +SB: 1 [AVR:149] Pillar of Flame +SB: 3 [ISD:115] Sever the Bloodline +SB: 2 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..f2c396c87a3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,33 @@ +4 [M13:228] Rootbound Crag +1 [M13:222] Dragonskull Summit +3 [M14:195] Scavenging Ooze +1 [RTR:141] Abrupt Decay +2 [M13:174] Garruk, Primal Hunter +1 [RTR:157] Dreadbore +1 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +1 [RTR:232] Rakdos Keyrune +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [C14:167] Tragic Slip +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +4 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +1 [M14:96] Doom Blade +4 [DKA:140] Huntmaster of the Fells +2 [DGM:93] Putrefy +4 [ISD:249] Woodland Cemetery +2 [UNH:138] Swamp +3 [ISD:215] Olivia Voldaren +SB: 2 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [C13:134] Acidic Slime +SB: 1 [C14:167] Tragic Slip +SB: 1 [DKA:149] Grafdigger's Cage +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [AVR:85] Barter in Blood +SB: 2 [M14:97] Duress +SB: 1 [ISD:94] Curse of Death's Hold +SB: 3 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..6acb46e2c12 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,33 @@ +2 [C13:97] Vampire Nighthawk +2 [UNH:140] Forest +2 [M13:228] Rootbound Crag +3 [M13:222] Dragonskull Summit +2 [M13:176] Ground Seal +3 [M13:174] Garruk, Primal Hunter +1 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +1 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +2 [AVR:149] Pillar of Flame +2 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +2 [DGM:93] Putrefy +4 [ISD:249] Woodland Cemetery +1 [DGM:104] Sire of Insanity +3 [ISD:215] Olivia Voldaren +2 [ISD:105] Liliana of the Veil +SB: 1 [RTR:157] Dreadbore +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [DGM:63] Deadbridge Chant +SB: 1 [DGM:72] Gaze of Granite +SB: 2 [M14:97] Duress +SB: 2 [RTR:197] Slaughter Games +SB: 2 [GTC:63] Devour Flesh +SB: 2 [RTR:141] Abrupt Decay +SB: 1 [DGM:104] Sire of Insanity +SB: 1 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..1a2a8490229 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,29 @@ +2 [RTR:82] Ultimate Price +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +4 [UNH:140] Forest +4 [THS:209] Xenagos, the Reveler +3 [M14:195] Scavenging Ooze +1 [RTR:141] Abrupt Decay +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +2 [BNG:119] Courser of Kruphix +4 [RTR:238] Blood Crypt +1 [BNG:164] Temple of Malice +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +1 [JOU:163] Mana Confluence +4 [THS:172] Polukranos, World Eater +3 [GTC:167] Ghor-Clan Rampager +3 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [RTR:101] Mizzium Mortars +SB: 2 [M15:134] Chandra, Pyromaster +SB: 2 [RTR:188] Rakdos's Return +SB: 2 [M14:96] Doom Blade +SB: 1 [RTR:208] Vraska the Unseen +SB: 4 [THS:162] Mistcutter Hydra +SB: 1 [THS:83] Dark Betrayal +SB: 1 [DGM:93] Putrefy +SB: 1 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..bcbad1f560b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund Midrange TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,32 @@ +2 [UNH:140] Forest +2 [M13:228] Rootbound Crag +3 [M13:222] Dragonskull Summit +1 [M13:101] Murder +2 [RTR:141] Abrupt Decay +3 [M13:174] Garruk, Primal Hunter +2 [RTR:157] Dreadbore +1 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +1 [RTR:188] Rakdos's Return +2 [M13:160] Arbor Elf +4 [M13:193] Thragtusk +3 [C14:167] Tragic Slip +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +3 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +2 [ISD:215] Olivia Voldaren +3 [ISD:105] Liliana of the Veil +SB: 2 [RTR:83] Underworld Connections +SB: 2 [RTR:188] Rakdos's Return +SB: 1 [C13:134] Acidic Slime +SB: 1 [C14:167] Tragic Slip +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [M13:217] Staff of Nin +SB: 2 [M14:97] Duress +SB: 2 [RTR:197] Slaughter Games +SB: 1 [M13:176] Ground Seal +SB: 1 [ISD:215] Olivia Voldaren diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..6cbfb8b166b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,26 @@ +4 [THS:224] Temple of Abandon +3 [THS:143] Stormbreath Dragon +1 [UNH:140] Forest +4 [JOU:165] Temple of Malady +3 [THS:209] Xenagos, the Reveler +4 [M14:195] Scavenging Ooze +4 [RTR:141] Abrupt Decay +1 [UNH:139] Mountain +4 [RTR:157] Dreadbore +4 [M15:244] Llanowar Wastes +2 [M15:134] Chandra, Pyromaster +4 [BNG:119] Courser of Kruphix +3 [RTR:188] Rakdos's Return +3 [RTR:238] Blood Crypt +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +4 [THS:172] Polukranos, World Eater +2 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 2 [RTR:101] Mizzium Mortars +SB: 3 [JOU:103] Magma Spray +SB: 3 [THS:162] Mistcutter Hydra +SB: 2 [THS:83] Dark Betrayal +SB: 1 [DGM:93] Putrefy +SB: 2 [RTR:164] Golgari Charm +SB: 2 [RTR:197] Slaughter Games diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..2a360ee8466 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +4 [UNH:140] Forest +3 [THS:209] Xenagos, the Reveler +3 [M14:195] Scavenging Ooze +3 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +3 [BNG:119] Courser of Kruphix +4 [RTR:238] Blood Crypt +1 [BNG:164] Temple of Malice +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +1 [JOU:163] Mana Confluence +4 [THS:172] Polukranos, World Eater +2 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [RTR:82] Ultimate Price +SB: 2 [RTR:101] Mizzium Mortars +SB: 1 [M15:134] Chandra, Pyromaster +SB: 2 [RTR:188] Rakdos's Return +SB: 1 [RTR:208] Vraska the Unseen +SB: 4 [THS:162] Mistcutter Hydra +SB: 2 [DGM:93] Putrefy +SB: 2 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..b7d3ba794bf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Jund TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,29 @@ +2 [THS:201] Reaper of the Wilds +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +5 [UNH:140] Forest +3 [THS:209] Xenagos, the Reveler +1 [M14:195] Scavenging Ooze +2 [UNH:139] Mountain +2 [RTR:157] Dreadbore +2 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +4 [BNG:119] Courser of Kruphix +4 [RTR:238] Blood Crypt +4 [GTC:247] Stomping Ground +4 [THS:172] Polukranos, World Eater +1 [RTR:208] Vraska the Unseen +1 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +1 [BNG:156] Xenagos, God of Revels +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 2 [RTR:82] Ultimate Price +SB: 2 [RTR:101] Mizzium Mortars +SB: 2 [RTR:188] Rakdos's Return +SB: 1 [THS:153] Bow of Nylea +SB: 1 [DGM:99] Ruric Thar, the Unbowed +SB: 1 [M14:96] Doom Blade +SB: 3 [THS:162] Mistcutter Hydra +SB: 2 [RTR:164] Golgari Charm +SB: 1 [DGM:104] Sire of Insanity diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..e9d86f9ec82 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,29 @@ +3 [AVR:32] Restoration Angel +2 [AVR:172] Craterhoof Behemoth +3 [M13:229] Sunpetal Grove +3 [UNH:140] Forest +3 [RTR:1] Angel of Serenity +3 [RTR:178] Loxodon Smiter +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +3 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +3 [ISD:122] Unburial Rites +1 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +2 [RTR:213] Deathrite Shaman +3 [ISD:196] Mulch +3 [DKA:12] Lingering Souls +1 [ISD:239] Gavony Township +2 [GTC:242] Godless Shrine +4 [ISD:249] Woodland Cemetery +SB: 2 [M13:29] Rhox Faithmender +SB: 4 [C13:134] Acidic Slime +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 1 [AVR:226] Cavern of Souls +SB: 1 [RTR:213] Deathrite Shaman +SB: 2 [ISD:115] Sever the Bloodline +SB: 1 [RTR:208] Vraska the Unseen +SB: 2 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..6adab747402 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,30 @@ +3 [AVR:32] Restoration Angel +2 [C13:11] Fiend Hunter +1 [AVR:172] Craterhoof Behemoth +3 [M13:229] Sunpetal Grove +2 [UNH:140] Forest +4 [RTR:1] Angel of Serenity +2 [RTR:141] Abrupt Decay +3 [RTR:178] Loxodon Smiter +4 [RTR:243] Overgrown Tomb +2 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +1 [AVR:226] Cavern of Souls +1 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +3 [ISD:196] Mulch +1 [ISD:115] Sever the Bloodline +1 [ISD:239] Gavony Township +3 [GTC:242] Godless Shrine +4 [ISD:249] Woodland Cemetery +SB: 2 [C13:134] Acidic Slime +SB: 1 [GTC:182] Obzedat, Ghost Council +SB: 3 [AVR:194] Somberwald Sage +SB: 1 [AVR:226] Cavern of Souls +SB: 1 [DGM:72] Gaze of Granite +SB: 2 [RTR:206] Trostani, Selesnya's Voice +SB: 2 [ISD:96] Dead Weight +SB: 3 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..2fd620b73e8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,27 @@ +3 [AVR:32] Restoration Angel +2 [C13:11] Fiend Hunter +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +3 [RTR:1] Angel of Serenity +2 [RTR:141] Abrupt Decay +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +2 [DGM:57] Blood Baron of Vizkopa +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [M13:170] Farseek +4 [ISD:122] Unburial Rites +1 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +1 [RTR:148] Centaur Healer +3 [ISD:196] Mulch +1 [ISD:115] Sever the Bloodline +2 [GTC:242] Godless Shrine +3 [ISD:249] Woodland Cemetery +SB: 3 [C13:134] Acidic Slime +SB: 2 [RTR:213] Deathrite Shaman +SB: 2 [RTR:206] Trostani, Selesnya's Voice +SB: 2 [RTR:141] Abrupt Decay +SB: 2 [DGM:103] Sin Collector +SB: 4 [DGM:114] Voice of Resurgence diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..319f7f68c13 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,25 @@ +4 [AVR:32] Restoration Angel +2 [AVR:172] Craterhoof Behemoth +4 [M13:229] Sunpetal Grove +3 [UNH:140] Forest +3 [RTR:1] Angel of Serenity +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +3 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +2 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +4 [RTR:148] Centaur Healer +3 [ISD:196] Mulch +2 [DKA:12] Lingering Souls +1 [GTC:242] Godless Shrine +4 [ISD:249] Woodland Cemetery +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 4 [C13:134] Acidic Slime +SB: 2 [M13:29] Rhox Faithmender +SB: 2 [RTR:213] Deathrite Shaman +SB: 1 [ISD:115] Sever the Bloodline +SB: 4 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..f32379d5430 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk Reanimator TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,29 @@ +3 [AVR:32] Restoration Angel +2 [C13:11] Fiend Hunter +1 [AVR:172] Craterhoof Behemoth +3 [M13:229] Sunpetal Grove +3 [UNH:140] Forest +4 [RTR:1] Angel of Serenity +4 [RTR:243] Overgrown Tomb +2 [RTR:177] Lotleth Troll +2 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +1 [ISD:181] Garruk Relentless +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +2 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +3 [ISD:196] Mulch +2 [DKA:12] Lingering Souls +2 [ISD:239] Gavony Township +2 [GTC:242] Godless Shrine +4 [ISD:249] Woodland Cemetery +SB: 1 [DGM:111] Unflinching Courage +SB: 2 [C13:134] Acidic Slime +SB: 1 [ISD:181] Garruk Relentless +SB: 2 [DGM:5] Renounce the Guilds +SB: 1 [RTR:148] Centaur Healer +SB: 4 [RTR:213] Deathrite Shaman +SB: 1 [ISD:115] Sever the Bloodline +SB: 3 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Junk TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Junk TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..b4b7b3b16f0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Junk TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,25 @@ +3 [M13:229] Sunpetal Grove +4 [AVR:86] Blood Artist +3 [DKA:134] Young Wolf +4 [GTC:150] Cartel Aristocrat +4 [RTR:243] Overgrown Tomb +1 [GTC:182] Obzedat, Ghost Council +2 [ISD:181] Garruk Relentless +4 [C14:167] Tragic Slip +3 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +3 [C14:163] Skirsdag High Priest +4 [DKA:12] Lingering Souls +2 [ISD:239] Gavony Township +4 [GTC:242] Godless Shrine +3 [DGM:112] Varolz, the Scar-Striped +4 [ISD:249] Woodland Cemetery +4 [CNS:69] Doomed Traveler +4 [DGM:114] Voice of Resurgence +SB: 2 [DGM:111] Unflinching Courage +SB: 1 [GTC:182] Obzedat, Ghost Council +SB: 3 [RTR:213] Deathrite Shaman +SB: 2 [M14:97] Duress +SB: 2 [RTR:164] Golgari Charm +SB: 3 [RTR:141] Abrupt Decay +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Bant TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Bant TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..583f40b827f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Bant TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,31 @@ +4 [AVR:32] Restoration Angel +2 [M13:229] Sunpetal Grove +3 [C13:30] Augur of Bolas +1 [RTR:54] Syncopate +3 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +3 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +1 [RTR:155] Detention Sphere +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +3 [RTR:248] Temple Garden +1 [RTR:247] Steam Vents +4 [ISD:241] Hinterland Harbor +3 [RTR:148] Centaur Healer +1 [GTC:247] Stomping Ground +2 [M15:51] Dissipate +1 [GTC:245] Sacred Foundry +2 [ISD:83] Think Twice +4 [GTC:240] Breeding Pool +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [RTR:155] Detention Sphere +SB: 3 [M13:29] Rhox Faithmender +SB: 1 [AVR:209] Gisela, Blade of Goldnight +SB: 2 [ISD:181] Garruk Relentless +SB: 1 [RTR:148] Centaur Healer +SB: 2 [ISD:236] Witchbane Orb +SB: 2 [RTR:18] Rest in Peace +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..02391602d2e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,28 @@ +4 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +6 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +5 [UNH:139] Mountain +3 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [C14:184] Whipflare +4 [MBS:145] Inkmoth Nexus +2 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +4 [SOM:91] Galvanic Blast +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [SOM:175] Mimic Vat +SB: 2 [NPH:74] Surgical Extraction +SB: 2 [KTK:142] Naturalize +SB: 2 [DKA:107] Wrack with Madness +SB: 1 [C14:184] Whipflare +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [ISD:127] Ancient Grudge +SB: 2 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..88c503ed749 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,26 @@ +3 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +4 [C13:114] Inferno Titan +2 [ISD:140] Devil's Play +1 [M14:155] Shock +3 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [SOM:91] Galvanic Blast +SB: 1 [MBS:75] Slagstorm +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [ISD:207] Tree of Redemption +SB: 1 [NPH:103] Beast Within +SB: 4 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..556549e5acf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,28 @@ +4 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +2 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [C14:184] Whipflare +4 [MBS:145] Inkmoth Nexus +3 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +4 [SOM:91] Galvanic Blast +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 2 [KTK:142] Naturalize +SB: 1 [M12:128] Combust +SB: 1 [C14:184] Whipflare +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [NPH:103] Beast Within +SB: 1 [M12:164] Autumn's Veil +SB: 2 [NPH:1] Karn Liberated +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..3900c13d23f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,27 @@ +4 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +3 [C13:114] Inferno Titan +2 [ISD:140] Devil's Play +3 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [C14:283] Wurmcoil Engine +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [SOM:91] Galvanic Blast +SB: 2 [C13:134] Acidic Slime +SB: 2 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [NPH:130] Batterskull +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 1 [SOM:104] Spikeshot Elder +SB: 1 [NPH:103] Beast Within +SB: 3 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..242dabfdaaf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,28 @@ +4 [MBS:75] Slagstorm +4 [UNH:140] Forest +4 [M13:228] Rootbound Crag +4 [M12:188] Primeval Titan +3 [NPH:103] Beast Within +3 [UNH:139] Mountain +4 [C13:114] Inferno Titan +2 [ISD:140] Devil's Play +1 [ISD:243] Kessig Wolf Run +4 [AVR:226] Cavern of Souls +4 [M12:190] Rampant Growth +1 [C14:184] Whipflare +2 [MBS:145] Inkmoth Nexus +4 [SOM:227] Glimmerpost +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 1 [ISD:243] Kessig Wolf Run +SB: 2 [M12:128] Combust +SB: 2 [MBS:74] Red Sun's Zenith +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [NPH:103] Beast Within +SB: 1 [M13:123] Chandra, the Firebrand +SB: 2 [SOM:222] Wall of Tanglecord +SB: 2 [DKA:110] Crushing Vines +SB: 2 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..2f3a4fffd2c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,28 @@ +3 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +10 [UNH:140] Forest +1 [M12:146] Incinerate +4 [MBS:81] Green Sun's Zenith +4 [M12:165] Birds of Paradise +4 [C14:204] Llanowar Elves +3 [UNH:139] Mountain +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +2 [NPH:42] Phyrexian Metamorph +4 [DKA:127] Strangleroot Geist +2 [DKA:93] Hellrider +1 [MBS:138] Sword of Feast and Famine +3 [AVR:205] Wolfir Avenger +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +4 [SOM:91] Galvanic Blast +SB: 1 [NPH:107] Corrosive Gale +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [M12:150] Manabarbs +SB: 2 [KTK:142] Naturalize +SB: 1 [ISD:176] Daybreak Ranger +SB: 2 [NPH:78] Act of Aggression +SB: 1 [AVR:166] Zealous Conscripts +SB: 3 [SOM:81] Arc Trail +SB: 1 [DKA:120] Increasing Savagery +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..88c503ed749 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,26 @@ +3 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +4 [C13:114] Inferno Titan +2 [ISD:140] Devil's Play +1 [M14:155] Shock +3 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [SOM:91] Galvanic Blast +SB: 1 [MBS:75] Slagstorm +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [ISD:207] Tree of Redemption +SB: 1 [NPH:103] Beast Within +SB: 4 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..11ea4f3ed56 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig Titan TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,25 @@ +3 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +9 [UNH:140] Forest +4 [MBS:95] Viridian Emissary +4 [MBS:81] Green Sun's Zenith +3 [M12:188] Primeval Titan +4 [NPH:103] Beast Within +1 [M12:165] Birds of Paradise +3 [UNH:139] Mountain +4 [M13:174] Garruk, Primal Hunter +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +3 [C14:283] Wurmcoil Engine +4 [MBS:145] Inkmoth Nexus +3 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +SB: 1 [MBS:75] Slagstorm +SB: 1 [MBS:94] Viridian Corrupter +SB: 3 [MBS:138] Sword of Feast and Famine +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [ISD:207] Tree of Redemption +SB: 1 [NPH:159] Spellskite +SB: 4 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kessig U TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kessig U TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..29b0c891699 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kessig U TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,28 @@ +5 [UNH:140] Forest +4 [AVR:81] Temporal Mastery +4 [M12:188] Primeval Titan +1 [UNH:139] Mountain +2 [ISD:78] Snapcaster Mage +2 [C14:112] Frost Titan +2 [M13:193] Thragtusk +1 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +2 [AVR:226] Cavern of Souls +4 [M12:190] Rampant Growth +4 [ISD:241] Hinterland Harbor +4 [AVR:129] Bonfire of the Damned +1 [MBS:145] Inkmoth Nexus +4 [SOM:227] Glimmerpost +2 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +2 [M12:72] Phantasmal Image +4 [UNH:137] Island +4 [M12:73] Ponder +SB: 2 [M13:193] Thragtusk +SB: 2 [AVR:226] Cavern of Souls +SB: 1 [M12:128] Combust +SB: 2 [C14:184] Whipflare +SB: 2 [NPH:103] Beast Within +SB: 2 [DKA:110] Crushing Vines +SB: 2 [NPH:1] Karn Liberated +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kozilek Caw-Blade TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kozilek Caw-Blade TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..7d67c0a5fff --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kozilek Caw-Blade TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,28 @@ +3 [MBS:43] Go for the Throat +1 [NPH:161] Sword of War and Peace +4 [WWK:134] Creeping Tar Pit +3 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +2 [ZEN:211] Arid Mesa +4 [ROE:115] Inquisition of Kozilek +2 [KTK:69] Despise +1 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [ZEN:219] Marsh Flats +1 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +2 [ZEN:11] Emeria Angel +4 [M11:33] Squadron Hawk +4 [SOM:226] Darkslick Shores +4 [WWK:20] Stoneforge Mystic +4 [WWK:31] Jace, the Mind Sculptor +4 [UNH:136] Plains +2 [UNH:138] Swamp +2 [M12:63] Mana Leak +SB: 2 [MBS:5] Divine Offering +SB: 2 [ZEN:11] Emeria Angel +SB: 2 [NPH:130] Batterskull +SB: 1 [M14:97] Duress +SB: 3 [ROE:40] Oust +SB: 3 [NPH:159] Spellskite +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Kuldotha Red TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Kuldotha Red TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..09c1d144168 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Kuldotha Red TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,20 @@ +4 [SOM:174] Memnite +3 [SOM:141] Chimeric Mass +2 [ROE:140] Devastating Summons +16 [UNH:139] Mountain +4 [M15:223] Ornithopter +4 [ZEN:125] Goblin Bushwhacker +4 [ZEN:126] Goblin Guide +4 [MBS:107] Flayer Husk +4 [SOM:96] Kuldotha Rebirth +4 [MBS:131] Signal Pest +3 [SOM:179] Mox Opal +4 [MBS:144] Contested War Zone +4 [SOM:91] Galvanic Blast +SB: 3 [M13:141] Mark of Mutiny +SB: 4 [M11:208] Jinxed Idol +SB: 1 [M15:225] Phyrexian Revoker +SB: 1 [ZEN:226] Teetering Peaks +SB: 1 [C14:183] Tuktuk the Explorer +SB: 3 [SOM:81] Arc Trail +SB: 2 [ROE:146] Forked Bolt diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..77253da0835 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,48 @@ +3 [ONS:313] Bloodstained Mire +1 [THS:127] Lightning Strike +1 [7ED:339] Mountain +1 [INV:343] Mountain +1 [ZEN:263] Mountain +1 [APC:140] Caves of Koilos +3 [KTK:22] Seeker of the Way +1 [THS:227] Temple of Silence +1 [KTK:202] Sorin, Solemn Visitor +4 [THS:228] Temple of Triumph +4 [KTK:168] Butcher of the Horde +1 [M14:132] Chandra, Pyromaster +2 [M15:145] Goblin Rabblemaster +1 [APC:139] Battlefield Forge +1 [DDL:22] Magma Jet +3 [THS:4] Chained to the Rocks +1 [10E:348] Battlefield Forge +1 [PO2:157] Mountain +1 [SOM:238] Swamp +1 [DDO:1] Elspeth, Sun's Champion +1 [JR:43] Bloodstained Mire +2 [MBP:98] Goblin Rabblemaster +1 [KTK:31] Wingmate Roc +2 [KTK:97] Arc Lightning +1 [9ED:320] Caves of Koilos +2 [KTK:119] Sarkhan, the Dragonspeaker +2 [KTK:237] Nomad Outpost +1 [M12:243] Mountain +2 [M15:155] Lightning Strike +2 [DDN:34] Nomad Outpost +4 [KTK:111] Hordeling Outburst +1 [9ED:318] Battlefield Forge +1 [KTK:81] Murderous Cut +4 [KTK:171] Crackling Doom +1 [TPR:262] Mountain +SB: 1 [ULG:7] Erase +SB: 1 [THS:15] Glare of Heresy +SB: 1 [MBP:75] Chandra, Pyromaster +SB: 2 [THS:112] Anger of the Gods +SB: 1 [THS:101] Read the Bones +SB: 1 [KTK:104] Burn Away +SB: 1 [THS:107] Thoughtseize +SB: 1 [C14:158] Read the Bones +SB: 1 [KTK:186] Mardu Charm +SB: 1 [MGDC:38] Utter End +SB: 1 [KTK:9] Erase +SB: 2 [KTK:8] End Hostilities +SB: 1 [THS:9] Elspeth, Sun's Champion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..c02752c3ca5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Control TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,26 @@ +3 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:237] Nomad Outpost +3 [KTK:22] Seeker of the Way +2 [THS:227] Temple of Silence +2 [KTK:202] Sorin, Solemn Visitor +2 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +3 [THS:228] Temple of Triumph +2 [M15:241] Caves of Koilos +4 [KTK:168] Butcher of the Horde +6 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +3 [THS:4] Chained to the Rocks +4 [KTK:230] Bloodstained Mire +1 [KTK:81] Murderous Cut +4 [KTK:171] Crackling Doom +1 [THS:9] Elspeth, Sun's Champion +1 [UNH:138] Swamp +SB: 2 [KTK:210] Utter End +SB: 2 [M15:134] Chandra, Pyromaster +SB: 2 [THS:15] Glare of Heresy +SB: 3 [KTK:8] End Hostilities +SB: 3 [THS:112] Anger of the Gods +SB: 3 [M15:164] Stoke the Flames diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..8b4efaf503e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,29 @@ +2 [KTK:31] Wingmate Roc +2 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:237] Nomad Outpost +3 [KTK:22] Seeker of the Way +2 [THS:227] Temple of Silence +2 [KTK:202] Sorin, Solemn Visitor +3 [M15:240] Battlefield Forge +4 [THS:228] Temple of Triumph +2 [M15:241] Caves of Koilos +4 [KTK:168] Butcher of the Horde +5 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +1 [KTK:210] Utter End +4 [KTK:111] Hordeling Outburst +3 [THS:4] Chained to the Rocks +4 [KTK:230] Bloodstained Mire +1 [KTK:81] Murderous Cut +4 [KTK:171] Crackling Doom +1 [THS:9] Elspeth, Sun's Champion +1 [UNH:138] Swamp +SB: 1 [KTK:210] Utter End +SB: 2 [C14:158] Read the Bones +SB: 3 [M15:15] Hushwing Gryff +SB: 1 [THS:15] Glare of Heresy +SB: 1 [KTK:9] Erase +SB: 1 [KTK:8] End Hostilities +SB: 3 [THS:112] Anger of the Gods +SB: 3 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Oct 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Oct 2014.mwDeck.dck new file mode 100644 index 00000000000..601d07e4c31 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mardu Midrange TDtB ST Oct 2014.mwDeck.dck @@ -0,0 +1,32 @@ +3 [BNG:5] Brimaz, King of Oreskos +3 [THS:143] Stormbreath Dragon +2 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:237] Nomad Outpost +2 [THS:227] Temple of Silence +2 [KTK:202] Sorin, Solemn Visitor +2 [M15:240] Battlefield Forge +2 [THS:228] Temple of Triumph +4 [THS:107] Thoughtseize +4 [M15:241] Caves of Koilos +2 [M15:164] Stoke the Flames +4 [KTK:168] Butcher of the Horde +2 [UNH:139] Mountain +3 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [KTK:230] Bloodstained Mire +1 [KTK:81] Murderous Cut +3 [THS:90] Hero's Downfall +4 [KTK:171] Crackling Doom +2 [BNG:164] Temple of Malice +1 [JOU:163] Mana Confluence +2 [UNH:138] Swamp +SB: 2 [JOU:18] Nyx-Fleece Ram +SB: 1 [KTK:210] Utter End +SB: 2 [JOU:103] Magma Spray +SB: 1 [KTK:72] Empty the Pits +SB: 1 [JOU:100] Harness by Force +SB: 3 [THS:112] Anger of the Gods +SB: 1 [KTK:31] Wingmate Roc +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 2 [KTK:69] Despise +SB: 1 [KTK:25] Suspension Field diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Aggro TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Aggro TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..8f2be967420 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Aggro TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,20 @@ +1 [RTR:82] Ultimate Price +4 [RTR:73] Pack Rat +4 [THS:107] Thoughtseize +4 [THS:108] Tormented Hero +3 [BNG:61] Bile Blight +3 [M14:101] Lifebane Zombie +4 [RTR:220] Rakdos Cackler +3 [BNG:80] Pain Seer +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +2 [THS:97] Mogis's Marauder +20 [UNH:138] Swamp +4 [BNG:75] Herald of Torment +SB: 1 [THS:110] Whip of Erebos +SB: 2 [RTR:63] Desecration Demon +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 3 [THS:83] Dark Betrayal +SB: 2 [GTC:63] Devour Flesh +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..a97fed56249 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,26 @@ +2 [MBS:43] Go for the Throat +2 [M12:109] Sorin Markov +4 [C13:97] Vampire Nighthawk +1 [M12:111] Sorin's Vengeance +2 [NPH:1] Karn Liberated +3 [C14:136] Black Sun's Zenith +2 [C14:145] Grave Titan +1 [NPH:74] Surgical Extraction +2 [NPH:42] Phyrexian Metamorph +4 [C14:264] Pristine Talisman +1 [NPH:57] Dismember +1 [ISD:115] Sever the Bloodline +1 [M14:96] Doom Blade +3 [C14:150] Mutilate +4 [C14:161] Sign in Blood +3 [M14:97] Duress +2 [ISD:94] Curse of Death's Hold +23 [UNH:138] Swamp +SB: 1 [NPH:74] Surgical Extraction +SB: 3 [DKA:149] Grafdigger's Cage +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [ISD:115] Sever the Bloodline +SB: 2 [ISD:90] Bloodline Keeper +SB: 2 [C13:249] Nihil Spellbomb +SB: 1 [NPH:137] Hex Parasite +SB: 3 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..bb087ddf3bd --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Control TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,18 @@ +1 [MBS:43] Go for the Throat +4 [C13:97] Vampire Nighthawk +4 [ROE:115] Inquisition of Kozilek +4 [ZEN:89] Gatekeeper of Malakir +4 [C14:245] Lashwrithe +2 [M15:103] Liliana Vess +4 [NPH:68] Phyrexian Obliterator +2 [NPH:57] Dismember +2 [M14:96] Doom Blade +4 [C14:161] Sign in Blood +4 [M14:97] Duress +1 [M14:91] Corrupt +24 [UNH:138] Swamp +SB: 4 [SOM:69] Memoricide +SB: 4 [MBS:50] Phyrexian Crusader +SB: 2 [M14:96] Doom Blade +SB: 4 [ZEN:83] Bloodghast +SB: 1 [NPH:130] Batterskull diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Infect TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Infect TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..68a90eabb8c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mono Black Infect TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,24 @@ +2 [SOM:79] Skithiryx, the Blight Dragon +4 [MBS:50] Phyrexian Crusader +3 [C13:249] Nihil Spellbomb +4 [C14:245] Lashwrithe +2 [NPH:77] Whispering Specter +1 [SOM:218] Tumble Magnet +2 [NPH:57] Dismember +4 [MBS:145] Inkmoth Nexus +4 [SOM:75] Plague Stinger +2 [M14:96] Doom Blade +2 [NPH:47] Tezzeret's Gambit +2 [MBS:57] Virulent Wound +2 [M12:94] Distress +21 [UNH:138] Swamp +3 [ISD:105] Liliana of the Veil +2 [SOM:144] Contagion Clasp +SB: 2 [C14:136] Black Sun's Zenith +SB: 2 [NPH:77] Whispering Specter +SB: 3 [MBS:52] Phyrexian Vatmother +SB: 1 [M14:96] Doom Blade +SB: 2 [MBS:57] Virulent Wound +SB: 2 [M12:94] Distress +SB: 1 [C13:249] Nihil Spellbomb +SB: 2 [NPH:159] Spellskite diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Mono Green Infect TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Mono Green Infect TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..97005651c11 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Mono Green Infect TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,22 @@ +1 [MBS:94] Viridian Corrupter +13 [UNH:140] Forest +4 [NPH:2] Apostle's Blessing +4 [NPH:111] Glistener Elf +2 [MBS:81] Green Sun's Zenith +4 [M13:221] Cathedral of War +4 [M13:185] Rancor +4 [NPH:116] Mutagenic Growth +4 [AVR:203] Wild Defiance +4 [NPH:86] Gut Shot +4 [M15:203] Titanic Growth +4 [MBS:145] Inkmoth Nexus +3 [NPH:38] Mental Misstep +1 [SOM:112] Blight Mamba +4 [SOM:166] Ichorclaw Myr +SB: 3 [MBS:94] Viridian Corrupter +SB: 4 [NPH:57] Dismember +SB: 1 [NPH:38] Mental Misstep +SB: 2 [NPH:103] Beast Within +SB: 1 [NPH:115] Melira, Sylvok Outcast +SB: 3 [NPH:159] Spellskite +SB: 1 [SOM:112] Blight Mamba diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..ec8c5863ea0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,23 @@ +3 [THS:224] Temple of Abandon +2 [M14:1] Ajani, Caller of the Pride +4 [GTC:119] Experiment One +2 [UNH:140] Forest +1 [THS:228] Temple of Triumph +4 [C13:179] Boros Charm +4 [C13:211] Selesnya Charm +4 [M14:202] Witchstalker +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +4 [THS:193] Fleecemane Lion +4 [BNG:165] Temple of Plenty +3 [DGM:51] Advent of the Wurm +4 [GTC:245] Sacred Foundry +4 [GTC:167] Ghor-Clan Rampager +1 [GTC:98] Madcap Skills +3 [THS:152] Boon Satyr +1 [UNH:136] Plains +4 [DGM:114] Voice of Resurgence +SB: 4 [DGM:49] Skylasher +SB: 4 [DGM:111] Unflinching Courage +SB: 3 [GTC:98] Madcap Skills +SB: 4 [RTR:9] Ethereal Armor diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..7fa129f9df3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,23 @@ +4 [AVR:32] Restoration Angel +4 [UNH:140] Forest +4 [M13:228] Rootbound Crag +3 [UNH:139] Mountain +4 [RTR:178] Loxodon Smiter +4 [M13:150] Thundermaw Hellkite +4 [C13:211] Selesnya Charm +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +4 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +4 [AVR:129] Bonfire of the Damned +4 [DKA:140] Huntmaster of the Fells +3 [ISD:238] Clifftop Retreat +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 1 [DKA:17] Ray of Revelation +SB: 2 [ISD:181] Garruk Relentless +SB: 4 [AVR:149] Pillar of Flame +SB: 2 [RTR:1] Angel of Serenity +SB: 2 [AVR:210] Sigarda, Host of Herons +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..d794aa0a0cd --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aggro TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,33 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +3 [UNH:140] Forest +3 [GTC:215] Boros Reckoner +1 [THS:209] Xenagos, the Reveler +2 [THS:228] Temple of Triumph +1 [M14:195] Scavenging Ooze +1 [UNH:139] Mountain +3 [RTR:178] Loxodon Smiter +1 [M15:134] Chandra, Pyromaster +1 [RTR:101] Mizzium Mortars +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +4 [THS:193] Fleecemane Lion +1 [THS:172] Polukranos, World Eater +4 [GTC:245] Sacred Foundry +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +2 [UNH:136] Plains +1 [THS:180] Sylvan Caryatid +4 [DGM:114] Voice of Resurgence +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [M14:155] Shock +SB: 2 [C13:179] Boros Charm +SB: 3 [DGM:111] Unflinching Courage +SB: 1 [C13:211] Selesnya Charm +SB: 2 [THS:15] Glare of Heresy +SB: 1 [RTR:231] Pithing Needle +SB: 1 [GTC:169] Gruul Charm +SB: 1 [THS:150] Arbor Colossus +SB: 1 [DGM:135] Wear // Tear +SB: 1 [M14:195] Scavenging Ooze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..ea1b95c2576 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,25 @@ +2 [M14:1] Ajani, Caller of the Pride +2 [BNG:7] Eidolon of Countless Battles +2 [M14:18] Fiendslayer Paladin +4 [UNH:140] Forest +2 [BNG:27] Spirit of the Labyrinth +1 [THS:228] Temple of Triumph +4 [RTR:9] Ethereal Armor +4 [M14:176] Gladecover Scout +4 [C13:179] Boros Charm +4 [THS:4] Chained to the Rocks +4 [DGM:111] Unflinching Courage +2 [C13:211] Selesnya Charm +4 [M14:202] Witchstalker +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +4 [BNG:165] Temple of Plenty +4 [GTC:245] Sacred Foundry +4 [GTC:98] Madcap Skills +1 [UNH:136] Plains +SB: 4 [DGM:49] Skylasher +SB: 2 [C13:211] Selesnya Charm +SB: 3 [GTC:219] Gift of Orzhova +SB: 3 [DGM:44] Mending Touch +SB: 2 [BNG:27] Spirit of the Labyrinth +SB: 1 [BNG:25] Revoke Existence diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..9f495c8c1a4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Aura TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,24 @@ +4 [JOU:117] Bassara Tower Archer +2 [THS:224] Temple of Abandon +1 [UNH:140] Forest +4 [RTR:9] Ethereal Armor +4 [M14:176] Gladecover Scout +4 [C13:179] Boros Charm +4 [DGM:111] Unflinching Courage +4 [M14:202] Witchstalker +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +2 [THS:193] Fleecemane Lion +4 [JOU:163] Mana Confluence +4 [BNG:165] Temple of Plenty +4 [GTC:245] Sacred Foundry +4 [GTC:167] Ghor-Clan Rampager +4 [GTC:98] Madcap Skills +3 [THS:152] Boon Satyr +SB: 2 [DGM:49] Skylasher +SB: 2 [C13:211] Selesnya Charm +SB: 2 [THS:4] Chained to the Rocks +SB: 2 [JOU:5] Banishing Light +SB: 3 [GTC:106] Skullcrack +SB: 2 [DGM:135] Wear // Tear +SB: 2 [M14:195] Scavenging Ooze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Blitz TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Blitz TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..ead1e4e5b8c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Blitz TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,24 @@ +4 [GTC:7] Boros Elite +2 [M13:229] Sunpetal Grove +4 [GTC:119] Experiment One +1 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [M13:147] Searing Spear +4 [ISD:193] Mayor of Avabruck +4 [M13:171] Flinthoof Boar +4 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +4 [GTC:12] Frontline Medic +4 [AVR:144] Lightning Mauler +4 [GTC:245] Sacred Foundry +1 [GTC:167] Ghor-Clan Rampager +3 [DKA:24] Thalia, Guardian of Thraben +1 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +SB: 4 [C13:179] Boros Charm +SB: 2 [C13:11] Fiend Hunter +SB: 3 [M14:25] Pacifism +SB: 2 [GTC:215] Boros Reckoner +SB: 2 [AVR:31] Nearheath Pilgrim +SB: 2 [M14:139] Flames of the Firebrand diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..de642397811 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,24 @@ +4 [GTC:7] Boros Elite +2 [M13:229] Sunpetal Grove +4 [GTC:119] Experiment One +1 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [M13:147] Searing Spear +4 [ISD:193] Mayor of Avabruck +4 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +4 [ISD:187] Hamlet Captain +4 [GTC:247] Stomping Ground +4 [GTC:12] Frontline Medic +4 [AVR:144] Lightning Mauler +4 [GTC:245] Sacred Foundry +1 [GTC:167] Ghor-Clan Rampager +3 [DKA:24] Thalia, Guardian of Thraben +1 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +SB: 2 [RTR:93] Electrickery +SB: 3 [C13:179] Boros Charm +SB: 2 [C13:11] Fiend Hunter +SB: 3 [C14:278] Tormod's Crypt +SB: 2 [M14:25] Pacifism +SB: 3 [GTC:106] Skullcrack diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..e0dbe60f93a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Human TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,25 @@ +4 [GTC:7] Boros Elite +4 [GTC:119] Experiment One +2 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +1 [ISD:34] Spare from Evil +2 [C13:179] Boros Charm +4 [ISD:193] Mayor of Avabruck +4 [M13:171] Flinthoof Boar +4 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +4 [GTC:247] Stomping Ground +4 [GTC:12] Frontline Medic +4 [AVR:144] Lightning Mauler +4 [GTC:245] Sacred Foundry +2 [GTC:167] Ghor-Clan Rampager +3 [DKA:24] Thalia, Guardian of Thraben +2 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +SB: 1 [ISD:34] Spare from Evil +SB: 3 [M13:141] Mark of Mutiny +SB: 1 [C13:179] Boros Charm +SB: 3 [C14:278] Tormod's Crypt +SB: 2 [C13:11] Fiend Hunter +SB: 2 [DGM:111] Unflinching Courage +SB: 3 [AVR:149] Pillar of Flame diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Humans TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Humans TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..877132184be --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Humans TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,26 @@ +4 [AVR:32] Restoration Angel +3 [UNH:140] Forest +3 [C14:72] Geist-Honored Monk +4 [NPH:4] Blade Splicer +4 [M12:165] Birds of Paradise +2 [UNH:139] Mountain +4 [ISD:170] Avacyn's Pilgrim +3 [DKA:127] Strangleroot Geist +4 [AVR:226] Cavern of Souls +4 [AVR:129] Bonfire of the Damned +4 [SOM:228] Razorverge Thicket +4 [SOM:225] Copperline Gorge +4 [AVR:169] Borderland Ranger +4 [DKA:140] Huntmaster of the Fells +2 [UNH:136] Plains +4 [ISD:239] Gavony Township +3 [DKA:24] Thalia, Guardian of Thraben +SB: 2 [M12:128] Combust +SB: 2 [AVR:206] Wolfir Silverheart +SB: 3 [AVR:166] Zealous Conscripts +SB: 1 [M15:192] Plummet +SB: 2 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 1 [DKA:110] Crushing Vines +SB: 2 [MBS:8] Hero of Bladehold +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Midrange TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Midrange TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..45a6b087871 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Midrange TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,24 @@ +3 [AVR:32] Restoration Angel +3 [M13:229] Sunpetal Grove +4 [M13:228] Rootbound Crag +4 [GTC:215] Boros Reckoner +4 [RTR:178] Loxodon Smiter +4 [M13:150] Thundermaw Hellkite +2 [C13:211] Selesnya Charm +4 [ISD:170] Avacyn's Pilgrim +4 [RTR:248] Temple Garden +3 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [GTC:245] Sacred Foundry +4 [GTC:156] Domri Rade +4 [DKA:140] Huntmaster of the Fells +2 [ISD:239] Gavony Township +3 [ISD:238] Clifftop Retreat +4 [DGM:114] Voice of Resurgence +SB: 3 [C13:179] Boros Charm +SB: 2 [DKA:17] Ray of Revelation +SB: 2 [DGM:111] Unflinching Courage +SB: 2 [AVR:149] Pillar of Flame +SB: 2 [AVR:166] Zealous Conscripts +SB: 2 [M13:22] Oblivion Ring +SB: 2 [DKA:7] Faith's Shield diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..3998b644a44 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,34 @@ +1 [C13:11] Fiend Hunter +3 [M13:229] Sunpetal Grove +3 [M13:228] Rootbound Crag +6 [UNH:140] Forest +1 [C14:72] Geist-Honored Monk +4 [NPH:4] Blade Splicer +4 [NPH:104] Birthing Pod +1 [C14:204] Llanowar Elves +1 [UNH:139] Mountain +1 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +4 [DKA:127] Strangleroot Geist +1 [NPH:9] Elesh Norn, Grand Cenobite +1 [C14:283] Wurmcoil Engine +3 [DKA:140] Huntmaster of the Fells +1 [UNH:136] Plains +4 [M12:165] Birds of Paradise +3 [ISD:170] Avacyn's Pilgrim +1 [NPH:42] Phyrexian Metamorph +2 [ISD:176] Daybreak Ranger +4 [SOM:228] Razorverge Thicket +1 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +2 [M13:22] Oblivion Ring +2 [ISD:239] Gavony Township +1 [MBS:8] Hero of Bladehold +SB: 3 [M12:150] Manabarbs +SB: 1 [NPH:42] Phyrexian Metamorph +SB: 2 [ISD:176] Daybreak Ranger +SB: 2 [NPH:78] Act of Aggression +SB: 3 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [MBS:8] Hero of Bladehold diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..d0f052dc40c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,34 @@ +4 [AVR:32] Restoration Angel +1 [M13:229] Sunpetal Grove +1 [M13:228] Rootbound Crag +5 [UNH:140] Forest +4 [NPH:4] Blade Splicer +4 [M12:165] Birds of Paradise +3 [NPH:104] Birthing Pod +1 [UNH:139] Mountain +1 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +1 [M13:193] Thragtusk +4 [ISD:170] Avacyn's Pilgrim +1 [NPH:42] Phyrexian Metamorph +4 [AVR:226] Cavern of Souls +1 [AVR:206] Wolfir Silverheart +3 [AVR:129] Bonfire of the Damned +4 [SOM:228] Razorverge Thicket +1 [AVR:166] Zealous Conscripts +3 [C14:193] Elvish Visionary +4 [SOM:225] Copperline Gorge +2 [DKA:140] Huntmaster of the Fells +3 [AVR:169] Borderland Ranger +1 [UNH:136] Plains +3 [ISD:239] Gavony Township +SB: 1 [M13:193] Thragtusk +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [AVR:166] Zealous Conscripts +SB: 2 [M12:11] Celestial Purge +SB: 2 [SOM:81] Arc Trail +SB: 1 [NPH:115] Melira, Sylvok Outcast +SB: 1 [NPH:159] Spellskite +SB: 1 [M12:197] Stingerfling Spider +SB: 2 [DKA:110] Crushing Vines +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..6978cca83b1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,36 @@ +1 [C13:11] Fiend Hunter +3 [M13:229] Sunpetal Grove +2 [M13:228] Rootbound Crag +6 [UNH:140] Forest +1 [C14:72] Geist-Honored Monk +4 [NPH:4] Blade Splicer +4 [NPH:104] Birthing Pod +1 [C14:204] Llanowar Elves +1 [UNH:139] Mountain +1 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +4 [DKA:127] Strangleroot Geist +1 [NPH:9] Elesh Norn, Grand Cenobite +1 [C14:283] Wurmcoil Engine +2 [MBS:115] Mortarpod +4 [DKA:140] Huntmaster of the Fells +1 [UNH:136] Plains +1 [MBS:95] Viridian Emissary +4 [M12:165] Birds of Paradise +3 [ISD:170] Avacyn's Pilgrim +4 [SOM:228] Razorverge Thicket +1 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +2 [M13:22] Oblivion Ring +3 [ISD:239] Gavony Township +SB: 1 [DKA:17] Ray of Revelation +SB: 1 [C13:134] Acidic Slime +SB: 1 [NPH:42] Phyrexian Metamorph +SB: 1 [NPH:97] Tormentor Exarch +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [M13:22] Oblivion Ring +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 3 [NPH:38] Mental Misstep +SB: 2 [MBS:8] Hero of Bladehold +SB: 1 [M12:164] Autumn's Veil +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..bc7638937a5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Pod TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,32 @@ +2 [M13:229] Sunpetal Grove +3 [M13:228] Rootbound Crag +8 [UNH:140] Forest +4 [NPH:4] Blade Splicer +4 [MBS:81] Green Sun's Zenith +1 [M12:188] Primeval Titan +1 [NPH:90] Priest of Urabrask +4 [M12:165] Birds of Paradise +4 [NPH:104] Birthing Pod +2 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:170] Avacyn's Pilgrim +1 [ISD:243] Kessig Wolf Run +1 [NPH:42] Phyrexian Metamorph +4 [DKA:127] Strangleroot Geist +1 [DKA:93] Hellrider +1 [MBS:138] Sword of Feast and Famine +4 [SOM:228] Razorverge Thicket +2 [AVR:166] Zealous Conscripts +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +2 [ISD:239] Gavony Township +SB: 1 [DKA:17] Ray of Revelation +SB: 1 [NPH:42] Phyrexian Metamorph +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [AVR:149] Pillar of Flame +SB: 1 [C14:175] Faithless Looting +SB: 1 [MBS:145] Inkmoth Nexus +SB: 2 [M12:11] Celestial Purge +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 3 [M13:22] Oblivion Ring +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya Podlight TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya Podlight TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..35bd1444f5d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya Podlight TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,37 @@ +1 [C13:11] Fiend Hunter +2 [M13:229] Sunpetal Grove +2 [M13:228] Rootbound Crag +4 [UNH:140] Forest +4 [NPH:4] Blade Splicer +2 [NPH:104] Birthing Pod +1 [UNH:139] Mountain +1 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:181] Garruk Relentless +2 [DKA:127] Strangleroot Geist +2 [AVR:226] Cavern of Souls +1 [AVR:206] Wolfir Silverheart +1 [AVR:166] Zealous Conscripts +1 [AVR:200] Ulvenwald Tracker +1 [AVR:169] Borderland Ranger +3 [DKA:140] Huntmaster of the Fells +2 [UNH:136] Plains +4 [AVR:32] Restoration Angel +4 [M12:165] Birds of Paradise +3 [ISD:170] Avacyn's Pilgrim +2 [NPH:42] Phyrexian Metamorph +4 [SOM:228] Razorverge Thicket +4 [SOM:225] Copperline Gorge +3 [ISD:239] Gavony Township +3 [DKA:24] Thalia, Guardian of Thraben +SB: 2 [NPH:161] Sword of War and Peace +SB: 1 [ISD:176] Daybreak Ranger +SB: 3 [AVR:129] Bonfire of the Damned +SB: 1 [AVR:166] Zealous Conscripts +SB: 1 [AVR:200] Ulvenwald Tracker +SB: 1 [DKA:140] Huntmaster of the Fells +SB: 2 [M13:22] Oblivion Ring +SB: 1 [DKA:110] Crushing Vines +SB: 1 [M12:197] Stingerfling Spider +SB: 1 [MBS:8] Hero of Bladehold +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Naya TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Naya TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..4a1b2cb2f4f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Naya TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,28 @@ +4 [AVR:32] Restoration Angel +4 [M13:229] Sunpetal Grove +3 [UNH:140] Forest +4 [M13:228] Rootbound Crag +3 [RTR:1] Angel of Serenity +1 [UNH:139] Mountain +2 [M13:174] Garruk, Primal Hunter +2 [RTR:178] Loxodon Smiter +3 [C13:211] Selesnya Charm +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +4 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +3 [AVR:129] Bonfire of the Damned +3 [AVR:169] Borderland Ranger +4 [DKA:140] Huntmaster of the Fells +2 [UNH:136] Plains +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 1 [DKA:17] Ray of Revelation +SB: 2 [RTR:178] Loxodon Smiter +SB: 1 [AVR:129] Bonfire of the Damned +SB: 1 [AVR:210] Sigarda, Host of Herons +SB: 2 [AVR:166] Zealous Conscripts +SB: 2 [M13:22] Oblivion Ring +SB: 3 [RTR:18] Rest in Peace +SB: 2 [AVR:198] Triumph of Ferocity diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..358bddefadb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,28 @@ +3 [RTR:83] Underworld Connections +1 [THS:110] Whip of Erebos +4 [RTR:73] Pack Rat +3 [RTR:63] Desecration Demon +2 [JOU:5] Banishing Light +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [M15:241] Caves of Koilos +3 [BNG:61] Bile Blight +3 [GTC:182] Obzedat, Ghost Council +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [GTC:222] Nightveil Specter +3 [GTC:63] Devour Flesh +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +2 [BNG:163] Temple of Enlightenment +7 [UNH:138] Swamp +SB: 1 [RTR:83] Underworld Connections +SB: 1 [THS:110] Whip of Erebos +SB: 2 [M14:5] Archangel of Thune +SB: 1 [JOU:5] Banishing Light +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 2 [BNG:65] Drown in Sorrow +SB: 1 [THS:85] Erebos, God of the Dead +SB: 2 [THS:22] Last Breath diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..a0e8ad57eff --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,24 @@ +1 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +1 [THS:110] Whip of Erebos +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +3 [C13:312] Orzhov Guildgate +3 [BNG:61] Bile Blight +2 [GTC:182] Obzedat, Ghost Council +4 [DGM:57] Blood Baron of Vizkopa +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +3 [GTC:63] Devour Flesh +1 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +9 [UNH:138] Swamp +SB: 3 [M14:101] Lifebane Zombie +SB: 4 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 2 [THS:83] Dark Betrayal +SB: 1 [THS:85] Erebos, God of the Dead +SB: 1 [GTC:177] Merciless Eviction diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..4d4baeef4e8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,27 @@ +2 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +3 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +2 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +2 [C13:312] Orzhov Guildgate +4 [DGM:57] Blood Baron of Vizkopa +1 [M14:215] Ratchet Bomb +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +3 [GTC:222] Nightveil Specter +2 [GTC:63] Devour Flesh +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +2 [THS:22] Last Breath +10 [UNH:138] Swamp +SB: 2 [M14:101] Lifebane Zombie +SB: 1 [THS:15] Glare of Heresy +SB: 3 [GTC:182] Obzedat, Ghost Council +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [M14:96] Doom Blade +SB: 2 [M14:97] Duress +SB: 2 [THS:83] Dark Betrayal +SB: 1 [THS:22] Last Breath +SB: 1 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..7b645864cfc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,30 @@ +2 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +1 [THS:110] Whip of Erebos +4 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +2 [JOU:5] Banishing Light +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [M15:241] Caves of Koilos +1 [BNG:61] Bile Blight +4 [M14:101] Lifebane Zombie +2 [GTC:182] Obzedat, Ghost Council +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +3 [GTC:63] Devour Flesh +1 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +8 [UNH:138] Swamp +SB: 1 [RTR:83] Underworld Connections +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 1 [THS:110] Whip of Erebos +SB: 1 [JOU:7] Deicide +SB: 2 [THS:100] Pharika's Cure +SB: 1 [M14:96] Doom Blade +SB: 2 [M14:97] Duress +SB: 2 [BNG:65] Drown in Sorrow +SB: 1 [THS:85] Erebos, God of the Dead +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Mar 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Mar 2014.mwDeck.dck new file mode 100644 index 00000000000..c4cff552ace --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST Mar 2014.mwDeck.dck @@ -0,0 +1,27 @@ +3 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +2 [BNG:5] Brimaz, King of Oreskos +1 [THS:110] Whip of Erebos +2 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [C13:312] Orzhov Guildgate +3 [BNG:61] Bile Blight +4 [M14:101] Lifebane Zombie +3 [DGM:57] Blood Baron of Vizkopa +3 [GTC:182] Obzedat, Ghost Council +4 [THS:90] Hero's Downfall +2 [M14:228] Mutavault +1 [GTC:63] Devour Flesh +4 [GTC:242] Godless Shrine +4 [UNH:136] Plains +2 [THS:9] Elspeth, Sun's Champion +7 [UNH:138] Swamp +SB: 1 [RTR:83] Underworld Connections +SB: 1 [RTR:231] Pithing Needle +SB: 2 [BNG:25] Revoke Existence +SB: 3 [M14:96] Doom Blade +SB: 4 [M14:97] Duress +SB: 1 [GTC:63] Devour Flesh +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 2 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..7288955c4f5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Control TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,25 @@ +1 [RTR:82] Ultimate Price +3 [RTR:83] Underworld Connections +4 [RTR:73] Pack Rat +3 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +2 [C13:312] Orzhov Guildgate +4 [BNG:61] Bile Blight +2 [GTC:182] Obzedat, Ghost Council +3 [DGM:57] Blood Baron of Vizkopa +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +1 [M14:97] Duress +3 [GTC:63] Devour Flesh +1 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +11 [UNH:138] Swamp +SB: 1 [RTR:82] Ultimate Price +SB: 2 [BNG:25] Revoke Existence +SB: 2 [M14:96] Doom Blade +SB: 3 [M14:97] Duress +SB: 3 [THS:83] Dark Betrayal +SB: 2 [BNG:65] Drown in Sorrow +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..73111d297d9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,26 @@ +2 [RTR:82] Ultimate Price +4 [THS:225] Temple of Deceit +4 [M14:22] Imposing Sovereign +2 [THS:110] Whip of Erebos +4 [GTC:249] Watery Grave +2 [THS:188] Ashiok, Nightmare Weaver +2 [RTR:63] Desecration Demon +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +4 [RTR:179] Lyev Skyknight +2 [RTR:201] Supreme Verdict +4 [M14:123] Xathrid Necromancer +4 [RTR:155] Detention Sphere +3 [GTC:182] Obzedat, Ghost Council +2 [M14:228] Mutavault +2 [DGM:127] Far // Away +3 [UNH:136] Plains +4 [GTC:242] Godless Shrine +4 [THS:32] Soldier of the Pantheon +SB: 1 [DGM:130] Profit // Loss +SB: 2 [THS:15] Glare of Heresy +SB: 3 [DGM:57] Blood Baron of Vizkopa +SB: 3 [M14:96] Doom Blade +SB: 1 [DGM:127] Far // Away +SB: 3 [THS:83] Dark Betrayal +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..0fc9e808bb9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Orzhov Midrange TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,29 @@ +1 [THS:110] Whip of Erebos +4 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [C13:312] Orzhov Guildgate +3 [C14:158] Read the Bones +1 [DGM:57] Blood Baron of Vizkopa +3 [GTC:182] Obzedat, Ghost Council +4 [THS:90] Hero's Downfall +1 [M14:228] Mutavault +3 [M14:96] Doom Blade +4 [RTR:17] Precinct Captain +4 [GTC:242] Godless Shrine +7 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +6 [UNH:138] Swamp +2 [DGM:103] Sin Collector +4 [THS:32] Soldier of the Pantheon +SB: 1 [RTR:83] Underworld Connections +SB: 2 [M14:101] Lifebane Zombie +SB: 1 [DGM:57] Blood Baron of Vizkopa +SB: 3 [M14:18] Fiendslayer Paladin +SB: 1 [RTR:231] Pithing Needle +SB: 1 [THS:100] Pharika's Cure +SB: 1 [M14:96] Doom Blade +SB: 1 [GTC:63] Devour Flesh +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 1 [THS:22] Last Breath +SB: 2 [DGM:103] Sin Collector diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Patriot Midrange TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Patriot Midrange TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..14626614355 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Patriot Midrange TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,32 @@ +3 [AVR:32] Restoration Angel +2 [C13:30] Augur of Bolas +3 [GTC:215] Boros Reckoner +4 [M13:225] Glacial Fortress +2 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +2 [RTR:172] Izzet Charm +3 [ISD:78] Snapcaster Mage +2 [RTR:201] Supreme Verdict +2 [RTR:145] Azorius Charm +3 [RTR:200] Sphinx's Revelation +2 [RTR:101] Mizzium Mortars +2 [AVR:227] Desolate Lighthouse +4 [RTR:247] Steam Vents +2 [M15:51] Dissipate +4 [GTC:245] Sacred Foundry +2 [DGM:94] Ral Zarek +2 [GTC:143] Aurelia, the Warleader +3 [DGM:134] Turn // Burn +3 [ISD:238] Clifftop Retreat +2 [ISD:83] Think Twice +4 [ISD:248] Sulfur Falls +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [AVR:149] Pillar of Flame +SB: 3 [M14:47] Clone +SB: 1 [RTR:1] Angel of Serenity +SB: 1 [M15:51] Dissipate +SB: 1 [RTR:153] Counterflux +SB: 1 [M14:60] Jace, Memory Adept +SB: 3 [RTR:173] Izzet Staticaster +SB: 2 [M15:71] Negate +SB: 1 [GTC:142] Assemble the Legion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Prime Speaker Bant TDtB ST May 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Prime Speaker Bant TDtB ST May 2013.mwDeck.dck new file mode 100644 index 00000000000..5deeb901492 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Prime Speaker Bant TDtB ST May 2013.mwDeck.dck @@ -0,0 +1,32 @@ +3 [AVR:32] Restoration Angel +4 [M13:229] Sunpetal Grove +2 [RTR:1] Angel of Serenity +4 [M13:225] Glacial Fortress +2 [RTR:241] Hallowed Fountain +2 [RTR:201] Supreme Verdict +4 [RTR:178] Loxodon Smiter +2 [GTC:195] Simic Charm +3 [RTR:200] Sphinx's Revelation +2 [RTR:155] Detention Sphere +3 [C13:211] Selesnya Charm +3 [M13:193] Thragtusk +1 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +2 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +3 [ISD:241] Hinterland Harbor +1 [GTC:247] Stomping Ground +2 [DGM:92] Progenitor Mimic +2 [GTC:188] Prime Speaker Zegana +3 [DGM:91] Plasm Capture +4 [GTC:240] Breeding Pool +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [C13:211] Selesnya Charm +SB: 2 [M13:29] Rhox Faithmender +SB: 1 [DGM:11] AEtherling +SB: 2 [RTR:148] Centaur Healer +SB: 2 [M15:51] Dissipate +SB: 1 [M13:22] Oblivion Ring +SB: 1 [DGM:92] Progenitor Mimic +SB: 2 [RTR:18] Rest in Peace +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Quest WW TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Quest WW TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..16beda95888 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Quest WW TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,18 @@ +4 [SOM:174] Memnite +3 [ROE:47] Student of Warfare +3 [SOM:10] Glint Hawk +2 [C14:228] Argentum Armor +2 [C14:313] Tectonic Edge +4 [ZEN:23] Kor Skyfisher +4 [M15:223] Ornithopter +4 [ZEN:21] Kor Outfitter +2 [SOM:208] Sword of Body and Mind +4 [ZEN:33] Quest for the Holy Relic +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +19 [UNH:136] Plains +1 [SOM:156] Glint Hawk Idol +SB: 4 [CMD:17] Journey to Nowhere +SB: 4 [ZEN:10] Devout Lightcaster +SB: 3 [M11:39] White Knight +SB: 4 [WWK:11] Kor Firewalker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..00af42f109c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,25 @@ +4 [WWK:141] Raging Ravine +3 [SOM:194] Precursor Golem +3 [UNH:140] Forest +4 [M11:149] Lightning Bolt +2 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +1 [ZEN:172] Oracle of Mul Daya +2 [UNH:139] Mountain +4 [C13:114] Inferno Titan +1 [C13:135] Avenger of Zendikar +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +4 [WWK:99] Explore +3 [SOM:225] Copperline Gorge +4 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 2 [C13:134] Acidic Slime +SB: 1 [ZEN:119] Burst Lightning +SB: 1 [ROE:59] Deprive +SB: 2 [SOM:218] Tumble Magnet +SB: 3 [M11:188] Obstinate Baloth +SB: 3 [M11:154] Pyroclasm +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..c2200a0c97d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,24 @@ +4 [WWK:141] Raging Ravine +3 [UNH:140] Forest +4 [M11:149] Lightning Bolt +2 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +3 [ZEN:172] Oracle of Mul Daya +2 [UNH:139] Mountain +4 [M11:70] Preordain +3 [C14:112] Frost Titan +4 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +3 [ZEN:127] Goblin Ruinblaster +4 [WWK:99] Explore +3 [SOM:225] Copperline Gorge +4 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 3 [ZEN:67] Spell Pierce +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [ZEN:127] Goblin Ruinblaster +SB: 1 [SOM:53] Volition Reins +SB: 3 [M11:188] Obstinate Baloth +SB: 4 [M11:154] Pyroclasm +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..c73eb8ad109 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,23 @@ +4 [WWK:141] Raging Ravine +3 [SOM:194] Precursor Golem +3 [UNH:140] Forest +4 [M11:149] Lightning Bolt +1 [WWK:137] Halimar Depths +3 [CMD:157] Garruk Wildspeaker +4 [ZEN:220] Misty Rainforest +2 [UNH:139] Mountain +3 [C13:114] Inferno Titan +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +4 [WWK:99] Explore +4 [SOM:225] Copperline Gorge +4 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 2 [ZEN:67] Spell Pierce +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [M11:188] Obstinate Baloth +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 4 [M11:154] Pyroclasm +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..b5028124950 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,23 @@ +4 [WWK:141] Raging Ravine +3 [UNH:140] Forest +4 [M11:149] Lightning Bolt +2 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +2 [UNH:139] Mountain +4 [C13:114] Inferno Titan +3 [C13:134] Acidic Slime +4 [M11:70] Preordain +2 [C14:112] Frost Titan +4 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +4 [WWK:99] Explore +3 [SOM:225] Copperline Gorge +4 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 2 [C13:156] Mold Shambler +SB: 1 [WWK:84] Kazuul, Tyrant of the Cliffs +SB: 2 [M14:215] Ratchet Bomb +SB: 3 [M11:188] Obstinate Baloth +SB: 4 [M11:154] Pyroclasm +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..43d5edf904d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Control TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,28 @@ +2 [MBS:21] Consecrated Sphinx +2 [NPH:161] Sword of War and Peace +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +4 [MBS:95] Viridian Emissary +3 [CNS:138] Brimstone Volley +1 [NPH:130] Batterskull +3 [MBS:92] Thrun, the Last Troll +2 [ISD:78] Snapcaster Mage +4 [M12:195] Skinshifter +2 [M13:174] Garruk, Primal Hunter +2 [ISD:181] Garruk Relentless +3 [ISD:144] Geistflame +4 [ISD:241] Hinterland Harbor +1 [C14:283] Wurmcoil Engine +4 [SOM:225] Copperline Gorge +1 [SOM:81] Arc Trail +6 [UNH:137] Island +2 [ISD:248] Sulfur Falls +1 [M15:71] Negate +4 [M12:63] Mana Leak +SB: 3 [ISD:193] Mayor of Avabruck +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 2 [M15:51] Dissipate +SB: 2 [SOM:81] Arc Trail +SB: 3 [ISD:207] Tree of Redemption +SB: 2 [M15:71] Negate +SB: 1 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Exarch TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Exarch TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..c6c39b7da56 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Exarch TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,24 @@ +4 [WWK:141] Raging Ravine +2 [M11:58] Jace Beleren +2 [UNH:140] Forest +3 [M11:149] Lightning Bolt +3 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +1 [ZEN:172] Oracle of Mul Daya +4 [C13:37] Deceiver Exarch +3 [ROE:165] Splinter Twin +2 [UNH:139] Mountain +4 [C13:114] Inferno Titan +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +2 [WWK:99] Explore +4 [SOM:225] Copperline Gorge +4 [WWK:31] Jace, the Mind Sculptor +4 [UNH:137] Island +2 [M12:63] Mana Leak +SB: 2 [ZEN:67] Spell Pierce +SB: 3 [CNS:171] Nature's Claim +SB: 2 [M11:188] Obstinate Baloth +SB: 4 [M11:154] Pyroclasm +SB: 4 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..1245022a6bb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,33 @@ +2 [WWK:141] Raging Ravine +3 [UNH:140] Forest +4 [ZEN:220] Misty Rainforest +1 [M11:188] Obstinate Baloth +1 [NPH:159] Spellskite +4 [M12:165] Birds of Paradise +4 [NPH:104] Birthing Pod +4 [C13:37] Deceiver Exarch +4 [ROE:165] Splinter Twin +3 [UNH:139] Mountain +1 [C13:134] Acidic Slime +1 [C14:124] Sea Gate Oracle +4 [M11:70] Preordain +1 [C14:112] Frost Titan +4 [ZEN:223] Scalding Tarn +1 [NPH:42] Phyrexian Metamorph +4 [ZEN:168] Lotus Cobra +1 [NPH:98] Urabrask the Hidden +1 [NPH:57] Dismember +1 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +1 [M12:72] Phantasmal Image +4 [UNH:137] Island +2 [M12:73] Ponder +SB: 1 [ZEN:67] Spell Pierce +SB: 4 [CNS:171] Nature's Claim +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [RTR:36] Dispel +SB: 2 [M12:145] Grim Lavamancer +SB: 2 [SOM:81] Arc Trail +SB: 2 [NPH:159] Spellskite +SB: 1 [M15:71] Negate +SB: 1 [SOM:210] Sylvok Replica diff --git a/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..86ea5652e40 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/RUG Twin Pod TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,32 @@ +3 [WWK:141] Raging Ravine +2 [UNH:140] Forest +1 [WWK:137] Halimar Depths +4 [ZEN:220] Misty Rainforest +4 [ROE:203] Overgrown Battlement +2 [NPH:159] Spellskite +4 [M12:165] Birds of Paradise +3 [NPH:104] Birthing Pod +4 [C13:37] Deceiver Exarch +4 [ROE:165] Splinter Twin +2 [UNH:139] Mountain +1 [C13:134] Acidic Slime +3 [M11:70] Preordain +2 [C14:112] Frost Titan +4 [ZEN:223] Scalding Tarn +1 [NPH:98] Urabrask the Hidden +1 [C14:183] Tuktuk the Explorer +2 [C14:271] Solemn Simulacrum +4 [SOM:225] Copperline Gorge +1 [M12:72] Phantasmal Image +4 [UNH:137] Island +3 [M12:73] Ponder +1 [SOM:177] Molten-Tail Masticore +SB: 2 [CNS:171] Nature's Claim +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [M11:188] Obstinate Baloth +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 1 [NPH:159] Spellskite +SB: 4 [M11:154] Pyroclasm +SB: 1 [SOM:101] Oxidda Scrapmelter +SB: 3 [M12:63] Mana Leak +SB: 1 [SOM:210] Sylvok Replica diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..1ad7926e473 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,22 @@ +4 [RTR:86] Ash Zealot +4 [M13:147] Searing Spear +4 [M13:222] Dragonskull Summit +10 [UNH:139] Mountain +3 [RTR:167] Hellhole Flailer +2 [M13:150] Thundermaw Hellkite +4 [RTR:220] Rakdos Cackler +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +4 [AVR:226] Cavern of Souls +3 [DKA:93] Hellrider +4 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [M13:96] Knight of Infamy +2 [UNH:138] Swamp +SB: 2 [RTR:82] Ultimate Price +SB: 4 [C13:97] Vampire Nighthawk +SB: 2 [AVR:84] Appetite for Brains +SB: 2 [M14:139] Flames of the Firebrand +SB: 2 [AVR:166] Zealous Conscripts +SB: 1 [RTR:197] Slaughter Games +SB: 2 [RTR:59] Cremate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..d0444e8b350 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,26 @@ +2 [RTR:82] Ultimate Price +2 [C13:97] Vampire Nighthawk +4 [AVR:86] Blood Artist +2 [M13:147] Searing Spear +4 [M13:222] Dragonskull Summit +3 [C13:314] Rakdos Guildgate +4 [ISD:97] Diregraf Ghoul +2 [C14:167] Tragic Slip +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +3 [AVR:226] Cavern of Souls +4 [DKA:93] Hellrider +4 [DKA:63] Geralf's Messenger +1 [AVR:129] Bonfire of the Damned +1 [AVR:166] Zealous Conscripts +4 [M13:96] Knight of Infamy +4 [DKA:64] Gravecrawler +8 [UNH:138] Swamp +SB: 2 [M13:141] Mark of Mutiny +SB: 2 [RTR:101] Mizzium Mortars +SB: 2 [AVR:84] Appetite for Brains +SB: 3 [AVR:149] Pillar of Flame +SB: 1 [M14:139] Flames of the Firebrand +SB: 1 [AVR:129] Bonfire of the Damned +SB: 2 [RTR:197] Slaughter Games +SB: 2 [RTR:184] Rakdos Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..fb48c9a3abc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Rakdos Aggro TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,24 @@ +2 [CNS:138] Brimstone Volley +4 [M13:147] Searing Spear +4 [M13:222] Dragonskull Summit +4 [C13:314] Rakdos Guildgate +1 [UNH:139] Mountain +3 [M13:150] Thundermaw Hellkite +4 [ISD:97] Diregraf Ghoul +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +4 [AVR:226] Cavern of Souls +3 [DKA:93] Hellrider +4 [DKA:63] Geralf's Messenger +4 [M13:96] Knight of Infamy +4 [DKA:64] Gravecrawler +2 [C14:161] Sign in Blood +2 [ISD:124] Victim of Night +7 [UNH:138] Swamp +SB: 2 [RTR:83] Underworld Connections +SB: 2 [AVR:84] Appetite for Brains +SB: 3 [AVR:149] Pillar of Flame +SB: 3 [AVR:129] Bonfire of the Damned +SB: 2 [AVR:166] Zealous Conscripts +SB: 1 [ISD:124] Victim of Night +SB: 2 [RTR:59] Cremate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..dec79db42c3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,25 @@ +2 [AVR:32] Restoration Angel +2 [AVR:172] Craterhoof Behemoth +3 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +4 [RTR:1] Angel of Serenity +4 [RTR:243] Overgrown Tomb +4 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +2 [AVR:226] Cavern of Souls +3 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +4 [RTR:148] Centaur Healer +4 [ISD:196] Mulch +1 [ISD:239] Gavony Township +3 [ISD:249] Woodland Cemetery +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 3 [AVR:194] Somberwald Sage +SB: 2 [AVR:226] Cavern of Souls +SB: 3 [RTR:213] Deathrite Shaman +SB: 2 [ISD:115] Sever the Bloodline +SB: 1 [M13:22] Oblivion Ring +SB: 2 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..8ed9a1640f1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Reanimator TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,28 @@ +3 [AVR:32] Restoration Angel +2 [AVR:172] Craterhoof Behemoth +3 [M13:229] Sunpetal Grove +1 [UNH:140] Forest +4 [RTR:1] Angel of Serenity +4 [RTR:243] Overgrown Tomb +2 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +4 [RTR:165] Grisly Salvage +4 [ISD:122] Unburial Rites +3 [AVR:226] Cavern of Souls +3 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +3 [RTR:148] Centaur Healer +4 [ISD:196] Mulch +3 [DKA:12] Lingering Souls +2 [ISD:239] Gavony Township +3 [ISD:249] Woodland Cemetery +SB: 1 [DKA:17] Ray of Revelation +SB: 3 [RTR:178] Loxodon Smiter +SB: 1 [M13:29] Rhox Faithmender +SB: 1 [AVR:226] Cavern of Souls +SB: 2 [RTR:213] Deathrite Shaman +SB: 2 [ISD:115] Sever the Bloodline +SB: 2 [M14:97] Duress +SB: 2 [M13:22] Oblivion Ring +SB: 1 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Apr 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Apr 2014.mwDeck.dck new file mode 100644 index 00000000000..7a56d373d40 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Apr 2014.mwDeck.dck @@ -0,0 +1,19 @@ +4 [GTC:90] Firefist Striker +4 [GTC:216] Burning-Tree Emissary +4 [THS:122] Firedrinker Satyr +4 [RTR:96] Gore-House Chainwalker +4 [M15:141] Foundry Street Denizen +18 [UNH:139] Mountain +4 [DGM:38] Rubblebelt Maaka +2 [M14:155] Shock +2 [RTR:101] Mizzium Mortars +4 [M14:134] Chandra's Phoenix +4 [RTR:220] Rakdos Cackler +4 [M14:228] Mutavault +2 [BNG:111] Searing Blood +SB: 2 [THS:124] Hammer of Purphoros +SB: 3 [THS:132] Peak Eruption +SB: 4 [GTC:106] Skullcrack +SB: 3 [GTC:215] Boros Reckoner +SB: 2 [BNG:111] Searing Blood +SB: 1 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..d82e7c3a331 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,24 @@ +1 [ROE:152] Kargan Dragonlord +2 [MBS:66] Hero of Oxid Ridge +1 [NPH:161] Sword of War and Peace +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +4 [M12:145] Grim Lavamancer +4 [NPH:153] Shrine of Burning Rage +2 [ZEN:141] Plated Geopede +4 [ROE:166] Staggershock +11 [UNH:139] Mountain +4 [WWK:90] Searing Blaze +4 [M14:134] Chandra's Phoenix +2 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +4 [ZEN:226] Teetering Peaks +1 [SOM:94] Koth of the Hammer +SB: 3 [M12:151] Manic Vandal +SB: 2 [M12:150] Manabarbs +SB: 2 [M12:128] Combust +SB: 3 [NPH:78] Act of Aggression +SB: 2 [NPH:57] Dismember +SB: 2 [SOM:81] Arc Trail +SB: 1 [NPH:101] Vulshok Refugee diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..4799f77ee08 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,23 @@ +3 [GTC:90] Firefist Striker +2 [RTR:86] Ash Zealot +4 [GTC:216] Burning-Tree Emissary +4 [THS:122] Firedrinker Satyr +1 [THS:145] Titan's Strength +4 [M15:141] Foundry Street Denizen +4 [M15:164] Stoke the Flames +18 [UNH:139] Mountain +3 [DGM:38] Rubblebelt Maaka +3 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [RTR:220] Rakdos Cackler +3 [M14:228] Mutavault +3 [GTC:97] Legion Loyalist +SB: 1 [RTR:93] Electrickery +SB: 2 [RTR:101] Mizzium Mortars +SB: 2 [JOU:103] Magma Spray +SB: 1 [RTR:92] Dynacharge +SB: 1 [JOU:100] Harness by Force +SB: 1 [THS:145] Titan's Strength +SB: 2 [GTC:106] Skullcrack +SB: 1 [BNG:111] Searing Blood +SB: 4 [JOU:94] Eidolon of the Great Revel diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..4c0beb4045f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,20 @@ +4 [ROE:152] Kargan Dragonlord +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +4 [ROE:145] Flame Slash +4 [ZEN:141] Plated Geopede +13 [UNH:139] Mountain +4 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +3 [ZEN:226] Teetering Peaks +4 [SOM:94] Koth of the Hammer +4 [SOM:104] Spikeshot Elder +4 [SOM:177] Molten-Tail Masticore +SB: 1 [M12:151] Manic Vandal +SB: 3 [M13:141] Mark of Mutiny +SB: 1 [KTK:120] Shatter +SB: 3 [M12:128] Combust +SB: 3 [M11:202] Brittle Effigy +SB: 2 [SOM:105] Tunnel Ignus +SB: 2 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..ad9ea9eb4da --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,20 @@ +3 [M13:228] Rootbound Crag +4 [M12:139] Goblin Fireslinger +4 [NPH:100] Volt Charge +2 [M12:146] Incinerate +3 [M12:145] Grim Lavamancer +4 [M12:156] Stormblood Berserker +4 [NPH:153] Shrine of Burning Rage +18 [UNH:139] Mountain +4 [M14:134] Chandra's Phoenix +4 [NPH:86] Gut Shot +4 [ISD:164] Stromkirk Noble +1 [SOM:104] Spikeshot Elder +2 [SOM:81] Arc Trail +3 [SOM:91] Galvanic Blast +SB: 2 [MBS:66] Hero of Oxid Ridge +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [NPH:57] Dismember +SB: 1 [SOM:81] Arc Trail +SB: 4 [NPH:101] Vulshok Refugee +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..1bdc8329718 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,16 @@ +20 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M14:155] Shock +4 [M14:134] Chandra's Phoenix +4 [RTR:220] Rakdos Cackler +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [GTC:216] Burning-Tree Emissary +4 [THS:122] Firedrinker Satyr +4 [GTC:215] Boros Reckoner +4 [THS:119] Dragon Mantle +SB: 2 [RTR:101] Mizzium Mortars +SB: 3 [THS:132] Peak Eruption +SB: 3 [KTK:95] Act of Treason +SB: 4 [GTC:106] Skullcrack +SB: 3 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..1901d9eb8ed --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,19 @@ +22 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +4 [THS:145] Titan's Strength +4 [KTK:118] Monastery Swiftspear +2 [BNG:111] Searing Blood +4 [KTK:125] Valley Dasher +4 [THS:128] Magma Jet +4 [M15:141] Foundry Street Denizen +4 [M15:164] Stoke the Flames +SB: 4 [M15:134] Chandra, Pyromaster +SB: 1 [THS:224] Temple of Abandon +SB: 1 [M15:147] Hammerhand +SB: 1 [THS:143] Stormbreath Dragon +SB: 2 [KTK:97] Arc Lightning +SB: 3 [KTK:119] Sarkhan, the Dragonspeaker +SB: 2 [BNG:111] Searing Blood +SB: 1 [THS:228] Temple of Triumph diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..5dd745b584a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,20 @@ +4 [ROE:152] Kargan Dragonlord +1 [WWK:122] Basilisk Collar +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +4 [ZEN:141] Plated Geopede +12 [UNH:139] Mountain +2 [WWK:90] Searing Blaze +2 [M13:141] Mark of Mutiny +4 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +4 [ZEN:226] Teetering Peaks +4 [SOM:94] Koth of the Hammer +4 [SOM:104] Spikeshot Elder +3 [SOM:81] Arc Trail +SB: 1 [M13:141] Mark of Mutiny +SB: 4 [M11:202] Brittle Effigy +SB: 4 [ROE:145] Flame Slash +SB: 3 [SOM:177] Molten-Tail Masticore +SB: 3 [WWK:79] Cunning Sparkmage diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..d9244811e0b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,16 @@ +22 [UNH:139] Mountain +4 [DKA:101] Pyreheart Wolf +4 [RTR:220] Rakdos Cackler +4 [RTR:86] Ash Zealot +4 [DKA:93] Hellrider +4 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [GTC:215] Boros Reckoner +4 [AVR:144] Lightning Mauler +2 [AVR:157] Stonewright +4 [M13:147] Searing Spear +SB: 4 [RTR:101] Mizzium Mortars +SB: 2 [AVR:126] Archwing Dragon +SB: 3 [GTC:106] Skullcrack +SB: 2 [M14:139] Flames of the Firebrand +SB: 4 [ISD:159] Reckless Waif diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..ad9ea9eb4da --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,20 @@ +3 [M13:228] Rootbound Crag +4 [M12:139] Goblin Fireslinger +4 [NPH:100] Volt Charge +2 [M12:146] Incinerate +3 [M12:145] Grim Lavamancer +4 [M12:156] Stormblood Berserker +4 [NPH:153] Shrine of Burning Rage +18 [UNH:139] Mountain +4 [M14:134] Chandra's Phoenix +4 [NPH:86] Gut Shot +4 [ISD:164] Stromkirk Noble +1 [SOM:104] Spikeshot Elder +2 [SOM:81] Arc Trail +3 [SOM:91] Galvanic Blast +SB: 2 [MBS:66] Hero of Oxid Ridge +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [NPH:57] Dismember +SB: 1 [SOM:81] Arc Trail +SB: 4 [NPH:101] Vulshok Refugee +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..da60362949f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,20 @@ +4 [RTR:86] Ash Zealot +2 [M13:226] Hellion Crucible +2 [CNS:138] Brimstone Volley +4 [M13:147] Searing Spear +21 [UNH:139] Mountain +4 [DKA:101] Pyreheart Wolf +2 [M13:150] Thundermaw Hellkite +4 [RTR:220] Rakdos Cackler +4 [DKA:93] Hellrider +3 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +4 [AVR:144] Lightning Mauler +2 [AVR:157] Stonewright +SB: 4 [RTR:101] Mizzium Mortars +SB: 2 [AVR:126] Archwing Dragon +SB: 1 [RTR:215] Frostburn Weird +SB: 1 [AVR:226] Cavern of Souls +SB: 1 [AVR:149] Pillar of Flame +SB: 4 [ISD:159] Reckless Waif +SB: 2 [M13:155] Volcanic Strength diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..2fe0d9b78ea --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,20 @@ +1 [MBS:66] Hero of Oxid Ridge +4 [M11:149] Lightning Bolt +3 [M11:135] Ember Hauler +4 [ZEN:211] Arid Mesa +4 [M12:145] Grim Lavamancer +4 [NPH:153] Shrine of Burning Rage +4 [ZEN:141] Plated Geopede +11 [UNH:139] Mountain +4 [WWK:90] Searing Blaze +2 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +4 [ZEN:226] Teetering Peaks +3 [NPH:57] Dismember +4 [SOM:81] Arc Trail +SB: 3 [M12:151] Manic Vandal +SB: 2 [MBS:75] Slagstorm +SB: 3 [NPH:78] Act of Aggression +SB: 3 [SOM:94] Koth of the Hammer +SB: 4 [NPH:101] Vulshok Refugee diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..763ec1de8f2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,18 @@ +4 [M11:149] Lightning Bolt +4 [M11:135] Ember Hauler +4 [ZEN:211] Arid Mesa +4 [NPH:153] Shrine of Burning Rage +4 [ROE:166] Staggershock +12 [UNH:139] Mountain +4 [WWK:90] Searing Blaze +4 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +4 [ZEN:226] Teetering Peaks +4 [SOM:94] Koth of the Hammer +4 [SOM:104] Spikeshot Elder +SB: 2 [M12:151] Manic Vandal +SB: 3 [M12:128] Combust +SB: 3 [NPH:78] Act of Aggression +SB: 3 [NPH:57] Dismember +SB: 4 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..812baf0eeee --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,19 @@ +3 [GTC:90] Firefist Striker +4 [RTR:86] Ash Zealot +4 [THS:121] Fanatic of Mogis +4 [GTC:216] Burning-Tree Emissary +4 [THS:122] Firedrinker Satyr +4 [GTC:215] Boros Reckoner +2 [THS:128] Magma Jet +19 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M14:155] Shock +4 [M14:134] Chandra's Phoenix +4 [RTR:220] Rakdos Cackler +2 [M14:228] Mutavault +1 [BNG:111] Searing Blood +SB: 4 [RTR:101] Mizzium Mortars +SB: 2 [DGM:133] Toil // Trouble +SB: 2 [JOU:100] Harness by Force +SB: 4 [GTC:106] Skullcrack +SB: 3 [BNG:111] Searing Blood diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..728f9ca2642 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,18 @@ +20 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +4 [THS:122] Firedrinker Satyr +4 [FRF:108] Mardu Scout +4 [KTK:118] Monastery Swiftspear +4 [FRF:118] Wild Slash +4 [BNG:111] Searing Blood +4 [M15:141] Foundry Street Denizen +4 [M15:164] Stoke the Flames +SB: 2 [THS:124] Hammer of Purphoros +SB: 2 [JOU:106] Prophetic Flamespeaker +SB: 2 [FRF:92] Bathe in Dragonfire +SB: 2 [THS:132] Peak Eruption +SB: 2 [KTK:97] Arc Lightning +SB: 4 [JOU:94] Eidolon of the Great Revel +SB: 1 [FRF:102] Goblin Heelcutter diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..592282bd4ac --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,20 @@ +1 [WWK:143] Smoldering Spires +4 [M11:149] Lightning Bolt +4 [M11:135] Ember Hauler +4 [ZEN:211] Arid Mesa +4 [NPH:153] Shrine of Burning Rage +4 [ROE:166] Staggershock +13 [UNH:139] Mountain +4 [WWK:90] Searing Blaze +4 [ZEN:119] Burst Lightning +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +2 [ZEN:226] Teetering Peaks +4 [SOM:94] Koth of the Hammer +4 [SOM:104] Spikeshot Elder +SB: 3 [M13:141] Mark of Mutiny +SB: 3 [MBS:75] Slagstorm +SB: 1 [SOM:192] Perilous Myr +SB: 3 [M12:128] Combust +SB: 3 [ROE:145] Flame Slash +SB: 2 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..22cb3f2ea62 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,19 @@ +4 [M12:139] Goblin Fireslinger +4 [NPH:100] Volt Charge +2 [M12:146] Incinerate +3 [M12:145] Grim Lavamancer +4 [M12:156] Stormblood Berserker +4 [NPH:153] Shrine of Burning Rage +21 [UNH:139] Mountain +4 [M14:134] Chandra's Phoenix +4 [NPH:86] Gut Shot +4 [ISD:164] Stromkirk Noble +1 [SOM:104] Spikeshot Elder +2 [SOM:81] Arc Trail +3 [SOM:91] Galvanic Blast +SB: 1 [M12:151] Manic Vandal +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [NPH:57] Dismember +SB: 2 [SOM:94] Koth of the Hammer +SB: 2 [SOM:81] Arc Trail +SB: 4 [NPH:101] Vulshok Refugee diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..3f517fdf05f --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,21 @@ +4 [RTR:86] Ash Zealot +3 [RTR:96] Gore-House Chainwalker +3 [M13:226] Hellion Crucible +2 [M13:147] Searing Spear +21 [UNH:139] Mountain +4 [DKA:101] Pyreheart Wolf +3 [M13:150] Thundermaw Hellkite +4 [RTR:220] Rakdos Cackler +4 [DKA:93] Hellrider +2 [AVR:149] Pillar of Flame +4 [ISD:164] Stromkirk Noble +2 [M14:139] Flames of the Firebrand +4 [AVR:144] Lightning Mauler +SB: 1 [ISD:166] Traitorous Blood +SB: 3 [AVR:126] Archwing Dragon +SB: 1 [AVR:149] Pillar of Flame +SB: 2 [M14:139] Flames of the Firebrand +SB: 1 [M13:226] Hellion Crucible +SB: 2 [AVR:166] Zealous Conscripts +SB: 4 [ISD:159] Reckless Waif +SB: 1 [M13:147] Searing Spear diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..18e19448d6d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,18 @@ +18 [UNH:139] Mountain +2 [DGM:38] Rubblebelt Maaka +4 [M15:155] Lightning Strike +4 [M14:155] Shock +4 [M14:134] Chandra's Phoenix +4 [GTC:90] Firefist Striker +4 [RTR:220] Rakdos Cackler +4 [GTC:216] Burning-Tree Emissary +4 [THS:122] Firedrinker Satyr +4 [RTR:96] Gore-House Chainwalker +4 [M14:228] Mutavault +4 [M15:141] Foundry Street Denizen +SB: 1 [DGM:38] Rubblebelt Maaka +SB: 4 [RTR:101] Mizzium Mortars +SB: 3 [THS:132] Peak Eruption +SB: 2 [KTK:95] Act of Treason +SB: 4 [GTC:106] Skullcrack +SB: 1 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..cd5d44d68a9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,17 @@ +18 [UNH:139] Mountain +3 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [M15:147] Hammerhand +4 [THS:111] Akroan Crusader +4 [THS:122] Firedrinker Satyr +4 [THS:145] Titan's Strength +4 [KTK:118] Monastery Swiftspear +4 [M15:141] Foundry Street Denizen +3 [M15:142] Frenzied Goblin +4 [THS:119] Dragon Mantle +4 [M15:164] Stoke the Flames +SB: 1 [M15:155] Lightning Strike +SB: 3 [JOU:103] Magma Spray +SB: 3 [JOU:100] Harness by Force +SB: 4 [BNG:111] Searing Blood +SB: 4 [JOU:94] Eidolon of the Great Revel diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..e0b6155848a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,18 @@ +20 [UNH:139] Mountain +3 [NPH:84] Furnace Scamp +4 [M14:134] Chandra's Phoenix +4 [ISD:144] Geistflame +3 [M13:228] Rootbound Crag +4 [ISD:164] Stromkirk Noble +4 [CNS:138] Brimstone Volley +4 [SOM:94] Koth of the Hammer +4 [M12:146] Incinerate +2 [SOM:104] Spikeshot Elder +4 [M12:156] Stormblood Berserker +4 [NPH:153] Shrine of Burning Rage +SB: 2 [MBS:66] Hero of Oxid Ridge +SB: 2 [ISD:166] Traitorous Blood +SB: 3 [SOM:192] Perilous Myr +SB: 2 [SOM:81] Arc Trail +SB: 4 [NPH:101] Vulshok Refugee +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..7a2314a3b8b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Red Deck Wins TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,21 @@ +3 [ROE:152] Kargan Dragonlord +2 [MBS:66] Hero of Oxid Ridge +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +4 [M12:145] Grim Lavamancer +4 [NPH:153] Shrine of Burning Rage +3 [ROE:146] Forked Bolt +3 [ROE:166] Staggershock +11 [UNH:139] Mountain +4 [WWK:90] Searing Blaze +4 [M14:134] Chandra's Phoenix +4 [ZEN:223] Scalding Tarn +4 [ZEN:126] Goblin Guide +4 [ZEN:226] Teetering Peaks +2 [SOM:81] Arc Trail +SB: 3 [M12:151] Manic Vandal +SB: 3 [M12:128] Combust +SB: 3 [NPH:78] Act of Aggression +SB: 2 [NPH:57] Dismember +SB: 1 [SOM:81] Arc Trail +SB: 3 [NPH:101] Vulshok Refugee diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..81d1b5e28ee --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,43 @@ +1 [WMCQ:2] Geist of Saint Traft +2 [M12:18] Gideon's Lawkeeper +1 [M12:19] Grand Abolisher +3 [C13:11] Fiend Hunter +1 [ALA:20] Oblivion Ring +3 [C14:74] Grand Abolisher +2 [M10:16] Honor of the Pure +1 [POR:216] Plains +1 [M10:233] Plains +1 [M13:225] Glacial Fortress +4 [PTC:47] Hero of Bladehold +3 [ISD:11] Doomed Traveler +1 [DDK:2] Doomed Traveler +1 [DDN:81] Plains +1 [ODY:333] Plains +1 [DDI:40] Plains +3 [ISD:244] Moorland Haunt +1 [MBS:14] Mirran Crusader +1 [ALA:230] Plains +2 [M10:226] Glacial Fortress +1 [M12:227] Glacial Fortress +2 [MBP:32] Mirran Crusader +3 [M12:3] Angelic Destiny +1 [LRW:34] Oblivion Ring +1 [ZEN:232] Plains +1 [DDN:38] Plains +1 [HOP:145] Plains +1 [KTK:250] Plains +1 [MM2:25] Mirran Crusader +1 [ISD:251] Plains +4 [SOM:229] Seachrome Coast +1 [ISD:213] Geist of Saint Traft +2 [M12:23] Honor of the Pure +1 [ME3:220] Island +4 [ISD:6] Champion of the Parish +1 [AVR:231] Plains +SB: 2 [NPH:161] Sword of War and Peace +SB: 2 [NPH:57] Dismember +SB: 1 [M12:11] Celestial Purge +SB: 1 [MBS:115] Mortarpod +SB: 4 [M12:40] Timely Reinforcements +SB: 3 [M12:63] Mana Leak +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..8514cee2baf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,21 @@ +4 [C14:74] Grand Abolisher +4 [M12:15] Elite Vanguard +4 [M12:3] Angelic Destiny +4 [M13:225] Glacial Fortress +4 [SOM:229] Seachrome Coast +2 [NPH:57] Dismember +4 [ISD:213] Geist of Saint Traft +2 [ISD:244] Moorland Haunt +3 [M13:22] Oblivion Ring +4 [M12:23] Honor of the Pure +12 [UNH:136] Plains +4 [MBS:14] Mirran Crusader +1 [UNH:137] Island +4 [ISD:6] Champion of the Parish +4 [MBS:8] Hero of Bladehold +SB: 3 [ISD:27] Purify the Grave +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [NPH:57] Dismember +SB: 3 [BNG:25] Revoke Existence +SB: 1 [M13:22] Oblivion Ring +SB: 4 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..100fa002955 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,30 @@ +2 [MBS:10] Leonin Relic-Warder +2 [SOM:14] Leonin Arbiter +4 [C13:11] Fiend Hunter +1 [NPH:161] Sword of War and Peace +1 [M12:3] Angelic Destiny +4 [M13:225] Glacial Fortress +1 [C14:298] Ghost Quarter +4 [SOM:229] Seachrome Coast +2 [NPH:57] Dismember +3 [ISD:213] Geist of Saint Traft +3 [ISD:244] Moorland Haunt +2 [M13:22] Oblivion Ring +4 [M12:23] Honor of the Pure +11 [UNH:136] Plains +4 [MBS:14] Mirran Crusader +1 [UNH:137] Island +4 [MBS:8] Hero of Bladehold +4 [CNS:69] Doomed Traveler +3 [M12:63] Mana Leak +SB: 1 [SOM:14] Leonin Arbiter +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [M12:3] Angelic Destiny +SB: 1 [NPH:57] Dismember +SB: 2 [BNG:25] Revoke Existence +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:12] Day of Judgment +SB: 4 [M12:40] Timely Reinforcements +SB: 1 [M12:63] Mana Leak +SB: 1 [M12:52] Flashfreeze +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..82965ed6233 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Saint WW with Leaks TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,27 @@ +2 [MBS:10] Leonin Relic-Warder +3 [M12:18] Gideon's Lawkeeper +4 [C13:11] Fiend Hunter +4 [M13:225] Glacial Fortress +4 [SOM:229] Seachrome Coast +2 [NPH:57] Dismember +3 [ISD:213] Geist of Saint Traft +1 [MBS:115] Mortarpod +4 [ISD:244] Moorland Haunt +2 [M13:22] Oblivion Ring +4 [M12:23] Honor of the Pure +11 [UNH:136] Plains +4 [MBS:14] Mirran Crusader +1 [UNH:137] Island +4 [MBS:8] Hero of Bladehold +4 [CNS:69] Doomed Traveler +3 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [M12:3] Angelic Destiny +SB: 2 [NPH:57] Dismember +SB: 2 [BNG:25] Revoke Existence +SB: 1 [ISD:213] Geist of Saint Traft +SB: 1 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:12] Day of Judgment +SB: 4 [M12:40] Timely Reinforcements +SB: 1 [M12:63] Mana Leak diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Saito Naya TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Saito Naya TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..95279e6802a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Saito Naya TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,25 @@ +3 [M13:229] Sunpetal Grove +4 [M13:228] Rootbound Crag +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +2 [UNH:139] Mountain +4 [RTR:178] Loxodon Smiter +4 [RTR:101] Mizzium Mortars +3 [M13:150] Thundermaw Hellkite +1 [M13:193] Thragtusk +4 [M13:171] Flinthoof Boar +4 [RTR:248] Temple Garden +4 [DKA:93] Hellrider +4 [GTC:247] Stomping Ground +4 [GTC:245] Sacred Foundry +4 [GTC:123] Gyre Sage +4 [GTC:156] Domri Rade +3 [ISD:238] Clifftop Retreat +SB: 3 [C13:179] Boros Charm +SB: 1 [M13:193] Thragtusk +SB: 2 [ISD:181] Garruk Relentless +SB: 2 [M14:25] Pacifism +SB: 2 [AVR:31] Nearheath Pilgrim +SB: 1 [GTC:143] Aurelia, the Warleader +SB: 2 [RTR:18] Rest in Peace +SB: 2 [AVR:198] Triumph of Ferocity diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..4a0631f59d9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,22 @@ +3 [M14:1] Ajani, Caller of the Pride +4 [GTC:119] Experiment One +7 [UNH:140] Forest +3 [JOU:5] Banishing Light +4 [RTR:178] Loxodon Smiter +4 [C13:211] Selesnya Charm +2 [M15:202] Sunblade Elf +4 [RTR:248] Temple Garden +4 [THS:193] Fleecemane Lion +2 [BNG:165] Temple of Plenty +4 [JOU:163] Mana Confluence +4 [DGM:51] Advent of the Wurm +7 [UNH:136] Plains +4 [THS:32] Soldier of the Pantheon +4 [DGM:114] Voice of Resurgence +SB: 4 [DGM:49] Skylasher +SB: 2 [C14:213] Reclamation Sage +SB: 3 [DGM:111] Unflinching Courage +SB: 2 [M14:5] Archangel of Thune +SB: 1 [JOU:5] Banishing Light +SB: 2 [JOU:140] Setessan Tactics +SB: 1 [THS:152] Boon Satyr diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..8845cd114d5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,25 @@ +3 [M14:1] Ajani, Caller of the Pride +4 [GTC:119] Experiment One +5 [UNH:140] Forest +2 [JOU:5] Banishing Light +4 [RTR:178] Loxodon Smiter +4 [C13:211] Selesnya Charm +2 [M15:202] Sunblade Elf +4 [RTR:248] Temple Garden +2 [M14:228] Mutavault +4 [THS:193] Fleecemane Lion +4 [JOU:163] Mana Confluence +4 [BNG:165] Temple of Plenty +3 [DGM:51] Advent of the Wurm +3 [THS:152] Boon Satyr +5 [UNH:136] Plains +3 [THS:32] Soldier of the Pantheon +4 [DGM:114] Voice of Resurgence +SB: 4 [DGM:49] Skylasher +SB: 2 [THS:159] Hunt the Hunter +SB: 2 [M15:1] Ajani Steadfast +SB: 2 [THS:16] Gods Willing +SB: 2 [M14:5] Archangel of Thune +SB: 1 [DGM:51] Advent of the Wurm +SB: 1 [THS:162] Mistcutter Hydra +SB: 1 [JOU:140] Setessan Tactics diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST May 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST May 2015.mwDeck.dck new file mode 100644 index 00000000000..8047e926796 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST May 2015.mwDeck.dck @@ -0,0 +1,27 @@ +2 [THS:223] Nykthos, Shrine to Nyx +2 [FRF:28] Valorous Stance +4 [DTK:181] Den Protector +8 [UNH:140] Forest +4 [KTK:248] Windswept Heath +2 [BNG:117] Aspect of Hydra +3 [DTK:248] Evolving Wilds +4 [DTK:175] Avatar of the Resolute +4 [THS:193] Fleecemane Lion +4 [BNG:165] Temple of Plenty +2 [DTK:210] Surrak, the Hunt Caller +4 [THS:173] Reverent Hunter +3 [DTK:221] Dromoka's Command +4 [DTK:177] Collected Company +4 [THS:152] Boon Satyr +4 [C14:191] Elvish Mystic +2 [UNH:136] Plains +SB: 1 [C14:213] Reclamation Sage +SB: 2 [FRF:18] Mardu Woe-Reaper +SB: 1 [KTK:130] Become Immense +SB: 1 [THS:16] Gods Willing +SB: 2 [BNG:4] Archetype of Courage +SB: 1 [THS:167] Nylea's Disciple +SB: 3 [FRF:5] Arashin Cleric +SB: 1 [DTK:221] Dromoka's Command +SB: 1 [DTK:210] Surrak, the Hunt Caller +SB: 2 [KTK:157] Windstorm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..5abc7495c81 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,27 @@ +4 [AVR:32] Restoration Angel +2 [C14:88] Silverblade Paladin +2 [AVR:12] Cloudshift +4 [M13:229] Sunpetal Grove +6 [UNH:140] Forest +1 [C14:72] Geist-Honored Monk +2 [M13:36] Sublime Archangel +4 [RTR:178] Loxodon Smiter +3 [C13:211] Selesnya Charm +2 [RTR:143] Armada Wurm +4 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +2 [AVR:226] Cavern of Souls +4 [RTR:248] Temple Garden +2 [M13:22] Oblivion Ring +3 [UNH:136] Plains +4 [ISD:239] Gavony Township +3 [DKA:24] Thalia, Guardian of Thraben +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 2 [ISD:32] Slayer of the Wicked +SB: 3 [RTR:148] Centaur Healer +SB: 2 [AVR:210] Sigarda, Host of Herons +SB: 1 [AVR:18] Divine Deflection +SB: 1 [M13:22] Oblivion Ring +SB: 1 [DKA:24] Thalia, Guardian of Thraben +SB: 3 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2013.mwDeck.dck new file mode 100644 index 00000000000..205021fe44c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Nov 2013.mwDeck.dck @@ -0,0 +1,20 @@ +2 [M14:1] Ajani, Caller of the Pride +4 [GTC:119] Experiment One +3 [THS:16] Gods Willing +8 [UNH:140] Forest +4 [RTR:178] Loxodon Smiter +3 [C13:321] Selesnya Guildgate +4 [C13:211] Selesnya Charm +4 [RTR:248] Temple Garden +4 [THS:193] Fleecemane Lion +4 [DGM:51] Advent of the Wurm +4 [THS:152] Boon Satyr +8 [UNH:136] Plains +4 [THS:32] Soldier of the Pantheon +4 [DGM:114] Voice of Resurgence +SB: 3 [DGM:111] Unflinching Courage +SB: 3 [RTR:19] Rootborn Defenses +SB: 1 [M14:1] Ajani, Caller of the Pride +SB: 3 [M14:12] Celestial Flare +SB: 2 [THS:172] Polukranos, World Eater +SB: 3 [THS:162] Mistcutter Hydra diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..be9097c524a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,27 @@ +4 [AVR:32] Restoration Angel +4 [M13:229] Sunpetal Grove +8 [UNH:140] Forest +3 [RTR:146] Call of the Conclave +3 [RTR:178] Loxodon Smiter +3 [C13:211] Selesnya Charm +2 [RTR:143] Armada Wurm +4 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +2 [ISD:181] Garruk Relentless +4 [RTR:248] Temple Garden +4 [RTR:148] Centaur Healer +1 [AVR:200] Ulvenwald Tracker +2 [RTR:206] Trostani, Selesnya's Voice +2 [M13:22] Oblivion Ring +2 [ISD:239] Gavony Township +4 [UNH:136] Plains +SB: 2 [RTR:223] Sundering Growth +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 1 [DKA:17] Ray of Revelation +SB: 1 [AVR:210] Sigarda, Host of Herons +SB: 1 [M13:22] Oblivion Ring +SB: 2 [DKA:24] Thalia, Guardian of Thraben +SB: 3 [RTR:18] Rest in Peace +SB: 1 [DKA:110] Crushing Vines +SB: 2 [RTR:150] Collective Blessing diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2013.mwDeck.dck new file mode 100644 index 00000000000..834a1c0280a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Selesnya Aggro TDtB ST Oct 2013.mwDeck.dck @@ -0,0 +1,22 @@ +4 [GTC:119] Experiment One +9 [UNH:140] Forest +2 [RTR:146] Call of the Conclave +3 [RTR:178] Loxodon Smiter +3 [C13:321] Selesnya Guildgate +3 [DGM:111] Unflinching Courage +4 [C13:211] Selesnya Charm +4 [RTR:248] Temple Garden +4 [THS:193] Fleecemane Lion +4 [DGM:51] Advent of the Wurm +1 [RTR:206] Trostani, Selesnya's Voice +4 [THS:152] Boon Satyr +7 [UNH:136] Plains +4 [THS:32] Soldier of the Pantheon +4 [DGM:114] Voice of Resurgence +SB: 2 [M14:1] Ajani, Caller of the Pride +SB: 4 [THS:15] Glare of Heresy +SB: 4 [THS:159] Hunt the Hunter +SB: 1 [RTR:19] Rootborn Defenses +SB: 1 [GTC:13] Gideon, Champion of Justice +SB: 1 [RTR:206] Trostani, Selesnya's Voice +SB: 2 [M14:195] Scavenging Ooze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..7d394d2ca5d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,35 @@ +2 [MBS:43] Go for the Throat +2 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +1 [ISD:78] Snapcaster Mage +4 [ISD:55] Forbidden Alchemy +1 [ISD:122] Unburial Rites +2 [AVR:226] Cavern of Souls +4 [ISD:242] Isolated Chapel +2 [M14:215] Ratchet Bomb +1 [M14:96] Doom Blade +4 [DKA:12] Lingering Souls +3 [M12:12] Day of Judgment +2 [ISD:96] Dead Weight +3 [UNH:136] Plains +4 [M12:72] Phantasmal Image +2 [UNH:137] Island +3 [M12:73] Ponder +2 [UNH:138] Swamp +1 [DKA:158] Vault of the Archangel +1 [C14:298] Ghost Quarter +1 [SOM:229] Seachrome Coast +2 [C14:295] Evolving Wilds +3 [C14:91] Sun Titan +4 [SOM:226] Darkslick Shores +2 [M13:22] Oblivion Ring +SB: 1 [MBS:5] Divine Offering +SB: 1 [C14:298] Ghost Quarter +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:51] Dissipate +SB: 3 [M12:11] Celestial Purge +SB: 1 [NPH:130] Batterskull +SB: 1 [M12:12] Day of Judgment +SB: 3 [C13:249] Nihil Spellbomb +SB: 1 [M15:71] Negate +SB: 2 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..6df9f32520a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,30 @@ +2 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +4 [ISD:55] Forbidden Alchemy +3 [C14:298] Ghost Quarter +1 [ISD:122] Unburial Rites +4 [ISD:242] Isolated Chapel +3 [M14:215] Ratchet Bomb +2 [C14:295] Evolving Wilds +4 [SOM:229] Seachrome Coast +1 [NPH:9] Elesh Norn, Grand Cenobite +3 [C14:91] Sun Titan +1 [SOM:226] Darkslick Shores +4 [DKA:12] Lingering Souls +3 [M13:22] Oblivion Ring +3 [M12:12] Day of Judgment +2 [ISD:96] Dead Weight +4 [UNH:136] Plains +4 [M12:72] Phantasmal Image +3 [UNH:137] Island +3 [M12:73] Ponder +1 [UNH:138] Swamp +SB: 1 [MBS:21] Consecrated Sphinx +SB: 2 [AVR:226] Cavern of Souls +SB: 2 [M12:11] Celestial Purge +SB: 1 [M12:12] Day of Judgment +SB: 3 [C13:249] Nihil Spellbomb +SB: 3 [M12:40] Timely Reinforcements +SB: 2 [M15:71] Negate +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..aeeee3c861d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,30 @@ +1 [MBS:21] Consecrated Sphinx +4 [M13:225] Glacial Fortress +3 [NPH:4] Blade Splicer +1 [M13:223] Drowned Catacomb +4 [ISD:55] Forbidden Alchemy +3 [C14:298] Ghost Quarter +2 [ISD:122] Unburial Rites +4 [ISD:242] Isolated Chapel +2 [M14:215] Ratchet Bomb +4 [SOM:229] Seachrome Coast +1 [C14:283] Wurmcoil Engine +3 [C14:91] Sun Titan +4 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +3 [M13:22] Oblivion Ring +3 [M12:12] Day of Judgment +3 [UNH:136] Plains +2 [M12:72] Phantasmal Image +2 [UNH:137] Island +2 [ISD:83] Think Twice +1 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [C14:283] Wurmcoil Engine +SB: 2 [M15:51] Dissipate +SB: 2 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 2 [C13:249] Nihil Spellbomb +SB: 3 [M12:40] Timely Reinforcements +SB: 2 [ISD:94] Curse of Death's Hold diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..38cfcdb9a18 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Solar Flare TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,31 @@ +1 [MBS:21] Consecrated Sphinx +4 [M13:225] Glacial Fortress +4 [M13:223] Drowned Catacomb +3 [ISD:78] Snapcaster Mage +4 [ISD:55] Forbidden Alchemy +2 [ISD:122] Unburial Rites +3 [ISD:242] Isolated Chapel +3 [SOM:229] Seachrome Coast +2 [C14:283] Wurmcoil Engine +2 [C14:91] Sun Titan +3 [M14:96] Doom Blade +2 [SOM:226] Darkslick Shores +4 [M13:22] Oblivion Ring +2 [M12:12] Day of Judgment +4 [UNH:136] Plains +2 [M12:72] Phantasmal Image +5 [UNH:137] Island +3 [ISD:83] Think Twice +3 [M12:40] Timely Reinforcements +1 [UNH:138] Swamp +3 [M12:63] Mana Leak +SB: 2 [NPH:74] Surgical Extraction +SB: 1 [MBS:5] Divine Offering +SB: 1 [M14:96] Doom Blade +SB: 2 [M15:51] Dissipate +SB: 3 [M12:11] Celestial Purge +SB: 1 [M12:12] Day of Judgment +SB: 1 [M12:40] Timely Reinforcements +SB: 1 [M15:71] Negate +SB: 2 [M12:52] Flashfreeze +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Spirit Delver TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Spirit Delver TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..41b30259ca4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Spirit Delver TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,33 @@ +2 [C13:42] Dungeon Geists +3 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +4 [DKA:136] Drogskol Captain +1 [MBS:5] Divine Offering +1 [NPH:86] Gut Shot +2 [C14:295] Evolving Wilds +4 [SOM:229] Seachrome Coast +1 [BNG:25] Revoke Existence +4 [NPH:35] Gitaxian Probe +4 [SOM:226] Darkslick Shores +4 [NPH:48] Vapor Snag +4 [DKA:12] Lingering Souls +2 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +3 [M12:72] Phantasmal Image +4 [ISD:51] Delver of Secrets +5 [UNH:137] Island +4 [M12:73] Ponder +1 [UNH:138] Swamp +2 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 2 [NPH:74] Surgical Extraction +SB: 2 [C13:42] Dungeon Geists +SB: 2 [NPH:86] Gut Shot +SB: 1 [M12:13] Demystify +SB: 1 [BNG:25] Revoke Existence +SB: 1 [NPH:57] Dismember +SB: 1 [M15:51] Dissipate +SB: 1 [M12:11] Celestial Purge +SB: 1 [M12:72] Phantasmal Image +SB: 1 [M12:63] Mana Leak +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Apr 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Apr 2015.mwDeck.dck new file mode 100644 index 00000000000..e076e268073 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Apr 2015.mwDeck.dck @@ -0,0 +1,36 @@ +2 [DTK:180] Deathmist Raptor +3 [DTK:181] Den Protector +4 [UNH:140] Forest +3 [JOU:165] Temple of Malady +2 [THS:107] Thoughtseize +4 [M15:198] Satyr Wayfinder +4 [M15:244] Llanowar Wastes +1 [KTK:144] Rattleclaw Mystic +1 [DTK:124] Ultimate Price +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [M15:249] Yavimaya Coast +1 [DTK:120] Sidisi, Undead Vizier +1 [UNH:137] Island +4 [THS:180] Sylvan Caryatid +2 [UNH:138] Swamp +2 [THS:110] Whip of Erebos +1 [KTK:239] Polluted Delta +4 [KTK:238] Opulent Palace +1 [KTK:234] Frontier Bivouac +1 [DTK:216] Dragonlord Atarka +2 [M15:178] Hornet Queen +4 [KTK:199] Sidisi, Brood Tyrant +4 [BNG:119] Courser of Kruphix +3 [KTK:81] Murderous Cut +3 [THS:90] Hero's Downfall +1 [JOU:163] Mana Confluence +SB: 2 [BNG:61] Bile Blight +SB: 1 [DTK:216] Dragonlord Atarka +SB: 1 [DTK:70] Profaner of the Dead +SB: 1 [C14:213] Reclamation Sage +SB: 1 [M15:115] Soul of Innistrad +SB: 2 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [THS:167] Nylea's Disciple +SB: 2 [FRF:65] Crux of Fate +SB: 1 [THS:107] Thoughtseize +SB: 3 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..f23ee79b2d2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,30 @@ +1 [THS:226] Temple of Mystery +3 [THS:110] Whip of Erebos +3 [UNH:140] Forest +2 [JOU:165] Temple of Malady +1 [JOU:154] Pharika, God of Affliction +3 [JOU:66] Doomwake Giant +2 [KTK:239] Polluted Delta +4 [KTK:238] Opulent Palace +3 [THS:107] Thoughtseize +4 [M15:198] Satyr Wayfinder +4 [M15:244] Llanowar Wastes +3 [M15:178] Hornet Queen +4 [KTK:199] Sidisi, Brood Tyrant +4 [BNG:119] Courser of Kruphix +4 [KTK:81] Murderous Cut +1 [M15:115] Soul of Innistrad +2 [M15:249] Yavimaya Coast +1 [C14:295] Evolving Wilds +3 [THS:90] Hero's Downfall +1 [JOU:163] Mana Confluence +1 [UNH:137] Island +4 [THS:180] Sylvan Caryatid +2 [UNH:138] Swamp +SB: 2 [M15:177] Hornet Nest +SB: 2 [C14:213] Reclamation Sage +SB: 3 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [JOU:154] Pharika, God of Affliction +SB: 2 [KTK:204] Sultai Charm +SB: 2 [BNG:65] Drown in Sorrow +SB: 3 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..e7d60fa99a9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,30 @@ +1 [THS:226] Temple of Mystery +3 [THS:110] Whip of Erebos +3 [UNH:140] Forest +2 [JOU:165] Temple of Malady +2 [JOU:66] Doomwake Giant +2 [KTK:239] Polluted Delta +1 [KTK:248] Windswept Heath +4 [KTK:238] Opulent Palace +4 [M15:198] Satyr Wayfinder +2 [BNG:61] Bile Blight +4 [M15:244] Llanowar Wastes +3 [M15:178] Hornet Queen +4 [KTK:199] Sidisi, Brood Tyrant +4 [BNG:119] Courser of Kruphix +4 [KTK:81] Murderous Cut +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [M15:249] Yavimaya Coast +3 [THS:90] Hero's Downfall +3 [FRF:87] Tasigur, the Golden Fang +1 [FRF:56] Torrent Elemental +1 [UNH:137] Island +3 [THS:180] Sylvan Caryatid +3 [UNH:138] Swamp +SB: 2 [BNG:61] Bile Blight +SB: 2 [C14:213] Reclamation Sage +SB: 2 [M15:117] Stain the Mind +SB: 3 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [FRF:56] Torrent Elemental +SB: 2 [BNG:65] Drown in Sorrow +SB: 3 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Jan 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Jan 2015.mwDeck.dck new file mode 100644 index 00000000000..a12c68806da --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Sultai Whip TDtB ST Jan 2015.mwDeck.dck @@ -0,0 +1,35 @@ +1 [THS:226] Temple of Mystery +3 [UNH:140] Forest +2 [JOU:165] Temple of Malady +2 [JOU:66] Doomwake Giant +3 [THS:107] Thoughtseize +4 [M15:198] Satyr Wayfinder +4 [M15:244] Llanowar Wastes +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [M15:249] Yavimaya Coast +1 [UNH:137] Island +4 [THS:180] Sylvan Caryatid +2 [UNH:138] Swamp +3 [THS:110] Whip of Erebos +1 [JOU:154] Pharika, God of Affliction +2 [KTK:239] Polluted Delta +4 [KTK:238] Opulent Palace +1 [C14:213] Reclamation Sage +2 [M15:178] Hornet Queen +4 [KTK:199] Sidisi, Brood Tyrant +4 [BNG:119] Courser of Kruphix +4 [KTK:81] Murderous Cut +1 [M15:115] Soul of Innistrad +1 [C14:295] Evolving Wilds +3 [THS:90] Hero's Downfall +1 [JOU:163] Mana Confluence +SB: 3 [BNG:61] Bile Blight +SB: 1 [C14:213] Reclamation Sage +SB: 1 [C14:158] Read the Bones +SB: 1 [M15:115] Soul of Innistrad +SB: 2 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [BNG:149] Kiora, the Crashing Wave +SB: 1 [BNG:65] Drown in Sorrow +SB: 1 [THS:107] Thoughtseize +SB: 2 [KTK:37] Disdainful Stroke +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..1df40b7a506 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,20 @@ +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +2 [SOM:10] Glint Hawk +4 [M11:214] Steel Overseer +2 [NPH:159] Spellskite +4 [M15:223] Ornithopter +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +12 [UNH:136] Plains +4 [SOM:179] Mox Opal +2 [MBS:144] Contested War Zone +6 [SOM:156] Glint Hawk Idol +SB: 2 [WWK:17] Refraction Trap +SB: 3 [NPH:78] Act of Aggression +SB: 4 [WWK:11] Kor Firewalker +SB: 3 [NPH:155] Shrine of Loyal Legions +SB: 3 [NPH:159] Spellskite +SB: 1 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..808ce67d003 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,23 @@ +2 [SOM:154] Etched Champion +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +3 [NPH:155] Shrine of Loyal Legions +2 [NPH:159] Spellskite +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +1 [NPH:57] Dismember +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +17 [UNH:136] Plains +3 [SOM:179] Mox Opal +4 [MBS:8] Hero of Bladehold +4 [SOM:156] Glint Hawk Idol +SB: 1 [SOM:154] Etched Champion +SB: 1 [M12:16] Gideon Jura +SB: 2 [NPH:57] Dismember +SB: 2 [BNG:25] Revoke Existence +SB: 1 [NPH:155] Shrine of Loyal Legions +SB: 1 [M12:11] Celestial Purge +SB: 3 [M13:22] Oblivion Ring +SB: 1 [NPH:159] Spellskite +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..808ce67d003 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,23 @@ +2 [SOM:154] Etched Champion +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +3 [NPH:155] Shrine of Loyal Legions +2 [NPH:159] Spellskite +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +1 [NPH:57] Dismember +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +17 [UNH:136] Plains +3 [SOM:179] Mox Opal +4 [MBS:8] Hero of Bladehold +4 [SOM:156] Glint Hawk Idol +SB: 1 [SOM:154] Etched Champion +SB: 1 [M12:16] Gideon Jura +SB: 2 [NPH:57] Dismember +SB: 2 [BNG:25] Revoke Existence +SB: 1 [NPH:155] Shrine of Loyal Legions +SB: 1 [M12:11] Celestial Purge +SB: 3 [M13:22] Oblivion Ring +SB: 1 [NPH:159] Spellskite +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..1b8217208c5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,19 @@ +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +3 [SOM:10] Glint Hawk +4 [M11:214] Steel Overseer +4 [M15:223] Ornithopter +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +11 [UNH:136] Plains +4 [SOM:179] Mox Opal +3 [MBS:144] Contested War Zone +3 [NPH:19] Porcelain Legionnaire +4 [SOM:156] Glint Hawk Idol +SB: 4 [WWK:11] Kor Firewalker +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 2 [M12:11] Celestial Purge +SB: 2 [NPH:38] Mental Misstep +SB: 3 [NPH:159] Spellskite diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..ec8cd221607 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,19 @@ +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +4 [M11:214] Steel Overseer +4 [NPH:137] Hex Parasite +4 [M15:223] Ornithopter +2 [M15:225] Phyrexian Revoker +4 [NPH:76] Vault Skirge +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +16 [UNH:136] Plains +3 [SOM:179] Mox Opal +3 [NPH:19] Porcelain Legionnaire +4 [SOM:156] Glint Hawk Idol +SB: 2 [MBS:10] Leonin Relic-Warder +SB: 2 [M15:225] Phyrexian Revoker +SB: 3 [CMD:17] Journey to Nowhere +SB: 2 [NPH:162] Torpor Orb +SB: 3 [SOM:218] Tumble Magnet +SB: 3 [WWK:11] Kor Firewalker diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Nov 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Nov 2011.mwDeck.dck new file mode 100644 index 00000000000..b17674026fe --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Nov 2011.mwDeck.dck @@ -0,0 +1,22 @@ +4 [SOM:154] Etched Champion +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +4 [SOM:10] Glint Hawk +1 [ISD:23] Mikaeus, the Lunarch +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +4 [SOM:229] Seachrome Coast +4 [MBS:145] Inkmoth Nexus +2 [ISD:244] Moorland Haunt +4 [MBS:131] Signal Pest +9 [UNH:136] Plains +4 [SOM:179] Mox Opal +4 [SOM:156] Glint Hawk Idol +4 [SOM:189] Origin Spellbomb +SB: 2 [NPH:57] Dismember +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 1 [M13:225] Glacial Fortress +SB: 1 [M13:22] Oblivion Ring +SB: 3 [NPH:159] Spellskite +SB: 3 [MBS:8] Hero of Bladehold +SB: 1 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..cf344f97f0b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,21 @@ +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +3 [NPH:155] Shrine of Loyal Legions +1 [NPH:159] Spellskite +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +2 [NPH:45] Spined Thopter +4 [MBS:145] Inkmoth Nexus +2 [M13:22] Oblivion Ring +4 [MBS:131] Signal Pest +17 [UNH:136] Plains +3 [SOM:179] Mox Opal +4 [MBS:8] Hero of Bladehold +4 [SOM:156] Glint Hawk Idol +SB: 2 [ISD:23] Mikaeus, the Lunarch +SB: 1 [M12:16] Gideon Jura +SB: 2 [NPH:57] Dismember +SB: 2 [BNG:25] Revoke Existence +SB: 4 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 3 [NPH:159] Spellskite diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..28535e70f73 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tempered Steel TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,19 @@ +4 [SOM:174] Memnite +4 [SOM:24] Tempered Steel +2 [SOM:10] Glint Hawk +4 [M11:214] Steel Overseer +4 [M15:223] Ornithopter +4 [NPH:76] Vault Skirge +4 [NPH:7] Dispatch +4 [MBS:145] Inkmoth Nexus +4 [MBS:131] Signal Pest +11 [UNH:136] Plains +4 [SOM:179] Mox Opal +3 [MBS:144] Contested War Zone +3 [NPH:19] Porcelain Legionnaire +5 [SOM:156] Glint Hawk Idol +SB: 2 [WWK:17] Refraction Trap +SB: 4 [WWK:11] Kor Firewalker +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 2 [UNH:136] Plains +SB: 3 [NPH:159] Spellskite diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Dec 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Dec 2014.mwDeck.dck new file mode 100644 index 00000000000..6fb5b07ee9a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Dec 2014.mwDeck.dck @@ -0,0 +1,31 @@ +1 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +3 [UNH:140] Forest +2 [KTK:208] Temur Charm +4 [KTK:249] Wooded Foothills +2 [KTK:56] Stubborn Denial +2 [KTK:106] Crater's Claws +4 [KTK:234] Frontier Bivouac +2 [UNH:139] Mountain +3 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +4 [KTK:144] Rattleclaw Mystic +1 [M15:246] Shivan Reef +4 [KTK:197] Savage Knuckleblade +4 [M15:249] Yavimaya Coast +2 [JOU:164] Temple of Epiphany +3 [JOU:163] Mana Confluence +4 [THS:172] Polukranos, World Eater +3 [THS:152] Boon Satyr +4 [C14:191] Elvish Mystic +SB: 2 [KTK:196] Sagu Mauler +SB: 1 [M15:135] Circle of Flame +SB: 1 [M15:169] Back to Nature +SB: 1 [KTK:208] Temur Charm +SB: 2 [THS:112] Anger of the Gods +SB: 1 [KTK:42] Icy Blast +SB: 1 [BNG:143] Unravel the AEther +SB: 1 [JOU:140] Setessan Tactics +SB: 2 [M15:75] Polymorphist's Jest +SB: 2 [KTK:37] Disdainful Stroke +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Nov 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Nov 2014.mwDeck.dck new file mode 100644 index 00000000000..55154046e54 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Temur Aggro TDtB ST Nov 2014.mwDeck.dck @@ -0,0 +1,29 @@ +1 [THS:226] Temple of Mystery +3 [UNH:140] Forest +2 [KTK:208] Temur Charm +1 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:99] Ashcloud Phoenix +4 [KTK:249] Wooded Foothills +4 [KTK:106] Crater's Claws +4 [KTK:134] Heir of the Wilds +4 [KTK:234] Frontier Bivouac +2 [UNH:139] Mountain +3 [M15:155] Lightning Strike +4 [KTK:144] Rattleclaw Mystic +1 [M15:246] Shivan Reef +4 [KTK:197] Savage Knuckleblade +4 [M15:249] Yavimaya Coast +2 [JOU:164] Temple of Epiphany +3 [JOU:163] Mana Confluence +3 [THS:172] Polukranos, World Eater +4 [THS:152] Boon Satyr +3 [C14:191] Elvish Mystic +SB: 1 [M15:155] Lightning Strike +SB: 1 [KTK:100] Barrage of Boulders +SB: 3 [THS:159] Hunt the Hunter +SB: 2 [JOU:103] Magma Spray +SB: 1 [M15:169] Back to Nature +SB: 1 [KTK:208] Temur Charm +SB: 1 [KTK:97] Arc Lightning +SB: 3 [KTK:56] Stubborn Denial +SB: 2 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Thalia WW TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Thalia WW TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..da61f5d5180 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Thalia WW TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,28 @@ +3 [MBS:10] Leonin Relic-Warder +2 [C13:11] Fiend Hunter +2 [NPH:161] Sword of War and Peace +1 [M12:3] Angelic Destiny +4 [M13:225] Glacial Fortress +4 [SOM:229] Seachrome Coast +3 [ISD:244] Moorland Haunt +2 [M13:22] Oblivion Ring +4 [M12:23] Honor of the Pure +12 [UNH:136] Plains +3 [MBS:14] Mirran Crusader +3 [DKA:24] Thalia, Guardian of Thraben +1 [UNH:137] Island +4 [ISD:6] Champion of the Parish +4 [MBS:8] Hero of Bladehold +4 [DKA:8] Gather the Townsfolk +4 [CNS:69] Doomed Traveler +SB: 1 [MBS:10] Leonin Relic-Warder +SB: 1 [C13:11] Fiend Hunter +SB: 2 [MBS:5] Divine Offering +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [M12:3] Angelic Destiny +SB: 1 [NPH:57] Dismember +SB: 2 [ISD:213] Geist of Saint Traft +SB: 1 [M13:22] Oblivion Ring +SB: 2 [M12:12] Day of Judgment +SB: 1 [MBS:14] Mirran Crusader +SB: 2 [M12:63] Mana Leak diff --git a/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Feb 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Feb 2013.mwDeck.dck new file mode 100644 index 00000000000..f9763f12f51 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Feb 2013.mwDeck.dck @@ -0,0 +1,28 @@ +1 [AVR:32] Restoration Angel +2 [C14:88] Silverblade Paladin +4 [GTC:215] Boros Reckoner +4 [GTC:150] Cartel Aristocrat +1 [DKA:158] Vault of the Archangel +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +3 [AVR:226] Cavern of Souls +4 [ISD:242] Isolated Chapel +2 [C14:163] Skirsdag High Priest +2 [AVR:166] Zealous Conscripts +3 [M13:96] Knight of Infamy +4 [GTC:245] Sacred Foundry +2 [DKA:12] Lingering Souls +3 [UNH:136] Plains +4 [GTC:242] Godless Shrine +1 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +4 [GTC:185] Orzhov Charm +4 [CNS:69] Doomed Traveler +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 3 [C14:167] Tragic Slip +SB: 1 [C14:163] Skirsdag High Priest +SB: 2 [C14:172] Blasphemous Act +SB: 2 [DKA:12] Lingering Souls +SB: 2 [RTR:18] Rest in Peace +SB: 2 [DKA:142] Sorin, Lord of Innistrad +SB: 1 [C14:79] Mentor of the Meek diff --git a/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..f9763f12f51 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/The Aristocrats TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,28 @@ +1 [AVR:32] Restoration Angel +2 [C14:88] Silverblade Paladin +4 [GTC:215] Boros Reckoner +4 [GTC:150] Cartel Aristocrat +1 [DKA:158] Vault of the Archangel +4 [RTR:238] Blood Crypt +4 [DKA:138] Falkenrath Aristocrat +3 [AVR:226] Cavern of Souls +4 [ISD:242] Isolated Chapel +2 [C14:163] Skirsdag High Priest +2 [AVR:166] Zealous Conscripts +3 [M13:96] Knight of Infamy +4 [GTC:245] Sacred Foundry +2 [DKA:12] Lingering Souls +3 [UNH:136] Plains +4 [GTC:242] Godless Shrine +1 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +4 [GTC:185] Orzhov Charm +4 [CNS:69] Doomed Traveler +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 3 [C14:167] Tragic Slip +SB: 1 [C14:163] Skirsdag High Priest +SB: 2 [C14:172] Blasphemous Act +SB: 2 [DKA:12] Lingering Souls +SB: 2 [RTR:18] Rest in Peace +SB: 2 [DKA:142] Sorin, Lord of Innistrad +SB: 1 [C14:79] Mentor of the Meek diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Tokens TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Tokens TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..ff5977a4fed --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Tokens TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,33 @@ +2 [RTR:82] Ultimate Price +2 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +1 [RTR:150] Collective Blessing +2 [M13:174] Garruk, Primal Hunter +1 [DKA:158] Vault of the Archangel +4 [RTR:243] Overgrown Tomb +3 [C13:211] Selesnya Charm +3 [M13:160] Arbor Elf +4 [ISD:170] Avacyn's Pilgrim +4 [M13:193] Thragtusk +1 [ISD:181] Garruk Relentless +3 [ISD:242] Isolated Chapel +4 [RTR:248] Temple Garden +4 [CNS:72] Intangible Virtue +1 [ISD:115] Sever the Bloodline +3 [C14:80] Midnight Haunting +4 [DKA:12] Lingering Souls +3 [AVR:169] Borderland Ranger +1 [UNH:136] Plains +3 [ISD:239] Gavony Township +2 [DKA:142] Sorin, Lord of Innistrad +1 [UNH:138] Swamp +SB: 1 [RTR:82] Ultimate Price +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [AVR:32] Restoration Angel +SB: 1 [ISD:32] Slayer of the Wicked +SB: 1 [ISD:181] Garruk Relentless +SB: 3 [RTR:148] Centaur Healer +SB: 1 [ISD:115] Sever the Bloodline +SB: 1 [AVR:210] Sigarda, Host of Herons +SB: 1 [M13:20] Intrepid Hero +SB: 3 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Torpor Tezz TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Torpor Tezz TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..2c0a5ad0d16 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Torpor Tezz TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,30 @@ +3 [MBS:97] Tezzeret, Agent of Bolas +2 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +4 [NPH:162] Torpor Orb +4 [M13:223] Drowned Catacomb +3 [ROE:115] Inquisition of Kozilek +4 [C14:239] Everflowing Chalice +2 [KTK:69] Despise +1 [ROE:100] Consume the Meek +3 [C14:313] Tectonic Edge +1 [C14:136] Black Sun's Zenith +4 [M11:70] Preordain +2 [ZEN:87] Disfigure +3 [SOM:218] Tumble Magnet +1 [C14:283] Wurmcoil Engine +2 [MBS:145] Inkmoth Nexus +2 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +2 [WWK:31] Jace, the Mind Sculptor +4 [UNH:137] Island +3 [UNH:138] Swamp +2 [M12:63] Mana Leak +SB: 1 [C14:136] Black Sun's Zenith +SB: 2 [C14:145] Grave Titan +SB: 2 [M11:58] Jace Beleren +SB: 2 [ZEN:87] Disfigure +SB: 1 [ROE:115] Inquisition of Kozilek +SB: 1 [ROE:100] Consume the Meek +SB: 4 [M12:52] Flashfreeze +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Trinket UB Control TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Trinket UB Control TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..c856bb28ad5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Trinket UB Control TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,32 @@ +1 [SOM:69] Memoricide +3 [SOM:48] Trinket Mage +2 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +1 [SOM:46] Stoic Rebuttal +2 [ZEN:220] Misty Rainforest +1 [M11:202] Brittle Effigy +4 [M13:223] Drowned Catacomb +1 [ROE:101] Consuming Vapors +2 [C14:239] Everflowing Chalice +1 [ROE:100] Consume the Meek +3 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +1 [ZEN:229] Verdant Catacombs +4 [M11:70] Preordain +3 [C14:112] Frost Titan +4 [M14:96] Doom Blade +2 [SOM:226] Darkslick Shores +4 [WWK:31] Jace, the Mind Sculptor +1 [M14:209] Elixir of Immortality +6 [UNH:137] Island +3 [UNH:138] Swamp +1 [M15:71] Negate +4 [M12:63] Mana Leak +SB: 2 [ZEN:67] Spell Pierce +SB: 2 [SOM:69] Memoricide +SB: 1 [M11:58] Jace Beleren +SB: 4 [ZEN:87] Disfigure +SB: 1 [RTR:36] Dispel +SB: 1 [C13:249] Nihil Spellbomb +SB: 2 [M15:71] Negate +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..bbaf0fbdc67 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,32 @@ +3 [MBS:43] Go for the Throat +1 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +1 [SOM:46] Stoic Rebuttal +2 [ZEN:70] Spreading Seas +4 [M13:223] Drowned Catacomb +3 [ROE:115] Inquisition of Kozilek +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +2 [C14:136] Black Sun's Zenith +4 [M11:70] Preordain +1 [ZEN:219] Marsh Flats +3 [C14:145] Grave Titan +1 [M15:103] Liliana Vess +1 [ZEN:223] Scalding Tarn +2 [SOM:218] Tumble Magnet +1 [C14:283] Wurmcoil Engine +4 [SOM:226] Darkslick Shores +2 [M14:97] Duress +4 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +3 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 1 [SOM:175] Mimic Vat +SB: 2 [SOM:69] Memoricide +SB: 1 [M11:58] Jace Beleren +SB: 2 [SOM:194] Precursor Golem +SB: 1 [SOM:46] Stoic Rebuttal +SB: 3 [ZEN:87] Disfigure +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M14:96] Doom Blade +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..b9acd187fc7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,34 @@ +1 [MBS:43] Go for the Throat +2 [MBS:21] Consecrated Sphinx +4 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +1 [M11:226] Mystifying Maze +4 [M13:223] Drowned Catacomb +4 [ROE:115] Inquisition of Kozilek +1 [KTK:69] Despise +1 [ROE:100] Consume the Meek +1 [NPH:1] Karn Liberated +4 [C14:313] Tectonic Edge +1 [C14:115] Into the Roil +1 [C14:136] Black Sun's Zenith +4 [M11:70] Preordain +2 [C14:145] Grave Titan +1 [M15:103] Liliana Vess +1 [NPH:57] Dismember +3 [C14:271] Solemn Simulacrum +3 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +4 [UNH:137] Island +5 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 1 [NPH:71] Praetor's Grasp +SB: 1 [C14:136] Black Sun's Zenith +SB: 1 [SOM:69] Memoricide +SB: 1 [NPH:74] Surgical Extraction +SB: 2 [ZEN:87] Disfigure +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [SOM:53] Volition Reins +SB: 2 [M14:97] Duress +SB: 1 [KTK:69] Despise +SB: 1 [CNS:201] Peace Strider +SB: 3 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..d2fafcbdcdb --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,32 @@ +1 [MBS:43] Go for the Throat +2 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +2 [SOM:46] Stoic Rebuttal +4 [ZEN:70] Spreading Seas +1 [ZEN:220] Misty Rainforest +4 [M13:223] Drowned Catacomb +4 [ROE:115] Inquisition of Kozilek +4 [C14:313] Tectonic Edge +2 [C14:136] Black Sun's Zenith +1 [ZEN:229] Verdant Catacombs +4 [M11:70] Preordain +3 [C14:145] Grave Titan +2 [M14:215] Ratchet Bomb +2 [ZEN:87] Disfigure +1 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +3 [WWK:31] Jace, the Mind Sculptor +5 [UNH:137] Island +3 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 1 [ZEN:67] Spell Pierce +SB: 1 [C14:136] Black Sun's Zenith +SB: 1 [MBS:43] Go for the Throat +SB: 2 [SOM:69] Memoricide +SB: 1 [M11:58] Jace Beleren +SB: 2 [SOM:194] Precursor Golem +SB: 1 [ROE:59] Deprive +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [M14:97] Duress +SB: 1 [WWK:31] Jace, the Mind Sculptor +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2015.mwDeck.dck new file mode 100644 index 00000000000..4691909f7e0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Feb 2015.mwDeck.dck @@ -0,0 +1,29 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +2 [THS:188] Ashiok, Nightmare Weaver +4 [KTK:239] Polluted Delta +4 [KTK:36] Dig Through Time +1 [KTK:233] Flooded Strand +4 [FRF:168] Dismal Backwater +4 [KTK:37] Disdainful Stroke +1 [KTK:49] Pearl Lake Ancient +4 [BNG:61] Bile Blight +3 [M15:245] Radiant Fountain +1 [KTK:230] Bloodstained Mire +1 [M15:224] Perilous Vault +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [FRF:1] Ugin, the Spirit Dragon +4 [THS:90] Hero's Downfall +2 [FRF:65] Crux of Fate +3 [M15:63] Jace's Ingenuity +1 [JOU:82] Silence the Believers +5 [UNH:137] Island +5 [UNH:138] Swamp +SB: 1 [M15:224] Perilous Vault +SB: 1 [KTK:81] Murderous Cut +SB: 1 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [FRF:65] Crux of Fate +SB: 2 [FRF:87] Tasigur, the Golden Fang +SB: 3 [BNG:65] Drown in Sorrow +SB: 4 [THS:107] Thoughtseize +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Mar 2015.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Mar 2015.mwDeck.dck new file mode 100644 index 00000000000..a538bd2a69a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Mar 2015.mwDeck.dck @@ -0,0 +1,31 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +2 [THS:188] Ashiok, Nightmare Weaver +4 [KTK:239] Polluted Delta +1 [KTK:238] Opulent Palace +4 [KTK:36] Dig Through Time +1 [KTK:233] Flooded Strand +4 [FRF:168] Dismal Backwater +2 [KTK:37] Disdainful Stroke +1 [KTK:49] Pearl Lake Ancient +4 [BNG:61] Bile Blight +3 [M15:245] Radiant Fountain +1 [KTK:230] Bloodstained Mire +1 [M15:224] Perilous Vault +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [FRF:1] Ugin, the Spirit Dragon +4 [THS:90] Hero's Downfall +2 [FRF:65] Crux of Fate +3 [M15:63] Jace's Ingenuity +1 [JOU:82] Silence the Believers +5 [UNH:137] Island +4 [UNH:138] Swamp +2 [DTK:65] Negate +SB: 2 [M15:224] Perilous Vault +SB: 1 [M15:225] Phyrexian Revoker +SB: 1 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [THS:100] Pharika's Cure +SB: 2 [FRF:87] Tasigur, the Golden Fang +SB: 3 [BNG:65] Drown in Sorrow +SB: 4 [THS:107] Thoughtseize +SB: 1 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..91cf13cbe9a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,27 @@ +3 [MBS:21] Consecrated Sphinx +4 [M13:223] Drowned Catacomb +4 [ISD:78] Snapcaster Mage +1 [NPH:61] Geth's Verdict +2 [M14:122] Wring Flesh +3 [ISD:55] Forbidden Alchemy +1 [C14:136] Black Sun's Zenith +1 [C14:145] Grave Titan +2 [C14:298] Ghost Quarter +1 [C14:283] Wurmcoil Engine +4 [M15:51] Dissipate +4 [M14:96] Doom Blade +2 [ISD:245] Nephalia Drownyard +4 [SOM:226] Darkslick Shores +9 [UNH:137] Island +4 [ISD:83] Think Twice +6 [UNH:138] Swamp +1 [M15:71] Negate +4 [M12:63] Mana Leak +SB: 1 [M14:122] Wring Flesh +SB: 1 [C14:136] Black Sun's Zenith +SB: 3 [M14:215] Ratchet Bomb +SB: 2 [ISD:245] Nephalia Drownyard +SB: 1 [C13:249] Nihil Spellbomb +SB: 3 [M12:72] Phantasmal Image +SB: 3 [NPH:159] Spellskite +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..bc1d20fa5a5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Control TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,30 @@ +2 [MBS:21] Consecrated Sphinx +3 [MBS:43] Go for the Throat +4 [M11:58] Jace Beleren +4 [WWK:134] Creeping Tar Pit +4 [M13:223] Drowned Catacomb +4 [ROE:115] Inquisition of Kozilek +1 [KTK:69] Despise +1 [NPH:1] Karn Liberated +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +1 [C14:136] Black Sun's Zenith +4 [M11:70] Preordain +2 [C14:145] Grave Titan +1 [M15:103] Liliana Vess +1 [NPH:74] Surgical Extraction +3 [C14:271] Solemn Simulacrum +1 [M14:96] Doom Blade +4 [SOM:226] Darkslick Shores +5 [UNH:137] Island +5 [UNH:138] Swamp +4 [M12:63] Mana Leak +SB: 1 [SOM:69] Memoricide +SB: 1 [NPH:74] Surgical Extraction +SB: 2 [NPH:162] Torpor Orb +SB: 1 [ZEN:87] Disfigure +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [C14:283] Wurmcoil Engine +SB: 4 [ZEN:83] Bloodghast +SB: 1 [M14:97] Duress +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Infect TDtB ST Apr 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Infect TDtB ST Apr 2011.mwDeck.dck new file mode 100644 index 00000000000..4d4729b550a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Infect TDtB ST Apr 2011.mwDeck.dck @@ -0,0 +1,25 @@ +4 [SOM:185] Necropede +2 [M11:58] Jace Beleren +1 [ROE:59] Deprive +4 [WWK:134] Creeping Tar Pit +2 [SOM:79] Skithiryx, the Blight Dragon +4 [MBS:50] Phyrexian Crusader +4 [M13:223] Drowned Catacomb +4 [ROE:115] Inquisition of Kozilek +1 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [SOM:218] Tumble Magnet +4 [MBS:145] Inkmoth Nexus +4 [SOM:226] Darkslick Shores +4 [UNH:137] Island +6 [UNH:138] Swamp +4 [SOM:144] Contagion Clasp +4 [M12:63] Mana Leak +SB: 1 [C14:115] Into the Roil +SB: 1 [MBS:43] Go for the Throat +SB: 1 [M11:58] Jace Beleren +SB: 3 [ZEN:87] Disfigure +SB: 3 [MBS:52] Phyrexian Vatmother +SB: 2 [M14:96] Doom Blade +SB: 2 [M14:97] Duress +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UB Zombi TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UB Zombi TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..957df3909a9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UB Zombi TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,18 @@ +4 [M13:223] Drowned Catacomb +4 [DKA:135] Diregraf Captain +4 [NPH:61] Geth's Verdict +4 [ISD:97] Diregraf Ghoul +4 [C14:167] Tragic Slip +4 [DKA:63] Geralf's Messenger +4 [C14:163] Skirsdag High Priest +3 [SOM:63] Fume Spitter +4 [DKA:64] Gravecrawler +4 [SOM:226] Darkslick Shores +3 [MBS:115] Mortarpod +4 [M12:72] Phantasmal Image +12 [UNH:138] Swamp +2 [ISD:105] Liliana of the Veil +SB: 4 [NPH:107] Corrosive Gale +SB: 4 [NPH:74] Surgical Extraction +SB: 4 [NPH:48] Vapor Snag +SB: 3 [NPH:19] Porcelain Legionnaire diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UG Fauna TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UG Fauna TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..81b9bb3589b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UG Fauna TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,24 @@ +6 [UNH:140] Forest +3 [CMD:157] Garruk Wildspeaker +4 [ZEN:220] Misty Rainforest +2 [ROE:201] Nest Invader +4 [M12:165] Birds of Paradise +4 [ROE:212] Vengevine +3 [C14:313] Tectonic Edge +4 [M11:172] Fauna Shaman +4 [ZEN:229] Verdant Catacombs +3 [C14:124] Sea Gate Oracle +3 [C14:112] Frost Titan +2 [ZEN:223] Scalding Tarn +4 [ZEN:168] Lotus Cobra +3 [WWK:31] Jace, the Mind Sculptor +6 [UNH:137] Island +1 [SOM:177] Molten-Tail Masticore +4 [M12:63] Mana Leak +SB: 1 [C13:134] Acidic Slime +SB: 2 [M13:67] Sleep +SB: 4 [ZEN:70] Spreading Seas +SB: 2 [SOM:53] Volition Reins +SB: 3 [M11:188] Obstinate Baloth +SB: 1 [ROE:211] Tajuru Preserver +SB: 2 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UR Exarch Twin TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UR Exarch Twin TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..6f82b89fc6c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UR Exarch Twin TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,26 @@ +2 [WWK:137] Halimar Depths +2 [ZEN:220] Misty Rainforest +2 [ZEN:211] Arid Mesa +4 [C13:37] Deceiver Exarch +4 [NPH:156] Shrine of Piercing Vision +4 [ROE:165] Splinter Twin +5 [UNH:139] Mountain +2 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +2 [NPH:57] Dismember +4 [NPH:35] Gitaxian Probe +4 [RTR:36] Dispel +1 [SOM:50] Twisted Image +2 [NPH:38] Mental Misstep +8 [UNH:137] Island +4 [M12:73] Ponder +2 [M12:63] Mana Leak +SB: 2 [NPH:116] Mutagenic Growth +SB: 2 [C14:98] Azure Mage +SB: 1 [KTK:120] Shatter +SB: 1 [NPH:38] Mental Misstep +SB: 3 [M12:145] Grim Lavamancer +SB: 2 [NPH:159] Spellskite +SB: 2 [M11:154] Pyroclasm +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..f338e415a7d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,24 @@ +2 [M11:58] Jace Beleren +2 [WWK:137] Halimar Depths +2 [NPH:159] Spellskite +2 [C14:315] Terramorphic Expanse +4 [C13:37] Deceiver Exarch +3 [NPH:156] Shrine of Piercing Vision +4 [ROE:165] Splinter Twin +6 [UNH:139] Mountain +3 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +4 [NPH:35] Gitaxian Probe +3 [RTR:36] Dispel +9 [UNH:137] Island +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [C14:115] Into the Roil +SB: 2 [ZEN:67] Spell Pierce +SB: 1 [M11:58] Jace Beleren +SB: 1 [ROE:59] Deprive +SB: 1 [MBS:61] Crush +SB: 4 [NPH:38] Mental Misstep +SB: 1 [NPH:159] Spellskite +SB: 4 [M12:52] Flashfreeze diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jun 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jun 2011.mwDeck.dck new file mode 100644 index 00000000000..0cc139005dc --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Jun 2011.mwDeck.dck @@ -0,0 +1,28 @@ +2 [M11:58] Jace Beleren +4 [C13:37] Deceiver Exarch +4 [ROE:165] Splinter Twin +4 [C14:313] Tectonic Edge +8 [UNH:139] Mountain +1 [C13:114] Inferno Titan +2 [ZEN:67] Spell Pierce +3 [C14:115] Into the Roil +1 [C14:124] Sea Gate Oracle +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +1 [NPH:57] Dismember +3 [NPH:35] Gitaxian Probe +4 [WWK:31] Jace, the Mind Sculptor +1 [NPH:38] Mental Misstep +10 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 1 [M12:151] Manic Vandal +SB: 1 [MBS:21] Consecrated Sphinx +SB: 1 [KTK:120] Shatter +SB: 2 [M12:128] Combust +SB: 1 [NPH:2] Apostle's Blessing +SB: 1 [C14:283] Wurmcoil Engine +SB: 1 [RTR:36] Dispel +SB: 1 [M15:63] Jace's Ingenuity +SB: 4 [M11:154] Pyroclasm +SB: 1 [M15:71] Negate +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..cb131d47bfe --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UR ExarchTwin TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,24 @@ +4 [WWK:137] Halimar Depths +3 [ZEN:220] Misty Rainforest +3 [ZEN:211] Arid Mesa +3 [M12:145] Grim Lavamancer +4 [C13:37] Deceiver Exarch +4 [NPH:156] Shrine of Piercing Vision +4 [ROE:165] Splinter Twin +5 [UNH:139] Mountain +2 [C14:115] Into the Roil +2 [ZEN:67] Spell Pierce +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +2 [NPH:35] Gitaxian Probe +4 [RTR:36] Dispel +3 [SOM:50] Twisted Image +5 [UNH:137] Island +4 [M12:73] Ponder +SB: 3 [NPH:116] Mutagenic Growth +SB: 1 [MBS:67] Into the Core +SB: 3 [WWK:81] Dragonmaster Outcast +SB: 1 [M12:145] Grim Lavamancer +SB: 2 [NPH:38] Mental Misstep +SB: 3 [ROE:146] Forked Bolt +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UR Snap-Burn TDtB ST Dec 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UR Snap-Burn TDtB ST Dec 2011.mwDeck.dck new file mode 100644 index 00000000000..c36eacaa251 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UR Snap-Burn TDtB ST Dec 2011.mwDeck.dck @@ -0,0 +1,24 @@ +3 [CNS:138] Brimstone Volley +2 [M12:146] Incinerate +3 [M12:145] Grim Lavamancer +4 [UNH:139] Mountain +4 [ISD:78] Snapcaster Mage +3 [M14:134] Chandra's Phoenix +2 [C13:242] Druidic Satchel +4 [NPH:86] Gut Shot +2 [NPH:43] Psychic Barrier +4 [SOM:225] Copperline Gorge +4 [ISD:51] Delver of Secrets +10 [UNH:137] Island +3 [ISD:139] Desperate Ravings +4 [M12:73] Ponder +4 [ISD:248] Sulfur Falls +4 [M12:63] Mana Leak +SB: 2 [NPH:88] Moltensteel Dragon +SB: 2 [NPH:38] Mental Misstep +SB: 2 [SOM:81] Arc Trail +SB: 1 [C14:229] Bonehoard +SB: 2 [NPH:159] Spellskite +SB: 1 [M15:71] Negate +SB: 3 [M12:52] Flashfreeze +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Blade TDtB ST Oct 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Blade TDtB ST Oct 2011.mwDeck.dck new file mode 100644 index 00000000000..53a2fc717bd --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Blade TDtB ST Oct 2011.mwDeck.dck @@ -0,0 +1,28 @@ +1 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +4 [NPH:4] Blade Splicer +2 [C14:298] Ghost Quarter +2 [MBS:138] Sword of Feast and Famine +4 [SOM:229] Seachrome Coast +4 [MBS:145] Inkmoth Nexus +3 [ISD:213] Geist of Saint Traft +1 [M15:51] Dissipate +4 [M13:22] Oblivion Ring +2 [M12:12] Day of Judgment +6 [UNH:136] Plains +3 [MBS:14] Mirran Crusader +5 [UNH:137] Island +1 [MBS:8] Hero of Bladehold +4 [ISD:83] Think Twice +2 [M12:40] Timely Reinforcements +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [C14:298] Ghost Quarter +SB: 3 [ISD:27] Purify the Grave +SB: 1 [M12:16] Gideon Jura +SB: 2 [M12:11] Celestial Purge +SB: 1 [M12:12] Day of Judgment +SB: 2 [ISD:40] Urgent Exorcism +SB: 1 [NPH:159] Spellskite +SB: 2 [M12:72] Phantasmal Image +SB: 2 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Aug 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Aug 2014.mwDeck.dck new file mode 100644 index 00000000000..366ee2642f5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Aug 2014.mwDeck.dck @@ -0,0 +1,32 @@ +1 [JOU:38] Font of Fortunes +4 [THS:47] Dissolve +2 [RTR:54] Syncopate +2 [M14:68] Quicken +2 [THS:227] Temple of Silence +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +3 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +1 [C13:275] Azorius Guildgate +2 [JOU:164] Temple of Epiphany +3 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +1 [M15:63] Jace's Ingenuity +2 [M15:52] Divination +1 [M14:209] Elixir of Immortality +5 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +1 [BNG:11] Fated Retribution +5 [UNH:137] Island +2 [THS:22] Last Breath +4 [BNG:163] Temple of Enlightenment +SB: 4 [JOU:18] Nyx-Fleece Ram +SB: 1 [GTC:6] Blind Obedience +SB: 1 [RTR:231] Pithing Needle +SB: 1 [JOU:7] Deicide +SB: 2 [BNG:5] Brimaz, King of Oreskos +SB: 1 [THS:49] Gainsay +SB: 2 [M14:5] Archangel of Thune +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..49d9e7644bf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,23 @@ +4 [WWK:133] Celestial Colonnade +3 [M11:58] Jace Beleren +4 [M13:225] Glacial Fortress +3 [M11:7] Baneslayer Angel +4 [CMD:37] Wall of Omens +4 [C14:69] Condemn +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [SOM:229] Seachrome Coast +1 [C14:91] Sun Titan +2 [SOM:53] Volition Reins +2 [WWK:31] Jace, the Mind Sculptor +3 [M12:12] Day of Judgment +6 [UNH:136] Plains +4 [UNH:137] Island +2 [M15:71] Negate +4 [M12:63] Mana Leak +SB: 4 [SOM:14] Leonin Arbiter +SB: 4 [ZEN:25] Luminarch Ascension +SB: 1 [M14:215] Ratchet Bomb +SB: 4 [WWK:11] Kor Firewalker +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2013.mwDeck.dck new file mode 100644 index 00000000000..3b8170f83c1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Dec 2013.mwDeck.dck @@ -0,0 +1,25 @@ +4 [THS:47] Dissolve +2 [RTR:54] Syncopate +2 [M14:68] Quicken +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +4 [C13:275] Azorius Guildgate +1 [M14:215] Ratchet Bomb +2 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +4 [M15:52] Divination +1 [M14:209] Elixir of Immortality +8 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +8 [UNH:137] Island +SB: 1 [GTC:6] Blind Obedience +SB: 1 [RTR:231] Pithing Needle +SB: 3 [M14:18] Fiendslayer Paladin +SB: 3 [THS:49] Gainsay +SB: 1 [M14:215] Ratchet Bomb +SB: 3 [THS:22] Last Breath +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Feb 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Feb 2014.mwDeck.dck new file mode 100644 index 00000000000..d8adbe4c367 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Feb 2014.mwDeck.dck @@ -0,0 +1,22 @@ +4 [THS:225] Temple of Deceit +4 [THS:47] Dissolve +3 [RTR:54] Syncopate +2 [THS:227] Temple of Silence +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +2 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +4 [C13:275] Azorius Guildgate +1 [DGM:11] AEtherling +3 [M14:228] Mutavault +4 [RTR:44] Jace, Architect of Thought +5 [UNH:136] Plains +3 [THS:9] Elspeth, Sun's Champion +5 [UNH:137] Island +4 [THS:22] Last Breath +SB: 3 [THS:49] Gainsay +SB: 4 [M14:5] Archangel of Thune +SB: 1 [C13:51] Opportunity +SB: 3 [THS:83] Dark Betrayal +SB: 4 [THS:32] Soldier of the Pantheon diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jan 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jan 2014.mwDeck.dck new file mode 100644 index 00000000000..17e8d66503d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jan 2014.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:47] Dissolve +2 [RTR:54] Syncopate +2 [M14:68] Quicken +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +3 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +4 [C13:275] Azorius Guildgate +1 [M14:215] Ratchet Bomb +2 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +4 [M15:52] Divination +1 [M14:209] Elixir of Immortality +8 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +8 [UNH:137] Island +1 [THS:22] Last Breath +SB: 1 [GTC:6] Blind Obedience +SB: 1 [THS:15] Glare of Heresy +SB: 1 [RTR:231] Pithing Needle +SB: 2 [M14:12] Celestial Flare +SB: 3 [THS:49] Gainsay +SB: 1 [M14:215] Ratchet Bomb +SB: 3 [THS:22] Last Breath +SB: 2 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..6290861ac78 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,30 @@ +4 [WWK:133] Celestial Colonnade +2 [M11:58] Jace Beleren +1 [SOM:46] Stoic Rebuttal +2 [C14:95] White Sun's Zenith +2 [ZEN:70] Spreading Seas +4 [M13:225] Glacial Fortress +3 [CMD:37] Wall of Omens +1 [NPH:130] Batterskull +2 [KTK:33] Cancel +2 [C14:69] Condemn +1 [NPH:1] Karn Liberated +4 [C14:313] Tectonic Edge +2 [C14:115] Into the Roil +4 [M11:70] Preordain +4 [SOM:229] Seachrome Coast +1 [C14:271] Solemn Simulacrum +2 [M15:63] Jace's Ingenuity +3 [M13:22] Oblivion Ring +2 [M12:12] Day of Judgment +4 [UNH:136] Plains +5 [UNH:137] Island +1 [M15:71] Negate +4 [M12:63] Mana Leak +SB: 2 [ZEN:25] Luminarch Ascension +SB: 2 [MBS:5] Divine Offering +SB: 1 [C14:74] Grand Abolisher +SB: 3 [M11:21] Leyline of Sanctity +SB: 4 [M12:11] Celestial Purge +SB: 2 [M12:12] Day of Judgment +SB: 1 [C14:69] Condemn diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2014.mwDeck.dck new file mode 100644 index 00000000000..dc0dd37ad41 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jul 2014.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:47] Dissolve +2 [M14:12] Celestial Flare +2 [RTR:54] Syncopate +1 [M14:68] Quicken +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [RTR:155] Detention Sphere +3 [C13:275] Azorius Guildgate +2 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +4 [M15:52] Divination +1 [M14:209] Elixir of Immortality +6 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +7 [UNH:137] Island +4 [BNG:163] Temple of Enlightenment +SB: 1 [GTC:6] Blind Obedience +SB: 2 [M14:18] Fiendslayer Paladin +SB: 1 [THS:49] Gainsay +SB: 2 [JOU:7] Deicide +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [JOU:23] Reprisal +SB: 3 [THS:22] Last Breath +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jun 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jun 2014.mwDeck.dck new file mode 100644 index 00000000000..ac66890ec47 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST Jun 2014.mwDeck.dck @@ -0,0 +1,27 @@ +4 [THS:47] Dissolve +3 [M14:29] Planar Cleansing +1 [JOU:7] Deicide +2 [RTR:54] Syncopate +3 [M14:68] Quicken +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +3 [C13:275] Azorius Guildgate +3 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +4 [M15:52] Divination +1 [M14:209] Elixir of Immortality +6 [UNH:136] Plains +6 [UNH:137] Island +4 [BNG:163] Temple of Enlightenment +1 [M15:71] Negate +SB: 2 [GTC:6] Blind Obedience +SB: 1 [M14:18] Fiendslayer Paladin +SB: 1 [RTR:231] Pithing Needle +SB: 1 [JOU:7] Deicide +SB: 3 [THS:49] Gainsay +SB: 2 [M14:12] Celestial Flare +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 2 [THS:22] Last Breath +SB: 1 [M14:60] Jace, Memory Adept diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST May 2014.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST May 2014.mwDeck.dck new file mode 100644 index 00000000000..aa98f81bf10 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Control TDtB ST May 2014.mwDeck.dck @@ -0,0 +1,30 @@ +4 [THS:47] Dissolve +2 [M14:29] Planar Cleansing +1 [JOU:7] Deicide +2 [M14:12] Celestial Flare +2 [RTR:54] Syncopate +4 [RTR:241] Hallowed Fountain +4 [RTR:201] Supreme Verdict +3 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [C13:275] Azorius Guildgate +1 [DGM:11] AEtherling +4 [M14:228] Mutavault +3 [RTR:44] Jace, Architect of Thought +4 [M15:52] Divination +1 [M14:209] Elixir of Immortality +5 [UNH:136] Plains +1 [THS:9] Elspeth, Sun's Champion +5 [UNH:137] Island +2 [THS:22] Last Breath +4 [BNG:163] Temple of Enlightenment +SB: 3 [JOU:18] Nyx-Fleece Ram +SB: 1 [RTR:155] Detention Sphere +SB: 1 [RTR:231] Pithing Needle +SB: 1 [JOU:7] Deicide +SB: 3 [THS:49] Gainsay +SB: 1 [JOU:5] Banishing Light +SB: 1 [RTR:36] Dispel +SB: 2 [THS:9] Elspeth, Sun's Champion +SB: 1 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..47f3a5caf03 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,29 @@ +2 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +1 [NPH:130] Batterskull +4 [ISD:78] Snapcaster Mage +2 [NPH:86] Gut Shot +1 [ISD:231] Runechanter's Pike +2 [DKA:52] Thought Scour +4 [SOM:229] Seachrome Coast +1 [NPH:57] Dismember +4 [NPH:35] Gitaxian Probe +4 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +9 [UNH:137] Island +4 [M12:73] Ponder +2 [ISD:60] Invisible Stalker +4 [M12:63] Mana Leak +SB: 2 [NPH:107] Corrosive Gale +SB: 1 [MBS:5] Divine Offering +SB: 1 [BNG:25] Revoke Existence +SB: 2 [M15:51] Dissipate +SB: 2 [M12:11] Celestial Purge +SB: 1 [NPH:130] Batterskull +SB: 2 [M12:72] Phantasmal Image +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M12:40] Timely Reinforcements +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Aug 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Aug 2012.mwDeck.dck new file mode 100644 index 00000000000..46f4b8bb856 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Aug 2012.mwDeck.dck @@ -0,0 +1,25 @@ +3 [AVR:32] Restoration Angel +3 [C13:30] Augur of Bolas +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +4 [NPH:86] Gut Shot +3 [ISD:231] Runechanter's Pike +4 [DKA:52] Thought Scour +4 [SOM:229] Seachrome Coast +4 [NPH:35] Gitaxian Probe +2 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +2 [ISD:244] Moorland Haunt +4 [ISD:51] Delver of Secrets +8 [UNH:137] Island +4 [M12:73] Ponder +3 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [MBS:138] Sword of Feast and Famine +SB: 1 [NPH:57] Dismember +SB: 1 [M15:51] Dissipate +SB: 3 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 3 [NPH:38] Mental Misstep +SB: 3 [M12:72] Phantasmal Image +SB: 1 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Feb 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Feb 2012.mwDeck.dck new file mode 100644 index 00000000000..6498036b314 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Feb 2012.mwDeck.dck @@ -0,0 +1,28 @@ +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +3 [NPH:86] Gut Shot +3 [ISD:231] Runechanter's Pike +2 [DKA:52] Thought Scour +4 [SOM:229] Seachrome Coast +4 [NPH:35] Gitaxian Probe +3 [ISD:213] Geist of Saint Traft +3 [C14:80] Midnight Haunting +4 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +2 [M12:72] Phantasmal Image +4 [ISD:51] Delver of Secrets +8 [UNH:137] Island +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [NPH:86] Gut Shot +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:51] Dissipate +SB: 2 [M13:22] Oblivion Ring +SB: 2 [M12:12] Day of Judgment +SB: 1 [M12:72] Phantasmal Image +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M12:40] Timely Reinforcements +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..c5893d3a7de --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,27 @@ +3 [AVR:32] Restoration Angel +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +1 [NPH:116] Mutagenic Growth +3 [NPH:86] Gut Shot +3 [ISD:231] Runechanter's Pike +4 [DKA:52] Thought Scour +4 [SOM:229] Seachrome Coast +4 [NPH:35] Gitaxian Probe +4 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +2 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +8 [UNH:137] Island +4 [M12:73] Ponder +3 [M12:63] Mana Leak +SB: 1 [NPH:116] Mutagenic Growth +SB: 1 [NPH:86] Gut Shot +SB: 1 [NPH:161] Sword of War and Peace +SB: 1 [ISD:79] Spectral Flight +SB: 1 [M15:51] Dissipate +SB: 3 [M12:11] Celestial Purge +SB: 2 [NPH:38] Mental Misstep +SB: 2 [M12:72] Phantasmal Image +SB: 2 [M12:40] Timely Reinforcements +SB: 1 [M12:63] Mana Leak diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..abb87980233 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Delver TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,30 @@ +2 [NPH:161] Sword of War and Peace +4 [M13:225] Glacial Fortress +4 [ISD:78] Snapcaster Mage +1 [NPH:86] Gut Shot +1 [MBS:138] Sword of Feast and Famine +2 [DKA:52] Thought Scour +4 [SOM:229] Seachrome Coast +1 [NPH:57] Dismember +4 [NPH:35] Gitaxian Probe +4 [ISD:213] Geist of Saint Traft +4 [NPH:48] Vapor Snag +3 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +2 [M12:72] Phantasmal Image +4 [ISD:51] Delver of Secrets +2 [DKA:7] Faith's Shield +9 [UNH:137] Island +4 [M12:73] Ponder +4 [M12:63] Mana Leak +SB: 1 [MBS:21] Consecrated Sphinx +SB: 1 [MBS:5] Divine Offering +SB: 1 [NPH:74] Surgical Extraction +SB: 1 [C13:42] Dungeon Geists +SB: 2 [NPH:78] Act of Aggression +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:51] Dissipate +SB: 2 [M12:11] Celestial Purge +SB: 1 [NPH:130] Batterskull +SB: 1 [M13:22] Oblivion Ring +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Flash TDtB ST Jul 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Flash TDtB ST Jul 2013.mwDeck.dck new file mode 100644 index 00000000000..960af27ae51 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Flash TDtB ST Jul 2013.mwDeck.dck @@ -0,0 +1,29 @@ +4 [AVR:32] Restoration Angel +4 [C13:30] Augur of Bolas +2 [RTR:54] Syncopate +4 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +3 [ISD:78] Snapcaster Mage +3 [RTR:201] Supreme Verdict +2 [RTR:145] Azorius Charm +3 [RTR:200] Sphinx's Revelation +2 [DGM:5] Renounce the Guilds +2 [ISD:231] Runechanter's Pike +3 [DKA:52] Thought Scour +1 [M13:75] Unsummon +2 [M15:51] Dissipate +2 [M13:65] Rewind +2 [ISD:244] Moorland Haunt +5 [UNH:136] Plains +10 [UNH:137] Island +2 [ISD:83] Think Twice +SB: 1 [RTR:201] Supreme Verdict +SB: 2 [AVR:34] Righteous Blow +SB: 2 [ISD:27] Purify the Grave +SB: 1 [DGM:5] Renounce the Guilds +SB: 1 [DGM:11] AEtherling +SB: 2 [RTR:36] Dispel +SB: 1 [RTR:44] Jace, Architect of Thought +SB: 1 [M13:22] Oblivion Ring +SB: 3 [AVR:38] Terminus +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UW Human TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UW Human TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..0ba723c4fd4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UW Human TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,20 @@ +4 [M13:225] Glacial Fortress +4 [SOM:229] Seachrome Coast +3 [ISD:244] Moorland Haunt +4 [M12:23] Honor of the Pure +4 [M13:22] Oblivion Ring +13 [UNH:136] Plains +3 [DKA:24] Thalia, Guardian of Thraben +4 [DKA:13] Loyal Cathar +4 [MBS:14] Mirran Crusader +4 [ISD:6] Champion of the Parish +4 [MBS:8] Hero of Bladehold +1 [DKA:8] Gather the Townsfolk +4 [CNS:69] Doomed Traveler +4 [M12:63] Mana Leak +SB: 2 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 2 [BNG:25] Revoke Existence +SB: 4 [M12:12] Day of Judgment +SB: 1 [SOM:135] Venser, the Sojourner +SB: 4 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWR Midrange TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWR Midrange TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..09ecec03363 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWR Midrange TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,30 @@ +4 [AVR:32] Restoration Angel +2 [M14:55] Essence Scatter +4 [M13:225] Glacial Fortress +3 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +1 [UNH:139] Mountain +4 [ISD:78] Snapcaster Mage +3 [RTR:145] Azorius Charm +3 [M13:150] Thundermaw Hellkite +2 [ISD:231] Runechanter's Pike +2 [AVR:149] Pillar of Flame +4 [RTR:247] Steam Vents +4 [DKA:52] Thought Scour +4 [ISD:213] Geist of Saint Traft +2 [M15:51] Dissipate +2 [M13:75] Unsummon +2 [ISD:244] Moorland Haunt +4 [ISD:238] Clifftop Retreat +2 [ISD:139] Desperate Ravings +4 [ISD:248] Sulfur Falls +SB: 1 [RTR:155] Detention Sphere +SB: 1 [AVR:79] Tamiyo, the Moon Sage +SB: 1 [C13:42] Dungeon Geists +SB: 2 [AVR:149] Pillar of Flame +SB: 2 [M14:47] Clone +SB: 2 [AVR:166] Zealous Conscripts +SB: 2 [M15:51] Dissipate +SB: 1 [RTR:36] Dispel +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWr Control TDtB ST Oct 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWr Control TDtB ST Oct 2012.mwDeck.dck new file mode 100644 index 00000000000..ce47869b1dd --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWr Control TDtB ST Oct 2012.mwDeck.dck @@ -0,0 +1,26 @@ +2 [AVR:79] Tamiyo, the Moon Sage +2 [RTR:54] Syncopate +3 [AVR:20] Entreat the Angels +4 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +2 [ISD:78] Snapcaster Mage +1 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:155] Detention Sphere +4 [AVR:149] Pillar of Flame +1 [AVR:227] Desolate Lighthouse +4 [RTR:247] Steam Vents +4 [RTR:44] Jace, Architect of Thought +4 [UNH:136] Plains +2 [UNH:137] Island +4 [ISD:238] Clifftop Retreat +4 [ISD:83] Think Twice +4 [AVR:38] Terminus +3 [ISD:248] Sulfur Falls +SB: 2 [RTR:201] Supreme Verdict +SB: 2 [RTR:223] Sundering Growth +SB: 2 [ISD:27] Purify the Grave +SB: 3 [ISD:213] Geist of Saint Traft +SB: 2 [M15:51] Dissipate +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Apr 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Apr 2013.mwDeck.dck new file mode 100644 index 00000000000..bbac01a541b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Apr 2013.mwDeck.dck @@ -0,0 +1,31 @@ +3 [AVR:32] Restoration Angel +1 [RTR:93] Electrickery +2 [C13:30] Augur of Bolas +4 [GTC:215] Boros Reckoner +4 [M13:225] Glacial Fortress +1 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +1 [UNH:139] Mountain +3 [ISD:78] Snapcaster Mage +2 [RTR:201] Supreme Verdict +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +2 [AVR:149] Pillar of Flame +4 [RTR:247] Steam Vents +4 [DKA:52] Thought Scour +3 [M15:51] Dissipate +2 [GTC:245] Sacred Foundry +1 [ISD:146] Harvest Pyre +1 [UNH:136] Plains +1 [UNH:137] Island +4 [ISD:238] Clifftop Retreat +2 [ISD:83] Think Twice +4 [ISD:248] Sulfur Falls +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [RTR:93] Electrickery +SB: 3 [M14:47] Clone +SB: 1 [ISD:236] Witchbane Orb +SB: 2 [RTR:36] Dispel +SB: 3 [RTR:18] Rest in Peace +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jan 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jan 2013.mwDeck.dck new file mode 100644 index 00000000000..9716b7fc776 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jan 2013.mwDeck.dck @@ -0,0 +1,33 @@ +4 [AVR:32] Restoration Angel +3 [C13:30] Augur of Bolas +4 [M13:225] Glacial Fortress +1 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +2 [RTR:153] Counterflux +1 [RTR:172] Izzet Charm +1 [UNH:139] Mountain +4 [ISD:78] Snapcaster Mage +1 [RTR:201] Supreme Verdict +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +1 [RTR:101] Mizzium Mortars +2 [ISD:231] Runechanter's Pike +3 [AVR:149] Pillar of Flame +4 [RTR:247] Steam Vents +4 [DKA:52] Thought Scour +1 [M13:65] Rewind +1 [ISD:244] Moorland Haunt +1 [UNH:136] Plains +2 [UNH:137] Island +4 [ISD:238] Clifftop Retreat +1 [ISD:83] Think Twice +4 [ISD:248] Sulfur Falls +SB: 2 [RTR:201] Supreme Verdict +SB: 1 [RTR:155] Detention Sphere +SB: 2 [ISD:27] Purify the Grave +SB: 1 [RTR:36] Dispel +SB: 1 [ISD:29] Rebuke +SB: 1 [M13:22] Oblivion Ring +SB: 3 [M14:60] Jace, Memory Adept +SB: 2 [RTR:173] Izzet Staticaster +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jun 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jun 2013.mwDeck.dck new file mode 100644 index 00000000000..7f2a6b90b60 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Jun 2013.mwDeck.dck @@ -0,0 +1,31 @@ +3 [AVR:32] Restoration Angel +3 [C13:30] Augur of Bolas +1 [RTR:54] Syncopate +4 [M13:225] Glacial Fortress +3 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +3 [ISD:78] Snapcaster Mage +2 [RTR:201] Supreme Verdict +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +2 [DGM:5] Renounce the Guilds +1 [AVR:149] Pillar of Flame +1 [AVR:227] Desolate Lighthouse +4 [RTR:247] Steam Vents +1 [DGM:116] Warleader's Helix +3 [M15:51] Dissipate +3 [GTC:245] Sacred Foundry +1 [ISD:244] Moorland Haunt +2 [DGM:134] Turn // Burn +2 [UNH:137] Island +3 [ISD:238] Clifftop Retreat +2 [ISD:83] Think Twice +4 [ISD:248] Sulfur Falls +1 [GTC:142] Assemble the Legion +SB: 1 [RTR:201] Supreme Verdict +SB: 3 [AVR:149] Pillar of Flame +SB: 2 [RTR:36] Dispel +SB: 3 [RTR:18] Rest in Peace +SB: 2 [RTR:173] Izzet Staticaster +SB: 2 [M14:60] Jace, Memory Adept +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Mar 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Mar 2013.mwDeck.dck new file mode 100644 index 00000000000..495275caebf --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWr Midrange TDtB ST Mar 2013.mwDeck.dck @@ -0,0 +1,32 @@ +4 [AVR:32] Restoration Angel +1 [RTR:54] Syncopate +3 [M13:225] Glacial Fortress +2 [M13:147] Searing Spear +4 [RTR:241] Hallowed Fountain +2 [RTR:172] Izzet Charm +4 [ISD:78] Snapcaster Mage +4 [RTR:145] Azorius Charm +3 [RTR:101] Mizzium Mortars +3 [M13:150] Thundermaw Hellkite +2 [AVR:149] Pillar of Flame +1 [AVR:227] Desolate Lighthouse +4 [RTR:247] Steam Vents +4 [DKA:52] Thought Scour +4 [ISD:213] Geist of Saint Traft +1 [M13:75] Unsummon +2 [M15:51] Dissipate +3 [GTC:245] Sacred Foundry +2 [ISD:244] Moorland Haunt +3 [ISD:238] Clifftop Retreat +4 [ISD:248] Sulfur Falls +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [AVR:149] Pillar of Flame +SB: 1 [ISD:231] Runechanter's Pike +SB: 2 [C13:30] Augur of Bolas +SB: 1 [RTR:203] Thoughtflare +SB: 4 [GTC:215] Boros Reckoner +SB: 1 [RTR:36] Dispel +SB: 1 [M13:147] Searing Spear +SB: 1 [RTR:153] Counterflux +SB: 1 [M15:71] Negate +SB: 1 [GTC:142] Assemble the Legion diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Aug 2013.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Aug 2013.mwDeck.dck new file mode 100644 index 00000000000..91871ec82e6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Aug 2013.mwDeck.dck @@ -0,0 +1,29 @@ +4 [AVR:32] Restoration Angel +3 [C13:30] Augur of Bolas +3 [RTR:54] Syncopate +4 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +1 [RTR:172] Izzet Charm +3 [ISD:78] Snapcaster Mage +2 [RTR:201] Supreme Verdict +3 [RTR:145] Azorius Charm +3 [RTR:200] Sphinx's Revelation +3 [AVR:149] Pillar of Flame +4 [RTR:247] Steam Vents +2 [M15:51] Dissipate +2 [DGM:116] Warleader's Helix +4 [GTC:245] Sacred Foundry +2 [ISD:244] Moorland Haunt +1 [DGM:134] Turn // Burn +1 [UNH:137] Island +3 [ISD:238] Clifftop Retreat +4 [ISD:83] Think Twice +4 [ISD:248] Sulfur Falls +SB: 3 [M13:150] Thundermaw Hellkite +SB: 2 [RTR:155] Detention Sphere +SB: 2 [M14:12] Celestial Flare +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [RTR:36] Dispel +SB: 1 [DGM:134] Turn // Burn +SB: 2 [RTR:173] Izzet Staticaster +SB: 3 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..301a37552e7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/UWx Midrange TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,22 @@ +4 [AVR:32] Restoration Angel +4 [C13:30] Augur of Bolas +4 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +4 [ISD:78] Snapcaster Mage +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +1 [AVR:226] Cavern of Souls +2 [ISD:14] Feeling of Dread +4 [DKA:52] Thought Scour +4 [ISD:213] Geist of Saint Traft +2 [M15:51] Dissipate +4 [M13:75] Unsummon +3 [ISD:244] Moorland Haunt +4 [UNH:136] Plains +8 [UNH:137] Island +1 [ISD:83] Think Twice +SB: 3 [RTR:201] Supreme Verdict +SB: 3 [ISD:27] Purify the Grave +SB: 3 [RTR:36] Dispel +SB: 3 [M13:21] Knight of Glory +SB: 3 [M14:60] Jace, Memory Adept diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Unsolar Flare TDtB ST Jan 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Unsolar Flare TDtB ST Jan 2012.mwDeck.dck new file mode 100644 index 00000000000..1f9e7c97285 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Unsolar Flare TDtB ST Jan 2012.mwDeck.dck @@ -0,0 +1,38 @@ +1 [MBS:21] Consecrated Sphinx +2 [MBS:43] Go for the Throat +1 [SOM:6] Elspeth Tirel +2 [C14:95] White Sun's Zenith +1 [M12:16] Gideon Jura +4 [M13:225] Glacial Fortress +2 [M13:223] Drowned Catacomb +1 [ISD:78] Snapcaster Mage +3 [ISD:55] Forbidden Alchemy +1 [C14:145] Grave Titan +2 [ISD:242] Isolated Chapel +3 [C14:264] Pristine Talisman +1 [NPH:9] Elesh Norn, Grand Cenobite +2 [M14:96] Doom Blade +3 [M15:51] Dissipate +4 [M12:12] Day of Judgment +4 [UNH:136] Plains +4 [UNH:137] Island +1 [UNH:138] Swamp +1 [NPH:130] Batterskull +2 [C14:298] Ghost Quarter +4 [SOM:229] Seachrome Coast +2 [SOM:226] Darkslick Shores +3 [M13:22] Oblivion Ring +3 [ISD:83] Think Twice +3 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [C13:32] Blue Sun's Zenith +SB: 1 [C14:298] Ghost Quarter +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:51] Dissipate +SB: 1 [M12:11] Celestial Purge +SB: 1 [M13:22] Oblivion Ring +SB: 1 [C13:249] Nihil Spellbomb +SB: 2 [M12:72] Phantasmal Image +SB: 3 [M12:40] Timely Reinforcements +SB: 1 [M15:71] Negate +SB: 1 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..714c7bd9b14 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,25 @@ +1 [WWK:141] Raging Ravine +2 [CNS:171] Nature's Claim +4 [UNH:140] Forest +2 [M11:149] Lightning Bolt +3 [ZEN:167] Khalni Heart Expedition +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +4 [ZEN:172] Oracle of Mul Daya +3 [C14:315] Terramorphic Expanse +3 [ZEN:184] Summoning Trap +11 [UNH:139] Mountain +3 [C13:114] Inferno Titan +4 [ZEN:228] Valakut, the Molten Pinnacle +1 [C13:135] Avenger of Zendikar +3 [ZEN:229] Verdant Catacombs +4 [M12:190] Rampant Growth +2 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 1 [C13:134] Acidic Slime +SB: 1 [CNS:171] Nature's Claim +SB: 2 [NPH:57] Dismember +SB: 3 [M11:188] Obstinate Baloth +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 4 [M11:154] Pyroclasm +SB: 2 [M11:174] Gaea's Revenge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Dec 2010.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Dec 2010.mwDeck.dck new file mode 100644 index 00000000000..f695f092330 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Dec 2010.mwDeck.dck @@ -0,0 +1,21 @@ +5 [UNH:140] Forest +4 [M11:149] Lightning Bolt +4 [ZEN:167] Khalni Heart Expedition +4 [M12:188] Primeval Titan +2 [ZEN:172] Oracle of Mul Daya +4 [C13:139] Cultivate +3 [C14:315] Terramorphic Expanse +2 [ZEN:184] Summoning Trap +1 [M11:174] Gaea's Revenge +13 [UNH:139] Mountain +4 [ZEN:228] Valakut, the Molten Pinnacle +3 [C13:135] Avenger of Zendikar +4 [C14:199] Harrow +3 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 3 [KTK:142] Naturalize +SB: 2 [KTK:95] Act of Treason +SB: 2 [WWK:87] Ricochet Trap +SB: 3 [M11:188] Obstinate Baloth +SB: 4 [M11:154] Pyroclasm +SB: 1 [M11:174] Gaea's Revenge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Feb 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Feb 2011.mwDeck.dck new file mode 100644 index 00000000000..c804c50e30a --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Feb 2011.mwDeck.dck @@ -0,0 +1,21 @@ +5 [UNH:140] Forest +4 [ZEN:220] Misty Rainforest +4 [ROE:203] Overgrown Battlement +4 [ZEN:167] Khalni Heart Expedition +4 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +4 [C13:139] Cultivate +4 [C14:315] Terramorphic Expanse +11 [UNH:139] Mountain +4 [ZEN:228] Valakut, the Molten Pinnacle +2 [C13:135] Avenger of Zendikar +4 [ZEN:168] Lotus Cobra +3 [C14:199] Harrow +3 [WWK:99] Explore +SB: 1 [C13:134] Acidic Slime +SB: 2 [CNS:171] Nature's Claim +SB: 2 [SOM:218] Tumble Magnet +SB: 1 [M11:188] Obstinate Baloth +SB: 2 [SOM:94] Koth of the Hammer +SB: 3 [MBS:92] Thrun, the Last Troll +SB: 4 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Jul 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Jul 2011.mwDeck.dck new file mode 100644 index 00000000000..6084a8118f2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Jul 2011.mwDeck.dck @@ -0,0 +1,28 @@ +1 [WWK:141] Raging Ravine +5 [UNH:140] Forest +2 [M11:149] Lightning Bolt +3 [ROE:203] Overgrown Battlement +4 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +4 [ZEN:172] Oracle of Mul Daya +4 [C13:139] Cultivate +2 [C14:315] Terramorphic Expanse +1 [ZEN:184] Summoning Trap +10 [UNH:139] Mountain +4 [ZEN:228] Valakut, the Molten Pinnacle +2 [C13:135] Avenger of Zendikar +2 [ZEN:229] Verdant Catacombs +4 [M12:190] Rampant Growth +4 [C14:295] Evolving Wilds +1 [SOM:218] Tumble Magnet +2 [WWK:99] Explore +SB: 3 [SOM:69] Memoricide +SB: 2 [MBS:78] Creeping Corrosion +SB: 1 [M15:169] Back to Nature +SB: 1 [SOM:218] Tumble Magnet +SB: 1 [M11:188] Obstinate Baloth +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 4 [M11:154] Pyroclasm +SB: 1 [UNH:138] Swamp +SB: 1 [M11:174] Gaea's Revenge diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Mar 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Mar 2011.mwDeck.dck new file mode 100644 index 00000000000..4c987ce2b4b --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Mar 2011.mwDeck.dck @@ -0,0 +1,24 @@ +1 [MBS:75] Slagstorm +7 [UNH:140] Forest +4 [ROE:203] Overgrown Battlement +4 [ZEN:167] Khalni Heart Expedition +3 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +2 [ZEN:172] Oracle of Mul Daya +2 [C13:139] Cultivate +3 [M11:154] Pyroclasm +2 [C14:315] Terramorphic Expanse +11 [UNH:139] Mountain +4 [ZEN:228] Valakut, the Molten Pinnacle +2 [C13:135] Avenger of Zendikar +1 [C13:134] Acidic Slime +4 [C14:199] Harrow +2 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 1 [MBS:75] Slagstorm +SB: 2 [M13:141] Mark of Mutiny +SB: 1 [C13:134] Acidic Slime +SB: 2 [CNS:171] Nature's Claim +SB: 3 [M11:188] Obstinate Baloth +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 4 [ZEN:184] Summoning Trap diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST May 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST May 2011.mwDeck.dck new file mode 100644 index 00000000000..6a97ddafb61 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST May 2011.mwDeck.dck @@ -0,0 +1,22 @@ +2 [WWK:141] Raging Ravine +4 [ROE:186] Growth Spasm +4 [CNS:171] Nature's Claim +5 [UNH:140] Forest +4 [ROE:203] Overgrown Battlement +4 [M12:188] Primeval Titan +4 [C13:139] Cultivate +4 [C14:315] Terramorphic Expanse +4 [ZEN:184] Summoning Trap +11 [UNH:139] Mountain +2 [C13:114] Inferno Titan +4 [ZEN:228] Valakut, the Molten Pinnacle +2 [C13:135] Avenger of Zendikar +2 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 2 [MBS:75] Slagstorm +SB: 2 [M12:128] Combust +SB: 3 [WWK:87] Ricochet Trap +SB: 3 [M11:188] Obstinate Baloth +SB: 1 [MBS:81] Green Sun's Zenith +SB: 1 [C14:218] Terastodon +SB: 3 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Sep 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Sep 2011.mwDeck.dck new file mode 100644 index 00000000000..4c8285c283c --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Valakut Ramp TDtB ST Sep 2011.mwDeck.dck @@ -0,0 +1,24 @@ +1 [WWK:141] Raging Ravine +2 [CNS:171] Nature's Claim +4 [UNH:140] Forest +2 [M11:149] Lightning Bolt +3 [ZEN:167] Khalni Heart Expedition +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +4 [ZEN:172] Oracle of Mul Daya +3 [C14:315] Terramorphic Expanse +3 [ZEN:184] Summoning Trap +11 [UNH:139] Mountain +4 [C13:114] Inferno Titan +4 [ZEN:228] Valakut, the Molten Pinnacle +3 [ZEN:229] Verdant Catacombs +4 [M12:190] Rampant Growth +2 [C14:295] Evolving Wilds +4 [WWK:99] Explore +SB: 1 [C13:135] Avenger of Zendikar +SB: 1 [C13:134] Acidic Slime +SB: 2 [CNS:171] Nature's Claim +SB: 2 [NPH:57] Dismember +SB: 3 [M11:188] Obstinate Baloth +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 4 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Vampires Br TDtB ST Aug 2011.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Vampires Br TDtB ST Aug 2011.mwDeck.dck new file mode 100644 index 00000000000..ee4774b5cd7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Vampires Br TDtB ST Aug 2011.mwDeck.dck @@ -0,0 +1,26 @@ +1 [MBS:43] Go for the Throat +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +2 [M12:145] Grim Lavamancer +3 [ROE:115] Inquisition of Kozilek +4 [M13:222] Dragonskull Summit +4 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +3 [ZEN:229] Verdant Catacombs +2 [ZEN:219] Marsh Flats +3 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +3 [NPH:57] Dismember +2 [M14:96] Doom Blade +4 [SOM:224] Blackcleave Cliffs +4 [WWK:59] Kalastria Highborn +6 [UNH:138] Swamp +SB: 4 [M12:151] Manic Vandal +SB: 1 [MBS:43] Go for the Throat +SB: 3 [M11:92] Demon of Death's Gate +SB: 2 [NPH:78] Act of Aggression +SB: 1 [M14:97] Duress +SB: 1 [M12:145] Grim Lavamancer +SB: 1 [KTK:69] Despise +SB: 2 [M12:110] Sorin's Thirst diff --git a/Mage.Client/release/sample-decks/Decks to Beat/WR Humans TDtB ST May 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/WR Humans TDtB ST May 2012.mwDeck.dck new file mode 100644 index 00000000000..4ed9860691e --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/WR Humans TDtB ST May 2012.mwDeck.dck @@ -0,0 +1,23 @@ +3 [C14:88] Silverblade Paladin +2 [C13:11] Fiend Hunter +3 [NPH:161] Sword of War and Peace +3 [M12:156] Stormblood Berserker +1 [AVR:229] Slayers' Stronghold +3 [UNH:139] Mountain +4 [AVR:226] Cavern of Souls +4 [AVR:144] Lightning Mauler +3 [M12:23] Honor of the Pure +12 [UNH:136] Plains +3 [MBS:14] Mirran Crusader +3 [DKA:24] Thalia, Guardian of Thraben +4 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +4 [MBS:8] Hero of Bladehold +2 [DKA:8] Gather the Townsfolk +2 [CNS:69] Doomed Traveler +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [BNG:25] Revoke Existence +SB: 3 [AVR:166] Zealous Conscripts +SB: 3 [M12:11] Celestial Purge +SB: 3 [M13:22] Oblivion Ring +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Weenie White TDtB ST Dec 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Weenie White TDtB ST Dec 2012.mwDeck.dck new file mode 100644 index 00000000000..5c0837c838d --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Weenie White TDtB ST Dec 2012.mwDeck.dck @@ -0,0 +1,23 @@ +4 [M13:38] War Falcon +2 [AVR:33] Riders of Gavony +4 [C14:88] Silverblade Paladin +4 [AVR:83] Wingcrafter +4 [M13:225] Glacial Fortress +4 [ISD:28] Rally the Peasants +4 [RTR:241] Hallowed Fountain +4 [AVR:226] Cavern of Souls +2 [RTR:247] Steam Vents +4 [ISD:213] Geist of Saint Traft +4 [M13:21] Knight of Glory +2 [ISD:244] Moorland Haunt +4 [RTR:17] Precinct Captain +6 [UNH:136] Plains +3 [DKA:24] Thalia, Guardian of Thraben +1 [ISD:238] Clifftop Retreat +4 [ISD:6] Champion of the Parish +SB: 2 [RTR:155] Detention Sphere +SB: 2 [M14:1] Ajani, Caller of the Pride +SB: 3 [RTR:214] Dryad Militant +SB: 3 [AVR:18] Divine Deflection +SB: 4 [ISD:5] Bonds of Faith +SB: 1 [M13:22] Oblivion Ring diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Zombie Pod TDtB ST Jul 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Zombie Pod TDtB ST Jul 2012.mwDeck.dck new file mode 100644 index 00000000000..5dcee4085b9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Zombie Pod TDtB ST Jul 2012.mwDeck.dck @@ -0,0 +1,27 @@ +2 [MBS:43] Go for the Throat +1 [AVR:89] Butcher Ghoul +3 [AVR:86] Blood Artist +4 [M13:222] Dragonskull Summit +3 [NPH:104] Birthing Pod +4 [ISD:97] Diregraf Ghoul +2 [C14:167] Tragic Slip +2 [DKA:138] Falkenrath Aristocrat +3 [AVR:104] Gloom Surgeon +3 [NPH:42] Phyrexian Metamorph +4 [DKA:63] Geralf's Messenger +1 [NPH:68] Phyrexian Obliterator +1 [AVR:166] Zealous Conscripts +2 [SOM:63] Fume Spitter +4 [DKA:64] Gravecrawler +2 [MBS:115] Mortarpod +4 [SOM:224] Blackcleave Cliffs +3 [ISD:249] Woodland Cemetery +12 [UNH:138] Swamp +SB: 1 [M12:151] Manic Vandal +SB: 2 [NPH:74] Surgical Extraction +SB: 2 [NPH:78] Act of Aggression +SB: 2 [AVR:129] Bonfire of the Damned +SB: 1 [NPH:68] Phyrexian Obliterator +SB: 2 [M14:96] Doom Blade +SB: 3 [KTK:69] Despise +SB: 2 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Zombies G TDtB ST Nov 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Zombies G TDtB ST Nov 2012.mwDeck.dck new file mode 100644 index 00000000000..a98c3ed1705 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Zombies G TDtB ST Nov 2012.mwDeck.dck @@ -0,0 +1,21 @@ +4 [RTR:82] Ultimate Price +4 [M13:185] Rancor +4 [RTR:243] Overgrown Tomb +4 [RTR:177] Lotleth Troll +4 [ISD:97] Diregraf Ghoul +3 [AVR:226] Cavern of Souls +4 [DKA:63] Geralf's Messenger +2 [RTR:213] Deathrite Shaman +4 [RTR:158] Dreg Mangler +2 [M13:96] Knight of Infamy +4 [DKA:64] Gravecrawler +2 [C14:161] Sign in Blood +2 [C13:290] Golgari Guildgate +4 [ISD:249] Woodland Cemetery +4 [M15:92] Crippling Blight +9 [UNH:138] Swamp +SB: 4 [C13:97] Vampire Nighthawk +SB: 2 [RTR:213] Deathrite Shaman +SB: 2 [M13:96] Knight of Infamy +SB: 4 [M14:97] Duress +SB: 3 [RTR:164] Golgari Charm diff --git a/Mage.Client/release/sample-decks/Decks to Beat/Zombies TDtB ST Apr 2012.mwDeck.dck b/Mage.Client/release/sample-decks/Decks to Beat/Zombies TDtB ST Apr 2012.mwDeck.dck new file mode 100644 index 00000000000..294284643a2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Decks to Beat/Zombies TDtB ST Apr 2012.mwDeck.dck @@ -0,0 +1,22 @@ +3 [MBS:43] Go for the Throat +4 [M13:223] Drowned Catacomb +4 [DKA:135] Diregraf Captain +2 [NPH:61] Geth's Verdict +4 [ISD:97] Diregraf Ghoul +4 [C14:167] Tragic Slip +4 [DKA:63] Geralf's Messenger +2 [M12:86] Cemetery Reaper +2 [SOM:63] Fume Spitter +4 [DKA:64] Gravecrawler +4 [SOM:226] Darkslick Shores +3 [MBS:115] Mortarpod +4 [DKA:68] Highborn Ghoul +4 [M12:72] Phantasmal Image +12 [UNH:138] Swamp +SB: 2 [NPH:107] Corrosive Gale +SB: 1 [NPH:61] Geth's Verdict +SB: 4 [NPH:74] Surgical Extraction +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [M14:96] Doom Blade +SB: 2 [ISD:96] Dead Weight +SB: 2 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Control 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Control 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..9e68cd03f6f --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Control 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,30 @@ +2 [UNH:140] Forest +4 [JOU:165] Temple of Malady +4 [KTK:248] Windswept Heath +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +2 [M15:241] Caves of Koilos +4 [KTK:200] Siege Rhino +2 [BNG:61] Bile Blight +3 [M15:244] Llanowar Wastes +2 [KTK:210] Utter End +4 [BNG:119] Courser of Kruphix +4 [KTK:241] Sandsteppe Citadel +1 [M15:103] Liliana Vess +2 [DTK:124] Ultimate Price +4 [KTK:161] Abzan Charm +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [KTK:8] End Hostilities +1 [FRF:1] Ugin, the Spirit Dragon +4 [THS:90] Hero's Downfall +2 [FRF:87] Tasigur, the Golden Fang +2 [UNH:136] Plains +3 [THS:9] Elspeth, Sun's Champion +SB: 1 [BNG:61] Bile Blight +SB: 2 [C14:158] Read the Bones +SB: 1 [KTK:9] Erase +SB: 1 [KTK:8] End Hostilities +SB: 3 [THS:193] Fleecemane Lion +SB: 3 [BNG:65] Drown in Sorrow +SB: 2 [M15:187] Nissa, Worldwaker +SB: 2 [DTK:98] Duress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange 1 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange 1 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..5eb461c2df0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange 1 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,31 @@ +2 [JOU:145] Ajani, Mentor of Heroes +3 [UNH:140] Forest +4 [JOU:165] Temple of Malady +2 [KTK:31] Wingmate Roc +4 [KTK:248] Windswept Heath +1 [THS:227] Temple of Silence +2 [KTK:202] Sorin, Solemn Visitor +4 [THS:107] Thoughtseize +2 [M15:241] Caves of Koilos +4 [KTK:200] Siege Rhino +2 [M15:244] Llanowar Wastes +2 [KTK:210] Utter End +4 [BNG:119] Courser of Kruphix +4 [KTK:241] Sandsteppe Citadel +4 [KTK:161] Abzan Charm +1 [M15:248] Urborg, Tomb of Yawgmoth +3 [THS:90] Hero's Downfall +1 [JOU:163] Mana Confluence +2 [C14:191] Elvish Mystic +2 [UNH:136] Plains +3 [THS:9] Elspeth, Sun's Champion +4 [THS:180] Sylvan Caryatid +SB: 3 [BNG:61] Bile Blight +SB: 1 [KTK:174] Duneblast +SB: 1 [M15:103] Liliana Vess +SB: 2 [KTK:81] Murderous Cut +SB: 1 [KTK:8] End Hostilities +SB: 1 [BNG:143] Unravel the AEther +SB: 3 [BNG:65] Drown in Sorrow +SB: 1 [M15:18] Mass Calcify +SB: 2 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(1) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(1) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..5c98d3a2820 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(1) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,33 @@ +1 [THS:110] Whip of Erebos +2 [UNH:140] Forest +1 [JOU:165] Temple of Malady +4 [KTK:31] Wingmate Roc +4 [KTK:248] Windswept Heath +4 [THS:227] Temple of Silence +2 [KTK:202] Sorin, Solemn Visitor +1 [THS:107] Thoughtseize +4 [KTK:200] Siege Rhino +2 [BNG:61] Bile Blight +4 [M15:244] Llanowar Wastes +1 [KTK:163] Anafenza, the Foremost +4 [BNG:119] Courser of Kruphix +4 [KTK:241] Sandsteppe Citadel +3 [KTK:161] Abzan Charm +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [THS:90] Hero's Downfall +4 [THS:193] Fleecemane Lion +1 [JOU:163] Mana Confluence +1 [BNG:165] Temple of Plenty +1 [BNG:65] Drown in Sorrow +2 [UNH:136] Plains +4 [THS:180] Sylvan Caryatid +1 [UNH:138] Swamp +SB: 1 [KTK:210] Utter End +SB: 1 [KTK:163] Anafenza, the Foremost +SB: 1 [JOU:59] Agent of Erebos +SB: 1 [M15:169] Back to Nature +SB: 1 [KTK:9] Erase +SB: 4 [KTK:8] End Hostilities +SB: 1 [M15:117] Stain the Mind +SB: 3 [THS:107] Thoughtseize +SB: 2 [THS:9] Elspeth, Sun's Champion diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(2) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(2) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..63966c2a499 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Abzan Midrange(2) 34 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,28 @@ +2 [UNH:140] Forest +4 [JOU:165] Temple of Malady +4 [KTK:248] Windswept Heath +1 [THS:227] Temple of Silence +3 [KTK:202] Sorin, Solemn Visitor +4 [THS:107] Thoughtseize +4 [M15:241] Caves of Koilos +2 [KTK:134] Heir of the Wilds +4 [KTK:200] Siege Rhino +2 [M15:244] Llanowar Wastes +3 [KTK:163] Anafenza, the Foremost +4 [KTK:241] Sandsteppe Citadel +3 [KTK:161] Abzan Charm +2 [M15:248] Urborg, Tomb of Yawgmoth +4 [KTK:192] Rakshasa Deathdealer +4 [THS:90] Hero's Downfall +4 [THS:193] Fleecemane Lion +1 [M15:119] Ulcerate +1 [UNH:136] Plains +4 [BNG:75] Herald of Torment +SB: 3 [BNG:61] Bile Blight +SB: 2 [KTK:9] Erase +SB: 1 [THS:110] Whip of Erebos +SB: 1 [JOU:145] Ajani, Mentor of Heroes +SB: 2 [KTK:31] Wingmate Roc +SB: 3 [BNG:65] Drown in Sorrow +SB: 2 [KTK:69] Despise +SB: 1 [JOU:82] Silence the Believers diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(1) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(1) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck new file mode 100644 index 00000000000..914a8d00c13 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(1) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck @@ -0,0 +1,37 @@ +1 [ATQ:88] Atog +2 [MRD:283] Seat of the Synod +3 [MMA:198] Arcbound Ravager +1 [HOP:136] Seat of the Synod +4 [MRD:62] Disciple of the Vault +4 [DST:91] AEther Vial +2 [MRD:286] Vault of Whispers +1 [FNMP:105] Myr Enforcer +1 [DDF:40] Arcbound Worker +3 [HOP:110] Cranial Plating +2 [MRD:86] Atog +1 [MM2:206] Cranial Plating +3 [INV:299] Chromatic Sphere +1 [MRD:151] Chromatic Sphere +2 [DST:163] Blinkmoth Nexus +1 [DST:100] Arcbound Ravager +1 [MMA:220] Blinkmoth Nexus +1 [MM2:64] Thoughtcast +1 [MMA:223] Glimmervoid +3 [MMA:201] Arcbound Worker +4 [C14:299] Great Furnace +1 [C14:255] Myr Retriever +1 [MMA:207] Frogmite +1 [MM2:236] Blinkmoth Nexus +2 [MMA:209] Myr Enforcer +1 [MRD:211] Myr Enforcer +3 [C14:290] Darksteel Citadel +1 [DDF:51] Frogmite +1 [DDF:74] Seat of the Synod +2 [MM2:215] Frogmite +3 [MRD:54] Thoughtcast +2 [HOP:141] Vault of Whispers +SB: 2 [C14:255] Myr Retriever +SB: 1 [MRD:281] Glimmervoid +SB: 4 [5DN:147] Relic Barrier +SB: 1 [MRD:51] Somber Hoverguard +SB: 3 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(2) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(2) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck new file mode 100644 index 00000000000..431d4219fa2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Affinity(2) 58 World Championship 2004 (San Francisco) ST 9-5-04.dck @@ -0,0 +1,37 @@ +4 [MMA:198] Arcbound Ravager +2 [HOP:136] Seat of the Synod +1 [DDM:68] Night's Whisper +1 [MM2:57] Somber Hoverguard +2 [5DN:55] Night's Whisper +4 [MRD:62] Disciple of the Vault +1 [MRD:286] Vault of Whispers +1 [ME4:243] City of Brass +1 [DDF:40] Arcbound Worker +2 [HOP:110] Cranial Plating +1 [MM2:206] Cranial Plating +2 [7ED:327] City of Brass +1 [MRD:172] Frogmite +2 [INV:299] Chromatic Sphere +2 [GPX:3] Chrome Mox +1 [MRD:151] Chromatic Sphere +1 [MRD:152] Chrome Mox +1 [5DN:113] Cranial Plating +1 [DST:163] Blinkmoth Nexus +3 [M15:161] Shrapnel Blast +1 [MMA:220] Blinkmoth Nexus +1 [MMA:221] City of Brass +1 [MM2:64] Thoughtcast +3 [MMA:201] Arcbound Worker +2 [C14:299] Great Furnace +3 [MMA:207] Frogmite +3 [MRD:51] Somber Hoverguard +1 [MM2:236] Blinkmoth Nexus +2 [DDF:74] Seat of the Synod +1 [MRD:54] Thoughtcast +3 [HOP:141] Vault of Whispers +2 [DDF:71] Thoughtcast +3 [M12:63] Mana Leak +SB: 2 [10E:182] Terror +SB: 4 [THS:38] Annul +SB: 4 [M11:154] Pyroclasm +SB: 3 [DST:69] Slobad, Goblin Tinkerer diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 1 World Championship 2004 (San Francisco) ST 9-5-04.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 1 World Championship 2004 (San Francisco) ST 9-5-04.dck new file mode 100644 index 00000000000..96997d1ec60 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 1 World Championship 2004 (San Francisco) ST 9-5-04.dck @@ -0,0 +1,27 @@ +4 [C13:10] Eternal Dragon +2 [C14:97] Wing Shards +1 [UDS:117] Plow Under +4 [CMD:152] Eternal Witness +7 [UNH:140] Forest +2 [CMD:3] Akroma's Vengeance +1 [FNMP:76] Astral Slide +4 [KTK:248] Windswept Heath +4 [C14:316] Tranquil Thicket +4 [C13:27] Wrath of God +2 [ONS:50] Renewed Faith +4 [C14:310] Secluded Steppe +3 [VMA:13] Astral Slide +4 [M12:190] Rampant Growth +4 [10E:308] Viridian Shaman +2 [VMA:42] Renewed Faith +2 [C14:70] Decree of Justice +6 [UNH:136] Plains +SB: 2 [DST:79] Oxidize +SB: 1 [5DN:92] Rude Awakening +SB: 2 [UDS:117] Plow Under +SB: 2 [MPRP:7] Oxidize +SB: 2 [5ED:296] Circle of Protection: Red +SB: 1 [MMA:160] Rude Awakening +SB: 1 [9ED:11] Circle of Protection: Red +SB: 1 [8ED:272] Plow Under +SB: 3 [MRD:237] Scrabbling Claws diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 58 World Championship 2004 (San Francisco) ST 9-5-04.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 58 World Championship 2004 (San Francisco) ST 9-5-04.dck new file mode 100644 index 00000000000..31dc11bd2c3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Astral Slide 58 World Championship 2004 (San Francisco) ST 9-5-04.dck @@ -0,0 +1,31 @@ +1 [INV:327] Shivan Oasis +4 [C13:10] Eternal Dragon +4 [CMD:152] Eternal Witness +1 [ONS:4] Astral Slide +5 [UNH:140] Forest +2 [FNMP:76] Astral Slide +1 [KTK:249] Wooded Foothills +2 [C13:119] Slice and Dice +4 [C14:316] Tranquil Thicket +4 [C13:27] Wrath of God +1 [UNH:139] Mountain +1 [ONS:50] Renewed Faith +4 [C14:310] Secluded Steppe +1 [VMA:13] Astral Slide +3 [C13:154] Krosan Tusker +3 [VMA:178] Lightning Rift +2 [10E:308] Viridian Shaman +3 [VMA:42] Renewed Faith +4 [C14:271] Solemn Simulacrum +1 [DDE:65] Shivan Oasis +1 [8ED:326] Shivan Oasis +8 [UNH:136] Plains +SB: 1 [DST:79] Oxidize +SB: 2 [UDS:117] Plow Under +SB: 2 [MPRP:7] Oxidize +SB: 1 [LEG:237] Relic Barrier +SB: 2 [5DN:147] Relic Barrier +SB: 2 [SCG:23] Silver Knight +SB: 2 [DST:146] Sundering Titan +SB: 2 [8ED:272] Plow Under +SB: 1 [FNMP:46] Silver Knight diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/BGW Angels 58 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/BGW Angels 58 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..6ffd8e665a5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/BGW Angels 58 PT San Diego ST 2-21-10.dck @@ -0,0 +1,31 @@ +2 [C14:77] Marshal's Anthem +1 [MM2:151] Noble Hierarch +3 [WWK:144] Stirring Wildwood +1 [M13:229] Sunpetal Grove +1 [WWK:142] Sejiri Steppe +4 [UNH:140] Forest +4 [M11:7] Baneslayer Angel +4 [CMD:25] Path to Exile +1 [MMA:178] Knight of the Reliquary +4 [ZEN:229] Verdant Catacombs +4 [ZEN:168] Lotus Cobra +2 [DDG:1] Knight of the Reliquary +2 [AVR:169] Borderland Ranger +4 [UNH:136] Plains +2 [ALA:9] Elspeth, Knight-Errant +2 [UNH:138] Swamp +1 [CON:113] Knight of the Reliquary +1 [JR:66] Noble Hierarch +1 [CON:95] Thornling +1 [C14:313] Tectonic Edge +4 [ARB:92] Maelstrom Pulse +4 [ZEN:219] Marsh Flats +1 [M10:191] Master of the Wild Hunt +2 [CON:87] Noble Hierarch +4 [ZEN:11] Emeria Angel +SB: 3 [ARB:81] Identity Crisis +SB: 1 [C14:77] Marshal's Anthem +SB: 4 [ZEN:25] Luminarch Ascension +SB: 4 [M12:11] Celestial Purge +SB: 1 [CON:95] Thornling +SB: 2 [ZEN:39] World Queller diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bant 58 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bant 58 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..61de3d15032 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bant 58 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,31 @@ +4 [ALA:198] Steward of Valeron +1 [CON:113] Knight of the Reliquary +4 [ALA:188] Rhox War Monk +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +2 [M11:1] Ajani Goldmane +4 [ZEN:220] Misty Rainforest +4 [M11:7] Baneslayer Angel +4 [CMD:25] Path to Exile +3 [C13:318] Seaside Citadel +1 [M13:8] Captain of the Watch +1 [ZEN:211] Arid Mesa +2 [M12:165] Birds of Paradise +1 [ZEN:216] Kabira Crossroads +1 [MMA:178] Knight of the Reliquary +1 [ZEN:229] Verdant Catacombs +2 [ZEN:219] Marsh Flats +4 [CON:87] Noble Hierarch +2 [DDG:1] Knight of the Reliquary +4 [ZEN:11] Emeria Angel +1 [AVR:169] Borderland Ranger +3 [M12:23] Honor of the Pure +2 [UNH:136] Plains +1 [UNH:137] Island +SB: 3 [C14:66] Brave the Elements +SB: 3 [ZEN:25] Luminarch Ascension +SB: 1 [C14:297] Gargoyle Castle +SB: 1 [M13:8] Captain of the Watch +SB: 1 [AVR:169] Borderland Ranger +SB: 2 [ZEN:39] World Queller +SB: 4 [ARB:69] Grizzled Leotau diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Black Kessig 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Black Kessig 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..e44f222a050 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Black Kessig 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,32 @@ +1 [MBS:43] Go for the Throat +6 [UNH:140] Forest +1 [MBS:96] Glissa, the Traitor +2 [MBS:81] Green Sun's Zenith +1 [M13:222] Dragonskull Summit +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +1 [UNH:139] Mountain +3 [C14:136] Black Sun's Zenith +2 [C13:134] Acidic Slime +4 [C14:145] Grave Titan +1 [C14:298] Ghost Quarter +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +2 [M14:215] Ratchet Bomb +2 [C14:295] Evolving Wilds +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +3 [M14:96] Doom Blade +4 [ISD:249] Woodland Cemetery +4 [UNH:138] Swamp +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 1 [C14:136] Black Sun's Zenith +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [NPH:130] Batterskull +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [ISD:207] Tree of Redemption +SB: 2 [C13:249] Nihil Spellbomb +SB: 2 [ISD:94] Curse of Death's Hold +SB: 2 [ISD:127] Ancient Grudge +SB: 1 [ISD:105] Liliana of the Veil diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros 34 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros 34 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..78e52189407 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros 34 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,25 @@ +4 [ALA:21] Ranger of Eos +3 [M12:15] Elite Vanguard +4 [M11:149] Lightning Bolt +4 [CMD:25] Path to Exile +4 [ZEN:211] Arid Mesa +4 [ZEN:141] Plated Geopede +4 [UNH:139] Mountain +3 [ZEN:23] Kor Skyfisher +4 [ZEN:36] Steppe Lynx +2 [ZEN:119] Burst Lightning +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +2 [ZEN:125] Goblin Bushwhacker +4 [ZEN:126] Goblin Guide +2 [ZEN:226] Teetering Peaks +6 [UNH:136] Plains +2 [ALA:9] Elspeth, Knight-Errant +SB: 3 [M12:150] Manabarbs +SB: 1 [ZEN:119] Burst Lightning +SB: 2 [CMD:17] Journey to Nowhere +SB: 2 [M11:7] Baneslayer Angel +SB: 1 [M12:11] Celestial Purge +SB: 2 [M13:22] Oblivion Ring +SB: 3 [M10:14] Harm's Way +SB: 1 [ALA:9] Elspeth, Knight-Errant diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 2 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 2 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..11d07714d3a --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 2 PT Paris ST 2-13-11.dck @@ -0,0 +1,28 @@ +2 [MBS:66] Hero of Oxid Ridge +3 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +2 [ZEN:195] Adventuring Gear +4 [ZEN:141] Plated Geopede +5 [UNH:139] Mountain +4 [ZEN:36] Steppe Lynx +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +2 [CMD:17] Journey to Nowhere +1 [MBS:138] Sword of Feast and Famine +4 [ZEN:126] Goblin Guide +1 [SOM:208] Sword of Body and Mind +1 [ZEN:226] Teetering Peaks +3 [C14:295] Evolving Wilds +4 [M11:33] Squadron Hawk +1 [SOM:94] Koth of the Hammer +1 [SOM:104] Spikeshot Elder +3 [WWK:20] Stoneforge Mystic +5 [UNH:136] Plains +2 [MBS:14] Mirran Crusader +SB: 1 [M13:141] Mark of Mutiny +SB: 1 [WWK:122] Basilisk Collar +SB: 3 [WWK:11] Kor Firewalker +SB: 1 [SOM:94] Koth of the Hammer +SB: 4 [SOM:81] Arc Trail +SB: 1 [MBS:14] Mirran Crusader +SB: 4 [WWK:79] Cunning Sparkmage diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 34 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 34 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..c2318660699 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boros Landfall 34 PT Paris ST 2-13-11.dck @@ -0,0 +1,27 @@ +2 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +1 [C14:229] Bonehoard +2 [C14:315] Terramorphic Expanse +2 [ZEN:195] Adventuring Gear +3 [ZEN:141] Plated Geopede +3 [UNH:139] Mountain +4 [ZEN:36] Steppe Lynx +4 [ZEN:219] Marsh Flats +4 [ZEN:223] Scalding Tarn +3 [CMD:17] Journey to Nowhere +4 [ZEN:126] Goblin Guide +1 [SOM:208] Sword of Body and Mind +2 [ZEN:226] Teetering Peaks +4 [M11:33] Squadron Hawk +1 [SOM:94] Koth of the Hammer +4 [WWK:20] Stoneforge Mystic +2 [SOM:81] Arc Trail +6 [UNH:136] Plains +4 [MBS:14] Mirran Crusader +SB: 2 [M13:141] Mark of Mutiny +SB: 3 [ZEN:25] Luminarch Ascension +SB: 1 [CMD:17] Journey to Nowhere +SB: 1 [MBS:138] Sword of Feast and Famine +SB: 4 [WWK:11] Kor Firewalker +SB: 2 [SOM:94] Koth of the Hammer +SB: 2 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boss Naya 34 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boss Naya 34 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..6005b7cf266 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Boss Naya 34 PT San Diego ST 2-21-10.dck @@ -0,0 +1,37 @@ +1 [WWK:141] Raging Ravine +2 [MM2:151] Noble Hierarch +4 [ALA:21] Ranger of Eos +2 [WWK:144] Stirring Wildwood +1 [WWK:122] Basilisk Collar +1 [M13:228] Rootbound Crag +1 [WWK:142] Sejiri Steppe +5 [UNH:140] Forest +3 [M11:149] Lightning Bolt +3 [ZEN:220] Misty Rainforest +1 [CMD:25] Path to Exile +1 [ZEN:182] Scute Mob +2 [UNH:139] Mountain +1 [C13:178] Behemoth Sledge +1 [DDG:1] Knight of the Reliquary +2 [WWK:20] Stoneforge Mystic +2 [UNH:136] Plains +1 [ALA:9] Elspeth, Knight-Errant +4 [ALA:152] Wild Nacatl +2 [ALA:154] Ajani Vengeant +3 [CON:113] Knight of the Reliquary +2 [JR:66] Noble Hierarch +4 [ZEN:211] Arid Mesa +2 [M12:165] Birds of Paradise +2 [C14:315] Terramorphic Expanse +1 [C14:313] Tectonic Edge +4 [ARB:50] Bloodbraid Elf +2 [M13:22] Oblivion Ring +SB: 2 [M12:150] Manabarbs +SB: 1 [C13:178] Behemoth Sledge +SB: 1 [WWK:122] Basilisk Collar +SB: 1 [ZEN:126] Goblin Guide +SB: 2 [ARB:67] Dauntless Escort +SB: 2 [M11:7] Baneslayer Angel +SB: 1 [M13:22] Oblivion Ring +SB: 1 [WWK:20] Stoneforge Mystic +SB: 4 [WWK:79] Cunning Sparkmage diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Br Vampires 58 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Br Vampires 58 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..47947370be7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Br Vampires 58 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,22 @@ +3 [C13:99] Viscera Seer +4 [M11:149] Lightning Bolt +4 [ZEN:83] Bloodghast +4 [M13:222] Dragonskull Summit +3 [WWK:139] Lavaclaw Reaches +4 [ZEN:89] Gatekeeper of Malakir +3 [M11:90] Dark Tutelage +2 [C14:168] Vampire Hexmage +2 [ZEN:119] Burst Lightning +4 [ZEN:219] Marsh Flats +4 [WWK:62] Pulse Tracker +4 [ZEN:115] Vampire Lacerator +4 [SOM:224] Blackcleave Cliffs +3 [SOM:81] Arc Trail +4 [WWK:59] Kalastria Highborn +8 [UNH:138] Swamp +SB: 4 [M11:92] Demon of Death's Gate +SB: 4 [SOM:78] Skinrender +SB: 2 [C13:97] Vampire Nighthawk +SB: 1 [ZEN:88] Feast of Blood +SB: 3 [M14:97] Duress +SB: 1 [ROE:214] Sarkhan the Mad diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bug Critical 58 World Championship 2005 (Yokohama) ST 12-4-05.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bug Critical 58 World Championship 2005 (Yokohama) ST 12-4-05.dck new file mode 100644 index 00000000000..c8a29d90766 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Bug Critical 58 World Championship 2005 (Yokohama) ST 12-4-05.dck @@ -0,0 +1,26 @@ +1 [CHK:279] Minamo, School at Water's Edge +4 [RAV:201] Dimir Cutpurse +4 [UNH:140] Forest +4 [GTC:249] Watery Grave +1 [CHK:280] Okina, Temple to the Grandfathers +4 [M10:100] Hypnotic Specter +3 [BOK:163] Umezawa's Jitte +4 [RAV:161] Elves of Deep Shadow +4 [M12:165] Birds of Paradise +2 [CHK:74] Meloku the Clouded Mirror +4 [RTR:243] Overgrown Tomb +4 [M15:249] Yavimaya Coast +3 [CHK:65] Hinder +3 [BOK:56] Threads of Disloyalty +4 [BOK:44] Ninja of the Deep Hours +3 [DGM:93] Putrefy +1 [UNH:136] Plains +1 [SOK:164] Oboro, Palace in the Clouds +2 [UNH:137] Island +4 [M12:63] Mana Leak +SB: 2 [CMD:163] Kodama's Reach +SB: 4 [RAV:214] Loxodon Hierarch +SB: 1 [9ED:11] Circle of Protection: Red +SB: 1 [8ED:13] Circle of Protection: Red +SB: 3 [RAV:16] Faith's Fetters +SB: 4 [CNS:177] Sakura-Tribe Elder diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Critical Mass 58 World Championship 2005 (Yokohama) ST 12-4-05.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Critical Mass 58 World Championship 2005 (Yokohama) ST 12-4-05.dck new file mode 100644 index 00000000000..f7ebc9d56dc --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Critical Mass 58 World Championship 2005 (Yokohama) ST 12-4-05.dck @@ -0,0 +1,24 @@ +1 [CHK:279] Minamo, School at Water's Edge +3 [CHK:268] Sensei's Divining Top +1 [SOK:163] Miren, the Moaning Well +4 [CHK:222] Kodama of the North Tree +5 [UNH:140] Forest +4 [BOK:165] Tendo Ice Bridge +1 [CHK:280] Okina, Temple to the Grandfathers +4 [BOK:163] Umezawa's Jitte +4 [C14:204] Llanowar Elves +4 [CNS:177] Sakura-Tribe Elder +4 [C14:226] Wood Elves +4 [CHK:74] Meloku the Clouded Mirror +1 [RTR:243] Overgrown Tomb +3 [CHK:72] Keiga, the Tide Star +4 [M15:249] Yavimaya Coast +4 [CHK:65] Hinder +1 [SOK:164] Oboro, Palace in the Clouds +5 [UNH:137] Island +3 [M12:63] Mana Leak +SB: 3 [KTK:142] Naturalize +SB: 4 [BOK:56] Threads of Disloyalty +SB: 3 [CHK:70] Jushi Apprentice +SB: 3 [CHK:105] Cranial Extraction +SB: 2 [SOK:121] Arashi, the Sky Asunder diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dark Exalted 34 PT Kyoto ST 3-1-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dark Exalted 34 PT Kyoto ST 3-1-09.dck new file mode 100644 index 00000000000..ade6c6d193f --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dark Exalted 34 PT Kyoto ST 3-1-09.dck @@ -0,0 +1,32 @@ +3 [ALA:185] Rafiq of the Many +1 [MM2:151] Noble Hierarch +4 [ALA:188] Rhox War Monk +2 [UNH:140] Forest +4 [ALA:202] Tidehollow Sculler +2 [CMD:25] Path to Exile +3 [10E:361] Treetop Village +2 [10E:349] Brushland +1 [C14:247] Loxodon Warhammer +1 [M15:244] Llanowar Wastes +1 [10E:347] Adarkar Wastes +2 [M15:249] Yavimaya Coast +4 [LRW:247] Doran, the Siege Tower +3 [LRW:248] Gaddock Teeg +3 [LRW:128] Nameless Inversion +1 [UNH:136] Plains +2 [SHM:229] Kitchen Finks +2 [CON:141] Ancient Ziggurat +1 [UNH:138] Swamp +4 [MOR:147] Murmuring Bosk +4 [SHM:245] Wilt-Leaf Liege +1 [JR:66] Noble Hierarch +4 [M12:165] Birds of Paradise +1 [M15:241] Caves of Koilos +2 [CON:87] Noble Hierarch +2 [FNMP:118] Ancient Ziggurat +SB: 2 [10E:182] Terror +SB: 2 [CMD:25] Path to Exile +SB: 2 [ALA:218] Relic of Progenitus +SB: 4 [CON:90] Scattershot Archer +SB: 2 [SHM:229] Kitchen Finks +SB: 3 [SHM:208] Guttural Response diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Black 58 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Black 58 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..f2523f433eb --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Black 58 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,21 @@ +1 [THS:223] Nykthos, Shrine to Nyx +4 [RTR:83] Underworld Connections +2 [THS:110] Whip of Erebos +2 [RTR:73] Pack Rat +4 [RTR:63] Desecration Demon +4 [THS:227] Temple of Silence +4 [THS:107] Thoughtseize +4 [C14:146] Gray Merchant of Asphodel +4 [M14:101] Lifebane Zombie +4 [THS:90] Hero's Downfall +4 [M14:228] Mutavault +4 [M14:96] Doom Blade +2 [GTC:63] Devour Flesh +1 [THS:85] Erebos, God of the Dead +16 [UNH:138] Swamp +SB: 4 [M14:123] Xathrid Necromancer +SB: 1 [RTR:231] Pithing Needle +SB: 4 [THS:100] Pharika's Cure +SB: 4 [M14:97] Duress +SB: 1 [GTC:63] Devour Flesh +SB: 1 [THS:85] Erebos, God of the Dead diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 1 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 1 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..99901edebbb --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 1 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,22 @@ +2 [THS:57] Omenspeaker +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +3 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [M14:51] Disperse +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +2 [RTR:44] Jace, Architect of Thought +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +1 [THS:42] Bident of Thassa +21 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [RTR:231] Pithing Needle +SB: 2 [DGM:11] AEtherling +SB: 2 [M14:215] Ratchet Bomb +SB: 1 [THS:71] Triton Tactics +SB: 3 [M15:83] Wall of Frost +SB: 1 [M14:228] Mutavault +SB: 2 [RTR:44] Jace, Architect of Thought +SB: 3 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 2 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 2 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..f4eab2cbb21 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 2 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,22 @@ +2 [THS:57] Omenspeaker +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +3 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +1 [GTC:44] Rapid Hybridization +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [RTR:44] Jace, Architect of Thought +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +2 [THS:42] Bident of Thassa +21 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [RTR:231] Pithing Needle +SB: 2 [M14:215] Ratchet Bomb +SB: 3 [M15:83] Wall of Frost +SB: 1 [THS:71] Triton Tactics +SB: 1 [M14:228] Mutavault +SB: 3 [RTR:44] Jace, Architect of Thought +SB: 1 [M14:60] Jace, Memory Adept +SB: 3 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 34 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 34 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..d9c3c4c10c0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Blue 34 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,21 @@ +1 [THS:223] Nykthos, Shrine to Nyx +1 [THS:57] Omenspeaker +2 [C14:104] Cyclonic Rift +4 [RTR:215] Frostburn Weird +4 [M14:228] Mutavault +4 [M14:73] Tidebinder Mage +4 [GTC:32] Cloudfin Raptor +4 [RTR:218] Judge's Familiar +1 [RTR:44] Jace, Architect of Thought +4 [GTC:222] Nightveil Specter +4 [THS:53] Master of Waves +3 [THS:42] Bident of Thassa +20 [UNH:137] Island +4 [THS:66] Thassa, God of the Sea +SB: 1 [THS:57] Omenspeaker +SB: 1 [THS:47] Dissolve +SB: 3 [THS:49] Gainsay +SB: 2 [DGM:11] AEtherling +SB: 3 [GTC:44] Rapid Hybridization +SB: 3 [RTR:44] Jace, Architect of Thought +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Green 34 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Green 34 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..53681412e85 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Green 34 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,25 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +9 [UNH:140] Forest +2 [THS:166] Nylea, God of the Hunt +4 [GTC:216] Burning-Tree Emissary +2 [THS:209] Xenagos, the Reveler +4 [M14:172] Garruk, Caller of Beasts +3 [M14:195] Scavenging Ooze +2 [UNH:139] Mountain +4 [GTC:247] Stomping Ground +4 [THS:182] Voyaging Satyr +3 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +3 [GTC:156] Domri Rade +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 2 [M15:134] Chandra, Pyromaster +SB: 3 [RTR:101] Mizzium Mortars +SB: 2 [GTC:139] Wasteland Viper +SB: 2 [THS:167] Nylea's Disciple +SB: 1 [THS:209] Xenagos, the Reveler +SB: 1 [GTC:136] Sylvan Primordial +SB: 1 [THS:162] Mistcutter Hydra +SB: 2 [M14:130] Burning Earth +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..c5d8e22bb08 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,21 @@ +3 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +10 [UNH:140] Forest +2 [KTK:248] Windswept Heath +4 [KTK:149] See the Unwritten +4 [KTK:249] Wooded Foothills +4 [FRF:145] Whisperwood Elemental +1 [UNH:139] Mountain +4 [DTK:216] Dragonlord Atarka +4 [KTK:144] Rattleclaw Mystic +4 [BNG:119] Courser of Kruphix +4 [THS:172] Polukranos, World Eater +2 [DTK:210] Surrak, the Hunt Caller +2 [THS:152] Boon Satyr +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 4 [THS:167] Nylea's Disciple +SB: 3 [THS:209] Xenagos, the Reveler +SB: 1 [THS:182] Voyaging Satyr +SB: 3 [THS:150] Arbor Colossus +SB: 4 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..546ee6069a5 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Gruul 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,25 @@ +4 [THS:223] Nykthos, Shrine to Nyx +4 [THS:224] Temple of Abandon +10 [UNH:140] Forest +2 [THS:209] Xenagos, the Reveler +4 [KTK:249] Wooded Foothills +4 [M15:176] Genesis Hydra +4 [FRF:145] Whisperwood Elemental +1 [UNH:139] Mountain +3 [DTK:216] Dragonlord Atarka +1 [M15:178] Hornet Queen +4 [BNG:119] Courser of Kruphix +2 [DTK:204] Shaman of Forgotten Ways +4 [THS:182] Voyaging Satyr +1 [THS:150] Arbor Colossus +4 [THS:172] Polukranos, World Eater +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [M15:177] Hornet Nest +SB: 2 [C14:213] Reclamation Sage +SB: 1 [FRF:1] Ugin, the Spirit Dragon +SB: 4 [THS:167] Nylea's Disciple +SB: 2 [THS:209] Xenagos, the Reveler +SB: 1 [THS:150] Arbor Colossus +SB: 1 [DTK:156] Seismic Rupture +SB: 3 [M15:187] Nissa, Worldwaker diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Red 58 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Red 58 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..51049877a70 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Devotion to Red 58 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,21 @@ +4 [THS:223] Nykthos, Shrine to Nyx +3 [THS:135] Purphoros, God of the Forge +2 [THS:124] Hammer of Purphoros +3 [THS:120] Ember Swallower +4 [RTR:86] Ash Zealot +4 [THS:143] Stormbreath Dragon +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [THS:128] Magma Jet +21 [UNH:139] Mountain +1 [M15:134] Chandra, Pyromaster +1 [RTR:101] Mizzium Mortars +4 [RTR:215] Frostburn Weird +1 [M14:228] Mutavault +SB: 1 [THS:124] Hammer of Purphoros +SB: 1 [M15:134] Chandra, Pyromaster +SB: 3 [RTR:101] Mizzium Mortars +SB: 2 [M14:134] Chandra's Phoenix +SB: 3 [THS:132] Peak Eruption +SB: 3 [THS:112] Anger of the Gods +SB: 2 [M14:130] Burning Earth diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran 58 PT Hollywood ST 5-25-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran 58 PT Hollywood ST 5-25-08.dck new file mode 100644 index 00000000000..ce7adcc13cf --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran 58 PT Hollywood ST 5-25-08.dck @@ -0,0 +1,28 @@ +4 [MOR:147] Murmuring Bosk +3 [MOR:116] Chameleon Colossus +3 [FUT:78] Slaughter Pact +3 [FUT:136] Riftsweeper +4 [10E:361] Treetop Village +1 [FUT:177] Horizon Canopy +1 [TSB:120] Pendelhaven +4 [M12:165] Birds of Paradise +4 [FUT:153] Tarmogoyf +4 [THS:107] Thoughtseize +2 [CNS:210] Reflecting Pool +2 [SHM:281] Wooded Bastion +2 [C14:204] Llanowar Elves +1 [10E:349] Brushland +3 [M15:244] Llanowar Wastes +3 [C14:156] Profane Command +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [LRW:247] Doran, the Siege Tower +3 [LRW:128] Nameless Inversion +4 [SHM:229] Kitchen Finks +4 [LRW:268] Gilt-Leaf Palace +SB: 3 [LRW:48] Wispmare +SB: 2 [MOR:58] Bitterblossom +SB: 3 [M10:106] Mind Shatter +SB: 1 [C14:160] Shriekmaw +SB: 3 [M13:22] Oblivion Ring +SB: 2 [LRW:233] Primal Command +SB: 1 [SHM:192] Murderous Redcap diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran Rock 1 World Championship 2007 (New York) ST 12-6-07.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran Rock 1 World Championship 2007 (New York) ST 12-6-07.dck new file mode 100644 index 00000000000..2d885c39fed --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Doran Rock 1 World Championship 2007 (New York) ST 12-6-07.dck @@ -0,0 +1,32 @@ +2 [LRW:110] Eyeblight's Ending +1 [UNH:140] Forest +3 [CMD:157] Garruk Wildspeaker +4 [10E:361] Treetop Village +1 [FUT:177] Horizon Canopy +1 [TSB:120] Pendelhaven +1 [M10:100] Hypnotic Specter +4 [M12:165] Birds of Paradise +4 [FUT:153] Tarmogoyf +4 [THS:107] Thoughtseize +3 [M15:241] Caves of Koilos +3 [C14:204] Llanowar Elves +1 [10E:349] Brushland +2 [TSB:119] Gemstone Mine +4 [M15:244] Llanowar Wastes +4 [DDM:57] Ohran Viper +1 [M15:103] Liliana Vess +2 [C14:156] Profane Command +2 [M15:248] Urborg, Tomb of Yawgmoth +4 [LRW:247] Doran, the Siege Tower +3 [C14:160] Shriekmaw +2 [LRW:128] Nameless Inversion +4 [LRW:268] Gilt-Leaf Palace +SB: 2 [C14:247] Loxodon Warhammer +SB: 2 [LRW:250] Nath of the Gilt-Leaf +SB: 1 [HML:135] Serrated Arrows +SB: 2 [TSB:48] Stupor +SB: 1 [TSB:114] Serrated Arrows +SB: 3 [FUT:136] Riftsweeper +SB: 1 [C14:160] Shriekmaw +SB: 1 [M13:22] Oblivion Ring +SB: 2 [LRW:202] Cloudthresher diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dragonstorm 1 World Championship 2006 (Paris) ST 12-3-06.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dragonstorm 1 World Championship 2006 (Paris) ST 12-3-06.dck new file mode 100644 index 00000000000..002549392a0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Dragonstorm 1 World Championship 2006 (Paris) ST 12-3-06.dck @@ -0,0 +1,28 @@ +2 [RAV:131] Hunted Dragon +4 [GPT:26] Gigadrowse +1 [CMD:271] Dreadship Reef +4 [RAV:63] Remand +4 [TSP:259] Lotus Bloom +4 [CSP:96] Rite of Flame +1 [ARC:46] Seething Song +4 [10E:114] Telling Time +4 [UNH:139] Mountain +1 [7ED:98] Sleight of Hand +4 [M15:246] Shivan Reef +4 [RTR:247] Steam Vents +1 [TSP:270] Calciform Pools +4 [C14:173] Bogardan Hellkite +1 [PO2:46] Sleight of Hand +2 [TSB:60] Dragonstorm +2 [9ED:99] Sleight of Hand +8 [UNH:137] Island +3 [DDG:70] Seething Song +2 [SCG:90] Dragonstorm +SB: 2 [CMD:271] Dreadship Reef +SB: 1 [MM2:56] Repeal +SB: 1 [GPT:32] Repeal +SB: 1 [TSP:270] Calciform Pools +SB: 2 [DDN:72] Repeal +SB: 1 [TSP:88] Trickbind +SB: 1 [TSP:83] Teferi, Mage of Zhalfir +SB: 3 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Eldrazi Green 34 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Eldrazi Green 34 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..5bb8ba1fbcc --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Eldrazi Green 34 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,24 @@ +2 [ROE:12] Ulamog, the Infinite Gyre +4 [ROE:186] Growth Spasm +12 [UNH:140] Forest +4 [ROE:190] Joraga Treespeaker +1 [M11:226] Mystifying Maze +4 [ROE:227] Eldrazi Temple +1 [ROE:4] Emrakul, the Aeons Torn +1 [WWK:136] Eye of Ugin +4 [ROE:203] Overgrown Battlement +1 [C14:218] Terastodon +4 [M12:188] Primeval Titan +3 [C14:239] Everflowing Chalice +1 [C13:139] Cultivate +4 [ZEN:184] Summoning Trap +4 [C13:302] Khalni Garden +4 [C14:313] Tectonic Edge +1 [C13:135] Avenger of Zendikar +1 [C14:283] Wurmcoil Engine +4 [WWK:99] Explore +SB: 4 [C13:134] Acidic Slime +SB: 4 [M14:215] Ratchet Bomb +SB: 3 [M11:188] Obstinate Baloth +SB: 1 [WWK:136] Eye of Ugin +SB: 3 [ZEN:172] Oracle of Mul Daya diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(1) 58 World Championship 2007 (New York) ST 12-6-07.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(1) 58 World Championship 2007 (New York) ST 12-6-07.dck new file mode 100644 index 00000000000..2979e4b1be7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(1) 58 World Championship 2007 (New York) ST 12-6-07.dck @@ -0,0 +1,30 @@ +2 [LRW:110] Eyeblight's Ending +5 [UNH:140] Forest +3 [CMD:176] Troll Ascetic +2 [CMD:157] Garruk Wildspeaker +4 [10E:361] Treetop Village +1 [TSB:120] Pendelhaven +1 [10E:255] Civic Wayfinder +2 [C14:206] Masked Admirers +3 [FUT:153] Tarmogoyf +4 [THS:107] Thoughtseize +4 [C14:227] Wren's Run Packmaster +1 [PLC:75] Mirri the Cursed +4 [C14:204] Llanowar Elves +1 [C14:247] Loxodon Warhammer +4 [M15:244] Llanowar Wastes +4 [C14:202] Imperious Perfect +4 [C14:156] Profane Command +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [LRW:128] Nameless Inversion +1 [CSP:105] Boreal Druid +4 [LRW:268] Gilt-Leaf Palace +4 [UNH:138] Swamp +SB: 1 [C14:247] Loxodon Warhammer +SB: 2 [TSP:261] Phyrexian Totem +SB: 3 [M15:103] Liliana Vess +SB: 2 [FUT:78] Slaughter Pact +SB: 1 [C13:153] Krosan Grip +SB: 2 [10E:308] Viridian Shaman +SB: 2 [10E:340] Razormane Masticore +SB: 2 [LRW:202] Cloudthresher diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(2) 58 World Championship 2007 (New York) ST 12-6-07.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(2) 58 World Championship 2007 (New York) ST 12-6-07.dck new file mode 100644 index 00000000000..11573e6b20e --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Elves(2) 58 World Championship 2007 (New York) ST 12-6-07.dck @@ -0,0 +1,28 @@ +3 [LRW:110] Eyeblight's Ending +5 [UNH:140] Forest +3 [CMD:176] Troll Ascetic +2 [CMD:157] Garruk Wildspeaker +4 [10E:361] Treetop Village +1 [TSB:120] Pendelhaven +2 [10E:255] Civic Wayfinder +3 [C14:206] Masked Admirers +4 [FUT:153] Tarmogoyf +3 [THS:107] Thoughtseize +4 [C14:227] Wren's Run Packmaster +4 [C14:204] Llanowar Elves +4 [M15:244] Llanowar Wastes +3 [C14:202] Imperious Perfect +4 [C14:156] Profane Command +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [LRW:128] Nameless Inversion +1 [CSP:105] Boreal Druid +4 [LRW:268] Gilt-Leaf Palace +4 [UNH:138] Swamp +SB: 2 [C14:247] Loxodon Warhammer +SB: 3 [M15:103] Liliana Vess +SB: 2 [FUT:78] Slaughter Pact +SB: 1 [C13:153] Krosan Grip +SB: 2 [C14:152] Nekrataal +SB: 2 [10E:308] Viridian Shaman +SB: 1 [THS:107] Thoughtseize +SB: 2 [LRW:202] Cloudthresher diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Enduring Ideal 34 World Championship 2005 (Yokohama) ST 12-4-05.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Enduring Ideal 34 World Championship 2005 (Yokohama) ST 12-4-05.dck new file mode 100644 index 00000000000..9cd00958c53 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Enduring Ideal 34 World Championship 2005 (Yokohama) ST 12-4-05.dck @@ -0,0 +1,29 @@ +2 [SCG:93] Form of the Dragon +1 [S99:51] Sleight of Hand +1 [CHK:273] Boseiju, Who Shelters All +4 [CMD:243] Boros Signet +1 [9ED:187] Form of the Dragon +4 [BOK:165] Tendo Ice Bridge +4 [SOK:9] Enduring Ideal +4 [CMD:248] Fellwar Stone +4 [C13:27] Wrath of God +4 [RAV:16] Faith's Fetters +1 [8ED:69] Confiscate +4 [10E:114] Telling Time +4 [10E:347] Adarkar Wastes +1 [MMQ:24] Ivory Mask +1 [7ED:65] Confiscate +1 [C14:102] Compulsive Research +4 [GTC:245] Sacred Foundry +3 [9ED:99] Sleight of Hand +3 [UNH:136] Plains +1 [USG:66] Confiscate +7 [UNH:137] Island +1 [5ED:138] Zur's Weirding +SB: 1 [8ED:296] Defense Grid +SB: 1 [BOK:151] Genju of the Realm +SB: 1 [9ED:23] Ivory Mask +SB: 4 [M11:154] Pyroclasm +SB: 1 [RAV:251] Privileged Position +SB: 3 [ULG:125] Defense Grid +SB: 4 [M12:63] Mana Leak diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 34 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 34 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..f80b7f844d9 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 34 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,30 @@ +3 [AVR:32] Restoration Angel +1 [RTR:82] Ultimate Price +2 [M14:29] Planar Cleansing +4 [C13:30] Augur of Bolas +2 [GTC:249] Watery Grave +4 [M13:225] Glacial Fortress +4 [M13:223] Drowned Catacomb +4 [RTR:241] Hallowed Fountain +2 [ISD:78] Snapcaster Mage +4 [RTR:201] Supreme Verdict +1 [RTR:156] Dramatic Rescue +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +4 [ISD:242] Isolated Chapel +2 [M15:51] Dissipate +4 [ISD:245] Nephalia Drownyard +2 [GTC:63] Devour Flesh +1 [UNH:136] Plains +2 [GTC:242] Godless Shrine +2 [UNH:137] Island +4 [ISD:83] Think Twice +SB: 3 [AVR:104] Gloom Surgeon +SB: 2 [RTR:1] Angel of Serenity +SB: 2 [ISD:236] Witchbane Orb +SB: 1 [RTR:36] Dispel +SB: 1 [RTR:47] Psychic Spiral +SB: 2 [M14:97] Duress +SB: 1 [RTR:18] Rest in Peace +SB: 2 [M14:60] Jace, Memory Adept +SB: 1 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 58 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 58 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..ca6badb6c3b --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Esper Control 58 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,27 @@ +4 [THS:225] Temple of Deceit +3 [THS:47] Dissolve +4 [GTC:249] Watery Grave +4 [RTR:241] Hallowed Fountain +4 [THS:227] Temple of Silence +2 [THS:107] Thoughtseize +4 [RTR:201] Supreme Verdict +3 [RTR:200] Sphinx's Revelation +4 [RTR:145] Azorius Charm +1 [RTR:155] Detention Sphere +1 [DGM:11] AEtherling +4 [THS:90] Hero's Downfall +4 [M14:96] Doom Blade +4 [RTR:44] Jace, Architect of Thought +2 [M15:52] Divination +2 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [THS:9] Elspeth, Sun's Champion +4 [UNH:137] Island +SB: 2 [RTR:155] Detention Sphere +SB: 2 [DGM:57] Blood Baron of Vizkopa +SB: 1 [THS:49] Gainsay +SB: 1 [DGM:11] AEtherling +SB: 1 [THS:107] Thoughtseize +SB: 2 [M15:71] Negate +SB: 2 [DGM:103] Sin Collector +SB: 4 [THS:32] Soldier of the Pantheon diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Faeries 58 PT Hollywood ST 5-25-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Faeries 58 PT Hollywood ST 5-25-08.dck new file mode 100644 index 00000000000..150ce6b0183 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Faeries 58 PT Hollywood ST 5-25-08.dck @@ -0,0 +1,23 @@ +4 [10E:182] Terror +4 [LRW:271] Secluded Glen +4 [LRW:89] Spellstutter Sprite +4 [LRW:56] Cryptic Command +3 [FUT:179] River of Tears +1 [FNMP:96] Pendelhaven +1 [TSB:120] Pendelhaven +4 [10E:362] Underground River +2 [SHM:280] Sunken Ruins +4 [MOR:58] Bitterblossom +2 [C13:288] Faerie Conclave +3 [MOR:55] Vendilion Clique +4 [TSP:48] Ancestral Vision +4 [CSP:46] Rune Snag +4 [M14:228] Mutavault +4 [LRW:83] Scion of Oona +4 [LRW:75] Mistbind Clique +4 [UNH:137] Island +SB: 3 [C14:231] Bottle Gnomes +SB: 3 [10E:340] Razormane Masticore +SB: 4 [THS:107] Thoughtseize +SB: 3 [PLC:85] Damnation +SB: 2 [SHM:192] Murderous Redcap diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Fauna Quest 58 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Fauna Quest 58 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..8591438ab1e --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Fauna Quest 58 PT Paris ST 2-13-11.dck @@ -0,0 +1,26 @@ +4 [SOM:174] Memnite +3 [WWK:144] Stirring Wildwood +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +2 [SOM:10] Glint Hawk +4 [ROE:212] Vengevine +2 [C14:228] Argentum Armor +4 [ZEN:23] Kor Skyfisher +4 [M11:172] Fauna Shaman +4 [M15:223] Ornithopter +1 [ZEN:21] Kor Outfitter +1 [SOM:208] Sword of Body and Mind +4 [ZEN:33] Quest for the Holy Relic +4 [SOM:228] Razorverge Thicket +4 [M11:33] Squadron Hawk +1 [WWK:20] Stoneforge Mystic +8 [UNH:136] Plains +2 [SOM:156] Glint Hawk Idol +SB: 1 [ROE:33] Linvala, Keeper of Silence +SB: 1 [MBS:10] Leonin Relic-Warder +SB: 1 [M13:39] War Priest of Thune +SB: 4 [SOM:14] Leonin Arbiter +SB: 2 [WWK:17] Refraction Trap +SB: 4 [ZEN:10] Devout Lightcaster +SB: 1 [M11:7] Baneslayer Angel +SB: 1 [WWK:11] Kor Firewalker diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GB Elves 34 PT Hollywood ST 5-25-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GB Elves 34 PT Hollywood ST 5-25-08.dck new file mode 100644 index 00000000000..6865f55ee9f --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GB Elves 34 PT Hollywood ST 5-25-08.dck @@ -0,0 +1,24 @@ +1 [LEG:250] Pendelhaven +3 [UNH:140] Forest +4 [CMD:157] Garruk Wildspeaker +4 [10E:361] Treetop Village +1 [TSB:120] Pendelhaven +3 [10E:255] Civic Wayfinder +4 [FUT:153] Tarmogoyf +4 [THS:107] Thoughtseize +4 [C14:204] Llanowar Elves +4 [M15:244] Llanowar Wastes +4 [C14:202] Imperious Perfect +4 [C14:156] Profane Command +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [M14:228] Mutavault +3 [LRW:128] Nameless Inversion +2 [CSP:105] Boreal Druid +4 [LRW:245] Wren's Run Vanquisher +2 [UNH:138] Swamp +4 [LRW:268] Gilt-Leaf Palace +SB: 4 [MOR:58] Bitterblossom +SB: 2 [SHM:70] Incremental Blight +SB: 2 [10E:182] Terror +SB: 4 [C14:160] Shriekmaw +SB: 3 [LRW:233] Primal Command diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GW Aggro 2 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GW Aggro 2 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..f9eee806beb --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/GW Aggro 2 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,24 @@ +3 [SOM:6] Elspeth Tirel +4 [M13:229] Sunpetal Grove +8 [UNH:140] Forest +1 [C14:72] Geist-Honored Monk +4 [NPH:4] Blade Splicer +4 [M12:165] Birds of Paradise +4 [ISD:170] Avacyn's Pilgrim +4 [ISD:181] Garruk Relentless +2 [NPH:86] Gut Shot +4 [SOM:228] Razorverge Thicket +3 [MBS:115] Mortarpod +4 [M13:22] Oblivion Ring +4 [ISD:239] Gavony Township +5 [UNH:136] Plains +2 [MBS:14] Mirran Crusader +4 [MBS:8] Hero of Bladehold +SB: 1 [ISD:23] Mikaeus, the Lunarch +SB: 2 [KTK:142] Naturalize +SB: 2 [NPH:86] Gut Shot +SB: 1 [NPH:161] Sword of War and Peace +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 2 [M12:11] Celestial Purge +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 3 [M12:40] Timely Reinforcements diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Greater Gift 2 World Championship 2005 (Yokohama) ST 12-4-05.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Greater Gift 2 World Championship 2005 (Yokohama) ST 12-4-05.dck new file mode 100644 index 00000000000..76629698819 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Greater Gift 2 World Championship 2005 (Yokohama) ST 12-4-05.dck @@ -0,0 +1,42 @@ +3 [CHK:268] Sensei's Divining Top +1 [SOK:163] Miren, the Moaning Well +1 [RAV:93] Last Gasp +2 [CHK:122] Kokusho, the Evening Star +4 [UNH:140] Forest +1 [CHK:283] Shizo, Death's Storehouse +2 [BOK:165] Tendo Ice Bridge +1 [CHK:280] Okina, Temple to the Grandfathers +1 [10E:289] Recollect +4 [CNS:177] Sakura-Tribe Elder +2 [10E:349] Brushland +3 [CHK:62] Gifts Ungiven +2 [RTR:243] Overgrown Tomb +2 [M13:170] Farseek +2 [RTR:248] Temple Garden +3 [BOK:67] Goryo's Vengeance +1 [DGM:93] Putrefy +3 [UNH:136] Plains +1 [UNH:137] Island +3 [UNH:138] Swamp +1 [JR:81] Greater Good +4 [CMD:163] Kodama's Reach +1 [GTC:249] Watery Grave +4 [C13:27] Wrath of God +4 [CHK:50] Yosei, the Morning Star +1 [M12:191] Reclaim +2 [USG:257] Greater Good +1 [SOK:73] Kagemaro, First to Suffer +SB: 1 [CHK:115] Hideous Laughter +SB: 1 [CHK:211] Hana Kami +SB: 1 [8ED:296] Defense Grid +SB: 1 [RAV:93] Last Gasp +SB: 1 [9ED:293] Defense Grid +SB: 1 [CHK:144] Soulless Revival +SB: 1 [RAV:214] Loxodon Hierarch +SB: 1 [CHK:74] Meloku the Clouded Mirror +SB: 1 [SOK:63] Death Denied +SB: 1 [CHK:105] Cranial Extraction +SB: 2 [ULG:125] Defense Grid +SB: 1 [CHK:205] Dosan the Falling Leaf +SB: 1 [BOK:71] Ink-Eyes, Servant of Oni +SB: 1 [SOK:143] Rending Vines diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Deck Wins 1 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Deck Wins 1 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..347d041b361 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Deck Wins 1 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,25 @@ +1 [THS:224] Temple of Abandon +1 [UNH:140] Forest +4 [KTK:118] Monastery Swiftspear +4 [FRF:118] Wild Slash +4 [KTK:249] Wooded Foothills +4 [M15:141] Foundry Street Denizen +1 [M15:142] Frenzied Goblin +4 [M15:164] Stoke the Flames +10 [UNH:139] Mountain +4 [M15:155] Lightning Strike +2 [M15:145] Goblin Rabblemaster +4 [KTK:111] Hordeling Outburst +1 [KTK:130] Become Immense +1 [DTK:146] Lightning Berserker +4 [DTK:135] Dragon Fodder +3 [DTK:169] Zurgo Bellstriker +4 [DTK:213] Atarka's Command +4 [JOU:163] Mana Confluence +SB: 2 [M15:145] Goblin Rabblemaster +SB: 1 [BNG:110] Scouring Sands +SB: 2 [JOU:162] Hall of Triumph +SB: 4 [JOU:94] Eidolon of the Great Revel +SB: 1 [FRF:102] Goblin Heelcutter +SB: 4 [DTK:151] Roast +SB: 1 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Dragons 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Dragons 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..c2c0d413f52 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Gruul Dragons 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,25 @@ +4 [THS:224] Temple of Abandon +4 [THS:143] Stormbreath Dragon +6 [UNH:140] Forest +1 [FRF:170] Rugged Highlands +4 [KTK:249] Wooded Foothills +4 [KTK:106] Crater's Claws +3 [KTK:134] Heir of the Wilds +1 [DTK:249] Haven of the Spirit Dragon +5 [UNH:139] Mountain +4 [M15:145] Goblin Rabblemaster +4 [KTK:144] Rattleclaw Mystic +2 [JOU:163] Mana Confluence +3 [DTK:210] Surrak, the Hunt Caller +4 [THS:152] Boon Satyr +2 [DTK:134] Draconic Roar +4 [C14:191] Elvish Mystic +4 [DTK:162] Thunderbreak Regent +1 [DTK:151] Roast +SB: 3 [M15:177] Hornet Nest +SB: 3 [THS:209] Xenagos, the Reveler +SB: 2 [KTK:97] Arc Lightning +SB: 3 [FRF:118] Wild Slash +SB: 1 [M15:192] Plummet +SB: 1 [DTK:151] Roast +SB: 2 [THS:192] Destructive Revelry diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Heartbeat 58 PT Honolulu ST 3-5-06.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Heartbeat 58 PT Honolulu ST 3-5-06.dck new file mode 100644 index 00000000000..c012292208f --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Heartbeat 58 PT Honolulu ST 3-5-06.dck @@ -0,0 +1,27 @@ +4 [CHK:268] Sensei's Divining Top +4 [CHK:212] Heartbeat of Spring +4 [RAV:60] Muddle the Mixture +1 [9ED:282] Weird Harvest +4 [CMD:163] Kodama's Reach +10 [UNH:140] Forest +1 [7ED:237] Early Harvest +4 [RAV:63] Remand +4 [RAV:46] Drift of Phantasms +1 [9ED:235] Early Harvest +1 [10E:289] Recollect +4 [CNS:177] Sakura-Tribe Elder +1 [UNH:139] Mountain +1 [C14:102] Compulsive Research +2 [MIR:111] Early Harvest +1 [10E:70] Boomerang +1 [DDJ:31] Invoke the Firemind +10 [UNH:137] Island +1 [SOK:81] Maga, Traitor to Mortals +1 [UNH:138] Swamp +SB: 2 [CHK:74] Meloku the Clouded Mirror +SB: 4 [RAV:189] Vinelasher Kudzu +SB: 1 [CHK:72] Keiga, the Tide Star +SB: 3 [C13:208] Savage Twister +SB: 3 [BOK:130] Iwamori of the Open Fist +SB: 1 [BOK:163] Umezawa's Jitte +SB: 1 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Izzetron 58 PT Honolulu ST 3-5-06.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Izzetron 58 PT Honolulu ST 3-5-06.dck new file mode 100644 index 00000000000..0ffe78a74ab --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Izzetron 58 PT Honolulu ST 3-5-06.dck @@ -0,0 +1,34 @@ +4 [CMD:252] Izzet Signet +4 [CMD:197] Electrolyze +2 [BOK:165] Tendo Ice Bridge +1 [9ED:327] Urza's Mine +1 [9ED:329] Urza's Tower +4 [C14:102] Compulsive Research +4 [M15:246] Shivan Reef +4 [RTR:247] Steam Vents +2 [9ED:68] Confiscate +1 [CHK:279] Minamo, School at Water's Edge +2 [8ED:330] Urza's Tower +1 [10E:190] Blaze +4 [RAV:63] Remand +1 [ATQ:75] Urza's Mine +2 [M11:154] Pyroclasm +2 [10E:114] Telling Time +2 [ME4:258] Urza's Power Plant +1 [ME4:257] Urza's Mine +4 [CHK:74] Meloku the Clouded Mirror +1 [10E:116] Tidings +1 [ME4:259] Urza's Tower +4 [CHK:72] Keiga, the Tide Star +1 [DDJ:31] Invoke the Firemind +2 [5ED:448] Urza's Power Plant +1 [8ED:328] Urza's Mine +4 [M12:63] Mana Leak +SB: 4 [GPT:143] Giant Solifuge +SB: 1 [GPT:32] Repeal +SB: 1 [CHK:185] Ryusei, The Falling Star +SB: 1 [DDN:72] Repeal +SB: 2 [ONS:63] Annex +SB: 2 [M11:154] Pyroclasm +SB: 2 [9ED:59] Annex +SB: 2 [10E:235] Smash diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Ascendancy 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Ascendancy 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..8fc729be8c2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Ascendancy 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,29 @@ +2 [THS:224] Temple of Abandon +2 [JOU:115] Twinflame +2 [THS:226] Temple of Mystery +1 [UNH:140] Forest +4 [BNG:49] Retraction Helix +4 [THS:155] Commune with the Gods +2 [KTK:217] Briber's Purse +2 [KTK:249] Wooded Foothills +3 [KTK:36] Dig Through Time +2 [KTK:233] Flooded Strand +4 [THS:119] Dragon Mantle +3 [KTK:123] Tormenting Voice +2 [KTK:234] Frontier Bivouac +1 [M15:187] Nissa, Worldwaker +1 [UNH:139] Mountain +4 [KTK:144] Rattleclaw Mystic +2 [M15:249] Yavimaya Coast +2 [BNG:165] Temple of Plenty +4 [JOU:163] Mana Confluence +4 [KTK:180] Jeskai Ascendancy +1 [UNH:136] Plains +3 [BNG:150] Kiora's Follower +1 [UNH:137] Island +4 [THS:180] Sylvan Caryatid +SB: 3 [M15:155] Lightning Strike +SB: 4 [KTK:197] Savage Knuckleblade +SB: 3 [KTK:97] Arc Lightning +SB: 2 [THS:172] Polukranos, World Eater +SB: 3 [THS:65] Swan Song diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo 2 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo 2 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..5f0b63eb464 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo 2 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,28 @@ +2 [JOU:5] Banishing Light +2 [THS:112] Anger of the Gods +2 [KTK:119] Sarkhan, the Dragonspeaker +1 [KTK:22] Seeker of the Way +4 [THS:128] Magma Jet +1 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +4 [KTK:36] Dig Through Time +4 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +3 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +2 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +4 [JOU:164] Temple of Epiphany +1 [UNH:136] Plains +2 [UNH:137] Island +SB: 3 [THS:47] Dissolve +SB: 1 [M15:225] Phyrexian Revoker +SB: 2 [KTK:9] Erase +SB: 2 [KTK:8] End Hostilities +SB: 2 [THS:112] Anger of the Gods +SB: 2 [JOU:151] Keranos, God of Storms +SB: 1 [KTK:37] Disdainful Stroke +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(1) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(1) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..7c943a501d4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(1) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,25 @@ +3 [BNG:5] Brimaz, King of Oreskos +2 [THS:16] Gods Willing +3 [KTK:119] Sarkhan, the Dragonspeaker +4 [KTK:22] Seeker of the Way +4 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +4 [KTK:236] Mystic Monastery +4 [THS:228] Temple of Triumph +3 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +3 [UNH:139] Mountain +4 [M15:155] Lightning Strike +4 [M15:145] Goblin Rabblemaster +3 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +2 [UNH:136] Plains +2 [UNH:137] Island +SB: 1 [M15:134] Chandra, Pyromaster +SB: 3 [JOU:103] Magma Spray +SB: 1 [THS:16] Gods Willing +SB: 2 [THS:60] Prognostic Sphinx +SB: 4 [KTK:25] Suspension Field +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 3 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(2) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(2) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..e70b3c3eaf1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jeskai Tempo(2) 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,25 @@ +4 [M15:15] Hushwing Gryff +2 [THS:143] Stormbreath Dragon +3 [JOU:5] Banishing Light +3 [KTK:99] Ashcloud Phoenix +4 [KTK:22] Seeker of the Way +4 [THS:128] Magma Jet +3 [M15:240] Battlefield Forge +3 [THS:228] Temple of Triumph +4 [KTK:236] Mystic Monastery +3 [KTK:233] Flooded Strand +4 [M15:164] Stoke the Flames +3 [UNH:139] Mountain +4 [M15:155] Lightning Strike +3 [M15:246] Shivan Reef +4 [KTK:184] Mantis Rider +4 [KTK:181] Jeskai Charm +2 [JOU:164] Temple of Epiphany +1 [UNH:136] Plains +2 [UNH:137] Island +SB: 3 [JOU:103] Magma Spray +SB: 1 [THS:49] Gainsay +SB: 2 [THS:112] Anger of the Gods +SB: 3 [THS:60] Prognostic Sphinx +SB: 3 [KTK:25] Suspension Field +SB: 3 [KTK:37] Disdainful Stroke diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 1 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 1 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..08f27a9ce86 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 1 PT San Diego ST 2-21-10.dck @@ -0,0 +1,25 @@ +4 [WWK:141] Raging Ravine +4 [ALA:156] Blightning +1 [M13:228] Rootbound Crag +4 [UNH:140] Forest +4 [M11:149] Lightning Bolt +2 [CMD:157] Garruk Wildspeaker +3 [M10:157] Siege-Gang Commander +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +2 [M13:222] Dragonskull Summit +3 [ALA:160] Broodmate Dragon +2 [WWK:139] Lavaclaw Reaches +3 [UNH:139] Mountain +3 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +2 [M12:190] Rampant Growth +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +3 [UNH:138] Swamp +SB: 1 [ARB:92] Maelstrom Pulse +SB: 4 [M12:90] Deathmark +SB: 3 [M10:191] Master of the Wild Hunt +SB: 1 [RTR:231] Pithing Needle +SB: 2 [CMD:231] Terminate +SB: 4 [M10:186] Great Sable Stag diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..29b66e022cf --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 PT San Diego ST 2-21-10.dck @@ -0,0 +1,27 @@ +4 [WWK:141] Raging Ravine +4 [ALA:156] Blightning +2 [M13:228] Rootbound Crag +3 [UNH:140] Forest +2 [CMD:231] Terminate +4 [M11:149] Lightning Bolt +3 [CMD:157] Garruk Wildspeaker +2 [M10:157] Siege-Gang Commander +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +3 [M13:222] Dragonskull Summit +2 [ALA:160] Broodmate Dragon +3 [UNH:139] Mountain +3 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +2 [WWK:99] Explore +3 [UNH:138] Swamp +SB: 2 [M12:90] Deathmark +SB: 1 [M15:104] Mind Rot +SB: 1 [CMD:231] Terminate +SB: 4 [ZEN:127] Goblin Ruinblaster +SB: 1 [ARB:34] Bituminous Blast +SB: 3 [M14:97] Duress +SB: 1 [ZEN:100] Malakir Bloodwitch +SB: 2 [M10:186] Great Sable Stag diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..1ccc3a28234 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 2 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,26 @@ +4 [ALA:156] Blightning +2 [UNH:140] Forest +4 [M13:228] Rootbound Crag +2 [CMD:231] Terminate +4 [M11:149] Lightning Bolt +2 [CMD:157] Garruk Wildspeaker +3 [ARB:34] Bituminous Blast +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +3 [M13:222] Dragonskull Summit +2 [C14:305] Oran-Rief, the Vastwood +2 [ALA:160] Broodmate Dragon +3 [UNH:139] Mountain +3 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +1 [ZEN:119] Burst Lightning +2 [M10:191] Master of the Wild Hunt +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +3 [UNH:138] Swamp +SB: 1 [ARB:92] Maelstrom Pulse +SB: 2 [C13:195] Jund Charm +SB: 4 [ZEN:127] Goblin Ruinblaster +SB: 3 [M14:97] Duress +SB: 3 [M10:186] Great Sable Stag +SB: 2 [ARB:47] Thought Hemorrhage diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 34 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 34 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..58cf8b52a21 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 34 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,32 @@ +3 [THS:224] Temple of Abandon +1 [UNH:140] Forest +2 [JOU:165] Temple of Malady +3 [THS:209] Xenagos, the Reveler +2 [RTR:164] Golgari Charm +1 [RTR:141] Abrupt Decay +2 [RTR:157] Dreadbore +4 [M15:244] Llanowar Wastes +3 [M15:134] Chandra, Pyromaster +3 [RTR:101] Mizzium Mortars +4 [C14:158] Read the Bones +2 [RTR:243] Overgrown Tomb +4 [BNG:119] Courser of Kruphix +2 [RTR:188] Rakdos's Return +2 [RTR:238] Blood Crypt +1 [THS:90] Hero's Downfall +1 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +4 [BNG:164] Temple of Malice +3 [RTR:208] Vraska the Unseen +2 [DGM:93] Putrefy +3 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [RTR:188] Rakdos's Return +SB: 4 [JOU:103] Magma Spray +SB: 1 [RTR:231] Pithing Needle +SB: 2 [M14:97] Duress +SB: 2 [RTR:197] Slaughter Games +SB: 1 [RTR:164] Golgari Charm +SB: 2 [THS:107] Thoughtseize +SB: 1 [RTR:141] Abrupt Decay diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..d99bdf0a783 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,32 @@ +2 [RTR:82] Ultimate Price +4 [THS:224] Temple of Abandon +3 [UNH:140] Forest +4 [THS:209] Xenagos, the Reveler +1 [RTR:164] Golgari Charm +1 [RTR:141] Abrupt Decay +2 [THS:107] Thoughtseize +4 [M15:187] Nissa, Worldwaker +2 [RTR:157] Dreadbore +3 [M15:244] Llanowar Wastes +2 [M15:134] Chandra, Pyromaster +3 [RTR:101] Mizzium Mortars +2 [RTR:243] Overgrown Tomb +4 [BNG:119] Courser of Kruphix +1 [RTR:188] Rakdos's Return +1 [RTR:238] Blood Crypt +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [M14:228] Mutavault +4 [GTC:247] Stomping Ground +4 [BNG:164] Temple of Malice +1 [RTR:208] Vraska the Unseen +1 [DGM:93] Putrefy +4 [C14:191] Elvish Mystic +4 [THS:180] Sylvan Caryatid +SB: 1 [RTR:101] Mizzium Mortars +SB: 1 [RTR:188] Rakdos's Return +SB: 2 [JOU:103] Magma Spray +SB: 2 [M14:96] Doom Blade +SB: 4 [THS:162] Mistcutter Hydra +SB: 1 [RTR:164] Golgari Charm +SB: 2 [M14:195] Scavenging Ooze +SB: 2 [THS:107] Thoughtseize diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..8884498cb03 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund 58 PT San Diego ST 2-21-10.dck @@ -0,0 +1,23 @@ +4 [WWK:141] Raging Ravine +4 [ALA:156] Blightning +3 [UNH:140] Forest +3 [CMD:231] Terminate +4 [M11:149] Lightning Bolt +3 [ARB:34] Bituminous Blast +3 [M10:157] Siege-Gang Commander +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +4 [M13:222] Dragonskull Summit +2 [ALA:160] Broodmate Dragon +4 [UNH:139] Mountain +3 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +3 [UNH:138] Swamp +SB: 1 [ARB:92] Maelstrom Pulse +SB: 3 [M10:191] Master of the Wild Hunt +SB: 1 [M15:103] Liliana Vess +SB: 2 [M15:104] Mind Rot +SB: 4 [ZEN:127] Goblin Ruinblaster +SB: 4 [M14:97] Duress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(1) 58 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(1) 58 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..d89a80d4c4d --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(1) 58 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,32 @@ +1 [RTR:82] Ultimate Price +1 [M13:228] Rootbound Crag +3 [UNH:140] Forest +3 [M13:222] Dragonskull Summit +1 [M13:101] Murder +2 [RTR:141] Abrupt Decay +2 [M13:174] Garruk, Primal Hunter +1 [RTR:157] Dreadbore +4 [RTR:243] Overgrown Tomb +2 [RTR:188] Rakdos's Return +3 [M13:160] Arbor Elf +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +2 [AVR:149] Pillar of Flame +4 [AVR:129] Bonfire of the Damned +4 [GTC:247] Stomping Ground +4 [DKA:140] Huntmaster of the Fells +4 [ISD:249] Woodland Cemetery +2 [ISD:215] Olivia Voldaren +3 [ISD:105] Liliana of the Veil +SB: 2 [RTR:83] Underworld Connections +SB: 1 [RTR:188] Rakdos's Return +SB: 1 [C14:167] Tragic Slip +SB: 2 [DKA:149] Grafdigger's Cage +SB: 2 [DKA:127] Strangleroot Geist +SB: 1 [AVR:149] Pillar of Flame +SB: 2 [M13:217] Staff of Nin +SB: 2 [M14:97] Duress +SB: 1 [M13:101] Murder +SB: 1 [ISD:215] Olivia Voldaren diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(2) 58 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(2) 58 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..95e709d4bf1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund Control(2) 58 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,30 @@ +2 [C13:97] Vampire Nighthawk +1 [UNH:140] Forest +4 [M13:228] Rootbound Crag +4 [M13:222] Dragonskull Summit +2 [RTR:141] Abrupt Decay +2 [M13:174] Garruk, Primal Hunter +2 [RTR:157] Dreadbore +3 [RTR:101] Mizzium Mortars +4 [RTR:243] Overgrown Tomb +2 [RTR:188] Rakdos's Return +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [RTR:238] Blood Crypt +4 [M13:170] Farseek +1 [GTC:247] Stomping Ground +2 [ISD:124] Victim of Night +4 [DKA:140] Huntmaster of the Fells +2 [ISD:96] Dead Weight +4 [ISD:249] Woodland Cemetery +1 [UNH:138] Swamp +3 [ISD:215] Olivia Voldaren +3 [ISD:105] Liliana of the Veil +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [RTR:83] Underworld Connections +SB: 1 [DKA:149] Grafdigger's Cage +SB: 2 [AVR:85] Barter in Blood +SB: 3 [RTR:213] Deathrite Shaman +SB: 2 [M14:97] Duress +SB: 2 [ISD:96] Dead Weight +SB: 2 [RTR:197] Slaughter Games diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(1) 58 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(1) 58 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..d5fc2d2c3d3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(1) 58 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,24 @@ +4 [ALA:156] Blightning +3 [UNH:140] Forest +4 [M13:228] Rootbound Crag +2 [CMD:231] Terminate +4 [M11:149] Lightning Bolt +3 [CMD:157] Garruk Wildspeaker +3 [ARB:34] Bituminous Blast +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +3 [M13:222] Dragonskull Summit +3 [ALA:160] Broodmate Dragon +3 [UNH:139] Mountain +3 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +1 [AVR:169] Borderland Ranger +4 [UNH:138] Swamp +SB: 3 [M15:104] Mind Rot +SB: 2 [ALA:95] Caldera Hellion +SB: 3 [ZEN:127] Goblin Ruinblaster +SB: 3 [C13:195] Jund Charm +SB: 2 [CMD:231] Terminate +SB: 2 [ARB:47] Thought Hemorrhage diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(2) 58 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(2) 58 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..a5cf22fdf4a --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Jund(2) 58 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,25 @@ +4 [ALA:156] Blightning +2 [UNH:140] Forest +3 [M13:228] Rootbound Crag +2 [CMD:231] Terminate +4 [M11:149] Lightning Bolt +3 [CMD:157] Garruk Wildspeaker +3 [ARB:34] Bituminous Blast +4 [C13:219] Sprouting Thrinax +4 [C13:317] Savage Lands +3 [M13:222] Dragonskull Summit +1 [C14:305] Oran-Rief, the Vastwood +3 [ALA:160] Broodmate Dragon +4 [UNH:139] Mountain +4 [ARB:92] Maelstrom Pulse +4 [ZEN:229] Verdant Catacombs +1 [C13:298] Jund Panorama +4 [ARB:50] Bloodbraid Elf +4 [ARB:95] Putrid Leech +3 [UNH:138] Swamp +SB: 2 [M15:104] Mind Rot +SB: 4 [ZEN:127] Goblin Ruinblaster +SB: 3 [C13:195] Jund Charm +SB: 1 [ARB:34] Bituminous Blast +SB: 3 [M14:97] Duress +SB: 2 [ARB:47] Thought Hemorrhage diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Bant 58 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Bant 58 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..05f7a34a8b4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Bant 58 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,31 @@ +4 [AVR:32] Restoration Angel +2 [M13:229] Sunpetal Grove +3 [C13:30] Augur of Bolas +1 [RTR:54] Syncopate +3 [M13:225] Glacial Fortress +4 [RTR:241] Hallowed Fountain +3 [RTR:201] Supreme Verdict +4 [RTR:145] Azorius Charm +4 [RTR:200] Sphinx's Revelation +1 [RTR:155] Detention Sphere +4 [M13:193] Thragtusk +2 [ISD:243] Kessig Wolf Run +4 [M13:170] Farseek +3 [RTR:248] Temple Garden +1 [RTR:247] Steam Vents +4 [ISD:241] Hinterland Harbor +3 [RTR:148] Centaur Healer +1 [GTC:247] Stomping Ground +2 [M15:51] Dissipate +1 [GTC:245] Sacred Foundry +2 [ISD:83] Think Twice +4 [GTC:240] Breeding Pool +SB: 1 [RTR:201] Supreme Verdict +SB: 1 [RTR:155] Detention Sphere +SB: 1 [AVR:209] Gisela, Blade of Goldnight +SB: 3 [M13:29] Rhox Faithmender +SB: 2 [ISD:181] Garruk Relentless +SB: 1 [RTR:148] Centaur Healer +SB: 2 [ISD:236] Witchbane Orb +SB: 2 [RTR:18] Rest in Peace +SB: 2 [M15:71] Negate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..1ebda5ca46d --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,28 @@ +4 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +2 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [C14:184] Whipflare +4 [MBS:145] Inkmoth Nexus +3 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +4 [SOM:91] Galvanic Blast +SB: 1 [M13:174] Garruk, Primal Hunter +SB: 2 [KTK:142] Naturalize +SB: 2 [M12:128] Combust +SB: 1 [C14:184] Whipflare +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [NPH:103] Beast Within +SB: 1 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge +SB: 2 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..f93361f80cf --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 1 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,26 @@ +3 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +4 [C13:114] Inferno Titan +2 [ISD:140] Devil's Play +1 [M14:155] Shock +3 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +4 [MBS:145] Inkmoth Nexus +4 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [SOM:91] Galvanic Blast +SB: 1 [MBS:75] Slagstorm +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [MBS:94] Viridian Corrupter +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 1 [NPH:103] Beast Within +SB: 2 [ISD:207] Tree of Redemption +SB: 4 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 2 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 2 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..cf3700a7a16 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kessig Titan 2 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,28 @@ +4 [MBS:75] Slagstorm +4 [M13:228] Rootbound Crag +5 [UNH:140] Forest +1 [MBS:92] Thrun, the Last Troll +2 [MBS:81] Green Sun's Zenith +4 [M12:188] Primeval Titan +1 [M12:165] Birds of Paradise +6 [UNH:139] Mountain +2 [C13:114] Inferno Titan +1 [C13:134] Acidic Slime +2 [ISD:243] Kessig Wolf Run +4 [M12:190] Rampant Growth +1 [C14:184] Whipflare +4 [MBS:145] Inkmoth Nexus +3 [C14:271] Solemn Simulacrum +4 [MBS:134] Sphere of the Suns +4 [SOM:225] Copperline Gorge +4 [DKA:140] Huntmaster of the Fells +4 [SOM:91] Galvanic Blast +SB: 2 [M13:174] Garruk, Primal Hunter +SB: 2 [KTK:142] Naturalize +SB: 1 [M12:128] Combust +SB: 1 [C14:184] Whipflare +SB: 2 [MBS:92] Thrun, the Last Troll +SB: 2 [NPH:103] Beast Within +SB: 1 [M12:164] Autumn's Veil +SB: 2 [ISD:127] Ancient Grudge +SB: 2 [NPH:1] Karn Liberated diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kithkins 34 World Championship 2008 (Memphis) ST 12-14-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kithkins 34 World Championship 2008 (Memphis) ST 12-14-08.dck new file mode 100644 index 00000000000..c0575fdd578 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Kithkins 34 World Championship 2008 (Memphis) ST 12-14-08.dck @@ -0,0 +1,21 @@ +3 [ALA:21] Ranger of Eos +4 [LRW:28] Knight of Meadowgrain +4 [LRW:49] Wizened Cenn +1 [LRW:7] Burrenton Forge-Tender +4 [LRW:10] Cloudgoat Ranger +4 [EVE:96] Unmake +4 [LRW:281] Windbrisk Heights +1 [M11:1] Ajani Goldmane +4 [LRW:18] Goldmeadow Stalwart +4 [MOR:150] Rustic Clachan +4 [EVE:139] Figure of Destiny +4 [C14:90] Spectral Procession +17 [UNH:136] Plains +2 [ALA:9] Elspeth, Knight-Errant +SB: 3 [MOR:22] Reveillark +SB: 4 [EVE:95] Stillmoon Cavalier +SB: 2 [LRW:7] Burrenton Forge-Tender +SB: 1 [SHM:245] Wilt-Leaf Liege +SB: 1 [M11:1] Ajani Goldmane +SB: 2 [M13:22] Oblivion Ring +SB: 2 [ALA:16] Knight of the White Orchid diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono Red Aggro 58 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono Red Aggro 58 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..3121ad3ad36 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono Red Aggro 58 PT San Diego ST 2-21-10.dck @@ -0,0 +1,22 @@ +4 [WWK:90] Searing Blaze +4 [M10:125] Ball Lightning +2 [DDK:46] Hellspark Elemental +4 [M11:149] Lightning Bolt +4 [ZEN:211] Arid Mesa +4 [ALA:103] Hell's Thunder +1 [GRC:25] Hellspark Elemental +13 [UNH:139] Mountain +3 [CMD:121] Earthquake +1 [CON:65] Hellspark Elemental +4 [ZEN:141] Plated Geopede +2 [CON:70] Quenchable Fire +3 [ZEN:119] Burst Lightning +4 [ZEN:126] Goblin Guide +4 [ZEN:223] Scalding Tarn +3 [ZEN:226] Teetering Peaks +SB: 4 [ZEN:153] Unstable Footing +SB: 2 [CON:70] Quenchable Fire +SB: 2 [ZEN:131] Hellkite Charger +SB: 2 [M12:150] Manabarbs +SB: 2 [CMD:131] Punishing Fire +SB: 3 [M12:206] Dragon's Claw diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono W Tokens World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono W Tokens World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..3a9811d7ebe --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mono W Tokens World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,23 @@ +2 [ZEN:11] Emeria Angel +2 [M11:39] White Knight +4 [ALA:21] Ranger of Eos +14 [UNH:136] Plains +4 [ZEN:211] Arid Mesa +4 [ALA:16] Knight of the White Orchid +4 [ZEN:8] Conqueror's Pledge +1 [C14:78] Martial Coup +3 [M13:22] Oblivion Ring +4 [ZEN:219] Marsh Flats +4 [ZEN:36] Steppe Lynx +2 [C14:66] Brave the Elements +4 [CMD:25] Path to Exile +4 [M12:23] Honor of the Pure +2 [C14:297] Gargoyle Castle +2 [M10:34] Soul Warden +SB: 3 [ZEN:25] Luminarch Ascension +SB: 4 [ZEN:10] Devout Lightcaster +SB: 1 [C14:66] Brave the Elements +SB: 1 [CMD:17] Journey to Nowhere +SB: 2 [M10:34] Soul Warden +SB: 2 [ALA:9] Elspeth, Knight-Errant +SB: 2 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 1 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 1 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..2ccf3591b4c --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 1 PT Paris ST 2-13-11.dck @@ -0,0 +1,26 @@ +4 [WWK:133] Celestial Colonnade +3 [M12:16] Gideon Jura +1 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +4 [UNH:136] Plains +4 [WWK:31] Jace, the Mind Sculptor +3 [M12:63] Mana Leak +1 [ROE:59] Deprive +1 [MBS:138] Sword of Feast and Famine +1 [SOM:46] Stoic Rebuttal +1 [SOM:209] Sylvok Lifestaff +4 [SOM:229] Seachrome Coast +4 [C14:313] Tectonic Edge +4 [M13:225] Glacial Fortress +4 [M11:70] Preordain +4 [ZEN:67] Spell Pierce +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [M12:12] Day of Judgment +SB: 1 [SOM:208] Sword of Body and Mind +SB: 1 [M15:71] Negate +SB: 2 [M11:7] Baneslayer Angel +SB: 2 [M12:52] Flashfreeze +SB: 4 [ROE:40] Oust +SB: 3 [M14:215] Ratchet Bomb +SB: 2 [MBS:5] Divine Offering diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 34 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 34 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..ca5cf0e9912 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go 34 PT Paris ST 2-13-11.dck @@ -0,0 +1,30 @@ +4 [WWK:133] Celestial Colonnade +2 [ZEN:70] Spreading Seas +2 [M12:16] Gideon Jura +4 [UNH:137] Island +3 [WWK:31] Jace, the Mind Sculptor +5 [UNH:136] Plains +2 [CMD:17] Journey to Nowhere +1 [ROE:59] Deprive +1 [MBS:138] Sword of Feast and Famine +1 [SOM:135] Venser, the Sojourner +1 [C14:115] Into the Roil +1 [SOM:208] Sword of Body and Mind +2 [C14:91] Sun Titan +1 [ZEN:219] Marsh Flats +4 [SOM:229] Seachrome Coast +4 [C14:313] Tectonic Edge +2 [SOM:218] Tumble Magnet +4 [M13:225] Glacial Fortress +4 [M11:70] Preordain +2 [WWK:20] Stoneforge Mystic +4 [M11:33] Squadron Hawk +2 [SOM:6] Elspeth Tirel +4 [M12:12] Day of Judgment +SB: 2 [BNG:25] Revoke Existence +SB: 4 [ZEN:25] Luminarch Ascension +SB: 2 [ZEN:70] Spreading Seas +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [C14:76] Kor Sanctifiers +SB: 2 [C14:69] Condemn +SB: 3 [M11:21] Leyline of Sanctity diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(1) 58 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(1) 58 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..c70eba85b04 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(1) 58 PT Paris ST 2-13-11.dck @@ -0,0 +1,26 @@ +4 [WWK:133] Celestial Colonnade +3 [M12:16] Gideon Jura +5 [UNH:137] Island +4 [UNH:136] Plains +4 [WWK:31] Jace, the Mind Sculptor +3 [M12:63] Mana Leak +1 [ROE:59] Deprive +1 [ZEN:211] Arid Mesa +1 [MBS:138] Sword of Feast and Famine +1 [SOM:46] Stoic Rebuttal +1 [SOM:209] Sylvok Lifestaff +4 [SOM:229] Seachrome Coast +4 [C14:313] Tectonic Edge +4 [M13:225] Glacial Fortress +4 [M11:70] Preordain +4 [ZEN:67] Spell Pierce +4 [M11:33] Squadron Hawk +4 [WWK:20] Stoneforge Mystic +4 [M12:12] Day of Judgment +SB: 1 [SOM:208] Sword of Body and Mind +SB: 1 [M11:7] Baneslayer Angel +SB: 2 [M12:52] Flashfreeze +SB: 3 [M14:215] Ratchet Bomb +SB: 4 [ROE:40] Oust +SB: 2 [MBS:5] Divine Offering +SB: 2 [SOM:6] Elspeth Tirel diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(2) 58 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(2) 58 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..dff94e849fb --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Mystic Caw Go(2) 58 PT Paris ST 2-13-11.dck @@ -0,0 +1,27 @@ +4 [WWK:133] Celestial Colonnade +3 [UNH:137] Island +4 [ROE:40] Oust +4 [UNH:136] Plains +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +2 [CMD:17] Journey to Nowhere +1 [ZEN:211] Arid Mesa +4 [ROE:47] Student of Warfare +1 [MBS:138] Sword of Feast and Famine +2 [SOM:208] Sword of Body and Mind +3 [MBS:14] Mirran Crusader +4 [SOM:229] Seachrome Coast +4 [C14:313] Tectonic Edge +4 [M13:225] Glacial Fortress +4 [M11:70] Preordain +1 [ZEN:223] Scalding Tarn +3 [ZEN:67] Spell Pierce +4 [WWK:20] Stoneforge Mystic +SB: 1 [WWK:17] Refraction Trap +SB: 2 [M11:7] Baneslayer Angel +SB: 1 [M12:52] Flashfreeze +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [C14:76] Kor Sanctifiers +SB: 4 [M11:33] Squadron Hawk +SB: 2 [C14:124] Sea Gate Oracle +SB: 1 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya 34 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya 34 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..97d8461373d --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya 34 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,28 @@ +3 [CMD:190] Colossal Might +2 [CON:141] Ancient Ziggurat +2 [ALA:21] Ranger of Eos +2 [ZEN:220] Misty Rainforest +4 [M11:149] Lightning Bolt +1 [UNH:136] Plains +3 [ZEN:211] Arid Mesa +4 [ALA:209] Woolly Thoctar +4 [M10:186] Great Sable Stag +2 [UNH:139] Mountain +4 [ARB:50] Bloodbraid Elf +2 [MM2:151] Noble Hierarch +2 [FNMP:118] Ancient Ziggurat +4 [ZEN:168] Lotus Cobra +1 [ALA:154] Ajani Vengeant +4 [ZEN:126] Goblin Guide +2 [M13:228] Rootbound Crag +4 [CMD:25] Path to Exile +4 [UNH:140] Forest +2 [JR:66] Noble Hierarch +4 [C13:299] Jungle Shrine +SB: 2 [M13:22] Oblivion Ring +SB: 1 [ALA:154] Ajani Vengeant +SB: 3 [M11:7] Baneslayer Angel +SB: 2 [C13:26] Wall of Reverence +SB: 2 [ARB:124] Uril, the Miststalker +SB: 2 [ZEN:127] Goblin Ruinblaster +SB: 3 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Aggro 58 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Aggro 58 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..fa6bc20a032 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Aggro 58 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,25 @@ +4 [RTR:214] Dryad Militant +2 [M15:240] Battlefield Forge +4 [GTC:167] Ghor-Clan Rampager +4 [JOU:163] Mana Confluence +4 [RTR:248] Temple Garden +1 [C13:179] Boros Charm +4 [THS:32] Soldier of the Pantheon +4 [BNG:165] Temple of Plenty +4 [C13:211] Selesnya Charm +4 [GTC:247] Stomping Ground +4 [GTC:245] Sacred Foundry +2 [RTR:17] Precinct Captain +3 [M14:1] Ajani, Caller of the Pride +4 [THS:193] Fleecemane Lion +4 [C14:66] Brave the Elements +4 [DGM:114] Voice of Resurgence +4 [GTC:215] Boros Reckoner +SB: 1 [M15:169] Back to Nature +SB: 1 [M15:1] Ajani Steadfast +SB: 3 [JOU:140] Setessan Tactics +SB: 1 [THS:209] Xenagos, the Reveler +SB: 3 [C13:179] Boros Charm +SB: 2 [JOU:5] Banishing Light +SB: 2 [DGM:51] Advent of the Wurm +SB: 2 [RTR:101] Mizzium Mortars diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Lightsaber 1 World Championship 2009 (Rome) ST 11-19-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Lightsaber 1 World Championship 2009 (Rome) ST 11-19-09.dck new file mode 100644 index 00000000000..baa537df4e3 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Lightsaber 1 World Championship 2009 (Rome) ST 11-19-09.dck @@ -0,0 +1,23 @@ +4 [M11:7] Baneslayer Angel +4 [ALA:21] Ranger of Eos +4 [M11:149] Lightning Bolt +4 [UNH:136] Plains +1 [C14:305] Oran-Rief, the Vastwood +4 [ZEN:211] Arid Mesa +4 [ALA:209] Woolly Thoctar +2 [CON:87] Noble Hierarch +3 [UNH:139] Mountain +4 [ARB:50] Bloodbraid Elf +2 [MM2:151] Noble Hierarch +3 [ALA:154] Ajani Vengeant +4 [ALA:152] Wild Nacatl +4 [M13:228] Rootbound Crag +1 [ZEN:182] Scute Mob +4 [CMD:25] Path to Exile +4 [M13:229] Sunpetal Grove +4 [UNH:140] Forest +SB: 1 [ALA:154] Ajani Vengeant +SB: 2 [ZEN:119] Burst Lightning +SB: 4 [ZEN:127] Goblin Ruinblaster +SB: 4 [M10:186] Great Sable Stag +SB: 4 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Pod 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Pod 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..c27a8f1c370 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Naya Pod 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,36 @@ +1 [UNH:136] Plains +1 [MBS:95] Viridian Emissary +3 [ISD:239] Gavony Township +1 [UNH:139] Mountain +2 [M13:22] Oblivion Ring +1 [C14:271] Solemn Simulacrum +6 [UNH:140] Forest +2 [MBS:115] Mortarpod +4 [NPH:104] Birthing Pod +4 [M12:165] Birds of Paradise +1 [C14:72] Geist-Honored Monk +1 [NPH:9] Elesh Norn, Grand Cenobite +1 [C13:114] Inferno Titan +4 [NPH:4] Blade Splicer +1 [C14:283] Wurmcoil Engine +3 [ISD:170] Avacyn's Pilgrim +1 [C14:204] Llanowar Elves +2 [M13:228] Rootbound Crag +4 [SOM:225] Copperline Gorge +4 [SOM:228] Razorverge Thicket +1 [C13:11] Fiend Hunter +3 [M13:229] Sunpetal Grove +4 [DKA:140] Huntmaster of the Fells +4 [DKA:127] Strangleroot Geist +1 [C13:134] Acidic Slime +SB: 1 [M12:164] Autumn's Veil +SB: 1 [M13:22] Oblivion Ring +SB: 1 [DKA:17] Ray of Revelation +SB: 3 [NPH:38] Mental Misstep +SB: 2 [MBS:8] Hero of Bladehold +SB: 1 [MBS:92] Thrun, the Last Troll +SB: 1 [NPH:42] Phyrexian Metamorph +SB: 1 [ISD:127] Ancient Grudge +SB: 2 [MBS:138] Sword of Feast and Famine +SB: 1 [NPH:97] Tormentor Exarch +SB: 1 [C13:134] Acidic Slime diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Open Filigree 58 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Open Filigree 58 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..2e76cf0a412 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Open Filigree 58 PT San Diego ST 2-21-10.dck @@ -0,0 +1,30 @@ +2 [WWK:133] Celestial Colonnade +4 [ZEN:70] Spreading Seas +1 [UNH:138] Swamp +4 [ARB:7] Glassdust Hulk +4 [UNH:137] Island +2 [ARB:5] Fieldmist Borderpost +2 [WWK:31] Jace, the Mind Sculptor +3 [UNH:136] Plains +4 [C13:189] Filigree Angel +2 [CMD:17] Journey to Nowhere +2 [C14:315] Terramorphic Expanse +3 [ALA:37] Courier's Capsule +1 [C13:212] Sharuum the Hegemon +3 [M13:22] Oblivion Ring +2 [ZEN:219] Marsh Flats +2 [ZEN:216] Kabira Crossroads +4 [M10:21] Open the Vaults +4 [M13:225] Glacial Fortress +4 [ARB:17] Architects of Will +4 [ZEN:69] Sphinx of Lost Truths +1 [ARB:27] Mistvein Borderpost +3 [M12:12] Day of Judgment +SB: 2 [ALA:173] Hindering Light +SB: 1 [M13:22] Oblivion Ring +SB: 4 [M15:71] Negate +SB: 3 [M12:52] Flashfreeze +SB: 1 [WWK:31] Jace, the Mind Sculptor +SB: 2 [CMD:17] Journey to Nowhere +SB: 1 [C13:92] Sanguine Bond +SB: 1 [M12:12] Day of Judgment diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 34 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 34 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..9493de41db2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 34 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,28 @@ +3 [RTR:63] Desecration Demon +1 [RTR:82] Ultimate Price +4 [M15:241] Caves of Koilos +4 [RTR:73] Pack Rat +3 [BNG:61] Bile Blight +3 [RTR:83] Underworld Connections +8 [UNH:138] Swamp +1 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [JOU:5] Banishing Light +2 [GTC:63] Devour Flesh +3 [DGM:57] Blood Baron of Vizkopa +1 [GTC:182] Obzedat, Ghost Council +4 [THS:107] Thoughtseize +3 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [THS:9] Elspeth, Sun's Champion +3 [M14:101] Lifebane Zombie +4 [M14:228] Mutavault +4 [THS:227] Temple of Silence +SB: 3 [M14:96] Doom Blade +SB: 1 [THS:85] Erebos, God of the Dead +SB: 1 [RTR:83] Underworld Connections +SB: 3 [M14:97] Duress +SB: 1 [DGM:103] Sin Collector +SB: 2 [THS:22] Last Breath +SB: 2 [JOU:7] Deicide +SB: 2 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 58 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 58 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..9493de41db2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Control 58 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,28 @@ +3 [RTR:63] Desecration Demon +1 [RTR:82] Ultimate Price +4 [M15:241] Caves of Koilos +4 [RTR:73] Pack Rat +3 [BNG:61] Bile Blight +3 [RTR:83] Underworld Connections +8 [UNH:138] Swamp +1 [UNH:136] Plains +4 [GTC:242] Godless Shrine +2 [JOU:5] Banishing Light +2 [GTC:63] Devour Flesh +3 [DGM:57] Blood Baron of Vizkopa +1 [GTC:182] Obzedat, Ghost Council +4 [THS:107] Thoughtseize +3 [THS:90] Hero's Downfall +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [THS:9] Elspeth, Sun's Champion +3 [M14:101] Lifebane Zombie +4 [M14:228] Mutavault +4 [THS:227] Temple of Silence +SB: 3 [M14:96] Doom Blade +SB: 1 [THS:85] Erebos, God of the Dead +SB: 1 [RTR:83] Underworld Connections +SB: 3 [M14:97] Duress +SB: 1 [DGM:103] Sin Collector +SB: 2 [THS:22] Last Breath +SB: 2 [JOU:7] Deicide +SB: 2 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Midrange 58 PT Theros (Dublin) ST 10-13-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Midrange 58 PT Theros (Dublin) ST 10-13-13.dck new file mode 100644 index 00000000000..acbda970f61 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Orzhov Midrange 58 PT Theros (Dublin) ST 10-13-13.dck @@ -0,0 +1,29 @@ +4 [RTR:63] Desecration Demon +6 [UNH:138] Swamp +7 [UNH:136] Plains +4 [THS:32] Soldier of the Pantheon +4 [GTC:242] Godless Shrine +4 [RTR:17] Precinct Captain +3 [M14:96] Doom Blade +1 [DGM:57] Blood Baron of Vizkopa +3 [GTC:182] Obzedat, Ghost Council +2 [DGM:103] Sin Collector +3 [C14:158] Read the Bones +4 [THS:107] Thoughtseize +1 [THS:110] Whip of Erebos +4 [THS:90] Hero's Downfall +1 [THS:9] Elspeth, Sun's Champion +4 [C13:312] Orzhov Guildgate +1 [M14:228] Mutavault +4 [THS:227] Temple of Silence +SB: 1 [DGM:57] Blood Baron of Vizkopa +SB: 1 [M14:96] Doom Blade +SB: 1 [RTR:231] Pithing Needle +SB: 1 [RTR:83] Underworld Connections +SB: 2 [DGM:103] Sin Collector +SB: 1 [THS:22] Last Breath +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 2 [M14:101] Lifebane Zombie +SB: 1 [GTC:63] Devour Flesh +SB: 3 [M14:18] Fiendslayer Paladin +SB: 1 [THS:100] Pharika's Cure diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Owling Mine 34 PT Honolulu ST 3-5-06.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Owling Mine 34 PT Honolulu ST 3-5-06.dck new file mode 100644 index 00000000000..8e3c8f2cdd4 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Owling Mine 34 PT Honolulu ST 3-5-06.dck @@ -0,0 +1,25 @@ +4 [CMD:251] Howling Mine +4 [CHK:59] Eye of Nowhere +10 [UNH:137] Island +2 [10E:83] Evacuation +4 [RTR:247] Steam Vents +2 [PTK:42] Exhaustion +2 [UNH:139] Mountain +1 [POR:42] Balance of Power +2 [SOK:162] Mikokoro, Center of the Sea +4 [SOK:154] Ebony Owl Netsuke +4 [RAV:63] Remand +4 [10E:70] Boomerang +4 [SOK:42] Kami of the Crescent Moon +3 [ME4:62] Sleight of Hand +4 [10E:241] Sudden Impact +1 [USG:74] Exhaustion +4 [M15:246] Shivan Reef +1 [PO2:46] Sleight of Hand +SB: 4 [BOK:56] Threads of Disloyalty +SB: 1 [DRK:57] Blood Moon +SB: 1 [9ED:176] Blood Moon +SB: 3 [M12:63] Mana Leak +SB: 2 [CHK:74] Meloku the Clouded Mirror +SB: 1 [8ED:178] Blood Moon +SB: 3 [M11:154] Pyroclasm diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Quick n Toast 2 World Championship 2008 (Memphis) ST 12-14-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Quick n Toast 2 World Championship 2008 (Memphis) ST 12-14-08.dck new file mode 100644 index 00000000000..5487fdd89bf --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Quick n Toast 2 World Championship 2008 (Memphis) ST 12-14-08.dck @@ -0,0 +1,32 @@ +2 [M15:71] Negate +2 [LRW:202] Cloudthresher +2 [C13:195] Jund Charm +4 [C13:334] Vivid Creek +1 [10E:116] Tidings +1 [M11:154] Pyroclasm +1 [C13:182] Cruel Ultimatum +1 [EVE:177] Flooded Grove +1 [SHM:280] Sunken Ruins +4 [LRW:56] Cryptic Command +4 [CNS:210] Reflecting Pool +4 [C14:118] Mulldrifter +1 [SHM:172] Oona, Queen of the Fae +3 [ALA:167] Esper Charm +2 [SHM:271] Fire-Lit Thicket +4 [10E:100] Remove Soul +3 [C13:27] Wrath of God +2 [C14:69] Condemn +1 [M15:249] Yavimaya Coast +4 [C13:335] Vivid Grove +4 [SHM:277] Mystic Gate +4 [CMD:297] Vivid Meadow +4 [ALA:188] Rhox War Monk +1 [10E:362] Underground River +SB: 1 [RTR:231] Pithing Needle +SB: 1 [CMD:8] Austere Command +SB: 1 [C13:27] Wrath of God +SB: 1 [EVE:22] Glen Elendra Archmage +SB: 2 [C14:69] Condemn +SB: 2 [M11:154] Pyroclasm +SB: 4 [MOR:58] Bitterblossom +SB: 3 [SHM:208] Guttural Response diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/RB Sauce 34 World Championship 2008 (Memphis) ST 12-14-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/RB Sauce 34 World Championship 2008 (Memphis) ST 12-14-08.dck new file mode 100644 index 00000000000..fdeddbc2f39 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/RB Sauce 34 World Championship 2008 (Memphis) ST 12-14-08.dck @@ -0,0 +1,21 @@ +4 [M12:146] Incinerate +4 [10E:359] Sulfurous Springs +4 [M10:157] Siege-Gang Commander +6 [UNH:139] Mountain +4 [MOR:58] Bitterblossom +3 [CNS:210] Reflecting Pool +3 [SHM:192] Murderous Redcap +4 [SHM:203] Boggart Ram-Gang +4 [JOU:103] Magma Spray +4 [SHM:272] Graven Cairns +4 [ALA:156] Blightning +4 [LRW:267] Auntie's Hovel +4 [EVE:139] Figure of Destiny +4 [SHM:92] Flame Javelin +4 [10E:353] Ghitu Encampment +SB: 3 [SHM:180] Ashenmoor Gouger +SB: 1 [C14:247] Loxodon Warhammer +SB: 2 [C14:160] Shriekmaw +SB: 2 [C13:233] Spiteful Visions +SB: 4 [ALA:120] Vithian Stinger +SB: 3 [C13:81] Infest diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Red Deck Wins 34 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Red Deck Wins 34 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..cd2c99accf8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Red Deck Wins 34 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,19 @@ +2 [M12:146] Incinerate +3 [M12:145] Grim Lavamancer +4 [M14:134] Chandra's Phoenix +4 [M12:139] Goblin Fireslinger +4 [M12:156] Stormblood Berserker +4 [NPH:100] Volt Charge +3 [SOM:91] Galvanic Blast +21 [UNH:139] Mountain +2 [SOM:81] Arc Trail +4 [NPH:86] Gut Shot +1 [SOM:104] Spikeshot Elder +4 [ISD:164] Stromkirk Noble +4 [NPH:153] Shrine of Burning Rage +SB: 2 [ISD:166] Traitorous Blood +SB: 4 [NPH:101] Vulshok Refugee +SB: 4 [NPH:57] Dismember +SB: 1 [M12:151] Manic Vandal +SB: 2 [SOM:94] Koth of the Hammer +SB: 2 [SOM:81] Arc Trail diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(1) 58 World Championship 2007 (New York) ST 12-6-07.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(1) 58 World Championship 2007 (New York) ST 12-6-07.dck new file mode 100644 index 00000000000..d238b630ef7 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(1) 58 World Championship 2007 (New York) ST 12-6-07.dck @@ -0,0 +1,31 @@ +1 [C14:247] Loxodon Warhammer +2 [M12:165] Birds of Paradise +1 [LEG:250] Pendelhaven +2 [CSP:153] Snow-Covered Swamp +1 [ME2:243] Snow-Covered Swamp +3 [M15:103] Liliana Vess +1 [FUT:177] Horizon Canopy +3 [LRW:128] Nameless Inversion +4 [FUT:153] Tarmogoyf +2 [C14:206] Masked Admirers +1 [LRW:110] Eyeblight's Ending +4 [THS:107] Thoughtseize +4 [C14:204] Llanowar Elves +3 [C14:156] Profane Command +3 [C14:160] Shriekmaw +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [LRW:268] Gilt-Leaf Palace +4 [DDM:57] Ohran Viper +5 [UNH:140] Forest +3 [CMD:157] Garruk Wildspeaker +4 [M15:244] Llanowar Wastes +4 [10E:361] Treetop Village +SB: 1 [RTR:231] Pithing Needle +SB: 1 [LRW:128] Nameless Inversion +SB: 1 [PLC:85] Damnation +SB: 4 [LRW:210] Eyes of the Wisent +SB: 1 [C14:160] Shriekmaw +SB: 3 [10E:308] Viridian Shaman +SB: 1 [FUT:136] Riftsweeper +SB: 2 [10E:145] Graveborn Muse +SB: 1 [PLC:71] Extirpate diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(2) 58 World Championship 2007 (New York) ST 12-6-07.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(2) 58 World Championship 2007 (New York) ST 12-6-07.dck new file mode 100644 index 00000000000..f43c1aeb5d2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Rock(2) 58 World Championship 2007 (New York) ST 12-6-07.dck @@ -0,0 +1,32 @@ +2 [C14:247] Loxodon Warhammer +1 [LRW:250] Nath of the Gilt-Leaf +4 [M12:165] Birds of Paradise +3 [UNH:138] Swamp +1 [LEG:250] Pendelhaven +1 [FUT:91] Tombstalker +1 [LRW:128] Nameless Inversion +4 [FUT:153] Tarmogoyf +3 [LRW:110] Eyeblight's Ending +3 [CMD:176] Troll Ascetic +4 [THS:107] Thoughtseize +4 [C14:204] Llanowar Elves +2 [C14:160] Shriekmaw +1 [M15:248] Urborg, Tomb of Yawgmoth +1 [CSP:115] Ohran Viper +3 [LRW:268] Gilt-Leaf Palace +3 [DDM:57] Ohran Viper +7 [UNH:140] Forest +4 [CMD:157] Garruk Wildspeaker +4 [M15:244] Llanowar Wastes +4 [10E:361] Treetop Village +SB: 1 [PLC:85] Damnation +SB: 1 [UNH:138] Swamp +SB: 1 [LRW:202] Cloudthresher +SB: 1 [CMD:176] Troll Ascetic +SB: 1 [LRW:110] Eyeblight's Ending +SB: 2 [LRW:210] Eyes of the Wisent +SB: 1 [C14:156] Profane Command +SB: 2 [C14:160] Shriekmaw +SB: 1 [FUT:91] Tombstalker +SB: 2 [C13:153] Krosan Grip +SB: 2 [M15:103] Liliana Vess diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saint WW with Leaks 58 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saint WW with Leaks 58 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..6a67a5a6f2a --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saint WW with Leaks 58 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,27 @@ +1 [MBS:115] Mortarpod +4 [ISD:244] Moorland Haunt +4 [CNS:69] Doomed Traveler +1 [UNH:137] Island +3 [M12:18] Gideon's Lawkeeper +11 [UNH:136] Plains +3 [M12:63] Mana Leak +3 [ISD:213] Geist of Saint Traft +2 [MBS:10] Leonin Relic-Warder +2 [M13:22] Oblivion Ring +4 [MBS:14] Mirran Crusader +4 [MBS:8] Hero of Bladehold +2 [NPH:57] Dismember +4 [SOM:229] Seachrome Coast +4 [M13:225] Glacial Fortress +4 [C13:11] Fiend Hunter +4 [M12:23] Honor of the Pure +SB: 2 [BNG:25] Revoke Existence +SB: 1 [M13:22] Oblivion Ring +SB: 4 [M12:40] Timely Reinforcements +SB: 2 [NPH:57] Dismember +SB: 1 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [ISD:213] Geist of Saint Traft +SB: 1 [M12:3] Angelic Destiny +SB: 1 [M12:12] Day of Judgment +SB: 1 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saito Naya 34 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saito Naya 34 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..582b0fb20a2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Saito Naya 34 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,25 @@ +4 [M13:171] Flinthoof Boar +4 [GTC:156] Domri Rade +4 [RTR:248] Temple Garden +1 [M13:193] Thragtusk +4 [GTC:123] Gyre Sage +4 [RTR:178] Loxodon Smiter +3 [ISD:238] Clifftop Retreat +2 [UNH:139] Mountain +4 [GTC:247] Stomping Ground +4 [GTC:245] Sacred Foundry +4 [DKA:93] Hellrider +4 [GTC:216] Burning-Tree Emissary +4 [GTC:215] Boros Reckoner +4 [M13:228] Rootbound Crag +3 [M13:229] Sunpetal Grove +3 [M13:150] Thundermaw Hellkite +4 [RTR:101] Mizzium Mortars +SB: 2 [AVR:31] Nearheath Pilgrim +SB: 2 [ISD:181] Garruk Relentless +SB: 1 [GTC:143] Aurelia, the Warleader +SB: 1 [M13:193] Thragtusk +SB: 3 [C13:179] Boros Charm +SB: 2 [M14:25] Pacifism +SB: 2 [AVR:198] Triumph of Ferocity +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Selesnya Aggro 2 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Selesnya Aggro 2 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..c1584b1bc65 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Selesnya Aggro 2 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,20 @@ +4 [JOU:163] Mana Confluence +4 [RTR:248] Temple Garden +8 [UNH:136] Plains +2 [M15:202] Sunblade Elf +3 [THS:32] Soldier of the Pantheon +3 [JOU:5] Banishing Light +3 [RTR:178] Loxodon Smiter +3 [C13:211] Selesnya Charm +3 [THS:152] Boon Satyr +3 [M14:1] Ajani, Caller of the Pride +4 [THS:193] Fleecemane Lion +4 [GTC:119] Experiment One +4 [DGM:114] Voice of Resurgence +4 [DGM:51] Advent of the Wurm +8 [UNH:140] Forest +SB: 4 [JOU:140] Setessan Tactics +SB: 1 [M15:1] Ajani Steadfast +SB: 4 [DGM:49] Skylasher +SB: 4 [DGM:111] Unflinching Courage +SB: 2 [JOU:2] Ajani's Presence diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Snow Mana Ramp 58 PT Hollywood ST 5-25-08.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Snow Mana Ramp 58 PT Hollywood ST 5-25-08.dck new file mode 100644 index 00000000000..075f8f6ada0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Snow Mana Ramp 58 PT Hollywood ST 5-25-08.dck @@ -0,0 +1,27 @@ +2 [LRW:233] Primal Command +4 [C13:148] Harmonize +1 [ME2:244] Snow-Covered Mountain +3 [LRW:202] Cloudthresher +5 [ME2:245] Snow-Covered Forest +2 [FUT:144] Edge of Autumn +4 [SHM:229] Kitchen Finks +2 [FNMP:98] Wall of Roots +1 [MIR:151] Wall of Roots +3 [CSP:148] Mouth of Ronom +2 [CSP:147] Highland Weald +1 [SHM:252] Grim Poppet +1 [ARC:73] Wall of Roots +4 [FUT:176] Grove of the Burnwillows +3 [ICE:347] Snow-Covered Forest +2 [CSP:155] Snow-Covered Forest +4 [CMD:199] Firespout +4 [MOR:116] Chameleon Colossus +4 [CSP:97] Skred +4 [10E:361] Treetop Village +4 [CSP:111] Into the North +SB: 4 [FUT:101] Magus of the Moon +SB: 4 [FUT:153] Tarmogoyf +SB: 1 [LRW:202] Cloudthresher +SB: 2 [M11:154] Pyroclasm +SB: 1 [SHM:66] Faerie Macabre +SB: 3 [CMD:157] Garruk Wildspeaker diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel 34 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel 34 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..3b544c79177 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel 34 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,22 @@ +2 [ISD:244] Moorland Haunt +6 [SOM:156] Glint Hawk Idol +4 [MBS:131] Signal Pest +4 [SOM:189] Origin Spellbomb +9 [UNH:136] Plains +4 [MBS:145] Inkmoth Nexus +4 [SOM:179] Mox Opal +4 [NPH:76] Vault Skirge +1 [ISD:23] Mikaeus, the Lunarch +4 [NPH:7] Dispatch +4 [SOM:154] Etched Champion +4 [SOM:229] Seachrome Coast +2 [SOM:10] Glint Hawk +4 [SOM:24] Tempered Steel +4 [SOM:174] Memnite +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:40] Timely Reinforcements +SB: 3 [NPH:159] Spellskite +SB: 3 [MBS:8] Hero of Bladehold +SB: 2 [NPH:57] Dismember +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 1 [M13:225] Glacial Fortress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(1) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(1) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..2331fc987e2 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(1) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,22 @@ +2 [ISD:244] Moorland Haunt +4 [SOM:156] Glint Hawk Idol +4 [MBS:131] Signal Pest +4 [SOM:189] Origin Spellbomb +9 [UNH:136] Plains +4 [MBS:145] Inkmoth Nexus +4 [SOM:179] Mox Opal +4 [NPH:76] Vault Skirge +1 [ISD:23] Mikaeus, the Lunarch +4 [NPH:7] Dispatch +4 [SOM:154] Etched Champion +4 [SOM:229] Seachrome Coast +4 [SOM:10] Glint Hawk +4 [SOM:24] Tempered Steel +4 [SOM:174] Memnite +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:40] Timely Reinforcements +SB: 3 [NPH:159] Spellskite +SB: 3 [MBS:8] Hero of Bladehold +SB: 2 [NPH:57] Dismember +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 1 [M13:225] Glacial Fortress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(2) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(2) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..5273130f8ef --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(2) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,22 @@ +2 [ISD:244] Moorland Haunt +5 [SOM:156] Glint Hawk Idol +4 [MBS:131] Signal Pest +4 [SOM:189] Origin Spellbomb +9 [UNH:136] Plains +4 [MBS:145] Inkmoth Nexus +4 [SOM:179] Mox Opal +4 [NPH:76] Vault Skirge +1 [ISD:23] Mikaeus, the Lunarch +4 [NPH:7] Dispatch +4 [SOM:154] Etched Champion +4 [SOM:229] Seachrome Coast +3 [SOM:10] Glint Hawk +4 [SOM:24] Tempered Steel +4 [SOM:174] Memnite +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:40] Timely Reinforcements +SB: 3 [NPH:159] Spellskite +SB: 3 [MBS:8] Hero of Bladehold +SB: 2 [NPH:57] Dismember +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 1 [M13:225] Glacial Fortress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(3) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(3) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck new file mode 100644 index 00000000000..3b544c79177 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tempered Steel(3) 58 World Championship 2011 (San Francisco) ST 11-20-11.dck @@ -0,0 +1,22 @@ +2 [ISD:244] Moorland Haunt +6 [SOM:156] Glint Hawk Idol +4 [MBS:131] Signal Pest +4 [SOM:189] Origin Spellbomb +9 [UNH:136] Plains +4 [MBS:145] Inkmoth Nexus +4 [SOM:179] Mox Opal +4 [NPH:76] Vault Skirge +1 [ISD:23] Mikaeus, the Lunarch +4 [NPH:7] Dispatch +4 [SOM:154] Etched Champion +4 [SOM:229] Seachrome Coast +2 [SOM:10] Glint Hawk +4 [SOM:24] Tempered Steel +4 [SOM:174] Memnite +SB: 1 [M13:22] Oblivion Ring +SB: 1 [M12:40] Timely Reinforcements +SB: 3 [NPH:159] Spellskite +SB: 3 [MBS:8] Hero of Bladehold +SB: 2 [NPH:57] Dismember +SB: 4 [NPH:155] Shrine of Loyal Legions +SB: 1 [M13:225] Glacial Fortress diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tezzeret Control 58 PT Paris ST 2-13-11.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tezzeret Control 58 PT Paris ST 2-13-11.dck new file mode 100644 index 00000000000..b935fbdfd67 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Tezzeret Control 58 PT Paris ST 2-13-11.dck @@ -0,0 +1,31 @@ +4 [WWK:134] Creeping Tar Pit +3 [MBS:134] Sphere of the Suns +4 [MBS:97] Tezzeret, Agent of Bolas +2 [MBS:75] Slagstorm +3 [UNH:137] Island +3 [WWK:31] Jace, the Mind Sculptor +2 [SOM:179] Mox Opal +2 [MBS:145] Inkmoth Nexus +2 [SOM:91] Galvanic Blast +2 [M11:154] Pyroclasm +2 [UNH:139] Mountain +4 [GTC:234] Prophetic Prism +1 [MBS:34] Treasure Mage +2 [SOM:46] Stoic Rebuttal +1 [C14:283] Wurmcoil Engine +3 [C14:313] Tectonic Edge +3 [SOM:218] Tumble Magnet +3 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +4 [ZEN:223] Scalding Tarn +4 [C14:239] Everflowing Chalice +1 [SOM:176] Mindslaver +1 [SOM:224] Blackcleave Cliffs +SB: 4 [ZEN:70] Spreading Seas +SB: 2 [SOM:46] Stoic Rebuttal +SB: 3 [M14:97] Duress +SB: 1 [M12:52] Flashfreeze +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [WWK:31] Jace, the Mind Sculptor +SB: 2 [M11:154] Pyroclasm +SB: 1 [SOM:96] Kuldotha Rebirth diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/The Aristocrats 1 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/The Aristocrats 1 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..e6f0d83a1d0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/The Aristocrats 1 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,28 @@ +4 [CNS:69] Doomed Traveler +1 [AVR:32] Restoration Angel +3 [UNH:136] Plains +4 [RTR:238] Blood Crypt +3 [M13:96] Knight of Infamy +4 [GTC:242] Godless Shrine +4 [GTC:150] Cartel Aristocrat +2 [C14:88] Silverblade Paladin +1 [ISD:238] Clifftop Retreat +2 [DKA:12] Lingering Souls +4 [ISD:242] Isolated Chapel +4 [GTC:245] Sacred Foundry +4 [ISD:6] Champion of the Parish +2 [C14:163] Skirsdag High Priest +2 [AVR:166] Zealous Conscripts +4 [GTC:215] Boros Reckoner +1 [DKA:158] Vault of the Archangel +4 [DKA:138] Falkenrath Aristocrat +4 [GTC:185] Orzhov Charm +3 [AVR:226] Cavern of Souls +SB: 3 [C14:167] Tragic Slip +SB: 2 [GTC:182] Obzedat, Ghost Council +SB: 1 [C14:79] Mentor of the Meek +SB: 1 [C14:163] Skirsdag High Priest +SB: 2 [C14:172] Blasphemous Act +SB: 2 [DKA:142] Sorin, Lord of Innistrad +SB: 2 [DKA:12] Lingering Souls +SB: 2 [RTR:18] Rest in Peace diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Trinity 34 World Championship 2000 (Brussels) ST 8-6-00.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Trinity 34 World Championship 2000 (Brussels) ST 8-6-00.dck new file mode 100644 index 00000000000..82458d9d4d6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/Trinity 34 World Championship 2000 (Brussels) ST 8-6-00.dck @@ -0,0 +1,27 @@ +3 [USG:321] Gaea's Cradle +2 [8ED:272] Plow Under +1 [UDS:118] Rofellos, Llanowar Emissary +4 [M12:165] Birds of Paradise +4 [NMS:119] Skyshroud Poacher +2 [UDS:117] Plow Under +4 [NMS:139] Tangle Wire +1 [UDS:134] Masticore +2 [JR:18] Deranged Hermit +4 [C14:210] Priest of Titania +1 [USG:306] Phyrexian Processor +4 [C14:204] Llanowar Elves +2 [VMA:229] Rofellos, Llanowar Emissary +4 [MMQ:324] Rishadan Port +3 [VMA:275] Masticore +1 [USG:248] Elvish Lyrist +14 [UNH:140] Forest +2 [10E:361] Treetop Village +2 [ULG:101] Deranged Hermit +SB: 1 [USG:306] Phyrexian Processor +SB: 4 [UDS:140] Thran Foundry +SB: 2 [BOK:146] Splinter +SB: 1 [DDE:29] Phyrexian Processor +SB: 1 [UNH:140] Forest +SB: 2 [VIS:73] Uktabi Orangutan +SB: 1 [MIR:153] Worldly Tutor +SB: 2 [NMS:111] Reverent Silence diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 1 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 1 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..c7f768bb7ae --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 1 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,29 @@ +3 [ROE:115] Inquisition of Kozilek +4 [WWK:134] Creeping Tar Pit +4 [ZEN:70] Spreading Seas +3 [UNH:138] Swamp +1 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +2 [ROE:100] Consume the Meek +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +2 [M11:58] Jace Beleren +2 [C14:124] Sea Gate Oracle +2 [M14:96] Doom Blade +1 [M14:97] Duress +4 [M13:223] Drowned Catacomb +3 [C14:145] Grave Titan +4 [C14:313] Tectonic Edge +4 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +2 [ZEN:87] Disfigure +1 [KTK:33] Cancel +1 [ZEN:229] Verdant Catacombs +SB: 1 [M12:109] Sorin Markov +SB: 1 [M14:96] Doom Blade +SB: 3 [SOM:69] Memoricide +SB: 2 [M14:97] Duress +SB: 2 [M12:52] Flashfreeze +SB: 3 [M14:215] Ratchet Bomb +SB: 1 [ROE:59] Deprive +SB: 2 [ZEN:87] Disfigure diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 2 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 2 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..df5a4447626 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 2 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,31 @@ +2 [ROE:115] Inquisition of Kozilek +4 [WWK:134] Creeping Tar Pit +4 [ZEN:70] Spreading Seas +3 [UNH:138] Swamp +1 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +2 [ROE:100] Consume the Meek +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +2 [M11:58] Jace Beleren +2 [C14:124] Sea Gate Oracle +2 [M14:96] Doom Blade +1 [SOM:46] Stoic Rebuttal +2 [M14:97] Duress +4 [M13:223] Drowned Catacomb +3 [C14:145] Grave Titan +2 [M14:215] Ratchet Bomb +4 [C14:313] Tectonic Edge +4 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +1 [ZEN:229] Verdant Catacombs +SB: 1 [M12:109] Sorin Markov +SB: 1 [ROE:115] Inquisition of Kozilek +SB: 1 [M14:96] Doom Blade +SB: 3 [SOM:69] Memoricide +SB: 1 [SOM:46] Stoic Rebuttal +SB: 1 [M14:97] Duress +SB: 2 [M12:52] Flashfreeze +SB: 1 [M14:215] Ratchet Bomb +SB: 3 [ZEN:87] Disfigure +SB: 1 [M11:58] Jace Beleren diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 34 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 34 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..d2e75124e40 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 34 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,32 @@ +4 [ROE:115] Inquisition of Kozilek +4 [WWK:134] Creeping Tar Pit +4 [ZEN:70] Spreading Seas +3 [UNH:138] Swamp +1 [ZEN:220] Misty Rainforest +4 [UNH:137] Island +1 [ROE:100] Consume the Meek +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +1 [M11:58] Jace Beleren +3 [C14:124] Sea Gate Oracle +3 [M14:96] Doom Blade +4 [M13:223] Drowned Catacomb +3 [C14:145] Grave Titan +4 [C14:313] Tectonic Edge +4 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +2 [ZEN:87] Disfigure +1 [M11:226] Mystifying Maze +1 [KTK:33] Cancel +1 [ZEN:229] Verdant Catacombs +SB: 1 [SOM:46] Stoic Rebuttal +SB: 1 [M14:97] Duress +SB: 1 [ZEN:57] Mindbreak Trap +SB: 1 [M12:52] Flashfreeze +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [SOM:78] Skinrender +SB: 1 [ROE:59] Deprive +SB: 2 [ZEN:87] Disfigure +SB: 1 [M11:58] Jace Beleren +SB: 1 [ZEN:67] Spell Pierce +SB: 3 [C13:97] Vampire Nighthawk diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck new file mode 100644 index 00000000000..55b9f03df19 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 PT Khans of Tarkir (Honolulu) ST 10-12-14.dck @@ -0,0 +1,30 @@ +4 [KTK:239] Polluted Delta +3 [BNG:61] Bile Blight +4 [UNH:138] Swamp +4 [THS:47] Dissolve +4 [UNH:137] Island +2 [KTK:233] Flooded Strand +4 [KTK:69] Despise +1 [JOU:165] Temple of Malady +2 [BNG:65] Drown in Sorrow +1 [THS:226] Temple of Mystery +4 [THS:225] Temple of Deceit +2 [THS:107] Thoughtseize +4 [KTK:232] Dismal Backwater +4 [THS:90] Hero's Downfall +4 [KTK:37] Disdainful Stroke +4 [THS:60] Prognostic Sphinx +4 [KTK:36] Dig Through Time +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [KTK:230] Bloodstained Mire +2 [JOU:82] Silence the Believers +SB: 2 [M15:71] Negate +SB: 1 [KTK:49] Pearl Lake Ancient +SB: 1 [BNG:61] Bile Blight +SB: 1 [KTK:54] Set Adrift +SB: 1 [THS:107] Thoughtseize +SB: 2 [THS:104] Returned Phalanx +SB: 1 [JOU:82] Silence the Believers +SB: 3 [KTK:34] Clever Impersonator +SB: 1 [THS:100] Pharika's Cure +SB: 2 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 World Championship 2005 (Yokohama) ST 12-4-05.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 World Championship 2005 (Yokohama) ST 12-4-05.dck new file mode 100644 index 00000000000..9b35dba9a2c --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control 58 World Championship 2005 (Yokohama) ST 12-4-05.dck @@ -0,0 +1,29 @@ +2 [RTR:231] Pithing Needle +4 [UNH:138] Swamp +1 [CHK:279] Minamo, School at Water's Edge +9 [UNH:137] Island +3 [M12:63] Mana Leak +3 [CHK:74] Meloku the Clouded Mirror +1 [CHK:72] Keiga, the Tide Star +2 [CHK:115] Hideous Laughter +4 [CHK:65] Hinder +3 [M13:65] Rewind +1 [SOK:163] Miren, the Moaning Well +1 [CHK:283] Shizo, Death's Storehouse +3 [RAV:93] Last Gasp +1 [SOK:164] Oboro, Palace in the Clouds +3 [10E:70] Boomerang +4 [CHK:70] Jushi Apprentice +1 [BOK:71] Ink-Eyes, Servant of Oni +3 [BOK:33] Disrupting Shoal +3 [C13:31] Azami, Lady of Scrolls +4 [GTC:249] Watery Grave +4 [10E:362] Underground River +SB: 1 [RTR:231] Pithing Needle +SB: 2 [RAV:82] Darkblast +SB: 2 [CHK:273] Boseiju, Who Shelters All +SB: 4 [BOK:56] Threads of Disloyalty +SB: 2 [7ED:154] Persecute +SB: 1 [8ED:151] Persecute +SB: 2 [SOK:51] Overwhelming Intellect +SB: 1 [CHK:115] Hideous Laughter diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragon 2 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragon 2 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..39275a907ca --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragon 2 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,32 @@ +3 [FRF:65] Crux of Fate +4 [KTK:239] Polluted Delta +3 [DTK:58] Icefall Regent +3 [M15:63] Jace's Ingenuity +2 [BNG:61] Bile Blight +2 [KTK:238] Opulent Palace +3 [UNH:138] Swamp +2 [THS:47] Dissolve +6 [UNH:137] Island +4 [DTK:78] Silumgar's Scorn +2 [DTK:220] Dragonlord Silumgar +1 [DTK:249] Haven of the Spirit Dragon +4 [THS:225] Temple of Deceit +2 [DTK:124] Ultimate Price +2 [THS:107] Thoughtseize +1 [FRF:157] Silumgar, the Drifting Death +3 [THS:90] Hero's Downfall +3 [KTK:36] Dig Through Time +1 [KTK:81] Murderous Cut +2 [M15:248] Urborg, Tomb of Yawgmoth +4 [FRF:168] Dismal Backwater +1 [FRF:1] Ugin, the Spirit Dragon +2 [DTK:102] Foul-Tongue Invocation +SB: 1 [DTK:125] Virulent Plague +SB: 1 [DTK:124] Ultimate Price +SB: 1 [BNG:61] Bile Blight +SB: 1 [DTK:65] Negate +SB: 1 [DTK:52] Dragonlord's Prerogative +SB: 2 [KTK:37] Disdainful Stroke +SB: 3 [DTK:98] Duress +SB: 2 [DTK:80] Stratus Dancer +SB: 3 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragonless 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragonless 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..265c316d9c6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control Dragonless 34 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,37 @@ +1 [M15:51] Dissipate +4 [UNH:138] Swamp +3 [UNH:137] Island +4 [THS:47] Dissolve +1 [JOU:165] Temple of Malady +1 [M15:103] Liliana Vess +4 [THS:225] Temple of Deceit +4 [THS:90] Hero's Downfall +3 [KTK:36] Dig Through Time +4 [KTK:239] Polluted Delta +1 [FRF:65] Crux of Fate +2 [M15:63] Jace's Ingenuity +2 [KTK:238] Opulent Palace +4 [BNG:61] Bile Blight +1 [DTK:52] Dragonlord's Prerogative +2 [THS:188] Ashiok, Nightmare Weaver +1 [BNG:163] Temple of Enlightenment +1 [BNG:65] Drown in Sorrow +1 [M15:44] AEtherspouts +1 [DTK:124] Ultimate Price +3 [M15:224] Perilous Vault +4 [FRF:168] Dismal Backwater +1 [M15:248] Urborg, Tomb of Yawgmoth +2 [FRF:1] Ugin, the Spirit Dragon +2 [JOU:82] Silence the Believers +3 [M15:245] Radiant Fountain +SB: 1 [JOU:43] Interpret the Signs +SB: 1 [M15:44] AEtherspouts +SB: 1 [KTK:49] Pearl Lake Ancient +SB: 1 [FRF:87] Tasigur, the Golden Fang +SB: 1 [KTK:218] Cranial Archive +SB: 2 [THS:107] Thoughtseize +SB: 2 [DTK:65] Negate +SB: 2 [KTK:37] Disdainful Stroke +SB: 1 [THS:188] Ashiok, Nightmare Weaver +SB: 1 [THS:100] Pharika's Cure +SB: 2 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(1) 58 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(1) 58 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..0ec4fb72e92 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(1) 58 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,27 @@ +4 [WWK:134] Creeping Tar Pit +3 [UNH:138] Swamp +2 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +3 [M11:58] Jace Beleren +3 [C14:124] Sea Gate Oracle +3 [M14:96] Doom Blade +2 [SOM:46] Stoic Rebuttal +2 [M14:97] Duress +4 [M13:223] Drowned Catacomb +3 [C14:145] Grave Titan +4 [C14:313] Tectonic Edge +3 [M14:215] Ratchet Bomb +4 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +3 [ZEN:87] Disfigure +SB: 1 [M14:96] Doom Blade +SB: 3 [M15:71] Negate +SB: 1 [M14:97] Duress +SB: 1 [WWK:68] Smother +SB: 2 [ZEN:57] Mindbreak Trap +SB: 3 [M12:52] Flashfreeze +SB: 2 [ROE:100] Consume the Meek +SB: 1 [M14:215] Ratchet Bomb +SB: 1 [ZEN:87] Disfigure diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(2) 58 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(2) 58 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..20780135be8 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UB Control(2) 58 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,27 @@ +4 [ROE:115] Inquisition of Kozilek +4 [WWK:134] Creeping Tar Pit +4 [ZEN:70] Spreading Seas +3 [UNH:138] Swamp +1 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +2 [M11:58] Jace Beleren +3 [C14:124] Sea Gate Oracle +3 [M14:96] Doom Blade +4 [M13:223] Drowned Catacomb +3 [C14:145] Grave Titan +1 [M14:215] Ratchet Bomb +4 [C14:313] Tectonic Edge +4 [SOM:226] Darkslick Shores +4 [M11:70] Preordain +2 [ZEN:87] Disfigure +1 [ZEN:229] Verdant Catacombs +SB: 2 [M15:71] Negate +SB: 2 [SOM:69] Memoricide +SB: 1 [SOM:46] Stoic Rebuttal +SB: 1 [M14:97] Duress +SB: 3 [M12:52] Flashfreeze +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [ZEN:87] Disfigure +SB: 3 [C13:97] Vampire Nighthawk diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UBw Control Dragon 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UBw Control Dragon 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck new file mode 100644 index 00000000000..1d5577cdce0 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UBw Control Dragon 58 PT Dragons of Tarkir (Brussels) ST 4-12-15.dck @@ -0,0 +1,35 @@ +2 [FRF:65] Crux of Fate +4 [KTK:239] Polluted Delta +2 [DTK:58] Icefall Regent +3 [UNH:138] Swamp +3 [UNH:137] Island +4 [DTK:78] Silumgar's Scorn +1 [DTK:52] Dragonlord's Prerogative +2 [DTK:219] Dragonlord Ojutai +2 [DTK:220] Dragonlord Silumgar +4 [DTK:45] Anticipate +3 [BNG:163] Temple of Enlightenment +2 [DTK:249] Haven of the Spirit Dragon +4 [THS:225] Temple of Deceit +2 [DTK:124] Ultimate Price +3 [THS:107] Thoughtseize +2 [FRF:157] Silumgar, the Drifting Death +3 [THS:90] Hero's Downfall +2 [KTK:36] Dig Through Time +1 [M15:248] Urborg, Tomb of Yawgmoth +4 [FRF:168] Dismal Backwater +1 [C14:161] Sign in Blood +1 [FRF:1] Ugin, the Spirit Dragon +3 [DTK:102] Foul-Tongue Invocation +2 [THS:227] Temple of Silence +SB: 1 [DTK:125] Virulent Plague +SB: 1 [BNG:61] Bile Blight +SB: 2 [DTK:65] Negate +SB: 1 [THS:107] Thoughtseize +SB: 1 [M15:224] Perilous Vault +SB: 1 [THS:90] Hero's Downfall +SB: 1 [DTK:80] Stratus Dancer +SB: 1 [THS:188] Ashiok, Nightmare Weaver +SB: 2 [M15:65] Jorubai Murk Lurker +SB: 1 [DTK:102] Foul-Tongue Invocation +SB: 3 [BNG:65] Drown in Sorrow diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 1 PT Magic 2015 (Portland) ST 8-3-14.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 1 PT Magic 2015 (Portland) ST 8-3-14.dck new file mode 100644 index 00000000000..41dca3a2037 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 1 PT Magic 2015 (Portland) ST 8-3-14.dck @@ -0,0 +1,27 @@ +3 [M15:52] Divination +4 [RTR:145] Azorius Charm +3 [RTR:44] Jace, Architect of Thought +1 [JOU:164] Temple of Epiphany +2 [THS:22] Last Breath +4 [THS:47] Dissolve +6 [UNH:137] Island +2 [C13:275] Azorius Guildgate +6 [UNH:136] Plains +4 [RTR:200] Sphinx's Revelation +4 [RTR:201] Supreme Verdict +4 [BNG:163] Temple of Enlightenment +4 [M14:68] Quicken +1 [M14:209] Elixir of Immortality +1 [THS:228] Temple of Triumph +2 [M14:228] Mutavault +2 [RTR:54] Syncopate +3 [M14:29] Planar Cleansing +4 [RTR:241] Hallowed Fountain +SB: 4 [JOU:18] Nyx-Fleece Ram +SB: 2 [THS:49] Gainsay +SB: 2 [THS:22] Last Breath +SB: 2 [M14:5] Archangel of Thune +SB: 2 [RTR:36] Dispel +SB: 1 [M14:60] Jace, Memory Adept +SB: 1 [THS:9] Elspeth, Sun's Champion +SB: 1 [JOU:7] Deicide diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 58 World Championship 2010 (Chiba) ST 12-12-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 58 World Championship 2010 (Chiba) ST 12-12-10.dck new file mode 100644 index 00000000000..583d37c4abd --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Control 58 World Championship 2010 (Chiba) ST 12-12-10.dck @@ -0,0 +1,26 @@ +2 [M15:71] Negate +4 [WWK:133] Celestial Colonnade +4 [ZEN:70] Spreading Seas +3 [M11:7] Baneslayer Angel +2 [M12:16] Gideon Jura +2 [ZEN:220] Misty Rainforest +5 [UNH:137] Island +4 [ROE:40] Oust +3 [UNH:136] Plains +4 [WWK:31] Jace, the Mind Sculptor +4 [M12:63] Mana Leak +2 [M11:58] Jace Beleren +1 [SOM:46] Stoic Rebuttal +4 [SOM:229] Seachrome Coast +4 [C14:313] Tectonic Edge +4 [M13:225] Glacial Fortress +4 [M11:70] Preordain +2 [SOM:6] Elspeth Tirel +2 [M12:12] Day of Judgment +SB: 2 [M15:71] Negate +SB: 1 [M11:7] Baneslayer Angel +SB: 1 [ZEN:57] Mindbreak Trap +SB: 3 [M12:52] Flashfreeze +SB: 3 [M14:215] Ratchet Bomb +SB: 4 [SOM:14] Leonin Arbiter +SB: 1 [SOM:135] Venser, the Sojourner diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..f6239aa78c1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,28 @@ +3 [ISD:244] Moorland Haunt +1 [ISD:231] Runechanter's Pike +9 [UNH:137] Island +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +4 [ISD:78] Snapcaster Mage +4 [M12:63] Mana Leak +2 [DKA:52] Thought Scour +4 [M12:73] Ponder +4 [ISD:213] Geist of Saint Traft +2 [ISD:60] Invisible Stalker +2 [NPH:86] Gut Shot +4 [NPH:35] Gitaxian Probe +4 [NPH:48] Vapor Snag +4 [SOM:229] Seachrome Coast +1 [NPH:57] Dismember +4 [M13:225] Glacial Fortress +3 [NPH:161] Sword of War and Peace +SB: 2 [BNG:25] Revoke Existence +SB: 1 [M13:22] Oblivion Ring +SB: 3 [M12:40] Timely Reinforcements +SB: 1 [NPH:116] Mutagenic Growth +SB: 2 [M15:51] Dissipate +SB: 1 [NPH:57] Dismember +SB: 1 [MBS:5] Divine Offering +SB: 2 [M12:72] Phantasmal Image +SB: 1 [M12:12] Day of Judgment +SB: 1 [MBS:21] Consecrated Sphinx diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Human Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Human Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..66e30a9138e --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UW Human Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,30 @@ +3 [DKA:8] Gather the Townsfolk +2 [ISD:244] Moorland Haunt +2 [MBS:115] Mortarpod +2 [CNS:69] Doomed Traveler +1 [DKA:7] Faith's Shield +5 [UNH:137] Island +5 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +4 [ISD:78] Snapcaster Mage +4 [M12:63] Mana Leak +4 [M12:73] Ponder +2 [ISD:213] Geist of Saint Traft +1 [BNG:25] Revoke Existence +4 [NPH:35] Gitaxian Probe +4 [ISD:6] Champion of the Parish +1 [C14:80] Midnight Haunting +4 [NPH:48] Vapor Snag +4 [SOM:229] Seachrome Coast +4 [M13:225] Glacial Fortress +SB: 2 [M13:22] Oblivion Ring +SB: 2 [M15:71] Negate +SB: 1 [M12:40] Timely Reinforcements +SB: 1 [NPH:38] Mental Misstep +SB: 1 [DKA:7] Faith's Shield +SB: 1 [M14:215] Ratchet Bomb +SB: 2 [MBS:5] Divine Offering +SB: 1 [ISD:14] Feeling of Dread +SB: 1 [C13:42] Dungeon Geists +SB: 2 [NPH:86] Gut Shot +SB: 1 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 2 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 2 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..2ec24b94388 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 2 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,30 @@ +4 [RTR:145] Azorius Charm +4 [ISD:248] Sulfur Falls +3 [M13:147] Searing Spear +1 [UNH:137] Island +3 [AVR:32] Restoration Angel +1 [UNH:136] Plains +4 [RTR:247] Steam Vents +3 [ISD:78] Snapcaster Mage +4 [C13:179] Boros Charm +3 [RTR:200] Sphinx's Revelation +4 [ISD:238] Clifftop Retreat +1 [M13:75] Unsummon +1 [CNS:74] Moment of Heroism +4 [GTC:245] Sacred Foundry +4 [GTC:215] Boros Reckoner +2 [M13:225] Glacial Fortress +4 [C13:30] Augur of Bolas +2 [C14:172] Blasphemous Act +2 [RTR:172] Izzet Charm +2 [AVR:226] Cavern of Souls +2 [AVR:149] Pillar of Flame +2 [RTR:241] Hallowed Fountain +SB: 1 [RTR:47] Psychic Spiral +SB: 2 [M15:71] Negate +SB: 2 [RTR:201] Supreme Verdict +SB: 4 [ISD:213] Geist of Saint Traft +SB: 1 [M14:60] Jace, Memory Adept +SB: 2 [M13:150] Thundermaw Hellkite +SB: 2 [C14:278] Tormod's Crypt +SB: 1 [AVR:149] Pillar of Flame diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 58 PT Gatecrash (Montreal) ST 2-17-13.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 58 PT Gatecrash (Montreal) ST 2-17-13.dck new file mode 100644 index 00000000000..97de7c74b2d --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWR Midrange 58 PT Gatecrash (Montreal) ST 2-17-13.dck @@ -0,0 +1,31 @@ +4 [RTR:145] Azorius Charm +4 [ISD:248] Sulfur Falls +3 [M13:147] Searing Spear +1 [UNH:137] Island +3 [AVR:32] Restoration Angel +1 [UNH:136] Plains +4 [RTR:247] Steam Vents +3 [ISD:78] Snapcaster Mage +4 [DKA:52] Thought Scour +3 [RTR:200] Sphinx's Revelation +1 [RTR:201] Supreme Verdict +3 [ISD:238] Clifftop Retreat +2 [UNH:139] Mountain +1 [ISD:146] Harvest Pyre +1 [ISD:83] Think Twice +1 [M13:65] Rewind +2 [GTC:245] Sacred Foundry +4 [GTC:215] Boros Reckoner +4 [M13:225] Glacial Fortress +4 [C13:30] Augur of Bolas +1 [RTR:153] Counterflux +2 [RTR:101] Mizzium Mortars +4 [RTR:241] Hallowed Fountain +SB: 2 [M13:22] Oblivion Ring +SB: 2 [M15:71] Negate +SB: 2 [DKA:149] Grafdigger's Cage +SB: 2 [M14:55] Essence Scatter +SB: 2 [RTR:36] Dispel +SB: 1 [M13:29] Rhox Faithmender +SB: 3 [M14:60] Jace, Memory Adept +SB: 1 [M14:29] Planar Cleansing diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..a2e7ff04921 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 34 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,33 @@ +2 [ISD:244] Moorland Haunt +1 [UNH:138] Swamp +5 [UNH:137] Island +4 [ISD:78] Snapcaster Mage +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +2 [M12:63] Mana Leak +4 [M12:73] Ponder +3 [M12:72] Phantasmal Image +1 [NPH:86] Gut Shot +4 [DKA:12] Lingering Souls +1 [BNG:25] Revoke Existence +4 [NPH:35] Gitaxian Probe +4 [NPH:48] Vapor Snag +4 [SOM:229] Seachrome Coast +3 [M13:225] Glacial Fortress +4 [SOM:226] Darkslick Shores +1 [MBS:5] Divine Offering +4 [DKA:136] Drogskol Captain +2 [C13:42] Dungeon Geists +2 [C14:295] Evolving Wilds +SB: 1 [M12:13] Demystify +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:71] Negate +SB: 1 [M15:51] Dissipate +SB: 1 [NPH:57] Dismember +SB: 1 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [M12:72] Phantasmal Image +SB: 2 [C13:42] Dungeon Geists +SB: 2 [NPH:86] Gut Shot +SB: 2 [NPH:74] Surgical Extraction +SB: 1 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck new file mode 100644 index 00000000000..e9cac761e3f --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWb Delver 58 PT Dark Ascension (Honolulu) ST 2-12-12.dck @@ -0,0 +1,33 @@ +2 [ISD:244] Moorland Haunt +1 [UNH:138] Swamp +5 [UNH:137] Island +4 [ISD:78] Snapcaster Mage +1 [UNH:136] Plains +4 [ISD:51] Delver of Secrets +2 [M12:63] Mana Leak +4 [M12:73] Ponder +3 [M12:72] Phantasmal Image +4 [DKA:12] Lingering Souls +1 [BNG:25] Revoke Existence +4 [NPH:35] Gitaxian Probe +1 [NPH:116] Mutagenic Growth +4 [NPH:48] Vapor Snag +4 [SOM:229] Seachrome Coast +3 [M13:225] Glacial Fortress +4 [SOM:226] Darkslick Shores +1 [MBS:5] Divine Offering +4 [DKA:136] Drogskol Captain +2 [C13:42] Dungeon Geists +2 [C14:295] Evolving Wilds +SB: 1 [BNG:25] Revoke Existence +SB: 1 [M15:71] Negate +SB: 1 [M12:40] Timely Reinforcements +SB: 1 [M15:51] Dissipate +SB: 1 [NPH:57] Dismember +SB: 2 [M14:215] Ratchet Bomb +SB: 2 [M12:63] Mana Leak +SB: 1 [MBS:5] Divine Offering +SB: 1 [C13:42] Dungeon Geists +SB: 2 [NPH:86] Gut Shot +SB: 1 [NPH:74] Surgical Extraction +SB: 1 [M12:11] Celestial Purge diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWr Control 58 World Championship 2006 (Paris) ST 12-3-06.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWr Control 58 World Championship 2006 (Paris) ST 12-3-06.dck new file mode 100644 index 00000000000..d2546d923be --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/UWr Control 58 World Championship 2006 (Paris) ST 12-3-06.dck @@ -0,0 +1,30 @@ +4 [CMD:43] Court Hussar +2 [C13:279] Boros Garrison +2 [10E:347] Adarkar Wastes +1 [C13:331] Urza's Factory +3 [CMD:243] Boros Signet +3 [UNH:137] Island +1 [UNH:136] Plains +2 [RTR:247] Steam Vents +1 [APC:108] Lightning Angel +4 [RAV:213] Lightning Helix +1 [C14:86] Sacred Mesa +4 [DIS:60] Demonfire +1 [TSB:94] Lightning Angel +4 [C14:102] Compulsive Research +3 [GTC:245] Sacred Foundry +3 [DIS:159] Azorius Signet +4 [RAV:63] Remand +4 [C13:27] Wrath of God +2 [C13:296] Izzet Boilerworks +2 [C14:173] Bogardan Hellkite +2 [DDN:56] Lightning Angel +2 [M15:246] Shivan Reef +2 [TSP:272] Flagstones of Trokair +3 [RTR:241] Hallowed Fountain +SB: 4 [9ED:59] Annex +SB: 3 [C14:69] Condemn +SB: 1 [C14:86] Sacred Mesa +SB: 2 [9ED:23] Ivory Mask +SB: 2 [GPT:143] Giant Solifuge +SB: 3 [RAV:16] Faith's Fetters diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WB Tokens 58 PT Kyoto ST 3-1-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WB Tokens 58 PT Kyoto ST 3-1-09.dck new file mode 100644 index 00000000000..66a4fded056 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WB Tokens 58 PT Kyoto ST 3-1-09.dck @@ -0,0 +1,25 @@ +4 [LRW:281] Windbrisk Heights +4 [M15:241] Caves of Koilos +2 [C13:273] Arcane Sanctum +2 [UNH:138] Swamp +3 [UNH:136] Plains +2 [M11:1] Ajani Goldmane +4 [MOR:58] Bitterblossom +4 [EVE:176] Fetid Heath +1 [ALA:9] Elspeth, Knight-Errant +4 [CNS:210] Reflecting Pool +4 [C14:90] Spectral Procession +4 [LRW:28] Knight of Meadowgrain +4 [THS:107] Thoughtseize +4 [10E:17] Glorious Anthem +4 [CMD:25] Path to Exile +4 [LRW:10] Cloudgoat Ranger +4 [ALA:202] Tidehollow Sculler +2 [M14:228] Mutavault +SB: 3 [LRW:48] Wispmare +SB: 3 [C13:27] Wrath of God +SB: 4 [LRW:7] Burrenton Forge-Tender +SB: 1 [C14:78] Martial Coup +SB: 2 [CON:53] Scepter of Fugue +SB: 1 [M11:1] Ajani Goldmane +SB: 1 [ALA:9] Elspeth, Knight-Errant diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Kithkins 58 PT Kyoto ST 3-1-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Kithkins 58 PT Kyoto ST 3-1-09.dck new file mode 100644 index 00000000000..eb7043664b1 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Kithkins 58 PT Kyoto ST 3-1-09.dck @@ -0,0 +1,21 @@ +4 [M15:240] Battlefield Forge +4 [LRW:281] Windbrisk Heights +9 [UNH:136] Plains +2 [MOR:150] Rustic Clachan +4 [EVE:178] Rugged Prairie +4 [ALA:154] Ajani Vengeant +4 [C14:90] Spectral Procession +4 [LRW:18] Goldmeadow Stalwart +4 [LRW:28] Knight of Meadowgrain +4 [LRW:49] Wizened Cenn +3 [10E:17] Glorious Anthem +4 [EVE:139] Figure of Destiny +4 [CMD:25] Path to Exile +4 [LRW:10] Cloudgoat Ranger +2 [M14:228] Mutavault +SB: 2 [ALA:21] Ranger of Eos +SB: 4 [MOR:22] Reveillark +SB: 4 [LRW:7] Burrenton Forge-Tender +SB: 1 [CON:58] Banefire +SB: 1 [DDN:31] Banefire +SB: 3 [ALA:9] Elspeth, Knight-Errant diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 34 PT Kyoto ST 3-1-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 34 PT Kyoto ST 3-1-09.dck new file mode 100644 index 00000000000..c28577e7f5a --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 34 PT Kyoto ST 3-1-09.dck @@ -0,0 +1,26 @@ +4 [M15:240] Battlefield Forge +4 [LRW:281] Windbrisk Heights +3 [10E:219] Mogg Fanatic +3 [ALA:21] Ranger of Eos +3 [UNH:136] Plains +3 [MOR:22] Reveillark +4 [ALA:16] Knight of the White Orchid +3 [M10:157] Siege-Gang Commander +4 [C14:250] Mind Stone +3 [UNH:139] Mountain +4 [EVE:178] Rugged Prairie +4 [ALA:154] Ajani Vengeant +4 [CNS:210] Reflecting Pool +4 [C14:90] Spectral Procession +2 [C13:27] Wrath of God +4 [EVE:139] Figure of Destiny +3 [CMD:25] Path to Exile +1 [LRW:167] Flamekin Harbinger +SB: 4 [EVE:95] Stillmoon Cavalier +SB: 2 [LRW:7] Burrenton Forge-Tender +SB: 2 [C13:27] Wrath of God +SB: 1 [CON:58] Banefire +SB: 1 [CMD:25] Path to Exile +SB: 1 [MM2:104] Banefire +SB: 2 [SHM:66] Faerie Macabre +SB: 2 [ALA:9] Elspeth, Knight-Errant diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 58 PT Kyoto ST 3-1-09.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 58 PT Kyoto ST 3-1-09.dck new file mode 100644 index 00000000000..475382caaa6 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/WR Vengeant 58 PT Kyoto ST 3-1-09.dck @@ -0,0 +1,23 @@ +4 [M15:240] Battlefield Forge +4 [LRW:281] Windbrisk Heights +4 [10E:219] Mogg Fanatic +4 [ALA:21] Ranger of Eos +5 [UNH:136] Plains +1 [LRW:7] Burrenton Forge-Tender +3 [MOR:22] Reveillark +4 [ALA:16] Knight of the White Orchid +3 [M10:157] Siege-Gang Commander +4 [UNH:139] Mountain +4 [EVE:178] Rugged Prairie +4 [ALA:154] Ajani Vengeant +3 [CNS:210] Reflecting Pool +4 [C14:90] Spectral Procession +4 [EVE:139] Figure of Destiny +3 [CMD:25] Path to Exile +2 [DDN:31] Banefire +SB: 4 [EVE:95] Stillmoon Cavalier +SB: 3 [LRW:7] Burrenton Forge-Tender +SB: 1 [MOR:22] Reveillark +SB: 1 [CON:58] Banefire +SB: 2 [M10:141] Ignite Disorder +SB: 4 [CON:9] Lapse of Certainty diff --git a/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/White Weenie 34 PT San Diego ST 2-21-10.dck b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/White Weenie 34 PT San Diego ST 2-21-10.dck new file mode 100644 index 00000000000..92bce03f941 --- /dev/null +++ b/Mage.Client/release/sample-decks/Top8 PT and Worlds decks (Standard)/White Weenie 34 PT San Diego ST 2-21-10.dck @@ -0,0 +1,23 @@ +4 [M11:39] White Knight +12 [UNH:136] Plains +4 [ZEN:211] Arid Mesa +1 [ALA:219] Sigil of Distinction +4 [WWK:135] Dread Statuary +4 [ALA:9] Elspeth, Knight-Errant +2 [M13:22] Oblivion Ring +1 [C14:293] Emeria, the Sky Ruin +4 [ZEN:219] Marsh Flats +4 [ZEN:23] Kor Skyfisher +4 [ZEN:36] Steppe Lynx +4 [CMD:25] Path to Exile +4 [WWK:11] Kor Firewalker +4 [WWK:20] Stoneforge Mystic +1 [ZEN:209] Trusty Machete +1 [WWK:122] Basilisk Collar +2 [M12:12] Day of Judgment +SB: 2 [ZEN:25] Luminarch Ascension +SB: 2 [M13:22] Oblivion Ring +SB: 4 [ZEN:10] Devout Lightcaster +SB: 3 [C14:76] Kor Sanctifiers +SB: 2 [ALA:218] Relic of Progenitus +SB: 2 [M12:12] Day of Judgment diff --git a/Mage.Client/sounds/OnAddArtifact.wav b/Mage.Client/sounds/OnAddArtifact.wav index e9488ecad8e..2d6295ca752 100644 Binary files a/Mage.Client/sounds/OnAddArtifact.wav and b/Mage.Client/sounds/OnAddArtifact.wav differ diff --git a/Mage.Client/sounds/OnAddPermanent.wav b/Mage.Client/sounds/OnAddPermanent.wav index ac338bf4c86..7ca048e5141 100644 Binary files a/Mage.Client/sounds/OnAddPermanent.wav and b/Mage.Client/sounds/OnAddPermanent.wav differ diff --git a/Mage.Client/sounds/OnAttack.wav b/Mage.Client/sounds/OnAttack.wav index 48f3b7ac287..815db42ae67 100644 Binary files a/Mage.Client/sounds/OnAttack.wav and b/Mage.Client/sounds/OnAttack.wav differ diff --git a/Mage.Client/sounds/OnBlock.wav b/Mage.Client/sounds/OnBlock.wav index 984ab5f9145..28bf3ddde51 100644 Binary files a/Mage.Client/sounds/OnBlock.wav and b/Mage.Client/sounds/OnBlock.wav differ diff --git a/Mage.Client/sounds/OnButtonCancel.wav b/Mage.Client/sounds/OnButtonCancel.wav index cb0b80dbf8a..9b0c04ca6f8 100644 Binary files a/Mage.Client/sounds/OnButtonCancel.wav and b/Mage.Client/sounds/OnButtonCancel.wav differ diff --git a/Mage.Client/sounds/OnButtonOk.wav b/Mage.Client/sounds/OnButtonOk.wav index 7c33054ce49..f0e09ff85b9 100644 Binary files a/Mage.Client/sounds/OnButtonOk.wav and b/Mage.Client/sounds/OnButtonOk.wav differ diff --git a/Mage.Client/sounds/OnCountdown1.wav b/Mage.Client/sounds/OnCountdown1.wav index 5ab29bf462b..08fbe61614b 100644 Binary files a/Mage.Client/sounds/OnCountdown1.wav and b/Mage.Client/sounds/OnCountdown1.wav differ diff --git a/Mage.Client/sounds/OnDraftSelect.wav b/Mage.Client/sounds/OnDraftSelect.wav index cd8a5c09dbd..a7aa354a744 100644 Binary files a/Mage.Client/sounds/OnDraftSelect.wav and b/Mage.Client/sounds/OnDraftSelect.wav differ diff --git a/Mage.Client/sounds/OnDraw.wav b/Mage.Client/sounds/OnDraw.wav index 144d2009d1f..a91c5ec6f4d 100644 Binary files a/Mage.Client/sounds/OnDraw.wav and b/Mage.Client/sounds/OnDraw.wav differ diff --git a/Mage.Client/sounds/OnEndTurn.wav b/Mage.Client/sounds/OnEndTurn.wav index 56a6c525e2f..261e7482e33 100644 Binary files a/Mage.Client/sounds/OnEndTurn.wav and b/Mage.Client/sounds/OnEndTurn.wav differ diff --git a/Mage.Client/sounds/OnGameStart.wav b/Mage.Client/sounds/OnGameStart.wav index 791a85b591a..08d76fefdb0 100644 Binary files a/Mage.Client/sounds/OnGameStart.wav and b/Mage.Client/sounds/OnGameStart.wav differ diff --git a/Mage.Client/sounds/OnHover.wav b/Mage.Client/sounds/OnHover.wav index fae205369b0..459fd070553 100644 Binary files a/Mage.Client/sounds/OnHover.wav and b/Mage.Client/sounds/OnHover.wav differ diff --git a/Mage.Client/sounds/OnNextPage.wav b/Mage.Client/sounds/OnNextPage.wav index e109a11679c..c8aae197d5d 100644 Binary files a/Mage.Client/sounds/OnNextPage.wav and b/Mage.Client/sounds/OnNextPage.wav differ diff --git a/Mage.Client/sounds/OnNextPhase.wav b/Mage.Client/sounds/OnNextPhase.wav index 7d321fc19fb..09cfb019cac 100644 Binary files a/Mage.Client/sounds/OnNextPhase.wav and b/Mage.Client/sounds/OnNextPhase.wav differ diff --git a/Mage.Client/sounds/OnPlayerJoined.wav b/Mage.Client/sounds/OnPlayerJoined.wav index 0182728328d..98a94af7515 100644 Binary files a/Mage.Client/sounds/OnPlayerJoined.wav and b/Mage.Client/sounds/OnPlayerJoined.wav differ diff --git a/Mage.Client/sounds/OnPlayerLeft.wav b/Mage.Client/sounds/OnPlayerLeft.wav index c0590e8489f..13c6a54aa3b 100644 Binary files a/Mage.Client/sounds/OnPlayerLeft.wav and b/Mage.Client/sounds/OnPlayerLeft.wav differ diff --git a/Mage.Client/sounds/OnPlayerLost.wav b/Mage.Client/sounds/OnPlayerLost.wav index 4fd3e50fb19..4960cf90d4d 100644 Binary files a/Mage.Client/sounds/OnPlayerLost.wav and b/Mage.Client/sounds/OnPlayerLost.wav differ diff --git a/Mage.Client/sounds/OnPlayerQuit.wav b/Mage.Client/sounds/OnPlayerQuit.wav index d9b2826d1ec..4d97f17e4fe 100644 Binary files a/Mage.Client/sounds/OnPlayerQuit.wav and b/Mage.Client/sounds/OnPlayerQuit.wav differ diff --git a/Mage.Client/sounds/OnPlayerQuitTournament.wav b/Mage.Client/sounds/OnPlayerQuitTournament.wav index c92220b59c0..8857e7980f7 100644 Binary files a/Mage.Client/sounds/OnPlayerQuitTournament.wav and b/Mage.Client/sounds/OnPlayerQuitTournament.wav differ diff --git a/Mage.Client/sounds/OnPlayerSubmittedDeck.wav b/Mage.Client/sounds/OnPlayerSubmittedDeck.wav index cfa7603c0fd..1e89502f8fd 100644 Binary files a/Mage.Client/sounds/OnPlayerSubmittedDeck.wav and b/Mage.Client/sounds/OnPlayerSubmittedDeck.wav differ diff --git a/Mage.Client/sounds/OnPlayerWhispered.wav b/Mage.Client/sounds/OnPlayerWhispered.wav index ad26c3a9d41..7e58c8a5a1c 100644 Binary files a/Mage.Client/sounds/OnPlayerWhispered.wav and b/Mage.Client/sounds/OnPlayerWhispered.wav differ diff --git a/Mage.Client/sounds/OnPlayerWon.wav b/Mage.Client/sounds/OnPlayerWon.wav index 3c9eda4625e..91f00881dde 100644 Binary files a/Mage.Client/sounds/OnPlayerWon.wav and b/Mage.Client/sounds/OnPlayerWon.wav differ diff --git a/Mage.Client/sounds/OnPrevPage.wav b/Mage.Client/sounds/OnPrevPage.wav index 9cafab28a64..85b7179063c 100644 Binary files a/Mage.Client/sounds/OnPrevPage.wav and b/Mage.Client/sounds/OnPrevPage.wav differ diff --git a/Mage.Client/sounds/OnSkipButton.wav b/Mage.Client/sounds/OnSkipButton.wav index 7d321fc19fb..db8a44c52f7 100644 Binary files a/Mage.Client/sounds/OnSkipButton.wav and b/Mage.Client/sounds/OnSkipButton.wav differ diff --git a/Mage.Client/sounds/OnSkipButtonCancel.wav b/Mage.Client/sounds/OnSkipButtonCancel.wav index cb0b80dbf8a..d58aa0144a4 100644 Binary files a/Mage.Client/sounds/OnSkipButtonCancel.wav and b/Mage.Client/sounds/OnSkipButtonCancel.wav differ diff --git a/Mage.Client/sounds/OnStackNew.wav b/Mage.Client/sounds/OnStackNew.wav index 4fd917b8e84..4610b5fe33c 100644 Binary files a/Mage.Client/sounds/OnStackNew.wav and b/Mage.Client/sounds/OnStackNew.wav differ diff --git a/Mage.Client/sounds/OnSummon-.wav b/Mage.Client/sounds/OnSummon-.wav index 1facee015c8..63e57d3df3e 100644 Binary files a/Mage.Client/sounds/OnSummon-.wav and b/Mage.Client/sounds/OnSummon-.wav differ diff --git a/Mage.Client/sounds/OnSummon.wav b/Mage.Client/sounds/OnSummon.wav index f41a49e9a68..bf5bed88cce 100644 Binary files a/Mage.Client/sounds/OnSummon.wav and b/Mage.Client/sounds/OnSummon.wav differ diff --git a/Mage.Client/sounds/OnTapPermanent.wav b/Mage.Client/sounds/OnTapPermanent.wav index 7c33054ce49..8760020598e 100644 Binary files a/Mage.Client/sounds/OnTapPermanent.wav and b/Mage.Client/sounds/OnTapPermanent.wav differ diff --git a/Mage.Client/sounds/OnTournamentStart.wav b/Mage.Client/sounds/OnTournamentStart.wav index a6aa47f24fc..94df53fcd9f 100644 Binary files a/Mage.Client/sounds/OnTournamentStart.wav and b/Mage.Client/sounds/OnTournamentStart.wav differ diff --git a/Mage.Client/src/main/java/mage/client/components/HoverButton.java b/Mage.Client/src/main/java/mage/client/components/HoverButton.java index d7998fe5041..f9baab84a83 100644 --- a/Mage.Client/src/main/java/mage/client/components/HoverButton.java +++ b/Mage.Client/src/main/java/mage/client/components/HoverButton.java @@ -20,6 +20,8 @@ import mage.client.util.Command; */ public class HoverButton extends JPanel implements MouseListener { + static final int TOP_TEXT_IMAGE_GAP = 3; + private Image image; private Image hoverImage; private Image disabledImage; @@ -36,6 +38,7 @@ public class HoverButton extends JPanel implements MouseListener { private Dimension overlayImageSize; private String topText; + private Image topTextImage; private boolean isHovered = false; private boolean isSelected = false; @@ -45,7 +48,7 @@ public class HoverButton extends JPanel implements MouseListener { private Command observer = null; private Command onHover = null; private Color textColor = Color.white; - private Color textBGColor = Color.black; + private final Color textBGColor = Color.black; static final Font textFont = new Font("Arial", Font.PLAIN, 12); static final Font textFontMini = new Font("Arial", Font.PLAIN, 11); @@ -120,9 +123,12 @@ public class HoverButton extends JPanel implements MouseListener { } topTextOffsetX = calculateOffsetForTop(g2d, topText); g2d.setColor(textBGColor); - g2d.drawString(topText, topTextOffsetX + 1, 13); + g2d.drawString(topText, topTextOffsetX + 1, 14); g2d.setColor(textColor); - g2d.drawString(topText, topTextOffsetX, 12); + g2d.drawString(topText, topTextOffsetX, 13); + } + if (topTextImage != null) { + g.drawImage(topTextImage, 4, 3, this); } if (overlayImage != null) { g.drawImage(overlayImage, (imageSize.width - overlayImageSize.width) / 2, 10, this); @@ -168,7 +174,9 @@ public class HoverButton extends JPanel implements MouseListener { if (topTextOffsetX == -1) { // calculate once FontRenderContext frc = g2d.getFontRenderContext(); int textWidth = (int) textFont.getStringBounds(text, frc).getWidth(); - topTextOffsetX = (imageSize.width - textWidth) / 2; + int neededImageWidth = (topTextImage == null ? 0 : topTextImage.getWidth(this)); + int availableXWidth = imageSize.width - neededImageWidth; + topTextOffsetX = (availableXWidth - textWidth) / 2 + neededImageWidth; } return topTextOffsetX; } @@ -284,6 +292,11 @@ public class HoverButton extends JPanel implements MouseListener { this.topText = topText; } + public void setTopTextImage(Image topTextImage) { + this.topTextImage = topTextImage; + this.textOffsetX = -1; // rest for new clculation + } + public void setTextAlwaysVisible(boolean textAlwaysVisible) { this.textAlwaysVisible = textAlwaysVisible; } diff --git a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGenerator.java b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGenerator.java index cdfad4bf344..2a7d8570191 100644 --- a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGenerator.java +++ b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGenerator.java @@ -193,6 +193,7 @@ public class DeckGenerator { Random random = new Random(); int count = 0; int reservesAdded = 0; + boolean added; if (retrievedCount > 0 && retrievedCount >= spellCount) { int tries = 0; while (count < spellCount) { @@ -208,9 +209,10 @@ public class DeckGenerator { count++; } } else { - if (reservesAdded < genPool.getDeckSize() / 2) { - genPool.tryAddReserve(card, cardCMC); - reservesAdded++; + if (reservesAdded < (genPool.getDeckSize() / 2)) { + added = genPool.tryAddReserve(card, cardCMC); + if(added) + reservesAdded++; } } } diff --git a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorDialog.java b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorDialog.java index 009785b124f..8e3770ce582 100644 --- a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorDialog.java +++ b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorDialog.java @@ -39,7 +39,8 @@ import java.awt.*; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.io.File; -import java.util.UUID; +import java.text.SimpleDateFormat; +import java.util.Date; /** * @@ -53,10 +54,12 @@ public class DeckGeneratorDialog { private static JComboBox cbDeckSize; private static JButton btnGenerate, btnCancel; private static JCheckBox cArtifacts, cSingleton, cNonBasicLands; + private static SimpleDateFormat dateFormat; public DeckGeneratorDialog() { initDialog(); + dateFormat = new SimpleDateFormat("dd-MM-yyyy-hh-mm-ss-SSS"); } private void initDialog() { @@ -172,14 +175,17 @@ public class DeckGeneratorDialog { for (ActionListener al: btnCancel.getActionListeners()) { btnCancel.removeActionListener(al); } - //deck = null; } public String saveDeck(Deck deck) { try { - File tmp = File.createTempFile("tempDeck" + UUID.randomUUID().toString(), ".dck"); + // Random directory through the system property to avoid random numeric string attached to temp files. + String tempDir = System.getProperty("java.io.tmpdir"); + // Generated deck has a nice unique name which corresponds to the timestamp at which it was created. + String deckName = "Generated-Deck-" + dateFormat.format( new Date()); + File tmp = new File(tempDir + File.separator + deckName + ".dck"); tmp.createNewFile(); - deck.setName("Generated-Deck-" + UUID.randomUUID()); + deck.setName(deckName); Sets.saveDeck(tmp.getAbsolutePath(), deck.getDeckCardLists()); DeckGeneratorDialog.cleanUp(); return tmp.getAbsolutePath(); diff --git a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorPool.java b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorPool.java index 64daa31f5a0..d45838990ee 100644 --- a/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorPool.java +++ b/Mage.Client/src/main/java/mage/client/deck/generator/DeckGeneratorPool.java @@ -176,13 +176,15 @@ public class DeckGeneratorPool * @param card the card to add * @param cardCMC the converted mana cost of the card */ - public void tryAddReserve(Card card, int cardCMC) { + public boolean tryAddReserve(Card card, int cardCMC) { // Only cards with CMC < 7 and don't already exist in the deck // can be added to our reserve pool as not to overwhelm the curve // with high CMC cards and duplicates. if(cardCMC < 7 && getCardCount(card.getName()) == 0) { this.reserveSpells.add(card); + return true; } + return false; } /** @@ -386,13 +388,13 @@ public class DeckGeneratorPool List spellsToAdd = new ArrayList<>(spellsNeeded); // Initial reservoir - for(int i = 0; i < spellsNeeded-1; i++) + for(int i = 0; i < spellsNeeded; i++) spellsToAdd.add(reserveSpells.get(i)); - for(int j = spellsNeeded+1; j < reserveSpells.size()-1; j++) { - int index = random.nextInt(j); - Card randomCard = reserveSpells.get(index); - if (index < j && isValidSpellCard(randomCard)) { + for(int i = spellsNeeded+1; i < reserveSpells.size()-1; i++) { + int j = random.nextInt(i); + Card randomCard = reserveSpells.get(j); + if (isValidSpellCard(randomCard) && j < spellsToAdd.size()) { spellsToAdd.set(j, randomCard); } } diff --git a/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.form b/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.form index beb4c5799db..92ca80af088 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.form +++ b/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.form @@ -169,7 +169,7 @@ - + @@ -521,10 +521,8 @@ - - - - + + diff --git a/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.java b/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.java index fd3e9d07a13..796b15b9b7f 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.java +++ b/Mage.Client/src/main/java/mage/client/dialog/NewTournamentDialog.java @@ -34,8 +34,10 @@ package mage.client.dialog; +import java.awt.Component; import java.util.ArrayList; import java.util.Arrays; +import java.util.Collections; import java.util.List; import java.util.UUID; import javax.swing.ComboBoxModel; @@ -122,8 +124,8 @@ public class NewTournamentDialog extends MageDialog { cbAllowSpectators.setSelected(true); setTournamentSettingsFromPrefs(); this.setModal(true); - this.setLocation(150, 100); - } + this.setLocation(150, 100); + } this.setVisible(true); } @@ -341,7 +343,7 @@ public class NewTournamentDialog extends MageDialog { pnlRandomPacks.setBorder(javax.swing.BorderFactory.createEtchedBorder()); pnlRandomPacks.setToolTipText(""); - pnlRandomPacks.setLayout(new java.awt.GridLayout(0, 1, 2, 0)); + pnlRandomPacks.setLayout(new javax.swing.BoxLayout(pnlRandomPacks, javax.swing.BoxLayout.Y_AXIS)); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); @@ -468,7 +470,7 @@ public class NewTournamentDialog extends MageDialog { .addGroup(layout.createSequentialGroup() .addComponent(pnlPacks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) - .addComponent(pnlRandomPacks, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) + .addComponent(pnlRandomPacks, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) @@ -477,7 +479,7 @@ public class NewTournamentDialog extends MageDialog { .addComponent(lblNumRounds)) .addComponent(lblNbrPlayers, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(spnNumPlayers) - .addComponent(pnlDraftOptions, javax.swing.GroupLayout.DEFAULT_SIZE, 0, Short.MAX_VALUE)) + .addComponent(pnlDraftOptions, javax.swing.GroupLayout.PREFERRED_SIZE, 0, Short.MAX_VALUE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(lblPlayer1, javax.swing.GroupLayout.PREFERRED_SIZE, 25, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) @@ -533,7 +535,18 @@ public class NewTournamentDialog extends MageDialog { tOptions.getLimitedOptions().setDraftCubeName(this.cbDraftCube.getSelectedItem().toString()); } else if (tournamentType.isRandom()) { tOptions.getLimitedOptions().getSetCodes().clear(); - tOptions.getLimitedOptions().getSetCodes().addAll(randomPackSelector.getSelectedPacks()); + ArrayList selected = randomPackSelector.getSelectedPacks(); + int maxPacks = 3 * (players.size() + 1); + if (selected.size() > maxPacks ){ + StringBuilder infoString = new StringBuilder("More sets were selected than needed. "); + infoString.append(maxPacks); + infoString.append(" sets will be randomly chosen."); + JOptionPane.showMessageDialog(MageFrame.getDesktop(), infoString, "Information", JOptionPane.INFORMATION_MESSAGE); + Collections.shuffle(selected); + tOptions.getLimitedOptions().getSetCodes().addAll(selected.subList(0, maxPacks)); + }else{ + tOptions.getLimitedOptions().getSetCodes().addAll(selected); + } } else { for (JComboBox pack: packs) { tOptions.getLimitedOptions().getSetCodes().add(((ExpansionInfo) pack.getSelectedItem()).getCode()); @@ -717,6 +730,7 @@ public class NewTournamentDialog extends MageDialog { if (pnlRandomPacks.getComponentCount() == 0) { if (randomPackSelector == null) { randomPackSelector = new RandomPacksSelectorDialog(); + randomPackSelector.setLocationRelativeTo(this); } txtRandomPacks = new JTextArea(); txtRandomPacks.setEnabled(false); @@ -736,9 +750,10 @@ public class NewTournamentDialog extends MageDialog { } txtRandomPacks.setText(packList.toString()); } - + txtRandomPacks.setAlignmentX(Component.LEFT_ALIGNMENT); pnlRandomPacks.add(txtRandomPacks); JButton btnSelectRandomPacks = new JButton(); + btnSelectRandomPacks.setAlignmentX(Component.LEFT_ALIGNMENT); btnSelectRandomPacks.setText("Select packs to be included in the pool"); btnSelectRandomPacks.setToolTipText(RandomPacksSelectorDialog.randomDraftDescription); btnSelectRandomPacks.addActionListener(new java.awt.event.ActionListener() { @@ -749,11 +764,11 @@ public class NewTournamentDialog extends MageDialog { } }); pnlRandomPacks.add(btnSelectRandomPacks); - } + } this.pack(); this.revalidate(); this.repaint(); - } + } private void showRandomPackSelectorDialog() { randomPackSelector.showDialog(); diff --git a/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.form b/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.form index 9a586070861..afaf19627ed 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.form +++ b/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.form @@ -82,7 +82,7 @@ - + @@ -333,16 +333,23 @@ - + - + + + + - + + + + + @@ -357,6 +364,16 @@ + + + + + + + + + + @@ -512,7 +529,7 @@ - + @@ -1155,7 +1172,7 @@ - + @@ -1606,7 +1623,7 @@ - + @@ -1819,7 +1836,7 @@ - + diff --git a/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.java b/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.java index 6536cb1973d..af4e96ed42e 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.java +++ b/Mage.Client/src/main/java/mage/client/dialog/PreferencesDialog.java @@ -91,6 +91,7 @@ public class PreferencesDialog extends javax.swing.JDialog { public static final String KEY_GAME_ASK_MOVE_TO_GRAVE_ORDER = "gameAskMoveToGraveORder"; public static final String KEY_GAME_LOG_AUTO_SAVE = "gameLogAutoSave"; + public static final String KEY_DRAFT_LOG_AUTO_SAVE = "draftLogAutoSave"; public static final String KEY_CARD_IMAGES_USE_DEFAULT = "cardImagesUseDefault"; public static final String KEY_CARD_IMAGES_PATH = "cardImagesPath"; @@ -362,6 +363,7 @@ public class PreferencesDialog extends javax.swing.JDialog { cbAskMoveToGraveOrder = new javax.swing.JCheckBox(); main_gamelog = new javax.swing.JPanel(); cbGameLogAutoSave = new javax.swing.JCheckBox(); + cbDraftLogAutoSave = new javax.swing.JCheckBox(); tabPhases = new javax.swing.JPanel(); jLabelHeadLine = new javax.swing.JLabel(); jLabelYourTurn = new javax.swing.JLabel(); @@ -643,18 +645,32 @@ public class PreferencesDialog extends javax.swing.JDialog { } }); + cbDraftLogAutoSave.setSelected(true); + cbDraftLogAutoSave.setText("Auto save draft logs (to \"../Mage.Client/gamelogs/\" directory)"); + cbDraftLogAutoSave.setToolTipText("The logs of all your games will be saved to the mentioned folder if this option is switched on."); + cbDraftLogAutoSave.addActionListener(new java.awt.event.ActionListener() { + public void actionPerformed(java.awt.event.ActionEvent evt) { + cbDraftLogAutoSaveActionPerformed(evt); + } + }); + javax.swing.GroupLayout main_gamelogLayout = new javax.swing.GroupLayout(main_gamelog); main_gamelog.setLayout(main_gamelogLayout); main_gamelogLayout.setHorizontalGroup( main_gamelogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(main_gamelogLayout.createSequentialGroup() .addContainerGap() - .addComponent(cbGameLogAutoSave, javax.swing.GroupLayout.PREFERRED_SIZE, 528, javax.swing.GroupLayout.PREFERRED_SIZE) + .addGroup(main_gamelogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) + .addComponent(cbGameLogAutoSave, javax.swing.GroupLayout.PREFERRED_SIZE, 528, javax.swing.GroupLayout.PREFERRED_SIZE) + .addComponent(cbDraftLogAutoSave, javax.swing.GroupLayout.PREFERRED_SIZE, 528, javax.swing.GroupLayout.PREFERRED_SIZE)) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); main_gamelogLayout.setVerticalGroup( main_gamelogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) - .addComponent(cbGameLogAutoSave, javax.swing.GroupLayout.Alignment.TRAILING) + .addGroup(main_gamelogLayout.createSequentialGroup() + .addComponent(cbGameLogAutoSave) + .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) + .addComponent(cbDraftLogAutoSave)) ); javax.swing.GroupLayout tabMainLayout = new javax.swing.GroupLayout(tabMain); @@ -675,7 +691,7 @@ public class PreferencesDialog extends javax.swing.JDialog { .addContainerGap() .addComponent(main_card, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) - .addComponent(main_game, javax.swing.GroupLayout.PREFERRED_SIZE, 189, Short.MAX_VALUE) + .addComponent(main_game, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(main_gamelog, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addContainerGap()) @@ -861,7 +877,7 @@ public class PreferencesDialog extends javax.swing.JDialog { .addComponent(checkBoxEndTurnOthers)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addComponent(phases_stopSettings, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) - .addContainerGap(13, Short.MAX_VALUE)) + .addContainerGap(45, Short.MAX_VALUE)) ); tabsPanel.addTab("Phases", tabPhases); @@ -1435,7 +1451,7 @@ public class PreferencesDialog extends javax.swing.JDialog { ); tabAvatarsLayout.setVerticalGroup( tabAvatarsLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) - .addComponent(avatarPane, javax.swing.GroupLayout.DEFAULT_SIZE, 359, Short.MAX_VALUE) + .addComponent(avatarPane, javax.swing.GroupLayout.DEFAULT_SIZE, 432, Short.MAX_VALUE) ); tabsPanel.addTab("Avatars", tabAvatars); @@ -1585,7 +1601,7 @@ public class PreferencesDialog extends javax.swing.JDialog { .addGroup(connection_serversLayout.createSequentialGroup() .addGroup(connection_serversLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false) .addComponent(lblURLServerList, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) - .addComponent(txtURLServerList, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) + .addComponent(txtURLServerList, javax.swing.GroupLayout.DEFAULT_SIZE, 28, Short.MAX_VALUE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jLabel17)) ); @@ -1617,7 +1633,7 @@ public class PreferencesDialog extends javax.swing.JDialog { .addComponent(cbProxyType, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGap(18, 18, 18) .addComponent(pnlProxySettings, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) - .addContainerGap(54, Short.MAX_VALUE)) + .addContainerGap(90, Short.MAX_VALUE)) ); pnlProxySettings.getAccessibleContext().setAccessibleDescription(""); @@ -1681,6 +1697,7 @@ public class PreferencesDialog extends javax.swing.JDialog { save(prefs, dialog.cbConfirmEmptyManaPool, KEY_GAME_CONFIRM_EMPTY_MANA_POOL, "true", "false", UPDATE_CACHE_POLICY); save(prefs, dialog.cbAskMoveToGraveOrder, KEY_GAME_ASK_MOVE_TO_GRAVE_ORDER, "true", "false", UPDATE_CACHE_POLICY); save(prefs, dialog.cbGameLogAutoSave, KEY_GAME_LOG_AUTO_SAVE, "true", "false", UPDATE_CACHE_POLICY); + save(prefs, dialog.cbDraftLogAutoSave, KEY_DRAFT_LOG_AUTO_SAVE, "true", "false", UPDATE_CACHE_POLICY); // Phases save(prefs, dialog.checkBoxUpkeepYou, UPKEEP_YOU); @@ -2001,6 +2018,10 @@ public class PreferencesDialog extends javax.swing.JDialog { // TODO add your handling code here: }//GEN-LAST:event_cbAskMoveToGraveOrderActionPerformed + private void cbDraftLogAutoSaveActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cbDraftLogAutoSaveActionPerformed + // TODO add your handling code here: + }//GEN-LAST:event_cbDraftLogAutoSaveActionPerformed + private void showProxySettings() { if (cbProxyType.getSelectedItem() == Connection.ProxyType.SOCKS) { this.pnlProxy.setVisible(true); @@ -2079,6 +2100,7 @@ public class PreferencesDialog extends javax.swing.JDialog { load(prefs, dialog.cbAskMoveToGraveOrder, KEY_GAME_ASK_MOVE_TO_GRAVE_ORDER, "true"); load(prefs, dialog.cbGameLogAutoSave, KEY_GAME_LOG_AUTO_SAVE, "true"); + load(prefs, dialog.cbDraftLogAutoSave, KEY_DRAFT_LOG_AUTO_SAVE, "true"); load(prefs, dialog.checkBoxUpkeepYou, UPKEEP_YOU, "on", "on"); load(prefs, dialog.checkBoxDrawYou, DRAW_YOU, "on", "on"); @@ -2449,6 +2471,7 @@ public class PreferencesDialog extends javax.swing.JDialog { private javax.swing.JCheckBox cbAskMoveToGraveOrder; private javax.swing.JCheckBox cbCheckForNewImages; private javax.swing.JCheckBox cbConfirmEmptyManaPool; + private javax.swing.JCheckBox cbDraftLogAutoSave; private javax.swing.JCheckBox cbEnableBattlefieldBGM; private javax.swing.JCheckBox cbEnableDraftSounds; private javax.swing.JCheckBox cbEnableGameSounds; diff --git a/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.form b/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.form index d486cab0471..7644055a2ac 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.form +++ b/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.form @@ -2,6 +2,7 @@
+ @@ -16,6 +17,9 @@ + + + diff --git a/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.java b/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.java index 5b9b3cc0d09..083f9a42dd0 100644 --- a/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.java +++ b/Mage.Client/src/main/java/mage/client/dialog/RandomPacksSelectorDialog.java @@ -8,6 +8,7 @@ package mage.client.dialog; import java.awt.Component; import java.util.ArrayList; import javax.swing.JCheckBox; +import javax.swing.JOptionPane; import mage.cards.repository.ExpansionInfo; import mage.cards.repository.ExpansionRepository; @@ -101,11 +102,17 @@ public class RandomPacksSelectorDialog extends javax.swing.JDialog { pnlApply = new javax.swing.JPanel(); btnApply = new javax.swing.JButton(); + setDefaultCloseOperation(javax.swing.WindowConstants.DO_NOTHING_ON_CLOSE); setTitle("Random Booster Draft Packs Selector"); setModal(true); setModalExclusionType(java.awt.Dialog.ModalExclusionType.APPLICATION_EXCLUDE); setPreferredSize(new java.awt.Dimension(600, 450)); setResizable(false); + addWindowListener(new java.awt.event.WindowAdapter() { + public void windowClosing(java.awt.event.WindowEvent evt) { + formWindowClosing(evt); + } + }); pnlPacks.setLayout(new java.awt.GridLayout(11, 12)); @@ -174,13 +181,21 @@ public class RandomPacksSelectorDialog extends javax.swing.JDialog { }//GEN-LAST:event_btnNoneActionPerformed private void btnApplyActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnApplyActionPerformed + this.doApply(); + }//GEN-LAST:event_btnApplyActionPerformed + + private void formWindowClosing(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowClosing + this.doApply(); + }//GEN-LAST:event_formWindowClosing + + public void doApply() { if (getSelectedPacks().size() < 2) { - // at least 2 packs must be selected. + JOptionPane.showMessageDialog(this, "At least 2 sets must be selected", "Error", JOptionPane.ERROR_MESSAGE); } else { this.setVisible(false); } - }//GEN-LAST:event_btnApplyActionPerformed - + } + private void setAllCheckBoxes(boolean value) { for (Component pack : pnlPacks.getComponents()) { JCheckBox thePack = (JCheckBox) pack; diff --git a/Mage.Client/src/main/java/mage/client/draft/DraftPanel.java b/Mage.Client/src/main/java/mage/client/draft/DraftPanel.java index 2b4c8613e3e..3b02073cac2 100644 --- a/Mage.Client/src/main/java/mage/client/draft/DraftPanel.java +++ b/Mage.Client/src/main/java/mage/client/draft/DraftPanel.java @@ -41,10 +41,21 @@ import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.KeyEvent; import java.awt.image.BufferedImage; +import java.io.File; +import java.io.IOException; +import java.nio.file.Files; +import java.nio.file.Path; +import java.nio.file.StandardOpenOption; +import java.text.SimpleDateFormat; +import java.util.Collection; +import java.util.Date; import java.util.HashSet; +import java.util.LinkedList; import java.util.Map; import java.util.Set; import java.util.UUID; +import java.util.logging.Level; +import java.util.logging.Logger; import javax.swing.AbstractAction; import javax.swing.ImageIcon; import javax.swing.JComponent; @@ -53,9 +64,12 @@ import javax.swing.JOptionPane; import javax.swing.JPopupMenu; import javax.swing.KeyStroke; import javax.swing.Timer; +import mage.cards.repository.CardInfo; +import mage.cards.repository.CardRepository; import mage.client.MageFrame; import mage.client.components.tray.MageTray; import mage.client.deckeditor.SortSettingDraft; +import mage.client.dialog.PreferencesDialog; import mage.client.plugins.impl.Plugins; import mage.client.util.CardsViewUtil; import mage.client.util.Event; @@ -94,6 +108,19 @@ public class DraftPanel extends javax.swing.JPanel { // id of card with popup menu protected UUID cardIdPopupMenu; + // Filename for the draft log (only updated if writing the log). + private String logFilename; + + // Number of the current booster (for draft log writing). + private int packNo; + + // Number of the current card pick (for draft log writing). + private int pickNo; + + // Cached booster data to be written into the log (see logLastPick). + private String currentBoosterHeader; + private String[] currentBooster; + private static final CardsView emptyView = new CardsView(); /** Creates new form DraftPanel */ @@ -149,6 +176,20 @@ public class DraftPanel extends javax.swing.JPanel { if (!client.joinDraft(draftId)) { hideDraft(); } + + if (isLogging()) { + // If we are logging the draft create a file that will contain + // the log. + SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMdd_HHmmss"); + logFilename = "Draft_" + sdf.format(new Date()) + "_" + draftId + ".txt"; + try { + Files.write(pathToDraftLog(), "".getBytes(), StandardOpenOption.CREATE, StandardOpenOption.TRUNCATE_EXISTING); + } catch (IOException ex) { + Logger.getLogger(DraftPanel.class.getName()).log(Level.SEVERE, null, ex); + } + } else { + logFilename = null; + } } public void updateDraft(DraftView draftView) { @@ -167,6 +208,9 @@ public class DraftPanel extends javax.swing.JPanel { this.chkPack3.setSelected(draftView.getBoosterNum() > 2); this.txtCardNo.setText(Integer.toString(draftView.getCardNum())); + packNo = draftView.getBoosterNum(); + pickNo = draftView.getCardNum(); + int right = draftView.getPlayers().size() / 2; int left = draftView.getPlayers().size() - right; int height = left * 18; @@ -247,6 +291,7 @@ public class DraftPanel extends javax.swing.JPanel { } public void loadBooster(DraftPickView draftPickView) { + logLastPick(draftPickView); // upper area that shows the picks loadCardsToPickedCardsArea(draftPickView.getPicks()); @@ -413,6 +458,94 @@ public class DraftPanel extends javax.swing.JPanel { draftPicks.loadCards(CardsViewUtil.convertSimple(pickedCardsShown), bigCard, null); } + // Log the last card picked into the draft log together with booster + // contents. + // We don't get any event when the card is selected due to timeout + // that's why instead of proactively logging our pick we instead + // log *last* pick from the list of picks. + // To make this possible we cache the list of cards from the + // previous booster and it's sequence number (pack number / pick number) + // in fields currentBooster and currentBoosterHeader. + private void logLastPick(DraftPickView pickView) { + if (!isLogging()) { + return; + } + if (currentBooster != null) { + String lastPick = getCardName(getLastPick(pickView.getPicks().values())); + if (lastPick != null) { + logPick(lastPick); + } + currentBooster = null; + } + setCurrentBoosterForLog(pickView.getBooster()); + if (currentBooster.length == 1) { + logPick(currentBooster[0]); + } + } + + private static boolean isLogging() { + String autoSave = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_DRAFT_LOG_AUTO_SAVE, "true"); + return autoSave.equals("true"); + } + + private void setCurrentBoosterForLog(SimpleCardsView booster) { + LinkedList cards = new LinkedList<>(); + for (SimpleCardView simple: booster.values()) { + String cardName = getCardName(simple); + if (cardName != null) { + cards.add(cardName); + } + } + + currentBoosterHeader = "Pack " + packNo + " pick " + pickNo + ":\n"; + currentBooster = cards.toArray(new String[cards.size()]); + } + + private void logPick(String pick) { + StringBuilder b = new StringBuilder(); + b.append(currentBoosterHeader); + for (String name : currentBooster) { + b.append(pick.equals(name) ? "--> " : " "); + b.append(name); + b.append('\n'); + } + b.append('\n'); + appendToDraftLog(b.toString()); + } + + private Path pathToDraftLog() { + File saveDir = new File("gamelogs"); + if(!saveDir.exists()) { + saveDir.mkdirs(); + } + return new File(saveDir, logFilename).toPath(); + } + + private void appendToDraftLog(String data) { + try { + Files.write(pathToDraftLog(), data.getBytes(), StandardOpenOption.APPEND); + } catch (IOException ex) { + Logger.getLogger(DraftPanel.class.getName()).log(Level.SEVERE, null, ex); + } + } + + private static SimpleCardView getLastPick(Collection picks) { + SimpleCardView last = null; + for (SimpleCardView pick : picks) { + last = pick; + } + return last; + } + + private static String getCardName(SimpleCardView card) { + if (card == null) { + return null; + } + CardInfo cardInfo = CardRepository.instance.findCard(card.getExpansionSetCode(), card.getCardNumber()); + return cardInfo != null ? cardInfo.getName() : null; + } + + /** This method is called from within the constructor to * initialize the form. * WARNING: Do NOT modify this code. The content of this method is diff --git a/Mage.Client/src/main/java/mage/client/game/PlayAreaPanel.java b/Mage.Client/src/main/java/mage/client/game/PlayAreaPanel.java index a80b860fe3d..c9b61253f17 100644 --- a/Mage.Client/src/main/java/mage/client/game/PlayAreaPanel.java +++ b/Mage.Client/src/main/java/mage/client/game/PlayAreaPanel.java @@ -333,7 +333,7 @@ public class PlayAreaPanel extends javax.swing.JPanel { } }; - JMenu rollbackMainItem = new JMenu("Roll back"); + JMenu rollbackMainItem = new JMenu("Rollback"); rollbackMainItem.setMnemonic(KeyEvent.VK_R); rollbackMainItem.setToolTipText("The game will be rolled back to the start of the requested turn if all players agree."); popupMenu.add(rollbackMainItem); diff --git a/Mage.Client/src/main/java/mage/client/game/PlayAreaPanelOptions.java b/Mage.Client/src/main/java/mage/client/game/PlayAreaPanelOptions.java index 377b7591c4b..fb6cfe194aa 100644 --- a/Mage.Client/src/main/java/mage/client/game/PlayAreaPanelOptions.java +++ b/Mage.Client/src/main/java/mage/client/game/PlayAreaPanelOptions.java @@ -1,30 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.client.game; /** @@ -39,20 +39,21 @@ public class PlayAreaPanelOptions { this.playerItself = playerItself; this.rollbackTurnsAllowed = rollbackTurnsAllowed; } - + /** - * true if the client is a player / false if the client is a watcher + * true if the client is a player / false if the client is a watcher */ public boolean isPlayer = false; /** - * true if the player is the client player itself, false if the player is another player playing with the clinet player + * true if the player is the client player itself, false if the player is + * another player playing with the clinet player */ public boolean playerItself = false; /** - * true if the player can roll back turns if all players agree + * true if the player can rollback turns if all players agree */ public boolean rollbackTurnsAllowed = false; - + } diff --git a/Mage.Client/src/main/java/mage/client/game/PlayerPanelExt.java b/Mage.Client/src/main/java/mage/client/game/PlayerPanelExt.java index 83014a6db90..7aee90e37ce 100644 --- a/Mage.Client/src/main/java/mage/client/game/PlayerPanelExt.java +++ b/Mage.Client/src/main/java/mage/client/game/PlayerPanelExt.java @@ -36,7 +36,6 @@ package mage.client.game; import java.awt.Color; import java.awt.Dimension; import java.awt.Font; -import java.awt.GridLayout; import java.awt.Image; import java.awt.Rectangle; import java.awt.event.ActionEvent; @@ -120,7 +119,7 @@ public class PlayerPanelExt extends javax.swing.JPanel { private static final Border emptyBorder = BorderFactory.createEmptyBorder(0, 0, 0, 0); private int avatarId = -1; - private String flagName = ""; + private String flagName; private PriorityTimer timer; @@ -139,7 +138,7 @@ public class PlayerPanelExt extends javax.swing.JPanel { client = MageFrame.getClient(); cheat.setVisible(client.getServerState().isTestMode()); cheat.setFocusable(false); - + flagName = null; if (priorityTime > 0) { long delay = 1000L; @@ -172,6 +171,25 @@ public class PlayerPanelExt extends javax.swing.JPanel { public void update(PlayerView player) { this.player = player; + if (flagName == null) { // do only once + avatar.setText(this.player.getName()); + if (!player.getUserData().getFlagName().equals(flagName)) { + flagName = player.getUserData().getFlagName(); + this.avatar.setTopTextImage(CountryUtil.getCountryFlagIcon(flagName).getImage()); + } + // TODO: Add the wins to the tooltiptext of the avatar + String countryname = CountryUtil.getCountryName(flagName); + if (countryname == null) { + countryname = "Unknown"; + } + String tooltip = "Name: " + player.getName() + "
Country: " + countryname; + avatar.setToolTipText(tooltip); + avatar.repaint(); + + // used if avatar image can't be used + this.btnPlayer.setText(player.getName()); + this.btnPlayer.setToolTipText(tooltip); + } int playerLife = player.getLife(); if (playerLife > 99) { Font font = lifeLabel.getFont(); @@ -250,15 +268,9 @@ public class PlayerPanelExt extends javax.swing.JPanel { Image image = ImageHelper.getImageFromResources(path); Rectangle r = new Rectangle(80, 80); BufferedImage resized = ImageHelper.getResizedImage(BufferedImageBuilder.bufferImage(image, BufferedImage.TYPE_INT_ARGB), r); - this.avatar.update("player", resized, resized, resized, resized, r); - } - if (!player.getUserData().getFlagName().equals(flagName)) { - flagName = player.getUserData().getFlagName(); - this.avatarFlag.setIcon(CountryUtil.getCountryFlagIcon(flagName)); - avatar.repaint(); + this.avatar.update(this.player.getName(), resized, resized, resized, resized, r); } } - this.avatar.setText(player.getName()); if (this.timer != null) { if (player.getPriorityTimeLeft() != Integer.MAX_VALUE) { String priorityTimeValue = getPriorityTimeLeftString(player); @@ -273,8 +285,6 @@ public class PlayerPanelExt extends javax.swing.JPanel { } } - this.btnPlayer.setText(player.getName()); - this.btnPlayer.setToolTipText("Life: " + player.getLife()); if (player.isActive()) { this.avatar.setBorder(greenBorder); this.btnPlayer.setBorder(greenBorder); @@ -338,15 +348,8 @@ public class PlayerPanelExt extends javax.swing.JPanel { Image image = ImageHelper.getImageFromResources(DEFAULT_AVATAR_PATH); BufferedImage resized = ImageHelper.getResizedImage(BufferedImageBuilder.bufferImage(image, BufferedImage.TYPE_INT_ARGB), r); - avatar = new HoverButton("player", resized, resized, resized, r); - avatar.setLayout(new GridLayout(4, 1, 0, 0)); - avatar.add(new JLabel()); - avatar.add(new JLabel()); - avatar.add(avatarFlag); - avatar.setAlignTextLeft(true); - avatarFlag.setHorizontalAlignment(JLabel.LEFT); - avatarFlag.setVerticalAlignment(JLabel.BOTTOM); - avatar.add(new JLabel()); + avatar = new HoverButton("", resized, resized, resized, r); + String showPlayerNamePermanently = MageFrame.getPreferences().get(PreferencesDialog.KEY_SHOW_PLAYER_NAMES_PERMANENTLY, "true"); if (showPlayerNamePermanently.equals("true")) { avatar.setTextAlwaysVisible(true); diff --git a/Mage.Client/src/main/java/mage/client/plugins/adapters/MageActionCallback.java b/Mage.Client/src/main/java/mage/client/plugins/adapters/MageActionCallback.java index 716c7a83008..151d3adc86c 100644 --- a/Mage.Client/src/main/java/mage/client/plugins/adapters/MageActionCallback.java +++ b/Mage.Client/src/main/java/mage/client/plugins/adapters/MageActionCallback.java @@ -1,5 +1,28 @@ package mage.client.plugins.adapters; +import java.awt.Component; +import java.awt.Image; +import java.awt.Point; +import java.awt.event.MouseEvent; +import java.awt.event.MouseWheelEvent; +import java.awt.image.BufferedImage; +import java.util.ArrayList; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashSet; +import java.util.List; +import java.util.Set; +import java.util.UUID; +import java.util.concurrent.Executors; +import java.util.concurrent.ScheduledExecutorService; +import java.util.concurrent.ScheduledFuture; +import java.util.concurrent.TimeUnit; +import javax.swing.JComponent; +import javax.swing.JPanel; +import javax.swing.JPopupMenu; +import javax.swing.Popup; +import javax.swing.PopupFactory; +import javax.swing.SwingUtilities; import mage.cards.MageCard; import mage.cards.action.ActionCallback; import mage.cards.action.TransferData; @@ -38,8 +61,9 @@ import java.util.concurrent.TimeUnit; import org.mage.network.Client; /** - * Class that handles the callbacks from the card panels to mage to display big card - * images from the cards the mouse hovers on. Also handles tooltip text window. + * Class that handles the callbacks from the card panels to mage to display big + * card images from the cards the mouse hovers on. Also handles tooltip text + * window. * * @author Nantuko, noxx */ @@ -63,7 +87,9 @@ public class MageActionCallback implements ActionCallback { private TransferData popupData; private JComponent cardInfoPane; private volatile boolean popupTextWindowOpen = false; + enum EnlargedWindowState { + CLOSED, NORMAL, ROTATED } private volatile EnlargedWindowState enlargedWindowState = EnlargedWindowState.CLOSED; @@ -181,15 +207,15 @@ public class MageActionCallback implements ActionCallback { final Component c = MageFrame.getUI().getComponent(MageComponents.DESKTOP_PANE); SwingUtilities.invokeLater(new Runnable() { - @Override - public void run() { - if (!popupTextWindowOpen || !enlargedWindowState.equals(EnlargedWindowState.CLOSED)) { - return; - } - popupContainer.setVisible(true); - c.repaint(); - } - } + @Override + public void run() { + if (!popupTextWindowOpen || !enlargedWindowState.equals(EnlargedWindowState.CLOSED)) { + return; + } + popupContainer.setVisible(true); + c.repaint(); + } + } ); } catch (InterruptedException e) { @@ -213,7 +239,7 @@ public class MageActionCallback implements ActionCallback { cardPanels.clear(); Point mouse = new Point(e.getX(), e.getY()); SwingUtilities.convertPointToScreen(mouse, data.component); - initialMousePos = new Point((int)mouse.getX(), (int)mouse.getY()); + initialMousePos = new Point((int) mouse.getX(), (int) mouse.getY()); initialCardPos = data.component.getLocation(); // Closes popup & enlarged view if a card/Permanent is selected hidePopup(); @@ -221,7 +247,7 @@ public class MageActionCallback implements ActionCallback { @Override public void mouseReleased(MouseEvent e, TransferData transferData) { - CardPanel card = ((CardPanel)transferData.component); + CardPanel card = ((CardPanel) transferData.component); if (card.getZone() != null && card.getZone().equalsIgnoreCase("hand")) { int maxXOffset = 0; if (isDragging) { @@ -270,7 +296,7 @@ public class MageActionCallback implements ActionCallback { @Override public void mouseDragged(MouseEvent e, TransferData transferData) { - CardPanel card = ((CardPanel)transferData.component); + CardPanel card = ((CardPanel) transferData.component); if (card.getZone() == null || !card.getZone().equalsIgnoreCase("hand")) { // drag'n'drop is allowed for HAND zone only return; @@ -281,7 +307,7 @@ public class MageActionCallback implements ActionCallback { Point mouse = new Point(e.getX(), e.getY()); SwingUtilities.convertPointToScreen(mouse, transferData.component); int xOffset = card.getXOffset(card.getCardWidth()); - int newX = Math.max(initialCardPos.x + (int)(mouse.getX() - initialMousePos.x) - xOffset, 0); + int newX = Math.max(initialCardPos.x + (int) (mouse.getX() - initialMousePos.x) - xOffset, 0); card.setCardBounds( newX, p.y, @@ -313,13 +339,13 @@ public class MageActionCallback implements ActionCallback { if (!cardPanels.contains(component)) { component.setLocation(component.getLocation().x, component.getLocation().y + GO_DOWN_ON_DRAG_Y_OFFSET); } - cardPanels.add((CardPanel)component); + cardPanels.add((CardPanel) component); } else { if (!startedDragging) { component.setLocation(component.getLocation().x, component.getLocation().y - GO_UP_ON_DRAG_Y_OFFSET); } } - cards.add((CardPanel)component); + cards.add((CardPanel) component); } } sortLayout(cards, card, sortSource); @@ -459,7 +485,8 @@ public class MageActionCallback implements ActionCallback { /** * Show the big card image on mouse position while hovering over a card * - * @param showAlternative defines if the original image (if it's a copied card) or the opposite side of a transformable card will be shown + * @param showAlternative defines if the original image (if it's a copied + * card) or the opposite side of a transformable card will be shown */ public void enlargeCard(EnlargeMode showAlternative) { if (enlargedWindowState.equals(EnlargedWindowState.CLOSED)) { @@ -484,7 +511,7 @@ public class MageActionCallback implements ActionCallback { public void hideEnlargedCard() { if (!enlargedWindowState.equals(EnlargedWindowState.CLOSED)) { - enlargedWindowState = EnlargedWindowState.CLOSED; + enlargedWindowState = EnlargedWindowState.CLOSED; try { Component cardPreviewContainer = MageFrame.getUI().getComponent(MageComponents.CARD_PREVIEW_CONTAINER); cardPreviewContainer.setVisible(false); @@ -497,8 +524,6 @@ public class MageActionCallback implements ActionCallback { } } - - private void displayEnlargedCard(final CardView cardView, final TransferData transferData) { ThreadUtils.threadPool2.submit(new Runnable() { @Override @@ -510,20 +535,18 @@ public class MageActionCallback implements ActionCallback { if (enlargedWindowState.equals(EnlargedWindowState.CLOSED)) { return; } - Component parentComponent = SwingUtilities.getRoot(transferData.component); - Point parentPoint = parentComponent.getLocationOnScreen(); MageComponents mageComponentCardPreviewContainer; MageComponents mageComponentCardPreviewPane; if (cardView.isToRotate()) { - if(enlargedWindowState.equals(EnlargedWindowState.NORMAL)) { + if (enlargedWindowState.equals(EnlargedWindowState.NORMAL)) { hideEnlargedCard(); enlargedWindowState = EnlargedWindowState.ROTATED; } mageComponentCardPreviewContainer = MageComponents.CARD_PREVIEW_CONTAINER_ROTATED; mageComponentCardPreviewPane = MageComponents.CARD_PREVIEW_PANE_ROTATED; } else { - if(enlargedWindowState.equals(EnlargedWindowState.ROTATED)) { + if (enlargedWindowState.equals(EnlargedWindowState.ROTATED)) { hideEnlargedCard(); enlargedWindowState = EnlargedWindowState.NORMAL; } @@ -532,7 +555,9 @@ public class MageActionCallback implements ActionCallback { } final Component popupContainer = MageFrame.getUI().getComponent(mageComponentCardPreviewContainer); Component cardPreviewPane = MageFrame.getUI().getComponent(mageComponentCardPreviewPane); - if (cardPreviewPane != null) { + Component parentComponent = SwingUtilities.getRoot(transferData.component); + if (cardPreviewPane != null && parentComponent != null) { + Point parentPoint = parentComponent.getLocationOnScreen(); transferData.locationOnScreen = transferData.component.getLocationOnScreen(); Point location = new Point((int) transferData.locationOnScreen.getX() + transferData.popupOffsetX - 40, (int) transferData.locationOnScreen.getY() + transferData.popupOffsetY - 40); location = GuiDisplayUtil.keepComponentInsideParent(location, parentPoint, cardPreviewPane, parentComponent); @@ -562,10 +587,9 @@ public class MageActionCallback implements ActionCallback { image = mageCard.getImage(); } // shows the card in the popup Container - BigCard bigCard = (BigCard)cardPreviewPane; + BigCard bigCard = (BigCard) cardPreviewPane; displayCardInfo(mageCard, image, bigCard); - } else { logger.warn("No Card preview Pane in Mage Frame defined. Card: " + cardView.getName()); } @@ -586,7 +610,7 @@ public class MageActionCallback implements ActionCallback { } else { image = ImageHelper.getResizedImage((BufferedImage) image, bigCard.getWidth()); } - bigCard.setCard(mageCard.getOriginal().getId(), enlargeMode, image, mageCard.getOriginal().getRules()); + bigCard.setCard(mageCard.getOriginal().getId(), enlargeMode, image, mageCard.getOriginal().getRules()); // if it's an ability, show only the ability text as overlay if (mageCard.getOriginal().isAbility() && enlargeMode.equals(EnlargeMode.NORMAL)) { bigCard.showTextComponent(); diff --git a/Mage.Client/src/main/java/mage/client/table/TablesPanel.java b/Mage.Client/src/main/java/mage/client/table/TablesPanel.java index 8419b85cfba..e0ccd97a663 100644 --- a/Mage.Client/src/main/java/mage/client/table/TablesPanel.java +++ b/Mage.Client/src/main/java/mage/client/table/TablesPanel.java @@ -1,37 +1,36 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ /* * TablesPanel.java * * Created on 15-Dec-2009, 10:54:01 PM */ - package mage.client.table; import java.awt.Color; @@ -119,14 +118,16 @@ public class TablesPanel extends javax.swing.JPanel { private List messages; private int currentMessage; private MageTableRowSorter activeTablesSorter; - + JToggleButton[] filterButtons; - + private static final int[] defaultColumnsWidth = {35, 150, 120, 180, 80, 120, 80, 60, 60}; - - /** Creates new form TablesPanel */ + + /** + * Creates new form TablesPanel + */ public TablesPanel() { - + tableModel = new TableTableModel(); matchesModel = new MatchesTableModel(); gameChooser = new GameChooser(); @@ -135,49 +136,46 @@ public class TablesPanel extends javax.swing.JPanel { tableModel.setClient(client); tableTables.createDefaultColumnsFromModel(); - + activeTablesSorter = new MageTableRowSorter(tableModel); tableTables.setRowSorter(activeTablesSorter); - - TableUtil.setColumnWidthAndOrder(tableTables, defaultColumnsWidth, + + TableUtil.setColumnWidthAndOrder(tableTables, defaultColumnsWidth, PreferencesDialog.KEY_TABLES_COLUMNS_WIDTH, PreferencesDialog.KEY_TABLES_COLUMNS_ORDER); - + tableCompleted.setRowSorter(new MageTableRowSorter(matchesModel)); chatPanel.useExtendedView(ChatPanel.VIEW_MODE.NONE); chatPanel.setBorder(null); chatPanel.setChatType(ChatPanel.ChatType.TABLES); - filterButtons = new JToggleButton[] - {btnStateWaiting, btnStateActive, btnStateFinished, - btnTypeMatch, btnTypeTourneyConstructed, btnTypeTourneyLimited, - btnFormatBlock, btnFormatStandard, btnFormatModern, btnFormatLegacy, btnFormatVintage, btnFormatCommander, btnFormatTinyLeader, btnFormatLimited, btnFormatOther, - btnSkillBeginner, btnSkillCasual, btnSkillSerious }; - - JComponent[] components = new JComponent[] {chatPanel, jSplitPane1, jScrollPane1, jScrollPane2, topPanel, jPanel3}; + filterButtons = new JToggleButton[]{btnStateWaiting, btnStateActive, btnStateFinished, + btnTypeMatch, btnTypeTourneyConstructed, btnTypeTourneyLimited, + btnFormatBlock, btnFormatStandard, btnFormatModern, btnFormatLegacy, btnFormatVintage, btnFormatCommander, btnFormatTinyLeader, btnFormatLimited, btnFormatOther, + btnSkillBeginner, btnSkillCasual, btnSkillSerious}; + + JComponent[] components = new JComponent[]{chatPanel, jSplitPane1, jScrollPane1, jScrollPane2, topPanel, jPanel3}; for (JComponent component : components) { component.setOpaque(false); } - jScrollPane1.getViewport().setBackground(new Color(255,255,255,50)); - jScrollPane2.getViewport().setBackground(new Color(255,255,255,50)); - + jScrollPane1.getViewport().setBackground(new Color(255, 255, 255, 50)); + jScrollPane2.getViewport().setBackground(new Color(255, 255, 255, 50)); + restoreSettings(); - + Action openTableAction; - openTableAction = new AbstractAction() - { + openTableAction = new AbstractAction() { @Override - public void actionPerformed(ActionEvent e) - { - int modelRow = Integer.valueOf( e.getActionCommand() ); - UUID tableId = (UUID)tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 3); - UUID gameId = (UUID)tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 2); - String action = (String)tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN); - String deckType = (String)tableModel.getValueAt(modelRow, TableTableModel.COLUMN_DECK_TYPE); - String status = (String)tableModel.getValueAt(modelRow, TableTableModel.COLUMN_STATUS); - boolean isTournament = (Boolean)tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 1); - String owner = (String)tableModel.getValueAt(modelRow, TableTableModel.COLUMN_OWNER); + public void actionPerformed(ActionEvent e) { + int modelRow = Integer.valueOf(e.getActionCommand()); + UUID tableId = (UUID) tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 3); + UUID gameId = (UUID) tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 2); + String action = (String) tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN); + String deckType = (String) tableModel.getValueAt(modelRow, TableTableModel.COLUMN_DECK_TYPE); + String status = (String) tableModel.getValueAt(modelRow, TableTableModel.COLUMN_STATUS); + boolean isTournament = (Boolean) tableModel.getValueAt(modelRow, TableTableModel.ACTION_COLUMN + 1); + String owner = (String) tableModel.getValueAt(modelRow, TableTableModel.COLUMN_OWNER); switch (action) { case "Join": if (owner.equals(client.getUserName())) { @@ -215,49 +213,46 @@ public class TablesPanel extends javax.swing.JPanel { } else { logger.info("Joining table " + tableId); joinTableDialog.showDialog(roomId, tableId, false, false); - } + } break; case "Remove": if (JOptionPane.showConfirmDialog(null, "Are you sure you want to remove table?", "Removing table", JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION) { client.removeTable(roomId, tableId); - } + } break; case "Show": if (isTournament) { logger.info("Showing tournament table " + tableId); client.watchTable(roomId, tableId); - } + } break; case "Watch": if (!isTournament) { logger.info("Watching table " + tableId); client.watchTable(roomId, tableId); - } + } break; case "Replay": logger.info("Replaying game " + gameId); client.replayGame(gameId); break; } - } - }; + } + }; - Action closedTableAction; - closedTableAction = new AbstractAction() - { + Action closedTableAction; + closedTableAction = new AbstractAction() { @Override - public void actionPerformed(ActionEvent e) - { - int modelRow = Integer.valueOf( e.getActionCommand() ); - String action = (String)matchesModel.getValueAt(modelRow, MatchesTableModel.ACTION_COLUMN); + public void actionPerformed(ActionEvent e) { + int modelRow = Integer.valueOf(e.getActionCommand()); + String action = (String) matchesModel.getValueAt(modelRow, MatchesTableModel.ACTION_COLUMN); switch (action) { - case "Replay": - List gameList = matchesModel.getListofGames(modelRow); + case "Replay": + List gameList = matchesModel.getListofGames(modelRow); if (gameList != null && gameList.size() > 0) { if (gameList.size() == 1) { client.replayGame(gameList.get(0)); - } - else { + } else { gameChooser.show(gameList, MageFrame.getDesktop().getMousePosition()); } } @@ -267,18 +262,18 @@ public class TablesPanel extends javax.swing.JPanel { if (matchesModel.isTournament(modelRow)) { logger.info("Showing tournament table " + matchesModel.getTableId(modelRow)); client.watchTable(roomId, matchesModel.getTableId(modelRow)); - } + } break; } } }; - + // !!!! adds action buttons to the table panel (don't delete this) new ButtonColumn(tableTables, openTableAction, tableTables.convertColumnIndexToView(TableTableModel.ACTION_COLUMN)); new ButtonColumn(tableCompleted, closedTableAction, tableCompleted.convertColumnIndexToView(MatchesTableModel.ACTION_COLUMN)); // !!!! } - + public void cleanUp() { saveSettings(); chatPanel.cleanUp(); @@ -293,30 +288,30 @@ public class TablesPanel extends javax.swing.JPanel { PreferencesDialog.saveValue(PreferencesDialog.KEY_TABLES_DIVIDER_LOCATION_2, Integer.toString(this.jSplitPane2.getDividerLocation())); PreferencesDialog.saveValue(PreferencesDialog.KEY_TABLES_DIVIDER_LOCATION_3, Integer.toString(chatPanel.getSplitDividerLocation())); } - + private void restoreSettings() { // filter settings String formatSettings = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_TABLES_FILTER_SETTINGS, ""); int i = 0; for (JToggleButton component : filterButtons) { if (formatSettings.length() > i) { - component.setSelected(formatSettings.substring(i,i+1).equals("x")); + component.setSelected(formatSettings.substring(i, i + 1).equals("x")); } else { component.setSelected(true); } i++; - } + } setTableFilter(); } - + private void saveSettings() { // Filters StringBuilder formatSettings = new StringBuilder(); for (JToggleButton component : filterButtons) { - formatSettings.append(component.isSelected() ? "x":"-"); + formatSettings.append(component.isSelected() ? "x" : "-"); } PreferencesDialog.saveValue(PreferencesDialog.KEY_TABLES_FILTER_SETTINGS, formatSettings.toString()); - + TableUtil.saveColumnWidthAndOrderToPrefs(tableTables, KEY_TABLES_COLUMNS_WIDTH, KEY_TABLES_COLUMNS_ORDER); } @@ -333,13 +328,12 @@ public class TablesPanel extends javax.swing.JPanel { } if (this.btnStateFinished.isSelected()) { this.jSplitPane2.setDividerLocation(-1); - } - else { + } else { location = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_TABLES_DIVIDER_LOCATION_2, null); if (location != null && jSplitPane2 != null) { jSplitPane2.setDividerLocation(Integer.parseInt(location)); } - } + } location = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_TABLES_DIVIDER_LOCATION_3, null); if (location != null && chatPanel != null) { chatPanel.setSplitDividerLocation(Integer.parseInt(location)); @@ -347,7 +341,7 @@ public class TablesPanel extends javax.swing.JPanel { } } } - + public Map getUIComponents() { Map components = new HashMap<>(); @@ -447,15 +441,15 @@ public class TablesPanel extends javax.swing.JPanel { reloadMessages(); MageFrame.getUI().addButton(MageComponents.NEW_GAME_BUTTON, btnNewTable); - + // divider locations have to be set with delay else values set are overwritten with system defaults Executors.newSingleThreadScheduledExecutor().schedule(new Runnable() { @Override public void run() { restoreDividerLocations(); } - }, 300, TimeUnit.MILLISECONDS); - + }, 300, TimeUnit.MILLISECONDS); + } protected void reloadMessages() { @@ -478,7 +472,7 @@ public class TablesPanel extends javax.swing.JPanel { this.saveDividerLocations(); for (Component component : MageFrame.getDesktop().getComponents()) { if (component instanceof TableWaitingDialog) { - ((TableWaitingDialog)component).closeDialog(); + ((TableWaitingDialog) component).closeDialog(); } } stopTasks(); @@ -489,7 +483,7 @@ public class TablesPanel extends javax.swing.JPanel { c = c.getParent(); } if (c != null) { - ((TablesPane)c).hideFrame(); + ((TablesPane) c).hideFrame(); } } @@ -522,31 +516,31 @@ public class TablesPanel extends javax.swing.JPanel { // format List> formatFilterList = new ArrayList<>(); if (btnFormatBlock.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Block", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Constructed.*Block", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatStandard.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Standard", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Constructed - Standard", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatModern.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Modern", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Constructed - Modern", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatLegacy.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Legacy", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Constructed - Legacy", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatVintage.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Vintage", TableTableModel.COLUMN_DECK_TYPE)); - } + formatFilterList.add(RowFilter.regexFilter("^Constructed - Vintage", TableTableModel.COLUMN_DECK_TYPE)); + } if (btnFormatCommander.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Commander", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Commander|^Duel Commander", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatTinyLeader.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Tiny", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Tiny", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatLimited.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Limited", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Limited", TableTableModel.COLUMN_DECK_TYPE)); } if (btnFormatOther.isSelected()) { - formatFilterList.add(RowFilter.regexFilter("Pauper|Extended", TableTableModel.COLUMN_DECK_TYPE)); + formatFilterList.add(RowFilter.regexFilter("^Constructed - Pauper|^Constructed - Extended|^Constructed - Historical|^Constructed - Super", TableTableModel.COLUMN_DECK_TYPE)); } List> skillFilterList = new ArrayList<>(); @@ -559,7 +553,7 @@ public class TablesPanel extends javax.swing.JPanel { if (btnSkillSerious.isSelected()) { skillFilterList.add(RowFilter.regexFilter(SkillLevel.SERIOUS.toString(), TableTableModel.COLUMN_SKILL)); } - + if (stateFilterList.isEmpty() || typeFilterList.isEmpty() || formatFilterList.isEmpty() || skillFilterList.isEmpty()) { // no selection activeTablesSorter.setRowFilter(RowFilter.regexFilter("Nothing", TableTableModel.COLUMN_SKILL)); } else { @@ -570,7 +564,7 @@ public class TablesPanel extends javax.swing.JPanel { } else if (stateFilterList.size() == 1) { filterList.addAll(stateFilterList); } - + if (typeFilterList.size() > 1) { filterList.add(RowFilter.orFilter(typeFilterList)); } else if (typeFilterList.size() == 1) { @@ -588,7 +582,7 @@ public class TablesPanel extends javax.swing.JPanel { } else if (skillFilterList.size() == 1) { filterList.addAll(skillFilterList); } - + if (filterList.size() == 1) { activeTablesSorter.setRowFilter(filterList.get(0)); } else { @@ -596,11 +590,11 @@ public class TablesPanel extends javax.swing.JPanel { } } } - - /** This method is called from within the constructor to - * initialize the form. - * WARNING: Do NOT modify this code. The content of this method is - * always regenerated by the Form Editor. + + /** + * This method is called from within the constructor to initialize the form. + * WARNING: Do NOT modify this code. The content of this method is always + * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // //GEN-BEGIN:initComponents @@ -1126,17 +1120,17 @@ public class TablesPanel extends javax.swing.JPanel { }// //GEN-END:initComponents private void btnNewTournamentActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnNewTournamentActionPerformed - newTournamentDialog.showDialog(roomId); + newTournamentDialog.showDialog(roomId); }//GEN-LAST:event_btnNewTournamentActionPerformed private void btnQuickStartActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnQuickStartActionPerformed - TableView table; - try { - File f = new File("test.dck"); - if (!f.exists()) { - JOptionPane.showMessageDialog(null, "Couldn't find test.dck file for quick game start", "Error", JOptionPane.ERROR_MESSAGE); - return; - } + TableView table; + try { + File f = new File("test.dck"); + if (!f.exists()) { + JOptionPane.showMessageDialog(null, "Couldn't find test.dck file for quick game start", "Error", JOptionPane.ERROR_MESSAGE); + return; + } MatchOptions options = new MatchOptions("1", "Two Player Duel"); options.getPlayerTypes().add("Human"); @@ -1182,8 +1176,7 @@ public class TablesPanel extends javax.swing.JPanel { private void btnStateFinishedActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_btnStateFinishedActionPerformed if (this.btnStateFinished.isSelected()) { this.jSplitPane2.setDividerLocation(-1); - } - else { + } else { this.jSplitPane2.setDividerLocation(this.jPanel3.getHeight()); } this.startTasks(); @@ -1194,7 +1187,6 @@ public class TablesPanel extends javax.swing.JPanel { JOptionPane.showMessageDialog(MageFrame.getDesktop(), "Error loading deck.", "Error", JOptionPane.ERROR_MESSAGE); } - // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JToggleButton btnFormatBlock; private javax.swing.JToggleButton btnFormatCommander; @@ -1237,14 +1229,15 @@ public class TablesPanel extends javax.swing.JPanel { private javax.swing.JTable tableTables; private javax.swing.JPanel topPanel; // End of variables declaration//GEN-END:variables - + } class TableTableModel extends AbstractTableModel { + ImageIcon tourneyIcon = new javax.swing.ImageIcon(getClass().getResource("/tables/tourney_icon.png")); ImageIcon matchIcon = new javax.swing.ImageIcon(getClass().getResource("/tables/match_icon.png")); - - public static final int COLUMN_ICON = 0; + + public static final int COLUMN_ICON = 0; public static final int COLUMN_DECK_TYPE = 1; // column the deck type is located (starting with 0) Start string is used to check for Limited public static final int COLUMN_OWNER = 2; public static final int COLUMN_GAME_TYPE = 3; @@ -1253,18 +1246,19 @@ class TableTableModel extends AbstractTableModel { public static final int COLUMN_SKILL = 7; public static final int ACTION_COLUMN = 8; // column the action is located (starting with 0) - private final String[] columnNames = new String[]{"M/T","Deck Type", "Owner / Players", "Game Type", "Info", "Status", "Created / Started", "Skill Level", "Action"}; - + private final String[] columnNames = new String[]{"M/T", "Deck Type", "Owner / Players", "Game Type", "Info", "Status", "Created / Started", "Skill Level", "Action"}; + private TableView[] tables = new TableView[0]; - private static final DateFormat timeFormatter = new SimpleDateFormat("HH:mm:ss");; + private static final DateFormat timeFormatter = new SimpleDateFormat("HH:mm:ss"); + ; private Client client; - + public void loadData(Collection tables) throws MageRemoteException { this.tables = tables.toArray(new TableView[0]); this.fireTableDataChanged(); - } - + } + @Override public int getRowCount() { return tables.length; @@ -1283,7 +1277,7 @@ class TableTableModel extends AbstractTableModel { public Object getValueAt(int arg0, int arg1) { switch (arg1) { case 0: - return tables[arg0].isTournament() ? tourneyIcon:matchIcon; + return tables[arg0].isTournament() ? tourneyIcon : matchIcon; case 1: return tables[arg0].getDeckType(); case 2: @@ -1318,10 +1312,10 @@ class TableTableModel extends AbstractTableModel { } else { owner = tables[arg0].getControllerName(); if (client != null && owner.equals(client.getUserName())) { - return ""; + return ""; } return "Watch"; - } + } default: return ""; } @@ -1350,7 +1344,7 @@ class TableTableModel extends AbstractTableModel { } @Override - public Class getColumnClass(int columnIndex){ + public Class getColumnClass(int columnIndex) { switch (columnIndex) { case COLUMN_ICON: return Icon.class; @@ -1416,7 +1410,8 @@ class UpdateRoomTask extends SwingWorker { get(); } catch (InterruptedException | ExecutionException ex) { logger.fatal("Update Tables Task error", ex); - } catch (CancellationException ex) {} + } catch (CancellationException ex) { + } } } @@ -1464,7 +1459,7 @@ class MatchesTableModel extends AbstractTableModel { public static final int ACTION_COLUMN = 6; // column the action is located (starting with 0) public static final int GAMES_LIST_COLUMN = 7; - private final String[] columnNames = new String[]{"Deck Type", "Players", "Game Type", "Result", "Start Time", "End Time","Action"}; + private final String[] columnNames = new String[]{"Deck Type", "Players", "Game Type", "Result", "Start Time", "End Time", "Action"}; private MatchView[] matches = new MatchView[0]; private static final DateFormat timeFormatter = SimpleDateFormat.getDateTimeInstance(DateFormat.SHORT, DateFormat.SHORT); @@ -1515,30 +1510,29 @@ class MatchesTableModel extends AbstractTableModel { } else { return "None"; } - } + } case 7: return matches[arg0].getGames(); } return ""; } - - public List getListofGames (int row) { - return matches[row].getGames(); + + public List getListofGames(int row) { + return matches[row].getGames(); } - + public boolean isTournament(int row) { - return matches[row].isTournament(); + return matches[row].isTournament(); } public UUID getMatchId(int row) { - return matches[row].getMatchId(); + return matches[row].getMatchId(); } - + public UUID getTableId(int row) { - return matches[row].getTableId(); + return matches[row].getTableId(); } - - + @Override public String getColumnName(int columnIndex) { String colName = ""; @@ -1551,7 +1545,7 @@ class MatchesTableModel extends AbstractTableModel { } @Override - public Class getColumnClass(int columnIndex){ + public Class getColumnClass(int columnIndex) { return String.class; } @@ -1617,7 +1611,7 @@ class GameChooser extends JPopupMenu { return; } this.removeAll(); - for (UUID gameId: games) { + for (UUID gameId : games) { this.add(new GameChooserAction(gameId, gameId.toString())); } this.show(MageFrame.getDesktop(), p.x, p.y); diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java index 4723b78aa69..4ad6037eccd 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/GathererSets.java @@ -48,7 +48,8 @@ public class GathererSets implements Iterable { "MMA", "MM2", "THS", "BNG", "JOU", "CNS", "VMA", "TPR", - "KTK", "FRF", "DTK"}; + "KTK", "FRF", "DTK", + "BFZ"}; private static final HashMap symbolsReplacements = new HashMap<>(); static { diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java index c5f817eb14d..bec0386a467 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/MagicCardsImageSource.java @@ -16,6 +16,7 @@ public class MagicCardsImageSource implements CardImageSource { private static final Map setNameTokenReplacement = new HashMap() { { + put("BFZ", "battle-for-zendikar"); put("FVL", "from-the-vault-legends"); put("FVD", "from-the-vault-dragons"); put("FVE", "from-the-vault-exiled"); diff --git a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java index 40d6f90b1eb..08a6a7287d8 100644 --- a/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java +++ b/Mage.Client/src/main/java/org/mage/plugins/card/dl/sources/WizardCardsImageSource.java @@ -92,6 +92,7 @@ public class WizardCardsImageSource implements CardImageSource { setsAliases.put("ATH", "Anthologies"); setsAliases.put("ATQ", "Antiquities"); setsAliases.put("AVR", "Avacyn Restored"); + setsAliases.put("BFZ", "Battle for Zendikar"); setsAliases.put("BNG", "Born of the Gods"); setsAliases.put("BOK", "Betrayers of Kamigawa"); setsAliases.put("BRB", "Battle Royale Box Set"); diff --git a/Mage.Client/src/main/resources/card-pictures-tok.txt b/Mage.Client/src/main/resources/card-pictures-tok.txt index 406edd79263..9cf60742b90 100644 --- a/Mage.Client/src/main/resources/card-pictures-tok.txt +++ b/Mage.Client/src/main/resources/card-pictures-tok.txt @@ -26,7 +26,20 @@ #Generate|TOK:TPR|Thopter| #Generate|TOK:TPR|Zombie| +#|Generate|TOK:ORI|Ashaya, the Awoken World| +#|Generate|TOK:ORI|Angel| +#|Generate|TOK:ORI|Demon| +#|Generate|TOK:ORI|Elemental| +#|Generate|TOK:ORI|Elf Warrior| +#|Generate|TOK:ORI|Goblin| +#|Generate|TOK:ORI|Knight| +#|Generate|TOK:ORI|Soldier| +#|Generate|TOK:ORI|Thopter 1| +#|Generate|TOK:ORI|Thopter 2| #|Generate|TOK:ORI|Zombie| +#|Generate|EMBLEM!:ORI|Emblem Chandra, Roaring Flame| +#|Generate|EMBLEM!:ORI|Emblem Jace, Telepath Unbound| +#|Generate|EMBLEM!:ORI|Emblem Liliana, Defiant Necromancer| #|Generate|TOK:PTC|Angel| #|Generate|TOK:PTC|Avatar| diff --git a/Mage.Client/src/main/resources/image.url.properties b/Mage.Client/src/main/resources/image.url.properties index f558b0933de..fb9c408f3ab 100644 --- a/Mage.Client/src/main/resources/image.url.properties +++ b/Mage.Client/src/main/resources/image.url.properties @@ -64,6 +64,6 @@ ddd=gvl unh=uh dde=pvc # Remove setname as soon as the images can be downloaded -ignore.urls=TOK,MM2,V15 +ignore.urls=TOK,MM2,V15,BFZ # sets ordered by release time (newest goes first) -token.lookup.order=FVD,FVE,FVL,FVR,V12,V13,V14,V15,TPR,MPRP,DD3,DDO,ORI,MM2,PTC,DTK,FRF,KTK,M15,VMA,CNS,JOU,BNG,THS,DDL,M14,MMA,DGM,GTC,RTR,M13,AVR,DDI,DKA,ISD,M12,NPH,MBS,SOM,M11,ROE,DDE,WWK,ZEN,M10,GVL,ARB,DVD,CFX,JVC,ALA,EVE,SHM,EVG,MOR,LRW,10E,CLS,CHK,GRC \ No newline at end of file +token.lookup.order=BFZ,FVD,FVE,FVL,FVR,V12,V13,V14,V15,TPR,MPRP,DD3,DDO,ORI,MM2,PTC,DTK,FRF,KTK,M15,VMA,CNS,JOU,BNG,THS,DDL,M14,MMA,DGM,GTC,RTR,M13,AVR,DDI,DKA,ISD,M12,NPH,MBS,SOM,M11,ROE,DDE,WWK,ZEN,M10,GVL,ARB,DVD,CFX,JVC,ALA,EVE,SHM,EVG,MOR,LRW,10E,CLS,CHK,GRC \ No newline at end of file diff --git a/Mage.Common/pom.xml b/Mage.Common/pom.xml index 7a1a16c5dcf..f7e64b9d190 100644 --- a/Mage.Common/pom.xml +++ b/Mage.Common/pom.xml @@ -7,7 +7,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-common diff --git a/Mage.Common/src/mage/utils/MageVersion.java b/Mage.Common/src/mage/utils/MageVersion.java index 68ca1b5026f..c4034f0b78b 100644 --- a/Mage.Common/src/mage/utils/MageVersion.java +++ b/Mage.Common/src/mage/utils/MageVersion.java @@ -40,8 +40,8 @@ public class MageVersion implements Serializable, Comparable { */ public final static int MAGE_VERSION_MAJOR = 1; public final static int MAGE_VERSION_MINOR = 4; - public final static int MAGE_VERSION_PATCH = 2; - public final static String MAGE_VERSION_MINOR_PATCH = "v2"; + public final static int MAGE_VERSION_PATCH = 3; + public final static String MAGE_VERSION_MINOR_PATCH = "v0"; public final static String MAGE_VERSION_INFO = ""; private final int major; diff --git a/Mage.Common/src/mage/view/CardView.java b/Mage.Common/src/mage/view/CardView.java index 857db14cd63..089c6fa158d 100644 --- a/Mage.Common/src/mage/view/CardView.java +++ b/Mage.Common/src/mage/view/CardView.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.view; import java.util.ArrayList; @@ -59,6 +58,7 @@ import mage.target.Targets; * @author BetaSteward_at_googlemail.com */ public class CardView extends SimpleCardView { + private static final long serialVersionUID = 1L; protected UUID parentId; @@ -91,7 +91,7 @@ public class CardView extends SimpleCardView { protected boolean flipCard; protected boolean faceDown; - + protected String alternateName; protected String originalName; @@ -117,7 +117,7 @@ public class CardView extends SimpleCardView { protected boolean isPlayable; protected boolean isChoosable; protected boolean selected; - protected boolean canAttack; + protected boolean canAttack; public CardView(Card card) { this(card, null, false); @@ -137,13 +137,42 @@ public class CardView extends SimpleCardView { * * @param card * @param game - * @param controlled is the card view created for the card controller - used for morph / face down cards to know which player may see information for the card + * @param controlled is the card view created for the card controller - used + * for morph / face down cards to know which player may see information for + * the card */ public CardView(Card card, Game game, boolean controlled) { + this(card, game, controlled, false); + } + + /** + * + * @param card + * @param game + * @param controlled is the card view created for the card controller - used + * for morph / face down cards to know which player may see information for + * the card + * @param showFaceDownCard if true and the card is not on the battelfield, + * also a face dwon card is shown in the view dwon cards will be shown + */ + public CardView(Card card, Game game, boolean controlled, boolean showFaceDownCard) { super(card.getId(), card.getExpansionSetCode(), card.getCardNumber(), card.getUsesVariousArt(), card.getTokenSetCode(), game != null); // no information available for face down cards as long it's not a controlled face down morph card - // TODO: Better handle this in Framework (but currently I'm not sure how to do it there) LevelX2 - if (game != null && card.isFaceDown(game)) { + // TODO: Better handle this in Framework (but currently I'm not sure how to do it there) LevelX2 + boolean showFaceUp = true; + if (game != null) { + if (card.isFaceDown(game)) { + showFaceUp = false; + if (!Zone.BATTLEFIELD.equals(game.getState().getZone(card.getId()))) { + if (showFaceDownCard) { + showFaceUp = true; + } + } + } + } + // boolean showFaceUp = game == null || !card.isFaceDown(game) || (!game.getState().getZone(card.getId()).equals(Zone.BATTLEFIELD) && showFaceDownCard); + + if (!showFaceUp) { this.fillEmpty(card, controlled); if (card instanceof Spell) { // special handling for casting of Morph cards @@ -154,10 +183,10 @@ public class CardView extends SimpleCardView { } this.power = "2"; this.toughness = "2"; - this.rules.add("You may cast this card as a 2/2 face-down creature, with no text," + - " no name, no subtypes, and no mana cost by paying {3} rather than paying its mana cost."); + this.rules.add("You may cast this card as a 2/2 face-down creature, with no text," + + " no name, no subtypes, and no mana cost by paying {3} rather than paying its mana cost."); return; - } else { + } else { if (card instanceof Permanent) { this.power = Integer.toString(card.getPower().getValue()); this.toughness = Integer.toString(card.getToughness().getValue()); @@ -176,7 +205,7 @@ public class CardView extends SimpleCardView { rotate = true; } else { if (card instanceof Spell) { - switch(((Spell) card).getSpellAbility().getSpellAbilityType()) { + switch (((Spell) card).getSpellAbility().getSpellAbilityType()) { case SPLIT_FUSED: splitCard = (SplitCard) ((Spell) card).getCard(); rotate = true; @@ -212,7 +241,7 @@ public class CardView extends SimpleCardView { if (card instanceof Permanent) { this.mageObjectType = MageObjectType.PERMANENT; - Permanent permanent = (Permanent)card; + Permanent permanent = (Permanent) card; this.loyalty = Integer.toString(permanent.getCounters().getCount(CounterType.LOYALTY)); this.pairedCard = permanent.getPairedCard(); if (!permanent.getControllerId().equals(permanent.getOwnerId())) { @@ -220,7 +249,7 @@ public class CardView extends SimpleCardView { } if (game != null && permanent.getCounters() != null && !permanent.getCounters().isEmpty()) { counters.clear(); - for (Counter counter: permanent.getCounters().values()) { + for (Counter counter : permanent.getCounters().values()) { counters.add(new CounterView(counter)); } } @@ -233,7 +262,7 @@ public class CardView extends SimpleCardView { this.loyalty = ""; if (game != null && card.getCounters(game) != null && !card.getCounters(game).isEmpty()) { counters.clear(); - for (Counter counter: card.getCounters(game).values()) { + for (Counter counter : card.getCounters(game).values()) { counters.add(new CounterView(counter)); } } @@ -249,8 +278,8 @@ public class CardView extends SimpleCardView { this.color = card.getColor(game); this.canTransform = card.canTransform(); this.flipCard = card.isFlipCard(); - this.faceDown = game != null ? card.isFaceDown(game) : false; - + this.faceDown = !showFaceUp; + if (card instanceof PermanentToken) { this.isToken = true; this.mageObjectType = MageObjectType.TOKEN; @@ -267,7 +296,7 @@ public class CardView extends SimpleCardView { // set code und card number for token copies to get the image this.rules.clear(); this.rules.addAll(((PermanentToken) card).getRules(game)); - this.type = ((PermanentToken)card).getToken().getTokenType(); + this.type = ((PermanentToken) card).getToken().getTokenType(); } else { this.rarity = card.getRarity(); this.isToken = false; @@ -279,7 +308,7 @@ public class CardView extends SimpleCardView { this.originalName = card.getName(); } this.flipCard = card.isFlipCard(); - if (card.isFlipCard() && card.getFlipCardName() != null) { + if (card.isFlipCard() && card.getFlipCardName() != null) { this.alternateName = card.getFlipCardName(); this.originalName = card.getName(); } @@ -287,8 +316,8 @@ public class CardView extends SimpleCardView { if (card instanceof Spell) { this.mageObjectType = MageObjectType.SPELL; Spell spell = (Spell) card; - for (SpellAbility spellAbility: spell.getSpellAbilities()) { - for(UUID modeId : spellAbility.getModes().getSelectedModes()) { + for (SpellAbility spellAbility : spell.getSpellAbilities()) { + for (UUID modeId : spellAbility.getModes().getSelectedModes()) { spellAbility.getModes().setActiveMode(modeId); if (spellAbility.getTargets().size() > 0) { setTargets(spellAbility.getTargets()); @@ -298,12 +327,12 @@ public class CardView extends SimpleCardView { // show for modal spell, which mode was choosen if (spell.getSpellAbility().isModal()) { Modes modes = spell.getSpellAbility().getModes(); - for(UUID modeId : modes.getSelectedModes()) { + for (UUID modeId : modes.getSelectedModes()) { modes.setActiveMode(modeId); - this.rules.add("Chosen mode: " + spell.getSpellAbility().getEffects().getText(modes.get(modeId))+""); + this.rules.add("Chosen mode: " + spell.getSpellAbility().getEffects().getText(modes.get(modeId)) + ""); } } - } + } } public CardView(MageObject object) { @@ -346,7 +375,7 @@ public class CardView extends SimpleCardView { this.rules.addAll(emblem.getAbilities().getRules(emblem.getName())); } if (this.rarity == null && object instanceof StackAbility) { - StackAbility stackAbility = (StackAbility)object; + StackAbility stackAbility = (StackAbility) object; this.rarity = Rarity.NA; this.rules.clear(); this.rules.add(stackAbility.getRule()); @@ -359,7 +388,7 @@ public class CardView extends SimpleCardView { protected CardView() { super(null, "", 0, false, "", true); } - + public CardView(EmblemView emblem) { this(true); this.gameObject = true; @@ -409,7 +438,7 @@ public class CardView extends SimpleCardView { } else { this.mageObjectType = MageObjectType.CARD; } - } + } if (card instanceof PermanentToken) { this.mageObjectType = MageObjectType.TOKEN; } @@ -422,7 +451,7 @@ public class CardView extends SimpleCardView { CardView(Token token) { super(token.getId(), "", 0, false, ""); - this.isToken = true; + this.isToken = true; this.id = token.getId(); this.name = token.getName(); this.displayName = token.getName(); @@ -528,11 +557,11 @@ public class CardView extends SimpleCardView { public String getExpansionSetCode() { return expansionSetCode; } - + public void setExpansionSetCode(String expansionSetCode) { this.expansionSetCode = expansionSetCode; } - + @Override public UUID getId() { return id; @@ -544,8 +573,7 @@ public class CardView extends SimpleCardView { } /** - * Returns UUIDs for targets. - * Can be null if there is no target selected. + * Returns UUIDs for targets. Can be null if there is no target selected. * * @return */ @@ -607,7 +635,8 @@ public class CardView extends SimpleCardView { } /** - * Stores the name of the original name, to provide it for a flipped or transformed or copying card + * Stores the name of the original name, to provide it for a flipped or + * transformed or copying card * * @return */ @@ -718,7 +747,7 @@ public class CardView extends SimpleCardView { public boolean isChoosable() { return isChoosable; } - + public void setChoosable(boolean isChoosable) { this.isChoosable = isChoosable; } @@ -738,5 +767,5 @@ public class CardView extends SimpleCardView { public void setCanAttack(boolean canAttack) { this.canAttack = canAttack; } - + } diff --git a/Mage.Common/src/mage/view/CardsView.java b/Mage.Common/src/mage/view/CardsView.java index a39a9d6e007..4a7ee78da5b 100644 --- a/Mage.Common/src/mage/view/CardsView.java +++ b/Mage.Common/src/mage/view/CardsView.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.view; import java.util.ArrayList; @@ -37,6 +36,7 @@ import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.Effect; import mage.cards.Card; +import mage.constants.CardType; import mage.constants.Zone; import static mage.constants.Zone.ALL; import static mage.constants.Zone.BATTLEFIELD; @@ -49,6 +49,7 @@ import mage.game.GameState; import mage.game.command.Emblem; import mage.game.permanent.Permanent; import mage.target.targetpointer.TargetPointer; +import mage.util.GameLog; /** * @@ -56,27 +57,34 @@ import mage.target.targetpointer.TargetPointer; */ public class CardsView extends LinkedHashMap { - public CardsView() {} + public CardsView() { + } public CardsView(Collection cards) { - for (Card card: cards) { + for (Card card : cards) { this.put(card.getId(), new CardView(card)); } } public CardsView(Game game, Collection cards) { - for (Card card: cards) { + for (Card card : cards) { this.put(card.getId(), new CardView(card, game, false)); } } - public CardsView ( Collection abilities, Game game ) { - for ( Ability ability : abilities ) { + public CardsView(Game game, Collection cards, boolean showFaceDown) { + for (Card card : cards) { + this.put(card.getId(), new CardView(card, game, false, showFaceDown)); + } + } + + public CardsView(Collection abilities, Game game) { + for (Ability ability : abilities) { MageObject sourceObject = null; AbilityView abilityView = null; boolean isCard = false; boolean isPermanent = false; - switch ( ability.getZone() ) { + switch (ability.getZone()) { case ALL: case EXILED: case GRAVEYARD: @@ -86,7 +94,7 @@ public class CardsView extends LinkedHashMap { case BATTLEFIELD: sourceObject = game.getPermanent(ability.getSourceId()); if (sourceObject == null) { - sourceObject = (Permanent)game.getLastKnownInformation(ability.getSourceId(), Zone.BATTLEFIELD); + sourceObject = (Permanent) game.getLastKnownInformation(ability.getSourceId(), Zone.BATTLEFIELD); } isPermanent = true; break; @@ -99,14 +107,19 @@ public class CardsView extends LinkedHashMap { case COMMAND: sourceObject = game.getObject(ability.getSourceId()); if (sourceObject instanceof Emblem) { - Card planeswalkerCard = game.getCard(((Emblem)sourceObject).getSourceId()); + Card planeswalkerCard = game.getCard(((Emblem) sourceObject).getSourceId()); if (planeswalkerCard != null) { - abilityView = new AbilityView(ability, "Emblem " + planeswalkerCard.getName(), new CardView(new EmblemView((Emblem)sourceObject, planeswalkerCard))); + if (!planeswalkerCard.getCardType().contains(CardType.PLANESWALKER)) { + if (planeswalkerCard.getSecondCardFace() != null) { + planeswalkerCard = planeswalkerCard.getSecondCardFace(); + } + } + abilityView = new AbilityView(ability, "Emblem " + planeswalkerCard.getName(), new CardView(new EmblemView((Emblem) sourceObject, planeswalkerCard))); abilityView.setName("Emblem " + planeswalkerCard.getName()); abilityView.setExpansionSetCode(planeswalkerCard.getExpansionSetCode()); } else { throw new IllegalArgumentException("Source card for emblem not found."); - } + } } break; } @@ -114,9 +127,9 @@ public class CardsView extends LinkedHashMap { if (abilityView == null) { CardView sourceCardView; if (isPermanent) { - sourceCardView = new CardView((Permanent)sourceObject); + sourceCardView = new CardView((Permanent) sourceObject); } else if (isCard) { - sourceCardView = new CardView((Card)sourceObject); + sourceCardView = new CardView((Card) sourceObject); } else { sourceCardView = new CardView(sourceObject); } @@ -139,11 +152,14 @@ public class CardsView extends LinkedHashMap { for (UUID uuid : abilityTargets) { MageObject mageObject = game.getObject(uuid); if (mageObject != null) { - names.add(mageObject.getName()); + if ((mageObject instanceof Card) && ((Card) mageObject).isFaceDown(game)) { + continue; + } + names.add(GameLog.getColoredObjectIdNameForTooltip(mageObject)); } } if (!names.isEmpty()) { - abilityView.getRules().add("Related to: " + names.toString() + ""); + abilityView.getRules().add("Related objects: " + names.toString() + ""); } } } @@ -153,7 +169,7 @@ public class CardsView extends LinkedHashMap { } public CardsView(Collection abilities, GameState state) { - for (Ability ability: abilities) { + for (Ability ability : abilities) { Card sourceCard = state.getPermanent(ability.getSourceId()); if (sourceCard != null) { this.put(ability.getId(), new AbilityView(ability, sourceCard.getName(), new CardView(sourceCard))); diff --git a/Mage.Common/src/mage/view/GameView.java b/Mage.Common/src/mage/view/GameView.java index b75d8045131..9f078a75b91 100644 --- a/Mage.Common/src/mage/view/GameView.java +++ b/Mage.Common/src/mage/view/GameView.java @@ -1,36 +1,42 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.view; +import java.io.Serializable; +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.UUID; import mage.MageObject; import mage.abilities.costs.Cost; import mage.cards.Card; +import mage.constants.CardType; import mage.constants.PhaseStep; import mage.constants.TurnPhase; import mage.constants.Zone; @@ -45,18 +51,15 @@ import mage.game.stack.Spell; import mage.game.stack.StackAbility; import mage.game.stack.StackObject; import mage.players.Player; -import org.apache.log4j.Logger; - -import java.io.Serializable; -import java.util.*; import mage.watchers.common.CastSpellLastTurnWatcher; - +import org.apache.log4j.Logger; /** * * @author BetaSteward_at_googlemail.com */ public class GameView implements Serializable { + private static final long serialVersionUID = 1L; private static final transient Logger logger = Logger.getLogger(GameView.class); @@ -83,70 +86,73 @@ public class GameView implements Serializable { private final int spellsCastCurrentTurn; private final boolean rollbackTurnsAllowed; - public GameView(GameState state, Game game, UUID createdForPlayerId, UUID watcherUserId) { Player createdForPlayer = null; this.isPlayer = createdForPlayerId != null; this.priorityTime = game.getPriorityTime(); - for (Player player: state.getPlayers().values()) { + for (Player player : state.getPlayers().values()) { players.add(new PlayerView(player, state, game, createdForPlayerId, watcherUserId)); if (player.getId().equals(createdForPlayerId)) { createdForPlayer = player; } } - for (StackObject stackObject: state.getStack()) { + for (StackObject stackObject : state.getStack()) { if (stackObject instanceof StackAbility) { - // Stack Ability + // Stack Ability MageObject object = game.getObject(stackObject.getSourceId()); Card card = game.getCard(stackObject.getSourceId()); if (card != null) { if (object != null) { - stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility)stackObject, card.getName(), new CardView(card))); + stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility) stackObject, card.getName(), new CardView(card))); } else { - stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility)stackObject, "", new CardView(card))); + stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility) stackObject, "", new CardView(card))); } if (card.canTransform()) { updateLatestCardView(game, card, stackObject.getId()); } - checkPaid(stackObject.getId(), (StackAbility)stackObject); + checkPaid(stackObject.getId(), (StackAbility) stackObject); } else if (object != null) { if (object instanceof PermanentToken) { - PermanentToken token = (PermanentToken)object; - stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility)stackObject, token.getName(), new CardView(token))); - checkPaid(stackObject.getId(), (StackAbility)stackObject); + PermanentToken token = (PermanentToken) object; + stack.put(stackObject.getId(), new StackAbilityView(game, (StackAbility) stackObject, token.getName(), new CardView(token))); + checkPaid(stackObject.getId(), (StackAbility) stackObject); } else if (object instanceof Emblem) { - Card sourceCard = game.getCard(((Emblem)object).getSourceId()); + Card sourceCard = game.getCard(((Emblem) object).getSourceId()); if (sourceCard != null) { - ((StackAbility)stackObject).setName("Emblem " + sourceCard.getName()); - ((StackAbility)stackObject).setExpansionSetCode(sourceCard.getExpansionSetCode()); + if (!sourceCard.getCardType().contains(CardType.PLANESWALKER)) { + if (sourceCard.getSecondCardFace() != null) { + sourceCard = sourceCard.getSecondCardFace(); + } + } + ((StackAbility) stackObject).setName("Emblem " + sourceCard.getName()); + ((StackAbility) stackObject).setExpansionSetCode(sourceCard.getExpansionSetCode()); } else { throw new IllegalArgumentException("Source card for emblem not found."); } - stack.put(stackObject.getId(), - new StackAbilityView(game, (StackAbility)stackObject, object.getName(), new CardView(new EmblemView(((Emblem)object),sourceCard)))); - checkPaid(stackObject.getId(), ((StackAbility)stackObject)); + stack.put(stackObject.getId(), + new StackAbilityView(game, (StackAbility) stackObject, object.getName(), new CardView(new EmblemView(((Emblem) object), sourceCard)))); + checkPaid(stackObject.getId(), ((StackAbility) stackObject)); } else { - StackAbility stackAbility = ((StackAbility)object); + StackAbility stackAbility = ((StackAbility) object); stackAbility.newId(); - stack.put(stackObject.getId(), new CardView(((StackAbility)stackObject))); - checkPaid(stackObject.getId(), ((StackAbility)stackObject)); + stack.put(stackObject.getId(), new CardView(((StackAbility) stackObject))); + checkPaid(stackObject.getId(), ((StackAbility) stackObject)); } } else { logger.error("Stack Object for stack ability not found: " + stackObject.getStackAbility().getRule()); } - } - else { + } else { // Spell - stack.put(stackObject.getId(), new CardView((Spell)stackObject, game, stackObject.getControllerId().equals(createdForPlayerId))); - checkPaid(stackObject.getId(), (Spell)stackObject); + stack.put(stackObject.getId(), new CardView((Spell) stackObject, game, stackObject.getControllerId().equals(createdForPlayerId))); + checkPaid(stackObject.getId(), (Spell) stackObject); } //stackOrder.add(stackObject.getId()); } //Collections.reverse(stackOrder); - for (ExileZone exileZone: state.getExile().getExileZones()) { + for (ExileZone exileZone : state.getExile().getExileZones()) { exiles.add(new ExileView(exileZone, game)); } - for (String name: state.getRevealed().keySet()) { + for (String name : state.getRevealed().keySet()) { revealed.add(new RevealedView(name, state.getRevealed().get(name), game)); } this.phase = state.getTurn().getPhaseType(); @@ -163,7 +169,7 @@ public class GameView implements Serializable { } else { this.priorityPlayerName = ""; } - for (CombatGroup combatGroup: state.getCombat().getGroups()) { + for (CombatGroup combatGroup : state.getCombat().getGroups()) { combat.add(new CombatGroupView(combatGroup, game)); } if (isPlayer) { @@ -174,13 +180,13 @@ public class GameView implements Serializable { } else { this.special = false; } - + CastSpellLastTurnWatcher watcher = (CastSpellLastTurnWatcher) game.getState().getWatchers().get("CastSpellLastTurnWatcher"); if (watcher != null) { spellsCastCurrentTurn = watcher.getAmountOfSpellsAllPlayersCastOnCurrentTurn(); } else { spellsCastCurrentTurn = 0; - } + } rollbackTurnsAllowed = game.getOptions().rollbackTurnsAllowed; } @@ -215,7 +221,7 @@ public class GameView implements Serializable { } Permanent permanent = game.getPermanent(card.getId()); if (permanent == null) { - permanent = (Permanent)game.getLastKnownInformation(card.getId(), Zone.BATTLEFIELD); + permanent = (Permanent) game.getLastKnownInformation(card.getId(), Zone.BATTLEFIELD); } if (permanent != null) { if (permanent.isTransformed()) { @@ -328,5 +334,5 @@ public class GameView implements Serializable { public boolean isRollbackTurnsAllowed() { return rollbackTurnsAllowed; } - + } diff --git a/Mage.Common/src/mage/view/PlayerView.java b/Mage.Common/src/mage/view/PlayerView.java index 14c3990eb38..ce66a5ffbe0 100644 --- a/Mage.Common/src/mage/view/PlayerView.java +++ b/Mage.Common/src/mage/view/PlayerView.java @@ -34,6 +34,7 @@ import java.util.List; import java.util.Map; import java.util.UUID; import mage.cards.Card; +import mage.constants.CardType; import mage.counters.CounterType; import mage.game.ExileZone; import mage.game.Game; @@ -125,6 +126,11 @@ public class PlayerView implements Serializable { if (emblem.getControllerId().equals(this.playerId)) { Card sourceCard = game.getCard(((CommandObject) emblem).getSourceId()); if (sourceCard != null) { + if (!sourceCard.getCardType().contains(CardType.PLANESWALKER)) { + if (sourceCard.getSecondCardFace() != null) { + sourceCard = sourceCard.getSecondCardFace(); + } + } commandList.add(new EmblemView(emblem, sourceCard)); } } diff --git a/Mage.Common/src/mage/view/StackAbilityView.java b/Mage.Common/src/mage/view/StackAbilityView.java index 9ec6c3f1776..cec56c58a99 100644 --- a/Mage.Common/src/mage/view/StackAbilityView.java +++ b/Mage.Common/src/mage/view/StackAbilityView.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.view; import java.util.ArrayList; @@ -34,6 +33,7 @@ import java.util.UUID; import mage.MageObject; import mage.abilities.Modes; import mage.abilities.effects.Effect; +import mage.cards.Card; import mage.constants.AbilityType; import mage.constants.CardType; import mage.constants.MageObjectType; @@ -41,21 +41,22 @@ import mage.game.Game; import mage.game.stack.StackAbility; import mage.target.targetpointer.FixedTarget; import mage.target.targetpointer.TargetPointer; +import mage.util.GameLog; /** * * @author BetaSteward_at_googlemail.com */ public class StackAbilityView extends CardView { + private static final long serialVersionUID = 1L; private final CardView sourceCard; - private final AbilityType abilityType; public StackAbilityView(Game game, StackAbility ability, String sourceName, CardView sourceCard) { this.id = ability.getId(); this.mageObjectType = MageObjectType.ABILITY_STACK; - this.abilityType = ability.getStackAbility().getAbilityType(); + this.abilityType = ability.getStackAbility().getAbilityType(); this.sourceCard = sourceCard; this.sourceCard.setMageObjectType(mageObjectType); this.name = "Ability"; @@ -76,7 +77,7 @@ public class StackAbilityView extends CardView { String nameToShow; if (sourceCard.isFaceDown()) { CardView tmpSourceCard = this.getSourceCard(); - tmpSourceCard.displayName = "Face Down"; + tmpSourceCard.displayName = "Face Down"; tmpSourceCard.superTypes.clear(); tmpSourceCard.subTypes.clear(); tmpSourceCard.cardTypes.clear(); @@ -97,7 +98,7 @@ public class StackAbilityView extends CardView { private void updateTargets(Game game, StackAbility ability) { List names = new ArrayList<>(); - for(UUID modeId : ability.getModes().getSelectedModes()) { + for (UUID modeId : ability.getModes().getSelectedModes()) { ability.getModes().setActiveMode(modeId); if (ability.getTargets().size() > 0) { setTargets(ability.getTargets()); @@ -115,7 +116,10 @@ public class StackAbilityView extends CardView { for (UUID uuid : targetList) { MageObject mageObject = game.getObject(uuid); if (mageObject != null) { - names.add(mageObject.getName()); + if ((mageObject instanceof Card) && ((Card) mageObject).isFaceDown(game)) { + continue; + } + names.add(GameLog.getColoredObjectIdNameForTooltip(mageObject)); } } @@ -128,9 +132,9 @@ public class StackAbilityView extends CardView { // show for modal ability, which mode was choosen if (ability.isModal()) { Modes modes = ability.getModes(); - for(UUID modeId : modes.getSelectedModes()) { + for (UUID modeId : modes.getSelectedModes()) { modes.setActiveMode(modeId); - this.rules.add("Chosen mode: " + ability.getEffects().getText(modes.get(modeId))+""); + this.rules.add("Chosen mode: " + ability.getEffects().getText(modes.get(modeId)) + ""); } } } @@ -143,5 +147,5 @@ public class StackAbilityView extends CardView { public AbilityType getAbilityType() { return abilityType; } - + } diff --git a/Mage.Network/pom.xml b/Mage.Network/pom.xml index b9cbd205837..8111e78e2e0 100644 --- a/Mage.Network/pom.xml +++ b/Mage.Network/pom.xml @@ -5,7 +5,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-network diff --git a/Mage.Plugins/Mage.Counter.Plugin/pom.xml b/Mage.Plugins/Mage.Counter.Plugin/pom.xml index e5ae116c808..df8cc7328b3 100644 --- a/Mage.Plugins/Mage.Counter.Plugin/pom.xml +++ b/Mage.Plugins/Mage.Counter.Plugin/pom.xml @@ -7,7 +7,7 @@ org.mage mage-plugins - 1.4.2 + 1.4.3 mage-counter-plugin diff --git a/Mage.Plugins/Mage.Theme.Plugin/pom.xml b/Mage.Plugins/Mage.Theme.Plugin/pom.xml index b85682e19c0..eebc730e4a8 100644 --- a/Mage.Plugins/Mage.Theme.Plugin/pom.xml +++ b/Mage.Plugins/Mage.Theme.Plugin/pom.xml @@ -6,7 +6,7 @@ org.mage mage-plugins - 1.4.2 + 1.4.3 mage-theme-plugin @@ -29,7 +29,7 @@ ${project.groupId} mage-client - 1.4.2 + 1.4.3 diff --git a/Mage.Plugins/pom.xml b/Mage.Plugins/pom.xml index ab4aa2c1d22..4e6b8ad8521 100644 --- a/Mage.Plugins/pom.xml +++ b/Mage.Plugins/pom.xml @@ -7,7 +7,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-plugins diff --git a/Mage.Server.Console/pom.xml b/Mage.Server.Console/pom.xml index eabc69c999a..96de7c38d85 100644 --- a/Mage.Server.Console/pom.xml +++ b/Mage.Server.Console/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 org.mage diff --git a/Mage.Server.Plugins/Mage.Deck.Constructed/pom.xml b/Mage.Server.Plugins/Mage.Deck.Constructed/pom.xml index b3599cd383e..dabc671779d 100644 --- a/Mage.Server.Plugins/Mage.Deck.Constructed/pom.xml +++ b/Mage.Server.Plugins/Mage.Deck.Constructed/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-deck-constructed diff --git a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/DuelCommander.java b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/DuelCommander.java index 2cad7819012..feb71b5e85a 100644 --- a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/DuelCommander.java +++ b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/DuelCommander.java @@ -64,6 +64,7 @@ public class DuelCommander extends Commander { banned.add("Mox Pearl"); banned.add("Mox Ruby"); banned.add("Mox Sapphire"); + banned.add("Mystical Tutor"); // banned effective July 17, 2015 banned.add("Natural Order"); banned.add("Necropotence"); banned.add("Oath of Druids"); diff --git a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/HistoricalStandard.java b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/HistoricalStandard.java new file mode 100644 index 00000000000..9f15bf867dc --- /dev/null +++ b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/HistoricalStandard.java @@ -0,0 +1,214 @@ +package mage.deck; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Calendar; +import java.util.GregorianCalendar; +import java.util.HashMap; +import java.util.Map; +import mage.cards.ExpansionSet; +import mage.cards.Sets; +import mage.cards.decks.Constructed; +import mage.cards.decks.Deck; +import mage.constants.SetType; + +/** + * This class represents a deck from any past standard. + * + * This class was originally made to work with the historical standard ruleset. + * Data taken from http://thattournament.website/historic-tournament.php (site + * changed, originally http://mtgt.nfshost.com/historic-tournament.php) + * + * If there are any questions or corrections, feel free to contact me. + * + * @author Marthinwurer (at gmail.com) + */ +public class HistoricalStandard extends Constructed { + + /* + * This array stores the set codes of each standard up to + * Kamigawa/Ravnica standard, where rotation stabilized. + */ + protected static final String[][] standards = { + // 1st standard: The Dark, Fallen Empires, and 4th. + {"DRK", "FEM", "4ED"}, + // 2nd standard: 4th, Fallen Empires, Ice Age, Chronicles, Homelands, + // Alliances, and Mirage. + {"FEM", "4ED", "ICE", "HML", "ALL", "MIR"}, + // 3rd standard: 4th, Chronicles, Alliances, Mirage, Visions. + {"4ED", "ALL", "MIR", "VIS"}, + // 4th Standard: Ice Age, Homelands, Alliances, Mirage, Visions, 5th, + // and Weatherlight. + {"ICE", "HML", "ALL", "MIR", "VIS", "5ED", "WTH"}, + // 5th Standard: Mirage, Visions, 5th, Weatherlight, Tempest, + // Stronghold, and Exodus. + {"MIR", "VIS", "5ED", "WTH", "TMP", "STH", "EXO"}, + // 6th Standard: 5th, Tempest, Stronghold, Exodus, Urza's Saga, Urza's + // Legacy, Urza's Destiny. + {"5ED", "TMP", "STH", "EXO", "USG", "ULG"}, + // 7th Standard: Tempest, Stronghold, Exodus, Urza's Saga, Urza's + // Legacy, 6th, Urza's Destiny. + {"TMP", "STH", "EXO", "USG", "ULG", "6ED", "UDS"}, + // 8th Standard: Urza's Saga, Urza's Legacy, 6th, Urza's Destiny, + // Mercadian Masques, Nemesis, Prophecy. + {"USG", "ULG", "6ED", "UDS", "MMQ", "NMS", "PCY"}, + // 9th Standard + {"6ED", "MMQ", "NMS", "PCY", "INV", "PLS"}, + // 10th Standard + {"7ED", "MMQ", "NMS", "PCY", "INV", "PLS", "APC"}, + // 11th Standard + {"7ED", "INV", "APC", "PLS", "ODY", "TOR", "JUD"}, + // 12th Standard + {"7ED", "ODY", "TOR", "JUD", "ONS", "LGN", "SCG"}, + // 13th Standard + {"8ED", "ODY", "TOR", "JUD", "ONS", "LGN", "SCG"}, + // 14th Standard + {"8ED", "ONS", "LGN", "SCG", "MRD", "DST", "5DN"}, + // 15th Standard + {"8ED", "MRD", "DST", "5DN", "CHK", "BOK", "SOK"}, + // 16th Standard + {"9ED", "MRD", "DST", "5DN", "CHK", "BOK", "SOK"}, + // 17th Standard + {"9ED", "CHK", "BOK", "SOK", "RAV", "GPT", "DIS", "CSP"}, + // 18th Standard + {"9ED", "RAV", "GPT", "DIS", "CSP", "TSP", "TSB", "PLC", "FUT"}, + // 19th Standard + {"10E", "RAV", "GPT", "DIS", "CSP", "TSP", "TSB", "PLC", "FUT"}, + // 20th Standard + {"10E", "CSP", "TSP", "TSB", "PLC", "FUT", "LRW", "MOR", "SHM", "EVE"}, + // 21st Standard + {"10E", "LRW", "MOR", "SHM", "EVE", "ALA", "CON", "ARB"} + }; + + /** + * Constructor. Don't need to mess with any of the sets yet; that will be + * done in the overridden validate function. + */ + public HistoricalStandard() { + super("Constructed - Historical Standard"); + + // banned cards + banned.add("Balance"); + banned.add("Memory Jar"); + banned.add("Mind Over Matter"); + banned.add("Mind Twist"); + banned.add("Skullclamp"); + banned.add("Tolarian Academy"); + banned.add("Yawgmoth's Bargain"); + } + + /** + * Overridden validate function. Changes the standard sets, then uses the + * regular validation function to test validity. + * + * @param deck - the deck to validate. + * @return + */ + @Override + public boolean validate(Deck deck) { + + Map leastInvalid = null; + + boolean valid = false; + + // first, check whether misty and batterskull are in the same deck. + Map counts = new HashMap<>(); + countCards(counts, deck.getCards()); + countCards(counts, deck.getSideboard()); + if (counts.containsKey("Stoneforge Mystic") + && counts.containsKey("Batterskull")) { + + // if both, then skip all following tests by returning + return false; + } + + // up to Lorwyn/Alara, standards will have to be hard-coded. + // iterate through the array of standards. + for (String[] sets : standards) { + + // clear the invalid list + invalid.clear(); + + // add the sets to the setCodes. + setCodes = new ArrayList<>(Arrays.asList(sets)); + + // validate it. If it validates, clear the invalid cards and break. + if (super.validate(deck)) { + valid = true; + break; + } + + // if the map holding the invalid cards is empty, set it to a + // copy of the current invalid list. + if (leastInvalid == null) { + leastInvalid = new HashMap<>(this.getInvalid()); + continue; + } + + // see how many invalid cards there are. if there are less invalid + // cards than the stored invalid list, assign the current invalid + // to leastInvalid. + if (leastInvalid.size() > this.getInvalid().size()) { + leastInvalid = new HashMap<>(this.getInvalid()); + } + } + + // After testing the first few standards, do the regular ones. + // set the initial starting and ending date, as well as the current. + GregorianCalendar start = new GregorianCalendar(2006, + Calendar.SEPTEMBER, 1); + GregorianCalendar end = new GregorianCalendar(2008, + Calendar.SEPTEMBER, 1); + GregorianCalendar current = new GregorianCalendar(); + + // use the method for determining regular standard legality, but change + // the date for each standard. + while (end.before(current) && !valid) { + + // clear the invalid list and set codes. + setCodes.clear(); + invalid.clear(); + + // increment the start and end dates. + start.set(Calendar.YEAR, start.get(Calendar.YEAR) + 1); + end.set(Calendar.YEAR, start.get(Calendar.YEAR) + 2); + + // Get the sets in that time period. + // (code taken from standard.java) + for (ExpansionSet set : Sets.getInstance().values()) { + if (set.getReleaseDate().after(start.getTime()) + && set.getReleaseDate().before(end.getTime()) + && (set.getSetType() == SetType.CORE || set.getSetType() == SetType.EXPANSION)) { + setCodes.add(set.getCode()); + } + } + + // validate it. If it validates, clear the invalid cards and break. + if (super.validate(deck)) { + invalid.clear(); + valid = true; + break; + } + + // see how many invalid cards there are. if there are less invalid + // cards than the stored invalid list, assign the current invalid + // to leastInvalid. + if (leastInvalid == null) { + leastInvalid = new HashMap<>(this.getInvalid()); + + } else if (leastInvalid.size() > this.getInvalid().size()) { + leastInvalid = new HashMap<>(this.getInvalid()); + } + } + + // if no standard environment is valid, set the invalid to the + // invalid that had the least errors. + if (!valid) { + this.invalid = new HashMap<>(leastInvalid); + } + + // return the validity. + return valid; + } + +} diff --git a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/SuperStandard.java b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/SuperStandard.java new file mode 100644 index 00000000000..de7ff76aae7 --- /dev/null +++ b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/SuperStandard.java @@ -0,0 +1,205 @@ +package mage.deck; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.Calendar; +import java.util.GregorianCalendar; +import java.util.HashMap; +import java.util.Map; +import mage.cards.ExpansionSet; +import mage.cards.Sets; +import mage.cards.decks.Constructed; +import mage.cards.decks.Deck; +import mage.constants.SetType; + +/** + * This class represents a deck conforming to the rules contained in the + * subreddit /r/SuperStandard. + * + * This class was originally made to work with the historical standard ruleset. + * Data taken from http://thattournament.website/historic-tournament.php (site + * changed, originally thtp://mtgt.nfshost.com/historic-tournament.php) + * + * If there are any questions or corrections, feel free to contact me. + * + * @author Marthinwurer (at gmail.com) + */ +public class SuperStandard extends Constructed { + + /* + * This array stores the set codes of each standard up to + * Kamigawa/Ravnica standard, where rotation stabilized. + * Data taken from http://thattournament.website/historic-tournament.php + */ + protected static final String[][] standards = { + // 11th Standard + {"7ED", "INV", "APC", "PLS", "ODY", "TOR", "JUD"}, + // 12th Standard + {"7ED", "ODY", "TOR", "JUD", "ONS", "LGN", "SCG"}, + // 13th Standard + {"8ED", "ODY", "TOR", "JUD", "ONS", "LGN", "SCG"}, + // 14th Standard + {"8ED", "ONS", "LGN", "SCG", "MRD", "DST", "5DN"}, + // 15th Standard + {"8ED", "MRD", "DST", "5DN", "CHK", "BOK", "SOK"}, + // 16th Standard + {"9ED", "MRD", "DST", "5DN", "CHK", "BOK", "SOK"}, + // 17th Standard + {"9ED", "CHK", "BOK", "SOK", "RAV", "GPT", "DIS", "CSP"}, + // 18th Standard + {"9ED", "RAV", "GPT", "DIS", "CSP", "TSP", "TSB", "PLC", "FUT"}, + // 19th Standard + {"10E", "RAV", "GPT", "DIS", "CSP", "TSP", "TSB", "PLC", "FUT"}, + // 20th Standard + {"10E", "CSP", "TSP", "TSB", "PLC", "FUT", "LRW", "MOR", "SHM", "EVE"}, + // 21st Standard + {"10E", "LRW", "MOR", "SHM", "EVE", "ALA", "CON", "ARB"} + }; + + /** + * Constructor. Don't need to mess with any of the sets yet; that will be + * done in the overridden validate function. + */ + public SuperStandard() { + super("Constructed - Super Standard"); + + banned.add("Ancient Den"); + banned.add("Disciple of the Vault"); + banned.add("Great Furnace"); + banned.add("Seat of the Synod"); + banned.add("Skullclamp"); + banned.add("Tree of Tales"); + banned.add("Vault of Whispers"); + } + + /** + * Overridden validate function. Changes the standard sets, then uses the + * regular validation function to test validity. + * + * @param deck - the deck to validate. + * @return + */ + @Override + public boolean validate(Deck deck) { + + Map leastInvalid = null; + + boolean valid = false; + + // first, check whether misty and batterskull are in the same deck. + Map counts = new HashMap<>(); + countCards(counts, deck.getCards()); + countCards(counts, deck.getSideboard()); + if (counts.containsKey("Stoneforge Mystic") + && counts.containsKey("Batterskull")) { + + // if both, then skip all following tests by returning + return false; + } + + // up to Lorwyn/Alara, standards will have to be hard-coded. + // iterate through the array of standards. + for (String[] sets : standards) { + + // clear the invalid list + invalid.clear(); + + // add the sets to the setCodes. + setCodes = new ArrayList<>(Arrays.asList(sets)); + + // if either of the mirrodin blocks are in the time period, ban + // misty and darksteel citadel + if (setCodes.contains("MRD") || setCodes.contains("SOM")) { + banned.add("Darksteel Citadel"); + } else { + banned.remove("Darksteel Citadel"); + } + + // validate it. If it validates, clear the invalid cards and break. + if (super.validate(deck)) { + valid = true; + break; + } + + // if the map holding the invalid cards is empty, set it to a + // copy of the current invalid list. + if (leastInvalid == null) { + leastInvalid = new HashMap<>(this.getInvalid()); + continue; + } + + // see how many invalid cards there are. if there are less invalid + // cards than the stored invalid list, assign the current invalid + // to leastInvalid. + if (leastInvalid.size() > this.getInvalid().size()) { + leastInvalid = new HashMap<>(this.getInvalid()); + } + } + + // After testing the first few standards, do the regular ones. + // set the initial starting and ending date, as well as the current. + GregorianCalendar start = new GregorianCalendar(2006, + Calendar.SEPTEMBER, 1); + GregorianCalendar end = new GregorianCalendar(2008, + Calendar.SEPTEMBER, 1); + GregorianCalendar current = new GregorianCalendar(); + + // use the method for determining regular standard legality, but change + // the date for each standard. + while (end.before(current) && !valid) { + + // clear the invalid list and set codes. + setCodes.clear(); + invalid.clear(); + + // increment the start and end dates. + start.set(Calendar.YEAR, start.get(Calendar.YEAR) + 1); + end.set(Calendar.YEAR, start.get(Calendar.YEAR) + 2); + + // Get the sets in that time period. + // (code taken from standard.java) + for (ExpansionSet set : Sets.getInstance().values()) { + if (set.getReleaseDate().after(start.getTime()) + && set.getReleaseDate().before(end.getTime()) + && (set.getSetType() == SetType.CORE || set.getSetType() == SetType.EXPANSION)) { + setCodes.add(set.getCode()); + } + } + + // if either of the mirrodin blocks are in the time period, ban + // misty and darksteel citadel + if (setCodes.contains("MRD") || setCodes.contains("SOM")) { + banned.add("Darksteel Citadel"); + } else { + banned.remove("Darksteel Citadel"); + } + + // validate it. If it validates, clear the invalid cards and break. + if (super.validate(deck)) { + invalid.clear(); + valid = true; + break; + } + + // see how many invalid cards there are. if there are less invalid + // cards than the stored invalid list, assign the current invalid + // to leastInvalid. + if (leastInvalid == null) { + leastInvalid = new HashMap<>(this.getInvalid()); + + } else if (leastInvalid.size() > this.getInvalid().size()) { + leastInvalid = new HashMap<>(this.getInvalid()); + } + } + + // if no standard environment is valid, set the invalid to the + // invalid that had the least errors. + if (!valid) { + this.invalid = new HashMap<>(leastInvalid); + } + + // return the validity. + return valid; + } + +} diff --git a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/TinyLeaders.java b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/TinyLeaders.java index 7144e68b5d8..7817d0be700 100644 --- a/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/TinyLeaders.java +++ b/Mage.Server.Plugins/Mage.Deck.Constructed/src/mage/deck/TinyLeaders.java @@ -65,6 +65,7 @@ public class TinyLeaders extends DeckValidator { banned.add("Edric, Spymaster of Trest"); banned.add("Fastbond"); banned.add("Goblin Recruiter"); + banned.add("Grindstone"); // banned effective July 13, 2015 banned.add("Hermit Druid"); banned.add("Imperial Seal"); banned.add("Library of Alexandria"); @@ -81,7 +82,6 @@ public class TinyLeaders extends DeckValidator { banned.add("Mox Ruby"); banned.add("Mox Sapphire"); banned.add("Necropotence"); - banned.add("Painter's Servant"); banned.add("Shahrazad"); banned.add("Skullclamp"); banned.add("Sol Ring"); diff --git a/Mage.Server.Plugins/Mage.Deck.Limited/pom.xml b/Mage.Server.Plugins/Mage.Deck.Limited/pom.xml index fef00e55350..3ab629a71a6 100644 --- a/Mage.Server.Plugins/Mage.Deck.Limited/pom.xml +++ b/Mage.Server.Plugins/Mage.Deck.Limited/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-deck-limited diff --git a/Mage.Server.Plugins/Mage.Game.CommanderDuel/pom.xml b/Mage.Server.Plugins/Mage.Game.CommanderDuel/pom.xml index 088bddb5c6e..66972c3a272 100644 --- a/Mage.Server.Plugins/Mage.Game.CommanderDuel/pom.xml +++ b/Mage.Server.Plugins/Mage.Game.CommanderDuel/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-game-commanderduel diff --git a/Mage.Server.Plugins/Mage.Game.CommanderDuel/src/mage/game/CommanderDuelMatch.java b/Mage.Server.Plugins/Mage.Game.CommanderDuel/src/mage/game/CommanderDuelMatch.java index b5f40072bc8..c20af5e9bf3 100644 --- a/Mage.Server.Plugins/Mage.Game.CommanderDuel/src/mage/game/CommanderDuelMatch.java +++ b/Mage.Server.Plugins/Mage.Game.CommanderDuel/src/mage/game/CommanderDuelMatch.java @@ -48,7 +48,7 @@ public class CommanderDuelMatch extends MatchImpl { // Don't like it to compare but seems like it's complicated to do it in another way if (options.getDeckType().equals("Variant Magic - Duel Commander")) { startLife = 30; - alsoHand = false; + alsoHand = true; // commander going to hand allowed to go to command zone effective July 17, 2015 } CommanderDuel game = new CommanderDuel(options.getAttackOption(), options.getRange(), options.getFreeMulligans(), startLife); game.setStartMessage(this.createGameStartMessage()); diff --git a/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/pom.xml b/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/pom.xml index bd62a87af49..ccfa64fc609 100644 --- a/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/pom.xml +++ b/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/pom.xml @@ -6,7 +6,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-game-commanderfreeforall diff --git a/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/src/mage/game/CommanderFreeForAllMatch.java b/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/src/mage/game/CommanderFreeForAllMatch.java index 1b23d078d99..998017e0613 100644 --- a/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/src/mage/game/CommanderFreeForAllMatch.java +++ b/Mage.Server.Plugins/Mage.Game.CommanderFreeForAll/src/mage/game/CommanderFreeForAllMatch.java @@ -1,60 +1,60 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ - -package mage.game; - -import mage.game.match.MatchImpl; -import mage.game.match.MatchOptions; - -/** - * - * @author LevelX2 - */ -public class CommanderFreeForAllMatch extends MatchImpl { - - public CommanderFreeForAllMatch(MatchOptions options) { - super(options); - } - - @Override - public void startGame() throws GameException { - int startLife = 40; - boolean alsoHand = true; - if (options.getDeckType().equals("Variant Magic - Duel Commander")) { - startLife = 30; - alsoHand = false; - } - CommanderFreeForAll game = new CommanderFreeForAll(options.getAttackOption(), options.getRange(), options.getFreeMulligans(), startLife); - game.setStartMessage(this.createGameStartMessage()); - game.setAlsoHand(alsoHand); - game.setAlsoLibrary(true); - initGame(game); - games.add(game); - } - -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.game; + +import mage.game.match.MatchImpl; +import mage.game.match.MatchOptions; + +/** + * + * @author LevelX2 + */ +public class CommanderFreeForAllMatch extends MatchImpl { + + public CommanderFreeForAllMatch(MatchOptions options) { + super(options); + } + + @Override + public void startGame() throws GameException { + int startLife = 40; + boolean alsoHand = true; + if (options.getDeckType().equals("Variant Magic - Duel Commander")) { + startLife = 30; + alsoHand = true; // commander going to hand allowed to go to command zone effective July 17, 2015 + } + CommanderFreeForAll game = new CommanderFreeForAll(options.getAttackOption(), options.getRange(), options.getFreeMulligans(), startLife); + game.setStartMessage(this.createGameStartMessage()); + game.setAlsoHand(alsoHand); + game.setAlsoLibrary(true); + initGame(game); + games.add(game); + } + +} diff --git a/Mage.Server.Plugins/Mage.Game.FreeForAll/pom.xml b/Mage.Server.Plugins/Mage.Game.FreeForAll/pom.xml index 40846d6d870..a608c789705 100644 --- a/Mage.Server.Plugins/Mage.Game.FreeForAll/pom.xml +++ b/Mage.Server.Plugins/Mage.Game.FreeForAll/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-game-freeforall diff --git a/Mage.Server.Plugins/Mage.Game.TinyLeadersDuel/pom.xml b/Mage.Server.Plugins/Mage.Game.TinyLeadersDuel/pom.xml index 84a07a702c4..7f1ff12438f 100644 --- a/Mage.Server.Plugins/Mage.Game.TinyLeadersDuel/pom.xml +++ b/Mage.Server.Plugins/Mage.Game.TinyLeadersDuel/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-game-tinyleadersduel diff --git a/Mage.Server.Plugins/Mage.Game.TwoPlayerDuel/pom.xml b/Mage.Server.Plugins/Mage.Game.TwoPlayerDuel/pom.xml index b5d97c415da..7c6e74649f0 100644 --- a/Mage.Server.Plugins/Mage.Game.TwoPlayerDuel/pom.xml +++ b/Mage.Server.Plugins/Mage.Game.TwoPlayerDuel/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-game-twoplayerduel diff --git a/Mage.Server.Plugins/Mage.Player.AI.DraftBot/pom.xml b/Mage.Server.Plugins/Mage.Player.AI.DraftBot/pom.xml index 893420512a1..bf21ad2d2fe 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.DraftBot/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.AI.DraftBot/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-ai-draftbot diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/pom.xml b/Mage.Server.Plugins/Mage.Player.AI.MA/pom.xml index 2f9afe8a97e..4495a41f8a6 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-ai-ma diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ComputerPlayer6.java b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ComputerPlayer6.java index da899f41f40..66fc062f4d7 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ComputerPlayer6.java +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ComputerPlayer6.java @@ -27,16 +27,43 @@ */ package mage.player.ai; +import java.io.File; +import java.util.ArrayList; +import java.util.Collections; +import java.util.Comparator; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedList; +import java.util.List; +import java.util.Map; +import java.util.Random; +import java.util.Scanner; +import java.util.Set; +import java.util.UUID; +import java.util.concurrent.Callable; +import java.util.concurrent.ExecutionException; +import java.util.concurrent.ExecutorService; +import java.util.concurrent.Executors; +import java.util.concurrent.FutureTask; +import java.util.concurrent.TimeUnit; +import java.util.concurrent.TimeoutException; import mage.abilities.Ability; import mage.abilities.ActivatedAbility; import mage.abilities.SpellAbility; import mage.abilities.common.PassAbility; import mage.abilities.effects.Effect; import mage.abilities.effects.SearchEffect; -import mage.abilities.keyword.*; +import mage.abilities.keyword.DeathtouchAbility; +import mage.abilities.keyword.DoubleStrikeAbility; +import mage.abilities.keyword.ExaltedAbility; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.IndestructibleAbility; +import mage.abilities.keyword.ReachAbility; import mage.cards.Card; import mage.cards.Cards; import mage.choices.Choice; +import mage.constants.AbilityType; import mage.constants.Outcome; import mage.constants.PhaseStep; import mage.constants.RangeOfInfluence; @@ -47,7 +74,25 @@ import mage.game.events.GameEvent; import mage.game.permanent.Permanent; import mage.game.stack.StackAbility; import mage.game.stack.StackObject; -import mage.game.turn.*; +import mage.game.turn.BeginCombatStep; +import mage.game.turn.BeginningPhase; +import mage.game.turn.CleanupStep; +import mage.game.turn.CombatDamageStep; +import mage.game.turn.CombatPhase; +import mage.game.turn.DeclareAttackersStep; +import mage.game.turn.DeclareBlockersStep; +import mage.game.turn.DrawStep; +import mage.game.turn.EndOfCombatStep; +import mage.game.turn.EndPhase; +import mage.game.turn.EndStep; +import mage.game.turn.FirstCombatDamageStep; +import mage.game.turn.Phase; +import mage.game.turn.PostCombatMainPhase; +import mage.game.turn.PostCombatMainStep; +import mage.game.turn.PreCombatMainPhase; +import mage.game.turn.PreCombatMainStep; +import mage.game.turn.UntapStep; +import mage.game.turn.UpkeepStep; import mage.player.ai.ma.optimizers.TreeOptimizer; import mage.player.ai.ma.optimizers.impl.DiscardCardOptimizer; import mage.player.ai.ma.optimizers.impl.EquipOptimizer; @@ -60,11 +105,6 @@ import mage.target.Target; import mage.target.TargetCard; import mage.target.Targets; -import java.io.File; -import java.util.*; -import java.util.concurrent.*; -import mage.constants.AbilityType; - /** * * @author nantuko @@ -89,6 +129,7 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { protected int lastLoggedTurn = 0; Random random = new Random(); protected static final String BLANKS = "..............................................."; + static { optimizers.add(new LevelUpOptimizer()); optimizers.add(new EquipOptimizer()); @@ -316,7 +357,6 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { * attack with any of them // let's try once again to avoid * possible horizon effect return false; } } */ - logger.info("simulating -- continuing previous action chain"); actions = new LinkedList<>(root.abilities); combat = root.combat; @@ -523,9 +563,10 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { List allActions = currentPlayer.simulatePriority(game); optimize(game, allActions); if (logger.isInfoEnabled() && allActions.size() > 0 && depth == maxDepth) { - logger.info("Sim Prio [" + depth + "] player " + currentPlayer.getName() + " adding " + allActions.size() + " actions:" + allActions); + logger.info("ADDED ACTIONS (" + allActions.size() + ") " + " " + allActions); } int counter = 0; + int bestValSubNodes = Integer.MIN_VALUE; for (Ability action : allActions) { counter++; if (ALLOW_INTERRUPT && Thread.interrupted()) { @@ -553,15 +594,14 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { sim.checkStateAndTriggered(); int val; if (action instanceof PassAbility) { - // Stop to simulate deeper if PassAbility + // Stop to simulate deeper if PassAbility val = GameStateEvaluator2.evaluate(this.getId(), sim); // logger.info("evaluate = " + val ); } else { val = addActions(newNode, depth - 1, alpha, beta); -// logger.info("addAction = " + val ); } - logger.debug("Sim Prio " + BLANKS.substring(0, 2 + (maxDepth-depth) * 3)+ "["+depth+"]#"+counter+" <" + val +"> - ("+action.toString()+") "+newNode.hashCode()+" parent node "+node.hashCode()); - if (logger.isInfoEnabled() && depth == maxDepth) { + logger.debug("Sim Prio " + BLANKS.substring(0, 2 + (maxDepth - depth) * 3) + "[" + depth + "]#" + counter + " <" + val + "> - (" + action.toString() + ") "); + if (logger.isInfoEnabled() && depth >= maxDepth) { StringBuilder sb = new StringBuilder("Sim Prio [").append(depth).append("] #").append(counter) .append(" <").append(val).append("> (").append(action) .append(action.isModal() ? " Mode = " + action.getModes().getMode().toString() : "") @@ -578,6 +618,9 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { } if (currentPlayer.getId().equals(playerId)) { + if (val > bestValSubNodes) { + bestValSubNodes = val; + } if (depth == maxDepth && action instanceof PassAbility) { val = val - PASSIVITY_PENALTY; // passivity penalty } @@ -594,7 +637,7 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { * choices = node.getChoices(); */ if (depth == maxDepth) { - logger.info(new StringBuilder("Sim Prio [").append(depth).append("] -- Saved best node yet <").append(bestNode.getScore()).append("> ").append(bestNode.getAbilities().toString()).toString()); + logger.info("Sim Prio [" + depth + "] -- Saved best node yet <" + bestNode.getScore() + "> " + bestNode.getAbilities().toString()); node.children.clear(); node.children.add(bestNode); node.setScore(bestNode.getScore()); @@ -652,7 +695,7 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { } */ //logger.info("returning priority alpha: " + alpha); - return alpha; + return bestValSubNodes; } else { // if (beta == Integer.MAX_VALUE) { // int val = GameStateEvaluator2.evaluate(playerId, game); @@ -861,7 +904,6 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { CombatUtil.sortByPower(attackers, false); //this is where my code goes - CombatInfo combatInfo = CombatUtil.blockWithGoodTrade2(game, attackers, possibleBlockers); Player player = game.getPlayer(this.playerId); @@ -995,7 +1037,6 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { } //CombatUtil.handleExalted(); - //TODO: refactor -- extract to method //List counterAttackList = new ArrayList(); //int counterAttackDamage = 0; @@ -1107,10 +1148,8 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { * (totalFirstStrikeBlockPower < attacker.getToughness().getValue()) * ) { finalAttackers.add(attacker); } } */ - // The AI will now attack more sanely. Simple, but good enough for now. - // The sim minmax does not work at the moment. - + // The sim minmax does not work at the moment. boolean safeToAttack; CombatEvaluator eval = new CombatEvaluator(); @@ -1418,7 +1457,7 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { if (powerLeftToKill <= 0) { return blockers.iterator().next().getId(); } - for (Permanent blocker: blockers) { + for (Permanent blocker : blockers) { if (attackerDeathtouch || powerLeftToKill >= blocker.getToughness().getValue()) { if (!blocker.getAbilities().containsKey(IndestructibleAbility.getInstance().getId())) { return blocker.getId(); @@ -1435,7 +1474,7 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { private List getAlreadyBlockingPermanents(List blockerOrder, Game game) { List blockerAlreadySet = new ArrayList<>(); - for (UUID uuid :blockerOrder) { + for (UUID uuid : blockerOrder) { Permanent permanent = game.getPermanent(uuid); if (permanent != null) { blockerAlreadySet.add(permanent); @@ -1455,5 +1494,4 @@ public class ComputerPlayer6 extends ComputerPlayer /*implements Player*/ { return toughnessAlreadyNeeded; } - } diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/GameStateEvaluator2.java b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/GameStateEvaluator2.java index 52b99359a6e..0e2c9f409c1 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/GameStateEvaluator2.java +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/GameStateEvaluator2.java @@ -2,7 +2,6 @@ * To change this template, choose Tools | Templates * and open the template in the editor. */ - package mage.player.ai; import java.util.UUID; @@ -60,21 +59,21 @@ public class GameStateEvaluator2 { StringBuilder sbPlayer = new StringBuilder(); StringBuilder sbOpponent = new StringBuilder(); // add values of player - for (Permanent permanent: game.getBattlefield().getAllActivePermanents(playerId)) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents(playerId)) { int onePermScore = evaluatePermanent(permanent, game); playerScore += onePermScore; if (logger.isDebugEnabled()) { sbPlayer.append(permanent.getName()).append("[").append(onePermScore).append("] "); } } - if (logger.isDebugEnabled()) { + if (logger.isDebugEnabled()) { sbPlayer.insert(0, playerScore + " - "); sbPlayer.insert(0, "Player..: "); logger.debug(sbPlayer); } // add values of opponent - for (Permanent permanent: game.getBattlefield().getAllActivePermanents(opponent.getId())) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents(opponent.getId())) { int onePermScore = evaluatePermanent(permanent, game); opponentScore += onePermScore; if (logger.isDebugEnabled()) { @@ -84,7 +83,7 @@ public class GameStateEvaluator2 { if (logger.isDebugEnabled()) { sbOpponent.insert(0, opponentScore + " - "); sbOpponent.insert(0, "Opponent: "); - + logger.debug(sbOpponent); } permanentScore = playerScore - opponentScore; @@ -97,28 +96,28 @@ public class GameStateEvaluator2 { handScore *= 5; int score = lifeScore + permanentScore + handScore; - logger.debug(score + " total Score (life:" + lifeScore + " permanents:" + permanentScore + " hand:" + handScore +")"); + logger.debug(score + " total Score (life:" + lifeScore + " permanents:" + permanentScore + " hand:" + handScore + ")"); return score; } public static int evaluatePermanent(Permanent permanent, Game game) { /*int value = permanent.isTapped()?4:5; - if (permanent.getCardType().contains(CardType.CREATURE)) { - value += evaluateCreature(permanent, game) * CREATURE_FACTOR; - } - value += permanent.getAbilities().getManaAbilities(Zone.BATTLEFIELD).size(); - for (ActivatedAbility ability: permanent.getAbilities().getActivatedAbilities(Zone.BATTLEFIELD)) { - if (!(ability instanceof ManaAbility) && ability.canActivate(ability.getControllerId(), game)) - value += ability.getEffects().size(); - } - value += permanent.getAbilities().getStaticAbilities(Zone.BATTLEFIELD).size(); - value += permanent.getAbilities().getTriggeredAbilities(Zone.BATTLEFIELD).size(); - value += permanent.getManaCost().convertedManaCost(); - */ + if (permanent.getCardType().contains(CardType.CREATURE)) { + value += evaluateCreature(permanent, game) * CREATURE_FACTOR; + } + value += permanent.getAbilities().getManaAbilities(Zone.BATTLEFIELD).size(); + for (ActivatedAbility ability: permanent.getAbilities().getActivatedAbilities(Zone.BATTLEFIELD)) { + if (!(ability instanceof ManaAbility) && ability.canActivate(ability.getControllerId(), game)) + value += ability.getEffects().size(); + } + value += permanent.getAbilities().getStaticAbilities(Zone.BATTLEFIELD).size(); + value += permanent.getAbilities().getTriggeredAbilities(Zone.BATTLEFIELD).size(); + value += permanent.getManaCost().convertedManaCost(); + */ int value = ArtificialScoringSystem.getFixedPermanentScore(game, permanent) - + ArtificialScoringSystem.getVariablePermanentScore(game, permanent); + + ArtificialScoringSystem.getVariablePermanentScore(game, permanent); //TODO: add a difficulty to calculation to ManaCost - sort permanents by difficulty for casting when evaluating game states return value; @@ -126,21 +125,20 @@ public class GameStateEvaluator2 { public static int evaluateCreature(Permanent creature, Game game) { int value = ArtificialScoringSystem.getFixedPermanentScore(game, creature) - + ArtificialScoringSystem.getVariablePermanentScore(game, creature); + + ArtificialScoringSystem.getVariablePermanentScore(game, creature); /*int value = 0; - value += creature.getPower().getValue(); - value += creature.getToughness().getValue(); -// if (creature.canAttack(game)) -// value += creature.getPower().getValue(); -// if (!creature.isTapped()) -// value += 2; - value += creature.getAbilities().getEvasionAbilities().size(); - value += creature.getAbilities().getProtectionAbilities().size(); - value += creature.getAbilities().containsKey(FirstStrikeAbility.getInstance().getId())?1:0; - value += creature.getAbilities().containsKey(DoubleStrikeAbility.getInstance().getId())?2:0; - value += creature.getAbilities().containsKey(TrampleAbility.getInstance().getId())?1:0;*/ - + value += creature.getPower().getValue(); + value += creature.getToughness().getValue(); + // if (creature.canAttack(game)) + // value += creature.getPower().getValue(); + // if (!creature.isTapped()) + // value += 2; + value += creature.getAbilities().getEvasionAbilities().size(); + value += creature.getAbilities().getProtectionAbilities().size(); + value += creature.getAbilities().containsKey(FirstStrikeAbility.getInstance().getId())?1:0; + value += creature.getAbilities().containsKey(DoubleStrikeAbility.getInstance().getId())?2:0; + value += creature.getAbilities().containsKey(TrampleAbility.getInstance().getId())?1:0;*/ return value; } diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulatedPlayer2.java b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulatedPlayer2.java index 40e947230c6..419a33a0b53 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulatedPlayer2.java +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulatedPlayer2.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.player.ai; import java.util.ArrayList; @@ -37,6 +36,7 @@ import java.util.List; import java.util.Map; import java.util.UUID; import java.util.concurrent.ConcurrentLinkedQueue; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.TriggeredAbility; import mage.abilities.common.PassAbility; @@ -108,11 +108,16 @@ public class SimulatedPlayer2 extends ComputerPlayer { if (logger.isTraceEnabled()) { for (Ability a : allActions) { - logger.trace("ability==" + a); + logger.info("ability==" + a); if (a.getTargets().size() > 0) { - Player player = game.getPlayer(a.getFirstTarget()); - if (player != null) { - logger.trace(" target="+player.getName()); + MageObject mageObject = game.getObject(a.getFirstTarget()); + if (mageObject != null) { + logger.info(" target=" + mageObject.getName()); + } else { + Player player = game.getPlayer(a.getFirstTarget()); + if (player != null) { + logger.info(" target=" + player.getName()); + } } } } @@ -124,26 +129,19 @@ public class SimulatedPlayer2 extends ComputerPlayer { protected void simulateOptions(Game game) { List playables = game.getPlayer(playerId).getPlayable(game, isSimulatedPlayer); playables = filterAbilities(game, playables, suggested); - for (Ability ability: playables) { + for (Ability ability : playables) { if (ability.getAbilityType().equals(AbilityType.MANA)) { continue; } List options = game.getPlayer(playerId).getPlayableOptions(ability, game); - options = filterOptions(game, options, ability, suggested); + options = filterOptions(game, options, ability, suggested); options = optimizeOptions(game, options, ability); if (options.isEmpty()) { - allActions.add(ability); -// simulateAction(game, previousActions, ability); - } - else { -// ExecutorService simulationExecutor = Executors.newFixedThreadPool(4); - for (Ability option: options) { - allActions.add(option); -// SimulationWorker worker = new SimulationWorker(game, this, previousActions, option); -// simulationExecutor.submit(worker); + allActions.add(ability); + } else { + for (Ability option : options) { + allActions.add(option); } -// simulationExecutor.shutdown(); -// while(!simulationExecutor.isTerminated()) {} } } } @@ -157,7 +155,7 @@ public class SimulatedPlayer2 extends ComputerPlayer { if (card != null && numAvailable > 0) { // check if variable mana costs is included and get the multiplier VariableManaCost variableManaCost = null; - for (ManaCost cost: ability.getManaCostsToPay()) { + for (ManaCost cost : ability.getManaCostsToPay()) { if (cost instanceof VariableManaCost && !cost.isPaid()) { variableManaCost = (VariableManaCost) cost; break; // only one VariableManCost per spell (or is it possible to have more?) @@ -171,7 +169,7 @@ public class SimulatedPlayer2 extends ComputerPlayer { int xAmount = mana / multiplier; Ability newAbility = ability.copy(); VariableManaCost varCost = null; - for (ManaCost cost: newAbility.getManaCostsToPay()) { + for (ManaCost cost : newAbility.getManaCostsToPay()) { if (cost instanceof VariableManaCost && !cost.isPaid()) { varCost = (VariableManaCost) cost; break; // only one VariableManCost per spell (or is it possible to have more?) @@ -207,7 +205,6 @@ public class SimulatedPlayer2 extends ComputerPlayer { // allActions.add(new SimulatedAction(sim, actions)); // } // } - /** * if suggested abilities exist, return only those from playables * @@ -253,7 +250,7 @@ public class SimulatedPlayer2 extends ComputerPlayer { Card card = game.getCard(ability.getSourceId()); for (String s : suggested) { String[] groups = s.split(";"); - logger.trace("s="+s+";groups="+groups.length); + logger.trace("s=" + s + ";groups=" + groups.length); if (groups.length == 2) { if (groups[0].equals(card.getName()) && groups[1].startsWith("name=")) { // extract target and compare to suggested @@ -299,10 +296,10 @@ public class SimulatedPlayer2 extends ComputerPlayer { } if (bad) { - // remove its own creatures, player itself for bad effects + // remove its own creatures, player itself for bad effects with one target while (iterator.hasNext()) { Ability ability1 = iterator.next(); - if (ability1.getTargets().size() == 1) { + if (ability1.getTargets().size() == 1 && ability1.getTargets().get(0).getTargets().size() == 1) { Permanent permanent = game.getPermanent(ability1.getFirstTarget()); if (permanent != null && !game.getOpponents(playerId).contains(permanent.getControllerId())) { iterator.remove(); @@ -315,10 +312,10 @@ public class SimulatedPlayer2 extends ComputerPlayer { } } if (good) { - // remove opponent creatures and opponent for only good effects + // remove opponent creatures and opponent for only good effects with one target while (iterator.hasNext()) { Ability ability1 = iterator.next(); - if (ability1.getTargets().size() == 1) { + if (ability1.getTargets().size() == 1 && ability1.getTargets().get(0).getTargets().size() == 1) { Permanent permanent = game.getPermanent(ability1.getFirstTarget()); if (permanent != null && game.getOpponents(playerId).contains(permanent.getControllerId())) { iterator.remove(); @@ -330,7 +327,7 @@ public class SimulatedPlayer2 extends ComputerPlayer { } } } - + return options; } @@ -352,15 +349,14 @@ public class SimulatedPlayer2 extends ComputerPlayer { for (int j = 0; j < attackersList.size(); j++) { if (binary.charAt(j) == '1') { setStoredBookmark(sim.bookmarkState()); // makes it possible to UNDO a declared attacker with costs from e.g. Propaganda - if(!sim.getCombat().declareAttacker(attackersList.get(j).getId(), defenderId, playerId, sim)) { + if (!sim.getCombat().declareAttacker(attackersList.get(j).getId(), defenderId, playerId, sim)) { sim.undo(playerId); - } + } } } if (engagements.put(sim.getCombat().getValue().hashCode(), sim.getCombat()) != null) { logger.debug("simulating -- found redundant attack combination"); - } - else { + } else { logger.debug("simulating -- attack:" + sim.getCombat().getGroups().size()); } } @@ -424,15 +420,14 @@ public class SimulatedPlayer2 extends ComputerPlayer { ability.activate(game, false); game.applyEffects(); game.getPlayers().resetPassed(); - } - else { + } else { SimulationNode2 parent = (SimulationNode2) game.getCustomData(); int depth = parent.getDepth() - 1; if (depth == 0) { return true; } logger.debug("simulating -- triggered ability - adding children:" + options.size()); - for (Ability option: options) { + for (Ability option : options) { addAbilityNode(parent, option, depth, game); } } @@ -446,12 +441,12 @@ public class SimulatedPlayer2 extends ComputerPlayer { sim.applyEffects(); SimulationNode2 newNode = new SimulationNode2(parent, sim, depth, playerId); logger.debug("simulating -- node #:" + SimulationNode2.getCount() + " triggered ability option"); - for (Target target: ability.getTargets()) { - for (UUID targetId: target.getTargets()) { + for (Target target : ability.getTargets()) { + for (UUID targetId : target.getTargets()) { newNode.getTargets().add(targetId); } } - for (Choice choice: ability.getChoices()) { + for (Choice choice : ability.getChoices()) { newNode.getChoices().add(choice.getChoice()); } parent.children.add(newNode); @@ -463,5 +458,4 @@ public class SimulatedPlayer2 extends ComputerPlayer { return false; } - } diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulationNode2.java b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulationNode2.java index b5e1fef4400..bbbf1f05c2f 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulationNode2.java +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/SimulationNode2.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.player.ai; import java.io.Serializable; @@ -49,10 +48,10 @@ public class SimulationNode2 implements Serializable { protected int score; protected List abilities; protected int depth; - protected List children = new ArrayList(); + protected List children = new ArrayList<>(); protected SimulationNode2 parent; - protected List targets = new ArrayList(); - protected List choices = new ArrayList(); + protected List targets = new ArrayList<>(); + protected List choices = new ArrayList<>(); protected UUID playerId; protected Combat combat; @@ -72,7 +71,7 @@ public class SimulationNode2 implements Serializable { public SimulationNode2(SimulationNode2 parent, Game game, Ability ability, int depth, UUID playerId) { this(parent, game, depth, playerId); - this.abilities = new ArrayList(); + this.abilities = new ArrayList<>(); abilities.add(ability); } diff --git a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ma/ArtificialScoringSystem.java b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ma/ArtificialScoringSystem.java index 4c008d09ff8..abaa31aaf60 100644 --- a/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ma/ArtificialScoringSystem.java +++ b/Mage.Server.Plugins/Mage.Player.AI.MA/src/mage/player/ai/ma/ArtificialScoringSystem.java @@ -1,24 +1,23 @@ package mage.player.ai.ma; +import java.util.UUID; import mage.abilities.Ability; +import mage.abilities.effects.Effect; import mage.abilities.keyword.HasteAbility; import mage.cards.Card; import mage.constants.CardType; +import mage.constants.Outcome; import mage.counters.CounterType; import mage.game.Game; import mage.game.permanent.Permanent; -import java.util.UUID; -import mage.constants.Outcome; -import mage.abilities.effects.Effect; - /** * @author ubeefx, nantuko */ public class ArtificialScoringSystem { - public static final int WIN_GAME_SCORE=100000000; - public static final int LOSE_GAME_SCORE=-WIN_GAME_SCORE; + public static final int WIN_GAME_SCORE = 100000000; + public static final int LOSE_GAME_SCORE = -WIN_GAME_SCORE; private static final int LIFE_SCORES[] = {0, 1000, 2000, 3000, 4000, 4500, 5000, 5500, 6000, 6500, 7000, 7400, 7800, 8200, 8600, 9000, 9200, 9400, 9600, 9800, 10000}; private static final int MAX_LIFE = LIFE_SCORES.length - 1; @@ -33,9 +32,9 @@ public class ArtificialScoringSystem { //TODO: check this for "any color" lands //TODO: check this for dual and filter lands /*for (Mana mana : card.getMana()) { - score += 50; - }*/ - score += card.getMana().size()*50; + score += 50; + }*/ + score += card.getMana().size() * 50; return score; } @@ -43,19 +42,19 @@ public class ArtificialScoringSystem { if (card.getCardType().contains(CardType.CREATURE)) { return score + (card.getPower().getValue() + card.getToughness().getValue()) * 10; } else { - return score + (/*card.getRemoval()*50*/ +card.getRarity().getRating() * 30); + return score + (/*card.getRemoval()*50*/+card.getRarity().getRating() * 30); } } public static int getFixedPermanentScore(final Game game, final Permanent permanent) { //TODO: cache it inside Card int score = getCardDefinitionScore(game, permanent); + score += PERMANENT_SCORE; if (permanent.getCardType().contains(CardType.CREATURE)) { // TODO: implement in the mage core //score + =cardDefinition.getActivations().size()*50; //score += cardDefinition.getManaActivations().size()*80; } else { - score += PERMANENT_SCORE; if (permanent.getSubtype().contains("Equipment")) { score += 100; } @@ -101,7 +100,7 @@ public class ArtificialScoringSystem { } } } - score += equipments*50 + enchantments*100; + score += equipments * 50 + enchantments * 100; if (!permanent.canAttack(game)) { score -= 100; @@ -116,9 +115,9 @@ public class ArtificialScoringSystem { private static boolean canTap(Permanent permanent) { return !permanent.isTapped() - &&(!permanent.hasSummoningSickness() - ||!permanent.getCardType().contains(CardType.CREATURE) - ||permanent.getAbilities().contains(HasteAbility.getInstance())); + && (!permanent.hasSummoningSickness() + || !permanent.getCardType().contains(CardType.CREATURE) + || permanent.getAbilities().contains(HasteAbility.getInstance())); } private static int getPositive(int value) { @@ -152,23 +151,23 @@ public class ArtificialScoringSystem { public static int getAttackerScore(final Permanent attacker) { //TODO: implement this /*int score = attacker.getPower().getValue() * 5 + attacker.lethalDamage * 2 - attacker.candidateBlockers.length; - for (final MagicCombatCreature blocker : attacker.candidateBlockers) { + for (final MagicCombatCreature blocker : attacker.candidateBlockers) { - score -= blocker.power; - } - // Dedicated attacker. - if (attacker.hasAbility(MagicAbility.AttacksEachTurnIfAble) || attacker.hasAbility(MagicAbility.CannotBlock)) { - score += 10; - } - // Abilities for attacking. - if (attacker.hasAbility(MagicAbility.Trample) || attacker.hasAbility(MagicAbility.Vigilance)) { - score += 8; - } - // Dangerous to block. - if (!attacker.normalDamage || attacker.hasAbility(MagicAbility.FirstStrike) || attacker.hasAbility(MagicAbility.Indestructible)) { - score += 7; - } - */ + score -= blocker.power; + } + // Dedicated attacker. + if (attacker.hasAbility(MagicAbility.AttacksEachTurnIfAble) || attacker.hasAbility(MagicAbility.CannotBlock)) { + score += 10; + } + // Abilities for attacking. + if (attacker.hasAbility(MagicAbility.Trample) || attacker.hasAbility(MagicAbility.Vigilance)) { + score += 8; + } + // Dangerous to block. + if (!attacker.normalDamage || attacker.hasAbility(MagicAbility.FirstStrike) || attacker.hasAbility(MagicAbility.Indestructible)) { + score += 7; + } + */ int score = 0; return score; } diff --git a/Mage.Server.Plugins/Mage.Player.AI/pom.xml b/Mage.Server.Plugins/Mage.Player.AI/pom.xml index 2aa9ab4e65a..51788aff21a 100644 --- a/Mage.Server.Plugins/Mage.Player.AI/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.AI/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-ai diff --git a/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/Attackers.java b/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/Attackers.java index a20c15f41da..d64d08900b7 100644 --- a/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/Attackers.java +++ b/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/Attackers.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.player.ai; import java.util.ArrayList; @@ -40,9 +39,9 @@ import mage.game.permanent.Permanent; public class Attackers extends TreeMap> { public List getAttackers() { - List attackers = new ArrayList(); - for (List l: this.values()) { - for (Permanent permanent: l) { + List attackers = new ArrayList<>(); + for (List l : this.values()) { + for (Permanent permanent : l) { attackers.add(permanent); } } diff --git a/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/ComputerPlayer.java b/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/ComputerPlayer.java index 57c42140b9b..9670c6f17f5 100644 --- a/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/ComputerPlayer.java +++ b/Mage.Server.Plugins/Mage.Player.AI/src/main/java/mage/player/ai/ComputerPlayer.java @@ -74,6 +74,7 @@ import mage.abilities.mana.ManaAbility; import mage.abilities.mana.ManaOptions; import mage.cards.Card; import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.cards.decks.Deck; import mage.cards.repository.CardCriteria; import mage.cards.repository.CardInfo; @@ -82,6 +83,7 @@ import mage.cards.repository.ExpansionInfo; import mage.cards.repository.ExpansionRepository; import mage.choices.Choice; import mage.choices.ChoiceColor; +import mage.constants.AsThoughEffectType; import mage.constants.CardType; import mage.constants.ColoredManaSymbol; import mage.constants.Outcome; @@ -160,7 +162,7 @@ public class ComputerPlayer extends PlayerImpl implements Player { private transient final static Logger log = Logger.getLogger(ComputerPlayer.class); protected int PASSIVITY_PENALTY = 5; // Penalty value for doing nothing if some actions are availble - protected boolean ALLOW_INTERRUPT = true; // change this for test purposes to switch off interrupts while debugging + protected boolean ALLOW_INTERRUPT = true; // change this for test / debugging purposes to false to switch off interrupts while debugging private transient Map unplayable = new TreeMap<>(); private transient List playableNonInstant = new ArrayList<>(); @@ -300,12 +302,25 @@ public class ComputerPlayer extends PlayerImpl implements Player { } for (Permanent permanent : targets) { if (((TargetPermanent) target).canTarget(abilityControllerId, permanent.getId(), null, game) && !target.getTargets().contains(permanent.getId())) { + // stop to add targets if not needed and outcome is no advantage for AI player + if (target.getNumberOfTargets() == target.getTargets().size()) { + if (outcome.isGood() && hasOpponent(permanent.getControllerId(), game)) { + return true; + } + if (!outcome.isGood() && !hasOpponent(permanent.getControllerId(), game)) { + return true; + } + } + // add the target target.add(permanent.getId(), game); - return true; + if (target.doneChosing()) { + return true; + } } } - return false; + return target.isChosen(); } + if (target instanceof TargetCardInHand) { List cards = new ArrayList<>(); for (UUID cardId : ((TargetCardInHand) target).possibleTargets(sourceId, this.getId(), game)) { @@ -508,8 +523,11 @@ public class ComputerPlayer extends PlayerImpl implements Player { } if (target instanceof TargetDiscard || target instanceof TargetCardInHand) { if (outcome.isGood()) { - ArrayList cardsInHand = new ArrayList<>(hand.getCards(game)); - while (!target.isChosen() && !cardsInHand.isEmpty() && target.getMaxNumberOfTargets() > target.getTargets().size()) { + Cards cards = new CardsImpl(target.possibleTargets(source.getSourceId(), getId(), game)); + ArrayList cardsInHand = new ArrayList<>(cards.getCards(game)); + while (!target.isChosen() + && target.possibleTargets(source.getSourceId(), getId(), game).size() > 0 + && target.getMaxNumberOfTargets() > target.getTargets().size()) { Card card = pickBestCard(cardsInHand, null, target, source, game); if (card != null) { if (target.canTarget(getId(), card.getId(), source, game)) { @@ -670,17 +688,6 @@ public class ComputerPlayer extends PlayerImpl implements Player { } return target.isChosen(); } - if (target instanceof TargetCardInHand) { - List cards = new ArrayList<>(); - cards.addAll(this.hand.getCards(game)); - while (!target.isChosen() && !cards.isEmpty()) { - Card pick = pickTarget(cards, outcome, target, source, game); - if (pick != null) { - target.addTarget(pick.getId(), source, game); - } - } - return target.isChosen(); - } if (target instanceof TargetSpell) { if (game.getStack().size() > 0) { Iterator it = game.getStack().iterator(); @@ -1116,21 +1123,23 @@ public class ComputerPlayer extends PlayerImpl implements Player { } @Override - public boolean playMana(ManaCost unpaid, String promptText, Game game) { + public boolean playMana(Ability ability, ManaCost unpaid, String promptText, Game game) { payManaMode = true; currentUnpaidMana = unpaid; - boolean result = playManaHandling(unpaid, game); + boolean result = playManaHandling(ability, unpaid, game); currentUnpaidMana = null; payManaMode = false; return result; } - protected boolean playManaHandling(ManaCost unpaid, Game game) { + protected boolean playManaHandling(Ability ability, ManaCost unpaid, Game game) { // log.info("paying for " + unpaid.getText()); + boolean spendAnyMana = game.getContinuousEffects().asThough(ability.getSourceId(), AsThoughEffectType.SPEND_ANY_MANA, ability, ability.getControllerId(), game); ManaCost cost; List producers; if (unpaid instanceof ManaCosts) { - cost = ((ManaCosts) unpaid).get(0); + ManaCosts manaCosts = (ManaCosts) unpaid; + cost = manaCosts.get(manaCosts.size() - 1); producers = getSortedProducers((ManaCosts) unpaid, game); } else { cost = unpaid; @@ -1138,12 +1147,37 @@ public class ComputerPlayer extends PlayerImpl implements Player { producers.addAll(this.getAvailableManaProducersWithCost(game)); } for (Permanent perm : producers) { - // pay all colored costs first - for (ManaAbility ability : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { - if (cost instanceof ColoredManaCost) { - for (Mana netMana : ability.getNetMana(game)) { + // use color producing mana abilities with costs first that produce all color manas that are needed to pay + // otherwise the computer may not be able to pay the cost for that source + ManaAbility: + for (ManaAbility manaAbility : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { + int colored = 0; + for (Mana mana : manaAbility.getNetMana(game)) { + if (!unpaid.getMana().includesMana(mana)) { + continue ManaAbility; + } + colored += mana.countColored(); + } + if (colored > 1 && (cost instanceof ColoredManaCost)) { + + for (Mana netMana : manaAbility.getNetMana(game)) { if (cost.testPay(netMana)) { - if (activateAbility(ability, game)) { + if (activateAbility(manaAbility, game)) { + return true; + } + } + } + } + } + } + + for (Permanent perm : producers) { + // pay all colored costs first + for (ManaAbility manaAbility : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { + if (cost instanceof ColoredManaCost) { + for (Mana netMana : manaAbility.getNetMana(game)) { + if (cost.testPay(netMana) || spendAnyMana) { + if (activateAbility(manaAbility, game)) { return true; } } @@ -1151,11 +1185,11 @@ public class ComputerPlayer extends PlayerImpl implements Player { } } // then pay hybrid - for (ManaAbility ability : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { + for (ManaAbility manaAbility : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { if (cost instanceof HybridManaCost) { - for (Mana netMana : ability.getNetMana(game)) { - if (cost.testPay(netMana)) { - if (activateAbility(ability, game)) { + for (Mana netMana : manaAbility.getNetMana(game)) { + if (cost.testPay(netMana) || spendAnyMana) { + if (activateAbility(manaAbility, game)) { return true; } } @@ -1163,11 +1197,11 @@ public class ComputerPlayer extends PlayerImpl implements Player { } } // then pay mono hybrid - for (ManaAbility ability : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { + for (ManaAbility manaAbility : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { if (cost instanceof MonoHybridManaCost) { - for (Mana netMana : ability.getNetMana(game)) { - if (cost.testPay(netMana)) { - if (activateAbility(ability, game)) { + for (Mana netMana : manaAbility.getNetMana(game)) { + if (cost.testPay(netMana) || spendAnyMana) { + if (activateAbility(manaAbility, game)) { return true; } } @@ -1175,11 +1209,11 @@ public class ComputerPlayer extends PlayerImpl implements Player { } } // finally pay generic - for (ManaAbility ability : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { + for (ManaAbility manaAbility : perm.getAbilities().getAvailableManaAbilities(Zone.BATTLEFIELD, game)) { if (cost instanceof GenericManaCost) { - for (Mana netMana : ability.getNetMana(game)) { - if (cost.testPay(netMana)) { - if (activateAbility(ability, game)) { + for (Mana netMana : manaAbility.getNetMana(game)) { + if (cost.testPay(netMana) || spendAnyMana) { + if (activateAbility(manaAbility, game)) { return true; } } @@ -1189,7 +1223,7 @@ public class ComputerPlayer extends PlayerImpl implements Player { } // pay phyrexian life costs if (cost instanceof PhyrexianManaCost) { - if (cost.pay(null, game, null, playerId, false)) { + if (cost.pay(null, game, null, playerId, false) || spendAnyMana) { return true; } } diff --git a/Mage.Server.Plugins/Mage.Player.AIMCTS/pom.xml b/Mage.Server.Plugins/Mage.Player.AIMCTS/pom.xml index d11572b64c7..62c8e069013 100644 --- a/Mage.Server.Plugins/Mage.Player.AIMCTS/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.AIMCTS/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-ai-mcts diff --git a/Mage.Server.Plugins/Mage.Player.AIMinimax/pom.xml b/Mage.Server.Plugins/Mage.Player.AIMinimax/pom.xml index aa551c80b76..696f0b3043f 100644 --- a/Mage.Server.Plugins/Mage.Player.AIMinimax/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.AIMinimax/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-aiminimax diff --git a/Mage.Server.Plugins/Mage.Player.Human/pom.xml b/Mage.Server.Plugins/Mage.Player.Human/pom.xml index 9dfaa3988b1..28493362e66 100644 --- a/Mage.Server.Plugins/Mage.Player.Human/pom.xml +++ b/Mage.Server.Plugins/Mage.Player.Human/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-player-human diff --git a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java index 0b26b8ea235..2ed5be13a9f 100644 --- a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java +++ b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java @@ -102,23 +102,25 @@ public class HumanPlayer extends PlayerImpl { protected static FilterCreatureForCombat filterCreatureForCombat = new FilterCreatureForCombat(); protected static FilterAttackingCreature filterAttack = new FilterAttackingCreature(); protected static FilterBlockingCreature filterBlock = new FilterBlockingCreature(); - protected static final Choice replacementEffectChoice = new ChoiceImpl(true); + protected final Choice replacementEffectChoice; private static final Logger log = Logger.getLogger(HumanPlayer.class); - static { - replacementEffectChoice.setMessage("Choose replacement effect to resolve first"); - } - protected HashSet autoSelectReplacementEffects = new HashSet<>(); + protected ManaCost currentlyUnpaidMana; public HumanPlayer(String name, RangeOfInfluence range, int skill) { super(name, range); + replacementEffectChoice = new ChoiceImpl(true); + replacementEffectChoice.setMessage("Choose replacement effect to resolve first"); human = true; } public HumanPlayer(final HumanPlayer player) { super(player); + this.autoSelectReplacementEffects.addAll(autoSelectReplacementEffects); + this.currentlyUnpaidMana = player.currentlyUnpaidMana; + this.replacementEffectChoice = player.replacementEffectChoice; } protected void waitForResponse(Game game) { @@ -248,6 +250,12 @@ public class HumanPlayer extends PlayerImpl { @Override public boolean choose(Outcome outcome, Choice choice, Game game) { + if (Outcome.PutManaInPool.equals(outcome)) { + if (currentlyUnpaidMana != null + && ManaUtil.tryToAutoSelectAManaColor(choice, currentlyUnpaidMana)) { + return true; + } + } updateGameStatePriority("choose(3)", game); while (!abort) { game.fireChooseChoiceEvent(playerId, choice); @@ -423,6 +431,7 @@ public class HumanPlayer extends PlayerImpl { if (!choosable.isEmpty()) { options.put("choosable", (Serializable) choosable); } + game.fireSelectTargetEvent(playerId, target.getMessage(), cards, required, options); waitForResponse(game); if (response.getUUID() != null) { @@ -506,7 +515,7 @@ public class HumanPlayer extends PlayerImpl { public boolean chooseTargetAmount(Outcome outcome, TargetAmount target, Ability source, Game game) { updateGameStatePriority("chooseTargetAmount", game); while (!abort) { - game.fireSelectTargetEvent(playerId, addSecondLineWithObjectName(target.getMessage() + "\n Amount remaining:" + target.getAmountRemaining(), source.getSourceId(), game), + game.fireSelectTargetEvent(playerId, addSecondLineWithObjectName(target.getMessage() + "\n Amount remaining:" + target.getAmountRemaining(), source == null ? null : source.getSourceId(), game), target.possibleTargets(source == null ? null : source.getSourceId(), playerId, game), target.isRequired(source), getOptions(target, null)); @@ -595,7 +604,7 @@ public class HumanPlayer extends PlayerImpl { passedUntilStackResolved = false; } } - while (isInGame()) { + while (canRespond()) { updateGameStatePriority("priority", game); game.firePriorityEvent(playerId); waitForResponse(game); @@ -674,7 +683,7 @@ public class HumanPlayer extends PlayerImpl { } @Override - public boolean playMana(ManaCost unpaid, String promptText, Game game) { + public boolean playMana(Ability ability, ManaCost unpaid, String promptText, Game game) { payManaMode = true; boolean result = playManaHandling(unpaid, promptText, game); payManaMode = false; @@ -689,7 +698,7 @@ public class HumanPlayer extends PlayerImpl { } game.firePlayManaEvent(playerId, "Pay " + promptText, options); waitForResponse(game); - if (!this.isInGame()) { + if (!this.canRespond()) { return false; } if (response.getBoolean() != null) { @@ -765,8 +774,10 @@ public class HumanPlayer extends PlayerImpl { if (zone != null) { LinkedHashMap useableAbilities = getUseableManaAbilities(object, zone, game); if (useableAbilities != null && useableAbilities.size() > 0) { - useableAbilities = ManaUtil.tryToAutoPay(unpaid, useableAbilities); + useableAbilities = ManaUtil.tryToAutoPay(unpaid, useableAbilities); // eliminates other abilities if one fits perfectly + currentlyUnpaidMana = unpaid; activateAbility(useableAbilities, object, game); + currentlyUnpaidMana = null; } } } @@ -1018,7 +1029,7 @@ public class HumanPlayer extends PlayerImpl { public void assignDamage(int damage, List targets, String singleTargetName, UUID sourceId, Game game) { updateGameStatePriority("assignDamage", game); int remainingDamage = damage; - while (remainingDamage > 0 && isInGame()) { + while (remainingDamage > 0 && canRespond()) { Target target = new TargetCreatureOrPlayer(); if (singleTargetName != null) { target.setTargetName(singleTargetName); @@ -1198,7 +1209,7 @@ public class HumanPlayer extends PlayerImpl { if (!source.getAbilityType().equals(AbilityType.TRIGGERED)) { done = true; } - if (!isInGame()) { + if (!canRespond()) { return null; } } diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/pom.xml b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/pom.xml index 92cd6907631..06efa02a054 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/pom.xml +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-tournament-boosterdraft diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/BensCube.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/BensCube.java index fd2982783ac..a22b0b7e2d0 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/BensCube.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/BensCube.java @@ -1,763 +1,762 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.tournament.cubes; - -import mage.game.draft.DraftCube; -import mage.game.draft.DraftCube.CardIdentity; - -/** - * - * @author LevelX2 - */ -public class BensCube extends DraftCube { - - public BensCube() { - super("Ben's Cube (720 cards)"); // http://cubetutor.com/viewcube/1 - cubeCards.add(new CardIdentity("Elite Vanguard", "")); - cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); - cubeCards.add(new CardIdentity("Isamaru, Hound of Konda", "")); - cubeCards.add(new CardIdentity("Mother of Runes", "")); - cubeCards.add(new CardIdentity("Soldier of the Pantheon", "")); - cubeCards.add(new CardIdentity("Steppe Lynx", "")); - cubeCards.add(new CardIdentity("Student of Warfare", "")); - cubeCards.add(new CardIdentity("Weathered Wayfarer", "")); - cubeCards.add(new CardIdentity("Accorder Paladin", "")); - cubeCards.add(new CardIdentity("Eight-and-a-Half-Tails", "")); - cubeCards.add(new CardIdentity("Imposing Sovereign", "")); - cubeCards.add(new CardIdentity("Kami of Ancient Law", "")); - cubeCards.add(new CardIdentity("Knight of Glory", "")); - cubeCards.add(new CardIdentity("Knight of Meadowgrain", "")); - cubeCards.add(new CardIdentity("Kor Skyfisher", "")); - cubeCards.add(new CardIdentity("Loyal Cathar", "")); - cubeCards.add(new CardIdentity("Soltari Monk", "")); - cubeCards.add(new CardIdentity("Soltari Priest", "")); - cubeCards.add(new CardIdentity("Stoneforge Mystic", "")); - cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben", "")); - cubeCards.add(new CardIdentity("Wall of Omens", "")); - cubeCards.add(new CardIdentity("Aven Mindcensor", "")); - cubeCards.add(new CardIdentity("Blade Splicer", "")); - cubeCards.add(new CardIdentity("Brimaz, King of Oreskos", "")); - cubeCards.add(new CardIdentity("Fiend Hunter", "")); - cubeCards.add(new CardIdentity("Flickerwisp", "")); - cubeCards.add(new CardIdentity("Kor Sanctifiers", "")); - cubeCards.add(new CardIdentity("Loyal Retainers", "")); - cubeCards.add(new CardIdentity("Mentor of the Meek", "")); - cubeCards.add(new CardIdentity("Mirran Crusader", "")); - cubeCards.add(new CardIdentity("Mirror Entity", "")); - cubeCards.add(new CardIdentity("Silverblade Paladin", "")); - cubeCards.add(new CardIdentity("Soltari Champion", "")); - cubeCards.add(new CardIdentity("Stonecloaker", "")); - cubeCards.add(new CardIdentity("Academy Rector", "")); - cubeCards.add(new CardIdentity("Emeria Angel", "")); - cubeCards.add(new CardIdentity("Hero of Bladehold", "")); - cubeCards.add(new CardIdentity("Hokori, Dust Drinker", "")); - cubeCards.add(new CardIdentity("Ranger of Eos", "")); - cubeCards.add(new CardIdentity("Restoration Angel", "")); - cubeCards.add(new CardIdentity("Sublime Archangel", "")); - cubeCards.add(new CardIdentity("Wall of Reverence", "")); - cubeCards.add(new CardIdentity("Archangel of Thune", "")); - cubeCards.add(new CardIdentity("Baneslayer Angel", "")); - cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); - cubeCards.add(new CardIdentity("Karmic Guide", "")); - cubeCards.add(new CardIdentity("Reveillark", "")); - cubeCards.add(new CardIdentity("Mikaeus, the Lunarch", "")); - cubeCards.add(new CardIdentity("Sun Titan", "")); - cubeCards.add(new CardIdentity("Yosei, the Morning Star", "")); - cubeCards.add(new CardIdentity("Angel of Serenity", "")); - cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite", "")); - cubeCards.add(new CardIdentity("Eternal Dragon", "")); - cubeCards.add(new CardIdentity("Akroma, Angel of Wrath", "")); - cubeCards.add(new CardIdentity("Avacyn, Angel of Hope", "")); - cubeCards.add(new CardIdentity("Iona, Shield of Emeria", "")); - cubeCards.add(new CardIdentity("Ajani, Caller of the Pride", "")); - cubeCards.add(new CardIdentity("Ajani Goldmane", "")); - cubeCards.add(new CardIdentity("Elspeth, Knight-Errant", "")); - cubeCards.add(new CardIdentity("Gideon Jura", "")); - cubeCards.add(new CardIdentity("Elspeth, Sun's Champion", "")); - cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); - cubeCards.add(new CardIdentity("Cloudshift", "")); - cubeCards.add(new CardIdentity("Condemn", "")); - cubeCards.add(new CardIdentity("Enlightened Tutor", "")); - cubeCards.add(new CardIdentity("Mana Tithe", "")); - cubeCards.add(new CardIdentity("Path to Exile", "")); - cubeCards.add(new CardIdentity("Swords to Plowshares", "")); - cubeCards.add(new CardIdentity("Disenchant", "")); - cubeCards.add(new CardIdentity("Momentary Blink", "")); - cubeCards.add(new CardIdentity("Balance", "")); - cubeCards.add(new CardIdentity("Lingering Souls", "")); - cubeCards.add(new CardIdentity("Spectral Procession", "")); - cubeCards.add(new CardIdentity("Armageddon", "")); - cubeCards.add(new CardIdentity("Cataclysm", "")); - cubeCards.add(new CardIdentity("Day of Judgment", "")); - cubeCards.add(new CardIdentity("Ravages of War", "")); - cubeCards.add(new CardIdentity("Wrath of God", "")); - cubeCards.add(new CardIdentity("Hallowed Burial", "")); - cubeCards.add(new CardIdentity("Increasing Devotion", "")); - cubeCards.add(new CardIdentity("Rout", "")); - cubeCards.add(new CardIdentity("Akroma's Vengeance", "")); - cubeCards.add(new CardIdentity("Terminus", "")); - cubeCards.add(new CardIdentity("Martial Coup", "")); - cubeCards.add(new CardIdentity("Entreat the Angels", "")); - cubeCards.add(new CardIdentity("Decree of Justice", "")); - cubeCards.add(new CardIdentity("Land Tax", "")); - cubeCards.add(new CardIdentity("Honor of the Pure", "")); - cubeCards.add(new CardIdentity("Journey to Nowhere", "")); - cubeCards.add(new CardIdentity("Luminarch Ascension", "")); - cubeCards.add(new CardIdentity("Temporal Isolation", "")); - cubeCards.add(new CardIdentity("Oblivion Ring", "")); - cubeCards.add(new CardIdentity("Angelic Destiny", "")); - cubeCards.add(new CardIdentity("Faith's Fetters", "")); - cubeCards.add(new CardIdentity("Parallax Wave", "")); - cubeCards.add(new CardIdentity("Worship", "")); - cubeCards.add(new CardIdentity("Spear of Heliod", "")); - cubeCards.add(new CardIdentity("Spirit of the Labyrinth", "")); - cubeCards.add(new CardIdentity("Karakas", "")); - cubeCards.add(new CardIdentity("Kjeldoran Outpost", "")); - cubeCards.add(new CardIdentity("Windbrisk Heights", "")); - cubeCards.add(new CardIdentity("Cursecatcher", "")); - cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); - cubeCards.add(new CardIdentity("Augur of Bolas", "")); - cubeCards.add(new CardIdentity("Fathom Seer", "")); - cubeCards.add(new CardIdentity("Gilded Drake", "")); - cubeCards.add(new CardIdentity("Looter il-Kor", "")); - cubeCards.add(new CardIdentity("Omenspeaker", "")); - cubeCards.add(new CardIdentity("Phantasmal Image", "")); - cubeCards.add(new CardIdentity("Snapcaster Mage", "")); - cubeCards.add(new CardIdentity("Waterfront Bouncer", "")); - cubeCards.add(new CardIdentity("AEther Adept", "")); - cubeCards.add(new CardIdentity("Kira, Great Glass-Spinner", "")); - cubeCards.add(new CardIdentity("Man-o'-War", "")); - cubeCards.add(new CardIdentity("Sea Gate Oracle", "")); - cubeCards.add(new CardIdentity("Serendib Efreet", "")); - cubeCards.add(new CardIdentity("Trinket Mage", "")); - cubeCards.add(new CardIdentity("Vendilion Clique", "")); - cubeCards.add(new CardIdentity("Wake Thrasher", "")); - cubeCards.add(new CardIdentity("Glen Elendra Archmage", "")); - cubeCards.add(new CardIdentity("Sower of Temptation", "")); - cubeCards.add(new CardIdentity("Talrand, Sky Summoner", "")); - cubeCards.add(new CardIdentity("Tradewind Rider", "")); - cubeCards.add(new CardIdentity("Venser, Shaper Savant", "")); - cubeCards.add(new CardIdentity("Meloku the Clouded Mirror", "")); - cubeCards.add(new CardIdentity("Mulldrifter", "")); - cubeCards.add(new CardIdentity("Prognostic Sphinx", "")); - cubeCards.add(new CardIdentity("Riftwing Cloudskate", "")); - cubeCards.add(new CardIdentity("Vesuvan Shapeshifter", "")); - cubeCards.add(new CardIdentity("AEtherling", "")); - cubeCards.add(new CardIdentity("Brine Elemental", "")); - cubeCards.add(new CardIdentity("Consecrated Sphinx", "")); - cubeCards.add(new CardIdentity("Frost Titan", "")); - cubeCards.add(new CardIdentity("Keiga, the Tide Star", "")); - cubeCards.add(new CardIdentity("Palinchron", "")); - cubeCards.add(new CardIdentity("Jace Beleren", "")); - cubeCards.add(new CardIdentity("Jace, Architect of Thought", "")); - cubeCards.add(new CardIdentity("Jace, the Mind Sculptor", "")); - cubeCards.add(new CardIdentity("Tamiyo, the Moon Sage", "")); - cubeCards.add(new CardIdentity("Phyrexian Metamorph", "")); - cubeCards.add(new CardIdentity("Ancestral Recall", "")); - cubeCards.add(new CardIdentity("Brainstorm", "")); - cubeCards.add(new CardIdentity("Mystical Tutor", "")); - cubeCards.add(new CardIdentity("Opt", "")); - cubeCards.add(new CardIdentity("Brain Freeze", "")); - cubeCards.add(new CardIdentity("Counterspell", "")); - cubeCards.add(new CardIdentity("Cyclonic Rift", "")); - cubeCards.add(new CardIdentity("Daze", "")); - cubeCards.add(new CardIdentity("Essence Scatter", "")); - cubeCards.add(new CardIdentity("Impulse", "")); - cubeCards.add(new CardIdentity("Into the Roil", "")); - cubeCards.add(new CardIdentity("Mana Drain", "")); - cubeCards.add(new CardIdentity("Mana Leak", "")); - cubeCards.add(new CardIdentity("Memory Lapse", "")); - cubeCards.add(new CardIdentity("Miscalculation", "")); - cubeCards.add(new CardIdentity("Negate", "")); - cubeCards.add(new CardIdentity("Remand", "")); - cubeCards.add(new CardIdentity("Capsize", "")); - cubeCards.add(new CardIdentity("Dissipate", "")); - cubeCards.add(new CardIdentity("Forbid", "")); - cubeCards.add(new CardIdentity("Forbidden Alchemy", "")); - cubeCards.add(new CardIdentity("Frantic Search", "")); - cubeCards.add(new CardIdentity("Intuition", "")); - cubeCards.add(new CardIdentity("Psionic Blast", "")); - cubeCards.add(new CardIdentity("Thirst for Knowledge", "")); - cubeCards.add(new CardIdentity("Careful Consideration", "")); - cubeCards.add(new CardIdentity("Cryptic Command", "")); - cubeCards.add(new CardIdentity("Fact or Fiction", "")); - cubeCards.add(new CardIdentity("Gifts Given", "")); - cubeCards.add(new CardIdentity("Gifts Ungiven", "")); - cubeCards.add(new CardIdentity("Turnabout", "")); - cubeCards.add(new CardIdentity("Desertion", "")); - cubeCards.add(new CardIdentity("Force of Will", "")); - cubeCards.add(new CardIdentity("Gush", "")); - cubeCards.add(new CardIdentity("Pact of Negation", "")); - cubeCards.add(new CardIdentity("Opportunity", "")); - cubeCards.add(new CardIdentity("Repeal", "")); - cubeCards.add(new CardIdentity("Ancestral Vision", "")); - cubeCards.add(new CardIdentity("Gitaxian Probe", "")); - cubeCards.add(new CardIdentity("Ponder", "")); - cubeCards.add(new CardIdentity("Preordain", "")); - cubeCards.add(new CardIdentity("Ideas Unbound", "")); - cubeCards.add(new CardIdentity("Time Walk", "")); - cubeCards.add(new CardIdentity("Compulsive Research", "")); - cubeCards.add(new CardIdentity("Show and Tell", "")); - cubeCards.add(new CardIdentity("Timetwister", "")); - cubeCards.add(new CardIdentity("Tinker", "")); - cubeCards.add(new CardIdentity("Deep Analysis", "")); - cubeCards.add(new CardIdentity("Bribery", "")); - cubeCards.add(new CardIdentity("Time Warp", "")); - cubeCards.add(new CardIdentity("Mind's Desire", "")); - cubeCards.add(new CardIdentity("Time Spiral", "")); - cubeCards.add(new CardIdentity("Upheaval", "")); - cubeCards.add(new CardIdentity("Legacy's Allure", "")); - cubeCards.add(new CardIdentity("Narcolepsy", "")); - cubeCards.add(new CardIdentity("Control Magic", "")); - cubeCards.add(new CardIdentity("Opposition", "")); - cubeCards.add(new CardIdentity("Future Sight", "")); - cubeCards.add(new CardIdentity("Treachery", "")); - cubeCards.add(new CardIdentity("Omniscience", "")); - cubeCards.add(new CardIdentity("Academy Ruins", "")); - cubeCards.add(new CardIdentity("Shelldock Isle", "")); - cubeCards.add(new CardIdentity("Carnophage", "")); - cubeCards.add(new CardIdentity("Diregraf Ghoul", "")); - cubeCards.add(new CardIdentity("Gravecrawler", "")); - cubeCards.add(new CardIdentity("Guul Draz Assassin", "")); - cubeCards.add(new CardIdentity("Tormented Hero", "")); - cubeCards.add(new CardIdentity("Vampire Lacerator", "")); - cubeCards.add(new CardIdentity("Blood Scrivener", "")); - cubeCards.add(new CardIdentity("Bloodghast", "")); - cubeCards.add(new CardIdentity("Dark Confidant", "")); - cubeCards.add(new CardIdentity("Dauthi Horror", "")); - cubeCards.add(new CardIdentity("Gatekeeper of Malakir", "")); - cubeCards.add(new CardIdentity("Knight of Infamy", "")); - cubeCards.add(new CardIdentity("Mesmeric Fiend", "")); - cubeCards.add(new CardIdentity("Nantuko Shade", "")); - cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); - cubeCards.add(new CardIdentity("Nezumi Shortfang", "")); - cubeCards.add(new CardIdentity("Nightscape Familiar", "")); - cubeCards.add(new CardIdentity("Oona's Prowler", "")); - cubeCards.add(new CardIdentity("Pack Rat", "")); - cubeCards.add(new CardIdentity("Vampire Hexmage", "")); - cubeCards.add(new CardIdentity("Bone Shredder", "")); - cubeCards.add(new CardIdentity("Geralf's Messenger", "")); - cubeCards.add(new CardIdentity("Hypnotic Specter", "")); - cubeCards.add(new CardIdentity("Phyrexian Rager", "")); - cubeCards.add(new CardIdentity("Vampire Nighthawk", "")); - cubeCards.add(new CardIdentity("Abyssal Persecutor", "")); - cubeCards.add(new CardIdentity("Bloodline Keeper", "")); - cubeCards.add(new CardIdentity("Braids, Cabal Minion", "")); - cubeCards.add(new CardIdentity("Crypt Ghast", "")); - cubeCards.add(new CardIdentity("Desecration Demon", "")); - cubeCards.add(new CardIdentity("Disciple of Bolas", "")); - cubeCards.add(new CardIdentity("Graveborn Muse", "")); - cubeCards.add(new CardIdentity("Nekrataal", "")); - cubeCards.add(new CardIdentity("Phyrexian Obliterator", "")); - cubeCards.add(new CardIdentity("Skinrender", "")); - cubeCards.add(new CardIdentity("Bloodgift Demon", "")); - cubeCards.add(new CardIdentity("Puppeteer Clique", "")); - cubeCards.add(new CardIdentity("Shriekmaw", "")); - cubeCards.add(new CardIdentity("Skithiryx, the Blight Dragon", "")); - cubeCards.add(new CardIdentity("Grave Titan", "")); - cubeCards.add(new CardIdentity("Ink-Eyes, Servant of Oni", "")); - cubeCards.add(new CardIdentity("Kokusho, the Evening Star", "")); - cubeCards.add(new CardIdentity("Sheoldred, Whispering One", "")); - cubeCards.add(new CardIdentity("Griselbrand", "")); - cubeCards.add(new CardIdentity("Tombstalker", "")); - cubeCards.add(new CardIdentity("Liliana of the Veil", "")); - cubeCards.add(new CardIdentity("Liliana Vess", "")); - cubeCards.add(new CardIdentity("Sorin Markov", "")); - cubeCards.add(new CardIdentity("Booster Tutor", "")); - cubeCards.add(new CardIdentity("Dark Ritual", "")); - cubeCards.add(new CardIdentity("Disfigure", "")); - cubeCards.add(new CardIdentity("Entomb", "")); - cubeCards.add(new CardIdentity("Vampiric Tutor", "")); - cubeCards.add(new CardIdentity("Doom Blade", "")); - cubeCards.add(new CardIdentity("Go for the Throat", "")); - cubeCards.add(new CardIdentity("Tainted Pact", "")); - cubeCards.add(new CardIdentity("Terror", "")); - cubeCards.add(new CardIdentity("Ultimate Price", "")); - cubeCards.add(new CardIdentity("Corpse Dance", "")); - cubeCards.add(new CardIdentity("Dismember", "")); - cubeCards.add(new CardIdentity("Hero's Downfall", "")); - cubeCards.add(new CardIdentity("Slaughter Pact", "")); - cubeCards.add(new CardIdentity("Makeshift Mannequin", "")); - cubeCards.add(new CardIdentity("Snuff Out", "")); - cubeCards.add(new CardIdentity("Duress", "")); - cubeCards.add(new CardIdentity("Innocent Blood", "")); - cubeCards.add(new CardIdentity("Inquisition of Kozilek", "")); - cubeCards.add(new CardIdentity("Reanimate", "")); - cubeCards.add(new CardIdentity("Thoughtseize", "")); - cubeCards.add(new CardIdentity("Chainer's Edict", "")); - cubeCards.add(new CardIdentity("Demonic Tutor", "")); - cubeCards.add(new CardIdentity("Exhume", "")); - cubeCards.add(new CardIdentity("Hymn to Tourach", "")); - cubeCards.add(new CardIdentity("Night's Whisper", "")); - cubeCards.add(new CardIdentity("Sign in Blood", "")); - cubeCards.add(new CardIdentity("Sinkhole", "")); - cubeCards.add(new CardIdentity("Buried Alive", "")); - cubeCards.add(new CardIdentity("Yawgmoth's Will", "")); - cubeCards.add(new CardIdentity("Ambition's Cost", "")); - cubeCards.add(new CardIdentity("Consuming Vapors", "")); - cubeCards.add(new CardIdentity("Damnation", "")); - cubeCards.add(new CardIdentity("Tendrils of Agony", "")); - cubeCards.add(new CardIdentity("Living Death", "")); - cubeCards.add(new CardIdentity("Black Sun's Zenith", "")); - cubeCards.add(new CardIdentity("Mind Shatter", "")); - cubeCards.add(new CardIdentity("Profane Command", "")); - cubeCards.add(new CardIdentity("Animate Dead", "")); - cubeCards.add(new CardIdentity("Bitterblossom", "")); - cubeCards.add(new CardIdentity("Necromancy", "")); - cubeCards.add(new CardIdentity("Necropotence", "")); - cubeCards.add(new CardIdentity("Phyrexian Arena", "")); - cubeCards.add(new CardIdentity("Recurring Nightmare", "")); - cubeCards.add(new CardIdentity("Diabolic Servitude", "")); - cubeCards.add(new CardIdentity("Nether Void", "")); - cubeCards.add(new CardIdentity("The Abyss", "")); - cubeCards.add(new CardIdentity("Yawgmoth's Bargain", "")); - cubeCards.add(new CardIdentity("Gnarled Scarhide", "")); - cubeCards.add(new CardIdentity("Herald of Torment", "")); - cubeCards.add(new CardIdentity("Master of the Feast", "")); - cubeCards.add(new CardIdentity("Cabal Coffers", "")); - cubeCards.add(new CardIdentity("Urborg, Tomb of Yawgmoth", "")); - cubeCards.add(new CardIdentity("Volrath's Stronghold", "")); - cubeCards.add(new CardIdentity("Firedrinker Satyr", "")); - cubeCards.add(new CardIdentity("Frenzied Goblin", "")); - cubeCards.add(new CardIdentity("Goblin Bushwhacker", "")); - cubeCards.add(new CardIdentity("Goblin Guide", "")); - cubeCards.add(new CardIdentity("Goblin Welder", "")); - cubeCards.add(new CardIdentity("Greater Gargadon", "")); - cubeCards.add(new CardIdentity("Grim Lavamancer", "")); - cubeCards.add(new CardIdentity("Jackal Pup", "")); - cubeCards.add(new CardIdentity("Reckless Waif", "")); - cubeCards.add(new CardIdentity("Spikeshot Elder", "")); - cubeCards.add(new CardIdentity("Stromkirk Noble", "")); - cubeCards.add(new CardIdentity("Vexing Devil", "")); - cubeCards.add(new CardIdentity("Ash Zealot", "")); - cubeCards.add(new CardIdentity("Ember Hauler", "")); - cubeCards.add(new CardIdentity("Firefist Striker", "")); - cubeCards.add(new CardIdentity("Goblin Wardriver", "")); - cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); - cubeCards.add(new CardIdentity("Hellspark Elemental", "")); - cubeCards.add(new CardIdentity("Kargan Dragonlord", "")); - cubeCards.add(new CardIdentity("Keldon Marauders", "")); - cubeCards.add(new CardIdentity("Lightning Mauler", "")); - cubeCards.add(new CardIdentity("Mogg Flunkies", "")); - cubeCards.add(new CardIdentity("Mogg War Marshal", "")); - cubeCards.add(new CardIdentity("Plated Geopede", "")); - cubeCards.add(new CardIdentity("Slith Firewalker", "")); - cubeCards.add(new CardIdentity("Stormblood Berserker", "")); - cubeCards.add(new CardIdentity("Torch Fiend", "")); - cubeCards.add(new CardIdentity("Young Pyromancer", "")); - cubeCards.add(new CardIdentity("Ball Lightning", "")); - cubeCards.add(new CardIdentity("Chandra's Phoenix", "")); - cubeCards.add(new CardIdentity("Countryside Crusher", "")); - cubeCards.add(new CardIdentity("Goblin Ruinblaster", "")); - cubeCards.add(new CardIdentity("Hell's Thunder", "")); - cubeCards.add(new CardIdentity("Imperial Recruiter", "")); - cubeCards.add(new CardIdentity("Squee, Goblin Nabob", "")); - cubeCards.add(new CardIdentity("Thunderscape Battlemage", "")); - cubeCards.add(new CardIdentity("Zo-Zu the Punisher", "")); - cubeCards.add(new CardIdentity("Avalanche Riders", "")); - cubeCards.add(new CardIdentity("Blistering Firecat", "")); - cubeCards.add(new CardIdentity("Flametongue Kavu", "")); - cubeCards.add(new CardIdentity("Hellrider", "")); - cubeCards.add(new CardIdentity("Hero of Oxid Ridge", "")); - cubeCards.add(new CardIdentity("Keldon Champion", "")); - cubeCards.add(new CardIdentity("Ravenous Baboons", "")); - cubeCards.add(new CardIdentity("Skizzik", "")); - cubeCards.add(new CardIdentity("Kiki-Jiki, Mirror Breaker", "")); - cubeCards.add(new CardIdentity("Siege-Gang Commander", "")); - cubeCards.add(new CardIdentity("Thundermaw Hellkite", "")); - cubeCards.add(new CardIdentity("Urabrask the Hidden", "")); - cubeCards.add(new CardIdentity("Zealous Conscripts", "")); - cubeCards.add(new CardIdentity("Inferno Titan", "")); - cubeCards.add(new CardIdentity("Bogardan Hellkite", "")); - cubeCards.add(new CardIdentity("Chandra, the Firebrand", "")); - cubeCards.add(new CardIdentity("Koth of the Hammer", "")); - cubeCards.add(new CardIdentity("Chandra Nalaar", "")); - cubeCards.add(new CardIdentity("Burst Lightning", "")); - cubeCards.add(new CardIdentity("Lightning Bolt", "")); - cubeCards.add(new CardIdentity("Ancient Grudge", "")); - cubeCards.add(new CardIdentity("Incinerate", "")); - cubeCards.add(new CardIdentity("Lightning Strike", "")); - cubeCards.add(new CardIdentity("Magma Jet", "")); - cubeCards.add(new CardIdentity("Searing Blaze", "")); - cubeCards.add(new CardIdentity("Searing Spear", "")); - cubeCards.add(new CardIdentity("Brimstone Volley", "")); - cubeCards.add(new CardIdentity("Chaos Warp", "")); - cubeCards.add(new CardIdentity("Char", "")); - cubeCards.add(new CardIdentity("Staggershock", "")); - cubeCards.add(new CardIdentity("Volcanic Fallout", "")); - cubeCards.add(new CardIdentity("Beacon of Destruction", "")); - cubeCards.add(new CardIdentity("Fireblast", "")); - cubeCards.add(new CardIdentity("Pyrokinesis", "")); - cubeCards.add(new CardIdentity("Chain Lightning", "")); - cubeCards.add(new CardIdentity("Faithless Looting", "")); - cubeCards.add(new CardIdentity("Firebolt", "")); - cubeCards.add(new CardIdentity("Gamble", "")); - cubeCards.add(new CardIdentity("Reckless Charge", "")); - cubeCards.add(new CardIdentity("Arc Trail", "")); - cubeCards.add(new CardIdentity("Pyroclasm", "")); - cubeCards.add(new CardIdentity("Anger of the Gods", "")); - cubeCards.add(new CardIdentity("Arc Lightning", "")); - cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); - cubeCards.add(new CardIdentity("Molten Rain", "")); - cubeCards.add(new CardIdentity("Pillage", "")); - cubeCards.add(new CardIdentity("Rift Bolt", "")); - cubeCards.add(new CardIdentity("Slagstorm", "")); - cubeCards.add(new CardIdentity("Stone Rain", "")); - cubeCards.add(new CardIdentity("Wheel of Fortune", "")); - cubeCards.add(new CardIdentity("Aftershock", "")); - cubeCards.add(new CardIdentity("Empty the Warrens", "")); - cubeCards.add(new CardIdentity("Banefire", "")); - cubeCards.add(new CardIdentity("Devil's Play", "")); - cubeCards.add(new CardIdentity("Earthquake", "")); - cubeCards.add(new CardIdentity("Jokulhaups", "")); - cubeCards.add(new CardIdentity("Rolling Earthquake", "")); - cubeCards.add(new CardIdentity("Wildfire", "")); - cubeCards.add(new CardIdentity("Bonfire of the Damned", "")); - cubeCards.add(new CardIdentity("Sulfuric Vortex", "")); - cubeCards.add(new CardIdentity("Sneak Attack", "")); - cubeCards.add(new CardIdentity("Purphoros, God of the Forge", "")); - cubeCards.add(new CardIdentity("Ghitu Encampment", "")); - cubeCards.add(new CardIdentity("Teetering Peaks", "")); - cubeCards.add(new CardIdentity("Avacyn's Pilgrim", "")); - cubeCards.add(new CardIdentity("Birds of Paradise", "")); - cubeCards.add(new CardIdentity("Elves of Deep Shadow", "")); - cubeCards.add(new CardIdentity("Elvish Mystic", "")); - cubeCards.add(new CardIdentity("Experiment One", "")); - cubeCards.add(new CardIdentity("Fyndhorn Elves", "")); - cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); - cubeCards.add(new CardIdentity("Llanowar Elves", "")); - cubeCards.add(new CardIdentity("Noble Hierarch", "")); - cubeCards.add(new CardIdentity("Ulvenwald Tracker", "")); - cubeCards.add(new CardIdentity("Devoted Druid", "")); - cubeCards.add(new CardIdentity("Fauna Shaman", "")); - cubeCards.add(new CardIdentity("Lotus Cobra", "")); - cubeCards.add(new CardIdentity("Mayor of Avabruck", "")); - cubeCards.add(new CardIdentity("Overgrown Battlement", "")); - cubeCards.add(new CardIdentity("Rofellos, Llanowar Emissary", "")); - cubeCards.add(new CardIdentity("Sakura-Tribe Elder", "")); - cubeCards.add(new CardIdentity("Scavenging Ooze", "")); - cubeCards.add(new CardIdentity("Scorned Villager", "")); - cubeCards.add(new CardIdentity("Strangleroot Geist", "")); - cubeCards.add(new CardIdentity("Sylvan Caryatid", "")); - cubeCards.add(new CardIdentity("Tarmogoyf", "")); - cubeCards.add(new CardIdentity("Wall of Blossoms", "")); - cubeCards.add(new CardIdentity("Wall of Roots", "")); - cubeCards.add(new CardIdentity("Werebear", "")); - cubeCards.add(new CardIdentity("Eternal Witness", "")); - cubeCards.add(new CardIdentity("Ohran Viper", "")); - cubeCards.add(new CardIdentity("Wolfir Avenger", "")); - cubeCards.add(new CardIdentity("Wood Elves", "")); - cubeCards.add(new CardIdentity("Yavimaya Elder", "")); - cubeCards.add(new CardIdentity("Blastoderm", "")); - cubeCards.add(new CardIdentity("Chameleon Colossus", "")); - cubeCards.add(new CardIdentity("Master of the Wild Hunt", "")); - cubeCards.add(new CardIdentity("Mold Shambler", "")); - cubeCards.add(new CardIdentity("Nantuko Vigilante", "")); - cubeCards.add(new CardIdentity("Obstinate Baloth", "")); - cubeCards.add(new CardIdentity("Oracle of Mul Daya", "")); - cubeCards.add(new CardIdentity("Polukranos, World Eater", "")); - cubeCards.add(new CardIdentity("Thelonite Hermit", "")); - cubeCards.add(new CardIdentity("Thrun, the Last Troll", "")); - cubeCards.add(new CardIdentity("Vengevine", "")); - cubeCards.add(new CardIdentity("Wickerbough Elder", "")); - cubeCards.add(new CardIdentity("Yeva, Nature's Herald", "")); - cubeCards.add(new CardIdentity("Acidic Slime", "")); - cubeCards.add(new CardIdentity("Deranged Hermit", "")); - cubeCards.add(new CardIdentity("Genesis", "")); - cubeCards.add(new CardIdentity("Indrik Stomphowler", "")); - cubeCards.add(new CardIdentity("Thornling", "")); - cubeCards.add(new CardIdentity("Thragtusk", "")); - cubeCards.add(new CardIdentity("Vorapede", "")); - cubeCards.add(new CardIdentity("Cloudthresher", "")); - cubeCards.add(new CardIdentity("Primeval Titan", "")); - cubeCards.add(new CardIdentity("Avenger of Zendikar", "")); - cubeCards.add(new CardIdentity("Primordial Hydra", "")); - cubeCards.add(new CardIdentity("Craterhoof Behemoth", "")); - cubeCards.add(new CardIdentity("Terastodon", "")); - cubeCards.add(new CardIdentity("Woodfall Primus", "")); - cubeCards.add(new CardIdentity("Garruk Relentless", "")); - cubeCards.add(new CardIdentity("Garruk Wildspeaker", "")); - cubeCards.add(new CardIdentity("Garruk, Primal Hunter", "")); - cubeCards.add(new CardIdentity("Arbor Elf", "")); - cubeCards.add(new CardIdentity("Birthing Pod", "")); - cubeCards.add(new CardIdentity("Vines of Vastwood", "")); - cubeCards.add(new CardIdentity("Moment's Peace", "")); - cubeCards.add(new CardIdentity("Naturalize", "")); - cubeCards.add(new CardIdentity("Beast Within", "")); - cubeCards.add(new CardIdentity("Harrow", "")); - cubeCards.add(new CardIdentity("Stonewood Invocation", "")); - cubeCards.add(new CardIdentity("Summoning Trap", "")); - cubeCards.add(new CardIdentity("Channel", "")); - cubeCards.add(new CardIdentity("Explore", "")); - cubeCards.add(new CardIdentity("Farseek", "")); - cubeCards.add(new CardIdentity("Life from the Loam", "")); - cubeCards.add(new CardIdentity("Rampant Growth", "")); - cubeCards.add(new CardIdentity("Regrowth", "")); - cubeCards.add(new CardIdentity("Call of the Herd", "")); - cubeCards.add(new CardIdentity("Cultivate", "")); - cubeCards.add(new CardIdentity("Kodama's Reach", "")); - cubeCards.add(new CardIdentity("Search for Tomorrow", "")); - cubeCards.add(new CardIdentity("Harmonize", "")); - cubeCards.add(new CardIdentity("Natural Order", "")); - cubeCards.add(new CardIdentity("Overrun", "")); - cubeCards.add(new CardIdentity("Plow Under", "")); - cubeCards.add(new CardIdentity("Primal Command", "")); - cubeCards.add(new CardIdentity("Restock", "")); - cubeCards.add(new CardIdentity("Rude Awakening", "")); - cubeCards.add(new CardIdentity("Stunted Growth", "")); - cubeCards.add(new CardIdentity("Green Sun's Zenith", "")); - cubeCards.add(new CardIdentity("Tooth and Nail", "")); - cubeCards.add(new CardIdentity("Genesis Wave", "")); - cubeCards.add(new CardIdentity("Rancor", "")); - cubeCards.add(new CardIdentity("Oath of Druids", "")); - cubeCards.add(new CardIdentity("Survival of the Fittest", "")); - cubeCards.add(new CardIdentity("Sylvan Library", "")); - cubeCards.add(new CardIdentity("Awakening Zone", "")); - cubeCards.add(new CardIdentity("Heartbeat of Spring", "")); - cubeCards.add(new CardIdentity("Defense of the Heart", "")); - cubeCards.add(new CardIdentity("Courser of Kruphix", "")); - cubeCards.add(new CardIdentity("Gaea's Cradle", "")); - cubeCards.add(new CardIdentity("Treetop Village", "")); - cubeCards.add(new CardIdentity("Yavimaya Hollow", "")); - cubeCards.add(new CardIdentity("Geist of Saint Traft", "")); - cubeCards.add(new CardIdentity("Plumeveil", "")); - cubeCards.add(new CardIdentity("Wall of Denial", "")); - cubeCards.add(new CardIdentity("Grand Arbiter Augustin IV", "")); - cubeCards.add(new CardIdentity("Venser, the Sojourner", "")); - cubeCards.add(new CardIdentity("Supreme Verdict", "")); - cubeCards.add(new CardIdentity("Detention Sphere", "")); - cubeCards.add(new CardIdentity("Celestial Colonnade", "")); - cubeCards.add(new CardIdentity("Glacial Fortress", "")); - cubeCards.add(new CardIdentity("Hallowed Fountain", "")); - cubeCards.add(new CardIdentity("Tundra", "")); - cubeCards.add(new CardIdentity("Psychatog", "")); - cubeCards.add(new CardIdentity("Shadowmage Infiltrator", "")); - cubeCards.add(new CardIdentity("Duskmantle Seer", "")); - cubeCards.add(new CardIdentity("Tezzeret, Agent of Bolas", "")); - cubeCards.add(new CardIdentity("Baleful Strix", "")); - cubeCards.add(new CardIdentity("Agony Warp", "")); - cubeCards.add(new CardIdentity("Far // Away", "")); - cubeCards.add(new CardIdentity("Creeping Tar Pit", "")); - cubeCards.add(new CardIdentity("Drowned Catacomb", "")); - cubeCards.add(new CardIdentity("Underground Sea", "")); - cubeCards.add(new CardIdentity("Watery Grave", "")); - cubeCards.add(new CardIdentity("Rakdos Cackler", "")); - cubeCards.add(new CardIdentity("Falkenrath Aristocrat", "")); - cubeCards.add(new CardIdentity("Murderous Redcap", "")); - cubeCards.add(new CardIdentity("Olivia Voldaren", "")); - cubeCards.add(new CardIdentity("Sarkhan the Mad", "")); - cubeCards.add(new CardIdentity("Bituminous Blast", "")); - cubeCards.add(new CardIdentity("Dreadbore", "")); - cubeCards.add(new CardIdentity("Badlands", "")); - cubeCards.add(new CardIdentity("Blood Crypt", "")); - cubeCards.add(new CardIdentity("Dragonskull Summit", "")); - cubeCards.add(new CardIdentity("Lavaclaw Reaches", "")); - cubeCards.add(new CardIdentity("Tattermunge Maniac", "")); - cubeCards.add(new CardIdentity("Burning-Tree Emissary", "")); - cubeCards.add(new CardIdentity("Boggart Ram-Gang", "")); - cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); - cubeCards.add(new CardIdentity("Huntmaster of the Fells", "")); - cubeCards.add(new CardIdentity("Domri Rade", "")); - cubeCards.add(new CardIdentity("Manamorphose", "")); - cubeCards.add(new CardIdentity("Raging Ravine", "")); - cubeCards.add(new CardIdentity("Rootbound Crag", "")); - cubeCards.add(new CardIdentity("Stomping Ground", "")); - cubeCards.add(new CardIdentity("Taiga", "")); - cubeCards.add(new CardIdentity("Dryad Militant", "")); - cubeCards.add(new CardIdentity("Qasali Pridemage", "")); - cubeCards.add(new CardIdentity("Voice of Resurgence", "")); - cubeCards.add(new CardIdentity("Kitchen Finks", "")); - cubeCards.add(new CardIdentity("Knight of the Reliquary", "")); - cubeCards.add(new CardIdentity("Mirari's Wake", "")); - cubeCards.add(new CardIdentity("Gavony Township", "")); - cubeCards.add(new CardIdentity("Savannah", "")); - cubeCards.add(new CardIdentity("Stirring Wildwood", "")); - cubeCards.add(new CardIdentity("Sunpetal Grove", "")); - cubeCards.add(new CardIdentity("Temple Garden", "")); - cubeCards.add(new CardIdentity("Stillmoon Cavalier", "")); - cubeCards.add(new CardIdentity("Obzedat, Ghost Council", "")); - cubeCards.add(new CardIdentity("Ashen Rider", "")); - cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad", "")); - cubeCards.add(new CardIdentity("Tidehollow Sculler", "")); - cubeCards.add(new CardIdentity("Vindicate", "")); - cubeCards.add(new CardIdentity("Godless Shrine", "")); - cubeCards.add(new CardIdentity("Isolated Chapel", "")); - cubeCards.add(new CardIdentity("Scrubland", "")); - cubeCards.add(new CardIdentity("Vault of the Archangel", "")); - cubeCards.add(new CardIdentity("Deathrite Shaman", "")); - cubeCards.add(new CardIdentity("Putrid Leech", "")); - cubeCards.add(new CardIdentity("Varolz, the Scar-Striped", "")); - cubeCards.add(new CardIdentity("Vraska the Unseen", "")); - cubeCards.add(new CardIdentity("Putrefy", "")); - cubeCards.add(new CardIdentity("Abrupt Decay", "")); - cubeCards.add(new CardIdentity("Maelstrom Pulse", "")); - cubeCards.add(new CardIdentity("Pernicious Deed", "")); - cubeCards.add(new CardIdentity("Bayou", "")); - cubeCards.add(new CardIdentity("Overgrown Tomb", "")); - cubeCards.add(new CardIdentity("Woodland Cemetery", "")); - cubeCards.add(new CardIdentity("Coiling Oracle", "")); - cubeCards.add(new CardIdentity("Cold-Eyed Selkie", "")); - cubeCards.add(new CardIdentity("Edric, Spymaster of Trest", "")); - cubeCards.add(new CardIdentity("Trygon Predator", "")); - cubeCards.add(new CardIdentity("Mystic Snake", "")); - cubeCards.add(new CardIdentity("Simic Sky Swallower", "")); - cubeCards.add(new CardIdentity("Kiora, the Crashing Wave", "")); - cubeCards.add(new CardIdentity("Voidslime", "")); - cubeCards.add(new CardIdentity("Breeding Pool", "")); - cubeCards.add(new CardIdentity("Hinterland Harbor", "")); - cubeCards.add(new CardIdentity("Tropical Island", "")); - cubeCards.add(new CardIdentity("Niv-Mizzet, Dracogenius", "")); - cubeCards.add(new CardIdentity("Nucklavee", "")); - cubeCards.add(new CardIdentity("Ral Zarek", "")); - cubeCards.add(new CardIdentity("Fire // Ice", "")); - cubeCards.add(new CardIdentity("Izzet Charm", "")); - cubeCards.add(new CardIdentity("Electrolyze", "")); - cubeCards.add(new CardIdentity("Steam Augury", "")); - cubeCards.add(new CardIdentity("Prophetic Bolt", "")); - cubeCards.add(new CardIdentity("Steam Vents", "")); - cubeCards.add(new CardIdentity("Sulfur Falls", "")); - cubeCards.add(new CardIdentity("Volcanic Island", "")); - cubeCards.add(new CardIdentity("Figure of Destiny", "")); - cubeCards.add(new CardIdentity("Boros Reckoner", "")); - cubeCards.add(new CardIdentity("Ajani Vengeant", "")); - cubeCards.add(new CardIdentity("Boros Charm", "")); - cubeCards.add(new CardIdentity("Lightning Helix", "")); - cubeCards.add(new CardIdentity("Aurelia's Fury", "")); - cubeCards.add(new CardIdentity("Chained to the Rocks", "")); - cubeCards.add(new CardIdentity("Clifftop Retreat", "")); - cubeCards.add(new CardIdentity("Plateau", "")); - cubeCards.add(new CardIdentity("Sacred Foundry", "")); - cubeCards.add(new CardIdentity("Sphinx of the Steel Wind", "")); - cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker", "")); - cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth", "")); - cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre", "")); - cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn", "")); - cubeCards.add(new CardIdentity("Karn Liberated", "")); - cubeCards.add(new CardIdentity("Epochrasite", "")); - cubeCards.add(new CardIdentity("Phyrexian Revoker", "")); - cubeCards.add(new CardIdentity("Spellskite", "")); - cubeCards.add(new CardIdentity("Palladium Myr", "")); - cubeCards.add(new CardIdentity("Lodestone Golem", "")); - cubeCards.add(new CardIdentity("Masticore", "")); - cubeCards.add(new CardIdentity("Molten-Tail Masticore", "")); - cubeCards.add(new CardIdentity("Solemn Simulacrum", "")); - cubeCards.add(new CardIdentity("Precursor Golem", "")); - cubeCards.add(new CardIdentity("Wurmcoil Engine", "")); - cubeCards.add(new CardIdentity("Myr Battlesphere", "")); - cubeCards.add(new CardIdentity("Platinum Angel", "")); - cubeCards.add(new CardIdentity("Sundering Titan", "")); - cubeCards.add(new CardIdentity("Black Lotus", "")); - cubeCards.add(new CardIdentity("Chrome Mox", "")); - cubeCards.add(new CardIdentity("Everflowing Chalice", "")); - cubeCards.add(new CardIdentity("Lotus Bloom", "")); - cubeCards.add(new CardIdentity("Lotus Petal", "")); - cubeCards.add(new CardIdentity("Mana Crypt", "")); - cubeCards.add(new CardIdentity("Mox Diamond", "")); - cubeCards.add(new CardIdentity("Mox Emerald", "")); - cubeCards.add(new CardIdentity("Mox Jet", "")); - cubeCards.add(new CardIdentity("Mox Pearl", "")); - cubeCards.add(new CardIdentity("Mox Ruby", "")); - cubeCards.add(new CardIdentity("Mox Sapphire", "")); - cubeCards.add(new CardIdentity("AEther Vial", "")); - cubeCards.add(new CardIdentity("Basilisk Collar", "")); - cubeCards.add(new CardIdentity("Bonesplitter", "")); - cubeCards.add(new CardIdentity("Cursed Scroll", "")); - cubeCards.add(new CardIdentity("Mana Vault", "")); - cubeCards.add(new CardIdentity("Pithing Needle", "")); - cubeCards.add(new CardIdentity("Relic of Progenitus", "")); - cubeCards.add(new CardIdentity("Sensei's Divining Top", "")); - cubeCards.add(new CardIdentity("Skullclamp", "")); - cubeCards.add(new CardIdentity("Sol Ring", "")); - cubeCards.add(new CardIdentity("Ankh of Mishra", "")); - cubeCards.add(new CardIdentity("Chaos Orb", "")); - cubeCards.add(new CardIdentity("Coldsteel Heart", "")); - cubeCards.add(new CardIdentity("Fellwar Stone", "")); - cubeCards.add(new CardIdentity("Grim Monolith", "")); - cubeCards.add(new CardIdentity("Isochron Scepter", "")); - cubeCards.add(new CardIdentity("Lightning Greaves", "")); - cubeCards.add(new CardIdentity("Mind Stone", "")); - cubeCards.add(new CardIdentity("Mortarpod", "")); - cubeCards.add(new CardIdentity("Powder Keg", "")); - cubeCards.add(new CardIdentity("Prismatic Lens", "")); - cubeCards.add(new CardIdentity("Scroll Rack", "")); - cubeCards.add(new CardIdentity("Shrine of Burning Rage", "")); - cubeCards.add(new CardIdentity("Sphere of the Suns", "")); - cubeCards.add(new CardIdentity("Umezawa's Jitte", "")); - cubeCards.add(new CardIdentity("Basalt Monolith", "")); - cubeCards.add(new CardIdentity("Coalition Relic", "")); - cubeCards.add(new CardIdentity("Crucible of Worlds", "")); - cubeCards.add(new CardIdentity("Crystal Shard", "")); - cubeCards.add(new CardIdentity("Grafted Wargear", "")); - cubeCards.add(new CardIdentity("Mimic Vat", "")); - cubeCards.add(new CardIdentity("Pristine Talisman", "")); - cubeCards.add(new CardIdentity("Sword of Body and Mind", "")); - cubeCards.add(new CardIdentity("Sword of Feast and Famine", "")); - cubeCards.add(new CardIdentity("Sword of Fire and Ice", "")); - cubeCards.add(new CardIdentity("Sword of Light and Shadow", "")); - cubeCards.add(new CardIdentity("Sword of War and Peace", "")); - cubeCards.add(new CardIdentity("Tangle Wire", "")); - cubeCards.add(new CardIdentity("Vedalken Shackles", "")); - cubeCards.add(new CardIdentity("Worn Powerstone", "")); - cubeCards.add(new CardIdentity("Nevinyrral's Disk", "")); - cubeCards.add(new CardIdentity("Smokestack", "")); - cubeCards.add(new CardIdentity("Thran Dynamo", "")); - cubeCards.add(new CardIdentity("Batterskull", "")); - cubeCards.add(new CardIdentity("Eldrazi Monument", "")); - cubeCards.add(new CardIdentity("Engineered Explosives", "")); - cubeCards.add(new CardIdentity("Gilded Lotus", "")); - cubeCards.add(new CardIdentity("Memory Jar", "")); - cubeCards.add(new CardIdentity("Mindslaver", "")); - cubeCards.add(new CardIdentity("All Is Dust", "")); - cubeCards.add(new CardIdentity("Ancient Tomb", "")); - cubeCards.add(new CardIdentity("Arid Mesa", "")); - cubeCards.add(new CardIdentity("Bloodstained Mire", "")); - cubeCards.add(new CardIdentity("City of Brass", "")); - cubeCards.add(new CardIdentity("City of Traitors", "")); - cubeCards.add(new CardIdentity("Evolving Wilds", "")); - cubeCards.add(new CardIdentity("Flooded Strand", "")); - cubeCards.add(new CardIdentity("Library of Alexandria", "")); - cubeCards.add(new CardIdentity("Mana Confluence", "")); - cubeCards.add(new CardIdentity("Marsh Flats", "")); - cubeCards.add(new CardIdentity("Maze of Ith", "")); - cubeCards.add(new CardIdentity("Mishra's Factory", "")); - cubeCards.add(new CardIdentity("Misty Rainforest", "")); - cubeCards.add(new CardIdentity("Mutavault", "")); - cubeCards.add(new CardIdentity("Polluted Delta", "")); - cubeCards.add(new CardIdentity("Rishadan Port", "")); - cubeCards.add(new CardIdentity("Scalding Tarn", "")); - cubeCards.add(new CardIdentity("Strip Mine", "")); - cubeCards.add(new CardIdentity("Tectonic Edge", "")); - cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); - cubeCards.add(new CardIdentity("The Tabernacle at Pendrell Vale", "")); - cubeCards.add(new CardIdentity("Verdant Catacombs", "")); - cubeCards.add(new CardIdentity("Wasteland", "")); - cubeCards.add(new CardIdentity("Windswept Heath", "")); - cubeCards.add(new CardIdentity("Wooded Foothills", "")); - - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.tournament.cubes; + +import mage.game.draft.DraftCube; +import mage.game.draft.DraftCube.CardIdentity; + +/** + * + * @author LevelX2 + */ +public class BensCube extends DraftCube { + + public BensCube() { + super("Ben's Cube (720 cards)"); // http://cubetutor.com/viewcube/1 + + cubeCards.add(new CardIdentity("Abrupt Decay", "")); + cubeCards.add(new CardIdentity("Abyssal Persecutor", "")); + cubeCards.add(new CardIdentity("Academy Rector", "")); + cubeCards.add(new CardIdentity("Academy Ruins", "")); + cubeCards.add(new CardIdentity("Accorder Paladin", "")); + cubeCards.add(new CardIdentity("Acidic Slime", "")); + cubeCards.add(new CardIdentity("AEther Adept", "")); + cubeCards.add(new CardIdentity("AEther Vial", "")); + cubeCards.add(new CardIdentity("AEtherling", "")); + cubeCards.add(new CardIdentity("Agony Warp", "")); + cubeCards.add(new CardIdentity("Ajani Goldmane", "")); + cubeCards.add(new CardIdentity("Ajani Steadfast", "")); + cubeCards.add(new CardIdentity("Ajani Vengeant", "")); + cubeCards.add(new CardIdentity("Ajani, Caller of the Pride", "")); + cubeCards.add(new CardIdentity("Akroma, Angel of Wrath", "")); + cubeCards.add(new CardIdentity("Akroma's Vengeance", "")); + cubeCards.add(new CardIdentity("All Is Dust", "")); + cubeCards.add(new CardIdentity("Ambition's Cost", "")); + cubeCards.add(new CardIdentity("Ancestral Recall", "")); + cubeCards.add(new CardIdentity("Ancestral Vision", "")); + cubeCards.add(new CardIdentity("Ancient Grudge", "")); + cubeCards.add(new CardIdentity("Ancient Tomb", "")); + cubeCards.add(new CardIdentity("Angel of Serenity", "")); + cubeCards.add(new CardIdentity("Anger of the Gods", "")); + cubeCards.add(new CardIdentity("Animate Dead", "")); + cubeCards.add(new CardIdentity("Ankh of Mishra", "")); + cubeCards.add(new CardIdentity("Arbor Elf", "")); + cubeCards.add(new CardIdentity("Arc Lightning", "")); + cubeCards.add(new CardIdentity("Arc Trail", "")); + cubeCards.add(new CardIdentity("Archangel of Thune", "")); + cubeCards.add(new CardIdentity("Arid Mesa", "")); + cubeCards.add(new CardIdentity("Armageddon", "")); + cubeCards.add(new CardIdentity("Ash Zealot", "")); + cubeCards.add(new CardIdentity("Ashen Rider", "")); + cubeCards.add(new CardIdentity("Augur of Bolas", "")); + cubeCards.add(new CardIdentity("Aurelia's Fury", "")); + cubeCards.add(new CardIdentity("Avacyn, Angel of Hope", "")); + cubeCards.add(new CardIdentity("Avacyn's Pilgrim", "")); + cubeCards.add(new CardIdentity("Avalanche Riders", "")); + cubeCards.add(new CardIdentity("Aven Mindcensor", "")); + cubeCards.add(new CardIdentity("Avenger of Zendikar", "")); + cubeCards.add(new CardIdentity("Awakening Zone", "")); + cubeCards.add(new CardIdentity("Badlands", "")); + cubeCards.add(new CardIdentity("Balance", "")); + cubeCards.add(new CardIdentity("Baleful Strix", "")); + cubeCards.add(new CardIdentity("Banefire", "")); + cubeCards.add(new CardIdentity("Baneslayer Angel", "")); + cubeCards.add(new CardIdentity("Basalt Monolith", "")); + cubeCards.add(new CardIdentity("Basilisk Collar", "")); + cubeCards.add(new CardIdentity("Batterskull", "")); + cubeCards.add(new CardIdentity("Bayou", "")); + cubeCards.add(new CardIdentity("Beast Within", "")); + cubeCards.add(new CardIdentity("Birds of Paradise", "")); + cubeCards.add(new CardIdentity("Birthing Pod", "")); + cubeCards.add(new CardIdentity("Bitterblossom", "")); + cubeCards.add(new CardIdentity("Bituminous Blast", "")); + cubeCards.add(new CardIdentity("Black Lotus", "")); + cubeCards.add(new CardIdentity("Black Sun's Zenith", "")); + cubeCards.add(new CardIdentity("Blade Splicer", "")); + cubeCards.add(new CardIdentity("Blastoderm", "")); + cubeCards.add(new CardIdentity("Blightsteel Colossus", "")); + cubeCards.add(new CardIdentity("Blistering Firecat", "")); + cubeCards.add(new CardIdentity("Blood Crypt", "")); + cubeCards.add(new CardIdentity("Blood Scrivener", "")); + cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); + cubeCards.add(new CardIdentity("Bloodghast", "")); + cubeCards.add(new CardIdentity("Bloodgift Demon", "")); + cubeCards.add(new CardIdentity("Bloodline Keeper", "")); + cubeCards.add(new CardIdentity("Bloodsoaked Champion", "")); + cubeCards.add(new CardIdentity("Bloodstained Mire", "")); + cubeCards.add(new CardIdentity("Bogardan Hellkite", "")); + cubeCards.add(new CardIdentity("Boggart Ram-Gang", "")); + cubeCards.add(new CardIdentity("Bone Shredder", "")); + cubeCards.add(new CardIdentity("Bonesplitter", "")); + cubeCards.add(new CardIdentity("Bonfire of the Damned", "")); + cubeCards.add(new CardIdentity("Booster Tutor", "")); + cubeCards.add(new CardIdentity("Borderland Marauder", "")); + cubeCards.add(new CardIdentity("Boros Charm", "")); + cubeCards.add(new CardIdentity("Boros Reckoner", "")); + cubeCards.add(new CardIdentity("Braids, Cabal Minion", "")); + cubeCards.add(new CardIdentity("Brain Freeze", "")); + cubeCards.add(new CardIdentity("Brainstorm", "")); + cubeCards.add(new CardIdentity("Breeding Pool", "")); + cubeCards.add(new CardIdentity("Bribery", "")); + cubeCards.add(new CardIdentity("Brimaz, King of Oreskos", "")); + cubeCards.add(new CardIdentity("Brimstone Volley", "")); + cubeCards.add(new CardIdentity("Buried Alive", "")); + cubeCards.add(new CardIdentity("Burning-Tree Emissary", "")); + cubeCards.add(new CardIdentity("Burst Lightning", "")); + cubeCards.add(new CardIdentity("Cabal Coffers", "")); + cubeCards.add(new CardIdentity("Call of the Herd", "")); + cubeCards.add(new CardIdentity("Capsize", "")); + cubeCards.add(new CardIdentity("Careful Consideration", "")); + cubeCards.add(new CardIdentity("Carnophage", "")); + cubeCards.add(new CardIdentity("Cataclysm", "")); + cubeCards.add(new CardIdentity("Celestial Colonnade", "")); + cubeCards.add(new CardIdentity("Chain Lightning", "")); + cubeCards.add(new CardIdentity("Chained to the Rocks", "")); + cubeCards.add(new CardIdentity("Chainer's Edict", "")); + cubeCards.add(new CardIdentity("Chameleon Colossus", "")); + cubeCards.add(new CardIdentity("Chandra, the Firebrand", "")); + cubeCards.add(new CardIdentity("Chandra's Phoenix", "")); + cubeCards.add(new CardIdentity("Channel", "")); + cubeCards.add(new CardIdentity("Chaos Orb", "")); + cubeCards.add(new CardIdentity("Chaos Warp", "")); + cubeCards.add(new CardIdentity("Char", "")); + cubeCards.add(new CardIdentity("Chrome Mox", "")); + cubeCards.add(new CardIdentity("City of Brass", "")); + cubeCards.add(new CardIdentity("City of Traitors", "")); + cubeCards.add(new CardIdentity("Clifftop Retreat", "")); + cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); + cubeCards.add(new CardIdentity("Cloudthresher", "")); + cubeCards.add(new CardIdentity("Coalition Relic", "")); + cubeCards.add(new CardIdentity("Coiling Oracle", "")); + cubeCards.add(new CardIdentity("Coldsteel Heart", "")); + cubeCards.add(new CardIdentity("Compulsive Research", "")); + cubeCards.add(new CardIdentity("Condemn", "")); + cubeCards.add(new CardIdentity("Consecrated Sphinx", "")); + cubeCards.add(new CardIdentity("Consuming Vapors", "")); + cubeCards.add(new CardIdentity("Containment Priest", "")); + cubeCards.add(new CardIdentity("Control Magic", "")); + cubeCards.add(new CardIdentity("Corpse Dance", "")); + cubeCards.add(new CardIdentity("Council's Judgment", "")); + cubeCards.add(new CardIdentity("Counterspell", "")); + cubeCards.add(new CardIdentity("Countryside Crusher", "")); + cubeCards.add(new CardIdentity("Courser of Kruphix", "")); + cubeCards.add(new CardIdentity("Craterhoof Behemoth", "")); + cubeCards.add(new CardIdentity("Creeping Tar Pit", "")); + cubeCards.add(new CardIdentity("Crucible of Worlds", "")); + cubeCards.add(new CardIdentity("Crypt Ghast", "")); + cubeCards.add(new CardIdentity("Cryptic Command", "")); + cubeCards.add(new CardIdentity("Crystal Shard", "")); + cubeCards.add(new CardIdentity("Cultivate", "")); + cubeCards.add(new CardIdentity("Cursed Scroll", "")); + cubeCards.add(new CardIdentity("Cyclonic Rift", "")); + cubeCards.add(new CardIdentity("Dack Fayden", "")); + cubeCards.add(new CardIdentity("Dack's Duplicate", "")); + cubeCards.add(new CardIdentity("Damnation", "")); + cubeCards.add(new CardIdentity("Daretti, Scrap Savant", "")); + cubeCards.add(new CardIdentity("Dark Confidant", "")); + cubeCards.add(new CardIdentity("Dark Ritual", "")); + cubeCards.add(new CardIdentity("Dauthi Horror", "")); + cubeCards.add(new CardIdentity("Day of Judgment", "")); + cubeCards.add(new CardIdentity("Daze", "")); + cubeCards.add(new CardIdentity("Deathrite Shaman", "")); + cubeCards.add(new CardIdentity("Deceiver Exarch", "")); + cubeCards.add(new CardIdentity("Decree of Justice", "")); + cubeCards.add(new CardIdentity("Deep Analysis", "")); + cubeCards.add(new CardIdentity("Defense of the Heart", "")); + cubeCards.add(new CardIdentity("Demonic Tutor", "")); + cubeCards.add(new CardIdentity("Deranged Hermit", "")); + cubeCards.add(new CardIdentity("Desecration Demon", "")); + cubeCards.add(new CardIdentity("Desertion", "")); + cubeCards.add(new CardIdentity("Detention Sphere", "")); + cubeCards.add(new CardIdentity("Devil's Play", "")); + cubeCards.add(new CardIdentity("Devoted Druid", "")); + cubeCards.add(new CardIdentity("Diabolic Servitude", "")); + cubeCards.add(new CardIdentity("Dig Through Time", "")); + cubeCards.add(new CardIdentity("Diregraf Ghoul", "")); + cubeCards.add(new CardIdentity("Disciple of Bolas", "")); + cubeCards.add(new CardIdentity("Disenchant", "")); + cubeCards.add(new CardIdentity("Disfigure", "")); + cubeCards.add(new CardIdentity("Dismember", "")); + cubeCards.add(new CardIdentity("Dissipate", "")); + cubeCards.add(new CardIdentity("Domri Rade", "")); + cubeCards.add(new CardIdentity("Doom Blade", "")); + cubeCards.add(new CardIdentity("Dragon Hunter", "")); + cubeCards.add(new CardIdentity("Dragonskull Summit", "")); + cubeCards.add(new CardIdentity("Dreadbore", "")); + cubeCards.add(new CardIdentity("Drowned Catacomb", "")); + cubeCards.add(new CardIdentity("Dryad Militant", "")); + cubeCards.add(new CardIdentity("Dualcaster Mage", "")); + cubeCards.add(new CardIdentity("Duress", "")); + cubeCards.add(new CardIdentity("Duskmantle Seer", "")); + cubeCards.add(new CardIdentity("Earthquake", "")); + cubeCards.add(new CardIdentity("Edric, Spymaster of Trest", "")); + cubeCards.add(new CardIdentity("Eidolon of the Great Revel", "")); + cubeCards.add(new CardIdentity("Eight-and-a-Half-Tails", "")); + cubeCards.add(new CardIdentity("Electrolyze", "")); + cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite", "")); + cubeCards.add(new CardIdentity("Elspeth, Knight-Errant", "")); + cubeCards.add(new CardIdentity("Elspeth, Sun's Champion", "")); + cubeCards.add(new CardIdentity("Elves of Deep Shadow", "")); + cubeCards.add(new CardIdentity("Elvish Mystic", "")); + cubeCards.add(new CardIdentity("Ember Hauler", "")); + cubeCards.add(new CardIdentity("Emeria Angel", "")); + cubeCards.add(new CardIdentity("Empty the Warrens", "")); + cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn", "")); + cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); + cubeCards.add(new CardIdentity("Engineered Explosives", "")); + cubeCards.add(new CardIdentity("Enlightened Tutor", "")); + cubeCards.add(new CardIdentity("Entomb", "")); + cubeCards.add(new CardIdentity("Entreat the Angels", "")); + cubeCards.add(new CardIdentity("Epochrasite", "")); + cubeCards.add(new CardIdentity("Essence Scatter", "")); + cubeCards.add(new CardIdentity("Eternal Dragon", "")); + cubeCards.add(new CardIdentity("Eternal Witness", "")); + cubeCards.add(new CardIdentity("Everflowing Chalice", "")); + cubeCards.add(new CardIdentity("Evolving Wilds", "")); + cubeCards.add(new CardIdentity("Exhume", "")); + cubeCards.add(new CardIdentity("Experiment One", "")); + cubeCards.add(new CardIdentity("Explore", "")); + cubeCards.add(new CardIdentity("Fact or Fiction", "")); + cubeCards.add(new CardIdentity("Faithless Looting", "")); + cubeCards.add(new CardIdentity("Faith's Fetters", "")); + cubeCards.add(new CardIdentity("Falkenrath Aristocrat", "")); + cubeCards.add(new CardIdentity("Far // Away", "")); + cubeCards.add(new CardIdentity("Farseek", "")); + cubeCards.add(new CardIdentity("Fastbond", "")); + cubeCards.add(new CardIdentity("Fathom Seer", "")); + cubeCards.add(new CardIdentity("Fauna Shaman", "")); + cubeCards.add(new CardIdentity("Fellwar Stone", "")); + cubeCards.add(new CardIdentity("Fiend Hunter", "")); + cubeCards.add(new CardIdentity("Figure of Destiny", "")); + cubeCards.add(new CardIdentity("Fire // Ice", "")); + cubeCards.add(new CardIdentity("Fireblast", "")); + cubeCards.add(new CardIdentity("Firebolt", "")); + cubeCards.add(new CardIdentity("Firedrinker Satyr", "")); + cubeCards.add(new CardIdentity("Firefist Striker", "")); + cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); + cubeCards.add(new CardIdentity("Flametongue Kavu", "")); + cubeCards.add(new CardIdentity("Flickerwisp", "")); + cubeCards.add(new CardIdentity("Flooded Strand", "")); + cubeCards.add(new CardIdentity("Forbid", "")); + cubeCards.add(new CardIdentity("Forbidden Alchemy", "")); + cubeCards.add(new CardIdentity("Force of Will", "")); + cubeCards.add(new CardIdentity("Frantic Search", "")); + cubeCards.add(new CardIdentity("Frenzied Goblin", "")); + cubeCards.add(new CardIdentity("Frost Titan", "")); + cubeCards.add(new CardIdentity("Future Sight", "")); + cubeCards.add(new CardIdentity("Fyndhorn Elves", "")); + cubeCards.add(new CardIdentity("Gaea's Cradle", "")); + cubeCards.add(new CardIdentity("Gamble", "")); + cubeCards.add(new CardIdentity("Garruk Relentless", "")); + cubeCards.add(new CardIdentity("Garruk Wildspeaker", "")); + cubeCards.add(new CardIdentity("Garruk, Primal Hunter", "")); + cubeCards.add(new CardIdentity("Gatekeeper of Malakir", "")); + cubeCards.add(new CardIdentity("Gavony Township", "")); + cubeCards.add(new CardIdentity("Geist of Saint Traft", "")); + cubeCards.add(new CardIdentity("Genesis Wave", "")); + cubeCards.add(new CardIdentity("Genesis", "")); + cubeCards.add(new CardIdentity("Ghitu Encampment", "")); + cubeCards.add(new CardIdentity("Gideon Jura", "")); + cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); + cubeCards.add(new CardIdentity("Gifts Ungiven", "")); + cubeCards.add(new CardIdentity("Gilded Drake", "")); + cubeCards.add(new CardIdentity("Gilded Lotus", "")); + cubeCards.add(new CardIdentity("Gitaxian Probe", "")); + cubeCards.add(new CardIdentity("Glacial Fortress", "")); + cubeCards.add(new CardIdentity("Glen Elendra Archmage", "")); + cubeCards.add(new CardIdentity("Gnarled Scarhide", "")); + cubeCards.add(new CardIdentity("Go for the Throat", "")); + cubeCards.add(new CardIdentity("Goblin Bushwhacker", "")); + cubeCards.add(new CardIdentity("Goblin Guide", "")); + cubeCards.add(new CardIdentity("Goblin Rabblemaster", "")); + cubeCards.add(new CardIdentity("Goblin Ruinblaster", "")); + cubeCards.add(new CardIdentity("Goblin Wardriver", "")); + cubeCards.add(new CardIdentity("Goblin Welder", "")); + cubeCards.add(new CardIdentity("Godless Shrine", "")); + cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); + cubeCards.add(new CardIdentity("Grafted Wargear", "")); + cubeCards.add(new CardIdentity("Grave Titan", "")); + cubeCards.add(new CardIdentity("Gravecrawler", "")); + cubeCards.add(new CardIdentity("Greater Gargadon", "")); + cubeCards.add(new CardIdentity("Green Sun's Zenith", "")); + cubeCards.add(new CardIdentity("Grim Lavamancer", "")); + cubeCards.add(new CardIdentity("Grim Monolith", "")); + cubeCards.add(new CardIdentity("Griselbrand", "")); + cubeCards.add(new CardIdentity("Gush", "")); + cubeCards.add(new CardIdentity("Guul Draz Assassin", "")); + cubeCards.add(new CardIdentity("Hallowed Burial", "")); + cubeCards.add(new CardIdentity("Hallowed Fountain", "")); + cubeCards.add(new CardIdentity("Harmonize", "")); + cubeCards.add(new CardIdentity("Harrow", "")); + cubeCards.add(new CardIdentity("Heartbeat of Spring", "")); + cubeCards.add(new CardIdentity("Hellrider", "")); + cubeCards.add(new CardIdentity("Hell's Thunder", "")); + cubeCards.add(new CardIdentity("Hellspark Elemental", "")); + cubeCards.add(new CardIdentity("Herald of Torment", "")); + cubeCards.add(new CardIdentity("Hero of Bladehold", "")); + cubeCards.add(new CardIdentity("Hero of Oxid Ridge", "")); + cubeCards.add(new CardIdentity("Hero's Downfall", "")); + cubeCards.add(new CardIdentity("Hinterland Harbor", "")); + cubeCards.add(new CardIdentity("Hokori, Dust Drinker", "")); + cubeCards.add(new CardIdentity("Honor of the Pure", "")); + cubeCards.add(new CardIdentity("Huntmaster of the Fells", "")); + cubeCards.add(new CardIdentity("Hymn to Tourach", "")); + cubeCards.add(new CardIdentity("Hypnotic Specter", "")); + cubeCards.add(new CardIdentity("Imperial Recruiter", "")); + cubeCards.add(new CardIdentity("Imposing Sovereign", "")); + cubeCards.add(new CardIdentity("Impulse", "")); + cubeCards.add(new CardIdentity("Incinerate", "")); + cubeCards.add(new CardIdentity("Indrik Stomphowler", "")); + cubeCards.add(new CardIdentity("Inferno Titan", "")); + cubeCards.add(new CardIdentity("Ink-Eyes, Servant of Oni", "")); + cubeCards.add(new CardIdentity("Innocent Blood", "")); + cubeCards.add(new CardIdentity("Inquisition of Kozilek", "")); + cubeCards.add(new CardIdentity("Into the Roil", "")); + cubeCards.add(new CardIdentity("Intuition", "")); + cubeCards.add(new CardIdentity("Iona, Shield of Emeria", "")); + cubeCards.add(new CardIdentity("Isamaru, Hound of Konda", "")); + cubeCards.add(new CardIdentity("Isochron Scepter", "")); + cubeCards.add(new CardIdentity("Isolated Chapel", "")); + cubeCards.add(new CardIdentity("Izzet Charm", "")); + cubeCards.add(new CardIdentity("Jace Beleren", "")); + cubeCards.add(new CardIdentity("Jace, Architect of Thought", "")); + cubeCards.add(new CardIdentity("Jace, the Mind Sculptor", "")); + cubeCards.add(new CardIdentity("Jackal Pup", "")); + cubeCards.add(new CardIdentity("Jokulhaups", "")); + cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); + cubeCards.add(new CardIdentity("Journey to Nowhere", "")); + cubeCards.add(new CardIdentity("Kami of Ancient Law", "")); + cubeCards.add(new CardIdentity("Karakas", "")); + cubeCards.add(new CardIdentity("Kargan Dragonlord", "")); + cubeCards.add(new CardIdentity("Karmic Guide", "")); + cubeCards.add(new CardIdentity("Karn Liberated", "")); + cubeCards.add(new CardIdentity("Keldon Champion", "")); + cubeCards.add(new CardIdentity("Keldon Marauders", "")); + cubeCards.add(new CardIdentity("Kiki-Jiki, Mirror Breaker", "")); + cubeCards.add(new CardIdentity("Kiora, the Crashing Wave", "")); + cubeCards.add(new CardIdentity("Kiora's Follower", "")); + cubeCards.add(new CardIdentity("Kira, Great Glass-Spinner", "")); + cubeCards.add(new CardIdentity("Kitchen Finks", "")); + cubeCards.add(new CardIdentity("Kjeldoran Outpost", "")); + cubeCards.add(new CardIdentity("Knight of Infamy", "")); + cubeCards.add(new CardIdentity("Knight of Meadowgrain", "")); + cubeCards.add(new CardIdentity("Knight of the Reliquary", "")); + cubeCards.add(new CardIdentity("Kodama's Reach", "")); + cubeCards.add(new CardIdentity("Kokusho, the Evening Star", "")); + cubeCards.add(new CardIdentity("Kolaghan's Command", "")); + cubeCards.add(new CardIdentity("Kor Sanctifiers", "")); + cubeCards.add(new CardIdentity("Kor Skyfisher", "")); + cubeCards.add(new CardIdentity("Koth of the Hammer", "")); + cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth", "")); + cubeCards.add(new CardIdentity("Land Tax", "")); + cubeCards.add(new CardIdentity("Lavaclaw Reaches", "")); + cubeCards.add(new CardIdentity("Legacy's Allure", "")); + cubeCards.add(new CardIdentity("Library of Alexandria", "")); + cubeCards.add(new CardIdentity("Life from the Loam", "")); + cubeCards.add(new CardIdentity("Lightning Bolt", "")); + cubeCards.add(new CardIdentity("Lightning Greaves", "")); + cubeCards.add(new CardIdentity("Lightning Helix", "")); + cubeCards.add(new CardIdentity("Lightning Mauler", "")); + cubeCards.add(new CardIdentity("Lightning Strike", "")); + cubeCards.add(new CardIdentity("Liliana of the Veil", "")); + cubeCards.add(new CardIdentity("Liliana Vess", "")); + cubeCards.add(new CardIdentity("Lingering Souls", "")); + cubeCards.add(new CardIdentity("Living Death", "")); + cubeCards.add(new CardIdentity("Llanowar Elves", "")); + cubeCards.add(new CardIdentity("Lodestone Golem", "")); + cubeCards.add(new CardIdentity("Looter il-Kor", "")); + cubeCards.add(new CardIdentity("Lotus Bloom", "")); + cubeCards.add(new CardIdentity("Lotus Cobra", "")); + cubeCards.add(new CardIdentity("Lotus Petal", "")); + cubeCards.add(new CardIdentity("Loyal Cathar", "")); + cubeCards.add(new CardIdentity("Loyal Retainers", "")); + cubeCards.add(new CardIdentity("Luminarch Ascension", "")); + cubeCards.add(new CardIdentity("Maelstrom Pulse", "")); + cubeCards.add(new CardIdentity("Magma Jet", "")); + cubeCards.add(new CardIdentity("Makeshift Mannequin", "")); + cubeCards.add(new CardIdentity("Mana Confluence", "")); + cubeCards.add(new CardIdentity("Mana Crypt", "")); + cubeCards.add(new CardIdentity("Mana Drain", "")); + cubeCards.add(new CardIdentity("Mana Leak", "")); + cubeCards.add(new CardIdentity("Mana Vault", "")); + cubeCards.add(new CardIdentity("Manamorphose", "")); + cubeCards.add(new CardIdentity("Man-o'-War", "")); + cubeCards.add(new CardIdentity("Mardu Woe-Reaper", "")); + cubeCards.add(new CardIdentity("Marsh Flats", "")); + cubeCards.add(new CardIdentity("Martial Coup", "")); + cubeCards.add(new CardIdentity("Master of the Feast", "")); + cubeCards.add(new CardIdentity("Master of the Wild Hunt", "")); + cubeCards.add(new CardIdentity("Masticore", "")); + cubeCards.add(new CardIdentity("Mayor of Avabruck", "")); + cubeCards.add(new CardIdentity("Maze of Ith", "")); + cubeCards.add(new CardIdentity("Meloku the Clouded Mirror", "")); + cubeCards.add(new CardIdentity("Memory Jar", "")); + cubeCards.add(new CardIdentity("Memory Lapse", "")); + cubeCards.add(new CardIdentity("Mentor of the Meek", "")); + cubeCards.add(new CardIdentity("Mesmeric Fiend", "")); + cubeCards.add(new CardIdentity("Mikaeus, the Lunarch", "")); + cubeCards.add(new CardIdentity("Mimic Vat", "")); + cubeCards.add(new CardIdentity("Mind Shatter", "")); + cubeCards.add(new CardIdentity("Mind Stone", "")); + cubeCards.add(new CardIdentity("Mind's Desire", "")); + cubeCards.add(new CardIdentity("Mindslaver", "")); + cubeCards.add(new CardIdentity("Mirari's Wake", "")); + cubeCards.add(new CardIdentity("Mirran Crusader", "")); + cubeCards.add(new CardIdentity("Mirror Entity", "")); + cubeCards.add(new CardIdentity("Miscalculation", "")); + cubeCards.add(new CardIdentity("Mishra's Factory", "")); + cubeCards.add(new CardIdentity("Misty Rainforest", "")); + cubeCards.add(new CardIdentity("Moat", "")); + cubeCards.add(new CardIdentity("Mogg Flunkies", "")); + cubeCards.add(new CardIdentity("Mogg War Marshal", "")); + cubeCards.add(new CardIdentity("Mold Shambler", "")); + cubeCards.add(new CardIdentity("Molten Rain", "")); + cubeCards.add(new CardIdentity("Molten-Tail Masticore", "")); + cubeCards.add(new CardIdentity("Momentary Blink", "")); + cubeCards.add(new CardIdentity("Moment's Peace", "")); + cubeCards.add(new CardIdentity("Monastery Mentor", "")); + cubeCards.add(new CardIdentity("Mortarpod", "")); + cubeCards.add(new CardIdentity("Mother of Runes", "")); + cubeCards.add(new CardIdentity("Mox Diamond", "")); + cubeCards.add(new CardIdentity("Mox Emerald", "")); + cubeCards.add(new CardIdentity("Mox Jet", "")); + cubeCards.add(new CardIdentity("Mox Pearl", "")); + cubeCards.add(new CardIdentity("Mox Ruby", "")); + cubeCards.add(new CardIdentity("Mox Sapphire", "")); + cubeCards.add(new CardIdentity("Mulldrifter", "")); + cubeCards.add(new CardIdentity("Murderous Cut", "")); + cubeCards.add(new CardIdentity("Murderous Redcap", "")); + cubeCards.add(new CardIdentity("Mutavault", "")); + cubeCards.add(new CardIdentity("Myr Battlesphere", "")); + cubeCards.add(new CardIdentity("Mystic Snake", "")); + cubeCards.add(new CardIdentity("Mystical Tutor", "")); + cubeCards.add(new CardIdentity("Nantuko Shade", "")); + cubeCards.add(new CardIdentity("Narcolepsy", "")); + cubeCards.add(new CardIdentity("Natural Order", "")); + cubeCards.add(new CardIdentity("Naturalize", "")); + cubeCards.add(new CardIdentity("Necromancy", "")); + cubeCards.add(new CardIdentity("Necropotence", "")); + cubeCards.add(new CardIdentity("Negate", "")); + cubeCards.add(new CardIdentity("Nekrataal", "")); + cubeCards.add(new CardIdentity("Nether Void", "")); + cubeCards.add(new CardIdentity("Nevinyrral's Disk", "")); + cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); + cubeCards.add(new CardIdentity("Nezumi Shortfang", "")); + cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker", "")); + cubeCards.add(new CardIdentity("Night's Whisper", "")); + cubeCards.add(new CardIdentity("Nightscape Familiar", "")); + cubeCards.add(new CardIdentity("Nissa, Worldwaker", "")); + cubeCards.add(new CardIdentity("Noble Hierarch", "")); + cubeCards.add(new CardIdentity("Oath of Druids", "")); + cubeCards.add(new CardIdentity("Oblivion Ring", "")); + cubeCards.add(new CardIdentity("Obstinate Baloth", "")); + cubeCards.add(new CardIdentity("Obzedat, Ghost Council", "")); + cubeCards.add(new CardIdentity("Ohran Viper", "")); + cubeCards.add(new CardIdentity("Omenspeaker", "")); + cubeCards.add(new CardIdentity("Omniscience", "")); + cubeCards.add(new CardIdentity("Oona's Prowler", "")); + cubeCards.add(new CardIdentity("Opposition", "")); + cubeCards.add(new CardIdentity("Opt", "")); + cubeCards.add(new CardIdentity("Oracle of Mul Daya", "")); + cubeCards.add(new CardIdentity("Overgrown Battlement", "")); + cubeCards.add(new CardIdentity("Overgrown Tomb", "")); + cubeCards.add(new CardIdentity("Overrun", "")); + cubeCards.add(new CardIdentity("Pack Rat", "")); + cubeCards.add(new CardIdentity("Pact of Negation", "")); + cubeCards.add(new CardIdentity("Palinchron", "")); + cubeCards.add(new CardIdentity("Palladium Myr", "")); + cubeCards.add(new CardIdentity("Path to Exile", "")); + cubeCards.add(new CardIdentity("Pernicious Deed", "")); + cubeCards.add(new CardIdentity("Pestermite", "")); + cubeCards.add(new CardIdentity("Phantasmal Image", "")); + cubeCards.add(new CardIdentity("Phyrexian Arena", "")); + cubeCards.add(new CardIdentity("Phyrexian Metamorph", "")); + cubeCards.add(new CardIdentity("Phyrexian Obliterator", "")); + cubeCards.add(new CardIdentity("Phyrexian Rager", "")); + cubeCards.add(new CardIdentity("Phyrexian Revoker", "")); + cubeCards.add(new CardIdentity("Pillage", "")); + cubeCards.add(new CardIdentity("Pithing Needle", "")); + cubeCards.add(new CardIdentity("Plateau", "")); + cubeCards.add(new CardIdentity("Plated Geopede", "")); + cubeCards.add(new CardIdentity("Plow Under", "")); + cubeCards.add(new CardIdentity("Plumeveil", "")); + cubeCards.add(new CardIdentity("Polluted Delta", "")); + cubeCards.add(new CardIdentity("Polukranos, World Eater", "")); + cubeCards.add(new CardIdentity("Ponder", "")); + cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); + cubeCards.add(new CardIdentity("Precursor Golem", "")); + cubeCards.add(new CardIdentity("Preordain", "")); + cubeCards.add(new CardIdentity("Primal Command", "")); + cubeCards.add(new CardIdentity("Primeval Titan", "")); + cubeCards.add(new CardIdentity("Primordial Hydra", "")); + cubeCards.add(new CardIdentity("Prismatic Lens", "")); + cubeCards.add(new CardIdentity("Pristine Talisman", "")); + cubeCards.add(new CardIdentity("Profane Command", "")); + cubeCards.add(new CardIdentity("Prognostic Sphinx", "")); + cubeCards.add(new CardIdentity("Prophetic Bolt", "")); + cubeCards.add(new CardIdentity("Psionic Blast", "")); + cubeCards.add(new CardIdentity("Psychatog", "")); + cubeCards.add(new CardIdentity("Puppeteer Clique", "")); + cubeCards.add(new CardIdentity("Purphoros, God of the Forge", "")); + cubeCards.add(new CardIdentity("Putrefy", "")); + cubeCards.add(new CardIdentity("Putrid Leech", "")); + cubeCards.add(new CardIdentity("Pyroclasm", "")); + cubeCards.add(new CardIdentity("Qasali Pridemage", "")); + cubeCards.add(new CardIdentity("Raging Ravine", "")); + cubeCards.add(new CardIdentity("Rakdos Cackler", "")); + cubeCards.add(new CardIdentity("Ral Zarek", "")); + cubeCards.add(new CardIdentity("Rampant Growth", "")); + cubeCards.add(new CardIdentity("Rancor", "")); + cubeCards.add(new CardIdentity("Ranger of Eos", "")); + cubeCards.add(new CardIdentity("Ravages of War", "")); + cubeCards.add(new CardIdentity("Ravenous Baboons", "")); + cubeCards.add(new CardIdentity("Reanimate", "")); + cubeCards.add(new CardIdentity("Reckless Charge", "")); + cubeCards.add(new CardIdentity("Reckless Waif", "")); + cubeCards.add(new CardIdentity("Reclamation Sage", "")); + cubeCards.add(new CardIdentity("Recurring Nightmare", "")); + cubeCards.add(new CardIdentity("Regrowth", "")); + cubeCards.add(new CardIdentity("Relic of Progenitus", "")); + cubeCards.add(new CardIdentity("Remand", "")); + cubeCards.add(new CardIdentity("Repeal", "")); + cubeCards.add(new CardIdentity("Restoration Angel", "")); + cubeCards.add(new CardIdentity("Reveillark", "")); + cubeCards.add(new CardIdentity("Rift Bolt", "")); + cubeCards.add(new CardIdentity("Riftwing Cloudskate", "")); + cubeCards.add(new CardIdentity("Rishadan Port", "")); + cubeCards.add(new CardIdentity("Rofellos, Llanowar Emissary", "")); + cubeCards.add(new CardIdentity("Rolling Earthquake", "")); + cubeCards.add(new CardIdentity("Rootbound Crag", "")); + cubeCards.add(new CardIdentity("Rout", "")); + cubeCards.add(new CardIdentity("Rude Awakening", "")); + cubeCards.add(new CardIdentity("Sacred Foundry", "")); + cubeCards.add(new CardIdentity("Sakura-Tribe Elder", "")); + cubeCards.add(new CardIdentity("Sarkhan, the Dragonspeaker", "")); + cubeCards.add(new CardIdentity("Savannah", "")); + cubeCards.add(new CardIdentity("Scalding Tarn", "")); + cubeCards.add(new CardIdentity("Scavenging Ooze", "")); + cubeCards.add(new CardIdentity("Scorned Villager", "")); + cubeCards.add(new CardIdentity("Scroll Rack", "")); + cubeCards.add(new CardIdentity("Scrubland", "")); + cubeCards.add(new CardIdentity("Sea Gate Oracle", "")); + cubeCards.add(new CardIdentity("Search for Tomorrow", "")); + cubeCards.add(new CardIdentity("Searing Blaze", "")); + cubeCards.add(new CardIdentity("Searing Spear", "")); + cubeCards.add(new CardIdentity("Sensei's Divining Top", "")); + cubeCards.add(new CardIdentity("Serendib Efreet", "")); + cubeCards.add(new CardIdentity("Shadowmage Infiltrator", "")); + cubeCards.add(new CardIdentity("Shelldock Isle", "")); + cubeCards.add(new CardIdentity("Sheoldred, Whispering One", "")); + cubeCards.add(new CardIdentity("Show and Tell", "")); + cubeCards.add(new CardIdentity("Shriekmaw", "")); + cubeCards.add(new CardIdentity("Shrine of Burning Rage", "")); + cubeCards.add(new CardIdentity("Siege-Gang Commander", "")); + cubeCards.add(new CardIdentity("Sign in Blood", "")); + cubeCards.add(new CardIdentity("Silverblade Paladin", "")); + cubeCards.add(new CardIdentity("Simic Sky Swallower", "")); + cubeCards.add(new CardIdentity("Sinkhole", "")); + cubeCards.add(new CardIdentity("Skinrender", "")); + cubeCards.add(new CardIdentity("Skithiryx, the Blight Dragon", "")); + cubeCards.add(new CardIdentity("Skullclamp", "")); + cubeCards.add(new CardIdentity("Slagstorm", "")); + cubeCards.add(new CardIdentity("Slaughter Pact", "")); + cubeCards.add(new CardIdentity("Smokestack", "")); + cubeCards.add(new CardIdentity("Snapcaster Mage", "")); + cubeCards.add(new CardIdentity("Sneak Attack", "")); + cubeCards.add(new CardIdentity("Sol Ring", "")); + cubeCards.add(new CardIdentity("Soldier of the Pantheon", "")); + cubeCards.add(new CardIdentity("Solemn Simulacrum", "")); + cubeCards.add(new CardIdentity("Soltari Champion", "")); + cubeCards.add(new CardIdentity("Soltari Priest", "")); + cubeCards.add(new CardIdentity("Song of the Dryads", "")); + cubeCards.add(new CardIdentity("Sorin Markov", "")); + cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad", "")); + cubeCards.add(new CardIdentity("Soulfire Grand Master", "")); + cubeCards.add(new CardIdentity("Sower of Temptation", "")); + cubeCards.add(new CardIdentity("Spear of Heliod", "")); + cubeCards.add(new CardIdentity("Spectral Procession", "")); + cubeCards.add(new CardIdentity("Spellskite", "")); + cubeCards.add(new CardIdentity("Sphere of the Suns", "")); + cubeCards.add(new CardIdentity("Sphinx of the Steel Wind", "")); + cubeCards.add(new CardIdentity("Sphinx's Revelation", "")); + cubeCards.add(new CardIdentity("Spikeshot Elder", "")); + cubeCards.add(new CardIdentity("Spirit of the Labyrinth", "")); + cubeCards.add(new CardIdentity("Splinter Twin", "")); + cubeCards.add(new CardIdentity("Squee, Goblin Nabob", "")); + cubeCards.add(new CardIdentity("Staggershock", "")); + cubeCards.add(new CardIdentity("Steam Augury", "")); + cubeCards.add(new CardIdentity("Steam Vents", "")); + cubeCards.add(new CardIdentity("Stillmoon Cavalier", "")); + cubeCards.add(new CardIdentity("Stirring Wildwood", "")); + cubeCards.add(new CardIdentity("Stoke the Flames", "")); + cubeCards.add(new CardIdentity("Stomping Ground", "")); + cubeCards.add(new CardIdentity("Stone Rain", "")); + cubeCards.add(new CardIdentity("Stonecloaker", "")); + cubeCards.add(new CardIdentity("Stoneforge Mystic", "")); + cubeCards.add(new CardIdentity("Stonewood Invocation", "")); + cubeCards.add(new CardIdentity("Stormblood Berserker", "")); + cubeCards.add(new CardIdentity("Strangleroot Geist", "")); + cubeCards.add(new CardIdentity("Stratus Dancer", "")); + cubeCards.add(new CardIdentity("Strip Mine", "")); + cubeCards.add(new CardIdentity("Stromkirk Noble", "")); + cubeCards.add(new CardIdentity("Student of Warfare", "")); + cubeCards.add(new CardIdentity("Sublime Archangel", "")); + cubeCards.add(new CardIdentity("Sulfur Falls", "")); + cubeCards.add(new CardIdentity("Sulfuric Vortex", "")); + cubeCards.add(new CardIdentity("Summoning Trap", "")); + cubeCards.add(new CardIdentity("Sun Titan", "")); + cubeCards.add(new CardIdentity("Sundering Titan", "")); + cubeCards.add(new CardIdentity("Sunpetal Grove", "")); + cubeCards.add(new CardIdentity("Supreme Verdict", "")); + cubeCards.add(new CardIdentity("Survival of the Fittest", "")); + cubeCards.add(new CardIdentity("Sword of Body and Mind", "")); + cubeCards.add(new CardIdentity("Sword of Feast and Famine", "")); + cubeCards.add(new CardIdentity("Sword of Fire and Ice", "")); + cubeCards.add(new CardIdentity("Sword of Light and Shadow", "")); + cubeCards.add(new CardIdentity("Sword of War and Peace", "")); + cubeCards.add(new CardIdentity("Swords to Plowshares", "")); + cubeCards.add(new CardIdentity("Sylvan Caryatid", "")); + cubeCards.add(new CardIdentity("Sylvan Library", "")); + cubeCards.add(new CardIdentity("Taiga", "")); + cubeCards.add(new CardIdentity("Tainted Pact", "")); + cubeCards.add(new CardIdentity("Talrand, Sky Summoner", "")); + cubeCards.add(new CardIdentity("Tamiyo, the Moon Sage", "")); + cubeCards.add(new CardIdentity("Tangle Wire", "")); + cubeCards.add(new CardIdentity("Tarmogoyf", "")); + cubeCards.add(new CardIdentity("Tectonic Edge", "")); + cubeCards.add(new CardIdentity("Teetering Peaks", "")); + cubeCards.add(new CardIdentity("Temple Garden", "")); + cubeCards.add(new CardIdentity("Temporal Isolation", "")); + cubeCards.add(new CardIdentity("Tendrils of Agony", "")); + cubeCards.add(new CardIdentity("Terastodon", "")); + cubeCards.add(new CardIdentity("Terminate", "")); + cubeCards.add(new CardIdentity("Terminus", "")); + cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); + cubeCards.add(new CardIdentity("Terror", "")); + cubeCards.add(new CardIdentity("Tezzeret the Seeker", "")); + cubeCards.add(new CardIdentity("Tezzeret, Agent of Bolas", "")); + cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben", "")); + cubeCards.add(new CardIdentity("The Abyss", "")); + cubeCards.add(new CardIdentity("The Tabernacle at Pendrell Vale", "")); + cubeCards.add(new CardIdentity("Thelonite Hermit", "")); + cubeCards.add(new CardIdentity("Thirst for Knowledge", "")); + cubeCards.add(new CardIdentity("Thornling", "")); + cubeCards.add(new CardIdentity("Thoughtseize", "")); + cubeCards.add(new CardIdentity("Thragtusk", "")); + cubeCards.add(new CardIdentity("Thran Dynamo", "")); + cubeCards.add(new CardIdentity("Through the Breach", "")); + cubeCards.add(new CardIdentity("Thrun, the Last Troll", "")); + cubeCards.add(new CardIdentity("Thundermaw Hellkite", "")); + cubeCards.add(new CardIdentity("Tidehollow Sculler", "")); + cubeCards.add(new CardIdentity("Time Spiral", "")); + cubeCards.add(new CardIdentity("Time Vault", "")); + cubeCards.add(new CardIdentity("Time Walk", "")); + cubeCards.add(new CardIdentity("Time Warp", "")); + cubeCards.add(new CardIdentity("Timetwister", "")); + cubeCards.add(new CardIdentity("Tinker", "")); + cubeCards.add(new CardIdentity("Tombstalker", "")); + cubeCards.add(new CardIdentity("Tooth and Nail", "")); + cubeCards.add(new CardIdentity("Torch Fiend", "")); + cubeCards.add(new CardIdentity("Tormented Hero", "")); + cubeCards.add(new CardIdentity("Tradewind Rider", "")); + cubeCards.add(new CardIdentity("Treachery", "")); + cubeCards.add(new CardIdentity("Treasure Cruise", "")); + cubeCards.add(new CardIdentity("Treetop Village", "")); + cubeCards.add(new CardIdentity("Trinket Mage", "")); + cubeCards.add(new CardIdentity("Triplicate Spirits", "")); + cubeCards.add(new CardIdentity("Tropical Island", "")); + cubeCards.add(new CardIdentity("Trygon Predator", "")); + cubeCards.add(new CardIdentity("Tundra", "")); + cubeCards.add(new CardIdentity("Turnabout", "")); + cubeCards.add(new CardIdentity("Ugin, the Spirit Dragon", "")); + cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre", "")); + cubeCards.add(new CardIdentity("Ultimate Price", "")); + cubeCards.add(new CardIdentity("Ulvenwald Tracker", "")); + cubeCards.add(new CardIdentity("Umezawa's Jitte", "")); + cubeCards.add(new CardIdentity("Underground Sea", "")); + cubeCards.add(new CardIdentity("Upheaval", "")); + cubeCards.add(new CardIdentity("Urabrask the Hidden", "")); + cubeCards.add(new CardIdentity("Urborg, Tomb of Yawgmoth", "")); + cubeCards.add(new CardIdentity("Vampire Hexmage", "")); + cubeCards.add(new CardIdentity("Vampire Lacerator", "")); + cubeCards.add(new CardIdentity("Vampire Nighthawk", "")); + cubeCards.add(new CardIdentity("Vampiric Tutor", "")); + cubeCards.add(new CardIdentity("Varolz, the Scar-Striped", "")); + cubeCards.add(new CardIdentity("Vault of the Archangel", "")); + cubeCards.add(new CardIdentity("Vedalken Shackles", "")); + cubeCards.add(new CardIdentity("Vendilion Clique", "")); + cubeCards.add(new CardIdentity("Vengevine", "")); + cubeCards.add(new CardIdentity("Venser, Shaper Savant", "")); + cubeCards.add(new CardIdentity("Venser, the Sojourner", "")); + cubeCards.add(new CardIdentity("Verdant Catacombs", "")); + cubeCards.add(new CardIdentity("Vexing Devil", "")); + cubeCards.add(new CardIdentity("Vindicate", "")); + cubeCards.add(new CardIdentity("Voice of Resurgence", "")); + cubeCards.add(new CardIdentity("Voidslime", "")); + cubeCards.add(new CardIdentity("Volcanic Island", "")); + cubeCards.add(new CardIdentity("Volrath's Stronghold", "")); + cubeCards.add(new CardIdentity("Voltaic Key", "")); + cubeCards.add(new CardIdentity("Vorapede", "")); + cubeCards.add(new CardIdentity("Vraska the Unseen", "")); + cubeCards.add(new CardIdentity("Wake Thrasher", "")); + cubeCards.add(new CardIdentity("Wall of Blossoms", "")); + cubeCards.add(new CardIdentity("Wall of Denial", "")); + cubeCards.add(new CardIdentity("Wall of Omens", "")); + cubeCards.add(new CardIdentity("Wall of Reverence", "")); + cubeCards.add(new CardIdentity("Wall of Roots", "")); + cubeCards.add(new CardIdentity("Wasteland", "")); + cubeCards.add(new CardIdentity("Waterfront Bouncer", "")); + cubeCards.add(new CardIdentity("Watery Grave", "")); + cubeCards.add(new CardIdentity("Weathered Wayfarer", "")); + cubeCards.add(new CardIdentity("Werebear", "")); + cubeCards.add(new CardIdentity("Wheel of Fortune", "")); + cubeCards.add(new CardIdentity("Wickerbough Elder", "")); + cubeCards.add(new CardIdentity("Wildfire", "")); + cubeCards.add(new CardIdentity("Windbrisk Heights", "")); + cubeCards.add(new CardIdentity("Windswept Heath", "")); + cubeCards.add(new CardIdentity("Wolfir Avenger", "")); + cubeCards.add(new CardIdentity("Wood Elves", "")); + cubeCards.add(new CardIdentity("Wooded Foothills", "")); + cubeCards.add(new CardIdentity("Woodfall Primus", "")); + cubeCards.add(new CardIdentity("Woodland Cemetery", "")); + cubeCards.add(new CardIdentity("Worn Powerstone", "")); + cubeCards.add(new CardIdentity("Worship", "")); + cubeCards.add(new CardIdentity("Wrath of God", "")); + cubeCards.add(new CardIdentity("Wurmcoil Engine", "")); + cubeCards.add(new CardIdentity("Yavimaya Elder", "")); + cubeCards.add(new CardIdentity("Yavimaya Hollow", "")); + cubeCards.add(new CardIdentity("Yawgmoth's Bargain", "")); + cubeCards.add(new CardIdentity("Yawgmoth's Will", "")); + cubeCards.add(new CardIdentity("Yeva, Nature's Herald", "")); + cubeCards.add(new CardIdentity("Yosei, the Morning Star", "")); + cubeCards.add(new CardIdentity("Young Pyromancer", "")); + cubeCards.add(new CardIdentity("Zealous Conscripts", "")); + cubeCards.add(new CardIdentity("Zo-Zu the Punisher", "")); + cubeCards.add(new CardIdentity("Zurgo Bellstriker", "")); + } +} diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGCube.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGCube.java index c401bb0fa82..509cb3d84cf 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGCube.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGCube.java @@ -1,545 +1,545 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.tournament.cubes; - -import mage.game.draft.DraftCube; - -/** - * - * @author LevelX2 - */ -public class MTGCube extends DraftCube { - - public MTGCube() { - super("www.mtgcube.com (502 cards)"); // http://www.mtgcube.com - - cubeCards.add(new CardIdentity("Abrupt Decay", "")); - cubeCards.add(new CardIdentity("Academy Ruins", "")); - cubeCards.add(new CardIdentity("Accorder Paladin", "")); - cubeCards.add(new CardIdentity("Acidic Slime", "")); - cubeCards.add(new CardIdentity("Aetherling", "")); - cubeCards.add(new CardIdentity("Ajani Goldmane", "")); - cubeCards.add(new CardIdentity("Ajani Vengeant", "")); - cubeCards.add(new CardIdentity("Ancestral Recall", "")); - cubeCards.add(new CardIdentity("Ancestral Vision", "")); - cubeCards.add(new CardIdentity("Animate Dead", "")); - cubeCards.add(new CardIdentity("Arbor Elf", "")); - cubeCards.add(new CardIdentity("Arc Lightning", "")); - cubeCards.add(new CardIdentity("Arc Trail", "")); - cubeCards.add(new CardIdentity("Arcane Denial", "")); - cubeCards.add(new CardIdentity("Archangel of Thune", "")); - cubeCards.add(new CardIdentity("Arid Mesa", "")); - cubeCards.add(new CardIdentity("Armageddon", "")); - cubeCards.add(new CardIdentity("Ash Zealot", "")); - cubeCards.add(new CardIdentity("Augur of Bolas", "")); - cubeCards.add(new CardIdentity("Avalanche Riders", "")); - cubeCards.add(new CardIdentity("Avenger of Zendikar", "")); - cubeCards.add(new CardIdentity("Awakening Zone", "")); - cubeCards.add(new CardIdentity("Azorius Signet", "")); - cubeCards.add(new CardIdentity("Badlands", "")); - cubeCards.add(new CardIdentity("Balance", "")); - cubeCards.add(new CardIdentity("Baleful Strix", "")); - cubeCards.add(new CardIdentity("Bane of the Living", "")); - cubeCards.add(new CardIdentity("Baneslayer Angel", "")); - cubeCards.add(new CardIdentity("Bant", "")); - cubeCards.add(new CardIdentity("Batterskull", "")); - cubeCards.add(new CardIdentity("Battlefield Forge", "")); - cubeCards.add(new CardIdentity("Bayou", "")); - cubeCards.add(new CardIdentity("Birds of Paradise", "")); - cubeCards.add(new CardIdentity("Birthing Pod", "")); - cubeCards.add(new CardIdentity("Bitterblossom", "")); - cubeCards.add(new CardIdentity("Black Lotus", "")); - cubeCards.add(new CardIdentity("Black Vise", "")); - cubeCards.add(new CardIdentity("Blade Splicer", "")); - cubeCards.add(new CardIdentity("Blightning", "")); - cubeCards.add(new CardIdentity("Blistering Firecat", "")); - cubeCards.add(new CardIdentity("Blood Crypt", "")); - cubeCards.add(new CardIdentity("Blood Scrivener", "")); - cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); - cubeCards.add(new CardIdentity("Bloodghast", "")); - cubeCards.add(new CardIdentity("Bloodstained Mire", "")); - cubeCards.add(new CardIdentity("Bone Shredder", "")); - cubeCards.add(new CardIdentity("Bonesplitter", "")); - cubeCards.add(new CardIdentity("Bonfire of the Damned", "")); - cubeCards.add(new CardIdentity("Boros Charm", "")); - cubeCards.add(new CardIdentity("Boros Reckoner", "")); - cubeCards.add(new CardIdentity("Boros Signet", "")); - cubeCards.add(new CardIdentity("Braids, Cabal Minion", "")); - cubeCards.add(new CardIdentity("Brainstorm", "")); - cubeCards.add(new CardIdentity("Breeding Pool", "")); - cubeCards.add(new CardIdentity("Bribery", "")); - cubeCards.add(new CardIdentity("Broodmate Dragon", "")); - cubeCards.add(new CardIdentity("Burning of Xinye", "")); - cubeCards.add(new CardIdentity("Burst Lightning", "")); - cubeCards.add(new CardIdentity("Call of the Herd", "")); - cubeCards.add(new CardIdentity("Carnophage", "")); - cubeCards.add(new CardIdentity("Catastrophe", "")); - cubeCards.add(new CardIdentity("Caves of Koilos", "")); - cubeCards.add(new CardIdentity("Celestial Colonnade", "")); - cubeCards.add(new CardIdentity("Chain Lightning", "")); - cubeCards.add(new CardIdentity("Chainers Edict", "")); - cubeCards.add(new CardIdentity("Chameleon Colossus", "")); - cubeCards.add(new CardIdentity("Chandra Nalaar", "")); - cubeCards.add(new CardIdentity("Chandra, Pyromaster", "")); - cubeCards.add(new CardIdentity("Char", "")); - cubeCards.add(new CardIdentity("Chrome Mox", "")); - cubeCards.add(new CardIdentity("City of Brass", "")); - cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); - cubeCards.add(new CardIdentity("Coalition Relic", "")); - cubeCards.add(new CardIdentity("Coldsteel Heart", "")); - cubeCards.add(new CardIdentity("Consecrated Sphinx", "")); - cubeCards.add(new CardIdentity("Consuming Vapors", "")); - cubeCards.add(new CardIdentity("Contagion", "")); - cubeCards.add(new CardIdentity("Control Magic", "")); - cubeCards.add(new CardIdentity("Counterspell", "")); - cubeCards.add(new CardIdentity("Creakwood Liege", "")); - cubeCards.add(new CardIdentity("Creeping Tar Pit", "")); - cubeCards.add(new CardIdentity("Crucible of Worlds", "")); - cubeCards.add(new CardIdentity("Cryptic Command", "")); - cubeCards.add(new CardIdentity("Crystal Shard", "")); - cubeCards.add(new CardIdentity("Cultivate", "")); - cubeCards.add(new CardIdentity("Cursed Scroll", "")); - cubeCards.add(new CardIdentity("Damnation", "")); - cubeCards.add(new CardIdentity("Dance of the Dead", "")); - cubeCards.add(new CardIdentity("Dark Confidant", "")); - cubeCards.add(new CardIdentity("Dark Ritual", "")); - cubeCards.add(new CardIdentity("Day of Judgment", "")); - cubeCards.add(new CardIdentity("Daze", "")); - cubeCards.add(new CardIdentity("Deep Analysis", "")); - cubeCards.add(new CardIdentity("Demonic Tutor", "")); - cubeCards.add(new CardIdentity("Deranged Hermit", "")); - cubeCards.add(new CardIdentity("Detention Sphere", "")); - cubeCards.add(new CardIdentity("Diabolic Edict", "")); - cubeCards.add(new CardIdentity("Dimir Signet", "")); - cubeCards.add(new CardIdentity("Diregraf Ghoul", "")); - cubeCards.add(new CardIdentity("Disenchant", "")); - cubeCards.add(new CardIdentity("Dismember", "")); - cubeCards.add(new CardIdentity("Dreadbore", "")); - cubeCards.add(new CardIdentity("Dryad Militant", "")); - cubeCards.add(new CardIdentity("Duress", "")); - cubeCards.add(new CardIdentity("Dust Bowl", "")); - cubeCards.add(new CardIdentity("Dwarven Blastminer", "")); - cubeCards.add(new CardIdentity("Earthquake", "")); - cubeCards.add(new CardIdentity("Edric, Spymaster of Trest", "")); - cubeCards.add(new CardIdentity("Electrolyze", "")); - cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite", "")); - cubeCards.add(new CardIdentity("Elite Vanguard", "")); - cubeCards.add(new CardIdentity("Elspeth, Knight Errant", "")); - cubeCards.add(new CardIdentity("Elspeth, Sun's Champion", "")); - cubeCards.add(new CardIdentity("Empty the Warrens", "")); - cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn", "")); - cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); - cubeCards.add(new CardIdentity("Enlightened Tutor", "")); - cubeCards.add(new CardIdentity("Entomb", "")); - cubeCards.add(new CardIdentity("Erratic Portal", "")); - cubeCards.add(new CardIdentity("Esper", "")); - cubeCards.add(new CardIdentity("Eternal Witness", "")); - cubeCards.add(new CardIdentity("Eureka", "")); - cubeCards.add(new CardIdentity("Everflowing Chalice", "")); - cubeCards.add(new CardIdentity("Evolving Wilds", "")); - cubeCards.add(new CardIdentity("Exalted Angel", "")); - cubeCards.add(new CardIdentity("Exhume", "")); - cubeCards.add(new CardIdentity("Experiment One", "")); - cubeCards.add(new CardIdentity("Fact or Fiction", "")); - cubeCards.add(new CardIdentity("Faerie Conclave", "")); - cubeCards.add(new CardIdentity("Faithless Looting", "")); - cubeCards.add(new CardIdentity("Faiths Fetters", "")); - cubeCards.add(new CardIdentity("Falkenrath Aristocrat", "")); - cubeCards.add(new CardIdentity("Fauna Shaman", "")); - cubeCards.add(new CardIdentity("Figure of Destiny", "")); - cubeCards.add(new CardIdentity("Fire // Ice ", "")); - cubeCards.add(new CardIdentity("Fire Imp", "")); - cubeCards.add(new CardIdentity("Firebolt", "")); - cubeCards.add(new CardIdentity("Firedrinker Satyr", "")); - cubeCards.add(new CardIdentity("Fireslinger", "")); - cubeCards.add(new CardIdentity("Firestorm", "")); - cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); - cubeCards.add(new CardIdentity("Flametongue Kavu", "")); - cubeCards.add(new CardIdentity("Flickerwisp", "")); - cubeCards.add(new CardIdentity("Flooded Strand", "")); - cubeCards.add(new CardIdentity("Forbid", "")); - cubeCards.add(new CardIdentity("Force of Will", "")); - cubeCards.add(new CardIdentity("Force Spike", "")); - cubeCards.add(new CardIdentity("Fyndhorn Elves", "")); - cubeCards.add(new CardIdentity("Gaea's Cradle", "")); - cubeCards.add(new CardIdentity("Galepowder Mage", "")); - cubeCards.add(new CardIdentity("Garruk Relentless", "")); - cubeCards.add(new CardIdentity("Garruk Wildspeaker", "")); - cubeCards.add(new CardIdentity("Garruk, Primal Hunter", "")); - cubeCards.add(new CardIdentity("Geist of Saint Traft", "")); - cubeCards.add(new CardIdentity("Gemstone Mine", "")); - cubeCards.add(new CardIdentity("Genesis", "")); - cubeCards.add(new CardIdentity("Geralf's Messenger", "")); - cubeCards.add(new CardIdentity("Gerrard's Verdict", "")); - cubeCards.add(new CardIdentity("Gideon Jura", "")); - cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); - cubeCards.add(new CardIdentity("Gifts Ungiven", "")); - cubeCards.add(new CardIdentity("Gilded Drake", "")); - cubeCards.add(new CardIdentity("Glen Elendra Archmage", "")); - cubeCards.add(new CardIdentity("Go For The Throat", "")); - cubeCards.add(new CardIdentity("Goblin Guide", "")); - cubeCards.add(new CardIdentity("Goblin Welder", "")); - cubeCards.add(new CardIdentity("Godless Shrine", "")); - cubeCards.add(new CardIdentity("Golgari Signet", "")); - cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); - cubeCards.add(new CardIdentity("Gorilla Shaman", "")); - cubeCards.add(new CardIdentity("Grafted Wargear", "")); - cubeCards.add(new CardIdentity("Grand Coliseum", "")); - cubeCards.add(new CardIdentity("Grave Titan", "")); - cubeCards.add(new CardIdentity("Gravecrawler", "")); - cubeCards.add(new CardIdentity("Greater Gargadon", "")); - cubeCards.add(new CardIdentity("Green Sun's Zenith", "")); - cubeCards.add(new CardIdentity("Grim Lavamancer", "")); - cubeCards.add(new CardIdentity("Grim Monolith", "")); - cubeCards.add(new CardIdentity("Grixis", "")); - cubeCards.add(new CardIdentity("Gruul Signet", "")); - cubeCards.add(new CardIdentity("Guul Draz Assassin", "")); - cubeCards.add(new CardIdentity("Hallowed Fountain", "")); - cubeCards.add(new CardIdentity("Hammer of Purphoros", "")); - cubeCards.add(new CardIdentity("Hellrider", "")); - cubeCards.add(new CardIdentity("Hellspark Elemental", "")); - cubeCards.add(new CardIdentity("Hero of Bladehold", "")); - cubeCards.add(new CardIdentity("Hero of Oxid Ridge", "")); - cubeCards.add(new CardIdentity("Hero's Downfall", "")); - cubeCards.add(new CardIdentity("Horizon Canopy", "")); - cubeCards.add(new CardIdentity("Huntmaster of the Fells", "")); - cubeCards.add(new CardIdentity("Hymn to Tourach", "")); - cubeCards.add(new CardIdentity("Hypnotic Specter", "")); - cubeCards.add(new CardIdentity("Icy Manipulator", "")); - cubeCards.add(new CardIdentity("Impending Disaster", "")); - cubeCards.add(new CardIdentity("Imperial Seal", "")); - cubeCards.add(new CardIdentity("Imposing Sovereign", "")); - cubeCards.add(new CardIdentity("Impulse", "")); - cubeCards.add(new CardIdentity("Incinerate", "")); - cubeCards.add(new CardIdentity("Inferno Titan", "")); - cubeCards.add(new CardIdentity("Inkwell Leviathan", "")); - cubeCards.add(new CardIdentity("Inquisition of Kozilek", "")); - cubeCards.add(new CardIdentity("Isamaru, Hound of Konda", "")); - cubeCards.add(new CardIdentity("Izzet Boilerworks", "")); - cubeCards.add(new CardIdentity("Izzet Charm", "")); - cubeCards.add(new CardIdentity("Izzet Signet", "")); - cubeCards.add(new CardIdentity("Jace Beleren", "")); - cubeCards.add(new CardIdentity("Jace, the Mind Sculptor", "")); - cubeCards.add(new CardIdentity("Jackal Pup", "")); - cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); - cubeCards.add(new CardIdentity("Journey to Nowhere", "")); - cubeCards.add(new CardIdentity("Jund", "")); - cubeCards.add(new CardIdentity("Jungle Lion", "")); - cubeCards.add(new CardIdentity("Kalonian Hydra", "")); - cubeCards.add(new CardIdentity("Karmic Guide", "")); - cubeCards.add(new CardIdentity("Karn Liberated", "")); - cubeCards.add(new CardIdentity("Karn, Silver Golem", "")); - cubeCards.add(new CardIdentity("Kataki, War's Wage", "")); - cubeCards.add(new CardIdentity("Keldon Marauders", "")); - cubeCards.add(new CardIdentity("Keldon Vandals", "")); - cubeCards.add(new CardIdentity("Kird Ape", "")); - cubeCards.add(new CardIdentity("Kitchen Finks", "")); - cubeCards.add(new CardIdentity("Knight of Meadowgrain", "")); - cubeCards.add(new CardIdentity("Kodamas Reach", "")); - cubeCards.add(new CardIdentity("Kor Sanctifiers", "")); - cubeCards.add(new CardIdentity("Kor Skyfisher", "")); - cubeCards.add(new CardIdentity("Koth of the Hammer", "")); - cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth", "")); - cubeCards.add(new CardIdentity("Land Tax", "")); - cubeCards.add(new CardIdentity("Lavaclaw Reaches", "")); - cubeCards.add(new CardIdentity("Library of Alexandria", "")); - cubeCards.add(new CardIdentity("Life from the Loam", "")); - cubeCards.add(new CardIdentity("Lifebane Zombie", "")); - cubeCards.add(new CardIdentity("Lightning Bolt", "")); - cubeCards.add(new CardIdentity("Lightning Greaves", "")); - cubeCards.add(new CardIdentity("Lightning Helix", "")); - cubeCards.add(new CardIdentity("Lightning Mauler", "")); - cubeCards.add(new CardIdentity("Lightning Strike", "")); - cubeCards.add(new CardIdentity("Liliana of the Veil", "")); - cubeCards.add(new CardIdentity("Lingering Souls", "")); - cubeCards.add(new CardIdentity("Llanowar Elves", "")); - cubeCards.add(new CardIdentity("Llanowar Wastes", "")); - cubeCards.add(new CardIdentity("Lone Missionary", "")); - cubeCards.add(new CardIdentity("Looter il-Kor", "")); - cubeCards.add(new CardIdentity("Lotleth Troll", "")); - cubeCards.add(new CardIdentity("Lotus Cobra", "")); - cubeCards.add(new CardIdentity("Luminarch Ascension", "")); - cubeCards.add(new CardIdentity("Maelstrom Pulse", "")); - cubeCards.add(new CardIdentity("Magma Jet", "")); - cubeCards.add(new CardIdentity("Man-O-War", "")); - cubeCards.add(new CardIdentity("Mana Crypt", "")); - cubeCards.add(new CardIdentity("Mana Drain", "")); - cubeCards.add(new CardIdentity("Mana Leak", "")); - cubeCards.add(new CardIdentity("Mana Tithe", "")); - cubeCards.add(new CardIdentity("Mana Vault", "")); - cubeCards.add(new CardIdentity("Manic Vandal", "")); - cubeCards.add(new CardIdentity("Marsh Flats", "")); - cubeCards.add(new CardIdentity("Master of the Wild Hunt", "")); - cubeCards.add(new CardIdentity("Masticore", "")); - cubeCards.add(new CardIdentity("Mayor of Avabruck", "")); - cubeCards.add(new CardIdentity("Maze of Ith", "")); - cubeCards.add(new CardIdentity("Meloku the Clouded Mirror", "")); - cubeCards.add(new CardIdentity("Memory Jar", "")); - cubeCards.add(new CardIdentity("Memory Lapse", "")); - cubeCards.add(new CardIdentity("Metalworker", "")); - cubeCards.add(new CardIdentity("Mimic Vat", "")); - cubeCards.add(new CardIdentity("Mind Stone", "")); - cubeCards.add(new CardIdentity("Mind Twist", "")); - cubeCards.add(new CardIdentity("Mirran Crusader", "")); - cubeCards.add(new CardIdentity("Mirror Entity", "")); - cubeCards.add(new CardIdentity("Miscalculation", "")); - cubeCards.add(new CardIdentity("Mishra's Factory", "")); - cubeCards.add(new CardIdentity("Misty Rainforest", "")); - cubeCards.add(new CardIdentity("Moat", "")); - cubeCards.add(new CardIdentity("Mogg Fanatic", "")); - cubeCards.add(new CardIdentity("Molten Rain", "")); - cubeCards.add(new CardIdentity("Molten-Tail Masticore", "")); - cubeCards.add(new CardIdentity("Morphling", "")); - cubeCards.add(new CardIdentity("Mortify", "")); - cubeCards.add(new CardIdentity("Mother of Runes", "")); - cubeCards.add(new CardIdentity("Mox Diamond", "")); - cubeCards.add(new CardIdentity("Mox Emerald", "")); - cubeCards.add(new CardIdentity("Mox Jet", "")); - cubeCards.add(new CardIdentity("Mox Pearl", "")); - cubeCards.add(new CardIdentity("Mox Ruby", "")); - cubeCards.add(new CardIdentity("Mox Sapphire", "")); - cubeCards.add(new CardIdentity("Mulldrifter", "")); - cubeCards.add(new CardIdentity("Murderous Redcap", "")); - cubeCards.add(new CardIdentity("Mutavault", "")); - cubeCards.add(new CardIdentity("Myr Battlesphere", "")); - cubeCards.add(new CardIdentity("Mystic Snake", "")); - cubeCards.add(new CardIdentity("Mystical Tutor", "")); - cubeCards.add(new CardIdentity("Nantuko Vigilante", "")); - cubeCards.add(new CardIdentity("Natural Order", "")); - cubeCards.add(new CardIdentity("Naya", "")); - cubeCards.add(new CardIdentity("Necromancy", "")); - cubeCards.add(new CardIdentity("Nekrataal", "")); - cubeCards.add(new CardIdentity("Nevinyrrals Disk", "")); - cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); - cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker", "")); - cubeCards.add(new CardIdentity("Noble Hierarch", "")); - cubeCards.add(new CardIdentity("Ob Nixilis, the Fallen", "")); - cubeCards.add(new CardIdentity("Oblivion Ring", "")); - cubeCards.add(new CardIdentity("Oonas Prowler", "")); - cubeCards.add(new CardIdentity("Opposition", "")); - cubeCards.add(new CardIdentity("Orzhov Signet", "")); - cubeCards.add(new CardIdentity("Overgrown Tomb", "")); - cubeCards.add(new CardIdentity("Pack Rat", "")); - cubeCards.add(new CardIdentity("Path to Exile", "")); - cubeCards.add(new CardIdentity("Pernicious Deed", "")); - cubeCards.add(new CardIdentity("Phantasmal Image", "")); - cubeCards.add(new CardIdentity("Phyrexian Arena", "")); - cubeCards.add(new CardIdentity("Phyrexian Metamorph", "")); - cubeCards.add(new CardIdentity("Phyrexian Revoker", "")); - cubeCards.add(new CardIdentity("Pillage", "")); - cubeCards.add(new CardIdentity("Pithing Needle", "")); - cubeCards.add(new CardIdentity("Plateau", "")); - cubeCards.add(new CardIdentity("Plated Geopede", "")); - cubeCards.add(new CardIdentity("Plow Under", "")); - cubeCards.add(new CardIdentity("Polluted Delta", "")); - cubeCards.add(new CardIdentity("Ponder", "")); - cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); - cubeCards.add(new CardIdentity("Pox", "")); - cubeCards.add(new CardIdentity("Preordain", "")); - cubeCards.add(new CardIdentity("Primeval Titan", "")); - cubeCards.add(new CardIdentity("Profane Command", "")); - cubeCards.add(new CardIdentity("Psychatog", "")); - cubeCards.add(new CardIdentity("Purphoros, God of the Forge", "")); - cubeCards.add(new CardIdentity("Qasali Pridemage", "")); - cubeCards.add(new CardIdentity("Raging Ravine", "")); - cubeCards.add(new CardIdentity("Rakdos Cackler", "")); - cubeCards.add(new CardIdentity("Rakdos Signet", "")); - cubeCards.add(new CardIdentity("Ral Zarek", "")); - cubeCards.add(new CardIdentity("Rancor", "")); - cubeCards.add(new CardIdentity("Ranger of Eos", "")); - cubeCards.add(new CardIdentity("Ratchet Bomb", "")); - cubeCards.add(new CardIdentity("Ravages of War", "")); - cubeCards.add(new CardIdentity("Reanimate", "")); - cubeCards.add(new CardIdentity("Reassembling Skeleton", "")); - cubeCards.add(new CardIdentity("Reckless Waif", "")); - cubeCards.add(new CardIdentity("Recurring Nightmare", "")); - cubeCards.add(new CardIdentity("Reflecting Pool", "")); - cubeCards.add(new CardIdentity("Regrowth", "")); - cubeCards.add(new CardIdentity("Remand", "")); - cubeCards.add(new CardIdentity("Restoration Angel", "")); - cubeCards.add(new CardIdentity("Reveillark", "")); - cubeCards.add(new CardIdentity("Rishadan Port", "")); - cubeCards.add(new CardIdentity("River Boa", "")); - cubeCards.add(new CardIdentity("Rolling Earthquake", "")); - cubeCards.add(new CardIdentity("Sacred Foundry", "")); - cubeCards.add(new CardIdentity("Sakura-Tribe Elder", "")); - cubeCards.add(new CardIdentity("Sarkhan Vol", "")); - cubeCards.add(new CardIdentity("Savannah", "")); - cubeCards.add(new CardIdentity("Savannah Lions", "")); - cubeCards.add(new CardIdentity("Scalding Tarn", "")); - cubeCards.add(new CardIdentity("Scavenging Ooze", "")); - cubeCards.add(new CardIdentity("Scroll Rack", "")); - cubeCards.add(new CardIdentity("Scrubland", "")); - cubeCards.add(new CardIdentity("Seal of Cleansing", "")); - cubeCards.add(new CardIdentity("Searing Spear", "")); - cubeCards.add(new CardIdentity("Selesnya Signet", "")); - cubeCards.add(new CardIdentity("Senseis Divining Top", "")); - cubeCards.add(new CardIdentity("Serendib Efreet", "")); - cubeCards.add(new CardIdentity("Shadowborn Demon", "")); - cubeCards.add(new CardIdentity("Shadowmage Infiltrator", "")); - cubeCards.add(new CardIdentity("Show and Tell", "")); - cubeCards.add(new CardIdentity("Shriekmaw", "")); - cubeCards.add(new CardIdentity("Siege-Gang Commander", "")); - cubeCards.add(new CardIdentity("Sigarda, Host of Herons", "")); - cubeCards.add(new CardIdentity("Silverblade Paladin", "")); - cubeCards.add(new CardIdentity("Simic Charm", "")); - cubeCards.add(new CardIdentity("SImic Growth Chamber", "")); - cubeCards.add(new CardIdentity("Simic Signet", "")); - cubeCards.add(new CardIdentity("Simic Sky Swallower", "")); - cubeCards.add(new CardIdentity("Sinkhole", "")); - cubeCards.add(new CardIdentity("Skinrender", "")); - cubeCards.add(new CardIdentity("Skinshifter", "")); - cubeCards.add(new CardIdentity("Skullclamp", "")); - cubeCards.add(new CardIdentity("Smallpox", "")); - cubeCards.add(new CardIdentity("Smoke Stack", "")); - cubeCards.add(new CardIdentity("Snapcaster Mage", "")); - cubeCards.add(new CardIdentity("Sneak Attack", "")); - cubeCards.add(new CardIdentity("Snuff Out", "")); - cubeCards.add(new CardIdentity("Sol Ring", "")); - cubeCards.add(new CardIdentity("Soldier of the Pantheon", "")); - cubeCards.add(new CardIdentity("Solemn Simulacrum", "")); - cubeCards.add(new CardIdentity("Soltari Champion", "")); - cubeCards.add(new CardIdentity("Soltari Monk", "")); - cubeCards.add(new CardIdentity("Soltari Priest", "")); - cubeCards.add(new CardIdentity("Soltari Trooper", "")); - cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad", "")); - cubeCards.add(new CardIdentity("Sower of Temptation", "")); - cubeCards.add(new CardIdentity("Spear of Heliod", "")); - cubeCards.add(new CardIdentity("Spectral Procession", "")); - cubeCards.add(new CardIdentity("Sphinx of the Steel Wind", "")); - cubeCards.add(new CardIdentity("Sphinx's Revelation", "")); - cubeCards.add(new CardIdentity("Spikeshot Elder", "")); - cubeCards.add(new CardIdentity("Squee, Goblin Nabob", "")); - cubeCards.add(new CardIdentity("Staggershock", "")); - cubeCards.add(new CardIdentity("Steam Augury", "")); - cubeCards.add(new CardIdentity("Steam Vents", "")); - cubeCards.add(new CardIdentity("Steppe Lynx", "")); - cubeCards.add(new CardIdentity("Stomping Ground", "")); - cubeCards.add(new CardIdentity("Stoneforge Mystic", "")); - cubeCards.add(new CardIdentity("Stormblood Berserker", "")); - cubeCards.add(new CardIdentity("Strangleroot Geist", "")); - cubeCards.add(new CardIdentity("Strip Mine", "")); - cubeCards.add(new CardIdentity("Stromkirk Noble", "")); - cubeCards.add(new CardIdentity("Student of Warfare", "")); - cubeCards.add(new CardIdentity("Sulfuric Vortex", "")); - cubeCards.add(new CardIdentity("Sun Titan", "")); - cubeCards.add(new CardIdentity("Sundering Titan", "")); - cubeCards.add(new CardIdentity("Supreme Verdict", "")); - cubeCards.add(new CardIdentity("Survival of the Fittest", "")); - cubeCards.add(new CardIdentity("Sword of Body and Mind", "")); - cubeCards.add(new CardIdentity("Sword of Feast and Famine", "")); - cubeCards.add(new CardIdentity("Sword of Fire and Ice", "")); - cubeCards.add(new CardIdentity("Sword of Light and Shadow", "")); - cubeCards.add(new CardIdentity("Sword of War and Peace", "")); - cubeCards.add(new CardIdentity("Swords to Plowshares", "")); - cubeCards.add(new CardIdentity("Sylvan Caryatid", "")); - cubeCards.add(new CardIdentity("Sylvan Library", "")); - cubeCards.add(new CardIdentity("Taiga", "")); - cubeCards.add(new CardIdentity("Tangle Wire", "")); - cubeCards.add(new CardIdentity("Tarmogoyf", "")); - cubeCards.add(new CardIdentity("Temple Garden", "")); - cubeCards.add(new CardIdentity("Terminus", "")); - cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); - cubeCards.add(new CardIdentity("Tezzeret the Seeker", "")); - cubeCards.add(new CardIdentity("Tezzeret, Agent of Bolas", "")); - cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben", "")); - cubeCards.add(new CardIdentity("Thassa, God of the Sea", "")); - cubeCards.add(new CardIdentity("The Abyss", "")); - cubeCards.add(new CardIdentity("Thirst for Knowledge", "")); - cubeCards.add(new CardIdentity("Thoughtseize", "")); - cubeCards.add(new CardIdentity("Thragtusk", "")); - cubeCards.add(new CardIdentity("Thrun, the Last Troll", "")); - cubeCards.add(new CardIdentity("Thundermaw Hellkite", "")); - cubeCards.add(new CardIdentity("Time Spiral", "")); - cubeCards.add(new CardIdentity("Time Walk", "")); - cubeCards.add(new CardIdentity("Timetwister", "")); - cubeCards.add(new CardIdentity("Tinker", "")); - cubeCards.add(new CardIdentity("Tolarian Academy", "")); - cubeCards.add(new CardIdentity("Tombstalker", "")); - cubeCards.add(new CardIdentity("Tooth and Nail", "")); - cubeCards.add(new CardIdentity("Tormented Hero", "")); - cubeCards.add(new CardIdentity("Treachery", "")); - cubeCards.add(new CardIdentity("Treetop Village", "")); - cubeCards.add(new CardIdentity("Trinket Mage", "")); - cubeCards.add(new CardIdentity("Triskelion", "")); - cubeCards.add(new CardIdentity("Troll Ascetic", "")); - cubeCards.add(new CardIdentity("Tropical Island", "")); - cubeCards.add(new CardIdentity("Trygon Predator", "")); - cubeCards.add(new CardIdentity("Tundra", "")); - cubeCards.add(new CardIdentity("Twinblade Slasher", "")); - cubeCards.add(new CardIdentity("Uktabi Orangutan", "")); - cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre", "")); - cubeCards.add(new CardIdentity("Umezawas Jitte", "")); - cubeCards.add(new CardIdentity("Underground Sea", "")); - cubeCards.add(new CardIdentity("Undiscovered Paradise", "")); - cubeCards.add(new CardIdentity("Upheaval", "")); - cubeCards.add(new CardIdentity("Vampire Hexmage", "")); - cubeCards.add(new CardIdentity("Vampire Lacerator", "")); - cubeCards.add(new CardIdentity("Vampire Nighthawk", "")); - cubeCards.add(new CardIdentity("Vampiric Tutor", "")); - cubeCards.add(new CardIdentity("Vedalken Shackles", "")); - cubeCards.add(new CardIdentity("Vendilion Clique", "")); - cubeCards.add(new CardIdentity("Vengevine", "")); - cubeCards.add(new CardIdentity("Venser, Shaper Savant", "")); - cubeCards.add(new CardIdentity("Venser, the Sojourner", "")); - cubeCards.add(new CardIdentity("Verdant Catacombs", "")); - cubeCards.add(new CardIdentity("Vindicate", "")); - cubeCards.add(new CardIdentity("Vinelasher Kudzu", "")); - cubeCards.add(new CardIdentity("Viridian Shaman", "")); - cubeCards.add(new CardIdentity("Voice of Resurgence", "")); - cubeCards.add(new CardIdentity("Volcanic Island", "")); - cubeCards.add(new CardIdentity("Volraths Stronghold", "")); - cubeCards.add(new CardIdentity("Wall of Blossoms", "")); - cubeCards.add(new CardIdentity("Wall of Omens", "")); - cubeCards.add(new CardIdentity("Wall of Roots", "")); - cubeCards.add(new CardIdentity("Wasteland", "")); - cubeCards.add(new CardIdentity("Waterfront Bouncer", "")); - cubeCards.add(new CardIdentity("Watery Grave", "")); - cubeCards.add(new CardIdentity("Wheel of Fortune", "")); - cubeCards.add(new CardIdentity("Wickerbough Elder", "")); - cubeCards.add(new CardIdentity("Wild Mongrel", "")); - cubeCards.add(new CardIdentity("Wild Nacatl", "")); - cubeCards.add(new CardIdentity("Wildfire", "")); - cubeCards.add(new CardIdentity("Willbender", "")); - cubeCards.add(new CardIdentity("Windswept Heath", "")); - cubeCards.add(new CardIdentity("Winter Orb", "")); - cubeCards.add(new CardIdentity("Wolfbitten Captive", "")); - cubeCards.add(new CardIdentity("Wolfir Silverheart", "")); - cubeCards.add(new CardIdentity("Wooded Foothills", "")); - cubeCards.add(new CardIdentity("Woodfall Primus", "")); - cubeCards.add(new CardIdentity("Worldly Tutor", "")); - cubeCards.add(new CardIdentity("Worn Powerstone", "")); - cubeCards.add(new CardIdentity("Wurmcoil Engine", "")); - cubeCards.add(new CardIdentity("Xenagos, the Reveler", "")); - cubeCards.add(new CardIdentity("Yavimaya Elder", "")); - cubeCards.add(new CardIdentity("Yawgmoths Will", "")); - cubeCards.add(new CardIdentity("Young Pyromancer", "")); - cubeCards.add(new CardIdentity("Zuran Orb", "")); - - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.tournament.cubes; + +import mage.game.draft.DraftCube; + +/** + * + * @author LevelX2 + */ +public class MTGCube extends DraftCube { + + public MTGCube() { + super("www.mtgcube.com (502 cards)"); // http://www.mtgcube.com + + cubeCards.add(new CardIdentity("Abrupt Decay", "")); + cubeCards.add(new CardIdentity("Academy Ruins", "")); + cubeCards.add(new CardIdentity("Accorder Paladin", "")); + cubeCards.add(new CardIdentity("Acidic Slime", "")); + cubeCards.add(new CardIdentity("AEtherling", "")); + cubeCards.add(new CardIdentity("Ajani Goldmane", "")); + cubeCards.add(new CardIdentity("Ajani Vengeant", "")); + cubeCards.add(new CardIdentity("Ancestral Recall", "")); + cubeCards.add(new CardIdentity("Ancestral Vision", "")); + cubeCards.add(new CardIdentity("Animate Dead", "")); + cubeCards.add(new CardIdentity("Arbor Elf", "")); + cubeCards.add(new CardIdentity("Arc Lightning", "")); + cubeCards.add(new CardIdentity("Arc Trail", "")); + cubeCards.add(new CardIdentity("Arcane Denial", "")); + cubeCards.add(new CardIdentity("Archangel of Thune", "")); + cubeCards.add(new CardIdentity("Arid Mesa", "")); + cubeCards.add(new CardIdentity("Armageddon", "")); + cubeCards.add(new CardIdentity("Ash Zealot", "")); + cubeCards.add(new CardIdentity("Augur of Bolas", "")); + cubeCards.add(new CardIdentity("Avalanche Riders", "")); + cubeCards.add(new CardIdentity("Avenger of Zendikar", "")); + cubeCards.add(new CardIdentity("Awakening Zone", "")); + cubeCards.add(new CardIdentity("Azorius Signet", "")); + cubeCards.add(new CardIdentity("Badlands", "")); + cubeCards.add(new CardIdentity("Balance", "")); + cubeCards.add(new CardIdentity("Baleful Strix", "")); + cubeCards.add(new CardIdentity("Bane of the Living", "")); + cubeCards.add(new CardIdentity("Baneslayer Angel", "")); + cubeCards.add(new CardIdentity("Bant Charm", "")); + cubeCards.add(new CardIdentity("Batterskull", "")); + cubeCards.add(new CardIdentity("Battlefield Forge", "")); + cubeCards.add(new CardIdentity("Bayou", "")); + cubeCards.add(new CardIdentity("Birds of Paradise", "")); + cubeCards.add(new CardIdentity("Birthing Pod", "")); + cubeCards.add(new CardIdentity("Bitterblossom", "")); + cubeCards.add(new CardIdentity("Black Lotus", "")); + cubeCards.add(new CardIdentity("Black Vise", "")); + cubeCards.add(new CardIdentity("Blade Splicer", "")); + cubeCards.add(new CardIdentity("Blightning", "")); + cubeCards.add(new CardIdentity("Blistering Firecat", "")); + cubeCards.add(new CardIdentity("Blood Crypt", "")); + cubeCards.add(new CardIdentity("Blood Scrivener", "")); + cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); + cubeCards.add(new CardIdentity("Bloodghast", "")); + cubeCards.add(new CardIdentity("Bloodstained Mire", "")); + cubeCards.add(new CardIdentity("Bone Shredder", "")); + cubeCards.add(new CardIdentity("Bonesplitter", "")); + cubeCards.add(new CardIdentity("Bonfire of the Damned", "")); + cubeCards.add(new CardIdentity("Boros Charm", "")); + cubeCards.add(new CardIdentity("Boros Reckoner", "")); + cubeCards.add(new CardIdentity("Boros Signet", "")); + cubeCards.add(new CardIdentity("Braids, Cabal Minion", "")); + cubeCards.add(new CardIdentity("Brainstorm", "")); + cubeCards.add(new CardIdentity("Breeding Pool", "")); + cubeCards.add(new CardIdentity("Bribery", "")); + cubeCards.add(new CardIdentity("Broodmate Dragon", "")); + cubeCards.add(new CardIdentity("Burning of Xinye", "")); + cubeCards.add(new CardIdentity("Burst Lightning", "")); + cubeCards.add(new CardIdentity("Call of the Herd", "")); + cubeCards.add(new CardIdentity("Carnophage", "")); + cubeCards.add(new CardIdentity("Catastrophe", "")); + cubeCards.add(new CardIdentity("Caves of Koilos", "")); + cubeCards.add(new CardIdentity("Celestial Colonnade", "")); + cubeCards.add(new CardIdentity("Chain Lightning", "")); + cubeCards.add(new CardIdentity("Chainer's Edict", "")); + cubeCards.add(new CardIdentity("Chameleon Colossus", "")); + cubeCards.add(new CardIdentity("Chandra Nalaar", "")); + cubeCards.add(new CardIdentity("Chandra, Pyromaster", "")); + cubeCards.add(new CardIdentity("Char", "")); + cubeCards.add(new CardIdentity("Chrome Mox", "")); + cubeCards.add(new CardIdentity("City of Brass", "")); + cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); + cubeCards.add(new CardIdentity("Coalition Relic", "")); + cubeCards.add(new CardIdentity("Coldsteel Heart", "")); + cubeCards.add(new CardIdentity("Consecrated Sphinx", "")); + cubeCards.add(new CardIdentity("Consuming Vapors", "")); + cubeCards.add(new CardIdentity("Contagion", "")); + cubeCards.add(new CardIdentity("Control Magic", "")); + cubeCards.add(new CardIdentity("Counterspell", "")); + cubeCards.add(new CardIdentity("Creakwood Liege", "")); + cubeCards.add(new CardIdentity("Creeping Tar Pit", "")); + cubeCards.add(new CardIdentity("Crucible of Worlds", "")); + cubeCards.add(new CardIdentity("Cryptic Command", "")); + cubeCards.add(new CardIdentity("Crystal Shard", "")); + cubeCards.add(new CardIdentity("Cultivate", "")); + cubeCards.add(new CardIdentity("Cursed Scroll", "")); + cubeCards.add(new CardIdentity("Damnation", "")); + cubeCards.add(new CardIdentity("Dance of the Dead", "")); + cubeCards.add(new CardIdentity("Dark Confidant", "")); + cubeCards.add(new CardIdentity("Dark Ritual", "")); + cubeCards.add(new CardIdentity("Day of Judgment", "")); + cubeCards.add(new CardIdentity("Daze", "")); + cubeCards.add(new CardIdentity("Deep Analysis", "")); + cubeCards.add(new CardIdentity("Demonic Tutor", "")); + cubeCards.add(new CardIdentity("Deranged Hermit", "")); + cubeCards.add(new CardIdentity("Detention Sphere", "")); + cubeCards.add(new CardIdentity("Diabolic Edict", "")); + cubeCards.add(new CardIdentity("Dimir Signet", "")); + cubeCards.add(new CardIdentity("Diregraf Ghoul", "")); + cubeCards.add(new CardIdentity("Disenchant", "")); + cubeCards.add(new CardIdentity("Dismember", "")); + cubeCards.add(new CardIdentity("Dreadbore", "")); + cubeCards.add(new CardIdentity("Dryad Militant", "")); + cubeCards.add(new CardIdentity("Duress", "")); + cubeCards.add(new CardIdentity("Dust Bowl", "")); + cubeCards.add(new CardIdentity("Dwarven Blastminer", "")); + cubeCards.add(new CardIdentity("Earthquake", "")); + cubeCards.add(new CardIdentity("Edric, Spymaster of Trest", "")); + cubeCards.add(new CardIdentity("Electrolyze", "")); + cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite", "")); + cubeCards.add(new CardIdentity("Elite Vanguard", "")); + cubeCards.add(new CardIdentity("Elspeth, Knight-Errant", "")); + cubeCards.add(new CardIdentity("Elspeth, Sun's Champion", "")); + cubeCards.add(new CardIdentity("Empty the Warrens", "")); + cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn", "")); + cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); + cubeCards.add(new CardIdentity("Enlightened Tutor", "")); + cubeCards.add(new CardIdentity("Entomb", "")); + cubeCards.add(new CardIdentity("Erratic Portal", "")); + cubeCards.add(new CardIdentity("Esper Charm", "")); + cubeCards.add(new CardIdentity("Eternal Witness", "")); + cubeCards.add(new CardIdentity("Eureka", "")); + cubeCards.add(new CardIdentity("Everflowing Chalice", "")); + cubeCards.add(new CardIdentity("Evolving Wilds", "")); + cubeCards.add(new CardIdentity("Exalted Angel", "")); + cubeCards.add(new CardIdentity("Exhume", "")); + cubeCards.add(new CardIdentity("Experiment One", "")); + cubeCards.add(new CardIdentity("Fact or Fiction", "")); + cubeCards.add(new CardIdentity("Faerie Conclave", "")); + cubeCards.add(new CardIdentity("Faithless Looting", "")); + cubeCards.add(new CardIdentity("Faith's Fetters", "")); + cubeCards.add(new CardIdentity("Falkenrath Aristocrat", "")); + cubeCards.add(new CardIdentity("Fauna Shaman", "")); + cubeCards.add(new CardIdentity("Figure of Destiny", "")); + cubeCards.add(new CardIdentity("Fire // Ice ", "")); + cubeCards.add(new CardIdentity("Fire Imp", "")); + cubeCards.add(new CardIdentity("Firebolt", "")); + cubeCards.add(new CardIdentity("Firedrinker Satyr", "")); + cubeCards.add(new CardIdentity("Fireslinger", "")); + cubeCards.add(new CardIdentity("Firestorm", "")); + cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); + cubeCards.add(new CardIdentity("Flametongue Kavu", "")); + cubeCards.add(new CardIdentity("Flickerwisp", "")); + cubeCards.add(new CardIdentity("Flooded Strand", "")); + cubeCards.add(new CardIdentity("Forbid", "")); + cubeCards.add(new CardIdentity("Force of Will", "")); + cubeCards.add(new CardIdentity("Force Spike", "")); + cubeCards.add(new CardIdentity("Fyndhorn Elves", "")); + cubeCards.add(new CardIdentity("Gaea's Cradle", "")); + cubeCards.add(new CardIdentity("Galepowder Mage", "")); + cubeCards.add(new CardIdentity("Garruk Relentless", "")); + cubeCards.add(new CardIdentity("Garruk Wildspeaker", "")); + cubeCards.add(new CardIdentity("Garruk, Primal Hunter", "")); + cubeCards.add(new CardIdentity("Geist of Saint Traft", "")); + cubeCards.add(new CardIdentity("Gemstone Mine", "")); + cubeCards.add(new CardIdentity("Genesis", "")); + cubeCards.add(new CardIdentity("Geralf's Messenger", "")); + cubeCards.add(new CardIdentity("Gerrard's Verdict", "")); + cubeCards.add(new CardIdentity("Gideon Jura", "")); + cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); + cubeCards.add(new CardIdentity("Gifts Ungiven", "")); + cubeCards.add(new CardIdentity("Gilded Drake", "")); + cubeCards.add(new CardIdentity("Glen Elendra Archmage", "")); + cubeCards.add(new CardIdentity("Go for the Throat", "")); + cubeCards.add(new CardIdentity("Goblin Guide", "")); + cubeCards.add(new CardIdentity("Goblin Welder", "")); + cubeCards.add(new CardIdentity("Godless Shrine", "")); + cubeCards.add(new CardIdentity("Golgari Signet", "")); + cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); + cubeCards.add(new CardIdentity("Gorilla Shaman", "")); + cubeCards.add(new CardIdentity("Grafted Wargear", "")); + cubeCards.add(new CardIdentity("Grand Coliseum", "")); + cubeCards.add(new CardIdentity("Grave Titan", "")); + cubeCards.add(new CardIdentity("Gravecrawler", "")); + cubeCards.add(new CardIdentity("Greater Gargadon", "")); + cubeCards.add(new CardIdentity("Green Sun's Zenith", "")); + cubeCards.add(new CardIdentity("Grim Lavamancer", "")); + cubeCards.add(new CardIdentity("Grim Monolith", "")); + cubeCards.add(new CardIdentity("Grixis Charm", "")); + cubeCards.add(new CardIdentity("Gruul Signet", "")); + cubeCards.add(new CardIdentity("Guul Draz Assassin", "")); + cubeCards.add(new CardIdentity("Hallowed Fountain", "")); + cubeCards.add(new CardIdentity("Hammer of Purphoros", "")); + cubeCards.add(new CardIdentity("Hellrider", "")); + cubeCards.add(new CardIdentity("Hellspark Elemental", "")); + cubeCards.add(new CardIdentity("Hero of Bladehold", "")); + cubeCards.add(new CardIdentity("Hero of Oxid Ridge", "")); + cubeCards.add(new CardIdentity("Hero's Downfall", "")); + cubeCards.add(new CardIdentity("Horizon Canopy", "")); + cubeCards.add(new CardIdentity("Huntmaster of the Fells", "")); + cubeCards.add(new CardIdentity("Hymn to Tourach", "")); + cubeCards.add(new CardIdentity("Hypnotic Specter", "")); + cubeCards.add(new CardIdentity("Icy Manipulator", "")); + cubeCards.add(new CardIdentity("Impending Disaster", "")); + cubeCards.add(new CardIdentity("Imperial Seal", "")); + cubeCards.add(new CardIdentity("Imposing Sovereign", "")); + cubeCards.add(new CardIdentity("Impulse", "")); + cubeCards.add(new CardIdentity("Incinerate", "")); + cubeCards.add(new CardIdentity("Inferno Titan", "")); + cubeCards.add(new CardIdentity("Inkwell Leviathan", "")); + cubeCards.add(new CardIdentity("Inquisition of Kozilek", "")); + cubeCards.add(new CardIdentity("Isamaru, Hound of Konda", "")); + cubeCards.add(new CardIdentity("Izzet Boilerworks", "")); + cubeCards.add(new CardIdentity("Izzet Charm", "")); + cubeCards.add(new CardIdentity("Izzet Signet", "")); + cubeCards.add(new CardIdentity("Jace Beleren", "")); + cubeCards.add(new CardIdentity("Jace, the Mind Sculptor", "")); + cubeCards.add(new CardIdentity("Jackal Pup", "")); + cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); + cubeCards.add(new CardIdentity("Journey to Nowhere", "")); + cubeCards.add(new CardIdentity("Jund Charm", "")); + cubeCards.add(new CardIdentity("Jungle Lion", "")); + cubeCards.add(new CardIdentity("Kalonian Hydra", "")); + cubeCards.add(new CardIdentity("Karmic Guide", "")); + cubeCards.add(new CardIdentity("Karn Liberated", "")); + cubeCards.add(new CardIdentity("Karn, Silver Golem", "")); + cubeCards.add(new CardIdentity("Kataki, War's Wage", "")); + cubeCards.add(new CardIdentity("Keldon Marauders", "")); + cubeCards.add(new CardIdentity("Keldon Vandals", "")); + cubeCards.add(new CardIdentity("Kird Ape", "")); + cubeCards.add(new CardIdentity("Kitchen Finks", "")); + cubeCards.add(new CardIdentity("Knight of Meadowgrain", "")); + cubeCards.add(new CardIdentity("Kodama's Reach", "")); + cubeCards.add(new CardIdentity("Kor Sanctifiers", "")); + cubeCards.add(new CardIdentity("Kor Skyfisher", "")); + cubeCards.add(new CardIdentity("Koth of the Hammer", "")); + cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth", "")); + cubeCards.add(new CardIdentity("Land Tax", "")); + cubeCards.add(new CardIdentity("Lavaclaw Reaches", "")); + cubeCards.add(new CardIdentity("Library of Alexandria", "")); + cubeCards.add(new CardIdentity("Life from the Loam", "")); + cubeCards.add(new CardIdentity("Lifebane Zombie", "")); + cubeCards.add(new CardIdentity("Lightning Bolt", "")); + cubeCards.add(new CardIdentity("Lightning Greaves", "")); + cubeCards.add(new CardIdentity("Lightning Helix", "")); + cubeCards.add(new CardIdentity("Lightning Mauler", "")); + cubeCards.add(new CardIdentity("Lightning Strike", "")); + cubeCards.add(new CardIdentity("Liliana of the Veil", "")); + cubeCards.add(new CardIdentity("Lingering Souls", "")); + cubeCards.add(new CardIdentity("Llanowar Elves", "")); + cubeCards.add(new CardIdentity("Llanowar Wastes", "")); + cubeCards.add(new CardIdentity("Lone Missionary", "")); + cubeCards.add(new CardIdentity("Looter il-Kor", "")); + cubeCards.add(new CardIdentity("Lotleth Troll", "")); + cubeCards.add(new CardIdentity("Lotus Cobra", "")); + cubeCards.add(new CardIdentity("Luminarch Ascension", "")); + cubeCards.add(new CardIdentity("Maelstrom Pulse", "")); + cubeCards.add(new CardIdentity("Magma Jet", "")); + cubeCards.add(new CardIdentity("Man-o'-War", "")); + cubeCards.add(new CardIdentity("Mana Crypt", "")); + cubeCards.add(new CardIdentity("Mana Drain", "")); + cubeCards.add(new CardIdentity("Mana Leak", "")); + cubeCards.add(new CardIdentity("Mana Tithe", "")); + cubeCards.add(new CardIdentity("Mana Vault", "")); + cubeCards.add(new CardIdentity("Manic Vandal", "")); + cubeCards.add(new CardIdentity("Marsh Flats", "")); + cubeCards.add(new CardIdentity("Master of the Wild Hunt", "")); + cubeCards.add(new CardIdentity("Masticore", "")); + cubeCards.add(new CardIdentity("Mayor of Avabruck", "")); + cubeCards.add(new CardIdentity("Maze of Ith", "")); + cubeCards.add(new CardIdentity("Meloku the Clouded Mirror", "")); + cubeCards.add(new CardIdentity("Memory Jar", "")); + cubeCards.add(new CardIdentity("Memory Lapse", "")); + cubeCards.add(new CardIdentity("Metalworker", "")); + cubeCards.add(new CardIdentity("Mimic Vat", "")); + cubeCards.add(new CardIdentity("Mind Stone", "")); + cubeCards.add(new CardIdentity("Mind Twist", "")); + cubeCards.add(new CardIdentity("Mirran Crusader", "")); + cubeCards.add(new CardIdentity("Mirror Entity", "")); + cubeCards.add(new CardIdentity("Miscalculation", "")); + cubeCards.add(new CardIdentity("Mishra's Factory", "")); + cubeCards.add(new CardIdentity("Misty Rainforest", "")); + cubeCards.add(new CardIdentity("Moat", "")); + cubeCards.add(new CardIdentity("Mogg Fanatic", "")); + cubeCards.add(new CardIdentity("Molten Rain", "")); + cubeCards.add(new CardIdentity("Molten-Tail Masticore", "")); + cubeCards.add(new CardIdentity("Morphling", "")); + cubeCards.add(new CardIdentity("Mortify", "")); + cubeCards.add(new CardIdentity("Mother of Runes", "")); + cubeCards.add(new CardIdentity("Mox Diamond", "")); + cubeCards.add(new CardIdentity("Mox Emerald", "")); + cubeCards.add(new CardIdentity("Mox Jet", "")); + cubeCards.add(new CardIdentity("Mox Pearl", "")); + cubeCards.add(new CardIdentity("Mox Ruby", "")); + cubeCards.add(new CardIdentity("Mox Sapphire", "")); + cubeCards.add(new CardIdentity("Mulldrifter", "")); + cubeCards.add(new CardIdentity("Murderous Redcap", "")); + cubeCards.add(new CardIdentity("Mutavault", "")); + cubeCards.add(new CardIdentity("Myr Battlesphere", "")); + cubeCards.add(new CardIdentity("Mystic Snake", "")); + cubeCards.add(new CardIdentity("Mystical Tutor", "")); + cubeCards.add(new CardIdentity("Nantuko Vigilante", "")); + cubeCards.add(new CardIdentity("Natural Order", "")); + cubeCards.add(new CardIdentity("Naya Charm", "")); + cubeCards.add(new CardIdentity("Necromancy", "")); + cubeCards.add(new CardIdentity("Nekrataal", "")); + cubeCards.add(new CardIdentity("Nevinyrral's Disk", "")); + cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); + cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker", "")); + cubeCards.add(new CardIdentity("Noble Hierarch", "")); + cubeCards.add(new CardIdentity("Ob Nixilis, the Fallen", "")); + cubeCards.add(new CardIdentity("Oblivion Ring", "")); + cubeCards.add(new CardIdentity("Oona's Prowler", "")); + cubeCards.add(new CardIdentity("Opposition", "")); + cubeCards.add(new CardIdentity("Orzhov Signet", "")); + cubeCards.add(new CardIdentity("Overgrown Tomb", "")); + cubeCards.add(new CardIdentity("Pack Rat", "")); + cubeCards.add(new CardIdentity("Path to Exile", "")); + cubeCards.add(new CardIdentity("Pernicious Deed", "")); + cubeCards.add(new CardIdentity("Phantasmal Image", "")); + cubeCards.add(new CardIdentity("Phyrexian Arena", "")); + cubeCards.add(new CardIdentity("Phyrexian Metamorph", "")); + cubeCards.add(new CardIdentity("Phyrexian Revoker", "")); + cubeCards.add(new CardIdentity("Pillage", "")); + cubeCards.add(new CardIdentity("Pithing Needle", "")); + cubeCards.add(new CardIdentity("Plateau", "")); + cubeCards.add(new CardIdentity("Plated Geopede", "")); + cubeCards.add(new CardIdentity("Plow Under", "")); + cubeCards.add(new CardIdentity("Polluted Delta", "")); + cubeCards.add(new CardIdentity("Ponder", "")); + cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); + cubeCards.add(new CardIdentity("Pox", "")); + cubeCards.add(new CardIdentity("Preordain", "")); + cubeCards.add(new CardIdentity("Primeval Titan", "")); + cubeCards.add(new CardIdentity("Profane Command", "")); + cubeCards.add(new CardIdentity("Psychatog", "")); + cubeCards.add(new CardIdentity("Purphoros, God of the Forge", "")); + cubeCards.add(new CardIdentity("Qasali Pridemage", "")); + cubeCards.add(new CardIdentity("Raging Ravine", "")); + cubeCards.add(new CardIdentity("Rakdos Cackler", "")); + cubeCards.add(new CardIdentity("Rakdos Signet", "")); + cubeCards.add(new CardIdentity("Ral Zarek", "")); + cubeCards.add(new CardIdentity("Rancor", "")); + cubeCards.add(new CardIdentity("Ranger of Eos", "")); + cubeCards.add(new CardIdentity("Ratchet Bomb", "")); + cubeCards.add(new CardIdentity("Ravages of War", "")); + cubeCards.add(new CardIdentity("Reanimate", "")); + cubeCards.add(new CardIdentity("Reassembling Skeleton", "")); + cubeCards.add(new CardIdentity("Reckless Waif", "")); + cubeCards.add(new CardIdentity("Recurring Nightmare", "")); + cubeCards.add(new CardIdentity("Reflecting Pool", "")); + cubeCards.add(new CardIdentity("Regrowth", "")); + cubeCards.add(new CardIdentity("Remand", "")); + cubeCards.add(new CardIdentity("Restoration Angel", "")); + cubeCards.add(new CardIdentity("Reveillark", "")); + cubeCards.add(new CardIdentity("Rishadan Port", "")); + cubeCards.add(new CardIdentity("River Boa", "")); + cubeCards.add(new CardIdentity("Rolling Earthquake", "")); + cubeCards.add(new CardIdentity("Sacred Foundry", "")); + cubeCards.add(new CardIdentity("Sakura-Tribe Elder", "")); + cubeCards.add(new CardIdentity("Sarkhan Vol", "")); + cubeCards.add(new CardIdentity("Savannah", "")); + cubeCards.add(new CardIdentity("Savannah Lions", "")); + cubeCards.add(new CardIdentity("Scalding Tarn", "")); + cubeCards.add(new CardIdentity("Scavenging Ooze", "")); + cubeCards.add(new CardIdentity("Scroll Rack", "")); + cubeCards.add(new CardIdentity("Scrubland", "")); + cubeCards.add(new CardIdentity("Seal of Cleansing", "")); + cubeCards.add(new CardIdentity("Searing Spear", "")); + cubeCards.add(new CardIdentity("Selesnya Signet", "")); + cubeCards.add(new CardIdentity("Sensei's Divining Top", "")); + cubeCards.add(new CardIdentity("Serendib Efreet", "")); + cubeCards.add(new CardIdentity("Shadowborn Demon", "")); + cubeCards.add(new CardIdentity("Shadowmage Infiltrator", "")); + cubeCards.add(new CardIdentity("Show and Tell", "")); + cubeCards.add(new CardIdentity("Shriekmaw", "")); + cubeCards.add(new CardIdentity("Siege-Gang Commander", "")); + cubeCards.add(new CardIdentity("Sigarda, Host of Herons", "")); + cubeCards.add(new CardIdentity("Silverblade Paladin", "")); + cubeCards.add(new CardIdentity("Simic Charm", "")); + cubeCards.add(new CardIdentity("Simic Growth Chamber", "")); + cubeCards.add(new CardIdentity("Simic Signet", "")); + cubeCards.add(new CardIdentity("Simic Sky Swallower", "")); + cubeCards.add(new CardIdentity("Sinkhole", "")); + cubeCards.add(new CardIdentity("Skinrender", "")); + cubeCards.add(new CardIdentity("Skinshifter", "")); + cubeCards.add(new CardIdentity("Skullclamp", "")); + cubeCards.add(new CardIdentity("Smallpox", "")); + cubeCards.add(new CardIdentity("Smokestack", "")); + cubeCards.add(new CardIdentity("Snapcaster Mage", "")); + cubeCards.add(new CardIdentity("Sneak Attack", "")); + cubeCards.add(new CardIdentity("Snuff Out", "")); + cubeCards.add(new CardIdentity("Sol Ring", "")); + cubeCards.add(new CardIdentity("Soldier of the Pantheon", "")); + cubeCards.add(new CardIdentity("Solemn Simulacrum", "")); + cubeCards.add(new CardIdentity("Soltari Champion", "")); + cubeCards.add(new CardIdentity("Soltari Monk", "")); + cubeCards.add(new CardIdentity("Soltari Priest", "")); + cubeCards.add(new CardIdentity("Soltari Trooper", "")); + cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad", "")); + cubeCards.add(new CardIdentity("Sower of Temptation", "")); + cubeCards.add(new CardIdentity("Spear of Heliod", "")); + cubeCards.add(new CardIdentity("Spectral Procession", "")); + cubeCards.add(new CardIdentity("Sphinx of the Steel Wind", "")); + cubeCards.add(new CardIdentity("Sphinx's Revelation", "")); + cubeCards.add(new CardIdentity("Spikeshot Elder", "")); + cubeCards.add(new CardIdentity("Squee, Goblin Nabob", "")); + cubeCards.add(new CardIdentity("Staggershock", "")); + cubeCards.add(new CardIdentity("Steam Augury", "")); + cubeCards.add(new CardIdentity("Steam Vents", "")); + cubeCards.add(new CardIdentity("Steppe Lynx", "")); + cubeCards.add(new CardIdentity("Stomping Ground", "")); + cubeCards.add(new CardIdentity("Stoneforge Mystic", "")); + cubeCards.add(new CardIdentity("Stormblood Berserker", "")); + cubeCards.add(new CardIdentity("Strangleroot Geist", "")); + cubeCards.add(new CardIdentity("Strip Mine", "")); + cubeCards.add(new CardIdentity("Stromkirk Noble", "")); + cubeCards.add(new CardIdentity("Student of Warfare", "")); + cubeCards.add(new CardIdentity("Sulfuric Vortex", "")); + cubeCards.add(new CardIdentity("Sun Titan", "")); + cubeCards.add(new CardIdentity("Sundering Titan", "")); + cubeCards.add(new CardIdentity("Supreme Verdict", "")); + cubeCards.add(new CardIdentity("Survival of the Fittest", "")); + cubeCards.add(new CardIdentity("Sword of Body and Mind", "")); + cubeCards.add(new CardIdentity("Sword of Feast and Famine", "")); + cubeCards.add(new CardIdentity("Sword of Fire and Ice", "")); + cubeCards.add(new CardIdentity("Sword of Light and Shadow", "")); + cubeCards.add(new CardIdentity("Sword of War and Peace", "")); + cubeCards.add(new CardIdentity("Swords to Plowshares", "")); + cubeCards.add(new CardIdentity("Sylvan Caryatid", "")); + cubeCards.add(new CardIdentity("Sylvan Library", "")); + cubeCards.add(new CardIdentity("Taiga", "")); + cubeCards.add(new CardIdentity("Tangle Wire", "")); + cubeCards.add(new CardIdentity("Tarmogoyf", "")); + cubeCards.add(new CardIdentity("Temple Garden", "")); + cubeCards.add(new CardIdentity("Terminus", "")); + cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); + cubeCards.add(new CardIdentity("Tezzeret the Seeker", "")); + cubeCards.add(new CardIdentity("Tezzeret, Agent of Bolas", "")); + cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben", "")); + cubeCards.add(new CardIdentity("Thassa, God of the Sea", "")); + cubeCards.add(new CardIdentity("The Abyss", "")); + cubeCards.add(new CardIdentity("Thirst for Knowledge", "")); + cubeCards.add(new CardIdentity("Thoughtseize", "")); + cubeCards.add(new CardIdentity("Thragtusk", "")); + cubeCards.add(new CardIdentity("Thrun, the Last Troll", "")); + cubeCards.add(new CardIdentity("Thundermaw Hellkite", "")); + cubeCards.add(new CardIdentity("Time Spiral", "")); + cubeCards.add(new CardIdentity("Time Walk", "")); + cubeCards.add(new CardIdentity("Timetwister", "")); + cubeCards.add(new CardIdentity("Tinker", "")); + cubeCards.add(new CardIdentity("Tolarian Academy", "")); + cubeCards.add(new CardIdentity("Tombstalker", "")); + cubeCards.add(new CardIdentity("Tooth and Nail", "")); + cubeCards.add(new CardIdentity("Tormented Hero", "")); + cubeCards.add(new CardIdentity("Treachery", "")); + cubeCards.add(new CardIdentity("Treetop Village", "")); + cubeCards.add(new CardIdentity("Trinket Mage", "")); + cubeCards.add(new CardIdentity("Triskelion", "")); + cubeCards.add(new CardIdentity("Troll Ascetic", "")); + cubeCards.add(new CardIdentity("Tropical Island", "")); + cubeCards.add(new CardIdentity("Trygon Predator", "")); + cubeCards.add(new CardIdentity("Tundra", "")); + cubeCards.add(new CardIdentity("Twinblade Slasher", "")); + cubeCards.add(new CardIdentity("Uktabi Orangutan", "")); + cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre", "")); + cubeCards.add(new CardIdentity("Umezawa's Jitte", "")); + cubeCards.add(new CardIdentity("Underground Sea", "")); + cubeCards.add(new CardIdentity("Undiscovered Paradise", "")); + cubeCards.add(new CardIdentity("Upheaval", "")); + cubeCards.add(new CardIdentity("Vampire Hexmage", "")); + cubeCards.add(new CardIdentity("Vampire Lacerator", "")); + cubeCards.add(new CardIdentity("Vampire Nighthawk", "")); + cubeCards.add(new CardIdentity("Vampiric Tutor", "")); + cubeCards.add(new CardIdentity("Vedalken Shackles", "")); + cubeCards.add(new CardIdentity("Vendilion Clique", "")); + cubeCards.add(new CardIdentity("Vengevine", "")); + cubeCards.add(new CardIdentity("Venser, Shaper Savant", "")); + cubeCards.add(new CardIdentity("Venser, the Sojourner", "")); + cubeCards.add(new CardIdentity("Verdant Catacombs", "")); + cubeCards.add(new CardIdentity("Vindicate", "")); + cubeCards.add(new CardIdentity("Vinelasher Kudzu", "")); + cubeCards.add(new CardIdentity("Viridian Shaman", "")); + cubeCards.add(new CardIdentity("Voice of Resurgence", "")); + cubeCards.add(new CardIdentity("Volcanic Island", "")); + cubeCards.add(new CardIdentity("Volrath's Stronghold", "")); + cubeCards.add(new CardIdentity("Wall of Blossoms", "")); + cubeCards.add(new CardIdentity("Wall of Omens", "")); + cubeCards.add(new CardIdentity("Wall of Roots", "")); + cubeCards.add(new CardIdentity("Wasteland", "")); + cubeCards.add(new CardIdentity("Waterfront Bouncer", "")); + cubeCards.add(new CardIdentity("Watery Grave", "")); + cubeCards.add(new CardIdentity("Wheel of Fortune", "")); + cubeCards.add(new CardIdentity("Wickerbough Elder", "")); + cubeCards.add(new CardIdentity("Wild Mongrel", "")); + cubeCards.add(new CardIdentity("Wild Nacatl", "")); + cubeCards.add(new CardIdentity("Wildfire", "")); + cubeCards.add(new CardIdentity("Willbender", "")); + cubeCards.add(new CardIdentity("Windswept Heath", "")); + cubeCards.add(new CardIdentity("Winter Orb", "")); + cubeCards.add(new CardIdentity("Wolfbitten Captive", "")); + cubeCards.add(new CardIdentity("Wolfir Silverheart", "")); + cubeCards.add(new CardIdentity("Wooded Foothills", "")); + cubeCards.add(new CardIdentity("Woodfall Primus", "")); + cubeCards.add(new CardIdentity("Worldly Tutor", "")); + cubeCards.add(new CardIdentity("Worn Powerstone", "")); + cubeCards.add(new CardIdentity("Wurmcoil Engine", "")); + cubeCards.add(new CardIdentity("Xenagos, the Reveler", "")); + cubeCards.add(new CardIdentity("Yavimaya Elder", "")); + cubeCards.add(new CardIdentity("Yawgmoth's Will", "")); + cubeCards.add(new CardIdentity("Young Pyromancer", "")); + cubeCards.add(new CardIdentity("Zuran Orb", "")); + + } +} diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOLegacyCube2015.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOLegacyCube2015.java index 1a51d0365b5..ff78a85711d 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOLegacyCube2015.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOLegacyCube2015.java @@ -54,7 +54,7 @@ public class MTGOLegacyCube2015 extends DraftCube { cubeCards.add(new DraftCube.CardIdentity("Angelic Destiny","")); cubeCards.add(new DraftCube.CardIdentity("Anger of the Gods","")); cubeCards.add(new DraftCube.CardIdentity("Animate Dead","")); - cubeCards.add(new DraftCube.CardIdentity("Anowon, the Ruiun Sage","")); + cubeCards.add(new DraftCube.CardIdentity("Anowon, the Ruin Sage","")); cubeCards.add(new DraftCube.CardIdentity("Arbor Elf","")); cubeCards.add(new DraftCube.CardIdentity("Arc Trail","")); cubeCards.add(new DraftCube.CardIdentity("Archangel of Thune","")); @@ -95,7 +95,7 @@ public class MTGOLegacyCube2015 extends DraftCube { cubeCards.add(new DraftCube.CardIdentity("Bloodline Keeper","")); cubeCards.add(new DraftCube.CardIdentity("Bloodlord of Vaasgoth","")); cubeCards.add(new DraftCube.CardIdentity("Bloodstained Mire","")); - cubeCards.add(new DraftCube.CardIdentity("Bogarden Hellkite","")); + cubeCards.add(new DraftCube.CardIdentity("Bogardan Hellkite","")); cubeCards.add(new DraftCube.CardIdentity("Bone Shredder","")); cubeCards.add(new DraftCube.CardIdentity("Bonesplitter","")); cubeCards.add(new DraftCube.CardIdentity("Bonfire of the Damned","")); @@ -274,8 +274,8 @@ public class MTGOLegacyCube2015 extends DraftCube { cubeCards.add(new DraftCube.CardIdentity("Green Sun's Zenith","")); cubeCards.add(new DraftCube.CardIdentity("Grim Lavamancer","")); cubeCards.add(new DraftCube.CardIdentity("Griselbrand","")); - cubeCards.add(new DraftCube.CardIdentity("Gruul Draz Assassin","")); - cubeCards.add(new DraftCube.CardIdentity("Gruul Draz Vampire","")); + cubeCards.add(new DraftCube.CardIdentity("Guul Draz Assassin","")); + cubeCards.add(new DraftCube.CardIdentity("Guul Draz Vampire","")); cubeCards.add(new DraftCube.CardIdentity("Hall of Triumph","")); cubeCards.add(new DraftCube.CardIdentity("Hallowed Fountain","")); cubeCards.add(new DraftCube.CardIdentity("Hallowed Spiritkeeper","")); @@ -332,7 +332,7 @@ public class MTGOLegacyCube2015 extends DraftCube { cubeCards.add(new DraftCube.CardIdentity("Land Tax","")); cubeCards.add(new DraftCube.CardIdentity("Legacy's Allure","")); cubeCards.add(new DraftCube.CardIdentity("Leonin Relic-Warder","")); - cubeCards.add(new DraftCube.CardIdentity("Life From the Loam","")); + cubeCards.add(new DraftCube.CardIdentity("Life from the Loam","")); cubeCards.add(new DraftCube.CardIdentity("Lightning Bolt","")); cubeCards.add(new DraftCube.CardIdentity("Lightning Greaves","")); cubeCards.add(new DraftCube.CardIdentity("Lightning Helix","")); diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOMarchCube2014.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOMarchCube2014.java index 6dfe2614902..d2499ae6bdd 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOMarchCube2014.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MTGOMarchCube2014.java @@ -1,763 +1,762 @@ -/* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ -package mage.tournament.cubes; - -import mage.game.draft.DraftCube; - -/** - * - * @author LevelX2 - */ -public class MTGOMarchCube2014 extends DraftCube { - - public MTGOMarchCube2014() { - super("MTGO Cube March 2014"); - - cubeCards.add(new CardIdentity("Academy Rector","")); - cubeCards.add(new CardIdentity("Akroma, Angel of Wrath","")); - cubeCards.add(new CardIdentity("Angel of Serenity","")); - cubeCards.add(new CardIdentity("Aven Mindcensor","")); - cubeCards.add(new CardIdentity("Baneslayer Angel","")); - cubeCards.add(new CardIdentity("Blade Splicer","")); - cubeCards.add(new CardIdentity("Calciderm","")); - cubeCards.add(new CardIdentity("Cloudgoat Ranger","")); - cubeCards.add(new CardIdentity("Descendant of Kiyomaro","")); - cubeCards.add(new CardIdentity("Eight-and-a-Half-Tails","")); - cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite","")); - cubeCards.add(new CardIdentity("Elite Vanguard","")); - cubeCards.add(new CardIdentity("Emeria Angel","")); - cubeCards.add(new CardIdentity("Exalted Angel","")); - cubeCards.add(new CardIdentity("Banisher Priest","")); - cubeCards.add(new CardIdentity("Flickerwisp","")); - cubeCards.add(new CardIdentity("Hand of Honor","")); - cubeCards.add(new CardIdentity("Hero of Bladehold","")); - cubeCards.add(new CardIdentity("Hokori, Dust Drinker","")); - cubeCards.add(new CardIdentity("Iona, Shield of Emeria","")); - cubeCards.add(new CardIdentity("Isamaru, Hound of Konda","")); - cubeCards.add(new CardIdentity("Jötun Grunt","")); - cubeCards.add(new CardIdentity("Kami of Ancient Law","")); - cubeCards.add(new CardIdentity("Knight of Glory","")); - cubeCards.add(new CardIdentity("Imposing Sovereign","")); - cubeCards.add(new CardIdentity("Leonin Relic-Warder","")); - cubeCards.add(new CardIdentity("Linvala, Keeper of Silence","")); - cubeCards.add(new CardIdentity("Loam Lion","")); - cubeCards.add(new CardIdentity("Mentor of the Meek","")); - cubeCards.add(new CardIdentity("Mirran Crusader","")); - cubeCards.add(new CardIdentity("Mirror Entity","")); - cubeCards.add(new CardIdentity("Mother of Runes","")); - cubeCards.add(new CardIdentity("Nearheath Pilgrim","")); - cubeCards.add(new CardIdentity("Brimaz, King of Oreskos","")); - cubeCards.add(new CardIdentity("Porcelain Legionnaire","")); - cubeCards.add(new CardIdentity("Pristine Angel","")); - cubeCards.add(new CardIdentity("Ranger of Eos","")); - cubeCards.add(new CardIdentity("Restoration Angel","")); - cubeCards.add(new CardIdentity("Reveillark","")); - cubeCards.add(new CardIdentity("Soldier of the Pantheon","")); - cubeCards.add(new CardIdentity("Savannah Lions","")); - cubeCards.add(new CardIdentity("Shrieking Grotesque","")); - cubeCards.add(new CardIdentity("Silver Knight","")); - cubeCards.add(new CardIdentity("Silverblade Paladin","")); - cubeCards.add(new CardIdentity("Steppe Lynx","")); - cubeCards.add(new CardIdentity("Stonecloaker","")); - cubeCards.add(new CardIdentity("Stoneforge Mystic","")); - cubeCards.add(new CardIdentity("Student of Warfare","")); - cubeCards.add(new CardIdentity("Sublime Archangel","")); - cubeCards.add(new CardIdentity("Sun Titan","")); - cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben","")); - cubeCards.add(new CardIdentity("Wall of Omens","")); - cubeCards.add(new CardIdentity("Wall of Reverence","")); - cubeCards.add(new CardIdentity("Weathered Wayfarer","")); - cubeCards.add(new CardIdentity("Whipcorder","")); - cubeCards.add(new CardIdentity("Yosei, the Morning Star","")); - cubeCards.add(new CardIdentity("Heliod, God of the Sun","")); - cubeCards.add(new CardIdentity("Faith's Fetters","")); - cubeCards.add(new CardIdentity("Spear of Heliod","")); - cubeCards.add(new CardIdentity("Honor of the Pure","")); - cubeCards.add(new CardIdentity("Journey to Nowhere","")); - cubeCards.add(new CardIdentity("Land Tax","")); - cubeCards.add(new CardIdentity("Oblivion Ring","")); - cubeCards.add(new CardIdentity("Parallax Wave","")); - cubeCards.add(new CardIdentity("Seal of Cleansing","")); - cubeCards.add(new CardIdentity("Celestial Purge","")); - cubeCards.add(new CardIdentity("Condemn","")); - cubeCards.add(new CardIdentity("Disenchant","")); - cubeCards.add(new CardIdentity("Dismantling Blow","")); - cubeCards.add(new CardIdentity("Enlightened Tutor","")); - cubeCards.add(new CardIdentity("Mana Tithe","")); - cubeCards.add(new CardIdentity("Momentary Blink","")); - cubeCards.add(new CardIdentity("Oust","")); - cubeCards.add(new CardIdentity("Path to Exile","")); - cubeCards.add(new CardIdentity("Elspeth, Sun's Champion","")); - cubeCards.add(new CardIdentity("Swords to Plowshares","")); - cubeCards.add(new CardIdentity("Archangel of Thune","")); - cubeCards.add(new CardIdentity("Ajani Goldmane","")); - cubeCards.add(new CardIdentity("Ajani, Caller of the Pride","")); - cubeCards.add(new CardIdentity("Elspeth Tirel","")); - cubeCards.add(new CardIdentity("Elspeth, Knight-Errant","")); - cubeCards.add(new CardIdentity("Gideon Jura","")); - cubeCards.add(new CardIdentity("Gideon, Champion of Justice","")); - cubeCards.add(new CardIdentity("Akroma's Vengeance","")); - cubeCards.add(new CardIdentity("Armageddon","")); - cubeCards.add(new CardIdentity("Balance","")); - cubeCards.add(new CardIdentity("Celestial Flare","")); - cubeCards.add(new CardIdentity("Catastrophe","")); - cubeCards.add(new CardIdentity("Day of Judgment","")); - cubeCards.add(new CardIdentity("Decree of Justice","")); - cubeCards.add(new CardIdentity("Entreat the Angels","")); - cubeCards.add(new CardIdentity("Hallowed Burial","")); - cubeCards.add(new CardIdentity("Lingering Souls","")); - cubeCards.add(new CardIdentity("Martial Coup","")); - cubeCards.add(new CardIdentity("Ravages of War","")); - cubeCards.add(new CardIdentity("Rout","")); - cubeCards.add(new CardIdentity("Spectral Procession","")); - cubeCards.add(new CardIdentity("Terminus","")); - cubeCards.add(new CardIdentity("Wrath of God","")); - cubeCards.add(new CardIdentity("Phyrexian Metamorph","")); - cubeCards.add(new CardIdentity("AEtherling","")); - cubeCards.add(new CardIdentity("Augur of Bolas","")); - cubeCards.add(new CardIdentity("Consecrated Sphinx","")); - cubeCards.add(new CardIdentity("Coralhelm Commander","")); - cubeCards.add(new CardIdentity("Court Hussar","")); - cubeCards.add(new CardIdentity("Cursecatcher","")); - cubeCards.add(new CardIdentity("Delver of Secrets","")); - cubeCards.add(new CardIdentity("Dungeon Geists","")); - cubeCards.add(new CardIdentity("Enclave Cryptologist","")); - cubeCards.add(new CardIdentity("Fathom Seer","")); - cubeCards.add(new CardIdentity("Frost Titan","")); - cubeCards.add(new CardIdentity("Glen Elendra Archmage","")); - cubeCards.add(new CardIdentity("Jushi Apprentice","")); - cubeCards.add(new CardIdentity("Keiga, the Tide Star","")); - cubeCards.add(new CardIdentity("Kira, Great Glass-Spinner","")); - cubeCards.add(new CardIdentity("Looter il-Kor","")); - cubeCards.add(new CardIdentity("Man-o'-War","")); - cubeCards.add(new CardIdentity("Meloku the Clouded Mirror","")); - cubeCards.add(new CardIdentity("Mulldrifter","")); - cubeCards.add(new CardIdentity("Master of Waves","")); - cubeCards.add(new CardIdentity("Old Man of the Sea","")); - cubeCards.add(new CardIdentity("Palinchron","")); - cubeCards.add(new CardIdentity("Phantasmal Bear","")); - cubeCards.add(new CardIdentity("Phantasmal Image","")); - cubeCards.add(new CardIdentity("Riftwing Cloudskate","")); - cubeCards.add(new CardIdentity("Sakashima's Student","")); - cubeCards.add(new CardIdentity("Sea Gate Oracle","")); - cubeCards.add(new CardIdentity("Serendib Efreet","")); - cubeCards.add(new CardIdentity("Snapcaster Mage","")); - cubeCards.add(new CardIdentity("Sower of Temptation","")); - cubeCards.add(new CardIdentity("Talrand, Sky Summoner","")); - cubeCards.add(new CardIdentity("Teferi, Mage of Zhalfir","")); - cubeCards.add(new CardIdentity("Thieving Magpie","")); - cubeCards.add(new CardIdentity("Tradewind Rider","")); - cubeCards.add(new CardIdentity("Trinket Mage","")); - cubeCards.add(new CardIdentity("Vendilion Clique","")); - cubeCards.add(new CardIdentity("Venser, Shaper Savant","")); - cubeCards.add(new CardIdentity("Vesuvan Shapeshifter","")); - cubeCards.add(new CardIdentity("Voidmage Prodigy","")); - cubeCards.add(new CardIdentity("Wake Thrasher","")); - cubeCards.add(new CardIdentity("Willbender","")); - cubeCards.add(new CardIdentity("Control Magic","")); - cubeCards.add(new CardIdentity("Future Sight","")); - cubeCards.add(new CardIdentity("Legacy's Allure","")); - cubeCards.add(new CardIdentity("Narcolepsy","")); - cubeCards.add(new CardIdentity("Opposition","")); - cubeCards.add(new CardIdentity("Spreading Seas","")); - cubeCards.add(new CardIdentity("Treachery","")); - cubeCards.add(new CardIdentity("Blue Elemental Blast","")); - cubeCards.add(new CardIdentity("Brain Freeze","")); - cubeCards.add(new CardIdentity("Brainstorm","")); - cubeCards.add(new CardIdentity("Capsize","")); - cubeCards.add(new CardIdentity("Condescend","")); - cubeCards.add(new CardIdentity("Counterspell","")); - cubeCards.add(new CardIdentity("Cryptic Command","")); - cubeCards.add(new CardIdentity("Daze","")); - cubeCards.add(new CardIdentity("Dismiss","")); - cubeCards.add(new CardIdentity("Dissipate","")); - cubeCards.add(new CardIdentity("Essence Scatter","")); - cubeCards.add(new CardIdentity("Fact or Fiction","")); - cubeCards.add(new CardIdentity("Flashfreeze","")); - cubeCards.add(new CardIdentity("Forbid","")); - cubeCards.add(new CardIdentity("Thassa, God of the Sea","")); - cubeCards.add(new CardIdentity("Force of Will","")); - cubeCards.add(new CardIdentity("Force Spike","")); - cubeCards.add(new CardIdentity("Frantic Search","")); - cubeCards.add(new CardIdentity("Gifts Ungiven","")); - cubeCards.add(new CardIdentity("Hinder","")); - cubeCards.add(new CardIdentity("Impulse","")); - cubeCards.add(new CardIdentity("Into the Roil","")); - cubeCards.add(new CardIdentity("Mana Leak","")); - cubeCards.add(new CardIdentity("Miscalculation","")); - cubeCards.add(new CardIdentity("Misdirection","")); - cubeCards.add(new CardIdentity("Mystical Tutor","")); - cubeCards.add(new CardIdentity("Negate","")); - cubeCards.add(new CardIdentity("Pact of Negation","")); - cubeCards.add(new CardIdentity("Remand","")); - cubeCards.add(new CardIdentity("Repeal","")); - cubeCards.add(new CardIdentity("Spell Pierce","")); - cubeCards.add(new CardIdentity("Thirst for Knowledge","")); - cubeCards.add(new CardIdentity("Turnabout","")); - cubeCards.add(new CardIdentity("Jace Beleren","")); - cubeCards.add(new CardIdentity("Jace, Architect of Thought","")); - cubeCards.add(new CardIdentity("Jace, the Mind Sculptor","")); - cubeCards.add(new CardIdentity("Tamiyo, the Moon Sage","")); - cubeCards.add(new CardIdentity("Ancestral Vision","")); - cubeCards.add(new CardIdentity("Compulsive Research","")); - cubeCards.add(new CardIdentity("Deep Analysis","")); - cubeCards.add(new CardIdentity("Mind's Desire","")); - cubeCards.add(new CardIdentity("Ponder","")); - cubeCards.add(new CardIdentity("Preordain","")); - cubeCards.add(new CardIdentity("Serum Visions","")); - cubeCards.add(new CardIdentity("Show and Tell","")); - cubeCards.add(new CardIdentity("Tidings","")); - cubeCards.add(new CardIdentity("Time Spiral","")); - cubeCards.add(new CardIdentity("Time Warp","")); - cubeCards.add(new CardIdentity("Tinker","")); - cubeCards.add(new CardIdentity("Upheaval","")); - cubeCards.add(new CardIdentity("Bane of the Living","")); - cubeCards.add(new CardIdentity("Bloodghast","")); - cubeCards.add(new CardIdentity("Bloodgift Demon","")); - cubeCards.add(new CardIdentity("Bloodline Keeper","")); - cubeCards.add(new CardIdentity("Bone Shredder","")); - cubeCards.add(new CardIdentity("Braids, Cabal Minion","")); - cubeCards.add(new CardIdentity("Carnophage","")); - cubeCards.add(new CardIdentity("Dark Confidant","")); - cubeCards.add(new CardIdentity("Diregraf Ghoul","")); - cubeCards.add(new CardIdentity("Gatekeeper of Malakir","")); - cubeCards.add(new CardIdentity("Geralf's Messenger","")); - cubeCards.add(new CardIdentity("Grave Titan","")); - cubeCards.add(new CardIdentity("Graveborn Muse","")); - cubeCards.add(new CardIdentity("Gravecrawler","")); - cubeCards.add(new CardIdentity("Griselbrand","")); - cubeCards.add(new CardIdentity("Guul Draz Assassin","")); - cubeCards.add(new CardIdentity("Hand of Cruelty","")); - cubeCards.add(new CardIdentity("Headhunter","")); - cubeCards.add(new CardIdentity("Hypnotic Specter","")); - cubeCards.add(new CardIdentity("Ink-Eyes, Servant of Oni","")); - cubeCards.add(new CardIdentity("Knight of Infamy","")); - cubeCards.add(new CardIdentity("Kokusho, the Evening Star","")); - cubeCards.add(new CardIdentity("Liliana's Reaver","")); - cubeCards.add(new CardIdentity("Mesmeric Fiend","")); - cubeCards.add(new CardIdentity("Nantuko Shade","")); - cubeCards.add(new CardIdentity("Nekrataal","")); - cubeCards.add(new CardIdentity("Nezumi Graverobber","")); - cubeCards.add(new CardIdentity("Nezumi Shortfang","")); - cubeCards.add(new CardIdentity("Nightscape Familiar","")); - cubeCards.add(new CardIdentity("Erebos, God of the Dead","")); - cubeCards.add(new CardIdentity("Oona's Prowler","")); - cubeCards.add(new CardIdentity("Phyrexian Obliterator","")); - cubeCards.add(new CardIdentity("Phyrexian Rager","")); - cubeCards.add(new CardIdentity("Plague Sliver","")); - cubeCards.add(new CardIdentity("Putrid Imp","")); - cubeCards.add(new CardIdentity("Pain Seer","")); - cubeCards.add(new CardIdentity("Shriekmaw","")); - cubeCards.add(new CardIdentity("Silent Specter","")); - cubeCards.add(new CardIdentity("Lifebane Zombie","")); - cubeCards.add(new CardIdentity("Skinrender","")); - cubeCards.add(new CardIdentity("Tombstalker","")); - cubeCards.add(new CardIdentity("Herald of Torment","")); - cubeCards.add(new CardIdentity("Vampire Hexmage","")); - cubeCards.add(new CardIdentity("Vampire Lacerator","")); - cubeCards.add(new CardIdentity("Vampire Nighthawk","")); - cubeCards.add(new CardIdentity("Visara the Dreadful","")); - cubeCards.add(new CardIdentity("Wrench Mind","")); - cubeCards.add(new CardIdentity("Animate Dead","")); - cubeCards.add(new CardIdentity("Attrition","")); - cubeCards.add(new CardIdentity("Bitterblossom","")); - cubeCards.add(new CardIdentity("Diabolic Servitude","")); - cubeCards.add(new CardIdentity("Necromancy","")); - cubeCards.add(new CardIdentity("Necropotence","")); - cubeCards.add(new CardIdentity("Phyrexian Arena","")); - cubeCards.add(new CardIdentity("Recurring Nightmare","")); - cubeCards.add(new CardIdentity("Sarcomancy","")); - cubeCards.add(new CardIdentity("Dark Ritual","")); - cubeCards.add(new CardIdentity("Disfigure","")); - cubeCards.add(new CardIdentity("Dismember","")); - cubeCards.add(new CardIdentity("Doom Blade","")); - cubeCards.add(new CardIdentity("Duress","")); - cubeCards.add(new CardIdentity("Entomb","")); - cubeCards.add(new CardIdentity("Go for the Throat","")); - cubeCards.add(new CardIdentity("Makeshift Mannequin","")); - cubeCards.add(new CardIdentity("Night's Whisper","")); - cubeCards.add(new CardIdentity("Skeletal Scrying","")); - cubeCards.add(new CardIdentity("Slaughter Pact","")); - cubeCards.add(new CardIdentity("Smother","")); - cubeCards.add(new CardIdentity("Snuff Out","")); - cubeCards.add(new CardIdentity("Sorin's Thirst","")); - cubeCards.add(new CardIdentity("Spinning Darkness","")); - cubeCards.add(new CardIdentity("Tainted Pact","")); - cubeCards.add(new CardIdentity("Tragic Slip","")); - cubeCards.add(new CardIdentity("Ultimate Price","")); - cubeCards.add(new CardIdentity("Vampiric Tutor","")); - cubeCards.add(new CardIdentity("Liliana of the Veil","")); - cubeCards.add(new CardIdentity("Liliana Vess","")); - cubeCards.add(new CardIdentity("Black Sun's Zenith","")); - cubeCards.add(new CardIdentity("Buried Alive","")); - cubeCards.add(new CardIdentity("Chainer's Edict","")); - cubeCards.add(new CardIdentity("Corrupt","")); - cubeCards.add(new CardIdentity("Damnation","")); - cubeCards.add(new CardIdentity("Death Cloud","")); - cubeCards.add(new CardIdentity("Demonic Tutor","")); - cubeCards.add(new CardIdentity("Exhume","")); - cubeCards.add(new CardIdentity("Hymn to Tourach","")); - cubeCards.add(new CardIdentity("Inquisition of Kozilek","")); - cubeCards.add(new CardIdentity("Living Death","")); - cubeCards.add(new CardIdentity("Persecute","")); - cubeCards.add(new CardIdentity("Hero's Downfall","")); - cubeCards.add(new CardIdentity("Reanimate","")); - cubeCards.add(new CardIdentity("Sign in Blood","")); - cubeCards.add(new CardIdentity("Sinkhole","")); - cubeCards.add(new CardIdentity("Stupor","")); - cubeCards.add(new CardIdentity("Tendrils of Agony","")); - cubeCards.add(new CardIdentity("Tendrils of Corruption","")); - cubeCards.add(new CardIdentity("Thoughtseize","")); - cubeCards.add(new CardIdentity("Unburial Rites","")); - cubeCards.add(new CardIdentity("Yawgmoth's Will","")); - cubeCards.add(new CardIdentity("Ash Zealot","")); - cubeCards.add(new CardIdentity("Avalanche Riders","")); - cubeCards.add(new CardIdentity("Ball Lightning","")); - cubeCards.add(new CardIdentity("Blistering Firecat","")); - cubeCards.add(new CardIdentity("Bogardan Hellkite","")); - cubeCards.add(new CardIdentity("Chandra, the Firebrand","")); - cubeCards.add(new CardIdentity("Chandra's Phoenix","")); - cubeCards.add(new CardIdentity("Countryside Crusher","")); - cubeCards.add(new CardIdentity("Cunning Sparkmage","")); - cubeCards.add(new CardIdentity("Ember Hauler","")); - cubeCards.add(new CardIdentity("Flametongue Kavu","")); - cubeCards.add(new CardIdentity("Frenzied Goblin","")); - cubeCards.add(new CardIdentity("Gathan Raiders","")); - cubeCards.add(new CardIdentity("Goblin Cadets","")); - cubeCards.add(new CardIdentity("Goblin Guide","")); - cubeCards.add(new CardIdentity("Firedrinker Satyr","")); - cubeCards.add(new CardIdentity("Goblin Ruinblaster","")); - cubeCards.add(new CardIdentity("Goblin Welder","")); - cubeCards.add(new CardIdentity("Gore-House Chainwalker","")); - cubeCards.add(new CardIdentity("Greater Gargadon","")); - cubeCards.add(new CardIdentity("Grim Lavamancer","")); - cubeCards.add(new CardIdentity("Hell's Thunder","")); - cubeCards.add(new CardIdentity("Hellrider","")); - cubeCards.add(new CardIdentity("Hellspark Elemental","")); - cubeCards.add(new CardIdentity("Hero of Oxid Ridge","")); - cubeCards.add(new CardIdentity("Inferno Titan","")); - cubeCards.add(new CardIdentity("Jackal Pup","")); - cubeCards.add(new CardIdentity("Kargan Dragonlord","")); - cubeCards.add(new CardIdentity("Keldon Champion","")); - cubeCards.add(new CardIdentity("Keldon Marauders","")); - cubeCards.add(new CardIdentity("Kird Ape","")); - cubeCards.add(new CardIdentity("Lightning Mauler","")); - cubeCards.add(new CardIdentity("Magus of the Moon","")); - cubeCards.add(new CardIdentity("Mogg War Marshal","")); - cubeCards.add(new CardIdentity("Orcish Lumberjack","")); - cubeCards.add(new CardIdentity("Plated Geopede","")); - cubeCards.add(new CardIdentity("Priest of Urabrask","")); - cubeCards.add(new CardIdentity("Ravenous Baboons","")); - cubeCards.add(new CardIdentity("Siege-Gang Commander","")); - cubeCards.add(new CardIdentity("Spikeshot Elder","")); - cubeCards.add(new CardIdentity("Stormblood Berserker","")); - cubeCards.add(new CardIdentity("Stromkirk Noble","")); - cubeCards.add(new CardIdentity("Taurean Mauler","")); - cubeCards.add(new CardIdentity("Thunderblust","")); - cubeCards.add(new CardIdentity("Thundermaw Hellkite","")); - cubeCards.add(new CardIdentity("Thunderscape Battlemage","")); - cubeCards.add(new CardIdentity("Tin Street Hooligan","")); - cubeCards.add(new CardIdentity("Torch Fiend","")); - cubeCards.add(new CardIdentity("Urabrask the Hidden","")); - cubeCards.add(new CardIdentity("Zealous Conscripts","")); - cubeCards.add(new CardIdentity("Zo-Zu the Punisher","")); - cubeCards.add(new CardIdentity("Genju of the Spires","")); - cubeCards.add(new CardIdentity("Sneak Attack","")); - cubeCards.add(new CardIdentity("Sulfuric Vortex","")); - cubeCards.add(new CardIdentity("Ancient Grudge","")); - cubeCards.add(new CardIdentity("Brimstone Volley","")); - cubeCards.add(new CardIdentity("Burst Lightning","")); - cubeCards.add(new CardIdentity("Chain Lightning","")); - cubeCards.add(new CardIdentity("Chaos Warp","")); - cubeCards.add(new CardIdentity("Char","")); - cubeCards.add(new CardIdentity("Desperate Ravings","")); - cubeCards.add(new CardIdentity("Fireblast","")); - cubeCards.add(new CardIdentity("Firestorm","")); - cubeCards.add(new CardIdentity("Flame Javelin","")); - cubeCards.add(new CardIdentity("Searing Blood","")); - cubeCards.add(new CardIdentity("Lightning Bolt","")); - cubeCards.add(new CardIdentity("Magma Jet","")); - cubeCards.add(new CardIdentity("Price of Progress","")); - cubeCards.add(new CardIdentity("Red Elemental Blast","")); - cubeCards.add(new CardIdentity("Searing Blaze","")); - cubeCards.add(new CardIdentity("Seething Song","")); - cubeCards.add(new CardIdentity("Skullcrack","")); - cubeCards.add(new CardIdentity("Smash to Smithereens","")); - cubeCards.add(new CardIdentity("Ogre Battledriver","")); - cubeCards.add(new CardIdentity("Volcanic Fallout","")); - cubeCards.add(new CardIdentity("Koth of the Hammer","")); - cubeCards.add(new CardIdentity("Arc Trail","")); - cubeCards.add(new CardIdentity("Chandra, Pyromaster","")); - cubeCards.add(new CardIdentity("Bonfire of the Damned","")); - cubeCards.add(new CardIdentity("Burning of Xinye","")); - cubeCards.add(new CardIdentity("Purphoros, God of the Forge","")); - cubeCards.add(new CardIdentity("Devil's Play","")); - cubeCards.add(new CardIdentity("Earthquake","")); - cubeCards.add(new CardIdentity("Empty the Warrens","")); - cubeCards.add(new CardIdentity("Faithless Looting","")); - cubeCards.add(new CardIdentity("Firebolt","")); - cubeCards.add(new CardIdentity("Forked Bolt","")); - cubeCards.add(new CardIdentity("Gamble","")); - cubeCards.add(new CardIdentity("Mark of Mutiny","")); - cubeCards.add(new CardIdentity("Mizzium Mortars","")); - cubeCards.add(new CardIdentity("Molten Rain","")); - cubeCards.add(new CardIdentity("Pillage","")); - cubeCards.add(new CardIdentity("Pyroclasm","")); - cubeCards.add(new CardIdentity("Reckless Charge","")); - cubeCards.add(new CardIdentity("Rift Bolt","")); - cubeCards.add(new CardIdentity("Rolling Earthquake","")); - cubeCards.add(new CardIdentity("Slagstorm","")); - cubeCards.add(new CardIdentity("Wheel of Fortune","")); - cubeCards.add(new CardIdentity("Wildfire","")); - cubeCards.add(new CardIdentity("Birthing Pod","")); - cubeCards.add(new CardIdentity("Acidic Slime","")); - cubeCards.add(new CardIdentity("Arbor Elf","")); - cubeCards.add(new CardIdentity("Avacyn's Pilgrim","")); - cubeCards.add(new CardIdentity("Avenger of Zendikar","")); - cubeCards.add(new CardIdentity("Birds of Paradise","")); - cubeCards.add(new CardIdentity("Blastoderm","")); - cubeCards.add(new CardIdentity("Borderland Ranger","")); - cubeCards.add(new CardIdentity("Boreal Druid","")); - cubeCards.add(new CardIdentity("Brooding Saurian","")); - cubeCards.add(new CardIdentity("Boon Satyr","")); - cubeCards.add(new CardIdentity("Deranged Hermit","")); - cubeCards.add(new CardIdentity("Sylvan Caryatid","")); - cubeCards.add(new CardIdentity("Dryad Sophisticate","")); - cubeCards.add(new CardIdentity("Elves of Deep Shadow","")); - cubeCards.add(new CardIdentity("Eternal Witness","")); - cubeCards.add(new CardIdentity("Experiment One","")); - cubeCards.add(new CardIdentity("Fauna Shaman","")); - cubeCards.add(new CardIdentity("Flinthoof Boar","")); - cubeCards.add(new CardIdentity("Fyndhorn Elves","")); - cubeCards.add(new CardIdentity("Genesis","")); - cubeCards.add(new CardIdentity("Great Sable Stag","")); - cubeCards.add(new CardIdentity("Hystrodon","")); - cubeCards.add(new CardIdentity("Indrik Stomphowler","")); - cubeCards.add(new CardIdentity("Joraga Treespeaker","")); - cubeCards.add(new CardIdentity("Llanowar Elves","")); - cubeCards.add(new CardIdentity("Lotus Cobra","")); - cubeCards.add(new CardIdentity("Master of the Wild Hunt","")); - cubeCards.add(new CardIdentity("Mold Shambler","")); - cubeCards.add(new CardIdentity("Nantuko Vigilante","")); - cubeCards.add(new CardIdentity("Noble Hierarch","")); - cubeCards.add(new CardIdentity("Obstinate Baloth","")); - cubeCards.add(new CardIdentity("Ohran Viper","")); - cubeCards.add(new CardIdentity("Oracle of Mul Daya","")); - cubeCards.add(new CardIdentity("Primeval Titan","")); - cubeCards.add(new CardIdentity("Rofellos, Llanowar Emissary","")); - cubeCards.add(new CardIdentity("Sakura-Tribe Elder","")); - cubeCards.add(new CardIdentity("Scavenging Ooze","")); - cubeCards.add(new CardIdentity("Strangleroot Geist","")); - cubeCards.add(new CardIdentity("Tarmogoyf","")); - cubeCards.add(new CardIdentity("Terastodon","")); - cubeCards.add(new CardIdentity("Thelonite Hermit","")); - cubeCards.add(new CardIdentity("Thornscape Battlemage","")); - cubeCards.add(new CardIdentity("Thragtusk","")); - cubeCards.add(new CardIdentity("Thrun, the Last Troll","")); - cubeCards.add(new CardIdentity("Troll Ascetic","")); - cubeCards.add(new CardIdentity("Ulvenwald Tracker","")); - cubeCards.add(new CardIdentity("Vengevine","")); - cubeCards.add(new CardIdentity("Wall of Blossoms","")); - cubeCards.add(new CardIdentity("Wall of Roots","")); - cubeCards.add(new CardIdentity("Wickerbough Elder","")); - cubeCards.add(new CardIdentity("Wild Nacatl","")); - cubeCards.add(new CardIdentity("Wolfir Silverheart","")); - cubeCards.add(new CardIdentity("Wood Elves","")); - cubeCards.add(new CardIdentity("Woodfall Primus","")); - cubeCards.add(new CardIdentity("Yavimaya Elder","")); - cubeCards.add(new CardIdentity("Polukranos, World Eater","")); - cubeCards.add(new CardIdentity("Courser of Kruphix","")); - cubeCards.add(new CardIdentity("Awakening Zone","")); - cubeCards.add(new CardIdentity("Exploration","")); - cubeCards.add(new CardIdentity("Fertile Ground","")); - cubeCards.add(new CardIdentity("Heartbeat of Spring","")); - cubeCards.add(new CardIdentity("Rancor","")); - cubeCards.add(new CardIdentity("Survival of the Fittest","")); - cubeCards.add(new CardIdentity("Sylvan Library","")); - cubeCards.add(new CardIdentity("Beast Within","")); - cubeCards.add(new CardIdentity("Chord of Calling","")); - cubeCards.add(new CardIdentity("Krosan Grip","")); - cubeCards.add(new CardIdentity("Moment's Peace","")); - cubeCards.add(new CardIdentity("Naturalize","")); - cubeCards.add(new CardIdentity("Nature's Claim","")); - cubeCards.add(new CardIdentity("Vines of Vastwood","")); - cubeCards.add(new CardIdentity("Garruk Relentless","")); - cubeCards.add(new CardIdentity("Garruk Wildspeaker","")); - cubeCards.add(new CardIdentity("Garruk, Primal Hunter","")); - cubeCards.add(new CardIdentity("Pattern of Rebirth","")); - cubeCards.add(new CardIdentity("Call of the Herd","")); - cubeCards.add(new CardIdentity("Channel","")); - cubeCards.add(new CardIdentity("Cultivate","")); - cubeCards.add(new CardIdentity("Elvish Mystic","")); - cubeCards.add(new CardIdentity("Eureka","")); - cubeCards.add(new CardIdentity("Explore","")); - cubeCards.add(new CardIdentity("Farseek","")); - cubeCards.add(new CardIdentity("Genesis Wave","")); - cubeCards.add(new CardIdentity("Green Sun's Zenith","")); - cubeCards.add(new CardIdentity("Harmonize","")); - cubeCards.add(new CardIdentity("Life from the Loam","")); - cubeCards.add(new CardIdentity("Natural Order","")); - cubeCards.add(new CardIdentity("Nature's Lore","")); - cubeCards.add(new CardIdentity("Nostalgic Dreams","")); - cubeCards.add(new CardIdentity("Plow Under","")); - cubeCards.add(new CardIdentity("Primal Command","")); - cubeCards.add(new CardIdentity("Rampant Growth","")); - cubeCards.add(new CardIdentity("Regrowth","")); - cubeCards.add(new CardIdentity("Restock","")); - cubeCards.add(new CardIdentity("Rude Awakening","")); - cubeCards.add(new CardIdentity("Search for Tomorrow","")); - cubeCards.add(new CardIdentity("Stunted Growth","")); - cubeCards.add(new CardIdentity("Tooth and Nail","")); - cubeCards.add(new CardIdentity("Academy Ruins","")); - cubeCards.add(new CardIdentity("Adarkar Wastes","")); - cubeCards.add(new CardIdentity("Ancient Tomb","")); - cubeCards.add(new CardIdentity("Seaside Citadel","")); - cubeCards.add(new CardIdentity("Arid Mesa","")); - cubeCards.add(new CardIdentity("Azorius Chancery","")); - cubeCards.add(new CardIdentity("Bad River","")); - cubeCards.add(new CardIdentity("Badlands","")); - cubeCards.add(new CardIdentity("Barbarian Ring","")); - cubeCards.add(new CardIdentity("Battlefield Forge","")); - cubeCards.add(new CardIdentity("Bayou","")); - cubeCards.add(new CardIdentity("Blood Crypt","")); - cubeCards.add(new CardIdentity("Bloodstained Mire","")); - cubeCards.add(new CardIdentity("Boros Garrison","")); - cubeCards.add(new CardIdentity("Breeding Pool","")); - cubeCards.add(new CardIdentity("Brushland","")); - cubeCards.add(new CardIdentity("Cascade Bluffs","")); - cubeCards.add(new CardIdentity("Caves of Koilos","")); - cubeCards.add(new CardIdentity("Celestial Colonnade","")); - cubeCards.add(new CardIdentity("City of Brass","")); - cubeCards.add(new CardIdentity("Clifftop Retreat","")); - cubeCards.add(new CardIdentity("Creeping Tar Pit","")); - cubeCards.add(new CardIdentity("Arcane Sanctum","")); - cubeCards.add(new CardIdentity("Dimir Aqueduct","")); - cubeCards.add(new CardIdentity("Dragonskull Summit","")); - cubeCards.add(new CardIdentity("Drowned Catacomb","")); - cubeCards.add(new CardIdentity("Faerie Conclave","")); - cubeCards.add(new CardIdentity("Fetid Heath","")); - cubeCards.add(new CardIdentity("Fire-Lit Thicket","")); - cubeCards.add(new CardIdentity("Flagstones of Trokair","")); - cubeCards.add(new CardIdentity("Flood Plain","")); - cubeCards.add(new CardIdentity("Flooded Grove","")); - cubeCards.add(new CardIdentity("Flooded Strand","")); - cubeCards.add(new CardIdentity("Gaea's Cradle","")); - cubeCards.add(new CardIdentity("Ghitu Encampment","")); - cubeCards.add(new CardIdentity("Glacial Fortress","")); - cubeCards.add(new CardIdentity("Godless Shrine","")); - cubeCards.add(new CardIdentity("Golgari Rot Farm","")); - cubeCards.add(new CardIdentity("Grasslands","")); - cubeCards.add(new CardIdentity("Graven Cairns","")); - cubeCards.add(new CardIdentity("Gruul Turf","")); - cubeCards.add(new CardIdentity("Halimar Depths","")); - cubeCards.add(new CardIdentity("Hallowed Fountain","")); - cubeCards.add(new CardIdentity("Hinterland Harbor","")); - cubeCards.add(new CardIdentity("Isolated Chapel","")); - cubeCards.add(new CardIdentity("Izzet Boilerworks","")); - cubeCards.add(new CardIdentity("Jungle Shrine","")); - cubeCards.add(new CardIdentity("Karakas","")); - cubeCards.add(new CardIdentity("Karplusan Forest","")); - cubeCards.add(new CardIdentity("Lake of the Dead","")); - cubeCards.add(new CardIdentity("Lavaclaw Reaches","")); - cubeCards.add(new CardIdentity("Llanowar Wastes","")); - cubeCards.add(new CardIdentity("Marsh Flats","")); - cubeCards.add(new CardIdentity("Maze of Ith","")); - cubeCards.add(new CardIdentity("Mishra's Factory","")); - cubeCards.add(new CardIdentity("Misty Rainforest","")); - cubeCards.add(new CardIdentity("Mountain Valley","")); - cubeCards.add(new CardIdentity("Murmuring Bosk","")); - cubeCards.add(new CardIdentity("Mutavault","")); - cubeCards.add(new CardIdentity("Mystic Gate","")); - cubeCards.add(new CardIdentity("Orzhov Basilica","")); - cubeCards.add(new CardIdentity("Overgrown Tomb","")); - cubeCards.add(new CardIdentity("Plateau","")); - cubeCards.add(new CardIdentity("Polluted Delta","")); - cubeCards.add(new CardIdentity("Raging Ravine","")); - cubeCards.add(new CardIdentity("Rakdos Carnarium","")); - cubeCards.add(new CardIdentity("Reflecting Pool","")); - cubeCards.add(new CardIdentity("Rishadan Port","")); - cubeCards.add(new CardIdentity("Rocky Tar Pit","")); - cubeCards.add(new CardIdentity("Rootbound Crag","")); - cubeCards.add(new CardIdentity("Rugged Prairie","")); - cubeCards.add(new CardIdentity("Sacred Foundry","")); - cubeCards.add(new CardIdentity("Savage Lands","")); - cubeCards.add(new CardIdentity("Savannah","")); - cubeCards.add(new CardIdentity("Scalding Tarn","")); - cubeCards.add(new CardIdentity("Scrubland","")); - cubeCards.add(new CardIdentity("Crumbling Necropolis","")); - cubeCards.add(new CardIdentity("Selesnya Sanctuary","")); - cubeCards.add(new CardIdentity("Shivan Reef","")); - cubeCards.add(new CardIdentity("Simic Growth Chamber","")); - cubeCards.add(new CardIdentity("Steam Vents","")); - cubeCards.add(new CardIdentity("Stirring Wildwood","")); - cubeCards.add(new CardIdentity("Stomping Grounds ","")); - cubeCards.add(new CardIdentity("Strip Mine","")); - cubeCards.add(new CardIdentity("Sulfur Falls","")); - cubeCards.add(new CardIdentity("Sulfurous Springs","")); - cubeCards.add(new CardIdentity("Sunken Ruins","")); - cubeCards.add(new CardIdentity("Sunpetal Grove","")); - cubeCards.add(new CardIdentity("Taiga","")); - cubeCards.add(new CardIdentity("Tectonic Edge","")); - cubeCards.add(new CardIdentity("Teetering Peaks","")); - cubeCards.add(new CardIdentity("Temple Garden","")); - cubeCards.add(new CardIdentity("Thawing Glaciers","")); - cubeCards.add(new CardIdentity("Treetop Village","")); - cubeCards.add(new CardIdentity("Tropical Island","")); - cubeCards.add(new CardIdentity("Tundra","")); - cubeCards.add(new CardIdentity("Twilight Mire","")); - cubeCards.add(new CardIdentity("Underground River","")); - cubeCards.add(new CardIdentity("Underground Sea","")); - cubeCards.add(new CardIdentity("Urborg, Tomb of Yawgmoth","")); - cubeCards.add(new CardIdentity("Verdant Catacombs","")); - cubeCards.add(new CardIdentity("Volcanic Island","")); - cubeCards.add(new CardIdentity("Volrath's Stronghold","")); - cubeCards.add(new CardIdentity("Wasteland","")); - cubeCards.add(new CardIdentity("Watery Grave","")); - cubeCards.add(new CardIdentity("Windbrisk Heights","")); - cubeCards.add(new CardIdentity("Windswept Heath","")); - cubeCards.add(new CardIdentity("Wooded Bastion","")); - cubeCards.add(new CardIdentity("Wooded Foothills","")); - cubeCards.add(new CardIdentity("Woodland Cemetery","")); - cubeCards.add(new CardIdentity("Yavimaya Coast","")); - cubeCards.add(new CardIdentity("Fleecemane Lion","")); - cubeCards.add(new CardIdentity("Baleful Strix","")); - cubeCards.add(new CardIdentity("Shardless Agent","")); - cubeCards.add(new CardIdentity("Bloodbraid Elf","")); - cubeCards.add(new CardIdentity("Broodmate Dragon","")); - cubeCards.add(new CardIdentity("Edric, Spymaster of Trest","")); - cubeCards.add(new CardIdentity("Falkenrath Aristocrat","")); - cubeCards.add(new CardIdentity("Figure of Destiny","")); - cubeCards.add(new CardIdentity("Geist of Saint Traft","")); - cubeCards.add(new CardIdentity("Xenagos, the Reveler","")); - cubeCards.add(new CardIdentity("Huntmaster of the Fells","")); - cubeCards.add(new CardIdentity("Kitchen Finks","")); - cubeCards.add(new CardIdentity("Mystic Snake","")); - cubeCards.add(new CardIdentity("Nightveil Specter","")); - cubeCards.add(new CardIdentity("Steam Augury","")); - cubeCards.add(new CardIdentity("Obzedat, Ghost Council","")); - cubeCards.add(new CardIdentity("Progenitus","")); - cubeCards.add(new CardIdentity("Putrid Leech","")); - cubeCards.add(new CardIdentity("Qasali Pridemage","")); - cubeCards.add(new CardIdentity("Rakdos Cackler","")); - cubeCards.add(new CardIdentity("Shadowmage Infiltrator","")); - cubeCards.add(new CardIdentity("Simic Sky Swallower","")); - cubeCards.add(new CardIdentity("Blood Baron of Vizkopa","")); - cubeCards.add(new CardIdentity("Kiora, the Crashing Wave","")); - cubeCards.add(new CardIdentity("Voice of Resurgence","")); - cubeCards.add(new CardIdentity("Woolly Thoctar","")); - cubeCards.add(new CardIdentity("Deadbridge Chant","")); - cubeCards.add(new CardIdentity("Detention Sphere","")); - cubeCards.add(new CardIdentity("Mirari's Wake","")); - cubeCards.add(new CardIdentity("Pernicious Deed","")); - cubeCards.add(new CardIdentity("Daxos of Meletis","")); - cubeCards.add(new CardIdentity("Aurelia's Fury","")); - cubeCards.add(new CardIdentity("Bant Charm","")); - cubeCards.add(new CardIdentity("Wear // Tear","")); - cubeCards.add(new CardIdentity("Dimir Charm","")); - cubeCards.add(new CardIdentity("Electrolyze","")); - cubeCards.add(new CardIdentity("Esper Charm","")); - cubeCards.add(new CardIdentity("Izzet Charm","")); - cubeCards.add(new CardIdentity("Lightning Helix","")); - cubeCards.add(new CardIdentity("Prophetic Bolt","")); - cubeCards.add(new CardIdentity("Putrefy","")); - cubeCards.add(new CardIdentity("Sphinx's Revelation","")); - cubeCards.add(new CardIdentity("Terminate","")); - cubeCards.add(new CardIdentity("Undermine","")); - cubeCards.add(new CardIdentity("Domri Rade","")); - cubeCards.add(new CardIdentity("Ajani Vengeant","")); - cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker","")); - cubeCards.add(new CardIdentity("Ral Zarek","")); - cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad","")); - cubeCards.add(new CardIdentity("Blightning","")); - cubeCards.add(new CardIdentity("Dreadbore","")); - cubeCards.add(new CardIdentity("Firespout","")); - cubeCards.add(new CardIdentity("Maelstrom Pulse","")); - cubeCards.add(new CardIdentity("Merciless Eviction","")); - cubeCards.add(new CardIdentity("Supreme Verdict","")); - cubeCards.add(new CardIdentity("Vindicate","")); - cubeCards.add(new CardIdentity("Skullclamp","")); - cubeCards.add(new CardIdentity("Bonesplitter","")); - cubeCards.add(new CardIdentity("Umezawa's Jitte","")); - cubeCards.add(new CardIdentity("Manriki-Gusari","")); - cubeCards.add(new CardIdentity("Sword of Body and Mind","")); - cubeCards.add(new CardIdentity("Sword of Fire and Ice","")); - cubeCards.add(new CardIdentity("Sword of War and Peace","")); - cubeCards.add(new CardIdentity("Batterskull","")); - cubeCards.add(new CardIdentity("Lotus Bloom","")); - cubeCards.add(new CardIdentity("Lion's Eye Diamond","")); - cubeCards.add(new CardIdentity("Chrome Mox","")); - cubeCards.add(new CardIdentity("Mox Diamond","")); - cubeCards.add(new CardIdentity("Mind Stone","")); - cubeCards.add(new CardIdentity("Sphere of the Suns","")); - cubeCards.add(new CardIdentity("Everflowing Chalice","")); - cubeCards.add(new CardIdentity("Grim Monolith","")); - cubeCards.add(new CardIdentity("Pristine Talisman","")); - cubeCards.add(new CardIdentity("Coalition Relic","")); - cubeCards.add(new CardIdentity("Worn Powerstone","")); - cubeCards.add(new CardIdentity("Basalt Monolith","")); - cubeCards.add(new CardIdentity("Thran Dynamo","")); - cubeCards.add(new CardIdentity("Gilded Lotus","")); - cubeCards.add(new CardIdentity("Spellskite","")); - cubeCards.add(new CardIdentity("Epochrasite","")); - cubeCards.add(new CardIdentity("Phyrexian Revoker","")); - cubeCards.add(new CardIdentity("Palladium Myr","")); - cubeCards.add(new CardIdentity("Lodestone Golem","")); - cubeCards.add(new CardIdentity("Etched Oracle","")); - cubeCards.add(new CardIdentity("Molten-Tail Masticore","")); - cubeCards.add(new CardIdentity("Solemn Simulacrum","")); - cubeCards.add(new CardIdentity("Precursor Golem","")); - cubeCards.add(new CardIdentity("Wurmcoil Engine","")); - cubeCards.add(new CardIdentity("Myr Battlesphere","")); - cubeCards.add(new CardIdentity("Sundering Titan","")); - cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth","")); - cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre","")); - cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn","")); - cubeCards.add(new CardIdentity("AEther Vial","")); - cubeCards.add(new CardIdentity("Elixir of Immortality","")); - cubeCards.add(new CardIdentity("Pithing Needle","")); - cubeCards.add(new CardIdentity("Relic of Progenitus","")); - cubeCards.add(new CardIdentity("Cursed Scroll","")); - cubeCards.add(new CardIdentity("Sensei's Divining Top","")); - cubeCards.add(new CardIdentity("Scroll Rack","")); - cubeCards.add(new CardIdentity("Pentad Prism","")); - cubeCards.add(new CardIdentity("Winter Orb","")); - cubeCards.add(new CardIdentity("Shrine of Burning Rage","")); - cubeCards.add(new CardIdentity("Ratchet Bomb","")); - cubeCards.add(new CardIdentity("Oblivion Stone","")); - cubeCards.add(new CardIdentity("Crucible of Worlds","")); - cubeCards.add(new CardIdentity("Vedalken Shackles","")); - cubeCards.add(new CardIdentity("Tangle Wire","")); - cubeCards.add(new CardIdentity("Smokestack","")); - cubeCards.add(new CardIdentity("Nevinyrral's Disk","")); - cubeCards.add(new CardIdentity("Memory Jar","")); - cubeCards.add(new CardIdentity("Karn Liberated","")); - cubeCards.add(new CardIdentity("All Is Dust","")); - cubeCards.add(new CardIdentity("Engineered Explosives","")); - - } -} +/* +* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. +* +* Redistribution and use in source and binary forms, with or without modification, are +* permitted provided that the following conditions are met: +* +* 1. Redistributions of source code must retain the above copyright notice, this list of +* conditions and the following disclaimer. +* +* 2. Redistributions in binary form must reproduce the above copyright notice, this list +* of conditions and the following disclaimer in the documentation and/or other materials +* provided with the distribution. +* +* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED +* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR +* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +* +* The views and conclusions contained in the software and documentation are those of the +* authors and should not be interpreted as representing official policies, either expressed +* or implied, of BetaSteward_at_googlemail.com. +*/ +package mage.tournament.cubes; + +import mage.game.draft.DraftCube; + +/** + * + * @author LevelX2 + */ +public class MTGOMarchCube2014 extends DraftCube { + + public MTGOMarchCube2014() { + super("MTGO Cube March 2014"); + + cubeCards.add(new CardIdentity("Academy Rector","")); + cubeCards.add(new CardIdentity("Academy Ruins","")); + cubeCards.add(new CardIdentity("Acidic Slime","")); + cubeCards.add(new CardIdentity("Adarkar Wastes","")); + cubeCards.add(new CardIdentity("AEther Vial","")); + cubeCards.add(new CardIdentity("AEtherling","")); + cubeCards.add(new CardIdentity("Ajani Goldmane","")); + cubeCards.add(new CardIdentity("Ajani Vengeant","")); + cubeCards.add(new CardIdentity("Ajani, Caller of the Pride","")); + cubeCards.add(new CardIdentity("Akroma, Angel of Wrath","")); + cubeCards.add(new CardIdentity("Akroma's Vengeance","")); + cubeCards.add(new CardIdentity("All Is Dust","")); + cubeCards.add(new CardIdentity("Ancestral Vision","")); + cubeCards.add(new CardIdentity("Ancient Grudge","")); + cubeCards.add(new CardIdentity("Ancient Tomb","")); + cubeCards.add(new CardIdentity("Angel of Serenity","")); + cubeCards.add(new CardIdentity("Animate Dead","")); + cubeCards.add(new CardIdentity("Arbor Elf","")); + cubeCards.add(new CardIdentity("Arc Trail","")); + cubeCards.add(new CardIdentity("Arcane Sanctum","")); + cubeCards.add(new CardIdentity("Archangel of Thune","")); + cubeCards.add(new CardIdentity("Arid Mesa","")); + cubeCards.add(new CardIdentity("Armageddon","")); + cubeCards.add(new CardIdentity("Ash Zealot","")); + cubeCards.add(new CardIdentity("Attrition","")); + cubeCards.add(new CardIdentity("Augur of Bolas","")); + cubeCards.add(new CardIdentity("Aurelia's Fury","")); + cubeCards.add(new CardIdentity("Avacyn's Pilgrim","")); + cubeCards.add(new CardIdentity("Avalanche Riders","")); + cubeCards.add(new CardIdentity("Aven Mindcensor","")); + cubeCards.add(new CardIdentity("Avenger of Zendikar","")); + cubeCards.add(new CardIdentity("Awakening Zone","")); + cubeCards.add(new CardIdentity("Azorius Chancery","")); + cubeCards.add(new CardIdentity("Bad River","")); + cubeCards.add(new CardIdentity("Badlands","")); + cubeCards.add(new CardIdentity("Balance","")); + cubeCards.add(new CardIdentity("Baleful Strix","")); + cubeCards.add(new CardIdentity("Ball Lightning","")); + cubeCards.add(new CardIdentity("Bane of the Living","")); + cubeCards.add(new CardIdentity("Baneslayer Angel","")); + cubeCards.add(new CardIdentity("Banisher Priest","")); + cubeCards.add(new CardIdentity("Bant Charm","")); + cubeCards.add(new CardIdentity("Barbarian Ring","")); + cubeCards.add(new CardIdentity("Basalt Monolith","")); + cubeCards.add(new CardIdentity("Batterskull","")); + cubeCards.add(new CardIdentity("Battlefield Forge","")); + cubeCards.add(new CardIdentity("Bayou","")); + cubeCards.add(new CardIdentity("Beast Within","")); + cubeCards.add(new CardIdentity("Birds of Paradise","")); + cubeCards.add(new CardIdentity("Birthing Pod","")); + cubeCards.add(new CardIdentity("Bitterblossom","")); + cubeCards.add(new CardIdentity("Black Sun's Zenith","")); + cubeCards.add(new CardIdentity("Blade Splicer","")); + cubeCards.add(new CardIdentity("Blastoderm","")); + cubeCards.add(new CardIdentity("Blightning","")); + cubeCards.add(new CardIdentity("Blistering Firecat","")); + cubeCards.add(new CardIdentity("Blood Baron of Vizkopa","")); + cubeCards.add(new CardIdentity("Blood Crypt","")); + cubeCards.add(new CardIdentity("Bloodbraid Elf","")); + cubeCards.add(new CardIdentity("Bloodghast","")); + cubeCards.add(new CardIdentity("Bloodgift Demon","")); + cubeCards.add(new CardIdentity("Bloodline Keeper","")); + cubeCards.add(new CardIdentity("Bloodstained Mire","")); + cubeCards.add(new CardIdentity("Blue Elemental Blast","")); + cubeCards.add(new CardIdentity("Bogardan Hellkite","")); + cubeCards.add(new CardIdentity("Bone Shredder","")); + cubeCards.add(new CardIdentity("Bonesplitter","")); + cubeCards.add(new CardIdentity("Bonfire of the Damned","")); + cubeCards.add(new CardIdentity("Boon Satyr","")); + cubeCards.add(new CardIdentity("Borderland Ranger","")); + cubeCards.add(new CardIdentity("Boreal Druid","")); + cubeCards.add(new CardIdentity("Boros Garrison","")); + cubeCards.add(new CardIdentity("Braids, Cabal Minion","")); + cubeCards.add(new CardIdentity("Brain Freeze","")); + cubeCards.add(new CardIdentity("Brainstorm","")); + cubeCards.add(new CardIdentity("Breeding Pool","")); + cubeCards.add(new CardIdentity("Brimaz, King of Oreskos","")); + cubeCards.add(new CardIdentity("Brimstone Volley","")); + cubeCards.add(new CardIdentity("Brooding Saurian","")); + cubeCards.add(new CardIdentity("Broodmate Dragon","")); + cubeCards.add(new CardIdentity("Brushland","")); + cubeCards.add(new CardIdentity("Buried Alive","")); + cubeCards.add(new CardIdentity("Burning of Xinye","")); + cubeCards.add(new CardIdentity("Burst Lightning","")); + cubeCards.add(new CardIdentity("Calciderm","")); + cubeCards.add(new CardIdentity("Call of the Herd","")); + cubeCards.add(new CardIdentity("Capsize","")); + cubeCards.add(new CardIdentity("Carnophage","")); + cubeCards.add(new CardIdentity("Cascade Bluffs","")); + cubeCards.add(new CardIdentity("Catastrophe","")); + cubeCards.add(new CardIdentity("Caves of Koilos","")); + cubeCards.add(new CardIdentity("Celestial Colonnade","")); + cubeCards.add(new CardIdentity("Celestial Flare","")); + cubeCards.add(new CardIdentity("Celestial Purge","")); + cubeCards.add(new CardIdentity("Chain Lightning","")); + cubeCards.add(new CardIdentity("Chainer's Edict","")); + cubeCards.add(new CardIdentity("Chandra, Pyromaster","")); + cubeCards.add(new CardIdentity("Chandra, the Firebrand","")); + cubeCards.add(new CardIdentity("Chandra's Phoenix","")); + cubeCards.add(new CardIdentity("Channel","")); + cubeCards.add(new CardIdentity("Chaos Warp","")); + cubeCards.add(new CardIdentity("Char","")); + cubeCards.add(new CardIdentity("Chord of Calling","")); + cubeCards.add(new CardIdentity("Chrome Mox","")); + cubeCards.add(new CardIdentity("City of Brass","")); + cubeCards.add(new CardIdentity("Clifftop Retreat","")); + cubeCards.add(new CardIdentity("Cloudgoat Ranger","")); + cubeCards.add(new CardIdentity("Coalition Relic","")); + cubeCards.add(new CardIdentity("Compulsive Research","")); + cubeCards.add(new CardIdentity("Condemn","")); + cubeCards.add(new CardIdentity("Condescend","")); + cubeCards.add(new CardIdentity("Consecrated Sphinx","")); + cubeCards.add(new CardIdentity("Control Magic","")); + cubeCards.add(new CardIdentity("Coralhelm Commander","")); + cubeCards.add(new CardIdentity("Corrupt","")); + cubeCards.add(new CardIdentity("Counterspell","")); + cubeCards.add(new CardIdentity("Countryside Crusher","")); + cubeCards.add(new CardIdentity("Courser of Kruphix","")); + cubeCards.add(new CardIdentity("Court Hussar","")); + cubeCards.add(new CardIdentity("Creeping Tar Pit","")); + cubeCards.add(new CardIdentity("Crucible of Worlds","")); + cubeCards.add(new CardIdentity("Crumbling Necropolis","")); + cubeCards.add(new CardIdentity("Cryptic Command","")); + cubeCards.add(new CardIdentity("Cultivate","")); + cubeCards.add(new CardIdentity("Cunning Sparkmage","")); + cubeCards.add(new CardIdentity("Cursecatcher","")); + cubeCards.add(new CardIdentity("Cursed Scroll","")); + cubeCards.add(new CardIdentity("Damnation","")); + cubeCards.add(new CardIdentity("Dark Confidant","")); + cubeCards.add(new CardIdentity("Dark Ritual","")); + cubeCards.add(new CardIdentity("Daxos of Meletis","")); + cubeCards.add(new CardIdentity("Day of Judgment","")); + cubeCards.add(new CardIdentity("Daze","")); + cubeCards.add(new CardIdentity("Deadbridge Chant","")); + cubeCards.add(new CardIdentity("Death Cloud","")); + cubeCards.add(new CardIdentity("Decree of Justice","")); + cubeCards.add(new CardIdentity("Deep Analysis","")); + cubeCards.add(new CardIdentity("Delver of Secrets","")); + cubeCards.add(new CardIdentity("Demonic Tutor","")); + cubeCards.add(new CardIdentity("Deranged Hermit","")); + cubeCards.add(new CardIdentity("Descendant of Kiyomaro","")); + cubeCards.add(new CardIdentity("Desperate Ravings","")); + cubeCards.add(new CardIdentity("Detention Sphere","")); + cubeCards.add(new CardIdentity("Devil's Play","")); + cubeCards.add(new CardIdentity("Diabolic Servitude","")); + cubeCards.add(new CardIdentity("Dimir Aqueduct","")); + cubeCards.add(new CardIdentity("Dimir Charm","")); + cubeCards.add(new CardIdentity("Diregraf Ghoul","")); + cubeCards.add(new CardIdentity("Disenchant","")); + cubeCards.add(new CardIdentity("Disfigure","")); + cubeCards.add(new CardIdentity("Dismantling Blow","")); + cubeCards.add(new CardIdentity("Dismember","")); + cubeCards.add(new CardIdentity("Dismiss","")); + cubeCards.add(new CardIdentity("Dissipate","")); + cubeCards.add(new CardIdentity("Domri Rade","")); + cubeCards.add(new CardIdentity("Doom Blade","")); + cubeCards.add(new CardIdentity("Dragonskull Summit","")); + cubeCards.add(new CardIdentity("Dreadbore","")); + cubeCards.add(new CardIdentity("Drowned Catacomb","")); + cubeCards.add(new CardIdentity("Dryad Sophisticate","")); + cubeCards.add(new CardIdentity("Dungeon Geists","")); + cubeCards.add(new CardIdentity("Duress","")); + cubeCards.add(new CardIdentity("Earthquake","")); + cubeCards.add(new CardIdentity("Edric, Spymaster of Trest","")); + cubeCards.add(new CardIdentity("Eight-and-a-Half-Tails","")); + cubeCards.add(new CardIdentity("Electrolyze","")); + cubeCards.add(new CardIdentity("Elesh Norn, Grand Cenobite","")); + cubeCards.add(new CardIdentity("Elite Vanguard","")); + cubeCards.add(new CardIdentity("Elixir of Immortality","")); + cubeCards.add(new CardIdentity("Elspeth Tirel","")); + cubeCards.add(new CardIdentity("Elspeth, Knight-Errant","")); + cubeCards.add(new CardIdentity("Elspeth, Sun's Champion","")); + cubeCards.add(new CardIdentity("Elves of Deep Shadow","")); + cubeCards.add(new CardIdentity("Elvish Mystic","")); + cubeCards.add(new CardIdentity("Ember Hauler","")); + cubeCards.add(new CardIdentity("Emeria Angel","")); + cubeCards.add(new CardIdentity("Empty the Warrens","")); + cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn","")); + cubeCards.add(new CardIdentity("Enclave Cryptologist","")); + cubeCards.add(new CardIdentity("Engineered Explosives","")); + cubeCards.add(new CardIdentity("Enlightened Tutor","")); + cubeCards.add(new CardIdentity("Entomb","")); + cubeCards.add(new CardIdentity("Entreat the Angels","")); + cubeCards.add(new CardIdentity("Epochrasite","")); + cubeCards.add(new CardIdentity("Erebos, God of the Dead","")); + cubeCards.add(new CardIdentity("Esper Charm","")); + cubeCards.add(new CardIdentity("Essence Scatter","")); + cubeCards.add(new CardIdentity("Etched Oracle","")); + cubeCards.add(new CardIdentity("Eternal Witness","")); + cubeCards.add(new CardIdentity("Eureka","")); + cubeCards.add(new CardIdentity("Everflowing Chalice","")); + cubeCards.add(new CardIdentity("Exalted Angel","")); + cubeCards.add(new CardIdentity("Exhume","")); + cubeCards.add(new CardIdentity("Experiment One","")); + cubeCards.add(new CardIdentity("Exploration","")); + cubeCards.add(new CardIdentity("Explore","")); + cubeCards.add(new CardIdentity("Fact or Fiction","")); + cubeCards.add(new CardIdentity("Faerie Conclave","")); + cubeCards.add(new CardIdentity("Faithless Looting","")); + cubeCards.add(new CardIdentity("Faith's Fetters","")); + cubeCards.add(new CardIdentity("Falkenrath Aristocrat","")); + cubeCards.add(new CardIdentity("Farseek","")); + cubeCards.add(new CardIdentity("Fathom Seer","")); + cubeCards.add(new CardIdentity("Fauna Shaman","")); + cubeCards.add(new CardIdentity("Fertile Ground","")); + cubeCards.add(new CardIdentity("Fetid Heath","")); + cubeCards.add(new CardIdentity("Figure of Destiny","")); + cubeCards.add(new CardIdentity("Fireblast","")); + cubeCards.add(new CardIdentity("Firebolt","")); + cubeCards.add(new CardIdentity("Firedrinker Satyr","")); + cubeCards.add(new CardIdentity("Fire-Lit Thicket","")); + cubeCards.add(new CardIdentity("Firespout","")); + cubeCards.add(new CardIdentity("Firestorm","")); + cubeCards.add(new CardIdentity("Flagstones of Trokair","")); + cubeCards.add(new CardIdentity("Flame Javelin","")); + cubeCards.add(new CardIdentity("Flametongue Kavu","")); + cubeCards.add(new CardIdentity("Flashfreeze","")); + cubeCards.add(new CardIdentity("Fleecemane Lion","")); + cubeCards.add(new CardIdentity("Flickerwisp","")); + cubeCards.add(new CardIdentity("Flinthoof Boar","")); + cubeCards.add(new CardIdentity("Flood Plain","")); + cubeCards.add(new CardIdentity("Flooded Grove","")); + cubeCards.add(new CardIdentity("Flooded Strand","")); + cubeCards.add(new CardIdentity("Forbid","")); + cubeCards.add(new CardIdentity("Force of Will","")); + cubeCards.add(new CardIdentity("Force Spike","")); + cubeCards.add(new CardIdentity("Forked Bolt","")); + cubeCards.add(new CardIdentity("Frantic Search","")); + cubeCards.add(new CardIdentity("Frenzied Goblin","")); + cubeCards.add(new CardIdentity("Frost Titan","")); + cubeCards.add(new CardIdentity("Future Sight","")); + cubeCards.add(new CardIdentity("Fyndhorn Elves","")); + cubeCards.add(new CardIdentity("Gaea's Cradle","")); + cubeCards.add(new CardIdentity("Gamble","")); + cubeCards.add(new CardIdentity("Garruk Relentless","")); + cubeCards.add(new CardIdentity("Garruk Wildspeaker","")); + cubeCards.add(new CardIdentity("Garruk, Primal Hunter","")); + cubeCards.add(new CardIdentity("Gatekeeper of Malakir","")); + cubeCards.add(new CardIdentity("Gathan Raiders","")); + cubeCards.add(new CardIdentity("Geist of Saint Traft","")); + cubeCards.add(new CardIdentity("Genesis Wave","")); + cubeCards.add(new CardIdentity("Genesis","")); + cubeCards.add(new CardIdentity("Genju of the Spires","")); + cubeCards.add(new CardIdentity("Geralf's Messenger","")); + cubeCards.add(new CardIdentity("Ghitu Encampment","")); + cubeCards.add(new CardIdentity("Gideon Jura","")); + cubeCards.add(new CardIdentity("Gideon, Champion of Justice","")); + cubeCards.add(new CardIdentity("Gifts Ungiven","")); + cubeCards.add(new CardIdentity("Gilded Lotus","")); + cubeCards.add(new CardIdentity("Glacial Fortress","")); + cubeCards.add(new CardIdentity("Glen Elendra Archmage","")); + cubeCards.add(new CardIdentity("Go for the Throat","")); + cubeCards.add(new CardIdentity("Goblin Cadets","")); + cubeCards.add(new CardIdentity("Goblin Guide","")); + cubeCards.add(new CardIdentity("Goblin Ruinblaster","")); + cubeCards.add(new CardIdentity("Goblin Welder","")); + cubeCards.add(new CardIdentity("Godless Shrine","")); + cubeCards.add(new CardIdentity("Golgari Rot Farm","")); + cubeCards.add(new CardIdentity("Gore-House Chainwalker","")); + cubeCards.add(new CardIdentity("Grasslands","")); + cubeCards.add(new CardIdentity("Grave Titan","")); + cubeCards.add(new CardIdentity("Graveborn Muse","")); + cubeCards.add(new CardIdentity("Gravecrawler","")); + cubeCards.add(new CardIdentity("Graven Cairns","")); + cubeCards.add(new CardIdentity("Great Sable Stag","")); + cubeCards.add(new CardIdentity("Greater Gargadon","")); + cubeCards.add(new CardIdentity("Green Sun's Zenith","")); + cubeCards.add(new CardIdentity("Grim Lavamancer","")); + cubeCards.add(new CardIdentity("Grim Monolith","")); + cubeCards.add(new CardIdentity("Griselbrand","")); + cubeCards.add(new CardIdentity("Gruul Turf","")); + cubeCards.add(new CardIdentity("Guul Draz Assassin","")); + cubeCards.add(new CardIdentity("Halimar Depths","")); + cubeCards.add(new CardIdentity("Hallowed Burial","")); + cubeCards.add(new CardIdentity("Hallowed Fountain","")); + cubeCards.add(new CardIdentity("Hand of Cruelty","")); + cubeCards.add(new CardIdentity("Hand of Honor","")); + cubeCards.add(new CardIdentity("Harmonize","")); + cubeCards.add(new CardIdentity("Headhunter","")); + cubeCards.add(new CardIdentity("Heartbeat of Spring","")); + cubeCards.add(new CardIdentity("Heliod, God of the Sun","")); + cubeCards.add(new CardIdentity("Hellrider","")); + cubeCards.add(new CardIdentity("Hell's Thunder","")); + cubeCards.add(new CardIdentity("Hellspark Elemental","")); + cubeCards.add(new CardIdentity("Herald of Torment","")); + cubeCards.add(new CardIdentity("Hero of Bladehold","")); + cubeCards.add(new CardIdentity("Hero of Oxid Ridge","")); + cubeCards.add(new CardIdentity("Hero's Downfall","")); + cubeCards.add(new CardIdentity("Hinder","")); + cubeCards.add(new CardIdentity("Hinterland Harbor","")); + cubeCards.add(new CardIdentity("Hokori, Dust Drinker","")); + cubeCards.add(new CardIdentity("Honor of the Pure","")); + cubeCards.add(new CardIdentity("Huntmaster of the Fells","")); + cubeCards.add(new CardIdentity("Hymn to Tourach","")); + cubeCards.add(new CardIdentity("Hypnotic Specter","")); + cubeCards.add(new CardIdentity("Hystrodon","")); + cubeCards.add(new CardIdentity("Imposing Sovereign","")); + cubeCards.add(new CardIdentity("Impulse","")); + cubeCards.add(new CardIdentity("Indrik Stomphowler","")); + cubeCards.add(new CardIdentity("Inferno Titan","")); + cubeCards.add(new CardIdentity("Ink-Eyes, Servant of Oni","")); + cubeCards.add(new CardIdentity("Inquisition of Kozilek","")); + cubeCards.add(new CardIdentity("Into the Roil","")); + cubeCards.add(new CardIdentity("Iona, Shield of Emeria","")); + cubeCards.add(new CardIdentity("Isamaru, Hound of Konda","")); + cubeCards.add(new CardIdentity("Isolated Chapel","")); + cubeCards.add(new CardIdentity("Izzet Boilerworks","")); + cubeCards.add(new CardIdentity("Izzet Charm","")); + cubeCards.add(new CardIdentity("Jace Beleren","")); + cubeCards.add(new CardIdentity("Jace, Architect of Thought","")); + cubeCards.add(new CardIdentity("Jace, the Mind Sculptor","")); + cubeCards.add(new CardIdentity("Jackal Pup","")); + cubeCards.add(new CardIdentity("Joraga Treespeaker","")); + cubeCards.add(new CardIdentity("Jotun Grunt","")); + cubeCards.add(new CardIdentity("Journey to Nowhere","")); + cubeCards.add(new CardIdentity("Jungle Shrine","")); + cubeCards.add(new CardIdentity("Jushi Apprentice","")); + cubeCards.add(new CardIdentity("Kami of Ancient Law","")); + cubeCards.add(new CardIdentity("Karakas","")); + cubeCards.add(new CardIdentity("Kargan Dragonlord","")); + cubeCards.add(new CardIdentity("Karn Liberated","")); + cubeCards.add(new CardIdentity("Karplusan Forest","")); + cubeCards.add(new CardIdentity("Keiga, the Tide Star","")); + cubeCards.add(new CardIdentity("Keldon Champion","")); + cubeCards.add(new CardIdentity("Keldon Marauders","")); + cubeCards.add(new CardIdentity("Kiora, the Crashing Wave","")); + cubeCards.add(new CardIdentity("Kira, Great Glass-Spinner","")); + cubeCards.add(new CardIdentity("Kird Ape","")); + cubeCards.add(new CardIdentity("Kitchen Finks","")); + cubeCards.add(new CardIdentity("Knight of Glory","")); + cubeCards.add(new CardIdentity("Knight of Infamy","")); + cubeCards.add(new CardIdentity("Kokusho, the Evening Star","")); + cubeCards.add(new CardIdentity("Koth of the Hammer","")); + cubeCards.add(new CardIdentity("Kozilek, Butcher of Truth","")); + cubeCards.add(new CardIdentity("Krosan Grip","")); + cubeCards.add(new CardIdentity("Lake of the Dead","")); + cubeCards.add(new CardIdentity("Land Tax","")); + cubeCards.add(new CardIdentity("Lavaclaw Reaches","")); + cubeCards.add(new CardIdentity("Legacy's Allure","")); + cubeCards.add(new CardIdentity("Leonin Relic-Warder","")); + cubeCards.add(new CardIdentity("Life from the Loam","")); + cubeCards.add(new CardIdentity("Lifebane Zombie","")); + cubeCards.add(new CardIdentity("Lightning Bolt","")); + cubeCards.add(new CardIdentity("Lightning Helix","")); + cubeCards.add(new CardIdentity("Lightning Mauler","")); + cubeCards.add(new CardIdentity("Liliana of the Veil","")); + cubeCards.add(new CardIdentity("Liliana Vess","")); + cubeCards.add(new CardIdentity("Liliana's Reaver","")); + cubeCards.add(new CardIdentity("Lingering Souls","")); + cubeCards.add(new CardIdentity("Linvala, Keeper of Silence","")); + cubeCards.add(new CardIdentity("Lion's Eye Diamond","")); + cubeCards.add(new CardIdentity("Living Death","")); + cubeCards.add(new CardIdentity("Llanowar Elves","")); + cubeCards.add(new CardIdentity("Llanowar Wastes","")); + cubeCards.add(new CardIdentity("Loam Lion","")); + cubeCards.add(new CardIdentity("Lodestone Golem","")); + cubeCards.add(new CardIdentity("Looter il-Kor","")); + cubeCards.add(new CardIdentity("Lotus Bloom","")); + cubeCards.add(new CardIdentity("Lotus Cobra","")); + cubeCards.add(new CardIdentity("Maelstrom Pulse","")); + cubeCards.add(new CardIdentity("Magma Jet","")); + cubeCards.add(new CardIdentity("Magus of the Moon","")); + cubeCards.add(new CardIdentity("Makeshift Mannequin","")); + cubeCards.add(new CardIdentity("Mana Leak","")); + cubeCards.add(new CardIdentity("Mana Tithe","")); + cubeCards.add(new CardIdentity("Man-o'-War","")); + cubeCards.add(new CardIdentity("Manriki-Gusari","")); + cubeCards.add(new CardIdentity("Mark of Mutiny","")); + cubeCards.add(new CardIdentity("Marsh Flats","")); + cubeCards.add(new CardIdentity("Martial Coup","")); + cubeCards.add(new CardIdentity("Master of the Wild Hunt","")); + cubeCards.add(new CardIdentity("Master of Waves","")); + cubeCards.add(new CardIdentity("Maze of Ith","")); + cubeCards.add(new CardIdentity("Meloku the Clouded Mirror","")); + cubeCards.add(new CardIdentity("Memory Jar","")); + cubeCards.add(new CardIdentity("Mentor of the Meek","")); + cubeCards.add(new CardIdentity("Merciless Eviction","")); + cubeCards.add(new CardIdentity("Mesmeric Fiend","")); + cubeCards.add(new CardIdentity("Mind Stone","")); + cubeCards.add(new CardIdentity("Mind's Desire","")); + cubeCards.add(new CardIdentity("Mirari's Wake","")); + cubeCards.add(new CardIdentity("Mirran Crusader","")); + cubeCards.add(new CardIdentity("Mirror Entity","")); + cubeCards.add(new CardIdentity("Miscalculation","")); + cubeCards.add(new CardIdentity("Misdirection","")); + cubeCards.add(new CardIdentity("Mishra's Factory","")); + cubeCards.add(new CardIdentity("Misty Rainforest","")); + cubeCards.add(new CardIdentity("Mizzium Mortars","")); + cubeCards.add(new CardIdentity("Mogg War Marshal","")); + cubeCards.add(new CardIdentity("Mold Shambler","")); + cubeCards.add(new CardIdentity("Molten Rain","")); + cubeCards.add(new CardIdentity("Molten-Tail Masticore","")); + cubeCards.add(new CardIdentity("Momentary Blink","")); + cubeCards.add(new CardIdentity("Moment's Peace","")); + cubeCards.add(new CardIdentity("Mother of Runes","")); + cubeCards.add(new CardIdentity("Mountain Valley","")); + cubeCards.add(new CardIdentity("Mox Diamond","")); + cubeCards.add(new CardIdentity("Mulldrifter","")); + cubeCards.add(new CardIdentity("Murmuring Bosk","")); + cubeCards.add(new CardIdentity("Mutavault","")); + cubeCards.add(new CardIdentity("Myr Battlesphere","")); + cubeCards.add(new CardIdentity("Mystic Gate","")); + cubeCards.add(new CardIdentity("Mystic Snake","")); + cubeCards.add(new CardIdentity("Mystical Tutor","")); + cubeCards.add(new CardIdentity("Nantuko Shade","")); + cubeCards.add(new CardIdentity("Nantuko Vigilante","")); + cubeCards.add(new CardIdentity("Narcolepsy","")); + cubeCards.add(new CardIdentity("Natural Order","")); + cubeCards.add(new CardIdentity("Naturalize","")); + cubeCards.add(new CardIdentity("Nature's Claim","")); + cubeCards.add(new CardIdentity("Nature's Lore","")); + cubeCards.add(new CardIdentity("Nearheath Pilgrim","")); + cubeCards.add(new CardIdentity("Necromancy","")); + cubeCards.add(new CardIdentity("Necropotence","")); + cubeCards.add(new CardIdentity("Negate","")); + cubeCards.add(new CardIdentity("Nekrataal","")); + cubeCards.add(new CardIdentity("Nevinyrral's Disk","")); + cubeCards.add(new CardIdentity("Nezumi Graverobber","")); + cubeCards.add(new CardIdentity("Nezumi Shortfang","")); + cubeCards.add(new CardIdentity("Nicol Bolas, Planeswalker","")); + cubeCards.add(new CardIdentity("Night's Whisper","")); + cubeCards.add(new CardIdentity("Nightscape Familiar","")); + cubeCards.add(new CardIdentity("Nightveil Specter","")); + cubeCards.add(new CardIdentity("Noble Hierarch","")); + cubeCards.add(new CardIdentity("Nostalgic Dreams","")); + cubeCards.add(new CardIdentity("Oblivion Ring","")); + cubeCards.add(new CardIdentity("Oblivion Stone","")); + cubeCards.add(new CardIdentity("Obstinate Baloth","")); + cubeCards.add(new CardIdentity("Obzedat, Ghost Council","")); + cubeCards.add(new CardIdentity("Ogre Battledriver","")); + cubeCards.add(new CardIdentity("Ohran Viper","")); + cubeCards.add(new CardIdentity("Old Man of the Sea","")); + cubeCards.add(new CardIdentity("Oona's Prowler","")); + cubeCards.add(new CardIdentity("Opposition","")); + cubeCards.add(new CardIdentity("Oracle of Mul Daya","")); + cubeCards.add(new CardIdentity("Orcish Lumberjack","")); + cubeCards.add(new CardIdentity("Orzhov Basilica","")); + cubeCards.add(new CardIdentity("Oust","")); + cubeCards.add(new CardIdentity("Overgrown Tomb","")); + cubeCards.add(new CardIdentity("Pact of Negation","")); + cubeCards.add(new CardIdentity("Pain Seer","")); + cubeCards.add(new CardIdentity("Palinchron","")); + cubeCards.add(new CardIdentity("Palladium Myr","")); + cubeCards.add(new CardIdentity("Parallax Wave","")); + cubeCards.add(new CardIdentity("Path to Exile","")); + cubeCards.add(new CardIdentity("Pattern of Rebirth","")); + cubeCards.add(new CardIdentity("Pentad Prism","")); + cubeCards.add(new CardIdentity("Pernicious Deed","")); + cubeCards.add(new CardIdentity("Persecute","")); + cubeCards.add(new CardIdentity("Phantasmal Bear","")); + cubeCards.add(new CardIdentity("Phantasmal Image","")); + cubeCards.add(new CardIdentity("Phyrexian Arena","")); + cubeCards.add(new CardIdentity("Phyrexian Metamorph","")); + cubeCards.add(new CardIdentity("Phyrexian Obliterator","")); + cubeCards.add(new CardIdentity("Phyrexian Rager","")); + cubeCards.add(new CardIdentity("Phyrexian Revoker","")); + cubeCards.add(new CardIdentity("Pillage","")); + cubeCards.add(new CardIdentity("Pithing Needle","")); + cubeCards.add(new CardIdentity("Plague Sliver","")); + cubeCards.add(new CardIdentity("Plateau","")); + cubeCards.add(new CardIdentity("Plated Geopede","")); + cubeCards.add(new CardIdentity("Plow Under","")); + cubeCards.add(new CardIdentity("Polluted Delta","")); + cubeCards.add(new CardIdentity("Polukranos, World Eater","")); + cubeCards.add(new CardIdentity("Ponder","")); + cubeCards.add(new CardIdentity("Porcelain Legionnaire","")); + cubeCards.add(new CardIdentity("Precursor Golem","")); + cubeCards.add(new CardIdentity("Preordain","")); + cubeCards.add(new CardIdentity("Price of Progress","")); + cubeCards.add(new CardIdentity("Priest of Urabrask","")); + cubeCards.add(new CardIdentity("Primal Command","")); + cubeCards.add(new CardIdentity("Primeval Titan","")); + cubeCards.add(new CardIdentity("Pristine Angel","")); + cubeCards.add(new CardIdentity("Pristine Talisman","")); + cubeCards.add(new CardIdentity("Progenitus","")); + cubeCards.add(new CardIdentity("Prophetic Bolt","")); + cubeCards.add(new CardIdentity("Purphoros, God of the Forge","")); + cubeCards.add(new CardIdentity("Putrefy","")); + cubeCards.add(new CardIdentity("Putrid Imp","")); + cubeCards.add(new CardIdentity("Putrid Leech","")); + cubeCards.add(new CardIdentity("Pyroclasm","")); + cubeCards.add(new CardIdentity("Qasali Pridemage","")); + cubeCards.add(new CardIdentity("Raging Ravine","")); + cubeCards.add(new CardIdentity("Rakdos Cackler","")); + cubeCards.add(new CardIdentity("Rakdos Carnarium","")); + cubeCards.add(new CardIdentity("Ral Zarek","")); + cubeCards.add(new CardIdentity("Rampant Growth","")); + cubeCards.add(new CardIdentity("Rancor","")); + cubeCards.add(new CardIdentity("Ranger of Eos","")); + cubeCards.add(new CardIdentity("Ratchet Bomb","")); + cubeCards.add(new CardIdentity("Ravages of War","")); + cubeCards.add(new CardIdentity("Ravenous Baboons","")); + cubeCards.add(new CardIdentity("Reanimate","")); + cubeCards.add(new CardIdentity("Reckless Charge","")); + cubeCards.add(new CardIdentity("Recurring Nightmare","")); + cubeCards.add(new CardIdentity("Red Elemental Blast","")); + cubeCards.add(new CardIdentity("Reflecting Pool","")); + cubeCards.add(new CardIdentity("Regrowth","")); + cubeCards.add(new CardIdentity("Relic of Progenitus","")); + cubeCards.add(new CardIdentity("Remand","")); + cubeCards.add(new CardIdentity("Repeal","")); + cubeCards.add(new CardIdentity("Restock","")); + cubeCards.add(new CardIdentity("Restoration Angel","")); + cubeCards.add(new CardIdentity("Reveillark","")); + cubeCards.add(new CardIdentity("Rift Bolt","")); + cubeCards.add(new CardIdentity("Riftwing Cloudskate","")); + cubeCards.add(new CardIdentity("Rishadan Port","")); + cubeCards.add(new CardIdentity("Rocky Tar Pit","")); + cubeCards.add(new CardIdentity("Rofellos, Llanowar Emissary","")); + cubeCards.add(new CardIdentity("Rolling Earthquake","")); + cubeCards.add(new CardIdentity("Rootbound Crag","")); + cubeCards.add(new CardIdentity("Rout","")); + cubeCards.add(new CardIdentity("Rude Awakening","")); + cubeCards.add(new CardIdentity("Rugged Prairie","")); + cubeCards.add(new CardIdentity("Sacred Foundry","")); + cubeCards.add(new CardIdentity("Sakashima's Student","")); + cubeCards.add(new CardIdentity("Sakura-Tribe Elder","")); + cubeCards.add(new CardIdentity("Sarcomancy","")); + cubeCards.add(new CardIdentity("Savage Lands","")); + cubeCards.add(new CardIdentity("Savannah Lions","")); + cubeCards.add(new CardIdentity("Savannah","")); + cubeCards.add(new CardIdentity("Scalding Tarn","")); + cubeCards.add(new CardIdentity("Scavenging Ooze","")); + cubeCards.add(new CardIdentity("Scroll Rack","")); + cubeCards.add(new CardIdentity("Scrubland","")); + cubeCards.add(new CardIdentity("Sea Gate Oracle","")); + cubeCards.add(new CardIdentity("Seal of Cleansing","")); + cubeCards.add(new CardIdentity("Search for Tomorrow","")); + cubeCards.add(new CardIdentity("Searing Blaze","")); + cubeCards.add(new CardIdentity("Searing Blood","")); + cubeCards.add(new CardIdentity("Seaside Citadel","")); + cubeCards.add(new CardIdentity("Seething Song","")); + cubeCards.add(new CardIdentity("Selesnya Sanctuary","")); + cubeCards.add(new CardIdentity("Sensei's Divining Top","")); + cubeCards.add(new CardIdentity("Serendib Efreet","")); + cubeCards.add(new CardIdentity("Serum Visions","")); + cubeCards.add(new CardIdentity("Shadowmage Infiltrator","")); + cubeCards.add(new CardIdentity("Shardless Agent","")); + cubeCards.add(new CardIdentity("Shivan Reef","")); + cubeCards.add(new CardIdentity("Show and Tell","")); + cubeCards.add(new CardIdentity("Shrieking Grotesque","")); + cubeCards.add(new CardIdentity("Shriekmaw","")); + cubeCards.add(new CardIdentity("Shrine of Burning Rage","")); + cubeCards.add(new CardIdentity("Siege-Gang Commander","")); + cubeCards.add(new CardIdentity("Sign in Blood","")); + cubeCards.add(new CardIdentity("Silent Specter","")); + cubeCards.add(new CardIdentity("Silver Knight","")); + cubeCards.add(new CardIdentity("Silverblade Paladin","")); + cubeCards.add(new CardIdentity("Simic Growth Chamber","")); + cubeCards.add(new CardIdentity("Simic Sky Swallower","")); + cubeCards.add(new CardIdentity("Sinkhole","")); + cubeCards.add(new CardIdentity("Skeletal Scrying","")); + cubeCards.add(new CardIdentity("Skinrender","")); + cubeCards.add(new CardIdentity("Skullclamp","")); + cubeCards.add(new CardIdentity("Skullcrack","")); + cubeCards.add(new CardIdentity("Slagstorm","")); + cubeCards.add(new CardIdentity("Slaughter Pact","")); + cubeCards.add(new CardIdentity("Smash to Smithereens","")); + cubeCards.add(new CardIdentity("Smokestack","")); + cubeCards.add(new CardIdentity("Smother","")); + cubeCards.add(new CardIdentity("Snapcaster Mage","")); + cubeCards.add(new CardIdentity("Sneak Attack","")); + cubeCards.add(new CardIdentity("Snuff Out","")); + cubeCards.add(new CardIdentity("Soldier of the Pantheon","")); + cubeCards.add(new CardIdentity("Solemn Simulacrum","")); + cubeCards.add(new CardIdentity("Sorin, Lord of Innistrad","")); + cubeCards.add(new CardIdentity("Sorin's Thirst","")); + cubeCards.add(new CardIdentity("Sower of Temptation","")); + cubeCards.add(new CardIdentity("Spear of Heliod","")); + cubeCards.add(new CardIdentity("Spectral Procession","")); + cubeCards.add(new CardIdentity("Spell Pierce","")); + cubeCards.add(new CardIdentity("Spellskite","")); + cubeCards.add(new CardIdentity("Sphere of the Suns","")); + cubeCards.add(new CardIdentity("Sphinx's Revelation","")); + cubeCards.add(new CardIdentity("Spikeshot Elder","")); + cubeCards.add(new CardIdentity("Spinning Darkness","")); + cubeCards.add(new CardIdentity("Spreading Seas","")); + cubeCards.add(new CardIdentity("Steam Augury","")); + cubeCards.add(new CardIdentity("Steam Vents","")); + cubeCards.add(new CardIdentity("Steppe Lynx","")); + cubeCards.add(new CardIdentity("Stirring Wildwood","")); + cubeCards.add(new CardIdentity("Stomping Ground","")); + cubeCards.add(new CardIdentity("Stonecloaker","")); + cubeCards.add(new CardIdentity("Stoneforge Mystic","")); + cubeCards.add(new CardIdentity("Stormblood Berserker","")); + cubeCards.add(new CardIdentity("Strangleroot Geist","")); + cubeCards.add(new CardIdentity("Strip Mine","")); + cubeCards.add(new CardIdentity("Stromkirk Noble","")); + cubeCards.add(new CardIdentity("Student of Warfare","")); + cubeCards.add(new CardIdentity("Stunted Growth","")); + cubeCards.add(new CardIdentity("Stupor","")); + cubeCards.add(new CardIdentity("Sublime Archangel","")); + cubeCards.add(new CardIdentity("Sulfur Falls","")); + cubeCards.add(new CardIdentity("Sulfuric Vortex","")); + cubeCards.add(new CardIdentity("Sulfurous Springs","")); + cubeCards.add(new CardIdentity("Sun Titan","")); + cubeCards.add(new CardIdentity("Sundering Titan","")); + cubeCards.add(new CardIdentity("Sunken Ruins","")); + cubeCards.add(new CardIdentity("Sunpetal Grove","")); + cubeCards.add(new CardIdentity("Supreme Verdict","")); + cubeCards.add(new CardIdentity("Survival of the Fittest","")); + cubeCards.add(new CardIdentity("Sword of Body and Mind","")); + cubeCards.add(new CardIdentity("Sword of Fire and Ice","")); + cubeCards.add(new CardIdentity("Sword of War and Peace","")); + cubeCards.add(new CardIdentity("Swords to Plowshares","")); + cubeCards.add(new CardIdentity("Sylvan Caryatid","")); + cubeCards.add(new CardIdentity("Sylvan Library","")); + cubeCards.add(new CardIdentity("Taiga","")); + cubeCards.add(new CardIdentity("Tainted Pact","")); + cubeCards.add(new CardIdentity("Talrand, Sky Summoner","")); + cubeCards.add(new CardIdentity("Tamiyo, the Moon Sage","")); + cubeCards.add(new CardIdentity("Tangle Wire","")); + cubeCards.add(new CardIdentity("Tarmogoyf","")); + cubeCards.add(new CardIdentity("Taurean Mauler","")); + cubeCards.add(new CardIdentity("Tectonic Edge","")); + cubeCards.add(new CardIdentity("Teetering Peaks","")); + cubeCards.add(new CardIdentity("Teferi, Mage of Zhalfir","")); + cubeCards.add(new CardIdentity("Temple Garden","")); + cubeCards.add(new CardIdentity("Tendrils of Agony","")); + cubeCards.add(new CardIdentity("Tendrils of Corruption","")); + cubeCards.add(new CardIdentity("Terastodon","")); + cubeCards.add(new CardIdentity("Terminate","")); + cubeCards.add(new CardIdentity("Terminus","")); + cubeCards.add(new CardIdentity("Thalia, Guardian of Thraben","")); + cubeCards.add(new CardIdentity("Thassa, God of the Sea","")); + cubeCards.add(new CardIdentity("Thawing Glaciers","")); + cubeCards.add(new CardIdentity("Thelonite Hermit","")); + cubeCards.add(new CardIdentity("Thieving Magpie","")); + cubeCards.add(new CardIdentity("Thirst for Knowledge","")); + cubeCards.add(new CardIdentity("Thornscape Battlemage","")); + cubeCards.add(new CardIdentity("Thoughtseize","")); + cubeCards.add(new CardIdentity("Thragtusk","")); + cubeCards.add(new CardIdentity("Thran Dynamo","")); + cubeCards.add(new CardIdentity("Thrun, the Last Troll","")); + cubeCards.add(new CardIdentity("Thunderblust","")); + cubeCards.add(new CardIdentity("Thundermaw Hellkite","")); + cubeCards.add(new CardIdentity("Thunderscape Battlemage","")); + cubeCards.add(new CardIdentity("Tidings","")); + cubeCards.add(new CardIdentity("Time Spiral","")); + cubeCards.add(new CardIdentity("Time Warp","")); + cubeCards.add(new CardIdentity("Tin Street Hooligan","")); + cubeCards.add(new CardIdentity("Tinker","")); + cubeCards.add(new CardIdentity("Tombstalker","")); + cubeCards.add(new CardIdentity("Tooth and Nail","")); + cubeCards.add(new CardIdentity("Torch Fiend","")); + cubeCards.add(new CardIdentity("Tradewind Rider","")); + cubeCards.add(new CardIdentity("Tragic Slip","")); + cubeCards.add(new CardIdentity("Treachery","")); + cubeCards.add(new CardIdentity("Treetop Village","")); + cubeCards.add(new CardIdentity("Trinket Mage","")); + cubeCards.add(new CardIdentity("Troll Ascetic","")); + cubeCards.add(new CardIdentity("Tropical Island","")); + cubeCards.add(new CardIdentity("Tundra","")); + cubeCards.add(new CardIdentity("Turnabout","")); + cubeCards.add(new CardIdentity("Twilight Mire","")); + cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre","")); + cubeCards.add(new CardIdentity("Ultimate Price","")); + cubeCards.add(new CardIdentity("Ulvenwald Tracker","")); + cubeCards.add(new CardIdentity("Umezawa's Jitte","")); + cubeCards.add(new CardIdentity("Unburial Rites","")); + cubeCards.add(new CardIdentity("Underground River","")); + cubeCards.add(new CardIdentity("Underground Sea","")); + cubeCards.add(new CardIdentity("Undermine","")); + cubeCards.add(new CardIdentity("Upheaval","")); + cubeCards.add(new CardIdentity("Urabrask the Hidden","")); + cubeCards.add(new CardIdentity("Urborg, Tomb of Yawgmoth","")); + cubeCards.add(new CardIdentity("Vampire Hexmage","")); + cubeCards.add(new CardIdentity("Vampire Lacerator","")); + cubeCards.add(new CardIdentity("Vampire Nighthawk","")); + cubeCards.add(new CardIdentity("Vampiric Tutor","")); + cubeCards.add(new CardIdentity("Vedalken Shackles","")); + cubeCards.add(new CardIdentity("Vendilion Clique","")); + cubeCards.add(new CardIdentity("Vengevine","")); + cubeCards.add(new CardIdentity("Venser, Shaper Savant","")); + cubeCards.add(new CardIdentity("Verdant Catacombs","")); + cubeCards.add(new CardIdentity("Vesuvan Shapeshifter","")); + cubeCards.add(new CardIdentity("Vindicate","")); + cubeCards.add(new CardIdentity("Vines of Vastwood","")); + cubeCards.add(new CardIdentity("Visara the Dreadful","")); + cubeCards.add(new CardIdentity("Voice of Resurgence","")); + cubeCards.add(new CardIdentity("Voidmage Prodigy","")); + cubeCards.add(new CardIdentity("Volcanic Fallout","")); + cubeCards.add(new CardIdentity("Volcanic Island","")); + cubeCards.add(new CardIdentity("Volrath's Stronghold","")); + cubeCards.add(new CardIdentity("Wake Thrasher","")); + cubeCards.add(new CardIdentity("Wall of Blossoms","")); + cubeCards.add(new CardIdentity("Wall of Omens","")); + cubeCards.add(new CardIdentity("Wall of Reverence","")); + cubeCards.add(new CardIdentity("Wall of Roots","")); + cubeCards.add(new CardIdentity("Wasteland","")); + cubeCards.add(new CardIdentity("Watery Grave","")); + cubeCards.add(new CardIdentity("Wear // Tear","")); + cubeCards.add(new CardIdentity("Weathered Wayfarer","")); + cubeCards.add(new CardIdentity("Wheel of Fortune","")); + cubeCards.add(new CardIdentity("Whipcorder","")); + cubeCards.add(new CardIdentity("Wickerbough Elder","")); + cubeCards.add(new CardIdentity("Wild Nacatl","")); + cubeCards.add(new CardIdentity("Wildfire","")); + cubeCards.add(new CardIdentity("Willbender","")); + cubeCards.add(new CardIdentity("Windbrisk Heights","")); + cubeCards.add(new CardIdentity("Windswept Heath","")); + cubeCards.add(new CardIdentity("Winter Orb","")); + cubeCards.add(new CardIdentity("Wolfir Silverheart","")); + cubeCards.add(new CardIdentity("Wood Elves","")); + cubeCards.add(new CardIdentity("Wooded Bastion","")); + cubeCards.add(new CardIdentity("Wooded Foothills","")); + cubeCards.add(new CardIdentity("Woodfall Primus","")); + cubeCards.add(new CardIdentity("Woodland Cemetery","")); + cubeCards.add(new CardIdentity("Woolly Thoctar","")); + cubeCards.add(new CardIdentity("Worn Powerstone","")); + cubeCards.add(new CardIdentity("Wrath of God","")); + cubeCards.add(new CardIdentity("Wrench Mind","")); + cubeCards.add(new CardIdentity("Wurmcoil Engine","")); + cubeCards.add(new CardIdentity("Xenagos, the Reveler","")); + cubeCards.add(new CardIdentity("Yavimaya Coast","")); + cubeCards.add(new CardIdentity("Yavimaya Elder","")); + cubeCards.add(new CardIdentity("Yawgmoth's Will","")); + cubeCards.add(new CardIdentity("Yosei, the Morning Star","")); + cubeCards.add(new CardIdentity("Zealous Conscripts","")); + cubeCards.add(new CardIdentity("Zo-Zu the Punisher","")); + } +} diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MonoBlueCube.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MonoBlueCube.java index 6f83bc066e3..538193858a5 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MonoBlueCube.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/MonoBlueCube.java @@ -1,407 +1,406 @@ -/* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - -package mage.tournament.cubes; - -import mage.game.draft.DraftCube; -import mage.game.draft.DraftCube.CardIdentity; - -/** - * Cube taken from - * http://www.mtgsalvation.com/articles/29806-close-to-the-edge-mono-blue-cube-overview - * - * @author LevelX2 - */ -public class MonoBlueCube extends DraftCube { - - public MonoBlueCube() { - super("Mono Blue Cube"); - cubeCards.add(new CardIdentity("All Is Dust","")); - cubeCards.add(new CardIdentity("Amnesia","")); - cubeCards.add(new CardIdentity("Ancestral Vision","")); - cubeCards.add(new CardIdentity("Braingeyser","")); - cubeCards.add(new CardIdentity("Call to Mind","")); - cubeCards.add(new CardIdentity("Compulsive Research","")); - cubeCards.add(new CardIdentity("Deep Analysis","")); - cubeCards.add(new CardIdentity("Devastation Tide","")); - cubeCards.add(new CardIdentity("Enter the Infinite","")); - cubeCards.add(new CardIdentity("Fabricate","")); - cubeCards.add(new CardIdentity("Gitaxian Probe","")); - cubeCards.add(new CardIdentity("Ideas Unbound","")); - cubeCards.add(new CardIdentity("Increasing Confusion","")); - cubeCards.add(new CardIdentity("Legerdemain","")); - cubeCards.add(new CardIdentity("Memory Sluice","")); - cubeCards.add(new CardIdentity("Merchant Scroll","")); - cubeCards.add(new CardIdentity("Mind Sculpt","")); - cubeCards.add(new CardIdentity("Mind's Desire","")); - cubeCards.add(new CardIdentity("Personal Tutor","")); - cubeCards.add(new CardIdentity("Ponder","")); - cubeCards.add(new CardIdentity("Portent","")); - cubeCards.add(new CardIdentity("Preordain","")); - cubeCards.add(new CardIdentity("Reconstruction","")); - cubeCards.add(new CardIdentity("Serum Visions","")); - cubeCards.add(new CardIdentity("Shape Anew","")); - cubeCards.add(new CardIdentity("Show and Tell","")); - cubeCards.add(new CardIdentity("Sleight of Hand","")); - cubeCards.add(new CardIdentity("Temporal Fissure","")); - cubeCards.add(new CardIdentity("Time Spiral","")); - cubeCards.add(new CardIdentity("Time Stretch","")); - cubeCards.add(new CardIdentity("Time Walk","")); - cubeCards.add(new CardIdentity("Timetwister","")); - cubeCards.add(new CardIdentity("Tinker","")); - cubeCards.add(new CardIdentity("Tome Scour","")); - cubeCards.add(new CardIdentity("Undo","")); - cubeCards.add(new CardIdentity("Upheaval","")); - cubeCards.add(new CardIdentity("Windfall","")); - cubeCards.add(new CardIdentity("Adaptive Automaton","")); - cubeCards.add(new CardIdentity("Aeon Chronicler","")); - cubeCards.add(new CardIdentity("AEtherling","")); - cubeCards.add(new CardIdentity("Ambassador Laquatus","")); - cubeCards.add(new CardIdentity("Arcanis the Omnipotent","")); - cubeCards.add(new CardIdentity("Archaeomancer","")); - cubeCards.add(new CardIdentity("Augur of Bolas","")); - cubeCards.add(new CardIdentity("Blightsteel Colossus","")); - cubeCards.add(new CardIdentity("Braids, Conjurer Adept","")); - cubeCards.add(new CardIdentity("Briarberry Cohort","")); - cubeCards.add(new CardIdentity("Chancellor of the Spires","")); - cubeCards.add(new CardIdentity("Chronomaton","")); - cubeCards.add(new CardIdentity("Cloud of Faeries","")); - cubeCards.add(new CardIdentity("Cloudfin Raptor","")); - cubeCards.add(new CardIdentity("Cold-Eyed Selkie","")); - cubeCards.add(new CardIdentity("Conundrum Sphinx","")); - cubeCards.add(new CardIdentity("Copper Gnomes","")); - cubeCards.add(new CardIdentity("Coralhelm Commander","")); - cubeCards.add(new CardIdentity("Cursecatcher","")); - cubeCards.add(new CardIdentity("Darksteel Colossus","")); - cubeCards.add(new CardIdentity("Delver of Secrets Flip","")); - cubeCards.add(new CardIdentity("Dewdrop Spy","")); - cubeCards.add(new CardIdentity("Draining Whelk","")); - cubeCards.add(new CardIdentity("Drift of Phantasms","")); - cubeCards.add(new CardIdentity("Drowner Initiate","")); - cubeCards.add(new CardIdentity("Dungeon Geists","")); - cubeCards.add(new CardIdentity("Duplicant","")); - cubeCards.add(new CardIdentity("Elite Arcanist","")); - cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn","")); - cubeCards.add(new CardIdentity("Enclave Cryptologist","")); - cubeCards.add(new CardIdentity("Errant Ephemeron","")); - cubeCards.add(new CardIdentity("Ertai, Wizard Adept","")); - cubeCards.add(new CardIdentity("Faerie Harbinger","")); - cubeCards.add(new CardIdentity("Frost Titan","")); - cubeCards.add(new CardIdentity("Geralf's Mindcrusher","")); - cubeCards.add(new CardIdentity("Glen Elendra Archmage","")); - cubeCards.add(new CardIdentity("Gomazoa","")); - cubeCards.add(new CardIdentity("Grand Architect","")); - cubeCards.add(new CardIdentity("Hammerhead Shark","")); - cubeCards.add(new CardIdentity("Hedron Crab","")); - cubeCards.add(new CardIdentity("Horizon Drake","")); - cubeCards.add(new CardIdentity("Illusionary Servant","")); - cubeCards.add(new CardIdentity("Illusory Angel","")); - cubeCards.add(new CardIdentity("Inkfathom Infiltrator","")); - cubeCards.add(new CardIdentity("Inkwell Leviathan","")); - cubeCards.add(new CardIdentity("Inspired Sprite","")); - cubeCards.add(new CardIdentity("Jace's Archivist","")); - cubeCards.add(new CardIdentity("Jushi Apprentice","")); - cubeCards.add(new CardIdentity("Kederekt Leviathan","")); - cubeCards.add(new CardIdentity("Kuldotha Forgemaster","")); - cubeCards.add(new CardIdentity("Laboratory Maniac","")); - cubeCards.add(new CardIdentity("Lighthouse Chronologist","")); - cubeCards.add(new CardIdentity("Llawan, Cephalid Empress","")); - cubeCards.add(new CardIdentity("Looter il-Kor","")); - cubeCards.add(new CardIdentity("Lord of Atlantis","")); - cubeCards.add(new CardIdentity("Lullmage Mentor","")); - cubeCards.add(new CardIdentity("Master of the Pearl Trident","")); - cubeCards.add(new CardIdentity("Master of Waves","")); - cubeCards.add(new CardIdentity("Master Thief","")); - cubeCards.add(new CardIdentity("Master Transmuter","")); - cubeCards.add(new CardIdentity("Meloku the Clouded Mirror","")); - cubeCards.add(new CardIdentity("Merfolk Looter","")); - cubeCards.add(new CardIdentity("Merfolk Mesmerist","")); - cubeCards.add(new CardIdentity("Merfolk Sovereign","")); - cubeCards.add(new CardIdentity("Merfolk Spy","")); - cubeCards.add(new CardIdentity("Merrow Reejerey","")); - cubeCards.add(new CardIdentity("Metalworker","")); - cubeCards.add(new CardIdentity("Minister of Impediments","")); - cubeCards.add(new CardIdentity("Mothdust Changeling","")); - cubeCards.add(new CardIdentity("Mulldrifter","")); - cubeCards.add(new CardIdentity("Myr Battlesphere","")); - cubeCards.add(new CardIdentity("Nightveil Specter","")); - cubeCards.add(new CardIdentity("Nimbus Naiad","")); - cubeCards.add(new CardIdentity("Ninja of the Deep Hours","")); - cubeCards.add(new CardIdentity("Oona, Queen of the Fae","")); - cubeCards.add(new CardIdentity("Overtaker","")); - cubeCards.add(new CardIdentity("Painter's Servant","")); - cubeCards.add(new CardIdentity("Palinchron","")); - cubeCards.add(new CardIdentity("Patron Wizard","")); - cubeCards.add(new CardIdentity("Pestermite","")); - cubeCards.add(new CardIdentity("Phantasmal Bear","")); - cubeCards.add(new CardIdentity("Phantasmal Dragon","")); - cubeCards.add(new CardIdentity("Phantasmal Image","")); - cubeCards.add(new CardIdentity("Phyrexian Ingester","")); - cubeCards.add(new CardIdentity("Phyrexian Metamorph","")); - cubeCards.add(new CardIdentity("Platinum Angel","")); - cubeCards.add(new CardIdentity("Plumeveil","")); - cubeCards.add(new CardIdentity("Precursor Golem","")); - cubeCards.add(new CardIdentity("Prognostic Sphinx","")); - cubeCards.add(new CardIdentity("Puresight Merrow","")); - cubeCards.add(new CardIdentity("Raven Guild Master","")); - cubeCards.add(new CardIdentity("Riftwing Cloudskate","")); - cubeCards.add(new CardIdentity("Riptide Director","")); - cubeCards.add(new CardIdentity("Sage of Fables","")); - cubeCards.add(new CardIdentity("Sand Squid","")); - cubeCards.add(new CardIdentity("Sea Drake","")); - cubeCards.add(new CardIdentity("Sea Gate Oracle","")); - cubeCards.add(new CardIdentity("Sea Scryer","")); - cubeCards.add(new CardIdentity("Seasinger","")); - cubeCards.add(new CardIdentity("Serendib Efreet","")); - cubeCards.add(new CardIdentity("Shapesharer","")); - cubeCards.add(new CardIdentity("Signal Pest","")); - cubeCards.add(new CardIdentity("Silvergill Adept","")); - cubeCards.add(new CardIdentity("Skywatcher Adept","")); - cubeCards.add(new CardIdentity("Snapcaster Mage","")); - cubeCards.add(new CardIdentity("Sower of Temptation","")); - cubeCards.add(new CardIdentity("Spellstutter Sprite","")); - cubeCards.add(new CardIdentity("Spiketail Drakeling","")); - cubeCards.add(new CardIdentity("Spire Golem","")); - cubeCards.add(new CardIdentity("Sprite Noble","")); - cubeCards.add(new CardIdentity("Steel Hellkite","")); - cubeCards.add(new CardIdentity("Stern Mentor","")); - cubeCards.add(new CardIdentity("Stonybrook Banneret","")); - cubeCards.add(new CardIdentity("Sygg, River Cutthroat","")); - cubeCards.add(new CardIdentity("Talrand, Sky Summoner","")); - cubeCards.add(new CardIdentity("Teferi, Mage of Zhalfir","")); - cubeCards.add(new CardIdentity("Temporal Adept","")); - cubeCards.add(new CardIdentity("Thada Adel, Acquisitor","")); - cubeCards.add(new CardIdentity("Thalakos Deceiver","")); - cubeCards.add(new CardIdentity("Thassa, God of the Sea","")); - cubeCards.add(new CardIdentity("Thistledown Liege","")); - cubeCards.add(new CardIdentity("True-Name Nemesis","")); - cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre","")); - cubeCards.add(new CardIdentity("Vaporkin","")); - cubeCards.add(new CardIdentity("Vedalken AEthermage","")); - cubeCards.add(new CardIdentity("Vendilion Clique","")); - cubeCards.add(new CardIdentity("Venser, Shaper Savant","")); - cubeCards.add(new CardIdentity("Vesuvan Shapeshifter","")); - cubeCards.add(new CardIdentity("Vexing Sphinx","")); - cubeCards.add(new CardIdentity("Vodalian Knights","")); - cubeCards.add(new CardIdentity("Void Stalker","")); - cubeCards.add(new CardIdentity("Voidmage Prodigy","")); - cubeCards.add(new CardIdentity("Wake Thrasher","")); - cubeCards.add(new CardIdentity("Wasp Lancer","")); - cubeCards.add(new CardIdentity("Waterfront Bouncer","")); - cubeCards.add(new CardIdentity("Welkin Tern","")); - cubeCards.add(new CardIdentity("Wurmcoil Engine","")); - cubeCards.add(new CardIdentity("Jace, Architect of Thought","")); - cubeCards.add(new CardIdentity("Jace Beleren","")); - cubeCards.add(new CardIdentity("Jace, Memory Adept","")); - cubeCards.add(new CardIdentity("Jace, the Mind Sculptor","")); - cubeCards.add(new CardIdentity("Karn Liberated","")); - cubeCards.add(new CardIdentity("Ancestral Recall","")); - cubeCards.add(new CardIdentity("Annul","")); - cubeCards.add(new CardIdentity("Archive Trap","")); - cubeCards.add(new CardIdentity("Blue Sun's Zenith","")); - cubeCards.add(new CardIdentity("Boomerang","")); - cubeCards.add(new CardIdentity("Brain Freeze","")); - cubeCards.add(new CardIdentity("Brainstorm","")); - cubeCards.add(new CardIdentity("Broken Ambitions","")); - cubeCards.add(new CardIdentity("Capsize","")); - cubeCards.add(new CardIdentity("Careful Consideration","")); - cubeCards.add(new CardIdentity("Commandeer","")); - cubeCards.add(new CardIdentity("Complicate","")); - cubeCards.add(new CardIdentity("Condescend","")); - cubeCards.add(new CardIdentity("Counterspell","")); - cubeCards.add(new CardIdentity("Crippling Chill","")); - cubeCards.add(new CardIdentity("Cryptic Command","")); - cubeCards.add(new CardIdentity("Cyclonic Rift","")); - cubeCards.add(new CardIdentity("Daze","")); - cubeCards.add(new CardIdentity("Delay","")); - cubeCards.add(new CardIdentity("Deprive","")); - cubeCards.add(new CardIdentity("Dismiss","")); - cubeCards.add(new CardIdentity("Dispel","")); - cubeCards.add(new CardIdentity("Disrupt","")); - cubeCards.add(new CardIdentity("Dissipate","")); - cubeCards.add(new CardIdentity("Dissolve","")); - cubeCards.add(new CardIdentity("Dizzy Spell","")); - cubeCards.add(new CardIdentity("Dream Twist","")); - cubeCards.add(new CardIdentity("Evacuation","")); - cubeCards.add(new CardIdentity("Exclude","")); - cubeCards.add(new CardIdentity("Fact or Fiction","")); - cubeCards.add(new CardIdentity("Flash of Insight","")); - cubeCards.add(new CardIdentity("Flusterstorm","")); - cubeCards.add(new CardIdentity("Foil","")); - cubeCards.add(new CardIdentity("Forbid","")); - cubeCards.add(new CardIdentity("Force of Will","")); - cubeCards.add(new CardIdentity("Force Spike","")); - cubeCards.add(new CardIdentity("Frantic Search","")); - cubeCards.add(new CardIdentity("Gainsay","")); - cubeCards.add(new CardIdentity("Gush","")); - cubeCards.add(new CardIdentity("High Tide","")); - cubeCards.add(new CardIdentity("Impulse","")); - cubeCards.add(new CardIdentity("Into the Roil","")); - cubeCards.add(new CardIdentity("Logic Knot","")); - cubeCards.add(new CardIdentity("Long-Term Plans","")); - cubeCards.add(new CardIdentity("Mana Drain","")); - cubeCards.add(new CardIdentity("Mana Leak","")); - cubeCards.add(new CardIdentity("Meditate","")); - cubeCards.add(new CardIdentity("Mental Misstep","")); - cubeCards.add(new CardIdentity("Miscalculation","")); - cubeCards.add(new CardIdentity("Misdirection","")); - cubeCards.add(new CardIdentity("Muddle the Mixture","")); - cubeCards.add(new CardIdentity("Mystical Tutor","")); - cubeCards.add(new CardIdentity("Negate","")); - cubeCards.add(new CardIdentity("Opportunity","")); - cubeCards.add(new CardIdentity("Pact of Negation","")); - cubeCards.add(new CardIdentity("Peek","")); - cubeCards.add(new CardIdentity("Peer Through Depths","")); - cubeCards.add(new CardIdentity("Piracy Charm","")); - cubeCards.add(new CardIdentity("Pongify","")); - cubeCards.add(new CardIdentity("Psionic Blast","")); - cubeCards.add(new CardIdentity("Psychic Barrier","")); - cubeCards.add(new CardIdentity("Rapid Hybridization","")); - cubeCards.add(new CardIdentity("Ray of Command","")); - cubeCards.add(new CardIdentity("Remand","")); - cubeCards.add(new CardIdentity("Repeal","")); - cubeCards.add(new CardIdentity("Rewind","")); - cubeCards.add(new CardIdentity("Spell Pierce","")); - cubeCards.add(new CardIdentity("Spell Snare","")); - cubeCards.add(new CardIdentity("Steel Sabotage","")); - cubeCards.add(new CardIdentity("Stroke of Genius","")); - cubeCards.add(new CardIdentity("Swan Song","")); - cubeCards.add(new CardIdentity("Telling Time","")); - cubeCards.add(new CardIdentity("Think Twice","")); - cubeCards.add(new CardIdentity("Thought Scour","")); - cubeCards.add(new CardIdentity("Thwart","")); - cubeCards.add(new CardIdentity("Turnabout","")); - cubeCards.add(new CardIdentity("Vapor Snag","")); - cubeCards.add(new CardIdentity("Vision Charm","")); - cubeCards.add(new CardIdentity("Visions of Beyond","")); - cubeCards.add(new CardIdentity("Wheel and Deal","")); - cubeCards.add(new CardIdentity("Withdraw","")); - cubeCards.add(new CardIdentity("Academy Ruins","")); - cubeCards.add(new CardIdentity("Ancient Tomb","")); - cubeCards.add(new CardIdentity("Blinkmoth Nexus","")); - cubeCards.add(new CardIdentity("Buried Ruin","")); - cubeCards.add(new CardIdentity("Cavern of Souls","")); - cubeCards.add(new CardIdentity("Contested War Zone","")); - cubeCards.add(new CardIdentity("Desert","")); - cubeCards.add(new CardIdentity("Faerie Conclave","")); - cubeCards.add(new CardIdentity("Inkmoth Nexus","")); - cubeCards.add(new CardIdentity("Library of Alexandria","")); - cubeCards.add(new CardIdentity("Lonely Sandbar","")); - cubeCards.add(new CardIdentity("Maze of Ith","")); - cubeCards.add(new CardIdentity("Mishra's Factory","")); - cubeCards.add(new CardIdentity("Mishra's Workshop","")); - cubeCards.add(new CardIdentity("Mutavault","")); - cubeCards.add(new CardIdentity("Quicksand","")); - cubeCards.add(new CardIdentity("Rath's Edge","")); - cubeCards.add(new CardIdentity("Reliquary Tower","")); - cubeCards.add(new CardIdentity("Remote Isle","")); - cubeCards.add(new CardIdentity("Riptide Laboratory","")); - cubeCards.add(new CardIdentity("Rishadan Port","")); - cubeCards.add(new CardIdentity("Shelldock Isle","")); - cubeCards.add(new CardIdentity("Strip Mine","")); - cubeCards.add(new CardIdentity("The Tabernacle at Pendrell Vale","")); - cubeCards.add(new CardIdentity("Tolaria West","")); - cubeCards.add(new CardIdentity("Tolarian Academy","")); - cubeCards.add(new CardIdentity("Tower of the Magistrate","")); - cubeCards.add(new CardIdentity("Bident of Thassa","")); - cubeCards.add(new CardIdentity("Claustrophobia","")); - cubeCards.add(new CardIdentity("Control Magic","")); - cubeCards.add(new CardIdentity("Eye of the Storm","")); - cubeCards.add(new CardIdentity("Leyline of Anticipation","")); - cubeCards.add(new CardIdentity("Meishin, the Mind Cage","")); - cubeCards.add(new CardIdentity("Mind Over Matter","")); - cubeCards.add(new CardIdentity("Omniscience","")); - cubeCards.add(new CardIdentity("Power Artifact","")); - cubeCards.add(new CardIdentity("Propaganda","")); - cubeCards.add(new CardIdentity("Sensory Deprivation","")); - cubeCards.add(new CardIdentity("Standstill","")); - cubeCards.add(new CardIdentity("Take Possession","")); - cubeCards.add(new CardIdentity("Treachery","")); - cubeCards.add(new CardIdentity("Veiled Serpent","")); - cubeCards.add(new CardIdentity("Aeolipile","")); - cubeCards.add(new CardIdentity("AEther Spellbomb","")); - cubeCards.add(new CardIdentity("AEther Vial","")); - cubeCards.add(new CardIdentity("Ankh of Mishra","")); - cubeCards.add(new CardIdentity("Basalt Monolith","")); - cubeCards.add(new CardIdentity("Black Lotus","")); - cubeCards.add(new CardIdentity("Black Vise","")); - cubeCards.add(new CardIdentity("Bonesplitter","")); - cubeCards.add(new CardIdentity("Brittle Effigy","")); - cubeCards.add(new CardIdentity("Caged Sun","")); - cubeCards.add(new CardIdentity("Candelabra of Tawnos","")); - cubeCards.add(new CardIdentity("Chalice of the Void","")); - cubeCards.add(new CardIdentity("Coalition Relic","")); - cubeCards.add(new CardIdentity("Coat of Arms","")); - cubeCards.add(new CardIdentity("Codex Shredder","")); - cubeCards.add(new CardIdentity("Elixir of Immortality","")); - cubeCards.add(new CardIdentity("Extraplanar Lens","")); - cubeCards.add(new CardIdentity("Gilded Lotus","")); - cubeCards.add(new CardIdentity("Grafted Wargear","")); - cubeCards.add(new CardIdentity("Grim Monolith","")); - cubeCards.add(new CardIdentity("Grindclock","")); - cubeCards.add(new CardIdentity("Grindstone","")); - cubeCards.add(new CardIdentity("Howling Mine","")); - cubeCards.add(new CardIdentity("Isochron Scepter","")); - cubeCards.add(new CardIdentity("Keening Stone","")); - cubeCards.add(new CardIdentity("Knowledge Pool","")); - cubeCards.add(new CardIdentity("Lotus Bloom","")); - cubeCards.add(new CardIdentity("Mana Crypt","")); - cubeCards.add(new CardIdentity("Mana Vault","")); - cubeCards.add(new CardIdentity("Memory Jar","")); - cubeCards.add(new CardIdentity("Mind Stone","")); - cubeCards.add(new CardIdentity("Mindslaver","")); - cubeCards.add(new CardIdentity("Mishra's Helix","")); - cubeCards.add(new CardIdentity("Mortarpod","")); - cubeCards.add(new CardIdentity("Mox Diamond","")); - cubeCards.add(new CardIdentity("Mox Sapphire","")); - cubeCards.add(new CardIdentity("Nevinyrral's Disk","")); - cubeCards.add(new CardIdentity("Oblivion Stone","")); - cubeCards.add(new CardIdentity("Powder Keg","")); - cubeCards.add(new CardIdentity("Ratchet Bomb","")); - cubeCards.add(new CardIdentity("Runechanter's Pike","")); - cubeCards.add(new CardIdentity("Sands of Delirium","")); - cubeCards.add(new CardIdentity("Sapphire Medallion","")); - cubeCards.add(new CardIdentity("Sensei's Divining Top","")); - cubeCards.add(new CardIdentity("Skullclamp","")); - cubeCards.add(new CardIdentity("Smokestack","")); - cubeCards.add(new CardIdentity("Sol Ring","")); - cubeCards.add(new CardIdentity("Strata Scythe","")); - cubeCards.add(new CardIdentity("Sword of Body and Mind","")); - cubeCards.add(new CardIdentity("Sword of Fire and Ice","")); - cubeCards.add(new CardIdentity("Tangle Wire","")); - cubeCards.add(new CardIdentity("Thran Dynamo","")); - cubeCards.add(new CardIdentity("Time Vault","")); - cubeCards.add(new CardIdentity("Umezawa's Jitte","")); - cubeCards.add(new CardIdentity("Vedalken Shackles","")); - cubeCards.add(new CardIdentity("Voltaic Key","")); - cubeCards.add(new CardIdentity("Winter Orb","")); - cubeCards.add(new CardIdentity("Worn Powerstone","")); - - } -} - +/* +* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. +* +* Redistribution and use in source and binary forms, with or without modification, are +* permitted provided that the following conditions are met: +* +* 1. Redistributions of source code must retain the above copyright notice, this list of +* conditions and the following disclaimer. +* +* 2. Redistributions in binary form must reproduce the above copyright notice, this list +* of conditions and the following disclaimer in the documentation and/or other materials +* provided with the distribution. +* +* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED +* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND +* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR +* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR +* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON +* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +* +* The views and conclusions contained in the software and documentation are those of the +* authors and should not be interpreted as representing official policies, either expressed +* or implied, of BetaSteward_at_googlemail.com. +*/ + +package mage.tournament.cubes; + +import mage.game.draft.DraftCube; +import mage.game.draft.DraftCube.CardIdentity; + +/** + * Cube taken from + * http://www.mtgsalvation.com/articles/29806-close-to-the-edge-mono-blue-cube-overview + * + * @author LevelX2 + */ +public class MonoBlueCube extends DraftCube { + + public MonoBlueCube() { + super("Mono Blue Cube"); + cubeCards.add(new CardIdentity("Academy Ruins","")); + cubeCards.add(new CardIdentity("Adaptive Automaton","")); + cubeCards.add(new CardIdentity("Aeolipile","")); + cubeCards.add(new CardIdentity("Aeon Chronicler","")); + cubeCards.add(new CardIdentity("AEther Spellbomb","")); + cubeCards.add(new CardIdentity("AEther Vial","")); + cubeCards.add(new CardIdentity("AEtherling","")); + cubeCards.add(new CardIdentity("All Is Dust","")); + cubeCards.add(new CardIdentity("Ambassador Laquatus","")); + cubeCards.add(new CardIdentity("Amnesia","")); + cubeCards.add(new CardIdentity("Ancestral Recall","")); + cubeCards.add(new CardIdentity("Ancestral Vision","")); + cubeCards.add(new CardIdentity("Ancient Tomb","")); + cubeCards.add(new CardIdentity("Ankh of Mishra","")); + cubeCards.add(new CardIdentity("Annul","")); + cubeCards.add(new CardIdentity("Arcanis the Omnipotent","")); + cubeCards.add(new CardIdentity("Archaeomancer","")); + cubeCards.add(new CardIdentity("Archive Trap","")); + cubeCards.add(new CardIdentity("Augur of Bolas","")); + cubeCards.add(new CardIdentity("Basalt Monolith","")); + cubeCards.add(new CardIdentity("Bident of Thassa","")); + cubeCards.add(new CardIdentity("Black Lotus","")); + cubeCards.add(new CardIdentity("Black Vise","")); + cubeCards.add(new CardIdentity("Blightsteel Colossus","")); + cubeCards.add(new CardIdentity("Blinkmoth Nexus","")); + cubeCards.add(new CardIdentity("Blue Sun's Zenith","")); + cubeCards.add(new CardIdentity("Bonesplitter","")); + cubeCards.add(new CardIdentity("Boomerang","")); + cubeCards.add(new CardIdentity("Braids, Conjurer Adept","")); + cubeCards.add(new CardIdentity("Brain Freeze","")); + cubeCards.add(new CardIdentity("Braingeyser","")); + cubeCards.add(new CardIdentity("Brainstorm","")); + cubeCards.add(new CardIdentity("Briarberry Cohort","")); + cubeCards.add(new CardIdentity("Brittle Effigy","")); + cubeCards.add(new CardIdentity("Broken Ambitions","")); + cubeCards.add(new CardIdentity("Buried Ruin","")); + cubeCards.add(new CardIdentity("Caged Sun","")); + cubeCards.add(new CardIdentity("Call to Mind","")); + cubeCards.add(new CardIdentity("Candelabra of Tawnos","")); + cubeCards.add(new CardIdentity("Capsize","")); + cubeCards.add(new CardIdentity("Careful Consideration","")); + cubeCards.add(new CardIdentity("Cavern of Souls","")); + cubeCards.add(new CardIdentity("Chalice of the Void","")); + cubeCards.add(new CardIdentity("Chancellor of the Spires","")); + cubeCards.add(new CardIdentity("Chronomaton","")); + cubeCards.add(new CardIdentity("Claustrophobia","")); + cubeCards.add(new CardIdentity("Cloud of Faeries","")); + cubeCards.add(new CardIdentity("Cloudfin Raptor","")); + cubeCards.add(new CardIdentity("Coalition Relic","")); + cubeCards.add(new CardIdentity("Coat of Arms","")); + cubeCards.add(new CardIdentity("Codex Shredder","")); + cubeCards.add(new CardIdentity("Cold-Eyed Selkie","")); + cubeCards.add(new CardIdentity("Commandeer","")); + cubeCards.add(new CardIdentity("Complicate","")); + cubeCards.add(new CardIdentity("Compulsive Research","")); + cubeCards.add(new CardIdentity("Condescend","")); + cubeCards.add(new CardIdentity("Contested War Zone","")); + cubeCards.add(new CardIdentity("Control Magic","")); + cubeCards.add(new CardIdentity("Conundrum Sphinx","")); + cubeCards.add(new CardIdentity("Copper Gnomes","")); + cubeCards.add(new CardIdentity("Coralhelm Commander","")); + cubeCards.add(new CardIdentity("Counterspell","")); + cubeCards.add(new CardIdentity("Crippling Chill","")); + cubeCards.add(new CardIdentity("Cryptic Command","")); + cubeCards.add(new CardIdentity("Cursecatcher","")); + cubeCards.add(new CardIdentity("Cyclonic Rift","")); + cubeCards.add(new CardIdentity("Darksteel Colossus","")); + cubeCards.add(new CardIdentity("Daze","")); + cubeCards.add(new CardIdentity("Deep Analysis","")); + cubeCards.add(new CardIdentity("Delay","")); + cubeCards.add(new CardIdentity("Delver of Secrets","")); + cubeCards.add(new CardIdentity("Deprive","")); + cubeCards.add(new CardIdentity("Desert","")); + cubeCards.add(new CardIdentity("Devastation Tide","")); + cubeCards.add(new CardIdentity("Dewdrop Spy","")); + cubeCards.add(new CardIdentity("Dismiss","")); + cubeCards.add(new CardIdentity("Dispel","")); + cubeCards.add(new CardIdentity("Disrupt","")); + cubeCards.add(new CardIdentity("Dissipate","")); + cubeCards.add(new CardIdentity("Dissolve","")); + cubeCards.add(new CardIdentity("Dizzy Spell","")); + cubeCards.add(new CardIdentity("Draining Whelk","")); + cubeCards.add(new CardIdentity("Dream Twist","")); + cubeCards.add(new CardIdentity("Drift of Phantasms","")); + cubeCards.add(new CardIdentity("Drowner Initiate","")); + cubeCards.add(new CardIdentity("Dungeon Geists","")); + cubeCards.add(new CardIdentity("Duplicant","")); + cubeCards.add(new CardIdentity("Elite Arcanist","")); + cubeCards.add(new CardIdentity("Elixir of Immortality","")); + cubeCards.add(new CardIdentity("Emrakul, the Aeons Torn","")); + cubeCards.add(new CardIdentity("Enclave Cryptologist","")); + cubeCards.add(new CardIdentity("Enter the Infinite","")); + cubeCards.add(new CardIdentity("Errant Ephemeron","")); + cubeCards.add(new CardIdentity("Ertai, Wizard Adept","")); + cubeCards.add(new CardIdentity("Evacuation","")); + cubeCards.add(new CardIdentity("Exclude","")); + cubeCards.add(new CardIdentity("Extraplanar Lens","")); + cubeCards.add(new CardIdentity("Eye of the Storm","")); + cubeCards.add(new CardIdentity("Fabricate","")); + cubeCards.add(new CardIdentity("Fact or Fiction","")); + cubeCards.add(new CardIdentity("Faerie Conclave","")); + cubeCards.add(new CardIdentity("Faerie Harbinger","")); + cubeCards.add(new CardIdentity("Flash of Insight","")); + cubeCards.add(new CardIdentity("Flusterstorm","")); + cubeCards.add(new CardIdentity("Foil","")); + cubeCards.add(new CardIdentity("Forbid","")); + cubeCards.add(new CardIdentity("Force of Will","")); + cubeCards.add(new CardIdentity("Force Spike","")); + cubeCards.add(new CardIdentity("Frantic Search","")); + cubeCards.add(new CardIdentity("Frost Titan","")); + cubeCards.add(new CardIdentity("Gainsay","")); + cubeCards.add(new CardIdentity("Geralf's Mindcrusher","")); + cubeCards.add(new CardIdentity("Gilded Lotus","")); + cubeCards.add(new CardIdentity("Gitaxian Probe","")); + cubeCards.add(new CardIdentity("Glen Elendra Archmage","")); + cubeCards.add(new CardIdentity("Gomazoa","")); + cubeCards.add(new CardIdentity("Grafted Wargear","")); + cubeCards.add(new CardIdentity("Grand Architect","")); + cubeCards.add(new CardIdentity("Grim Monolith","")); + cubeCards.add(new CardIdentity("Grindclock","")); + cubeCards.add(new CardIdentity("Grindstone","")); + cubeCards.add(new CardIdentity("Gush","")); + cubeCards.add(new CardIdentity("Hammerhead Shark","")); + cubeCards.add(new CardIdentity("Hedron Crab","")); + cubeCards.add(new CardIdentity("High Tide","")); + cubeCards.add(new CardIdentity("Horizon Drake","")); + cubeCards.add(new CardIdentity("Howling Mine","")); + cubeCards.add(new CardIdentity("Ideas Unbound","")); + cubeCards.add(new CardIdentity("Illusionary Servant","")); + cubeCards.add(new CardIdentity("Illusory Angel","")); + cubeCards.add(new CardIdentity("Impulse","")); + cubeCards.add(new CardIdentity("Increasing Confusion","")); + cubeCards.add(new CardIdentity("Inkfathom Infiltrator","")); + cubeCards.add(new CardIdentity("Inkmoth Nexus","")); + cubeCards.add(new CardIdentity("Inkwell Leviathan","")); + cubeCards.add(new CardIdentity("Inspired Sprite","")); + cubeCards.add(new CardIdentity("Into the Roil","")); + cubeCards.add(new CardIdentity("Isochron Scepter","")); + cubeCards.add(new CardIdentity("Jace Beleren","")); + cubeCards.add(new CardIdentity("Jace, Architect of Thought","")); + cubeCards.add(new CardIdentity("Jace, Memory Adept","")); + cubeCards.add(new CardIdentity("Jace, the Mind Sculptor","")); + cubeCards.add(new CardIdentity("Jace's Archivist","")); + cubeCards.add(new CardIdentity("Jushi Apprentice","")); + cubeCards.add(new CardIdentity("Karn Liberated","")); + cubeCards.add(new CardIdentity("Kederekt Leviathan","")); + cubeCards.add(new CardIdentity("Keening Stone","")); + cubeCards.add(new CardIdentity("Knowledge Pool","")); + cubeCards.add(new CardIdentity("Kuldotha Forgemaster","")); + cubeCards.add(new CardIdentity("Laboratory Maniac","")); + cubeCards.add(new CardIdentity("Legerdemain","")); + cubeCards.add(new CardIdentity("Leyline of Anticipation","")); + cubeCards.add(new CardIdentity("Library of Alexandria","")); + cubeCards.add(new CardIdentity("Lighthouse Chronologist","")); + cubeCards.add(new CardIdentity("Llawan, Cephalid Empress","")); + cubeCards.add(new CardIdentity("Logic Knot","")); + cubeCards.add(new CardIdentity("Lonely Sandbar","")); + cubeCards.add(new CardIdentity("Long-Term Plans","")); + cubeCards.add(new CardIdentity("Looter il-Kor","")); + cubeCards.add(new CardIdentity("Lord of Atlantis","")); + cubeCards.add(new CardIdentity("Lotus Bloom","")); + cubeCards.add(new CardIdentity("Lullmage Mentor","")); + cubeCards.add(new CardIdentity("Mana Crypt","")); + cubeCards.add(new CardIdentity("Mana Drain","")); + cubeCards.add(new CardIdentity("Mana Leak","")); + cubeCards.add(new CardIdentity("Mana Vault","")); + cubeCards.add(new CardIdentity("Master of the Pearl Trident","")); + cubeCards.add(new CardIdentity("Master of Waves","")); + cubeCards.add(new CardIdentity("Master Thief","")); + cubeCards.add(new CardIdentity("Master Transmuter","")); + cubeCards.add(new CardIdentity("Maze of Ith","")); + cubeCards.add(new CardIdentity("Meditate","")); + cubeCards.add(new CardIdentity("Meishin, the Mind Cage","")); + cubeCards.add(new CardIdentity("Meloku the Clouded Mirror","")); + cubeCards.add(new CardIdentity("Memory Jar","")); + cubeCards.add(new CardIdentity("Memory Sluice","")); + cubeCards.add(new CardIdentity("Mental Misstep","")); + cubeCards.add(new CardIdentity("Merchant Scroll","")); + cubeCards.add(new CardIdentity("Merfolk Looter","")); + cubeCards.add(new CardIdentity("Merfolk Mesmerist","")); + cubeCards.add(new CardIdentity("Merfolk Sovereign","")); + cubeCards.add(new CardIdentity("Merfolk Spy","")); + cubeCards.add(new CardIdentity("Merrow Reejerey","")); + cubeCards.add(new CardIdentity("Metalworker","")); + cubeCards.add(new CardIdentity("Mind Over Matter","")); + cubeCards.add(new CardIdentity("Mind Sculpt","")); + cubeCards.add(new CardIdentity("Mind Stone","")); + cubeCards.add(new CardIdentity("Mind's Desire","")); + cubeCards.add(new CardIdentity("Mindslaver","")); + cubeCards.add(new CardIdentity("Minister of Impediments","")); + cubeCards.add(new CardIdentity("Miscalculation","")); + cubeCards.add(new CardIdentity("Misdirection","")); + cubeCards.add(new CardIdentity("Mishra's Factory","")); + cubeCards.add(new CardIdentity("Mishra's Helix","")); + cubeCards.add(new CardIdentity("Mishra's Workshop","")); + cubeCards.add(new CardIdentity("Mortarpod","")); + cubeCards.add(new CardIdentity("Mothdust Changeling","")); + cubeCards.add(new CardIdentity("Mox Diamond","")); + cubeCards.add(new CardIdentity("Mox Sapphire","")); + cubeCards.add(new CardIdentity("Muddle the Mixture","")); + cubeCards.add(new CardIdentity("Mulldrifter","")); + cubeCards.add(new CardIdentity("Mutavault","")); + cubeCards.add(new CardIdentity("Myr Battlesphere","")); + cubeCards.add(new CardIdentity("Mystical Tutor","")); + cubeCards.add(new CardIdentity("Negate","")); + cubeCards.add(new CardIdentity("Nevinyrral's Disk","")); + cubeCards.add(new CardIdentity("Nightveil Specter","")); + cubeCards.add(new CardIdentity("Nimbus Naiad","")); + cubeCards.add(new CardIdentity("Ninja of the Deep Hours","")); + cubeCards.add(new CardIdentity("Oblivion Stone","")); + cubeCards.add(new CardIdentity("Omniscience","")); + cubeCards.add(new CardIdentity("Oona, Queen of the Fae","")); + cubeCards.add(new CardIdentity("Opportunity","")); + cubeCards.add(new CardIdentity("Overtaker","")); + cubeCards.add(new CardIdentity("Pact of Negation","")); + cubeCards.add(new CardIdentity("Painter's Servant","")); + cubeCards.add(new CardIdentity("Palinchron","")); + cubeCards.add(new CardIdentity("Patron Wizard","")); + cubeCards.add(new CardIdentity("Peek","")); + cubeCards.add(new CardIdentity("Peer Through Depths","")); + cubeCards.add(new CardIdentity("Personal Tutor","")); + cubeCards.add(new CardIdentity("Pestermite","")); + cubeCards.add(new CardIdentity("Phantasmal Bear","")); + cubeCards.add(new CardIdentity("Phantasmal Dragon","")); + cubeCards.add(new CardIdentity("Phantasmal Image","")); + cubeCards.add(new CardIdentity("Phyrexian Ingester","")); + cubeCards.add(new CardIdentity("Phyrexian Metamorph","")); + cubeCards.add(new CardIdentity("Piracy Charm","")); + cubeCards.add(new CardIdentity("Platinum Angel","")); + cubeCards.add(new CardIdentity("Plumeveil","")); + cubeCards.add(new CardIdentity("Ponder","")); + cubeCards.add(new CardIdentity("Pongify","")); + cubeCards.add(new CardIdentity("Portent","")); + cubeCards.add(new CardIdentity("Powder Keg","")); + cubeCards.add(new CardIdentity("Power Artifact","")); + cubeCards.add(new CardIdentity("Precursor Golem","")); + cubeCards.add(new CardIdentity("Preordain","")); + cubeCards.add(new CardIdentity("Prognostic Sphinx","")); + cubeCards.add(new CardIdentity("Propaganda","")); + cubeCards.add(new CardIdentity("Psionic Blast","")); + cubeCards.add(new CardIdentity("Psychic Barrier","")); + cubeCards.add(new CardIdentity("Puresight Merrow","")); + cubeCards.add(new CardIdentity("Quicksand","")); + cubeCards.add(new CardIdentity("Rapid Hybridization","")); + cubeCards.add(new CardIdentity("Ratchet Bomb","")); + cubeCards.add(new CardIdentity("Rath's Edge","")); + cubeCards.add(new CardIdentity("Raven Guild Master","")); + cubeCards.add(new CardIdentity("Ray of Command","")); + cubeCards.add(new CardIdentity("Reconstruction","")); + cubeCards.add(new CardIdentity("Reliquary Tower","")); + cubeCards.add(new CardIdentity("Remand","")); + cubeCards.add(new CardIdentity("Remote Isle","")); + cubeCards.add(new CardIdentity("Repeal","")); + cubeCards.add(new CardIdentity("Rewind","")); + cubeCards.add(new CardIdentity("Riftwing Cloudskate","")); + cubeCards.add(new CardIdentity("Riptide Director","")); + cubeCards.add(new CardIdentity("Riptide Laboratory","")); + cubeCards.add(new CardIdentity("Rishadan Port","")); + cubeCards.add(new CardIdentity("Runechanter's Pike","")); + cubeCards.add(new CardIdentity("Sage of Fables","")); + cubeCards.add(new CardIdentity("Sand Squid","")); + cubeCards.add(new CardIdentity("Sands of Delirium","")); + cubeCards.add(new CardIdentity("Sapphire Medallion","")); + cubeCards.add(new CardIdentity("Sea Drake","")); + cubeCards.add(new CardIdentity("Sea Gate Oracle","")); + cubeCards.add(new CardIdentity("Sea Scryer","")); + cubeCards.add(new CardIdentity("Seasinger","")); + cubeCards.add(new CardIdentity("Sensei's Divining Top","")); + cubeCards.add(new CardIdentity("Sensory Deprivation","")); + cubeCards.add(new CardIdentity("Serendib Efreet","")); + cubeCards.add(new CardIdentity("Serum Visions","")); + cubeCards.add(new CardIdentity("Shape Anew","")); + cubeCards.add(new CardIdentity("Shapesharer","")); + cubeCards.add(new CardIdentity("Shelldock Isle","")); + cubeCards.add(new CardIdentity("Show and Tell","")); + cubeCards.add(new CardIdentity("Signal Pest","")); + cubeCards.add(new CardIdentity("Silvergill Adept","")); + cubeCards.add(new CardIdentity("Skullclamp","")); + cubeCards.add(new CardIdentity("Skywatcher Adept","")); + cubeCards.add(new CardIdentity("Sleight of Hand","")); + cubeCards.add(new CardIdentity("Smokestack","")); + cubeCards.add(new CardIdentity("Snapcaster Mage","")); + cubeCards.add(new CardIdentity("Sol Ring","")); + cubeCards.add(new CardIdentity("Sower of Temptation","")); + cubeCards.add(new CardIdentity("Spell Pierce","")); + cubeCards.add(new CardIdentity("Spell Snare","")); + cubeCards.add(new CardIdentity("Spellstutter Sprite","")); + cubeCards.add(new CardIdentity("Spiketail Drakeling","")); + cubeCards.add(new CardIdentity("Spire Golem","")); + cubeCards.add(new CardIdentity("Sprite Noble","")); + cubeCards.add(new CardIdentity("Standstill","")); + cubeCards.add(new CardIdentity("Steel Hellkite","")); + cubeCards.add(new CardIdentity("Steel Sabotage","")); + cubeCards.add(new CardIdentity("Stern Mentor","")); + cubeCards.add(new CardIdentity("Stonybrook Banneret","")); + cubeCards.add(new CardIdentity("Strata Scythe","")); + cubeCards.add(new CardIdentity("Strip Mine","")); + cubeCards.add(new CardIdentity("Stroke of Genius","")); + cubeCards.add(new CardIdentity("Swan Song","")); + cubeCards.add(new CardIdentity("Sword of Body and Mind","")); + cubeCards.add(new CardIdentity("Sword of Fire and Ice","")); + cubeCards.add(new CardIdentity("Sygg, River Cutthroat","")); + cubeCards.add(new CardIdentity("Take Possession","")); + cubeCards.add(new CardIdentity("Talrand, Sky Summoner","")); + cubeCards.add(new CardIdentity("Tangle Wire","")); + cubeCards.add(new CardIdentity("Teferi, Mage of Zhalfir","")); + cubeCards.add(new CardIdentity("Telling Time","")); + cubeCards.add(new CardIdentity("Temporal Adept","")); + cubeCards.add(new CardIdentity("Temporal Fissure","")); + cubeCards.add(new CardIdentity("Thada Adel, Acquisitor","")); + cubeCards.add(new CardIdentity("Thalakos Deceiver","")); + cubeCards.add(new CardIdentity("Thassa, God of the Sea","")); + cubeCards.add(new CardIdentity("The Tabernacle at Pendrell Vale","")); + cubeCards.add(new CardIdentity("Think Twice","")); + cubeCards.add(new CardIdentity("Thistledown Liege","")); + cubeCards.add(new CardIdentity("Thought Scour","")); + cubeCards.add(new CardIdentity("Thran Dynamo","")); + cubeCards.add(new CardIdentity("Thwart","")); + cubeCards.add(new CardIdentity("Time Spiral","")); + cubeCards.add(new CardIdentity("Time Stretch","")); + cubeCards.add(new CardIdentity("Time Vault","")); + cubeCards.add(new CardIdentity("Time Walk","")); + cubeCards.add(new CardIdentity("Timetwister","")); + cubeCards.add(new CardIdentity("Tinker","")); + cubeCards.add(new CardIdentity("Tolaria West","")); + cubeCards.add(new CardIdentity("Tolarian Academy","")); + cubeCards.add(new CardIdentity("Tome Scour","")); + cubeCards.add(new CardIdentity("Tower of the Magistrate","")); + cubeCards.add(new CardIdentity("Treachery","")); + cubeCards.add(new CardIdentity("True-Name Nemesis","")); + cubeCards.add(new CardIdentity("Turnabout","")); + cubeCards.add(new CardIdentity("Ulamog, the Infinite Gyre","")); + cubeCards.add(new CardIdentity("Umezawa's Jitte","")); + cubeCards.add(new CardIdentity("Undo","")); + cubeCards.add(new CardIdentity("Upheaval","")); + cubeCards.add(new CardIdentity("Vapor Snag","")); + cubeCards.add(new CardIdentity("Vaporkin","")); + cubeCards.add(new CardIdentity("Vedalken AEthermage","")); + cubeCards.add(new CardIdentity("Vedalken Shackles","")); + cubeCards.add(new CardIdentity("Veiled Serpent","")); + cubeCards.add(new CardIdentity("Vendilion Clique","")); + cubeCards.add(new CardIdentity("Venser, Shaper Savant","")); + cubeCards.add(new CardIdentity("Vesuvan Shapeshifter","")); + cubeCards.add(new CardIdentity("Vexing Sphinx","")); + cubeCards.add(new CardIdentity("Vision Charm","")); + cubeCards.add(new CardIdentity("Visions of Beyond","")); + cubeCards.add(new CardIdentity("Vodalian Knights","")); + cubeCards.add(new CardIdentity("Void Stalker","")); + cubeCards.add(new CardIdentity("Voidmage Prodigy","")); + cubeCards.add(new CardIdentity("Voltaic Key","")); + cubeCards.add(new CardIdentity("Wake Thrasher","")); + cubeCards.add(new CardIdentity("Wasp Lancer","")); + cubeCards.add(new CardIdentity("Waterfront Bouncer","")); + cubeCards.add(new CardIdentity("Welkin Tern","")); + cubeCards.add(new CardIdentity("Wheel and Deal","")); + cubeCards.add(new CardIdentity("Windfall","")); + cubeCards.add(new CardIdentity("Winter Orb","")); + cubeCards.add(new CardIdentity("Withdraw","")); + cubeCards.add(new CardIdentity("Worn Powerstone","")); + cubeCards.add(new CardIdentity("Wurmcoil Engine","")); + } +} + diff --git a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/PeasantsToolboxCube.java b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/PeasantsToolboxCube.java index df5459ac826..afe63e3d623 100644 --- a/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/PeasantsToolboxCube.java +++ b/Mage.Server.Plugins/Mage.Tournament.BoosterDraft/src/mage/tournament/cubes/PeasantsToolboxCube.java @@ -1,844 +1,843 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.tournament.cubes; - -import mage.game.draft.DraftCube; -import mage.game.draft.DraftCube.CardIdentity; - -/** - * Cube taken from http://www.cubetutor.com/viewcube/10358 - * - * @author LevelX2 - */ -public class PeasantsToolboxCube extends DraftCube { - - public PeasantsToolboxCube() { - super("The Peasant's Toolbox"); - cubeCards.add(new CardIdentity("Boros Elite", "")); - cubeCards.add(new CardIdentity("Caravan Escort", "")); - cubeCards.add(new CardIdentity("Cenn's Tactician", "")); - cubeCards.add(new CardIdentity("Ghost-Lit Redeemer", "")); - cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); - cubeCards.add(new CardIdentity("Loyal Pegasus", "")); - cubeCards.add(new CardIdentity("Accorder Paladin", "")); - cubeCards.add(new CardIdentity("Alabaster Mage", "")); - cubeCards.add(new CardIdentity("Azorius Arrester", "")); - cubeCards.add(new CardIdentity("Cloistered Youth", "")); - cubeCards.add(new CardIdentity("Daring Skyjek", "")); - cubeCards.add(new CardIdentity("Dauntless River Marshal", "")); - cubeCards.add(new CardIdentity("God-Favored General", "")); - cubeCards.add(new CardIdentity("Knight of Cliffhaven", "")); - cubeCards.add(new CardIdentity("Knight of the Holy Nimbus", "")); - cubeCards.add(new CardIdentity("Knight of the Skyward Eye", "")); - cubeCards.add(new CardIdentity("Kor Aeronaut", "")); - cubeCards.add(new CardIdentity("Kor Skyfisher", "")); - cubeCards.add(new CardIdentity("Nearheath Pilgrim", "")); - cubeCards.add(new CardIdentity("Order of the Golden Cricket", "")); - cubeCards.add(new CardIdentity("Squall Drifter", "")); - cubeCards.add(new CardIdentity("Syndic of Tithes", "")); - cubeCards.add(new CardIdentity("Unruly Mob", "")); - cubeCards.add(new CardIdentity("Affa Guard Hound", "")); - cubeCards.add(new CardIdentity("Apex Hawks", "")); - cubeCards.add(new CardIdentity("Azorius Herald", "")); - cubeCards.add(new CardIdentity("Banisher Priest", "")); - cubeCards.add(new CardIdentity("Basilica Guards", "")); - cubeCards.add(new CardIdentity("Burrenton Bombardier", "")); - cubeCards.add(new CardIdentity("Dawnglare Invoker", "")); - cubeCards.add(new CardIdentity("Fiend Hunter", "")); - cubeCards.add(new CardIdentity("Flickerwisp", "")); - cubeCards.add(new CardIdentity("Haazda Snare Squad", "")); - cubeCards.add(new CardIdentity("Icatian Crier", "")); - cubeCards.add(new CardIdentity("Kabuto Moth", "")); - cubeCards.add(new CardIdentity("Riftmarked Knight", "")); - cubeCards.add(new CardIdentity("Roc Egg", "")); - cubeCards.add(new CardIdentity("Scholar of Athreos", "")); - cubeCards.add(new CardIdentity("Soulsworn Jury", "")); - cubeCards.add(new CardIdentity("Spirit en-Dal", "")); - cubeCards.add(new CardIdentity("Village Bell-Ringer", "")); - cubeCards.add(new CardIdentity("Wingsteed Rider", "")); - cubeCards.add(new CardIdentity("Akroan Phalanx", "")); - cubeCards.add(new CardIdentity("Ballista Squad", "")); - cubeCards.add(new CardIdentity("Celestial Crusader", "")); - cubeCards.add(new CardIdentity("Glimmerpoint Stag", "")); - cubeCards.add(new CardIdentity("Goldmeadow Lookout", "")); - cubeCards.add(new CardIdentity("Goldnight Commander", "")); - cubeCards.add(new CardIdentity("Kabira Vindicator", "")); - cubeCards.add(new CardIdentity("Knight of Obligation", "")); - cubeCards.add(new CardIdentity("Lightkeeper of Emeria", "")); - cubeCards.add(new CardIdentity("Master Splicer", "")); - cubeCards.add(new CardIdentity("Meadowboon", "")); - cubeCards.add(new CardIdentity("Prized Elephant", "")); - cubeCards.add(new CardIdentity("Shade of Trokair", "")); - cubeCards.add(new CardIdentity("Thraben Sentry", "")); - cubeCards.add(new CardIdentity("Wakestone Gargoyle", "")); - cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); - cubeCards.add(new CardIdentity("Ornitharch", "")); - cubeCards.add(new CardIdentity("Yoked Plowbeast", "")); - cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); - cubeCards.add(new CardIdentity("Harm's Way", "")); - cubeCards.add(new CardIdentity("Reciprocate", "")); - cubeCards.add(new CardIdentity("Smite", "")); - cubeCards.add(new CardIdentity("Stand Firm", "")); - cubeCards.add(new CardIdentity("Celestial Flare", "")); - cubeCards.add(new CardIdentity("Dawn Charm", "")); - cubeCards.add(new CardIdentity("Judge Unworthy", "")); - cubeCards.add(new CardIdentity("Otherworldly Journey", "")); - cubeCards.add(new CardIdentity("Puncturing Light", "")); - cubeCards.add(new CardIdentity("Test of Faith", "")); - cubeCards.add(new CardIdentity("Blinding Beam", "")); - cubeCards.add(new CardIdentity("Choking Fumes", "")); - cubeCards.add(new CardIdentity("Dauntless Onslaught", "")); - cubeCards.add(new CardIdentity("Devouring Light", "")); - cubeCards.add(new CardIdentity("Dispense Justice", "")); - cubeCards.add(new CardIdentity("Lapse of Certainty", "")); - cubeCards.add(new CardIdentity("Pitfall Trap", "")); - cubeCards.add(new CardIdentity("Rally the Peasants", "")); - cubeCards.add(new CardIdentity("Chastise", "")); - cubeCards.add(new CardIdentity("Divine Verdict", "")); - cubeCards.add(new CardIdentity("Refraction Trap", "")); - cubeCards.add(new CardIdentity("Arrow Volley Trap", "")); - cubeCards.add(new CardIdentity("Gleam of Resistance", "")); - cubeCards.add(new CardIdentity("Swell of Courage", "")); - cubeCards.add(new CardIdentity("Banishing Stroke", "")); - cubeCards.add(new CardIdentity("Hail of Arrows", "")); - cubeCards.add(new CardIdentity("Lingering Souls", "")); - cubeCards.add(new CardIdentity("Marshaling Cry", "")); - cubeCards.add(new CardIdentity("Survival Cache", "")); - cubeCards.add(new CardIdentity("Timely Reinforcements", "")); - cubeCards.add(new CardIdentity("Cenn's Enlistment", "")); - cubeCards.add(new CardIdentity("Genju of the Fields", "")); - cubeCards.add(new CardIdentity("Hyena Umbra", "")); - cubeCards.add(new CardIdentity("Oppressive Rays", "")); - cubeCards.add(new CardIdentity("Shadow Lance", "")); - cubeCards.add(new CardIdentity("Bonds of Faith", "")); - cubeCards.add(new CardIdentity("Ordeal of Heliod", "")); - cubeCards.add(new CardIdentity("Triclopean Sight", "")); - cubeCards.add(new CardIdentity("Cage of Hands", "")); - cubeCards.add(new CardIdentity("Ghostly Prison", "")); - cubeCards.add(new CardIdentity("Security Blockade", "")); - cubeCards.add(new CardIdentity("Faith's Fetters", "")); - cubeCards.add(new CardIdentity("Knightly Valor", "")); - cubeCards.add(new CardIdentity("Hopeful Eidolon", "")); - cubeCards.add(new CardIdentity("Nyx-Fleece Ram", "")); - cubeCards.add(new CardIdentity("Sightless Brawler", "")); - cubeCards.add(new CardIdentity("Archetype of Courage", "")); - cubeCards.add(new CardIdentity("Observant Alseid", "")); - cubeCards.add(new CardIdentity("Heliod's Emissary", "")); - cubeCards.add(new CardIdentity("Cloudfin Raptor", "")); - cubeCards.add(new CardIdentity("Dakra Mystic", "")); - cubeCards.add(new CardIdentity("Drifter il-Dal", "")); - cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); - cubeCards.add(new CardIdentity("Vortex Elemental", "")); - cubeCards.add(new CardIdentity("Aether Figment", "")); - cubeCards.add(new CardIdentity("Dreamscape Artist", "")); - cubeCards.add(new CardIdentity("Frilled Oculus", "")); - cubeCards.add(new CardIdentity("Ghost-Lit Warder", "")); - cubeCards.add(new CardIdentity("Hada Spy Patrol", "")); - cubeCards.add(new CardIdentity("Looter il-Kor", "")); - cubeCards.add(new CardIdentity("Plaxmanta", "")); - cubeCards.add(new CardIdentity("Sigiled Starfish", "")); - cubeCards.add(new CardIdentity("Stitcher's Apprentice", "")); - cubeCards.add(new CardIdentity("Thrummingbird", "")); - cubeCards.add(new CardIdentity("Arctic Aven", "")); - cubeCards.add(new CardIdentity("Brackwater Elemental", "")); - cubeCards.add(new CardIdentity("Civilized Scholar", "")); - cubeCards.add(new CardIdentity("Court Hussar", "")); - cubeCards.add(new CardIdentity("Courtly Provocateur", "")); - cubeCards.add(new CardIdentity("Crackling Triton", "")); - cubeCards.add(new CardIdentity("Deceiver Exarch", "")); - cubeCards.add(new CardIdentity("Drift of Phantasms", "")); - cubeCards.add(new CardIdentity("Fettergeist", "")); - cubeCards.add(new CardIdentity("Frontline Sage", "")); - cubeCards.add(new CardIdentity("Jorubai Murk Lurker", "")); - cubeCards.add(new CardIdentity("Leech Bonder", "")); - cubeCards.add(new CardIdentity("Mistblade Shinobi", "")); - cubeCards.add(new CardIdentity("Neurok Invisimancer", "")); - cubeCards.add(new CardIdentity("Niblis of the Breath", "")); - cubeCards.add(new CardIdentity("Simic Fluxmage", "")); - cubeCards.add(new CardIdentity("Stitched Drake", "")); - cubeCards.add(new CardIdentity("Tandem Lookout", "")); - cubeCards.add(new CardIdentity("Trained Condor", "")); - cubeCards.add(new CardIdentity("Trinket Mage", "")); - cubeCards.add(new CardIdentity("Vedalken Anatomist", "")); - cubeCards.add(new CardIdentity("War-Wing Siren", "")); - cubeCards.add(new CardIdentity("Aerie Worshippers", "")); - cubeCards.add(new CardIdentity("Aven Augur", "")); - cubeCards.add(new CardIdentity("Crookclaw Transmuter", "")); - cubeCards.add(new CardIdentity("Cryptic Annelid", "")); - cubeCards.add(new CardIdentity("Fatestitcher", "")); - cubeCards.add(new CardIdentity("Impaler Shrike", "")); - cubeCards.add(new CardIdentity("Inspired Sprite", "")); - cubeCards.add(new CardIdentity("Mist Raven", "")); - cubeCards.add(new CardIdentity("Nevermaker", "")); - cubeCards.add(new CardIdentity("Ninja of the Deep Hours", "")); - cubeCards.add(new CardIdentity("Phantasmal Dragon", "")); - cubeCards.add(new CardIdentity("Secretkeeper", "")); - cubeCards.add(new CardIdentity("Soratami Savant", "")); - cubeCards.add(new CardIdentity("Water Servant", "")); - cubeCards.add(new CardIdentity("Windrider Eel", "")); - cubeCards.add(new CardIdentity("Wing Splicer", "")); - cubeCards.add(new CardIdentity("Air Servant", "")); - cubeCards.add(new CardIdentity("Helium Squirter", "")); - cubeCards.add(new CardIdentity("Mulldrifter", "")); - cubeCards.add(new CardIdentity("Riftwing Cloudskate", "")); - cubeCards.add(new CardIdentity("Sealock Monster", "")); - cubeCards.add(new CardIdentity("Siren of the Fanged Coast", "")); - cubeCards.add(new CardIdentity("Tidewater Minion", "")); - cubeCards.add(new CardIdentity("Aethersnipe", "")); - cubeCards.add(new CardIdentity("Floodchaser", "")); - cubeCards.add(new CardIdentity("Maze Glider", "")); - cubeCards.add(new CardIdentity("Triton Tactics", "")); - cubeCards.add(new CardIdentity("Essence Scatter", "")); - cubeCards.add(new CardIdentity("Familiar's Ruse", "")); - cubeCards.add(new CardIdentity("Into the Roil", "")); - cubeCards.add(new CardIdentity("Mana Leak", "")); - cubeCards.add(new CardIdentity("Muddle the Mixture", "")); - cubeCards.add(new CardIdentity("Ovinize", "")); - cubeCards.add(new CardIdentity("Spell Rupture", "")); - cubeCards.add(new CardIdentity("Think Twice", "")); - cubeCards.add(new CardIdentity("Dissolve", "")); - cubeCards.add(new CardIdentity("Erratic Mutation", "")); - cubeCards.add(new CardIdentity("Hour of Need", "")); - cubeCards.add(new CardIdentity("Spell Contortion", "")); - cubeCards.add(new CardIdentity("Aetherize", "")); - cubeCards.add(new CardIdentity("Careful Consideration", "")); - cubeCards.add(new CardIdentity("Controvert", "")); - cubeCards.add(new CardIdentity("Mystical Teachings", "")); - cubeCards.add(new CardIdentity("Lost in the Mist", "")); - cubeCards.add(new CardIdentity("Traumatic Visions", "")); - cubeCards.add(new CardIdentity("Vanishment", "")); - cubeCards.add(new CardIdentity("Whiplash Trap", "")); - cubeCards.add(new CardIdentity("Condescend", "")); - cubeCards.add(new CardIdentity("Repeal", "")); - cubeCards.add(new CardIdentity("Logic Knot", "")); - cubeCards.add(new CardIdentity("Serum Visions", "")); - cubeCards.add(new CardIdentity("Hands of Binding", "")); - cubeCards.add(new CardIdentity("Hidden Strings", "")); - cubeCards.add(new CardIdentity("Grasp of Phantoms", "")); - cubeCards.add(new CardIdentity("Mystic Retrieval", "")); - cubeCards.add(new CardIdentity("Tezzeret's Gambit", "")); - cubeCards.add(new CardIdentity("Aqueous Form", "")); - cubeCards.add(new CardIdentity("Genju of the Falls", "")); - cubeCards.add(new CardIdentity("Eel Umbra", "")); - cubeCards.add(new CardIdentity("Military Intelligence", "")); - cubeCards.add(new CardIdentity("Ordeal of Thassa", "")); - cubeCards.add(new CardIdentity("Phantom Wings", "")); - cubeCards.add(new CardIdentity("Stratus Walk", "")); - cubeCards.add(new CardIdentity("Freed from the Real", "")); - cubeCards.add(new CardIdentity("Leaden Fists", "")); - cubeCards.add(new CardIdentity("Bonds of Quicksilver", "")); - cubeCards.add(new CardIdentity("Domestication", "")); - cubeCards.add(new CardIdentity("Flight of Fancy", "")); - cubeCards.add(new CardIdentity("Ocular Halo", "")); - cubeCards.add(new CardIdentity("Crystalline Nautilus", "")); - cubeCards.add(new CardIdentity("Nimbus Naiad", "")); - cubeCards.add(new CardIdentity("Thassa's Emissary", "")); - cubeCards.add(new CardIdentity("Duty-Bound Dead", "")); - cubeCards.add(new CardIdentity("Thrull Parasite", "")); - cubeCards.add(new CardIdentity("Augur of Skulls", "")); - cubeCards.add(new CardIdentity("Basilica Screecher", "")); - cubeCards.add(new CardIdentity("Blind Creeper", "")); - cubeCards.add(new CardIdentity("Blood Artist", "")); - cubeCards.add(new CardIdentity("Disciple of Griselbrand", "")); - cubeCards.add(new CardIdentity("Gatekeeper of Malakir", "")); - cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); - cubeCards.add(new CardIdentity("Onyx Mage", "")); - cubeCards.add(new CardIdentity("Returned Phalanx", "")); - cubeCards.add(new CardIdentity("Arrogant Bloodlord", "")); - cubeCards.add(new CardIdentity("Blind Zealot", "")); - cubeCards.add(new CardIdentity("Bloodflow Connoisseur", "")); - cubeCards.add(new CardIdentity("Bloodhusk Ritualist", "")); - cubeCards.add(new CardIdentity("Deepcavern Imp", "")); - cubeCards.add(new CardIdentity("Demonic Taskmaster", "")); - cubeCards.add(new CardIdentity("Fleshbag Marauder", "")); - cubeCards.add(new CardIdentity("Harbor Bandit", "")); - cubeCards.add(new CardIdentity("Hired Torturer", "")); - cubeCards.add(new CardIdentity("Nirkana Cutthroat", "")); - cubeCards.add(new CardIdentity("Orzhov Euthanist", "")); - cubeCards.add(new CardIdentity("Pawn of Ulamog", "")); - cubeCards.add(new CardIdentity("Phyrexian Rager", "")); - cubeCards.add(new CardIdentity("Screeching Bat", "")); - cubeCards.add(new CardIdentity("Servant of Tymaret", "")); - cubeCards.add(new CardIdentity("Sewer Shambler", "")); - cubeCards.add(new CardIdentity("Stinkweed Imp", "")); - cubeCards.add(new CardIdentity("Undercity Informer", "")); - cubeCards.add(new CardIdentity("Wakedancer", "")); - cubeCards.add(new CardIdentity("Xathrid Slyblade", "")); - cubeCards.add(new CardIdentity("Corpse Traders", "")); - cubeCards.add(new CardIdentity("Crypt Champion", "")); - cubeCards.add(new CardIdentity("Dimir House Guard", "")); - cubeCards.add(new CardIdentity("Entomber Exarch", "")); - cubeCards.add(new CardIdentity("Falkenrath Noble", "")); - cubeCards.add(new CardIdentity("Final-Sting Faerie", "")); - cubeCards.add(new CardIdentity("Fleshwrither", "")); - cubeCards.add(new CardIdentity("Forlorn Pseudamma", "")); - cubeCards.add(new CardIdentity("Heartstabber Mosquito", "")); - cubeCards.add(new CardIdentity("Marsh Flitter", "")); - cubeCards.add(new CardIdentity("Mortis Dogs", "")); - cubeCards.add(new CardIdentity("Nightshade Assassin", "")); - cubeCards.add(new CardIdentity("Perilous Shadow", "")); - cubeCards.add(new CardIdentity("Scavenger Drake", "")); - cubeCards.add(new CardIdentity("Skinrender", "")); - cubeCards.add(new CardIdentity("Slum Reaper", "")); - cubeCards.add(new CardIdentity("Soul Snuffers", "")); - cubeCards.add(new CardIdentity("Vampire Outcasts", "")); - cubeCards.add(new CardIdentity("Viscera Dragger", "")); - cubeCards.add(new CardIdentity("Gray Merchant of Asphodel", "")); - cubeCards.add(new CardIdentity("Keepsake Gorgon", "")); - cubeCards.add(new CardIdentity("Morkrut Banshee", "")); - cubeCards.add(new CardIdentity("Nightfire Giant", "")); - cubeCards.add(new CardIdentity("Revenant Patriarch", "")); - cubeCards.add(new CardIdentity("Shriekmaw", "")); - cubeCards.add(new CardIdentity("Shrike Harpy", "")); - cubeCards.add(new CardIdentity("Throat Slitter", "")); - cubeCards.add(new CardIdentity("Grixis Slavedriver", "")); - cubeCards.add(new CardIdentity("Twisted Abomination", "")); - cubeCards.add(new CardIdentity("Terrus Wurm", "")); - cubeCards.add(new CardIdentity("Darkblast", "")); - cubeCards.add(new CardIdentity("Tragic Slip", "")); - cubeCards.add(new CardIdentity("Undying Evil", "")); - cubeCards.add(new CardIdentity("Virulent Swipe", "")); - cubeCards.add(new CardIdentity("Cradle to Grave", "")); - cubeCards.add(new CardIdentity("Devour Flesh", "")); - cubeCards.add(new CardIdentity("Grim Harvest", "")); - cubeCards.add(new CardIdentity("Necrobite", "")); - cubeCards.add(new CardIdentity("Strangling Soot", "")); - cubeCards.add(new CardIdentity("Tomb Hex", "")); - cubeCards.add(new CardIdentity("Makeshift Mannequin", "")); - cubeCards.add(new CardIdentity("Death Denied", "")); - cubeCards.add(new CardIdentity("Deadly Allure", "")); - cubeCards.add(new CardIdentity("Cruel Edict", "")); - cubeCards.add(new CardIdentity("Premature Burial", "")); - cubeCards.add(new CardIdentity("Smallpox", "")); - cubeCards.add(new CardIdentity("Asphyxiate", "")); - cubeCards.add(new CardIdentity("Assassinate", "")); - cubeCards.add(new CardIdentity("Beseech the Queen", "")); - cubeCards.add(new CardIdentity("Dead Reckoning", "")); - cubeCards.add(new CardIdentity("Dimir Machinations", "")); - cubeCards.add(new CardIdentity("Drown in Sorrow", "")); - cubeCards.add(new CardIdentity("Ichor Slick", "")); - cubeCards.add(new CardIdentity("Read the Bones", "")); - cubeCards.add(new CardIdentity("Syphon Life", "")); - cubeCards.add(new CardIdentity("Barter in Blood", "")); - cubeCards.add(new CardIdentity("Diabolic Tutor", "")); - cubeCards.add(new CardIdentity("Moan of the Unhallowed", "")); - cubeCards.add(new CardIdentity("Vigor Mortis", "")); - cubeCards.add(new CardIdentity("Incremental Blight", "")); - cubeCards.add(new CardIdentity("Ribbons of Night", "")); - cubeCards.add(new CardIdentity("Unburial Rites", "")); - cubeCards.add(new CardIdentity("Absorb Vis", "")); - cubeCards.add(new CardIdentity("Genju of the Fens", "")); - cubeCards.add(new CardIdentity("Quest for the Gravelord", "")); - cubeCards.add(new CardIdentity("Soul Stair Expedition", "")); - cubeCards.add(new CardIdentity("Grave Peril", "")); - cubeCards.add(new CardIdentity("Ordeal of Erebos", "")); - cubeCards.add(new CardIdentity("Yoke of the Damned", "")); - cubeCards.add(new CardIdentity("Fallen Ideal", "")); - cubeCards.add(new CardIdentity("Stab Wound", "")); - cubeCards.add(new CardIdentity("Witch's Mist", "")); - cubeCards.add(new CardIdentity("Brink of Disaster", "")); - cubeCards.add(new CardIdentity("Strands of Undeath", "")); - cubeCards.add(new CardIdentity("Homicidal Seclusion", "")); - cubeCards.add(new CardIdentity("Gnarled Scarhide", "")); - cubeCards.add(new CardIdentity("Baleful Eidolon", "")); - cubeCards.add(new CardIdentity("Spiteful Returned", "")); - cubeCards.add(new CardIdentity("Erebos's Emissary", "")); - cubeCards.add(new CardIdentity("Frenzied Goblin", "")); - cubeCards.add(new CardIdentity("Goblin Bushwhacker", "")); - cubeCards.add(new CardIdentity("Jackal Familiar", "")); - cubeCards.add(new CardIdentity("Reckless Waif", "")); - cubeCards.add(new CardIdentity("Skitter of Lizards", "")); - cubeCards.add(new CardIdentity("Stonewright", "")); - cubeCards.add(new CardIdentity("Altac Bloodseeker", "")); - cubeCards.add(new CardIdentity("Bomber Corps", "")); - cubeCards.add(new CardIdentity("Crimson Muckwader", "")); - cubeCards.add(new CardIdentity("Deathbellow Raider", "")); - cubeCards.add(new CardIdentity("Falkenrath Exterminator", "")); - cubeCards.add(new CardIdentity("Generator Servant", "")); - cubeCards.add(new CardIdentity("Goblin Wardriver", "")); - cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); - cubeCards.add(new CardIdentity("Kruin Striker", "")); - cubeCards.add(new CardIdentity("Lightning Mauler", "")); - cubeCards.add(new CardIdentity("Mogg War Marshal", "")); - cubeCards.add(new CardIdentity("Plated Geopede", "")); - cubeCards.add(new CardIdentity("Skinbrand Goblin", "")); - cubeCards.add(new CardIdentity("Stingscourger", "")); - cubeCards.add(new CardIdentity("Stormblood Berserker", "")); - cubeCards.add(new CardIdentity("Blisterstick Shaman", "")); - cubeCards.add(new CardIdentity("Blood Ogre", "")); - cubeCards.add(new CardIdentity("Dragon Egg", "")); - cubeCards.add(new CardIdentity("Flamewave Invoker", "")); - cubeCards.add(new CardIdentity("Ghost-Lit Raider", "")); - cubeCards.add(new CardIdentity("Hanweir Watchkeep", "")); - cubeCards.add(new CardIdentity("Inner-Flame Acolyte", "")); - cubeCards.add(new CardIdentity("Kessig Wolf", "")); - cubeCards.add(new CardIdentity("Pyreheart Wolf", "")); - cubeCards.add(new CardIdentity("Satyr Nyx-Smith", "")); - cubeCards.add(new CardIdentity("Sparkspitter", "")); - cubeCards.add(new CardIdentity("Stormcaller of Keranos", "")); - cubeCards.add(new CardIdentity("Thunder-Thrash Elder", "")); - cubeCards.add(new CardIdentity("Torch Slinger", "")); - cubeCards.add(new CardIdentity("Vithian Stinger", "")); - cubeCards.add(new CardIdentity("Changeling Berserker", "")); - cubeCards.add(new CardIdentity("Cinder Elemental", "")); - cubeCards.add(new CardIdentity("Flame-Kin War Scout", "")); - cubeCards.add(new CardIdentity("Gorehorn Minotaurs", "")); - cubeCards.add(new CardIdentity("Havengul Vampire", "")); - cubeCards.add(new CardIdentity("Henchfiend of Ukor", "")); - cubeCards.add(new CardIdentity("Ill-Tempered Cyclops", "")); - cubeCards.add(new CardIdentity("Kird Chieftain", "")); - cubeCards.add(new CardIdentity("Mad Prophet", "")); - cubeCards.add(new CardIdentity("Rubblebelt Maaka", "")); - cubeCards.add(new CardIdentity("Skirsdag Cultist", "")); - cubeCards.add(new CardIdentity("Thorn-Thrash Viashino", "")); - cubeCards.add(new CardIdentity("Tormentor Exarch", "")); - cubeCards.add(new CardIdentity("Viashino Shanktail", "")); - cubeCards.add(new CardIdentity("Akroan Conscriptor", "")); - cubeCards.add(new CardIdentity("Emrakul's Hatcher", "")); - cubeCards.add(new CardIdentity("Geyser Glider", "")); - cubeCards.add(new CardIdentity("Glarewielder", "")); - cubeCards.add(new CardIdentity("Pharagax Giant", "")); - cubeCards.add(new CardIdentity("Scourge Devil", "")); - cubeCards.add(new CardIdentity("Stoneshock Giant", "")); - cubeCards.add(new CardIdentity("Towering Thunderfist", "")); - cubeCards.add(new CardIdentity("Firemaw Kavu", "")); - cubeCards.add(new CardIdentity("Greater Stone Spirit", "")); - cubeCards.add(new CardIdentity("Spitebellows", "")); - cubeCards.add(new CardIdentity("Boldwyr Intimidator", "")); - cubeCards.add(new CardIdentity("Ridge Rannet", "")); - cubeCards.add(new CardIdentity("Burst Lightning", "")); - cubeCards.add(new CardIdentity("Coordinated Assault", "")); - cubeCards.add(new CardIdentity("Titan's Strength", "")); - cubeCards.add(new CardIdentity("Weapon Surge", "")); - cubeCards.add(new CardIdentity("Burning Oil", "")); - cubeCards.add(new CardIdentity("Magma Jet", "")); - cubeCards.add(new CardIdentity("Searing Blaze", "")); - cubeCards.add(new CardIdentity("Barbed Lightning", "")); - cubeCards.add(new CardIdentity("Brimstone Volley", "")); - cubeCards.add(new CardIdentity("Staggershock", "")); - cubeCards.add(new CardIdentity("Volt Charge", "")); - cubeCards.add(new CardIdentity("Grab the Reins", "")); - cubeCards.add(new CardIdentity("Inferno Trap", "")); - cubeCards.add(new CardIdentity("Act of Aggression", "")); - cubeCards.add(new CardIdentity("Fiery Fall", "")); - cubeCards.add(new CardIdentity("Flash Conscription", "")); - cubeCards.add(new CardIdentity("Street Spasm", "")); - cubeCards.add(new CardIdentity("Thunderous Wrath", "")); - cubeCards.add(new CardIdentity("Forked Bolt", "")); - cubeCards.add(new CardIdentity("Arc Trail", "")); - cubeCards.add(new CardIdentity("Nightbird's Clutches", "")); - cubeCards.add(new CardIdentity("Pyroclasm", "")); - cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); - cubeCards.add(new CardIdentity("Rift Bolt", "")); - cubeCards.add(new CardIdentity("Rolling Temblor", "")); - cubeCards.add(new CardIdentity("Thatcher Revolt", "")); - cubeCards.add(new CardIdentity("Burn Trail", "")); - cubeCards.add(new CardIdentity("Rivals' Duel", "")); - cubeCards.add(new CardIdentity("Cone of Flame", "")); - cubeCards.add(new CardIdentity("Fireball", "")); - cubeCards.add(new CardIdentity("Dragon Mantle", "")); - cubeCards.add(new CardIdentity("Genju of the Spires", "")); - cubeCards.add(new CardIdentity("Hammerhand", "")); - cubeCards.add(new CardIdentity("Circle of Flame", "")); - cubeCards.add(new CardIdentity("Emblem of the Warmind", "")); - cubeCards.add(new CardIdentity("Madcap Skills", "")); - cubeCards.add(new CardIdentity("Ordeal of Purphoros", "")); - cubeCards.add(new CardIdentity("Pursuit of Flight", "")); - cubeCards.add(new CardIdentity("Zektar Shrine Expedition", "")); - cubeCards.add(new CardIdentity("Fatal Attraction", "")); - cubeCards.add(new CardIdentity("Fearsome Temper", "")); - cubeCards.add(new CardIdentity("Galvanic Arc", "")); - cubeCards.add(new CardIdentity("Hypervolt Grasp", "")); - cubeCards.add(new CardIdentity("Lust for War", "")); - cubeCards.add(new CardIdentity("Everflame Eidolon", "")); - cubeCards.add(new CardIdentity("Mogis's Warhound", "")); - cubeCards.add(new CardIdentity("Spearpoint Oread", "")); - cubeCards.add(new CardIdentity("Purphoros's Emissary", "")); - cubeCards.add(new CardIdentity("Centaur's Herald", "")); - cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); - cubeCards.add(new CardIdentity("Llanowar Augur", "")); - cubeCards.add(new CardIdentity("Renowned Weaver", "")); - cubeCards.add(new CardIdentity("Sunblade Elf", "")); - cubeCards.add(new CardIdentity("Twinblade Slasher", "")); - cubeCards.add(new CardIdentity("Wasteland Viper", "")); - cubeCards.add(new CardIdentity("Ambush Viper", "")); - cubeCards.add(new CardIdentity("Aquastrand Spider", "")); - cubeCards.add(new CardIdentity("Beastbreaker of Bala Ged", "")); - cubeCards.add(new CardIdentity("Bramblesnap", "")); - cubeCards.add(new CardIdentity("Darkthicket Wolf", "")); - cubeCards.add(new CardIdentity("Dawntreader Elk", "")); - cubeCards.add(new CardIdentity("Death-Hood Cobra", "")); - cubeCards.add(new CardIdentity("Flinthoof Boar", "")); - cubeCards.add(new CardIdentity("Gatstaf Shepherd", "")); - cubeCards.add(new CardIdentity("Gnarlid Pack", "")); - cubeCards.add(new CardIdentity("Nest Invader", "")); - cubeCards.add(new CardIdentity("Nightshade Peddler", "")); - cubeCards.add(new CardIdentity("River Boa", "")); - cubeCards.add(new CardIdentity("Shinen of Life's Roar", "")); - cubeCards.add(new CardIdentity("Agent of Horizons", "")); - cubeCards.add(new CardIdentity("Awakener Druid", "")); - cubeCards.add(new CardIdentity("Citanul Woodreaders", "")); - cubeCards.add(new CardIdentity("Crocanura", "")); - cubeCards.add(new CardIdentity("Ghost-Lit Nourisher", "")); - cubeCards.add(new CardIdentity("Gluttonous Slime", "")); - cubeCards.add(new CardIdentity("Hedge Troll", "")); - cubeCards.add(new CardIdentity("Lambholt Elder", "")); - cubeCards.add(new CardIdentity("Rootwalla", "")); - cubeCards.add(new CardIdentity("Slaughterhorn", "")); - cubeCards.add(new CardIdentity("Stonefare Crocodile", "")); - cubeCards.add(new CardIdentity("Thornscape Battlemage", "")); - cubeCards.add(new CardIdentity("Trusted Forcemage", "")); - cubeCards.add(new CardIdentity("Turntimber Basilisk", "")); - cubeCards.add(new CardIdentity("Ulvenwald Bear", "")); - cubeCards.add(new CardIdentity("Villagers of Estwald", "")); - cubeCards.add(new CardIdentity("Wolfir Avenger", "")); - cubeCards.add(new CardIdentity("Briarhorn", "")); - cubeCards.add(new CardIdentity("Druid's Familiar", "")); - cubeCards.add(new CardIdentity("Drumhunter", "")); - cubeCards.add(new CardIdentity("Festerhide Boar", "")); - cubeCards.add(new CardIdentity("Golgari Decoy", "")); - cubeCards.add(new CardIdentity("Graverobber Spider", "")); - cubeCards.add(new CardIdentity("Kavu Primarch", "")); - cubeCards.add(new CardIdentity("Kozilek's Predator", "")); - cubeCards.add(new CardIdentity("Masked Admirers", "")); - cubeCards.add(new CardIdentity("Patagia Viper", "")); - cubeCards.add(new CardIdentity("Penumbra Spider", "")); - cubeCards.add(new CardIdentity("Pouncing Wurm", "")); - cubeCards.add(new CardIdentity("Scab-Clan Charger", "")); - cubeCards.add(new CardIdentity("Swarmborn Giant", "")); - cubeCards.add(new CardIdentity("Thrashing Mossdog", "")); - cubeCards.add(new CardIdentity("Vital Splicer", "")); - cubeCards.add(new CardIdentity("Acidic Slime", "")); - cubeCards.add(new CardIdentity("Durkwood Tracker", "")); - cubeCards.add(new CardIdentity("Grizzled Outcasts", "")); - cubeCards.add(new CardIdentity("Nessian Asp", "")); - cubeCards.add(new CardIdentity("Snake of the Golden Grove", "")); - cubeCards.add(new CardIdentity("Somberwald Spider", "")); - cubeCards.add(new CardIdentity("Durkwood Baloth", "")); - cubeCards.add(new CardIdentity("Pathbreaker Wurm", "")); - cubeCards.add(new CardIdentity("Pheres-Band Raiders", "")); - cubeCards.add(new CardIdentity("Jungle Weaver", "")); - cubeCards.add(new CardIdentity("Thundering Tanadon", "")); - cubeCards.add(new CardIdentity("Groundswell", "")); - cubeCards.add(new CardIdentity("Hunger of the Howlpack", "")); - cubeCards.add(new CardIdentity("Vines of Vastwood", "")); - cubeCards.add(new CardIdentity("Earthbrawn", "")); - cubeCards.add(new CardIdentity("Evolution Charm", "")); - cubeCards.add(new CardIdentity("Resize", "")); - cubeCards.add(new CardIdentity("Sprout Swarm", "")); - cubeCards.add(new CardIdentity("Gilt-Leaf Ambush", "")); - cubeCards.add(new CardIdentity("Lace with Moonglove", "")); - cubeCards.add(new CardIdentity("Wild Hunger", "")); - cubeCards.add(new CardIdentity("Baloth Cage Trap", "")); - cubeCards.add(new CardIdentity("Reach of Branches", "")); - cubeCards.add(new CardIdentity("Stand Together", "")); - cubeCards.add(new CardIdentity("Sylvan Bounty", "")); - cubeCards.add(new CardIdentity("Ancient Stirrings", "")); - cubeCards.add(new CardIdentity("Commune with the Gods", "")); - cubeCards.add(new CardIdentity("Edge of Autumn", "")); - cubeCards.add(new CardIdentity("Phytoburst", "")); - cubeCards.add(new CardIdentity("Tracker's Instincts", "")); - cubeCards.add(new CardIdentity("Travel Preparations", "")); - cubeCards.add(new CardIdentity("Journey of Discovery", "")); - cubeCards.add(new CardIdentity("Lead the Stampede", "")); - cubeCards.add(new CardIdentity("Search for Tomorrow", "")); - cubeCards.add(new CardIdentity("Tower Above", "")); - cubeCards.add(new CardIdentity("Fungal Sprouting", "")); - cubeCards.add(new CardIdentity("Hunt the Weak", "")); - cubeCards.add(new CardIdentity("Hunting Triad", "")); - cubeCards.add(new CardIdentity("Blessings of Nature", "")); - cubeCards.add(new CardIdentity("Enlarge", "")); - cubeCards.add(new CardIdentity("Incremental Growth", "")); - cubeCards.add(new CardIdentity("Spider Spawning", "")); - cubeCards.add(new CardIdentity("Genju of the Cedars", "")); - cubeCards.add(new CardIdentity("Fists of Ironwood", "")); - cubeCards.add(new CardIdentity("Lignify", "")); - cubeCards.add(new CardIdentity("Ordeal of Nylea", "")); - cubeCards.add(new CardIdentity("Quest for the Gemblades", "")); - cubeCards.add(new CardIdentity("Quiet Disrepair", "")); - cubeCards.add(new CardIdentity("Utopia Vow", "")); - cubeCards.add(new CardIdentity("Feral Invocation", "")); - cubeCards.add(new CardIdentity("Moldervine Cloak", "")); - cubeCards.add(new CardIdentity("Petrified Plating", "")); - cubeCards.add(new CardIdentity("Snake Umbra", "")); - cubeCards.add(new CardIdentity("Triumph of Ferocity", "")); - cubeCards.add(new CardIdentity("Trollhide", "")); - cubeCards.add(new CardIdentity("Leafcrown Dryad", "")); - cubeCards.add(new CardIdentity("Spirespine", "")); - cubeCards.add(new CardIdentity("Nylea's Emissary", "")); - cubeCards.add(new CardIdentity("Azorius Guildmage", "")); - cubeCards.add(new CardIdentity("Battlewise Hoplite", "")); - cubeCards.add(new CardIdentity("Deputy of Acquittals", "")); - cubeCards.add(new CardIdentity("New Prahv Guildmage", "")); - cubeCards.add(new CardIdentity("Lyev Skyknight", "")); - cubeCards.add(new CardIdentity("Plumeveil", "")); - cubeCards.add(new CardIdentity("Silkbind Faerie", "")); - cubeCards.add(new CardIdentity("Skymark Roc", "")); - cubeCards.add(new CardIdentity("Sky Hussar", "")); - cubeCards.add(new CardIdentity("Shield of the Righteous", "")); - cubeCards.add(new CardIdentity("Azorius Charm", "")); - cubeCards.add(new CardIdentity("Repel Intruders", "")); - cubeCards.add(new CardIdentity("Ephara's Enlightenment", "")); - cubeCards.add(new CardIdentity("Plumes of Peace", "")); - cubeCards.add(new CardIdentity("Dimir Guildmage", "")); - cubeCards.add(new CardIdentity("Dimir Infiltrator", "")); - cubeCards.add(new CardIdentity("Disciple of Deceit", "")); - cubeCards.add(new CardIdentity("Duskmantle Guildmage", "")); - cubeCards.add(new CardIdentity("Inkfathom Witch", "")); - cubeCards.add(new CardIdentity("Shipwreck Singer", "")); - cubeCards.add(new CardIdentity("Wasp Lancer", "")); - cubeCards.add(new CardIdentity("Blizzard Specter", "")); - cubeCards.add(new CardIdentity("Agony Warp", "")); - cubeCards.add(new CardIdentity("Dimir Charm", "")); - cubeCards.add(new CardIdentity("Far // Away", "")); - cubeCards.add(new CardIdentity("Perplex", "")); - cubeCards.add(new CardIdentity("Soul Manipulation", "")); - cubeCards.add(new CardIdentity("Call of the Nightwing", "")); - cubeCards.add(new CardIdentity("River's Grasp", "")); - cubeCards.add(new CardIdentity("Rix Maadi Guildmage", "")); - cubeCards.add(new CardIdentity("Spike Jester", "")); - cubeCards.add(new CardIdentity("Ashenmoor Gouger", "")); - cubeCards.add(new CardIdentity("Hellhole Flailer", "")); - cubeCards.add(new CardIdentity("Kathari Bomber", "")); - cubeCards.add(new CardIdentity("Shambling Remains", "")); - cubeCards.add(new CardIdentity("Carnage Gladiator", "")); - cubeCards.add(new CardIdentity("Murderous Redcap", "")); - cubeCards.add(new CardIdentity("Grief Tyrant", "")); - cubeCards.add(new CardIdentity("Rakdos Charm", "")); - cubeCards.add(new CardIdentity("Bituminous Blast", "")); - cubeCards.add(new CardIdentity("Twinstrike", "")); - cubeCards.add(new CardIdentity("Blightning", "")); - cubeCards.add(new CardIdentity("Torrent of Souls", "")); - cubeCards.add(new CardIdentity("Burning-Tree Emissary", "")); - cubeCards.add(new CardIdentity("Scab-Clan Mauler", "")); - cubeCards.add(new CardIdentity("Skarrg Guildmage", "")); - cubeCards.add(new CardIdentity("Zhur-Taa Druid", "")); - cubeCards.add(new CardIdentity("Boggart Ram-Gang", "")); - cubeCards.add(new CardIdentity("Fanatic of Xenagos", "")); - cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); - cubeCards.add(new CardIdentity("Ghor-Clan Rampager", "")); - cubeCards.add(new CardIdentity("Zhur-Taa Swine", "")); - cubeCards.add(new CardIdentity("Gruul Charm", "")); - cubeCards.add(new CardIdentity("Pit Fight", "")); - cubeCards.add(new CardIdentity("Branching Bolt", "")); - cubeCards.add(new CardIdentity("Armed // Dangerous", "")); - cubeCards.add(new CardIdentity("Firespout", "")); - cubeCards.add(new CardIdentity("Savage Twister", "")); - cubeCards.add(new CardIdentity("Seedcradle Witch", "")); - cubeCards.add(new CardIdentity("Qasali Pridemage", "")); - cubeCards.add(new CardIdentity("Selesnya Evangel", "")); - cubeCards.add(new CardIdentity("Vitu-Ghazi Guildmage", "")); - cubeCards.add(new CardIdentity("Kitchen Finks", "")); - cubeCards.add(new CardIdentity("Qasali Ambusher", "")); - cubeCards.add(new CardIdentity("Wilt-Leaf Cavaliers", "")); - cubeCards.add(new CardIdentity("Juniper Order Ranger", "")); - cubeCards.add(new CardIdentity("Enlisted Wurm", "")); - cubeCards.add(new CardIdentity("Selesnya Charm", "")); - cubeCards.add(new CardIdentity("Sigil Blessing", "")); - cubeCards.add(new CardIdentity("Common Bond", "")); - cubeCards.add(new CardIdentity("Mercy Killing", "")); - cubeCards.add(new CardIdentity("Alive // Well", "")); - cubeCards.add(new CardIdentity("Sigil of the Nayan Gods", "")); - cubeCards.add(new CardIdentity("Cartel Aristocrat", "")); - cubeCards.add(new CardIdentity("Tithe Drinker", "")); - cubeCards.add(new CardIdentity("Vizkopa Guildmage", "")); - cubeCards.add(new CardIdentity("Gwyllion Hedge-Mage", "")); - cubeCards.add(new CardIdentity("Kingpin's Pet", "")); - cubeCards.add(new CardIdentity("Restless Apparition", "")); - cubeCards.add(new CardIdentity("Blind Hunter", "")); - cubeCards.add(new CardIdentity("Harvest Gwyllion", "")); - cubeCards.add(new CardIdentity("Sentry of the Underworld", "")); - cubeCards.add(new CardIdentity("Tidehollow Sculler", "")); - cubeCards.add(new CardIdentity("Cauldron Haze", "")); - cubeCards.add(new CardIdentity("Executioner's Swing", "")); - cubeCards.add(new CardIdentity("Orzhov Charm", "")); - cubeCards.add(new CardIdentity("Profit // Loss", "")); - cubeCards.add(new CardIdentity("Zealous Persecution", "")); - cubeCards.add(new CardIdentity("Korozda Guildmage", "")); - cubeCards.add(new CardIdentity("Putrid Leech", "")); - cubeCards.add(new CardIdentity("Dreg Mangler", "")); - cubeCards.add(new CardIdentity("Shambling Shell", "")); - cubeCards.add(new CardIdentity("Trestle Troll", "")); - cubeCards.add(new CardIdentity("Canker Abomination", "")); - cubeCards.add(new CardIdentity("Desecrator Hag", "")); - cubeCards.add(new CardIdentity("Sluiceway Scorpion", "")); - cubeCards.add(new CardIdentity("Marrow Chomper", "")); - cubeCards.add(new CardIdentity("Golgari Charm", "")); - cubeCards.add(new CardIdentity("Cankerous Thirst", "")); - cubeCards.add(new CardIdentity("Down // Dirty", "")); - cubeCards.add(new CardIdentity("Worm Harvest", "")); - cubeCards.add(new CardIdentity("Necrogenesis", "")); - cubeCards.add(new CardIdentity("Nyx Weaver", "")); - cubeCards.add(new CardIdentity("Coiling Oracle", "")); - cubeCards.add(new CardIdentity("Kiora's Follower", "")); - cubeCards.add(new CardIdentity("Zameck Guildmage", "")); - cubeCards.add(new CardIdentity("Beetleform Mage", "")); - cubeCards.add(new CardIdentity("Gilder Bairn", "")); - cubeCards.add(new CardIdentity("Lorescale Coatl", "")); - cubeCards.add(new CardIdentity("Plaxcaster Frogling", "")); - cubeCards.add(new CardIdentity("Selkie Hedge-Mage", "")); - cubeCards.add(new CardIdentity("Wistful Selkie", "")); - cubeCards.add(new CardIdentity("Horizon Chimera", "")); - cubeCards.add(new CardIdentity("Fleetfeather Cockatrice", "")); - cubeCards.add(new CardIdentity("Simic Charm", "")); - cubeCards.add(new CardIdentity("Snakeform", "")); - cubeCards.add(new CardIdentity("Give // Take", "")); - cubeCards.add(new CardIdentity("Leafdrake Roost", "")); - cubeCards.add(new CardIdentity("Frostburn Weird", "")); - cubeCards.add(new CardIdentity("Goblin Electromancer", "")); - cubeCards.add(new CardIdentity("Nivix Guildmage", "")); - cubeCards.add(new CardIdentity("Crag Puca", "")); - cubeCards.add(new CardIdentity("Gelectrode", "")); - cubeCards.add(new CardIdentity("Izzet Staticaster", "")); - cubeCards.add(new CardIdentity("Nivix Cyclops", "")); - cubeCards.add(new CardIdentity("Fluxcharger", "")); - cubeCards.add(new CardIdentity("Shrewd Hatchling", "")); - cubeCards.add(new CardIdentity("Nucklavee", "")); - cubeCards.add(new CardIdentity("Izzet Charm", "")); - cubeCards.add(new CardIdentity("Swerve", "")); - cubeCards.add(new CardIdentity("Turn // Burn", "")); - cubeCards.add(new CardIdentity("Electrolyze", "")); - cubeCards.add(new CardIdentity("Blast of Genius", "")); - cubeCards.add(new CardIdentity("Boros Guildmage", "")); - cubeCards.add(new CardIdentity("Stun Sniper", "")); - cubeCards.add(new CardIdentity("Sunhome Guildmage", "")); - cubeCards.add(new CardIdentity("Truefire Paladin", "")); - cubeCards.add(new CardIdentity("Wojek Halberdiers", "")); - cubeCards.add(new CardIdentity("Skyknight Legionnaire", "")); - cubeCards.add(new CardIdentity("Viashino Firstblade", "")); - cubeCards.add(new CardIdentity("Spitemare", "")); - cubeCards.add(new CardIdentity("Wear // Tear", "")); - cubeCards.add(new CardIdentity("Boros Charm", "")); - cubeCards.add(new CardIdentity("Martial Glory", "")); - cubeCards.add(new CardIdentity("Arrows of Justice", "")); - cubeCards.add(new CardIdentity("Fire at Will", "")); - cubeCards.add(new CardIdentity("Intimidation Bolt", "")); - cubeCards.add(new CardIdentity("Warleader's Helix", "")); - cubeCards.add(new CardIdentity("Chronomaton", "")); - cubeCards.add(new CardIdentity("Whispergear Sneak", "")); - cubeCards.add(new CardIdentity("Agent of Acquisitions", "")); - cubeCards.add(new CardIdentity("Wall of Tanglecord", "")); - cubeCards.add(new CardIdentity("Burnished Hart", "")); - cubeCards.add(new CardIdentity("Cogwork Spy", "")); - cubeCards.add(new CardIdentity("Gargoyle Sentinel", "")); - cubeCards.add(new CardIdentity("Moriok Replica", "")); - cubeCards.add(new CardIdentity("Cogwork Librarian", "")); - cubeCards.add(new CardIdentity("Paradise Mantle", "")); - cubeCards.add(new CardIdentity("Aether Vial", "")); - cubeCards.add(new CardIdentity("Bonesplitter", "")); - cubeCards.add(new CardIdentity("Infiltration Lens", "")); - cubeCards.add(new CardIdentity("O-Naginata", "")); - cubeCards.add(new CardIdentity("Pyrite Spellbomb", "")); - cubeCards.add(new CardIdentity("Sensei's Divining Top", "")); - cubeCards.add(new CardIdentity("Shuriken", "")); - cubeCards.add(new CardIdentity("Traveler's Amulet", "")); - cubeCards.add(new CardIdentity("Wayfarer's Bauble", "")); - cubeCards.add(new CardIdentity("Banshee's Blade", "")); - cubeCards.add(new CardIdentity("Contagion Clasp", "")); - cubeCards.add(new CardIdentity("Glint Hawk Idol", "")); - cubeCards.add(new CardIdentity("Gorgon Flail", "")); - cubeCards.add(new CardIdentity("Mortarpod", "")); - cubeCards.add(new CardIdentity("Prismatic Lens", "")); - cubeCards.add(new CardIdentity("Prophetic Prism", "")); - cubeCards.add(new CardIdentity("Ring of Evos Isle", "")); - cubeCards.add(new CardIdentity("Ring of Kalonia", "")); - cubeCards.add(new CardIdentity("Ring of Thune", "")); - cubeCards.add(new CardIdentity("Ring of Valkas", "")); - cubeCards.add(new CardIdentity("Ring of Xathrid", "")); - cubeCards.add(new CardIdentity("Azorius Keyrune", "")); - cubeCards.add(new CardIdentity("Boros Keyrune", "")); - cubeCards.add(new CardIdentity("Chronatog Totem", "")); - cubeCards.add(new CardIdentity("Crystal Shard", "")); - cubeCards.add(new CardIdentity("Dimir Keyrune", "")); - cubeCards.add(new CardIdentity("Foriysian Totem", "")); - cubeCards.add(new CardIdentity("Golgari Keyrune", "")); - cubeCards.add(new CardIdentity("Grafted Wargear", "")); - cubeCards.add(new CardIdentity("Gruul Keyrune", "")); - cubeCards.add(new CardIdentity("Izzet Keyrune", "")); - cubeCards.add(new CardIdentity("Orzhov Keyrune", "")); - cubeCards.add(new CardIdentity("Phyrexian Totem", "")); - cubeCards.add(new CardIdentity("Rakdos Keyrune", "")); - cubeCards.add(new CardIdentity("Selesnya Keyrune", "")); - cubeCards.add(new CardIdentity("Sickleslicer", "")); - cubeCards.add(new CardIdentity("Simic Keyrune", "")); - cubeCards.add(new CardIdentity("Strider Harness", "")); - cubeCards.add(new CardIdentity("Thunder Totem", "")); - cubeCards.add(new CardIdentity("Tumble Magnet", "")); - cubeCards.add(new CardIdentity("Weatherseed Totem", "")); - cubeCards.add(new CardIdentity("Serrated Arrows", "")); - cubeCards.add(new CardIdentity("Skinwing", "")); - cubeCards.add(new CardIdentity("Strandwalker", "")); - cubeCards.add(new CardIdentity("Azorius Chancery", "")); - cubeCards.add(new CardIdentity("Azorius Guildgate", "")); - cubeCards.add(new CardIdentity("Bant Panorama", "")); - cubeCards.add(new CardIdentity("Boros Garrison", "")); - cubeCards.add(new CardIdentity("Boros Guildgate", "")); - cubeCards.add(new CardIdentity("Dimir Aqueduct", "")); - cubeCards.add(new CardIdentity("Dimir Guildgate", "")); - cubeCards.add(new CardIdentity("Dread Statuary", "")); - cubeCards.add(new CardIdentity("Esper Panorama", "")); - cubeCards.add(new CardIdentity("Faerie Conclave", "")); - cubeCards.add(new CardIdentity("Forbidding Watchtower", "")); - cubeCards.add(new CardIdentity("Ghitu Encampment", "")); - cubeCards.add(new CardIdentity("Golgari Guildgate", "")); - cubeCards.add(new CardIdentity("Golgari Rot Farm", "")); - cubeCards.add(new CardIdentity("Grixis Panorama", "")); - cubeCards.add(new CardIdentity("Gruul Guildgate", "")); - cubeCards.add(new CardIdentity("Gruul Turf", "")); - cubeCards.add(new CardIdentity("Izzet Boilerworks", "")); - cubeCards.add(new CardIdentity("Izzet Guildgate", "")); - cubeCards.add(new CardIdentity("Jund Panorama", "")); - cubeCards.add(new CardIdentity("Mirrodin's Core", "")); - cubeCards.add(new CardIdentity("Naya Panorama", "")); - cubeCards.add(new CardIdentity("Orzhov Basilica", "")); - cubeCards.add(new CardIdentity("Orzhov Guildgate", "")); - cubeCards.add(new CardIdentity("Rakdos Carnarium", "")); - cubeCards.add(new CardIdentity("Rakdos Guildgate", "")); - cubeCards.add(new CardIdentity("Selesnya Guildgate", "")); - cubeCards.add(new CardIdentity("Selesnya Sanctuary", "")); - cubeCards.add(new CardIdentity("Shimmering Grotto", "")); - cubeCards.add(new CardIdentity("Simic Growth Chamber", "")); - cubeCards.add(new CardIdentity("Simic Guildgate", "")); - cubeCards.add(new CardIdentity("Spawning Pool", "")); - cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); - cubeCards.add(new CardIdentity("Transguild Promenade", "")); - cubeCards.add(new CardIdentity("Treetop Village", "")); - cubeCards.add(new CardIdentity("Vivid Crag", "")); - cubeCards.add(new CardIdentity("Vivid Creek", "")); - cubeCards.add(new CardIdentity("Vivid Grove", "")); - cubeCards.add(new CardIdentity("Vivid Marsh", "")); - cubeCards.add(new CardIdentity("Vivid Meadow", "")); - cubeCards.add(new CardIdentity("Brago's Favor", "")); - cubeCards.add(new CardIdentity("Double Stroke", "")); - cubeCards.add(new CardIdentity("Immediate Action", "")); - cubeCards.add(new CardIdentity("Muzzio's Preparations", "")); - cubeCards.add(new CardIdentity("Power Play", "")); - cubeCards.add(new CardIdentity("Unexpected Potential", "")); - - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.tournament.cubes; + +import mage.game.draft.DraftCube; +import mage.game.draft.DraftCube.CardIdentity; + +/** + * Cube taken from http://www.cubetutor.com/viewcube/10358 + * + * @author LevelX2 + */ +public class PeasantsToolboxCube extends DraftCube { + + public PeasantsToolboxCube() { + super("The Peasant's Toolbox"); + cubeCards.add(new CardIdentity("Absorb Vis", "")); + cubeCards.add(new CardIdentity("Accorder Paladin", "")); + cubeCards.add(new CardIdentity("Acidic Slime", "")); + cubeCards.add(new CardIdentity("Act of Aggression", "")); + cubeCards.add(new CardIdentity("Aerie Worshippers", "")); + cubeCards.add(new CardIdentity("AEther Figment", "")); + cubeCards.add(new CardIdentity("AEther Vial", "")); + cubeCards.add(new CardIdentity("AEtherize", "")); + cubeCards.add(new CardIdentity("AEthersnipe", "")); + cubeCards.add(new CardIdentity("Affa Guard Hound", "")); + cubeCards.add(new CardIdentity("Agent of Acquisitions", "")); + cubeCards.add(new CardIdentity("Agent of Horizons", "")); + cubeCards.add(new CardIdentity("Agony Warp", "")); + cubeCards.add(new CardIdentity("Air Servant", "")); + cubeCards.add(new CardIdentity("Akroan Conscriptor", "")); + cubeCards.add(new CardIdentity("Akroan Phalanx", "")); + cubeCards.add(new CardIdentity("Alabaster Mage", "")); + cubeCards.add(new CardIdentity("Alive // Well", "")); + cubeCards.add(new CardIdentity("Altac Bloodseeker", "")); + cubeCards.add(new CardIdentity("Ambush Viper", "")); + cubeCards.add(new CardIdentity("Ancient Stirrings", "")); + cubeCards.add(new CardIdentity("Apex Hawks", "")); + cubeCards.add(new CardIdentity("Aquastrand Spider", "")); + cubeCards.add(new CardIdentity("Aqueous Form", "")); + cubeCards.add(new CardIdentity("Arc Trail", "")); + cubeCards.add(new CardIdentity("Archetype of Courage", "")); + cubeCards.add(new CardIdentity("Arctic Aven", "")); + cubeCards.add(new CardIdentity("Armed // Dangerous", "")); + cubeCards.add(new CardIdentity("Arrogant Bloodlord", "")); + cubeCards.add(new CardIdentity("Arrow Volley Trap", "")); + cubeCards.add(new CardIdentity("Arrows of Justice", "")); + cubeCards.add(new CardIdentity("Ashenmoor Gouger", "")); + cubeCards.add(new CardIdentity("Asphyxiate", "")); + cubeCards.add(new CardIdentity("Assassinate", "")); + cubeCards.add(new CardIdentity("Augur of Skulls", "")); + cubeCards.add(new CardIdentity("Aven Augur", "")); + cubeCards.add(new CardIdentity("Awakener Druid", "")); + cubeCards.add(new CardIdentity("Azorius Arrester", "")); + cubeCards.add(new CardIdentity("Azorius Chancery", "")); + cubeCards.add(new CardIdentity("Azorius Charm", "")); + cubeCards.add(new CardIdentity("Azorius Guildgate", "")); + cubeCards.add(new CardIdentity("Azorius Guildmage", "")); + cubeCards.add(new CardIdentity("Azorius Herald", "")); + cubeCards.add(new CardIdentity("Azorius Keyrune", "")); + cubeCards.add(new CardIdentity("Baleful Eidolon", "")); + cubeCards.add(new CardIdentity("Ballista Squad", "")); + cubeCards.add(new CardIdentity("Baloth Cage Trap", "")); + cubeCards.add(new CardIdentity("Banisher Priest", "")); + cubeCards.add(new CardIdentity("Banishing Stroke", "")); + cubeCards.add(new CardIdentity("Banshee's Blade", "")); + cubeCards.add(new CardIdentity("Bant Panorama", "")); + cubeCards.add(new CardIdentity("Barbed Lightning", "")); + cubeCards.add(new CardIdentity("Barter in Blood", "")); + cubeCards.add(new CardIdentity("Basilica Guards", "")); + cubeCards.add(new CardIdentity("Basilica Screecher", "")); + cubeCards.add(new CardIdentity("Battlewise Hoplite", "")); + cubeCards.add(new CardIdentity("Beastbreaker of Bala Ged", "")); + cubeCards.add(new CardIdentity("Beetleform Mage", "")); + cubeCards.add(new CardIdentity("Beseech the Queen", "")); + cubeCards.add(new CardIdentity("Bituminous Blast", "")); + cubeCards.add(new CardIdentity("Blast of Genius", "")); + cubeCards.add(new CardIdentity("Blessings of Nature", "")); + cubeCards.add(new CardIdentity("Blightning", "")); + cubeCards.add(new CardIdentity("Blind Creeper", "")); + cubeCards.add(new CardIdentity("Blind Hunter", "")); + cubeCards.add(new CardIdentity("Blind Zealot", "")); + cubeCards.add(new CardIdentity("Blinding Beam", "")); + cubeCards.add(new CardIdentity("Blisterstick Shaman", "")); + cubeCards.add(new CardIdentity("Blizzard Specter", "")); + cubeCards.add(new CardIdentity("Blood Artist", "")); + cubeCards.add(new CardIdentity("Blood Ogre", "")); + cubeCards.add(new CardIdentity("Bloodbraid Elf", "")); + cubeCards.add(new CardIdentity("Bloodflow Connoisseur", "")); + cubeCards.add(new CardIdentity("Bloodhusk Ritualist", "")); + cubeCards.add(new CardIdentity("Boggart Ram-Gang", "")); + cubeCards.add(new CardIdentity("Boldwyr Intimidator", "")); + cubeCards.add(new CardIdentity("Bomber Corps", "")); + cubeCards.add(new CardIdentity("Bonds of Faith", "")); + cubeCards.add(new CardIdentity("Bonds of Quicksilver", "")); + cubeCards.add(new CardIdentity("Bonesplitter", "")); + cubeCards.add(new CardIdentity("Boros Charm", "")); + cubeCards.add(new CardIdentity("Boros Elite", "")); + cubeCards.add(new CardIdentity("Boros Garrison", "")); + cubeCards.add(new CardIdentity("Boros Guildgate", "")); + cubeCards.add(new CardIdentity("Boros Guildmage", "")); + cubeCards.add(new CardIdentity("Boros Keyrune", "")); + cubeCards.add(new CardIdentity("Brackwater Elemental", "")); + cubeCards.add(new CardIdentity("Brago's Favor", "")); + cubeCards.add(new CardIdentity("Bramblesnap", "")); + cubeCards.add(new CardIdentity("Branching Bolt", "")); + cubeCards.add(new CardIdentity("Briarhorn", "")); + cubeCards.add(new CardIdentity("Brimstone Volley", "")); + cubeCards.add(new CardIdentity("Brink of Disaster", "")); + cubeCards.add(new CardIdentity("Burn Trail", "")); + cubeCards.add(new CardIdentity("Burning Oil", "")); + cubeCards.add(new CardIdentity("Burning-Tree Emissary", "")); + cubeCards.add(new CardIdentity("Burnished Hart", "")); + cubeCards.add(new CardIdentity("Burrenton Bombardier", "")); + cubeCards.add(new CardIdentity("Burst Lightning", "")); + cubeCards.add(new CardIdentity("Cage of Hands", "")); + cubeCards.add(new CardIdentity("Call of the Nightwing", "")); + cubeCards.add(new CardIdentity("Canker Abomination", "")); + cubeCards.add(new CardIdentity("Cankerous Thirst", "")); + cubeCards.add(new CardIdentity("Caravan Escort", "")); + cubeCards.add(new CardIdentity("Careful Consideration", "")); + cubeCards.add(new CardIdentity("Carnage Gladiator", "")); + cubeCards.add(new CardIdentity("Cartel Aristocrat", "")); + cubeCards.add(new CardIdentity("Cauldron Haze", "")); + cubeCards.add(new CardIdentity("Celestial Crusader", "")); + cubeCards.add(new CardIdentity("Celestial Flare", "")); + cubeCards.add(new CardIdentity("Cenn's Enlistment", "")); + cubeCards.add(new CardIdentity("Cenn's Tactician", "")); + cubeCards.add(new CardIdentity("Centaur's Herald", "")); + cubeCards.add(new CardIdentity("Changeling Berserker", "")); + cubeCards.add(new CardIdentity("Chastise", "")); + cubeCards.add(new CardIdentity("Choking Fumes", "")); + cubeCards.add(new CardIdentity("Chronatog Totem", "")); + cubeCards.add(new CardIdentity("Chronomaton", "")); + cubeCards.add(new CardIdentity("Cinder Elemental", "")); + cubeCards.add(new CardIdentity("Circle of Flame", "")); + cubeCards.add(new CardIdentity("Citanul Woodreaders", "")); + cubeCards.add(new CardIdentity("Civilized Scholar", "")); + cubeCards.add(new CardIdentity("Cloistered Youth", "")); + cubeCards.add(new CardIdentity("Cloudfin Raptor", "")); + cubeCards.add(new CardIdentity("Cloudgoat Ranger", "")); + cubeCards.add(new CardIdentity("Cogwork Librarian", "")); + cubeCards.add(new CardIdentity("Cogwork Spy", "")); + cubeCards.add(new CardIdentity("Coiling Oracle", "")); + cubeCards.add(new CardIdentity("Common Bond", "")); + cubeCards.add(new CardIdentity("Commune with the Gods", "")); + cubeCards.add(new CardIdentity("Condescend", "")); + cubeCards.add(new CardIdentity("Cone of Flame", "")); + cubeCards.add(new CardIdentity("Contagion Clasp", "")); + cubeCards.add(new CardIdentity("Controvert", "")); + cubeCards.add(new CardIdentity("Coordinated Assault", "")); + cubeCards.add(new CardIdentity("Corpse Traders", "")); + cubeCards.add(new CardIdentity("Court Hussar", "")); + cubeCards.add(new CardIdentity("Courtly Provocateur", "")); + cubeCards.add(new CardIdentity("Crackling Triton", "")); + cubeCards.add(new CardIdentity("Cradle to Grave", "")); + cubeCards.add(new CardIdentity("Crag Puca", "")); + cubeCards.add(new CardIdentity("Crimson Muckwader", "")); + cubeCards.add(new CardIdentity("Crocanura", "")); + cubeCards.add(new CardIdentity("Crookclaw Transmuter", "")); + cubeCards.add(new CardIdentity("Cruel Edict", "")); + cubeCards.add(new CardIdentity("Crypt Champion", "")); + cubeCards.add(new CardIdentity("Cryptic Annelid", "")); + cubeCards.add(new CardIdentity("Crystal Shard", "")); + cubeCards.add(new CardIdentity("Crystalline Nautilus", "")); + cubeCards.add(new CardIdentity("Dakra Mystic", "")); + cubeCards.add(new CardIdentity("Daring Skyjek", "")); + cubeCards.add(new CardIdentity("Darkblast", "")); + cubeCards.add(new CardIdentity("Darkthicket Wolf", "")); + cubeCards.add(new CardIdentity("Dauntless Onslaught", "")); + cubeCards.add(new CardIdentity("Dauntless River Marshal", "")); + cubeCards.add(new CardIdentity("Dawn Charm", "")); + cubeCards.add(new CardIdentity("Dawnglare Invoker", "")); + cubeCards.add(new CardIdentity("Dawntreader Elk", "")); + cubeCards.add(new CardIdentity("Dead Reckoning", "")); + cubeCards.add(new CardIdentity("Deadly Allure", "")); + cubeCards.add(new CardIdentity("Death Denied", "")); + cubeCards.add(new CardIdentity("Deathbellow Raider", "")); + cubeCards.add(new CardIdentity("Death-Hood Cobra", "")); + cubeCards.add(new CardIdentity("Deceiver Exarch", "")); + cubeCards.add(new CardIdentity("Deepcavern Imp", "")); + cubeCards.add(new CardIdentity("Demonic Taskmaster", "")); + cubeCards.add(new CardIdentity("Deputy of Acquittals", "")); + cubeCards.add(new CardIdentity("Desecrator Hag", "")); + cubeCards.add(new CardIdentity("Devour Flesh", "")); + cubeCards.add(new CardIdentity("Devouring Light", "")); + cubeCards.add(new CardIdentity("Diabolic Tutor", "")); + cubeCards.add(new CardIdentity("Dimir Aqueduct", "")); + cubeCards.add(new CardIdentity("Dimir Charm", "")); + cubeCards.add(new CardIdentity("Dimir Guildgate", "")); + cubeCards.add(new CardIdentity("Dimir Guildmage", "")); + cubeCards.add(new CardIdentity("Dimir House Guard", "")); + cubeCards.add(new CardIdentity("Dimir Infiltrator", "")); + cubeCards.add(new CardIdentity("Dimir Keyrune", "")); + cubeCards.add(new CardIdentity("Dimir Machinations", "")); + cubeCards.add(new CardIdentity("Disciple of Deceit", "")); + cubeCards.add(new CardIdentity("Disciple of Griselbrand", "")); + cubeCards.add(new CardIdentity("Dispense Justice", "")); + cubeCards.add(new CardIdentity("Dissolve", "")); + cubeCards.add(new CardIdentity("Divine Verdict", "")); + cubeCards.add(new CardIdentity("Domestication", "")); + cubeCards.add(new CardIdentity("Double Stroke", "")); + cubeCards.add(new CardIdentity("Down // Dirty", "")); + cubeCards.add(new CardIdentity("Dragon Egg", "")); + cubeCards.add(new CardIdentity("Dragon Mantle", "")); + cubeCards.add(new CardIdentity("Dread Statuary", "")); + cubeCards.add(new CardIdentity("Dreamscape Artist", "")); + cubeCards.add(new CardIdentity("Dreg Mangler", "")); + cubeCards.add(new CardIdentity("Drift of Phantasms", "")); + cubeCards.add(new CardIdentity("Drifter il-Dal", "")); + cubeCards.add(new CardIdentity("Drown in Sorrow", "")); + cubeCards.add(new CardIdentity("Druid's Familiar", "")); + cubeCards.add(new CardIdentity("Drumhunter", "")); + cubeCards.add(new CardIdentity("Durkwood Baloth", "")); + cubeCards.add(new CardIdentity("Durkwood Tracker", "")); + cubeCards.add(new CardIdentity("Duskmantle Guildmage", "")); + cubeCards.add(new CardIdentity("Duty-Bound Dead", "")); + cubeCards.add(new CardIdentity("Earthbrawn", "")); + cubeCards.add(new CardIdentity("Edge of Autumn", "")); + cubeCards.add(new CardIdentity("Eel Umbra", "")); + cubeCards.add(new CardIdentity("Electrolyze", "")); + cubeCards.add(new CardIdentity("Emblem of the Warmind", "")); + cubeCards.add(new CardIdentity("Emrakul's Hatcher", "")); + cubeCards.add(new CardIdentity("Enclave Cryptologist", "")); + cubeCards.add(new CardIdentity("Enlarge", "")); + cubeCards.add(new CardIdentity("Enlisted Wurm", "")); + cubeCards.add(new CardIdentity("Entomber Exarch", "")); + cubeCards.add(new CardIdentity("Ephara's Enlightenment", "")); + cubeCards.add(new CardIdentity("Erebos's Emissary", "")); + cubeCards.add(new CardIdentity("Erratic Mutation", "")); + cubeCards.add(new CardIdentity("Esper Panorama", "")); + cubeCards.add(new CardIdentity("Essence Scatter", "")); + cubeCards.add(new CardIdentity("Everflame Eidolon", "")); + cubeCards.add(new CardIdentity("Evolution Charm", "")); + cubeCards.add(new CardIdentity("Executioner's Swing", "")); + cubeCards.add(new CardIdentity("Faerie Conclave", "")); + cubeCards.add(new CardIdentity("Faith's Fetters", "")); + cubeCards.add(new CardIdentity("Falkenrath Exterminator", "")); + cubeCards.add(new CardIdentity("Falkenrath Noble", "")); + cubeCards.add(new CardIdentity("Fallen Ideal", "")); + cubeCards.add(new CardIdentity("Familiar's Ruse", "")); + cubeCards.add(new CardIdentity("Fanatic of Xenagos", "")); + cubeCards.add(new CardIdentity("Far // Away", "")); + cubeCards.add(new CardIdentity("Fatal Attraction", "")); + cubeCards.add(new CardIdentity("Fatestitcher", "")); + cubeCards.add(new CardIdentity("Fearsome Temper", "")); + cubeCards.add(new CardIdentity("Feral Invocation", "")); + cubeCards.add(new CardIdentity("Festerhide Boar", "")); + cubeCards.add(new CardIdentity("Fettergeist", "")); + cubeCards.add(new CardIdentity("Fiend Hunter", "")); + cubeCards.add(new CardIdentity("Fiery Fall", "")); + cubeCards.add(new CardIdentity("Final-Sting Faerie", "")); + cubeCards.add(new CardIdentity("Fire at Will", "")); + cubeCards.add(new CardIdentity("Fireball", "")); + cubeCards.add(new CardIdentity("Firemaw Kavu", "")); + cubeCards.add(new CardIdentity("Firespout", "")); + cubeCards.add(new CardIdentity("Fists of Ironwood", "")); + cubeCards.add(new CardIdentity("Flame-Kin War Scout", "")); + cubeCards.add(new CardIdentity("Flames of the Firebrand", "")); + cubeCards.add(new CardIdentity("Flamewave Invoker", "")); + cubeCards.add(new CardIdentity("Flash Conscription", "")); + cubeCards.add(new CardIdentity("Fleetfeather Cockatrice", "")); + cubeCards.add(new CardIdentity("Fleshbag Marauder", "")); + cubeCards.add(new CardIdentity("Fleshwrither", "")); + cubeCards.add(new CardIdentity("Flickerwisp", "")); + cubeCards.add(new CardIdentity("Flight of Fancy", "")); + cubeCards.add(new CardIdentity("Flinthoof Boar", "")); + cubeCards.add(new CardIdentity("Floodchaser", "")); + cubeCards.add(new CardIdentity("Fluxcharger", "")); + cubeCards.add(new CardIdentity("Forbidding Watchtower", "")); + cubeCards.add(new CardIdentity("Foriysian Totem", "")); + cubeCards.add(new CardIdentity("Forked Bolt", "")); + cubeCards.add(new CardIdentity("Forlorn Pseudamma", "")); + cubeCards.add(new CardIdentity("Freed from the Real", "")); + cubeCards.add(new CardIdentity("Frenzied Goblin", "")); + cubeCards.add(new CardIdentity("Frilled Oculus", "")); + cubeCards.add(new CardIdentity("Frontline Sage", "")); + cubeCards.add(new CardIdentity("Frostburn Weird", "")); + cubeCards.add(new CardIdentity("Fungal Sprouting", "")); + cubeCards.add(new CardIdentity("Galvanic Arc", "")); + cubeCards.add(new CardIdentity("Gargoyle Sentinel", "")); + cubeCards.add(new CardIdentity("Gatekeeper of Malakir", "")); + cubeCards.add(new CardIdentity("Gatstaf Shepherd", "")); + cubeCards.add(new CardIdentity("Gelectrode", "")); + cubeCards.add(new CardIdentity("Generator Servant", "")); + cubeCards.add(new CardIdentity("Genju of the Cedars", "")); + cubeCards.add(new CardIdentity("Genju of the Falls", "")); + cubeCards.add(new CardIdentity("Genju of the Fens", "")); + cubeCards.add(new CardIdentity("Genju of the Fields", "")); + cubeCards.add(new CardIdentity("Genju of the Spires", "")); + cubeCards.add(new CardIdentity("Geyser Glider", "")); + cubeCards.add(new CardIdentity("Ghitu Encampment", "")); + cubeCards.add(new CardIdentity("Ghor-Clan Rampager", "")); + cubeCards.add(new CardIdentity("Ghost-Lit Nourisher", "")); + cubeCards.add(new CardIdentity("Ghost-Lit Raider", "")); + cubeCards.add(new CardIdentity("Ghost-Lit Redeemer", "")); + cubeCards.add(new CardIdentity("Ghost-Lit Warder", "")); + cubeCards.add(new CardIdentity("Ghostly Prison", "")); + cubeCards.add(new CardIdentity("Gideon's Lawkeeper", "")); + cubeCards.add(new CardIdentity("Gilder Bairn", "")); + cubeCards.add(new CardIdentity("Gilt-Leaf Ambush", "")); + cubeCards.add(new CardIdentity("Give // Take", "")); + cubeCards.add(new CardIdentity("Glarewielder", "")); + cubeCards.add(new CardIdentity("Gleam of Resistance", "")); + cubeCards.add(new CardIdentity("Glimmerpoint Stag", "")); + cubeCards.add(new CardIdentity("Glint Hawk Idol", "")); + cubeCards.add(new CardIdentity("Gluttonous Slime", "")); + cubeCards.add(new CardIdentity("Gnarled Scarhide", "")); + cubeCards.add(new CardIdentity("Gnarlid Pack", "")); + cubeCards.add(new CardIdentity("Goblin Bushwhacker", "")); + cubeCards.add(new CardIdentity("Goblin Electromancer", "")); + cubeCards.add(new CardIdentity("Goblin Wardriver", "")); + cubeCards.add(new CardIdentity("God-Favored General", "")); + cubeCards.add(new CardIdentity("Goldmeadow Lookout", "")); + cubeCards.add(new CardIdentity("Goldnight Commander", "")); + cubeCards.add(new CardIdentity("Golgari Charm", "")); + cubeCards.add(new CardIdentity("Golgari Decoy", "")); + cubeCards.add(new CardIdentity("Golgari Guildgate", "")); + cubeCards.add(new CardIdentity("Golgari Keyrune", "")); + cubeCards.add(new CardIdentity("Golgari Rot Farm", "")); + cubeCards.add(new CardIdentity("Gorehorn Minotaurs", "")); + cubeCards.add(new CardIdentity("Gore-House Chainwalker", "")); + cubeCards.add(new CardIdentity("Gorgon Flail", "")); + cubeCards.add(new CardIdentity("Grab the Reins", "")); + cubeCards.add(new CardIdentity("Grafted Wargear", "")); + cubeCards.add(new CardIdentity("Grasp of Phantoms", "")); + cubeCards.add(new CardIdentity("Grave Peril", "")); + cubeCards.add(new CardIdentity("Graverobber Spider", "")); + cubeCards.add(new CardIdentity("Gray Merchant of Asphodel", "")); + cubeCards.add(new CardIdentity("Greater Stone Spirit", "")); + cubeCards.add(new CardIdentity("Grief Tyrant", "")); + cubeCards.add(new CardIdentity("Grim Harvest", "")); + cubeCards.add(new CardIdentity("Grixis Panorama", "")); + cubeCards.add(new CardIdentity("Grixis Slavedriver", "")); + cubeCards.add(new CardIdentity("Grizzled Outcasts", "")); + cubeCards.add(new CardIdentity("Groundswell", "")); + cubeCards.add(new CardIdentity("Gruul Charm", "")); + cubeCards.add(new CardIdentity("Gruul Guildgate", "")); + cubeCards.add(new CardIdentity("Gruul Keyrune", "")); + cubeCards.add(new CardIdentity("Gruul Turf", "")); + cubeCards.add(new CardIdentity("Gwyllion Hedge-Mage", "")); + cubeCards.add(new CardIdentity("Haazda Snare Squad", "")); + cubeCards.add(new CardIdentity("Hada Spy Patrol", "")); + cubeCards.add(new CardIdentity("Hail of Arrows", "")); + cubeCards.add(new CardIdentity("Hammerhand", "")); + cubeCards.add(new CardIdentity("Hands of Binding", "")); + cubeCards.add(new CardIdentity("Hanweir Watchkeep", "")); + cubeCards.add(new CardIdentity("Harbor Bandit", "")); + cubeCards.add(new CardIdentity("Harm's Way", "")); + cubeCards.add(new CardIdentity("Harvest Gwyllion", "")); + cubeCards.add(new CardIdentity("Havengul Vampire", "")); + cubeCards.add(new CardIdentity("Heartstabber Mosquito", "")); + cubeCards.add(new CardIdentity("Hedge Troll", "")); + cubeCards.add(new CardIdentity("Heliod's Emissary", "")); + cubeCards.add(new CardIdentity("Helium Squirter", "")); + cubeCards.add(new CardIdentity("Hellhole Flailer", "")); + cubeCards.add(new CardIdentity("Henchfiend of Ukor", "")); + cubeCards.add(new CardIdentity("Hidden Strings", "")); + cubeCards.add(new CardIdentity("Hired Torturer", "")); + cubeCards.add(new CardIdentity("Homicidal Seclusion", "")); + cubeCards.add(new CardIdentity("Hopeful Eidolon", "")); + cubeCards.add(new CardIdentity("Horizon Chimera", "")); + cubeCards.add(new CardIdentity("Hour of Need", "")); + cubeCards.add(new CardIdentity("Hunger of the Howlpack", "")); + cubeCards.add(new CardIdentity("Hunt the Weak", "")); + cubeCards.add(new CardIdentity("Hunting Triad", "")); + cubeCards.add(new CardIdentity("Hyena Umbra", "")); + cubeCards.add(new CardIdentity("Hypervolt Grasp", "")); + cubeCards.add(new CardIdentity("Icatian Crier", "")); + cubeCards.add(new CardIdentity("Ichor Slick", "")); + cubeCards.add(new CardIdentity("Ill-Tempered Cyclops", "")); + cubeCards.add(new CardIdentity("Immediate Action", "")); + cubeCards.add(new CardIdentity("Impaler Shrike", "")); + cubeCards.add(new CardIdentity("Incremental Blight", "")); + cubeCards.add(new CardIdentity("Incremental Growth", "")); + cubeCards.add(new CardIdentity("Inferno Trap", "")); + cubeCards.add(new CardIdentity("Infiltration Lens", "")); + cubeCards.add(new CardIdentity("Inkfathom Witch", "")); + cubeCards.add(new CardIdentity("Inner-Flame Acolyte", "")); + cubeCards.add(new CardIdentity("Inspired Sprite", "")); + cubeCards.add(new CardIdentity("Intimidation Bolt", "")); + cubeCards.add(new CardIdentity("Into the Roil", "")); + cubeCards.add(new CardIdentity("Izzet Boilerworks", "")); + cubeCards.add(new CardIdentity("Izzet Charm", "")); + cubeCards.add(new CardIdentity("Izzet Guildgate", "")); + cubeCards.add(new CardIdentity("Izzet Keyrune", "")); + cubeCards.add(new CardIdentity("Izzet Staticaster", "")); + cubeCards.add(new CardIdentity("Jackal Familiar", "")); + cubeCards.add(new CardIdentity("Joraga Treespeaker", "")); + cubeCards.add(new CardIdentity("Jorubai Murk Lurker", "")); + cubeCards.add(new CardIdentity("Journey of Discovery", "")); + cubeCards.add(new CardIdentity("Judge Unworthy", "")); + cubeCards.add(new CardIdentity("Jund Panorama", "")); + cubeCards.add(new CardIdentity("Jungle Weaver", "")); + cubeCards.add(new CardIdentity("Juniper Order Ranger", "")); + cubeCards.add(new CardIdentity("Kabira Vindicator", "")); + cubeCards.add(new CardIdentity("Kabuto Moth", "")); + cubeCards.add(new CardIdentity("Kathari Bomber", "")); + cubeCards.add(new CardIdentity("Kavu Primarch", "")); + cubeCards.add(new CardIdentity("Keepsake Gorgon", "")); + cubeCards.add(new CardIdentity("Kessig Wolf", "")); + cubeCards.add(new CardIdentity("Kingpin's Pet", "")); + cubeCards.add(new CardIdentity("Kiora's Follower", "")); + cubeCards.add(new CardIdentity("Kird Chieftain", "")); + cubeCards.add(new CardIdentity("Kitchen Finks", "")); + cubeCards.add(new CardIdentity("Knight of Cliffhaven", "")); + cubeCards.add(new CardIdentity("Knight of Obligation", "")); + cubeCards.add(new CardIdentity("Knight of the Holy Nimbus", "")); + cubeCards.add(new CardIdentity("Knight of the Skyward Eye", "")); + cubeCards.add(new CardIdentity("Knightly Valor", "")); + cubeCards.add(new CardIdentity("Kor Aeronaut", "")); + cubeCards.add(new CardIdentity("Kor Skyfisher", "")); + cubeCards.add(new CardIdentity("Korozda Guildmage", "")); + cubeCards.add(new CardIdentity("Kozilek's Predator", "")); + cubeCards.add(new CardIdentity("Kruin Striker", "")); + cubeCards.add(new CardIdentity("Lace with Moonglove", "")); + cubeCards.add(new CardIdentity("Lambholt Elder", "")); + cubeCards.add(new CardIdentity("Lapse of Certainty", "")); + cubeCards.add(new CardIdentity("Lead the Stampede", "")); + cubeCards.add(new CardIdentity("Leaden Fists", "")); + cubeCards.add(new CardIdentity("Leafcrown Dryad", "")); + cubeCards.add(new CardIdentity("Leafdrake Roost", "")); + cubeCards.add(new CardIdentity("Leech Bonder", "")); + cubeCards.add(new CardIdentity("Lightkeeper of Emeria", "")); + cubeCards.add(new CardIdentity("Lightning Mauler", "")); + cubeCards.add(new CardIdentity("Lignify", "")); + cubeCards.add(new CardIdentity("Lingering Souls", "")); + cubeCards.add(new CardIdentity("Llanowar Augur", "")); + cubeCards.add(new CardIdentity("Logic Knot", "")); + cubeCards.add(new CardIdentity("Looter il-Kor", "")); + cubeCards.add(new CardIdentity("Lorescale Coatl", "")); + cubeCards.add(new CardIdentity("Lost in the Mist", "")); + cubeCards.add(new CardIdentity("Loyal Pegasus", "")); + cubeCards.add(new CardIdentity("Lust for War", "")); + cubeCards.add(new CardIdentity("Lyev Skyknight", "")); + cubeCards.add(new CardIdentity("Mad Prophet", "")); + cubeCards.add(new CardIdentity("Madcap Skills", "")); + cubeCards.add(new CardIdentity("Magma Jet", "")); + cubeCards.add(new CardIdentity("Makeshift Mannequin", "")); + cubeCards.add(new CardIdentity("Mana Leak", "")); + cubeCards.add(new CardIdentity("Marrow Chomper", "")); + cubeCards.add(new CardIdentity("Marsh Flitter", "")); + cubeCards.add(new CardIdentity("Marshaling Cry", "")); + cubeCards.add(new CardIdentity("Martial Glory", "")); + cubeCards.add(new CardIdentity("Masked Admirers", "")); + cubeCards.add(new CardIdentity("Master Splicer", "")); + cubeCards.add(new CardIdentity("Maze Glider", "")); + cubeCards.add(new CardIdentity("Meadowboon", "")); + cubeCards.add(new CardIdentity("Mercy Killing", "")); + cubeCards.add(new CardIdentity("Military Intelligence", "")); + cubeCards.add(new CardIdentity("Mirrodin's Core", "")); + cubeCards.add(new CardIdentity("Mist Raven", "")); + cubeCards.add(new CardIdentity("Mistblade Shinobi", "")); + cubeCards.add(new CardIdentity("Moan of the Unhallowed", "")); + cubeCards.add(new CardIdentity("Mogg War Marshal", "")); + cubeCards.add(new CardIdentity("Mogis's Warhound", "")); + cubeCards.add(new CardIdentity("Moldervine Cloak", "")); + cubeCards.add(new CardIdentity("Moriok Replica", "")); + cubeCards.add(new CardIdentity("Morkrut Banshee", "")); + cubeCards.add(new CardIdentity("Mortarpod", "")); + cubeCards.add(new CardIdentity("Mortis Dogs", "")); + cubeCards.add(new CardIdentity("Muddle the Mixture", "")); + cubeCards.add(new CardIdentity("Mulldrifter", "")); + cubeCards.add(new CardIdentity("Murderous Redcap", "")); + cubeCards.add(new CardIdentity("Muzzio's Preparations", "")); + cubeCards.add(new CardIdentity("Mystic Retrieval", "")); + cubeCards.add(new CardIdentity("Mystical Teachings", "")); + cubeCards.add(new CardIdentity("Naya Panorama", "")); + cubeCards.add(new CardIdentity("Nearheath Pilgrim", "")); + cubeCards.add(new CardIdentity("Necrobite", "")); + cubeCards.add(new CardIdentity("Necrogenesis", "")); + cubeCards.add(new CardIdentity("Nessian Asp", "")); + cubeCards.add(new CardIdentity("Nest Invader", "")); + cubeCards.add(new CardIdentity("Neurok Invisimancer", "")); + cubeCards.add(new CardIdentity("Nevermaker", "")); + cubeCards.add(new CardIdentity("New Prahv Guildmage", "")); + cubeCards.add(new CardIdentity("Nezumi Graverobber", "")); + cubeCards.add(new CardIdentity("Niblis of the Breath", "")); + cubeCards.add(new CardIdentity("Nightbird's Clutches", "")); + cubeCards.add(new CardIdentity("Nightfire Giant", "")); + cubeCards.add(new CardIdentity("Nightshade Assassin", "")); + cubeCards.add(new CardIdentity("Nightshade Peddler", "")); + cubeCards.add(new CardIdentity("Nimbus Naiad", "")); + cubeCards.add(new CardIdentity("Ninja of the Deep Hours", "")); + cubeCards.add(new CardIdentity("Nirkana Cutthroat", "")); + cubeCards.add(new CardIdentity("Nivix Cyclops", "")); + cubeCards.add(new CardIdentity("Nivix Guildmage", "")); + cubeCards.add(new CardIdentity("Nucklavee", "")); + cubeCards.add(new CardIdentity("Nylea's Emissary", "")); + cubeCards.add(new CardIdentity("Nyx Weaver", "")); + cubeCards.add(new CardIdentity("Nyx-Fleece Ram", "")); + cubeCards.add(new CardIdentity("Observant Alseid", "")); + cubeCards.add(new CardIdentity("Ocular Halo", "")); + cubeCards.add(new CardIdentity("O-Naginata", "")); + cubeCards.add(new CardIdentity("Onyx Mage", "")); + cubeCards.add(new CardIdentity("Oppressive Rays", "")); + cubeCards.add(new CardIdentity("Ordeal of Erebos", "")); + cubeCards.add(new CardIdentity("Ordeal of Heliod", "")); + cubeCards.add(new CardIdentity("Ordeal of Nylea", "")); + cubeCards.add(new CardIdentity("Ordeal of Purphoros", "")); + cubeCards.add(new CardIdentity("Ordeal of Thassa", "")); + cubeCards.add(new CardIdentity("Order of the Golden Cricket", "")); + cubeCards.add(new CardIdentity("Ornitharch", "")); + cubeCards.add(new CardIdentity("Orzhov Basilica", "")); + cubeCards.add(new CardIdentity("Orzhov Charm", "")); + cubeCards.add(new CardIdentity("Orzhov Euthanist", "")); + cubeCards.add(new CardIdentity("Orzhov Guildgate", "")); + cubeCards.add(new CardIdentity("Orzhov Keyrune", "")); + cubeCards.add(new CardIdentity("Otherworldly Journey", "")); + cubeCards.add(new CardIdentity("Ovinize", "")); + cubeCards.add(new CardIdentity("Paradise Mantle", "")); + cubeCards.add(new CardIdentity("Patagia Viper", "")); + cubeCards.add(new CardIdentity("Pathbreaker Wurm", "")); + cubeCards.add(new CardIdentity("Pawn of Ulamog", "")); + cubeCards.add(new CardIdentity("Penumbra Spider", "")); + cubeCards.add(new CardIdentity("Perilous Shadow", "")); + cubeCards.add(new CardIdentity("Perplex", "")); + cubeCards.add(new CardIdentity("Petrified Plating", "")); + cubeCards.add(new CardIdentity("Phantasmal Dragon", "")); + cubeCards.add(new CardIdentity("Phantom Wings", "")); + cubeCards.add(new CardIdentity("Pharagax Giant", "")); + cubeCards.add(new CardIdentity("Pheres-Band Raiders", "")); + cubeCards.add(new CardIdentity("Phyrexian Rager", "")); + cubeCards.add(new CardIdentity("Phyrexian Totem", "")); + cubeCards.add(new CardIdentity("Phytoburst", "")); + cubeCards.add(new CardIdentity("Pit Fight", "")); + cubeCards.add(new CardIdentity("Pitfall Trap", "")); + cubeCards.add(new CardIdentity("Plated Geopede", "")); + cubeCards.add(new CardIdentity("Plaxcaster Frogling", "")); + cubeCards.add(new CardIdentity("Plaxmanta", "")); + cubeCards.add(new CardIdentity("Plumes of Peace", "")); + cubeCards.add(new CardIdentity("Plumeveil", "")); + cubeCards.add(new CardIdentity("Porcelain Legionnaire", "")); + cubeCards.add(new CardIdentity("Pouncing Wurm", "")); + cubeCards.add(new CardIdentity("Power Play", "")); + cubeCards.add(new CardIdentity("Premature Burial", "")); + cubeCards.add(new CardIdentity("Prismatic Lens", "")); + cubeCards.add(new CardIdentity("Prized Elephant", "")); + cubeCards.add(new CardIdentity("Profit // Loss", "")); + cubeCards.add(new CardIdentity("Prophetic Prism", "")); + cubeCards.add(new CardIdentity("Puncturing Light", "")); + cubeCards.add(new CardIdentity("Purphoros's Emissary", "")); + cubeCards.add(new CardIdentity("Pursuit of Flight", "")); + cubeCards.add(new CardIdentity("Putrid Leech", "")); + cubeCards.add(new CardIdentity("Pyreheart Wolf", "")); + cubeCards.add(new CardIdentity("Pyrite Spellbomb", "")); + cubeCards.add(new CardIdentity("Pyroclasm", "")); + cubeCards.add(new CardIdentity("Qasali Ambusher", "")); + cubeCards.add(new CardIdentity("Qasali Pridemage", "")); + cubeCards.add(new CardIdentity("Quest for the Gemblades", "")); + cubeCards.add(new CardIdentity("Quest for the Gravelord", "")); + cubeCards.add(new CardIdentity("Quiet Disrepair", "")); + cubeCards.add(new CardIdentity("Rakdos Carnarium", "")); + cubeCards.add(new CardIdentity("Rakdos Charm", "")); + cubeCards.add(new CardIdentity("Rakdos Guildgate", "")); + cubeCards.add(new CardIdentity("Rakdos Keyrune", "")); + cubeCards.add(new CardIdentity("Rally the Peasants", "")); + cubeCards.add(new CardIdentity("Reach of Branches", "")); + cubeCards.add(new CardIdentity("Read the Bones", "")); + cubeCards.add(new CardIdentity("Reciprocate", "")); + cubeCards.add(new CardIdentity("Reckless Waif", "")); + cubeCards.add(new CardIdentity("Refraction Trap", "")); + cubeCards.add(new CardIdentity("Renowned Weaver", "")); + cubeCards.add(new CardIdentity("Repeal", "")); + cubeCards.add(new CardIdentity("Repel Intruders", "")); + cubeCards.add(new CardIdentity("Resize", "")); + cubeCards.add(new CardIdentity("Restless Apparition", "")); + cubeCards.add(new CardIdentity("Returned Phalanx", "")); + cubeCards.add(new CardIdentity("Revenant Patriarch", "")); + cubeCards.add(new CardIdentity("Ribbons of Night", "")); + cubeCards.add(new CardIdentity("Ridge Rannet", "")); + cubeCards.add(new CardIdentity("Rift Bolt", "")); + cubeCards.add(new CardIdentity("Riftmarked Knight", "")); + cubeCards.add(new CardIdentity("Riftwing Cloudskate", "")); + cubeCards.add(new CardIdentity("Ring of Evos Isle", "")); + cubeCards.add(new CardIdentity("Ring of Kalonia", "")); + cubeCards.add(new CardIdentity("Ring of Thune", "")); + cubeCards.add(new CardIdentity("Ring of Valkas", "")); + cubeCards.add(new CardIdentity("Ring of Xathrid", "")); + cubeCards.add(new CardIdentity("Rivals' Duel", "")); + cubeCards.add(new CardIdentity("River Boa", "")); + cubeCards.add(new CardIdentity("River's Grasp", "")); + cubeCards.add(new CardIdentity("Rix Maadi Guildmage", "")); + cubeCards.add(new CardIdentity("Roc Egg", "")); + cubeCards.add(new CardIdentity("Rolling Temblor", "")); + cubeCards.add(new CardIdentity("Rootwalla", "")); + cubeCards.add(new CardIdentity("Rubblebelt Maaka", "")); + cubeCards.add(new CardIdentity("Satyr Nyx-Smith", "")); + cubeCards.add(new CardIdentity("Savage Twister", "")); + cubeCards.add(new CardIdentity("Scab-Clan Charger", "")); + cubeCards.add(new CardIdentity("Scab-Clan Mauler", "")); + cubeCards.add(new CardIdentity("Scavenger Drake", "")); + cubeCards.add(new CardIdentity("Scholar of Athreos", "")); + cubeCards.add(new CardIdentity("Scourge Devil", "")); + cubeCards.add(new CardIdentity("Screeching Bat", "")); + cubeCards.add(new CardIdentity("Sealock Monster", "")); + cubeCards.add(new CardIdentity("Search for Tomorrow", "")); + cubeCards.add(new CardIdentity("Searing Blaze", "")); + cubeCards.add(new CardIdentity("Secretkeeper", "")); + cubeCards.add(new CardIdentity("Security Blockade", "")); + cubeCards.add(new CardIdentity("Seedcradle Witch", "")); + cubeCards.add(new CardIdentity("Selesnya Charm", "")); + cubeCards.add(new CardIdentity("Selesnya Evangel", "")); + cubeCards.add(new CardIdentity("Selesnya Guildgate", "")); + cubeCards.add(new CardIdentity("Selesnya Keyrune", "")); + cubeCards.add(new CardIdentity("Selesnya Sanctuary", "")); + cubeCards.add(new CardIdentity("Selkie Hedge-Mage", "")); + cubeCards.add(new CardIdentity("Sensei's Divining Top", "")); + cubeCards.add(new CardIdentity("Sentry of the Underworld", "")); + cubeCards.add(new CardIdentity("Serrated Arrows", "")); + cubeCards.add(new CardIdentity("Serum Visions", "")); + cubeCards.add(new CardIdentity("Servant of Tymaret", "")); + cubeCards.add(new CardIdentity("Sewer Shambler", "")); + cubeCards.add(new CardIdentity("Shade of Trokair", "")); + cubeCards.add(new CardIdentity("Shadow Lance", "")); + cubeCards.add(new CardIdentity("Shambling Remains", "")); + cubeCards.add(new CardIdentity("Shambling Shell", "")); + cubeCards.add(new CardIdentity("Shield of the Righteous", "")); + cubeCards.add(new CardIdentity("Shimmering Grotto", "")); + cubeCards.add(new CardIdentity("Shinen of Life's Roar", "")); + cubeCards.add(new CardIdentity("Shipwreck Singer", "")); + cubeCards.add(new CardIdentity("Shrewd Hatchling", "")); + cubeCards.add(new CardIdentity("Shriekmaw", "")); + cubeCards.add(new CardIdentity("Shrike Harpy", "")); + cubeCards.add(new CardIdentity("Shuriken", "")); + cubeCards.add(new CardIdentity("Sickleslicer", "")); + cubeCards.add(new CardIdentity("Sightless Brawler", "")); + cubeCards.add(new CardIdentity("Sigil Blessing", "")); + cubeCards.add(new CardIdentity("Sigil of the Nayan Gods", "")); + cubeCards.add(new CardIdentity("Sigiled Starfish", "")); + cubeCards.add(new CardIdentity("Silkbind Faerie", "")); + cubeCards.add(new CardIdentity("Simic Charm", "")); + cubeCards.add(new CardIdentity("Simic Fluxmage", "")); + cubeCards.add(new CardIdentity("Simic Growth Chamber", "")); + cubeCards.add(new CardIdentity("Simic Guildgate", "")); + cubeCards.add(new CardIdentity("Simic Keyrune", "")); + cubeCards.add(new CardIdentity("Siren of the Fanged Coast", "")); + cubeCards.add(new CardIdentity("Skarrg Guildmage", "")); + cubeCards.add(new CardIdentity("Skinbrand Goblin", "")); + cubeCards.add(new CardIdentity("Skinrender", "")); + cubeCards.add(new CardIdentity("Skinwing", "")); + cubeCards.add(new CardIdentity("Skirsdag Cultist", "")); + cubeCards.add(new CardIdentity("Skitter of Lizards", "")); + cubeCards.add(new CardIdentity("Sky Hussar", "")); + cubeCards.add(new CardIdentity("Skyknight Legionnaire", "")); + cubeCards.add(new CardIdentity("Skymark Roc", "")); + cubeCards.add(new CardIdentity("Slaughterhorn", "")); + cubeCards.add(new CardIdentity("Sluiceway Scorpion", "")); + cubeCards.add(new CardIdentity("Slum Reaper", "")); + cubeCards.add(new CardIdentity("Smallpox", "")); + cubeCards.add(new CardIdentity("Smite", "")); + cubeCards.add(new CardIdentity("Snake of the Golden Grove", "")); + cubeCards.add(new CardIdentity("Snake Umbra", "")); + cubeCards.add(new CardIdentity("Snakeform", "")); + cubeCards.add(new CardIdentity("Somberwald Spider", "")); + cubeCards.add(new CardIdentity("Soratami Savant", "")); + cubeCards.add(new CardIdentity("Soul Manipulation", "")); + cubeCards.add(new CardIdentity("Soul Snuffers", "")); + cubeCards.add(new CardIdentity("Soul Stair Expedition", "")); + cubeCards.add(new CardIdentity("Soulsworn Jury", "")); + cubeCards.add(new CardIdentity("Sparkspitter", "")); + cubeCards.add(new CardIdentity("Spawning Pool", "")); + cubeCards.add(new CardIdentity("Spearpoint Oread", "")); + cubeCards.add(new CardIdentity("Spell Contortion", "")); + cubeCards.add(new CardIdentity("Spell Rupture", "")); + cubeCards.add(new CardIdentity("Spider Spawning", "")); + cubeCards.add(new CardIdentity("Spike Jester", "")); + cubeCards.add(new CardIdentity("Spirespine", "")); + cubeCards.add(new CardIdentity("Spirit en-Dal", "")); + cubeCards.add(new CardIdentity("Spitebellows", "")); + cubeCards.add(new CardIdentity("Spiteful Returned", "")); + cubeCards.add(new CardIdentity("Spitemare", "")); + cubeCards.add(new CardIdentity("Sprout Swarm", "")); + cubeCards.add(new CardIdentity("Squall Drifter", "")); + cubeCards.add(new CardIdentity("Stab Wound", "")); + cubeCards.add(new CardIdentity("Staggershock", "")); + cubeCards.add(new CardIdentity("Stand Firm", "")); + cubeCards.add(new CardIdentity("Stand Together", "")); + cubeCards.add(new CardIdentity("Stingscourger", "")); + cubeCards.add(new CardIdentity("Stinkweed Imp", "")); + cubeCards.add(new CardIdentity("Stitched Drake", "")); + cubeCards.add(new CardIdentity("Stitcher's Apprentice", "")); + cubeCards.add(new CardIdentity("Stonefare Crocodile", "")); + cubeCards.add(new CardIdentity("Stoneshock Giant", "")); + cubeCards.add(new CardIdentity("Stonewright", "")); + cubeCards.add(new CardIdentity("Stormblood Berserker", "")); + cubeCards.add(new CardIdentity("Stormcaller of Keranos", "")); + cubeCards.add(new CardIdentity("Strands of Undeath", "")); + cubeCards.add(new CardIdentity("Strandwalker", "")); + cubeCards.add(new CardIdentity("Strangling Soot", "")); + cubeCards.add(new CardIdentity("Stratus Walk", "")); + cubeCards.add(new CardIdentity("Street Spasm", "")); + cubeCards.add(new CardIdentity("Strider Harness", "")); + cubeCards.add(new CardIdentity("Stun Sniper", "")); + cubeCards.add(new CardIdentity("Sunblade Elf", "")); + cubeCards.add(new CardIdentity("Sunhome Guildmage", "")); + cubeCards.add(new CardIdentity("Survival Cache", "")); + cubeCards.add(new CardIdentity("Swarmborn Giant", "")); + cubeCards.add(new CardIdentity("Swell of Courage", "")); + cubeCards.add(new CardIdentity("Swerve", "")); + cubeCards.add(new CardIdentity("Sylvan Bounty", "")); + cubeCards.add(new CardIdentity("Syndic of Tithes", "")); + cubeCards.add(new CardIdentity("Syphon Life", "")); + cubeCards.add(new CardIdentity("Tandem Lookout", "")); + cubeCards.add(new CardIdentity("Terramorphic Expanse", "")); + cubeCards.add(new CardIdentity("Terrus Wurm", "")); + cubeCards.add(new CardIdentity("Test of Faith", "")); + cubeCards.add(new CardIdentity("Tezzeret's Gambit", "")); + cubeCards.add(new CardIdentity("Thassa's Emissary", "")); + cubeCards.add(new CardIdentity("Thatcher Revolt", "")); + cubeCards.add(new CardIdentity("Think Twice", "")); + cubeCards.add(new CardIdentity("Thornscape Battlemage", "")); + cubeCards.add(new CardIdentity("Thorn-Thrash Viashino", "")); + cubeCards.add(new CardIdentity("Thraben Sentry", "")); + cubeCards.add(new CardIdentity("Thrashing Mossdog", "")); + cubeCards.add(new CardIdentity("Throat Slitter", "")); + cubeCards.add(new CardIdentity("Thrull Parasite", "")); + cubeCards.add(new CardIdentity("Thrummingbird", "")); + cubeCards.add(new CardIdentity("Thunder Totem", "")); + cubeCards.add(new CardIdentity("Thundering Tanadon", "")); + cubeCards.add(new CardIdentity("Thunderous Wrath", "")); + cubeCards.add(new CardIdentity("Thunder-Thrash Elder", "")); + cubeCards.add(new CardIdentity("Tidehollow Sculler", "")); + cubeCards.add(new CardIdentity("Tidewater Minion", "")); + cubeCards.add(new CardIdentity("Timely Reinforcements", "")); + cubeCards.add(new CardIdentity("Titan's Strength", "")); + cubeCards.add(new CardIdentity("Tithe Drinker", "")); + cubeCards.add(new CardIdentity("Tomb Hex", "")); + cubeCards.add(new CardIdentity("Torch Slinger", "")); + cubeCards.add(new CardIdentity("Tormentor Exarch", "")); + cubeCards.add(new CardIdentity("Torrent of Souls", "")); + cubeCards.add(new CardIdentity("Tower Above", "")); + cubeCards.add(new CardIdentity("Towering Thunderfist", "")); + cubeCards.add(new CardIdentity("Tracker's Instincts", "")); + cubeCards.add(new CardIdentity("Tragic Slip", "")); + cubeCards.add(new CardIdentity("Trained Condor", "")); + cubeCards.add(new CardIdentity("Transguild Promenade", "")); + cubeCards.add(new CardIdentity("Traumatic Visions", "")); + cubeCards.add(new CardIdentity("Travel Preparations", "")); + cubeCards.add(new CardIdentity("Traveler's Amulet", "")); + cubeCards.add(new CardIdentity("Treetop Village", "")); + cubeCards.add(new CardIdentity("Trestle Troll", "")); + cubeCards.add(new CardIdentity("Triclopean Sight", "")); + cubeCards.add(new CardIdentity("Trinket Mage", "")); + cubeCards.add(new CardIdentity("Triton Tactics", "")); + cubeCards.add(new CardIdentity("Triumph of Ferocity", "")); + cubeCards.add(new CardIdentity("Trollhide", "")); + cubeCards.add(new CardIdentity("Truefire Paladin", "")); + cubeCards.add(new CardIdentity("Trusted Forcemage", "")); + cubeCards.add(new CardIdentity("Tumble Magnet", "")); + cubeCards.add(new CardIdentity("Turn // Burn", "")); + cubeCards.add(new CardIdentity("Turntimber Basilisk", "")); + cubeCards.add(new CardIdentity("Twinblade Slasher", "")); + cubeCards.add(new CardIdentity("Twinstrike", "")); + cubeCards.add(new CardIdentity("Twisted Abomination", "")); + cubeCards.add(new CardIdentity("Ulvenwald Bear", "")); + cubeCards.add(new CardIdentity("Unburial Rites", "")); + cubeCards.add(new CardIdentity("Undercity Informer", "")); + cubeCards.add(new CardIdentity("Undying Evil", "")); + cubeCards.add(new CardIdentity("Unexpected Potential", "")); + cubeCards.add(new CardIdentity("Unruly Mob", "")); + cubeCards.add(new CardIdentity("Utopia Vow", "")); + cubeCards.add(new CardIdentity("Vampire Outcasts", "")); + cubeCards.add(new CardIdentity("Vanishment", "")); + cubeCards.add(new CardIdentity("Vedalken Anatomist", "")); + cubeCards.add(new CardIdentity("Viashino Firstblade", "")); + cubeCards.add(new CardIdentity("Viashino Shanktail", "")); + cubeCards.add(new CardIdentity("Vigor Mortis", "")); + cubeCards.add(new CardIdentity("Village Bell-Ringer", "")); + cubeCards.add(new CardIdentity("Villagers of Estwald", "")); + cubeCards.add(new CardIdentity("Vines of Vastwood", "")); + cubeCards.add(new CardIdentity("Virulent Swipe", "")); + cubeCards.add(new CardIdentity("Viscera Dragger", "")); + cubeCards.add(new CardIdentity("Vital Splicer", "")); + cubeCards.add(new CardIdentity("Vithian Stinger", "")); + cubeCards.add(new CardIdentity("Vitu-Ghazi Guildmage", "")); + cubeCards.add(new CardIdentity("Vivid Crag", "")); + cubeCards.add(new CardIdentity("Vivid Creek", "")); + cubeCards.add(new CardIdentity("Vivid Grove", "")); + cubeCards.add(new CardIdentity("Vivid Marsh", "")); + cubeCards.add(new CardIdentity("Vivid Meadow", "")); + cubeCards.add(new CardIdentity("Vizkopa Guildmage", "")); + cubeCards.add(new CardIdentity("Volt Charge", "")); + cubeCards.add(new CardIdentity("Vortex Elemental", "")); + cubeCards.add(new CardIdentity("Wakedancer", "")); + cubeCards.add(new CardIdentity("Wakestone Gargoyle", "")); + cubeCards.add(new CardIdentity("Wall of Tanglecord", "")); + cubeCards.add(new CardIdentity("Warleader's Helix", "")); + cubeCards.add(new CardIdentity("War-Wing Siren", "")); + cubeCards.add(new CardIdentity("Wasp Lancer", "")); + cubeCards.add(new CardIdentity("Wasteland Viper", "")); + cubeCards.add(new CardIdentity("Water Servant", "")); + cubeCards.add(new CardIdentity("Wayfarer's Bauble", "")); + cubeCards.add(new CardIdentity("Weapon Surge", "")); + cubeCards.add(new CardIdentity("Wear // Tear", "")); + cubeCards.add(new CardIdentity("Weatherseed Totem", "")); + cubeCards.add(new CardIdentity("Whiplash Trap", "")); + cubeCards.add(new CardIdentity("Whispergear Sneak", "")); + cubeCards.add(new CardIdentity("Wild Hunger", "")); + cubeCards.add(new CardIdentity("Wilt-Leaf Cavaliers", "")); + cubeCards.add(new CardIdentity("Windrider Eel", "")); + cubeCards.add(new CardIdentity("Wing Splicer", "")); + cubeCards.add(new CardIdentity("Wingsteed Rider", "")); + cubeCards.add(new CardIdentity("Wistful Selkie", "")); + cubeCards.add(new CardIdentity("Witch's Mist", "")); + cubeCards.add(new CardIdentity("Wojek Halberdiers", "")); + cubeCards.add(new CardIdentity("Wolfir Avenger", "")); + cubeCards.add(new CardIdentity("Worm Harvest", "")); + cubeCards.add(new CardIdentity("Xathrid Slyblade", "")); + cubeCards.add(new CardIdentity("Yoke of the Damned", "")); + cubeCards.add(new CardIdentity("Yoked Plowbeast", "")); + cubeCards.add(new CardIdentity("Zameck Guildmage", "")); + cubeCards.add(new CardIdentity("Zealous Persecution", "")); + cubeCards.add(new CardIdentity("Zektar Shrine Expedition", "")); + cubeCards.add(new CardIdentity("Zhur-Taa Druid", "")); + cubeCards.add(new CardIdentity("Zhur-Taa Swine", "")); + } +} diff --git a/Mage.Server.Plugins/Mage.Tournament.Constructed/pom.xml b/Mage.Server.Plugins/Mage.Tournament.Constructed/pom.xml index 091d2b0a971..884159dba8a 100644 --- a/Mage.Server.Plugins/Mage.Tournament.Constructed/pom.xml +++ b/Mage.Server.Plugins/Mage.Tournament.Constructed/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-tournament-constructed diff --git a/Mage.Server.Plugins/Mage.Tournament.Sealed/pom.xml b/Mage.Server.Plugins/Mage.Tournament.Sealed/pom.xml index ac640da9525..30abbd2009c 100644 --- a/Mage.Server.Plugins/Mage.Tournament.Sealed/pom.xml +++ b/Mage.Server.Plugins/Mage.Tournament.Sealed/pom.xml @@ -7,7 +7,7 @@ org.mage mage-server-plugins - 1.4.2 + 1.4.3 mage-tournament-sealed diff --git a/Mage.Server.Plugins/pom.xml b/Mage.Server.Plugins/pom.xml index bcc34b3f72a..49073190dca 100644 --- a/Mage.Server.Plugins/pom.xml +++ b/Mage.Server.Plugins/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-server-plugins diff --git a/Mage.Server/config/config.xml b/Mage.Server/config/config.xml index 12a6e336575..b6a3eb38f8b 100644 --- a/Mage.Server/config/config.xml +++ b/Mage.Server/config/config.xml @@ -1,16 +1,16 @@ - - + - + @@ -72,8 +72,8 @@ - - + + @@ -85,10 +85,12 @@ - + + + - + @@ -96,7 +98,7 @@ - + diff --git a/Mage.Server/config/init.txt.example b/Mage.Server/config/init.txt.example deleted file mode 100644 index 8203963155a..00000000000 --- a/Mage.Server/config/init.txt.example +++ /dev/null @@ -1,20 +0,0 @@ -# -# Rename this file to init.txt if you want to start using it -# - -# You may add any card to any zone here -# -# Format: ::: -# -# zone ::= hand | battlefield | graveyard | library -# nickname - Player's name you connect to the game with -# -# -battlefield:player:Forest:3 -graveyard:player:Plains:1 -battlefield:player:Snapsail Glider:1 -battlefield:computer:Island:2 -battlefield:player:Plains:3 -hand:player:Whispersilk Cloak:1 -hand:computer:Lightning Bolt:1 -library:player:Shock:2 diff --git a/Mage.Server/pom.xml b/Mage.Server/pom.xml index 41037f63f97..e31288ef6d2 100644 --- a/Mage.Server/pom.xml +++ b/Mage.Server/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-server diff --git a/Mage.Server/release/config/config.xml b/Mage.Server/release/config/config.xml index 9e6a47f3b10..d071f6f62bc 100644 --- a/Mage.Server/release/config/config.xml +++ b/Mage.Server/release/config/config.xml @@ -65,6 +65,8 @@ + + diff --git a/Mage.Server/release/server.msg.txt b/Mage.Server/release/server.msg.txt index b22aa2823b6..82d31dc20a4 100644 --- a/Mage.Server/release/server.msg.txt +++ b/Mage.Server/release/server.msg.txt @@ -1,4 +1,4 @@ -Welcome! You are playing XMage version 1.4.2 +Welcome! You are playing XMage version 1.4.3 Find what was changed since previous versions on project Wiki https://github.com/magefree/mage/wiki Contact us on the XMAGE board of http://www.slightlymagic.net/forum/viewforum.php?f=70 for bug reports or enhancement requests. Download newest version from http://XMage.de \ No newline at end of file diff --git a/Mage.Server/server.msg.txt b/Mage.Server/server.msg.txt index b9630adc79b..b7101ba5dc5 100644 --- a/Mage.Server/server.msg.txt +++ b/Mage.Server/server.msg.txt @@ -2,5 +2,5 @@ HotKeys: Alt+E - Enlarge card image Wheel zoom in/out - Enlarge card image F4 - end current turn, response to stack F9 - skip all opponents' turns, no response to stack -Welcome! You are playing Mage version 1.4.2 +Welcome! You are playing Mage version 1.4.3 Contact us on www.slightlymagic.net \ No newline at end of file diff --git a/Mage.Server/src/main/java/mage/server/game/GameController.java b/Mage.Server/src/main/java/mage/server/game/GameController.java index 5606c4d4db0..6aac4f91b91 100644 --- a/Mage.Server/src/main/java/mage/server/game/GameController.java +++ b/Mage.Server/src/main/java/mage/server/game/GameController.java @@ -492,13 +492,21 @@ public class GameController implements GameCallback { if (data instanceof Integer) { turnsToRollback = (Integer) data; if (game.canRollbackTurns(turnsToRollback)) { - requestsOpen = requestPermissionToRollback(userId, turnsToRollback); - if (requestsOpen == 0) { - game.rollbackTurns(turnsToRollback); - turnsToRollback = -1; - requestsOpen = -1; + UUID playerId = getPlayerId(userId); + if (game.getPriorityPlayerId().equals(playerId)) { + requestsOpen = requestPermissionToRollback(userId, turnsToRollback); + if (requestsOpen == 0) { + game.rollbackTurns(turnsToRollback); + turnsToRollback = -1; + requestsOpen = -1; + } else { + userReqestingRollback = userId; + } } else { - userReqestingRollback = userId; + Player player = game.getPlayer(playerId); + if (player != null) { + game.informPlayer(player, "You can only request a rollback if you have priority."); + } } } else { UUID playerId = getPlayerId(userId); @@ -822,7 +830,9 @@ public class GameController implements GameCallback { @Override public void execute(UUID playerId) { if (cards != null) { - getGameSession(playerId).target(question, new CardsView(game, cards.getCards(game)), targets, required, options); + Zone targetZone = (Zone) options.get("targetZone"); + boolean showFaceDown = targetZone != null && targetZone.equals(Zone.PICK); + getGameSession(playerId).target(question, new CardsView(game, cards.getCards(game), showFaceDown), targets, required, options); } else if (perms != null) { CardsView permsView = new CardsView(); for (Permanent perm : perms) { diff --git a/Mage.Server/src/main/java/mage/server/tournament/TournamentFactory.java b/Mage.Server/src/main/java/mage/server/tournament/TournamentFactory.java index 114331fb785..9575acc3bb8 100644 --- a/Mage.Server/src/main/java/mage/server/tournament/TournamentFactory.java +++ b/Mage.Server/src/main/java/mage/server/tournament/TournamentFactory.java @@ -80,6 +80,13 @@ public class TournamentFactory { if (tournament.getTournamentType().isCubeBooster()) { tournament.getOptions().getLimitedOptions().setDraftCube(CubeFactory.getInstance().createDraftCube(tournament.getOptions().getLimitedOptions().getDraftCubeName())); tournament.setBoosterInfo(tournament.getOptions().getLimitedOptions().getDraftCubeName()); + } else if (tournament.getTournamentType().isRandom()) { + StringBuilder rv = new StringBuilder( "Random Draft using sets: "); + for (Map.Entry entry: setInfo.entrySet()){ + rv.append(entry.getKey()); + rv.append(";"); + } + tournament.setBoosterInfo(rv.toString()); } else { StringBuilder sb = new StringBuilder(); for (Map.Entry entry:setInfo.entrySet()) { diff --git a/Mage.Sets/pom.xml b/Mage.Sets/pom.xml index 95e4a1caf0b..a206bff7596 100644 --- a/Mage.Sets/pom.xml +++ b/Mage.Sets/pom.xml @@ -7,7 +7,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 org.mage diff --git a/Mage.Sets/src/mage/sets/BattleForZendikar.java b/Mage.Sets/src/mage/sets/BattleForZendikar.java new file mode 100644 index 00000000000..b6dc6ad2d77 --- /dev/null +++ b/Mage.Sets/src/mage/sets/BattleForZendikar.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets; + +import java.util.GregorianCalendar; +import mage.cards.ExpansionSet; +import mage.constants.SetType; + +/** + * + * @author fireshoes + */ + +public class BattleForZendikar extends ExpansionSet { + + private static final BattleForZendikar fINSTANCE = new BattleForZendikar(); + + public static BattleForZendikar getInstance() { + return fINSTANCE; + } + + private BattleForZendikar() { + super("Battle for Zendikar", "BFZ", "mage.sets.battleforzendikar", new GregorianCalendar(2015, 10, 2).getTime(), SetType.EXPANSION); + this.blockName = "Battle for Zendikar"; + this.hasBoosters = true; + this.hasBasicLands = true; + this.numBoosterLands = 1; + this.numBoosterCommon = 10; + this.numBoosterUncommon = 3; + this.numBoosterRare = 1; + this.ratioBoosterMythic = 8; + } + +} diff --git a/Mage.Sets/src/mage/sets/ChampionsOfKamigawa.java b/Mage.Sets/src/mage/sets/ChampionsOfKamigawa.java index ee0847dea9f..bd5d6bdda63 100644 --- a/Mage.Sets/src/mage/sets/ChampionsOfKamigawa.java +++ b/Mage.Sets/src/mage/sets/ChampionsOfKamigawa.java @@ -15,8 +15,8 @@ public class ChampionsOfKamigawa extends ExpansionSet { super("Champions of Kamigawa", "CHK", "mage.sets.championsofkamigawa", new GregorianCalendar(2004, 9, 1).getTime(), SetType.EXPANSION); this.blockName = "Kamigawa"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/ClassicSixthEdition.java b/Mage.Sets/src/mage/sets/ClassicSixthEdition.java index f8b987af32f..191829e2a60 100644 --- a/Mage.Sets/src/mage/sets/ClassicSixthEdition.java +++ b/Mage.Sets/src/mage/sets/ClassicSixthEdition.java @@ -28,7 +28,6 @@ package mage.sets; import java.util.GregorianCalendar; - import mage.cards.ExpansionSet; import mage.constants.SetType; @@ -47,8 +46,8 @@ public class ClassicSixthEdition extends ExpansionSet { private ClassicSixthEdition() { super("Classic Sixth Edition", "6ED", "mage.sets.classicsixthedition", new GregorianCalendar(1999, 3, 28).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/DragonsMaze.java b/Mage.Sets/src/mage/sets/DragonsMaze.java index 45c316b308e..1fe91979797 100644 --- a/Mage.Sets/src/mage/sets/DragonsMaze.java +++ b/Mage.Sets/src/mage/sets/DragonsMaze.java @@ -84,7 +84,8 @@ public class DragonsMaze extends ExpansionSet { savedCardsInfos = CardRepository.instance.findCards(criteria); savedCards.put(rarity, savedCardsInfos); } - return savedCardsInfos; + // Return a copy of the saved cards information, as not to modify the original. + return new ArrayList<>(savedCardsInfos); } else { return super.getCardsByRarity(rarity); } diff --git a/Mage.Sets/src/mage/sets/FateReforged.java b/Mage.Sets/src/mage/sets/FateReforged.java index f1126deeb10..76d31b292a2 100644 --- a/Mage.Sets/src/mage/sets/FateReforged.java +++ b/Mage.Sets/src/mage/sets/FateReforged.java @@ -81,9 +81,8 @@ public class FateReforged extends ExpansionSet { savedCardsInfos = CardRepository.instance.findCards(criteria); savedCards.put(rarity, savedCardsInfos); } - List cards = new ArrayList<>(); - cards.addAll(savedCardsInfos); - return cards; + // Return a copy of the saved cards information, as not to modify the original. + return new ArrayList<>(savedCardsInfos); } else { return super.getCardsByRarity(rarity); } diff --git a/Mage.Sets/src/mage/sets/FifthEdition.java b/Mage.Sets/src/mage/sets/FifthEdition.java index 56b9d933fc4..91d596d49a0 100644 --- a/Mage.Sets/src/mage/sets/FifthEdition.java +++ b/Mage.Sets/src/mage/sets/FifthEdition.java @@ -1,12 +1,12 @@ package mage.sets; import java.util.GregorianCalendar; -import mage.constants.SetType; import mage.cards.ExpansionSet; +import mage.constants.SetType; public class FifthEdition extends ExpansionSet { - private static final FifthEdition fINSTANCE = new FifthEdition(); + private static final FifthEdition fINSTANCE = new FifthEdition(); public static FifthEdition getInstance() { return fINSTANCE; @@ -15,11 +15,11 @@ public class FifthEdition extends ExpansionSet { private FifthEdition() { super("Fifth Edition", "5ED", "mage.sets.fifthedition", new GregorianCalendar(1997, 3, 1).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; - this.ratioBoosterMythic = 0; + this.ratioBoosterMythic = 0; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/FourthEdition.java b/Mage.Sets/src/mage/sets/FourthEdition.java index 46b0f5a8906..624d4519eb2 100644 --- a/Mage.Sets/src/mage/sets/FourthEdition.java +++ b/Mage.Sets/src/mage/sets/FourthEdition.java @@ -47,8 +47,8 @@ public class FourthEdition extends ExpansionSet { private FourthEdition() { super("Fourth Edition", "4ED", "mage.sets.fourthedition", new GregorianCalendar(1995, 3, 1).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/FutureSight.java b/Mage.Sets/src/mage/sets/FutureSight.java index ca70d3b350d..30444985c8f 100644 --- a/Mage.Sets/src/mage/sets/FutureSight.java +++ b/Mage.Sets/src/mage/sets/FutureSight.java @@ -49,8 +49,8 @@ public class FutureSight extends ExpansionSet { this.parentSet = TimeSpiral.getInstance(); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/IceAge.java b/Mage.Sets/src/mage/sets/IceAge.java index 0612030775c..3ef48130795 100644 --- a/Mage.Sets/src/mage/sets/IceAge.java +++ b/Mage.Sets/src/mage/sets/IceAge.java @@ -48,8 +48,8 @@ public class IceAge extends ExpansionSet { super("Ice Age", "ICE", "mage.sets.iceage", new GregorianCalendar(1995, 5, 1).getTime(), SetType.EXPANSION); this.blockName = "Ice Age"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Invasion.java b/Mage.Sets/src/mage/sets/Invasion.java index 98588fb7648..8e9290f7724 100644 --- a/Mage.Sets/src/mage/sets/Invasion.java +++ b/Mage.Sets/src/mage/sets/Invasion.java @@ -46,10 +46,10 @@ public class Invasion extends ExpansionSet { super("Invasion", "INV", "mage.sets.invasion", new GregorianCalendar(2000, 9, 2).getTime(), SetType.EXPANSION); this.blockName = "Invasion"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/Judgment.java b/Mage.Sets/src/mage/sets/Judgment.java index 4b25afcd4e6..3614c778829 100644 --- a/Mage.Sets/src/mage/sets/Judgment.java +++ b/Mage.Sets/src/mage/sets/Judgment.java @@ -49,10 +49,10 @@ public class Judgment extends ExpansionSet { this.parentSet = Odyssey.getInstance(); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/Legends.java b/Mage.Sets/src/mage/sets/Legends.java index cdc9935d03a..b5307e817fa 100644 --- a/Mage.Sets/src/mage/sets/Legends.java +++ b/Mage.Sets/src/mage/sets/Legends.java @@ -48,8 +48,8 @@ public class Legends extends ExpansionSet { super("Legends", "LEG", "mage.sets.legends", new GregorianCalendar(1994, 5, 1).getTime(), SetType.EXPANSION); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/LimitedEditionAlpha.java b/Mage.Sets/src/mage/sets/LimitedEditionAlpha.java index fb93b406110..467f742fd0d 100644 --- a/Mage.Sets/src/mage/sets/LimitedEditionAlpha.java +++ b/Mage.Sets/src/mage/sets/LimitedEditionAlpha.java @@ -20,8 +20,8 @@ public class LimitedEditionAlpha extends ExpansionSet { private LimitedEditionAlpha() { super("Limited Edition Alpha", "LEA", "mage.sets.limitedalpha", new GregorianCalendar(1993, 7, 1).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/LimitedEditionBeta.java b/Mage.Sets/src/mage/sets/LimitedEditionBeta.java index 599ae25cf32..dfd8189ced3 100644 --- a/Mage.Sets/src/mage/sets/LimitedEditionBeta.java +++ b/Mage.Sets/src/mage/sets/LimitedEditionBeta.java @@ -20,8 +20,8 @@ public class LimitedEditionBeta extends ExpansionSet { private LimitedEditionBeta() { super("Limited Edition Beta", "LEB", "mage.sets.limitedbeta", new GregorianCalendar(1993, 9, 1).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Lorwyn.java b/Mage.Sets/src/mage/sets/Lorwyn.java index cac08597c78..011e1b6180e 100644 --- a/Mage.Sets/src/mage/sets/Lorwyn.java +++ b/Mage.Sets/src/mage/sets/Lorwyn.java @@ -47,8 +47,8 @@ public class Lorwyn extends ExpansionSet { super("Lorwyn", "LRW", "mage.sets.lorwyn", new GregorianCalendar(2007, 9, 12).getTime(), SetType.EXPANSION); this.blockName = "Lorwyn"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/MagicOrigins.java b/Mage.Sets/src/mage/sets/MagicOrigins.java index d9d75e78dd0..63cfc6f55d5 100644 --- a/Mage.Sets/src/mage/sets/MagicOrigins.java +++ b/Mage.Sets/src/mage/sets/MagicOrigins.java @@ -51,6 +51,7 @@ public class MagicOrigins extends ExpansionSet { this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 8; + this.numBoosterDoubleFaced = -1; // use by rarity /* There are additional cards, numbered 273–288, that don't appear in Magic Origin booster packs. These are reprints from earlier sets that are present in some supplemental products, including sample decks and the Deck Builder's Toolkit. diff --git a/Mage.Sets/src/mage/sets/MercadianMasques.java b/Mage.Sets/src/mage/sets/MercadianMasques.java index 7182d87bc46..dc1d00790f8 100644 --- a/Mage.Sets/src/mage/sets/MercadianMasques.java +++ b/Mage.Sets/src/mage/sets/MercadianMasques.java @@ -48,8 +48,8 @@ public class MercadianMasques extends ExpansionSet { super("Mercadian Masques", "MMQ", "mage.sets.mercadianmasques", new GregorianCalendar(1999, 8, 25).getTime(), SetType.EXPANSION); this.blockName = "Masques"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Mirage.java b/Mage.Sets/src/mage/sets/Mirage.java index 7bdbf7c12dc..9d40be18729 100644 --- a/Mage.Sets/src/mage/sets/Mirage.java +++ b/Mage.Sets/src/mage/sets/Mirage.java @@ -47,8 +47,8 @@ public class Mirage extends ExpansionSet { super("Mirage", "MIR", "mage.sets.mirage", new GregorianCalendar(1996, 8, 21).getTime(), SetType.EXPANSION); this.blockName = "Mirage"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Mirrodin.java b/Mage.Sets/src/mage/sets/Mirrodin.java index 92f3cdb2c9c..82d6d416541 100644 --- a/Mage.Sets/src/mage/sets/Mirrodin.java +++ b/Mage.Sets/src/mage/sets/Mirrodin.java @@ -16,8 +16,8 @@ public class Mirrodin extends ExpansionSet { super("Mirrodin", "MRD", "mage.sets.mirrodin", new GregorianCalendar(2003, 9, 2).getTime(), SetType.EXPANSION); this.blockName = "Mirrodin"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Odyssey.java b/Mage.Sets/src/mage/sets/Odyssey.java index 6eea1098284..b962188d4e7 100644 --- a/Mage.Sets/src/mage/sets/Odyssey.java +++ b/Mage.Sets/src/mage/sets/Odyssey.java @@ -47,8 +47,8 @@ public class Odyssey extends ExpansionSet { super("Odyssey", "ODY", "mage.sets.odyssey", new GregorianCalendar(2001, 9, 22).getTime(), SetType.EXPANSION); this.blockName = "Odyssey"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Onslaught.java b/Mage.Sets/src/mage/sets/Onslaught.java index c3ca10d05d0..e1e64cb4754 100644 --- a/Mage.Sets/src/mage/sets/Onslaught.java +++ b/Mage.Sets/src/mage/sets/Onslaught.java @@ -16,10 +16,10 @@ public class Onslaught extends ExpansionSet { super("Onslaught", "ONS", "mage.sets.onslaught", new GregorianCalendar(2002, 10, 7).getTime(), SetType.EXPANSION); this.blockName = "Onslaught"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/RavnicaCityOfGuilds.java b/Mage.Sets/src/mage/sets/RavnicaCityOfGuilds.java index b0c4cfaffd0..f9f0f39e511 100644 --- a/Mage.Sets/src/mage/sets/RavnicaCityOfGuilds.java +++ b/Mage.Sets/src/mage/sets/RavnicaCityOfGuilds.java @@ -48,8 +48,8 @@ public class RavnicaCityOfGuilds extends ExpansionSet { super("Ravnica: City of Guilds", "RAV", "mage.sets.ravnica", new GregorianCalendar(2005, 9, 24).getTime(), SetType.EXPANSION); this.blockName = "Ravnica"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/RevisedEdition.java b/Mage.Sets/src/mage/sets/RevisedEdition.java index 585abbfc50a..9a39ecc2686 100644 --- a/Mage.Sets/src/mage/sets/RevisedEdition.java +++ b/Mage.Sets/src/mage/sets/RevisedEdition.java @@ -20,8 +20,8 @@ public class RevisedEdition extends ExpansionSet { private RevisedEdition() { super("Revised Edition", "3ED", "mage.sets.revisededition", new GregorianCalendar(1994, 3, 1).getTime(), SetType.CORE); this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Shadowmoor.java b/Mage.Sets/src/mage/sets/Shadowmoor.java index f6c6627905d..855d14b372c 100644 --- a/Mage.Sets/src/mage/sets/Shadowmoor.java +++ b/Mage.Sets/src/mage/sets/Shadowmoor.java @@ -47,8 +47,8 @@ public class Shadowmoor extends ExpansionSet { super("Shadowmoor", "SHM", "mage.sets.shadowmoor", new GregorianCalendar(2008, 4, 2).getTime(), SetType.EXPANSION); this.blockName = "Shadowmoor"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Tempest.java b/Mage.Sets/src/mage/sets/Tempest.java index 28249cb07db..8ac10ab2a21 100644 --- a/Mage.Sets/src/mage/sets/Tempest.java +++ b/Mage.Sets/src/mage/sets/Tempest.java @@ -16,8 +16,8 @@ public class Tempest extends ExpansionSet { super("Tempest", "TMP", "mage.sets.tempest", new GregorianCalendar(1997, 9, 1).getTime(), SetType.EXPANSION); this.blockName = "Tempest"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/TimeSpiral.java b/Mage.Sets/src/mage/sets/TimeSpiral.java index 98aa18145ab..6ac46687ed2 100644 --- a/Mage.Sets/src/mage/sets/TimeSpiral.java +++ b/Mage.Sets/src/mage/sets/TimeSpiral.java @@ -1,9 +1,13 @@ package mage.sets; -import mage.cards.ExpansionSet; -import mage.constants.SetType; - import java.util.GregorianCalendar; +import java.util.List; +import mage.cards.Card; +import mage.cards.ExpansionSet; +import mage.cards.repository.CardCriteria; +import mage.cards.repository.CardRepository; +import mage.constants.Rarity; +import mage.constants.SetType; public class TimeSpiral extends ExpansionSet { @@ -17,10 +21,19 @@ public class TimeSpiral extends ExpansionSet { super("Time Spiral", "TSP", "mage.sets.timespiral", new GregorianCalendar(2006, 9, 9).getTime(), SetType.EXPANSION); this.blockName = "Time Spiral"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 11; + this.numBoosterLands = 0; + this.numBoosterCommon = 10; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; } + + @Override + public List createBooster() { + List booster = super.createBooster(); + CardCriteria criteria = new CardCriteria(); + criteria.rarities(Rarity.SPECIAL).setCodes("TSB"); + addToBooster(booster, CardRepository.instance.findCards(criteria)); + return booster; + } } diff --git a/Mage.Sets/src/mage/sets/UrzasDestiny.java b/Mage.Sets/src/mage/sets/UrzasDestiny.java index e0fcdbdebef..8a71f5e2e6f 100644 --- a/Mage.Sets/src/mage/sets/UrzasDestiny.java +++ b/Mage.Sets/src/mage/sets/UrzasDestiny.java @@ -49,8 +49,8 @@ public class UrzasDestiny extends ExpansionSet { this.parentSet = UrzasSaga.getInstance(); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/UrzasLegacy.java b/Mage.Sets/src/mage/sets/UrzasLegacy.java index 3d4fef267ad..c56402921e2 100644 --- a/Mage.Sets/src/mage/sets/UrzasLegacy.java +++ b/Mage.Sets/src/mage/sets/UrzasLegacy.java @@ -51,8 +51,8 @@ public class UrzasLegacy extends ExpansionSet { this.parentSet = UrzasSaga.getInstance(); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/UrzasSaga.java b/Mage.Sets/src/mage/sets/UrzasSaga.java index 9187caf4678..2ff9831caca 100644 --- a/Mage.Sets/src/mage/sets/UrzasSaga.java +++ b/Mage.Sets/src/mage/sets/UrzasSaga.java @@ -48,8 +48,8 @@ public class UrzasSaga extends ExpansionSet { super("Urza's Saga", "USG", "mage.sets.urzassaga", new GregorianCalendar(1998, 10, 1).getTime(), SetType.EXPANSION); this.blockName = "Urza"; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/Weatherlight.java b/Mage.Sets/src/mage/sets/Weatherlight.java index 6020c0bf36c..9931163de2f 100644 --- a/Mage.Sets/src/mage/sets/Weatherlight.java +++ b/Mage.Sets/src/mage/sets/Weatherlight.java @@ -51,8 +51,8 @@ public class Weatherlight extends ExpansionSet { this.parentSet = Mirage.getInstance(); this.hasBasicLands = false; this.hasBoosters = true; - this.numBoosterLands = 1; - this.numBoosterCommon = 10; + this.numBoosterLands = 0; + this.numBoosterCommon = 11; this.numBoosterUncommon = 3; this.numBoosterRare = 1; this.ratioBoosterMythic = 0; diff --git a/Mage.Sets/src/mage/sets/alarareborn/DefilerOfSouls.java b/Mage.Sets/src/mage/sets/alarareborn/DefilerOfSouls.java index 8a6afe04c35..a7069ec7258 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/DefilerOfSouls.java +++ b/Mage.Sets/src/mage/sets/alarareborn/DefilerOfSouls.java @@ -108,7 +108,7 @@ class DefilerOfSoulsEffect extends OneShotEffect { //had, if thats the case this ability should fizzle. if (amount > 0 && target.canChoose(source.getSourceId(), player.getId(), game)) { boolean abilityApplied = false; - while (player.isInGame() && !target.isChosen() && target.canChoose(player.getId(), game)) { + while (player.canRespond() && !target.isChosen() && target.canChoose(player.getId(), game)) { player.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } diff --git a/Mage.Sets/src/mage/sets/alarareborn/MadrushCyclops.java b/Mage.Sets/src/mage/sets/alarareborn/MadrushCyclops.java index 952c829ce4c..63c01ca52dc 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/MadrushCyclops.java +++ b/Mage.Sets/src/mage/sets/alarareborn/MadrushCyclops.java @@ -1,71 +1,73 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ - -package mage.sets.alarareborn; - -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; -import mage.abilities.keyword.HasteAbility; -import mage.cards.CardImpl; -import mage.filter.common.FilterCreaturePermanent; - -/** - * - * @author Loki - */ -public class MadrushCyclops extends CardImpl { - - public MadrushCyclops (UUID ownerId) { - super(ownerId, 119, "Madrush Cyclops", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{R}{G}"); - this.expansionSetCode = "ARB"; - this.subtype.add("Cyclops"); - this.subtype.add("Warrior"); - - - - this.power = new MageInt(3); - this.toughness = new MageInt(4); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent()))); - } - - public MadrushCyclops (final MadrushCyclops card) { - super(card); - } - - @Override - public MadrushCyclops copy() { - return new MadrushCyclops(this); - } - -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets.alarareborn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author Loki + */ +public class MadrushCyclops extends CardImpl { + + public MadrushCyclops (UUID ownerId) { + super(ownerId, 119, "Madrush Cyclops", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{R}{G}"); + this.expansionSetCode = "ARB"; + this.subtype.add("Cyclops"); + this.subtype.add("Warrior"); + + + + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Creatures you control have haste. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent()))); + } + + public MadrushCyclops (final MadrushCyclops card) { + super(card); + } + + @Override + public MadrushCyclops copy() { + return new MadrushCyclops(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/alarareborn/MeddlingMage.java b/Mage.Sets/src/mage/sets/alarareborn/MeddlingMage.java index cce3267605f..e460268a654 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/MeddlingMage.java +++ b/Mage.Sets/src/mage/sets/alarareborn/MeddlingMage.java @@ -57,8 +57,6 @@ public class MeddlingMage extends CardImpl { this.subtype.add("Human"); this.subtype.add("Wizard"); - - this.power = new MageInt(2); this.toughness = new MageInt(2); @@ -117,7 +115,8 @@ class MeddlingMageReplacementEffect extends ContinuousRuleModifyingEffectImpl { @Override public boolean applies(GameEvent event, Ability source, Game game) { MageObject object = game.getObject(event.getSourceId()); - return object != null && object.getName().equals(game.getState().getValue(source.getSourceId().toString() + NameACardEffect.INFO_KEY)); + // fixes issue #1072 + return object != null && !object.isCopy() && object.getName().equals(game.getState().getValue(source.getSourceId().toString() + NameACardEffect.INFO_KEY)); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/alarareborn/NecromancersCovenant.java b/Mage.Sets/src/mage/sets/alarareborn/NecromancersCovenant.java index df2dbbeadfa..9e5dcf9df74 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/NecromancersCovenant.java +++ b/Mage.Sets/src/mage/sets/alarareborn/NecromancersCovenant.java @@ -28,11 +28,6 @@ package mage.sets.alarareborn; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; @@ -41,6 +36,11 @@ import mage.abilities.effects.common.continuous.GainAbilityAllEffect; import mage.abilities.keyword.LifelinkAbility; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterControlledCreaturePermanent; import mage.filter.common.FilterCreatureCard; import mage.filter.predicate.mageobject.SubtypePredicate; @@ -54,9 +54,9 @@ import mage.target.TargetPlayer; * @author jeffwadsworth */ public class NecromancersCovenant extends CardImpl { - + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("Zombies you control"); - + static { filter.add(new SubtypePredicate("Zombie")); } @@ -65,9 +65,6 @@ public class NecromancersCovenant extends CardImpl { super(ownerId, 82, "Necromancer's Covenant", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}{B}{B}"); this.expansionSetCode = "ARB"; - - - // When Necromancer's Covenant enters the battlefield, exile all creature cards from target player's graveyard, then put a 2/2 black Zombie creature token onto the battlefield for each card exiled this way. Ability ability = new EntersBattlefieldTriggeredAbility(new NecromancersConvenantEffect(), false); ability.addTarget(new TargetPlayer()); @@ -110,7 +107,7 @@ class NecromancersConvenantEffect extends OneShotEffect { count += 1; } } - ZombieToken zombieToken = new ZombieToken("ALA"); + ZombieToken zombieToken = new ZombieToken(); if (zombieToken.putOntoBattlefield(count, game, source.getSourceId(), source.getControllerId())) { return true; } diff --git a/Mage.Sets/src/mage/sets/alarareborn/SagesOfTheAnima.java b/Mage.Sets/src/mage/sets/alarareborn/SagesOfTheAnima.java index 61b2394f775..b8d83c987f6 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/SagesOfTheAnima.java +++ b/Mage.Sets/src/mage/sets/alarareborn/SagesOfTheAnima.java @@ -120,7 +120,7 @@ class SagesOfTheAnimaReplacementEffect extends ReplacementEffectImpl { } } TargetCard target = new TargetCard(Zone.PICK, new FilterCard()); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/alarareborn/SlaveOfBolas.java b/Mage.Sets/src/mage/sets/alarareborn/SlaveOfBolas.java index 414e9e9cee0..da0c98d4ea7 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/SlaveOfBolas.java +++ b/Mage.Sets/src/mage/sets/alarareborn/SlaveOfBolas.java @@ -43,6 +43,7 @@ import mage.constants.Duration; import mage.constants.Outcome; import mage.constants.Rarity; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.target.common.TargetCreaturePermanent; import mage.target.targetpointer.FixedTarget; @@ -56,10 +57,6 @@ public class SlaveOfBolas extends CardImpl { super(ownerId, 136, "Slave of Bolas", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{U/R}{B}"); this.expansionSetCode = "ARB"; - - - - // Gain control of target creature. Untap that creature. It gains haste until end of turn. Sacrifice it at the beginning of the next end step. this.getSpellAbility().addEffect(new GainControlTargetEffect(Duration.EndOfTurn)); this.getSpellAbility().addEffect(new UntapTargetEffect()); @@ -96,13 +93,17 @@ class SlaveOfBolasEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this"); - sacrificeEffect.setTargetPointer(new FixedTarget(source.getFirstTarget())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); - return true; + Permanent permanent = game.getPermanent(source.getFirstTarget()); + if (permanent != null) { + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + return true; + } + return false; } } diff --git a/Mage.Sets/src/mage/sets/alarareborn/TraceOfAbundance.java b/Mage.Sets/src/mage/sets/alarareborn/TraceOfAbundance.java index 388649436cd..15a6d36f72d 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/TraceOfAbundance.java +++ b/Mage.Sets/src/mage/sets/alarareborn/TraceOfAbundance.java @@ -55,7 +55,7 @@ import mage.target.common.TargetLandPermanent; * @author jeffwadsworth */ public class TraceOfAbundance extends CardImpl { - + private String rule = "Enchanted land has shroud"; public TraceOfAbundance(UUID ownerId) { @@ -63,10 +63,6 @@ public class TraceOfAbundance extends CardImpl { this.expansionSetCode = "ARB"; this.subtype.add("Aura"); - - - - // Enchant land TargetPermanent auraTarget = new TargetLandPermanent(); this.getSpellAbility().addTarget(auraTarget); diff --git a/Mage.Sets/src/mage/sets/alarareborn/UnscytheKillerOfKings.java b/Mage.Sets/src/mage/sets/alarareborn/UnscytheKillerOfKings.java index b89373ee45c..3400918c530 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/UnscytheKillerOfKings.java +++ b/Mage.Sets/src/mage/sets/alarareborn/UnscytheKillerOfKings.java @@ -163,7 +163,7 @@ class UnscytheEffect extends OneShotEffect { if (controller != null) { Card card = game.getCard(targetPointer.getFirst(game, source)); if (card != null && game.getState().getZone(card.getId()).equals(Zone.GRAVEYARD) && controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.GRAVEYARD, true)) { - ZombieToken zombie = new ZombieToken("ALA"); + ZombieToken zombie = new ZombieToken(); return zombie.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); } return true; diff --git a/Mage.Sets/src/mage/sets/alarareborn/VedalkenHeretic.java b/Mage.Sets/src/mage/sets/alarareborn/VedalkenHeretic.java index 5b8f0d526ab..0a1d61f2124 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/VedalkenHeretic.java +++ b/Mage.Sets/src/mage/sets/alarareborn/VedalkenHeretic.java @@ -29,7 +29,7 @@ package mage.sets.alarareborn; import java.util.UUID; import mage.MageInt; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.cards.CardImpl; import mage.constants.CardType; @@ -54,7 +54,7 @@ public class VedalkenHeretic extends CardImpl { // Whenever Vedalken Heretic deals damage to an opponent, you may draw a card. this.addAbility(new DealsDamageToOpponentTriggeredAbility(new DrawCardSourceControllerEffect(1), true)); - + } public VedalkenHeretic(final VedalkenHeretic card) { diff --git a/Mage.Sets/src/mage/sets/alliances/Astrolabe1.java b/Mage.Sets/src/mage/sets/alliances/Astrolabe1.java new file mode 100644 index 00000000000..ec59b50b40d --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/Astrolabe1.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Astrolabe1 extends mage.sets.masterseditioniii.Astrolabe { + + public Astrolabe1(UUID ownerId) { + super(ownerId); + this.cardNumber = 159; + this.expansionSetCode = "ALL"; + } + + public Astrolabe1(final Astrolabe1 card) { + super(card); + } + + @Override + public Astrolabe1 copy() { + return new Astrolabe1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/Astrolabe2.java b/Mage.Sets/src/mage/sets/alliances/Astrolabe2.java new file mode 100644 index 00000000000..1ef02040269 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/Astrolabe2.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Astrolabe2 extends mage.sets.masterseditioniii.Astrolabe { + + public Astrolabe2(UUID ownerId) { + super(ownerId); + this.cardNumber = 160; + this.expansionSetCode = "ALL"; + } + + public Astrolabe2(final Astrolabe2 card) { + super(card); + } + + @Override + public Astrolabe2 copy() { + return new Astrolabe2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/FeastOrFamine1.java b/Mage.Sets/src/mage/sets/alliances/FeastOrFamine1.java new file mode 100644 index 00000000000..dcdb28a3477 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/FeastOrFamine1.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class FeastOrFamine1 extends mage.sets.izzetvsgolgari.FeastOrFamine { + + public FeastOrFamine1(UUID ownerId) { + super(ownerId); + this.cardNumber = 8; + this.expansionSetCode = "ALL"; + } + + public FeastOrFamine1(final FeastOrFamine1 card) { + super(card); + } + + @Override + public FeastOrFamine1 copy() { + return new FeastOrFamine1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/FeastOrFamine2.java b/Mage.Sets/src/mage/sets/alliances/FeastOrFamine2.java new file mode 100644 index 00000000000..36b61ba137c --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/FeastOrFamine2.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class FeastOrFamine2 extends mage.sets.izzetvsgolgari.FeastOrFamine { + + public FeastOrFamine2(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "ALL"; + } + + public FeastOrFamine2(final FeastOrFamine2 card) { + super(card); + } + + @Override + public FeastOrFamine2 copy() { + return new FeastOrFamine2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/FloodwaterDam.java b/Mage.Sets/src/mage/sets/alliances/FloodwaterDam.java new file mode 100644 index 00000000000..ae4e16a926f --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/FloodwaterDam.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class FloodwaterDam extends mage.sets.masterseditioniv.FloodwaterDam { + + public FloodwaterDam(UUID ownerId) { + super(ownerId); + this.cardNumber = 161; + this.expansionSetCode = "ALL"; + } + + public FloodwaterDam(final FloodwaterDam card) { + super(card); + } + + @Override + public FloodwaterDam copy() { + return new FloodwaterDam(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/GorillaShaman1.java b/Mage.Sets/src/mage/sets/alliances/GorillaShaman1.java new file mode 100644 index 00000000000..edb27282bc7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/GorillaShaman1.java @@ -0,0 +1,90 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterArtifactPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; +import mage.game.Game; +import mage.target.Target; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class GorillaShaman1 extends CardImpl { + + public GorillaShaman1(UUID ownerId) { + super(ownerId, 106, "Gorilla Shaman", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "ALL"; + this.subtype.add("Ape"); + this.subtype.add("Shaman"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {X}{X}{1}: Destroy target noncreature artifact with converted mana cost X. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{X}{X}{1}")); + ability.addTarget(new TargetPermanent(new FilterArtifactPermanent("noncreature artifact with converted mana cost X"))); + this.addAbility(ability); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability instanceof SimpleActivatedAbility) { + int xValue = ability.getManaCostsToPay().getX(); + ability.getTargets().clear(); + FilterArtifactPermanent filter = new FilterArtifactPermanent(new StringBuilder("noncreature artifact with converted mana cost ").append(xValue).toString()); + filter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.Equal, xValue)); + filter.add(Predicates.not(new CardTypePredicate(CardType.CREATURE))); + Target target = new TargetPermanent(filter); + ability.addTarget(target); + } + } + + public GorillaShaman1(final GorillaShaman1 card) { + super(card); + } + + @Override + public GorillaShaman1 copy() { + return new GorillaShaman1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/GorillaShaman2.java b/Mage.Sets/src/mage/sets/alliances/GorillaShaman2.java new file mode 100644 index 00000000000..d6f1c2181d4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/GorillaShaman2.java @@ -0,0 +1,53 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class GorillaShaman2 extends GorillaShaman1 { + + public GorillaShaman2(UUID ownerId) { + super(ownerId); + this.cardNumber = 107; + this.rarity = Rarity.UNCOMMON; + } + + public GorillaShaman2(final GorillaShaman2 card) { + super(card); + } + + @Override + public GorillaShaman2 copy() { + return new GorillaShaman2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/GorillaWarCry1.java b/Mage.Sets/src/mage/sets/alliances/GorillaWarCry1.java new file mode 100644 index 00000000000..8ee452418b5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/GorillaWarCry1.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class GorillaWarCry1 extends mage.sets.masterseditioniv.GorillaWarCry { + + public GorillaWarCry1(UUID ownerId) { + super(ownerId); + this.cardNumber = 108; + this.expansionSetCode = "ALL"; + } + + public GorillaWarCry1(final GorillaWarCry1 card) { + super(card); + } + + @Override + public GorillaWarCry1 copy() { + return new GorillaWarCry1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/GorillaWarCry2.java b/Mage.Sets/src/mage/sets/alliances/GorillaWarCry2.java new file mode 100644 index 00000000000..657c2278db0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/GorillaWarCry2.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class GorillaWarCry2 extends mage.sets.masterseditioniv.GorillaWarCry { + + public GorillaWarCry2(UUID ownerId) { + super(ownerId); + this.cardNumber = 109; + this.expansionSetCode = "ALL"; + } + + public GorillaWarCry2(final GorillaWarCry2 card) { + super(card); + } + + @Override + public GorillaWarCry2 copy() { + return new GorillaWarCry2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/LordOfTresserhorn.java b/Mage.Sets/src/mage/sets/alliances/LordOfTresserhorn.java index 615bff39518..12dc40a8961 100644 --- a/Mage.Sets/src/mage/sets/alliances/LordOfTresserhorn.java +++ b/Mage.Sets/src/mage/sets/alliances/LordOfTresserhorn.java @@ -37,16 +37,13 @@ import mage.abilities.effects.Effect; import mage.abilities.effects.common.DrawCardTargetEffect; import mage.abilities.effects.common.LoseLifeSourceControllerEffect; import mage.abilities.effects.common.RegenerateSourceEffect; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterControlledCreaturePermanent; -import mage.target.Target; -import mage.target.common.TargetControlledCreaturePermanent; import mage.target.common.TargetOpponent; -import mage.target.targetpointer.SecondTargetPointer; /** * @@ -65,15 +62,13 @@ public class LordOfTresserhorn extends CardImpl { // When Lord of Tresserhorn enters the battlefield, you lose 2 life, you sacrifice two creatures, and target opponent draws two cards. Ability ability = new EntersBattlefieldTriggeredAbility(new LoseLifeSourceControllerEffect(2), false); - ability.addEffect(new SacrificeTargetEffect(", you sacrifice two creatures")); - Target target = new TargetControlledCreaturePermanent(2,2, new FilterControlledCreaturePermanent(), true); - ability.addTarget(target); + ability.addEffect(new SacrificeControllerEffect(new FilterControlledCreaturePermanent("creatures"), 2, "you")); Effect effect = new DrawCardTargetEffect(2); effect.setText(", and target opponent draws two cards"); - effect.setTargetPointer(new SecondTargetPointer()); ability.addEffect(effect); ability.addTarget(new TargetOpponent()); this.addAbility(ability); + // {B}: Regenerate Lord of Tresserhorn. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{B}"))); } diff --git a/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast1.java b/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast1.java new file mode 100644 index 00000000000..e91607c20c2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast1.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageControllerEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class PhyrexianWarBeast1 extends CardImpl { + + public PhyrexianWarBeast1(UUID ownerId) { + super(ownerId, 169, "Phyrexian War Beast", Rarity.COMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}"); + this.expansionSetCode = "ALL"; + this.subtype.add("Beast"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // When Phyrexian War Beast leaves the battlefield, sacrifice a land and Phyrexian War Beast deals 1 damage to you. + Ability ability = new LeavesBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterControlledLandPermanent(), 1, ""), false); + Effect effect = new DamageControllerEffect(1); + effect.setText("and {this} deals 1 damage to you"); + ability.addEffect(effect); + ability.addTarget(new TargetControlledPermanent(new FilterControlledLandPermanent())); + this.addAbility(ability); + } + + public PhyrexianWarBeast1(final PhyrexianWarBeast1 card) { + super(card); + } + + @Override + public PhyrexianWarBeast1 copy() { + return new PhyrexianWarBeast1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast2.java b/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast2.java new file mode 100644 index 00000000000..baa04a1b989 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/PhyrexianWarBeast2.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class PhyrexianWarBeast2 extends PhyrexianWarBeast1 { + + public PhyrexianWarBeast2(UUID ownerId) { + super(ownerId); + this.cardNumber = 170; + } + + public PhyrexianWarBeast2(final PhyrexianWarBeast2 card) { + super(card); + } + + @Override + public PhyrexianWarBeast2 copy() { + return new PhyrexianWarBeast2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/Reinforcements1.java b/Mage.Sets/src/mage/sets/alliances/Reinforcements1.java new file mode 100644 index 00000000000..7863eca7cb7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/Reinforcements1.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Reinforcements1 extends mage.sets.masterseditionii.Reinforcements { + + public Reinforcements1(UUID ownerId) { + super(ownerId); + this.cardNumber = 142; + this.expansionSetCode = "ALL"; + } + + public Reinforcements1(final Reinforcements1 card) { + super(card); + } + + @Override + public Reinforcements1 copy() { + return new Reinforcements1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/Reinforcements2.java b/Mage.Sets/src/mage/sets/alliances/Reinforcements2.java new file mode 100644 index 00000000000..e9010af8794 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/Reinforcements2.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Reinforcements2 extends mage.sets.masterseditionii.Reinforcements { + + public Reinforcements2(UUID ownerId) { + super(ownerId); + this.cardNumber = 143; + this.expansionSetCode = "ALL"; + } + + public Reinforcements2(final Reinforcements2 card) { + super(card); + } + + @Override + public Reinforcements2 copy() { + return new Reinforcements2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/SoldeviDigger.java b/Mage.Sets/src/mage/sets/alliances/SoldeviDigger.java new file mode 100644 index 00000000000..e1b72ee1ae8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/SoldeviDigger.java @@ -0,0 +1,99 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class SoldeviDigger extends CardImpl { + + public SoldeviDigger(UUID ownerId) { + super(ownerId, 174, "Soldevi Digger", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "ALL"; + + // {2}: Put the top card of your graveyard on the bottom of your library. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new SoldeviDiggerEffect(), new ManaCostsImpl("{2}"))); + } + + public SoldeviDigger(final SoldeviDigger card) { + super(card); + } + + @Override + public SoldeviDigger copy() { + return new SoldeviDigger(this); + } +} + +class SoldeviDiggerEffect extends OneShotEffect { + + public SoldeviDiggerEffect() { + super(Outcome.Benefit); + this.staticText = "put the top card of your graveyard on the bottom of your library"; + } + + public SoldeviDiggerEffect(final SoldeviDiggerEffect effect) { + super(effect); + } + + @Override + public SoldeviDiggerEffect copy() { + return new SoldeviDiggerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + Card topCard = null; + for (Card card :controller.getGraveyard().getCards(game)) { + topCard = card; + } + if (topCard != null) { + return controller.moveCardToLibraryWithInfo(topCard, source.getSourceId(), game, Zone.GRAVEYARD, false, true); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/alliances/SoldeviExcavations.java b/Mage.Sets/src/mage/sets/alliances/SoldeviExcavations.java index cbf814751bb..a4705db82e3 100644 --- a/Mage.Sets/src/mage/sets/alliances/SoldeviExcavations.java +++ b/Mage.Sets/src/mage/sets/alliances/SoldeviExcavations.java @@ -30,14 +30,13 @@ package mage.sets.alliances; import java.util.UUID; import mage.Mana; import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.SacrificeTargetCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.effects.common.EnterBattlefieldPayCostOrPutGraveyardEffect; -import mage.abilities.effects.common.LookLibraryMayPutToBottomEffect; +import mage.abilities.effects.keyword.ScryEffect; import mage.abilities.mana.SimpleManaAbility; import mage.cards.CardImpl; import mage.constants.CardType; @@ -70,13 +69,12 @@ public class SoldeviExcavations extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.ALL, new EnterBattlefieldPayCostOrPutGraveyardEffect(new SacrificeTargetCost(new TargetControlledPermanent(filter))))); // {tap}: Add {1}{U} to your mana pool. - this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 1, 0, 0, 1,0 ), new TapSourceCost())); - // {1}, {tap}: Look at the top card of your library. You may put that card on the bottom of your library. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LookLibraryMayPutToBottomEffect(), new GenericManaCost(1)); + this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 1, 0, 0, 1, 0), new TapSourceCost())); + + // {1}, {tap}: Scry 1. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ScryEffect(1), new GenericManaCost(1)); ability.addCost(new TapSourceCost()); this.addAbility(ability); - - } public SoldeviExcavations(final SoldeviExcavations card) { diff --git a/Mage.Sets/src/mage/sets/alliances/WanderingMage.java b/Mage.Sets/src/mage/sets/alliances/WanderingMage.java new file mode 100644 index 00000000000..20d38dca7c9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alliances/WanderingMage.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.alliances; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class WanderingMage extends mage.sets.masterseditioniii.WanderingMage { + + public WanderingMage(UUID ownerId) { + super(ownerId); + this.cardNumber = 198; + this.expansionSetCode = "ALL"; + } + + public WanderingMage(final WanderingMage card) { + super(card); + } + + @Override + public WanderingMage copy() { + return new WanderingMage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/antiquities/ArgivianBlacksmith.java b/Mage.Sets/src/mage/sets/antiquities/ArgivianBlacksmith.java new file mode 100644 index 00000000000..c789f94e247 --- /dev/null +++ b/Mage.Sets/src/mage/sets/antiquities/ArgivianBlacksmith.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.antiquities; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class ArgivianBlacksmith extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("target artifact creature"); + + static { + filter.add(new CardTypePredicate(CardType.ARTIFACT)); + filter.add(new CardTypePredicate(CardType.CREATURE)); + } + + public ArgivianBlacksmith(UUID ownerId) { + super(ownerId, 95, "Argivian Blacksmith", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}{W}"); + this.expansionSetCode = "ATQ"; + this.subtype.add("Human"); + this.subtype.add("Artificer"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {tap}: Prevent the next 2 damage that would be dealt to target artifact creature this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new TapSourceCost()); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + public ArgivianBlacksmith(final ArgivianBlacksmith card) { + super(card); + } + + @Override + public ArgivianBlacksmith copy() { + return new ArgivianBlacksmith(this); + } +} diff --git a/Mage.Sets/src/mage/sets/antiquities/Crumble.java b/Mage.Sets/src/mage/sets/antiquities/Crumble.java new file mode 100644 index 00000000000..e9ca8886e69 --- /dev/null +++ b/Mage.Sets/src/mage/sets/antiquities/Crumble.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.antiquities; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Crumble extends mage.sets.masterseditioniv.Crumble { + + public Crumble(UUID ownerId) { + super(ownerId); + this.cardNumber = 62; + this.expansionSetCode = "ATQ"; + } + + public Crumble(final Crumble card) { + super(card); + } + + @Override + public Crumble copy() { + return new Crumble(this); + } +} diff --git a/Mage.Sets/src/mage/sets/antiquities/PowerArtifact.java b/Mage.Sets/src/mage/sets/antiquities/PowerArtifact.java index 64ac7fd00bf..b36596b5cbe 100644 --- a/Mage.Sets/src/mage/sets/antiquities/PowerArtifact.java +++ b/Mage.Sets/src/mage/sets/antiquities/PowerArtifact.java @@ -8,6 +8,7 @@ package mage.sets.antiquities; import java.util.UUID; import mage.Mana; import mage.abilities.Ability; +import mage.abilities.ActivatedAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.cost.CostModificationEffectImpl; @@ -32,48 +33,46 @@ import mage.util.CardUtil; * @author nick.myers */ public class PowerArtifact extends CardImpl { - + public PowerArtifact(UUID ownerId) { super(ownerId, 55, "Power Artifact", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{U}{U}"); this.expansionSetCode = "ATQ"; this.subtype.add("Aura"); - + // Enchant artifact TargetPermanent auraTarget = new TargetArtifactPermanent(); this.getSpellAbility().addTarget(auraTarget); this.getSpellAbility().addEffect(new AttachEffect(Outcome.Benefit)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); - - // The activation cost of target artifact is reduced by {2}. If this would reduce target - // artifact's activation cost below {1}, target artifact's activation cost becomes {1}. - // Power Artifact has no effect on artifacts that have no activation cost or whose activation - // cost is {0}. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PowerArtifactCostModificationEffect())); + + // Enchanted artifact's activated abilities cost less to activate. + // This effect can't reduce the amount of mana an ability costs to activate to less than one mana. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PowerArtifactCostModificationEffect())); } - + public PowerArtifact(final PowerArtifact card) { super(card); } - + @Override public PowerArtifact copy() { return new PowerArtifact(this); - } + } } class PowerArtifactCostModificationEffect extends CostModificationEffectImpl { - + PowerArtifactCostModificationEffect() { super(Duration.WhileOnBattlefield, Outcome.Benefit, CostModificationType.REDUCE_COST); staticText = "The activation cost of target artifact is reduced by {2}. If this would reduce target artifact's activation cost below {1}, target artifact's activation cost becomes {1}. Power artifact has no effect on artifacts that have no activation cost or whose activation cost is {0}."; - + } - + PowerArtifactCostModificationEffect(PowerArtifactCostModificationEffect effect) { super(effect); } - + @Override public boolean apply(Game game, Ability source, Ability abilityToModify) { Player controller = game.getPlayer(abilityToModify.getControllerId()); @@ -90,21 +89,22 @@ class PowerArtifactCostModificationEffect extends CostModificationEffectImpl { } return true; } - + @Override public boolean applies(Ability abilityToModify, Ability source, Game game) { Permanent artifact = game.getPermanent(abilityToModify.getSourceId()); if (artifact != null && artifact.getAttachments().contains(source.getSourceId())) { - if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED)) { + if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED) + || (abilityToModify.getAbilityType().equals(AbilityType.MANA) && (abilityToModify instanceof ActivatedAbility))) { return true; } } return false; } - - @Override + + @Override public PowerArtifactCostModificationEffect copy() { return new PowerArtifactCostModificationEffect(this); } - + } diff --git a/Mage.Sets/src/mage/sets/antiquities/Reconstruction.java b/Mage.Sets/src/mage/sets/antiquities/Reconstruction.java new file mode 100644 index 00000000000..a50fea4eec6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/antiquities/Reconstruction.java @@ -0,0 +1,61 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.antiquities; + +import java.util.UUID; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterArtifactCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class Reconstruction extends CardImpl { + + public Reconstruction(UUID ownerId) { + super(ownerId, 56, "Reconstruction", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{U}"); + this.expansionSetCode = "ATQ"; + + // Return target artifact card from your graveyard to your hand. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(new FilterArtifactCard("artifact card from your graveyard"))); + } + + public Reconstruction(final Reconstruction card) { + super(card); + } + + @Override + public Reconstruction copy() { + return new Reconstruction(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/BrassHerald.java b/Mage.Sets/src/mage/sets/apocalypse/BrassHerald.java new file mode 100644 index 00000000000..a4050e666de --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/BrassHerald.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.ChooseCreatureTypeEffect; +import mage.abilities.effects.common.EnvoyEffect; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; + +/** + * + * @author LoneFox + */ +public class BrassHerald extends CardImpl { + + public BrassHerald(UUID ownerId) { + super(ownerId, 133, "Brass Herald", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{6}"); + this.expansionSetCode = "APC"; + this.subtype.add("Golem"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // As Brass Herald enters the battlefield, choose a creature type. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.BoostCreature))); + // When Brass Herald enters the battlefield, reveal the top four cards of your library. Put all creature cards of the chosen type revealed this way into your hand and the rest on the bottom of your library in any order. + FilterCard filter = new FilterCard("creature cards of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); + + // Creatures of the chosen type get +1/+1. + FilterCreaturePermanent filter2 = new FilterCreaturePermanent("creatures of the chosen type"); + filter2.add(new ChosenSubtypePredicate(this.getId())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, + filter2, false))); + } + + public BrassHerald(final BrassHerald card) { + super(card); + } + + @Override + public BrassHerald copy() { + return new BrassHerald(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/CoastalDrake.java b/Mage.Sets/src/mage/sets/apocalypse/CoastalDrake.java index 3be0c8808e2..c310b13a6e2 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/CoastalDrake.java +++ b/Mage.Sets/src/mage/sets/apocalypse/CoastalDrake.java @@ -28,18 +28,19 @@ package mage.sets.apocalypse; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; /** * @@ -54,12 +55,13 @@ public class CoastalDrake extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(1); - - // Flying + + // Flying this.addAbility(FlyingAbility.getInstance()); - + // {1}{U}, {T} : Return target Kavu to its owner's hand. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandSourceEffect(true), new ManaCostsImpl("{1}{U}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(true), new ManaCostsImpl("{1}{U}")); + ability.addTarget(new TargetCreaturePermanent(new FilterCreaturePermanent("Kavu", "Kavu"))); ability.addCost(new TapSourceCost()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/apocalypse/DeadRingers.java b/Mage.Sets/src/mage/sets/apocalypse/DeadRingers.java new file mode 100644 index 00000000000..22e8ab64b2d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/DeadRingers.java @@ -0,0 +1,102 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.Target; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class DeadRingers extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("nonblack creature"); + + static { + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + + public DeadRingers(UUID ownerId) { + super(ownerId, 37, "Dead Ringers", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{4}{B}"); + this.expansionSetCode = "APC"; + + // Destroy two target nonblack creatures unless either one is a color the other isn't. They can't be regenerated. + this.getSpellAbility().addEffect(new DeadRingersEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(2, 2, filter, false)); + } + + public DeadRingers(final DeadRingers card) { + super(card); + } + + @Override + public DeadRingers copy() { + return new DeadRingers(this); + } +} + +class DeadRingersEffect extends DestroyTargetEffect { + + public DeadRingersEffect() { + super(true); + staticText = "Destroy two target nonblack creatures unless either one is a color the other isn't. They can't be regenerated."; + } + + public DeadRingersEffect(final DeadRingersEffect effect) { + super(effect); + } + + @Override + public DeadRingersEffect copy() { + return new DeadRingersEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Target target = source.getTargets().get(0); + Permanent first = game.getPermanentOrLKIBattlefield(target.getTargets().get(0)); + Permanent second = game.getPermanentOrLKIBattlefield(target.getTargets().get(1)); + if(first != null && second != null && first.getColor(game).equals(second.getColor(game))) { + return super.apply(game, source); + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/DesolationGiant.java b/Mage.Sets/src/mage/sets/apocalypse/DesolationGiant.java new file mode 100644 index 00000000000..ba7062ff42d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/DesolationGiant.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DestroyAllEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class DesolationGiant extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("other creatures"); + private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent("other creatures you control"); + + static { + filter.add(new AnotherPredicate()); + filter2.add(new AnotherPredicate()); + filter2.add(new ControllerPredicate(TargetController.YOU)); + } + + public DesolationGiant(UUID ownerId) { + super(ownerId, 59, "Desolation Giant", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}{R}"); + this.expansionSetCode = "APC"; + this.subtype.add("Giant"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Kicker {W}{W} + this.addAbility(new KickerAbility("{W}{W}")); + // When Desolation Giant enters the battlefield, destroy all other creatures you control. If it was kicked, destroy all other creatures instead. + this.addAbility(new EntersBattlefieldTriggeredAbility(new ConditionalOneShotEffect(new DestroyAllEffect(filter), + new DestroyAllEffect(filter2), KickedCondition.getInstance(), "destroy all other creatures you control. If it was kicked, destroy all other creatures instead."))); +} + + public DesolationGiant(final DesolationGiant card) { + super(card); + } + + @Override + public DesolationGiant copy() { + return new DesolationGiant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/DivineLight.java b/Mage.Sets/src/mage/sets/apocalypse/DivineLight.java new file mode 100644 index 00000000000..6cf52f3af6d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/DivineLight.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.effects.common.PreventAllDamageToAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class DivineLight extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures you control"); + + static { + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public DivineLight(UUID ownerId) { + super(ownerId, 8, "Divine Light", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{W}"); + this.expansionSetCode = "APC"; + + // Prevent all damage that would be dealt this turn to creatures you control. + this.getSpellAbility().addEffect(new PreventAllDamageToAllEffect(Duration.EndOfTurn, filter)); + } + + public DivineLight(final DivineLight card) { + super(card); + } + + @Override + public DivineLight copy() { + return new DivineLight(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/Dodecapod.java b/Mage.Sets/src/mage/sets/apocalypse/Dodecapod.java new file mode 100644 index 00000000000..28c78bf997a --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/Dodecapod.java @@ -0,0 +1,97 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DiscardOntoBattlefieldEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author LoneFox + */ +public class Dodecapod extends CardImpl { + + public Dodecapod(UUID ownerId) { + super(ownerId, 134, "Dodecapod", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{4}"); + this.expansionSetCode = "APC"; + this.subtype.add("Golem"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // If a spell or ability an opponent controls causes you to discard Dodecapod, put it onto the battlefield with two +1/+1 counters on it instead of putting it into your graveyard. + this.addAbility(new SimpleStaticAbility(Zone.HAND, new DodecapodEffect())); + + } + + public Dodecapod(final Dodecapod card) { + super(card); + } + + @Override + public Dodecapod copy() { + return new Dodecapod(this); + } +} + + +class DodecapodEffect extends DiscardOntoBattlefieldEffect { + + public DodecapodEffect() { + super(); + staticText = "If a spell or ability an opponent controls causes you to discard {this}, put it onto the battlefield with two +1/+1 counters on it instead of putting it into your graveyard"; + } + + public DodecapodEffect(final DodecapodEffect effect) { + super(effect); + } + + @Override + public DodecapodEffect copy() { + return new DodecapodEffect(this); + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + if(super.replaceEvent(event, source, game)) { + new AddCountersSourceEffect(CounterType.P1P1.createInstance(2)).apply(game, source); + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/DragonArch.java b/Mage.Sets/src/mage/sets/apocalypse/DragonArch.java index ebf26f8065c..60fe65ac0ee 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/DragonArch.java +++ b/Mage.Sets/src/mage/sets/apocalypse/DragonArch.java @@ -32,7 +32,7 @@ import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.PutCreatureOnBattlefieldEffect; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; @@ -58,7 +58,7 @@ public class DragonArch extends CardImpl { this.expansionSetCode = "APC"; // {2}, {T}: You may put a multicolored creature card from your hand onto the battlefield. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutCreatureOnBattlefieldEffect(filter), + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutPermanentOnBattlefieldEffect(filter), new ManaCostsImpl("{2}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/apocalypse/DwarvenLandslide.java b/Mage.Sets/src/mage/sets/apocalypse/DwarvenLandslide.java new file mode 100644 index 00000000000..4edae4f5649 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/DwarvenLandslide.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.costs.Cost; +import mage.abilities.costs.Costs; +import mage.abilities.costs.CostsImpl; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.game.Game; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LevelX2 + */ +public class DwarvenLandslide extends CardImpl { + + public DwarvenLandslide(UUID ownerId) { + super(ownerId, 60, "Dwarven Landslide", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{3}{R}"); + this.expansionSetCode = "APC"; + + // Kicker-{2}{R}, Sacrifice a land. + Costs kickerCosts = new CostsImpl<>(); + kickerCosts.add(new ManaCostsImpl<>("{2}{R}")); + kickerCosts.add(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land")))); + this.addAbility(new KickerAbility(kickerCosts)); + // Destroy target land. If Dwarven Landslide was kicked, destroy another target land. + getSpellAbility().addEffect(new DestroyTargetEffect("Destroy target land. If {this} was kicked, destroy another target land")); + } + + public DwarvenLandslide(final DwarvenLandslide card) { + super(card); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + ability.addTarget(new TargetLandPermanent(KickedCondition.getInstance().apply(game, ability) ? 2 : 1)); + } + + @Override + public DwarvenLandslide copy() { + return new DwarvenLandslide(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/EnlistmentOfficer.java b/Mage.Sets/src/mage/sets/apocalypse/EnlistmentOfficer.java index 1f51b2b2680..2b46d650488 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/EnlistmentOfficer.java +++ b/Mage.Sets/src/mage/sets/apocalypse/EnlistmentOfficer.java @@ -29,29 +29,32 @@ package mage.sets.apocalypse; import java.util.UUID; import mage.MageInt; -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; import mage.abilities.keyword.FirstStrikeAbility; -import mage.cards.Card; import mage.cards.CardImpl; -import mage.cards.Cards; -import mage.cards.CardsImpl; import mage.constants.CardType; -import mage.constants.Outcome; +import mage.constants.Duration; import mage.constants.Rarity; import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; import mage.filter.FilterCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.players.Player; + /** * * @author fireshoes */ public class EnlistmentOfficer extends CardImpl { + private static final FilterCard filter = new FilterCard("Soldier cards"); + + static { + filter.add(new SubtypePredicate("Soldier")); + } + public EnlistmentOfficer(UUID ownerId) { super(ownerId, 9, "Enlistment Officer", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); this.expansionSetCode = "APC"; @@ -64,7 +67,7 @@ public class EnlistmentOfficer extends CardImpl { // First strike this.addAbility(FirstStrikeAbility.getInstance()); // When Enlistment Officer enters the battlefield, reveal the top four cards of your library. Put all Soldier cards revealed this way into your hand and the rest on the bottom of your library in any order. - this.addAbility(new EntersBattlefieldTriggeredAbility(new EnlistmentOfficerEffect())); + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); } public EnlistmentOfficer(final EnlistmentOfficer card) { @@ -76,45 +79,3 @@ public class EnlistmentOfficer extends CardImpl { return new EnlistmentOfficer(this); } } - -class EnlistmentOfficerEffect extends OneShotEffect { - - private static final FilterCard filter = new FilterCard("Soldier"); - static { - filter.add(new SubtypePredicate("Soldier")); - } - - public EnlistmentOfficerEffect() { - super(Outcome.DrawCard); - this.staticText = "reveal the top four cards of your library. Put all Soldier cards revealed this way into your hand and the rest on the bottom of your library in any order"; - } - - public EnlistmentOfficerEffect(final EnlistmentOfficerEffect effect) { - super(effect); - } - - @Override - public EnlistmentOfficerEffect copy() { - return new EnlistmentOfficerEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller == null || sourceObject == null) { - return false; - } - Cards cards = new CardsImpl(); - cards.addAll(controller.getLibrary().getTopCards(game, 4)); - controller.revealCards(sourceObject.getName(), cards, game); - for (Card card: cards.getCards(game)) { - if (filter.match(card, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - cards.remove(card); - } - } - controller.putCardsOnBottomOfLibrary(cards, game, source, true); - return true; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/apocalypse/FerventCharge.java b/Mage.Sets/src/mage/sets/apocalypse/FerventCharge.java new file mode 100644 index 00000000000..495197d62de --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/FerventCharge.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.common.AttacksCreatureYouControlTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class FerventCharge extends CardImpl { + + public FerventCharge(UUID ownerId) { + super(ownerId, 98, "Fervent Charge", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}{B}{R}"); + this.expansionSetCode = "APC"; + + // Whenever a creature you control attacks, it gets +2/+2 until end of turn. + Effect effect = new BoostTargetEffect(2, 2, Duration.EndOfTurn); + effect.setText("it gets +2/+2 until end of turn"); + this.addAbility(new AttacksCreatureYouControlTriggeredAbility(effect, false, true)); + } + + public FerventCharge(final FerventCharge card) { + super(card); + } + + @Override + public FerventCharge copy() { + return new FerventCharge(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/FoulPresence.java b/Mage.Sets/src/mage/sets/apocalypse/FoulPresence.java new file mode 100644 index 00000000000..67ad72ed4e1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/FoulPresence.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class FoulPresence extends CardImpl { + + public FoulPresence(UUID ownerId) { + super(ownerId, 39, "Foul Presence", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "APC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.UnboostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Enchanted creature gets -1/-1 and has "{T}: Target creature gets -1/-1 until end of turn." + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(-1, -1, Duration.WhileOnBattlefield)); + Ability gainedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostTargetEffect(-1, -1, Duration.EndOfTurn), new TapSourceCost()); + gainedAbility.addTarget(new TargetCreaturePermanent()); + Effect effect = new GainAbilityAttachedEffect(gainedAbility, AttachmentType.AURA, Duration.WhileOnBattlefield); + effect.setText("and has \"{T}: Target creature gets -1/-1 until end of turn.\""); + ability.addEffect(effect); + this.addAbility(ability); + } + + public FoulPresence(final FoulPresence card) { + super(card); + } + + @Override + public FoulPresence copy() { + return new FoulPresence(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/FungalShambler.java b/Mage.Sets/src/mage/sets/apocalypse/FungalShambler.java new file mode 100644 index 00000000000..385de243c2c --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/FungalShambler.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class FungalShambler extends CardImpl { + + public FungalShambler(UUID ownerId) { + super(ownerId, 100, "Fungal Shambler", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{G}{U}{B}"); + this.expansionSetCode = "APC"; + this.subtype.add("Fungus"); + this.subtype.add("Beast"); + this.power = new MageInt(6); + this.toughness = new MageInt(4); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + // Whenever Fungal Shambler deals damage to an opponent, you draw a card and that opponent discards a card. + Effect effect = new DrawCardSourceControllerEffect(1); + effect.setText("you draw a card"); + Ability ability = new DealsDamageToOpponentTriggeredAbility(effect, false); + effect = new DiscardTargetEffect(1); + effect.setText("and that opponent discards a card"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public FungalShambler(final FungalShambler card) { + super(card); + } + + @Override + public FungalShambler copy() { + return new FungalShambler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/GoblinRingleader.java b/Mage.Sets/src/mage/sets/apocalypse/GoblinRingleader.java index 2594b49c05b..31446160675 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/GoblinRingleader.java +++ b/Mage.Sets/src/mage/sets/apocalypse/GoblinRingleader.java @@ -29,23 +29,19 @@ package mage.sets.apocalypse; import java.util.UUID; import mage.MageInt; -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; import mage.abilities.keyword.HasteAbility; -import mage.cards.Card; import mage.cards.CardImpl; -import mage.cards.Cards; -import mage.cards.CardsImpl; import mage.constants.CardType; -import mage.constants.Outcome; +import mage.constants.Duration; import mage.constants.Rarity; import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; import mage.filter.FilterCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.players.Player; /** * @@ -53,6 +49,12 @@ import mage.players.Player; */ public class GoblinRingleader extends CardImpl { + private static final FilterCard filter = new FilterCard("Goblin cards"); + + static { + filter.add(new SubtypePredicate("Goblin")); + } + public GoblinRingleader(UUID ownerId) { super(ownerId, 62, "Goblin Ringleader", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); this.expansionSetCode = "APC"; @@ -64,7 +66,7 @@ public class GoblinRingleader extends CardImpl { // Haste this.addAbility(HasteAbility.getInstance()); // When Goblin Ringleader enters the battlefield, reveal the top four cards of your library. Put all Goblin cards revealed this way into your hand and the rest on the bottom of your library in any order. - this.addAbility(new EntersBattlefieldTriggeredAbility(new GoblinRingleaderEffect())); + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); } public GoblinRingleader(final GoblinRingleader card) { @@ -76,45 +78,3 @@ public class GoblinRingleader extends CardImpl { return new GoblinRingleader(this); } } - -class GoblinRingleaderEffect extends OneShotEffect { - - private static final FilterCard filter = new FilterCard("Goblin"); - static { - filter.add(new SubtypePredicate("Goblin")); - } - - public GoblinRingleaderEffect() { - super(Outcome.DrawCard); - this.staticText = "reveal the top four cards of your library. Put all Goblin cards revealed this way into your hand and the rest on the bottom of your library in any order"; - } - - public GoblinRingleaderEffect(final GoblinRingleaderEffect effect) { - super(effect); - } - - @Override - public GoblinRingleaderEffect copy() { - return new GoblinRingleaderEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller == null || sourceObject == null) { - return false; - } - Cards cards = new CardsImpl(); - cards.addAll(controller.getLibrary().getTopCards(game, 4)); - controller.revealCards(sourceObject.getName(), cards, game); - for (Card card: cards.getCards(game)) { - if (filter.match(card, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - cards.remove(card); - } - } - controller.putCardsOnBottomOfLibrary(cards, game, source, true); - return true; - } -} diff --git a/Mage.Sets/src/mage/sets/apocalypse/GraveDefiler.java b/Mage.Sets/src/mage/sets/apocalypse/GraveDefiler.java new file mode 100644 index 00000000000..32f78b77b22 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/GraveDefiler.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class GraveDefiler extends CardImpl { + + private static final FilterCard filter = new FilterCard("Zombie cards"); + + static { + filter.add(new SubtypePredicate("Zombie")); + } + + public GraveDefiler(UUID ownerId) { + super(ownerId, 40, "Grave Defiler", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "APC"; + this.subtype.add("Zombie"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // When Grave Defiler enters the battlefield, reveal the top four cards of your library. Put all Zombie cards revealed this way into your hand and the rest on the bottom of your library in any order. + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); + // {1}{B}: Regenerate Grave Defiler. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{1}{B}"))); } + + public GraveDefiler(final GraveDefiler card) { + super(card); + } + + @Override + public GraveDefiler copy() { + return new GraveDefiler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/Illuminate.java b/Mage.Sets/src/mage/sets/apocalypse/Illuminate.java new file mode 100644 index 00000000000..d5e8769fbb2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/Illuminate.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.condition.common.KickedCostCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.effects.common.DamageTargetControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Illuminate extends CardImpl { + + public Illuminate(UUID ownerId) { + super(ownerId, 63, "Illuminate", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{X}{R}"); + this.expansionSetCode = "APC"; + + // Kicker {2}{R} and/or {3}{U} + KickerAbility kickerAbility = new KickerAbility("{2}{R}"); + kickerAbility.addKickerCost("{3}{U}"); + this.addAbility(kickerAbility); + // Illuminate deals X damage to target creature. If Illuminate was kicked with its {2}{R} kicker, it deals X damage to that creature's controller. If Illuminate was kicked with its {3}{U} kicker, you draw X cards. + this.getSpellAbility().addEffect(new DamageTargetEffect(new ManacostVariableValue())); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new DamageTargetControllerEffect(new ManacostVariableValue()), + new KickedCostCondition("{2}{R}"), + "If {this} was kicked with its {2}{R} kicker, it deals X damage to that creature's controller.")); + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new DrawCardSourceControllerEffect(new ManacostVariableValue()), + new KickedCostCondition("{3}{U}"), + "If {this} was kicked with its {3}{U} kicker, you draw X cards.")); + + } + + public Illuminate(final Illuminate card) { + super(card); + } + + @Override + public Illuminate copy() { + return new Illuminate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/Jilt.java b/Mage.Sets/src/mage/sets/apocalypse/Jilt.java new file mode 100644 index 00000000000..1dc7fa14ae4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/Jilt.java @@ -0,0 +1,111 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.target.common.TargetCreaturePermanent; +import mage.target.targetpointer.SecondTargetPointer; + +/** + * + * @author fireshoes + */ +public class Jilt extends CardImpl { + + public Jilt(UUID ownerId) { + super(ownerId, 27, "Jilt", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "APC"; + + // Kicker {1}{R} + this.addAbility(new KickerAbility("{1}{R}")); + + // Return target creature to its owner's hand. If Jilt was kicked, it deals 2 damage to another target creature. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + Effect effect = new ConditionalOneShotEffect( + new DamageTargetEffect(2), + KickedCondition.getInstance(), + "If {this} was kicked, it deals 2 damage to another target creature"); + effect.setTargetPointer(new SecondTargetPointer()); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability instanceof SpellAbility && KickedCondition.getInstance().apply(game, ability)) { + ability.addTarget(new TargetOtherCreaturePermanent(new FilterCreaturePermanent("another target creature"))); + } + + } + + public Jilt(final Jilt card) { + super(card); + } + + @Override + public Jilt copy() { + return new Jilt(this); + } +} + +class TargetOtherCreaturePermanent extends TargetCreaturePermanent { + + public TargetOtherCreaturePermanent(FilterCreaturePermanent filter) { + super(filter); + } + + public TargetOtherCreaturePermanent(final TargetOtherCreaturePermanent target) { + super(target); + } + + @Override + public boolean canTarget(UUID controllerId, UUID id, Ability source, Game game) { + if (source.getTargets().get(0).getTargets().contains(id)) { + return false; + } + return super.canTarget(controllerId, id, source, game); + } + + @Override + public TargetOtherCreaturePermanent copy() { + return new TargetOtherCreaturePermanent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/KavuHowler.java b/Mage.Sets/src/mage/sets/apocalypse/KavuHowler.java index 7e339821ac5..5a724d26974 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/KavuHowler.java +++ b/Mage.Sets/src/mage/sets/apocalypse/KavuHowler.java @@ -29,29 +29,31 @@ package mage.sets.apocalypse; import java.util.UUID; import mage.MageInt; -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.keyword.FirstStrikeAbility; -import mage.cards.Card; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; import mage.cards.CardImpl; -import mage.cards.Cards; -import mage.cards.CardsImpl; import mage.constants.CardType; -import mage.constants.Outcome; +import mage.constants.Duration; import mage.constants.Rarity; import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; import mage.filter.FilterCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.players.Player; + /** * * @author fireshoes */ public class KavuHowler extends CardImpl { + private static final FilterCard filter = new FilterCard("Kavu cards"); + + static { + filter.add(new SubtypePredicate("Kavu")); + } + public KavuHowler(UUID ownerId) { super(ownerId, 79, "Kavu Howler", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{G}{G}"); this.expansionSetCode = "APC"; @@ -61,8 +63,7 @@ public class KavuHowler extends CardImpl { this.toughness = new MageInt(5); // When Kavu Howler enters the battlefield, reveal the top four cards of your library. Put all Kavu cards revealed this way into your hand and the rest on the bottom of your library in any order. - this.addAbility(new EntersBattlefieldTriggeredAbility(new KavuHowlerEffect())); - + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); } public KavuHowler(final KavuHowler card) { @@ -74,45 +75,3 @@ public class KavuHowler extends CardImpl { return new KavuHowler(this); } } - -class KavuHowlerEffect extends OneShotEffect { - - private static final FilterCard filter = new FilterCard("Kavu"); - static { - filter.add(new SubtypePredicate("Kavu")); - } - - public KavuHowlerEffect() { - super(Outcome.DrawCard); - this.staticText = "reveal the top four cards of your library. Put all Kavu cards revealed this way into your hand and the rest on the bottom of your library in any order"; - } - - public KavuHowlerEffect(final KavuHowlerEffect effect) { - super(effect); - } - - @Override - public KavuHowlerEffect copy() { - return new KavuHowlerEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller == null || sourceObject == null) { - return false; - } - Cards cards = new CardsImpl(); - cards.addAll(controller.getLibrary().getTopCards(game, 4)); - controller.revealCards(sourceObject.getName(), cards, game); - for (Card card: cards.getCards(game)) { - if (filter.match(card, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - cards.remove(card); - } - } - controller.putCardsOnBottomOfLibrary(cards, game, source, true); - return true; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/apocalypse/KavuMauler.java b/Mage.Sets/src/mage/sets/apocalypse/KavuMauler.java new file mode 100644 index 00000000000..131fc3391fd --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/KavuMauler.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterAttackingCreature; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author LoneFox + */ +public class KavuMauler extends CardImpl { + + private static final FilterAttackingCreature filter = new FilterAttackingCreature("other attacking Kavu"); + + static { + filter.add(new SubtypePredicate("Kavu")); + filter.add(new AnotherPredicate()); + } + + public KavuMauler(UUID ownerId) { + super(ownerId, 80, "Kavu Mauler", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{G}{G}"); + this.expansionSetCode = "APC"; + this.subtype.add("Kavu"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + // Whenever Kavu Mauler attacks, it gets +1/+1 until end of turn for each other attacking Kavu. + PermanentsOnBattlefieldCount value = new PermanentsOnBattlefieldCount(filter); + this.addAbility(new AttacksTriggeredAbility(new BoostSourceEffect(value, value, Duration.EndOfTurn, true), false)); + } + + public KavuMauler(final KavuMauler card) { + super(card); + } + + @Override + public KavuMauler copy() { + return new KavuMauler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/MaskOfIntolerance.java b/Mage.Sets/src/mage/sets/apocalypse/MaskOfIntolerance.java new file mode 100644 index 00000000000..c0ac3330e6e --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/MaskOfIntolerance.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.IntCompareCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.Game; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + */ +public class MaskOfIntolerance extends CardImpl { + + public MaskOfIntolerance(UUID ownerId) { + super(ownerId, 138, "Mask of Intolerance", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "APC"; + + // At the beginning of each player's upkeep, if there are four or more basic land types among lands that player controls, Mask of Intolerance deals 3 damage to him or her. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageTargetEffect(3), TargetController.ANY, false); + this.addAbility(new ConditionalTriggeredAbility(ability, new MaskOfIntoleranceCondition(), + "At the beginning of each player's upkeep, if there are four or more basic land types among lands that player controls, {this} deals 3 damage to him or her.")); + } + + public MaskOfIntolerance(final MaskOfIntolerance card) { + super(card); + } + + @Override + public MaskOfIntolerance copy() { + return new MaskOfIntolerance(this); + } +} + +class MaskOfIntoleranceCondition extends IntCompareCondition { + + public MaskOfIntoleranceCondition() { + super(ComparisonType.GreaterThan, 3); + } + + @Override + protected int getInputValue(Game game, Ability source) { + return new DomainValue(1, game.getActivePlayerId()).calculate(game, source, null); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/MinotaurTactician.java b/Mage.Sets/src/mage/sets/apocalypse/MinotaurTactician.java new file mode 100644 index 00000000000..b838ecdd088 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/MinotaurTactician.java @@ -0,0 +1,96 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition.CountType; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class MinotaurTactician extends CardImpl { + + private static final FilterControlledCreaturePermanent filterWhite = new FilterControlledCreaturePermanent(); + private static final FilterControlledCreaturePermanent filterBlue = new FilterControlledCreaturePermanent(); + + static { + filterWhite.add(new ColorPredicate(ObjectColor.WHITE)); + filterBlue.add(new ColorPredicate(ObjectColor.BLUE)); + } + + final private String ruleWhite = "{this} gets +1/+1 as long as you control another white creature"; + + final private String ruleBlue = "{this} gets +1/+1 as long as you control another white creature"; + + public MinotaurTactician(UUID ownerId) { + super(ownerId, 65, "Minotaur Tactician", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "APC"; + this.subtype.add("Minotaur"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Haste + this.addAbility(HasteAbility.getInstance()); + + // Minotaur Tactician gets +1/+1 as long as you control a white creature. + Condition conditionWhite = new PermanentsOnTheBattlefieldCondition(filterWhite, CountType.MORE_THAN, 0); + Effect effectWhite = new ConditionalContinuousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), conditionWhite, ruleWhite); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effectWhite)); + + // Minotaur Tactician gets +1/+1 as long as you control a blue creature. + Condition conditionBlue = new PermanentsOnTheBattlefieldCondition(filterBlue, CountType.MORE_THAN, 0); + Effect effectBlue = new ConditionalContinuousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), conditionBlue, ruleBlue); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effectBlue)); + } + + public MinotaurTactician(final MinotaurTactician card) { + super(card); + } + + @Override + public MinotaurTactician copy() { + return new MinotaurTactician(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/PutridWarrior.java b/Mage.Sets/src/mage/sets/apocalypse/PutridWarrior.java new file mode 100644 index 00000000000..5c166fb112d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/PutridWarrior.java @@ -0,0 +1,144 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.LoseLifeAllPlayersEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; +import mage.players.Player; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + + */ +public class PutridWarrior extends CardImpl { + + public PutridWarrior(UUID ownerId) { + super(ownerId, 117, "Putrid Warrior", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}{B}"); + this.expansionSetCode = "APC"; + this.subtype.add("Zombie"); + this.subtype.add("Soldier"); + this.subtype.add("Warrior"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Putrid Warrior deals damage, choose one - Each player loses 1 life; or each player gains 1 life. + Ability ability = new PutridWarriorDealsDamageTriggeredAbility(new LoseLifeAllPlayersEffect(1)); + Mode mode = new Mode(); + mode.getEffects().add(new PutridWarriorGainLifeEffect()); + ability.addMode(mode); + this.addAbility(ability); + } + + public PutridWarrior(final PutridWarrior card) { + super(card); + } + + @Override + public PutridWarrior copy() { + return new PutridWarrior(this); + } +} + + +class PutridWarriorDealsDamageTriggeredAbility extends TriggeredAbilityImpl { + + public PutridWarriorDealsDamageTriggeredAbility(Effect effect) { + super(Zone.BATTLEFIELD, effect, false); + } + + public PutridWarriorDealsDamageTriggeredAbility(final PutridWarriorDealsDamageTriggeredAbility ability) { + super(ability); + } + + @Override + public PutridWarriorDealsDamageTriggeredAbility copy() { + return new PutridWarriorDealsDamageTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.DAMAGED_PLAYER || event.getType() == EventType.DAMAGED_CREATURE + || event.getType() == EventType.DAMAGED_PLANESWALKER; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return event.getSourceId().equals(this.sourceId); + } + + @Override + public String getRule() { + return "Whenever {this} deals damage, " + super.getRule(); + } +} + + +class PutridWarriorGainLifeEffect extends OneShotEffect { + + public PutridWarriorGainLifeEffect() { + super(Outcome.GainLife); + staticText = "Each player gains 1 life."; + } + + public PutridWarriorGainLifeEffect(final PutridWarriorGainLifeEffect effect) { + super(effect); + } + + @Override + public PutridWarriorGainLifeEffect copy() { + return new PutridWarriorGainLifeEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for(UUID playerId: game.getPlayer(source.getControllerId()).getInRange()) { + Player player = game.getPlayer(playerId); + if(player != null) { + player.gainLife(1, game); + } + } + return true; + } + +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java b/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java new file mode 100644 index 00000000000..a66ce005308 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class ReefShaman extends CardImpl { + + public ReefShaman(UUID ownerId) { + super(ownerId, 29, "Reef Shaman", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "APC"; + this.subtype.add("Merfolk"); + this.subtype.add("Shaman"); + this.power = new MageInt(0); + this.toughness = new MageInt(2); + + // {T}: Target land becomes the basic land type of your choice until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public ReefShaman(final ReefShaman card) { + super(card); + } + + @Override + public ReefShaman copy() { + return new ReefShaman(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/ShieldOfDutyAndReason.java b/Mage.Sets/src/mage/sets/apocalypse/ShieldOfDutyAndReason.java new file mode 100644 index 00000000000..c1f2b60d39b --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/ShieldOfDutyAndReason.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.ObjectColor; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ShieldOfDutyAndReason extends CardImpl { + + private static final FilterCard filter = new FilterCard("green and from blue"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.GREEN), new ColorPredicate(ObjectColor.BLUE))); + } + + public ShieldOfDutyAndReason(UUID ownerId) { + super(ownerId, 16, "Shield of Duty and Reason", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}"); + this.expansionSetCode = "APC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Enchanted creature has protection from green and from blue. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), + AttachmentType.AURA, Duration.WhileOnBattlefield))); + } + + public ShieldOfDutyAndReason(final ShieldOfDutyAndReason card) { + super(card); + } + + @Override + public ShieldOfDutyAndReason copy() { + return new ShieldOfDutyAndReason(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/ShimmeringMirage.java b/Mage.Sets/src/mage/sets/apocalypse/ShimmeringMirage.java new file mode 100644 index 00000000000..34e9fd56802 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/ShimmeringMirage.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class ShimmeringMirage extends CardImpl { + + public ShimmeringMirage(UUID ownerId) { + super(ownerId, 30, "Shimmering Mirage", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "APC"; + + // Target land becomes the basic land type of your choice until end of turn. + this.getSpellAbility().addEffect(new BecomesBasicLandTargetEffect(Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetLandPermanent()); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public ShimmeringMirage(final ShimmeringMirage card) { + super(card); + } + + @Override + public ShimmeringMirage copy() { + return new ShimmeringMirage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/SoulLink.java b/Mage.Sets/src/mage/sets/apocalypse/SoulLink.java new file mode 100644 index 00000000000..dbfb8ef7510 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/SoulLink.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageAttachedTriggeredAbility; +import mage.abilities.common.DamageDealtToAttachedTriggeredAbility; +import mage.abilities.dynamicvalue.common.NumericSetToEffectValues; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class SoulLink extends CardImpl { + + public SoulLink(UUID ownerId) { + super(ownerId, 120, "Soul Link", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}{B}"); + this.expansionSetCode = "APC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Whenever enchanted creature deals damage, you gain that much life. + this.addAbility(new DealsDamageAttachedTriggeredAbility(Zone.BATTLEFIELD, + new GainLifeEffect(new NumericSetToEffectValues("that much", "damage")), false)); + // Whenever enchanted creature is dealt damage, you gain that much life. + this.addAbility(new DamageDealtToAttachedTriggeredAbility(new GainLifeEffect(new NumericSetToEffectValues("that much", "damage")), false)); + } + + public SoulLink(final SoulLink card) { + super(card); + } + + @Override + public SoulLink copy() { + return new SoulLink(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/SqueesEmbrace.java b/Mage.Sets/src/mage/sets/apocalypse/SqueesEmbrace.java new file mode 100644 index 00000000000..15236cb021c --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/SqueesEmbrace.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.DiesAttachedTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandAttachedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SqueesEmbrace extends CardImpl { + + public SqueesEmbrace(UUID ownerId) { + super(ownerId, 122, "Squee's Embrace", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{R}{W}"); + this.expansionSetCode = "APC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature gets +2/+2. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(2, 2, Duration.WhileOnBattlefield))); + + // When enchanted creature dies, return that card to its owner's hand. + this.addAbility(new DiesAttachedTriggeredAbility(new ReturnToHandAttachedEffect(), "enchanted creature")); + } + + public SqueesEmbrace(final SqueesEmbrace card) { + super(card); + } + + @Override + public SqueesEmbrace copy() { + return new SqueesEmbrace(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/SqueesRevenge.java b/Mage.Sets/src/mage/sets/apocalypse/SqueesRevenge.java new file mode 100644 index 00000000000..b513bdc569d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/SqueesRevenge.java @@ -0,0 +1,95 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author LoneFox + */ +public class SqueesRevenge extends CardImpl { + + public SqueesRevenge(UUID ownerId) { + super(ownerId, 123, "Squee's Revenge", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{U}{R}"); + this.expansionSetCode = "APC"; + + // Choose a number. Flip a coin that many times or until you lose a flip, whichever comes first. If you win all the flips, draw two cards for each flip. + this.getSpellAbility().addEffect(new SqueesRevengeEffect()); + } + + public SqueesRevenge(final SqueesRevenge card) { + super(card); + } + + @Override + public SqueesRevenge copy() { + return new SqueesRevenge(this); + } +} + +class SqueesRevengeEffect extends OneShotEffect { + + public SqueesRevengeEffect() { + super(Outcome.DrawCard); + staticText = "Choose a number. Flip a coin that many times or until you lose a flip, whichever comes first. If you win all the flips, draw two cards for each flip."; + } + + public SqueesRevengeEffect(final SqueesRevengeEffect effect) { + super(effect); + } + + public SqueesRevengeEffect copy() { + return new SqueesRevengeEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if(player != null) { + int number = player.announceXMana(0, Integer.MAX_VALUE, "Choose how many times to flip a coin", game, source); + game.informPlayers(player.getLogName() + " chooses " + number + "."); + for(int i = 0; i < number; i++) { + if(!player.flipCoin(game)) { + return true; + } + } + player.drawCards(2 * number, game); + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/SuffocatingBlast.java b/Mage.Sets/src/mage/sets/apocalypse/SuffocatingBlast.java new file mode 100644 index 00000000000..b0e3f6ee67e --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/SuffocatingBlast.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetSpell; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class SuffocatingBlast extends CardImpl { + + public SuffocatingBlast(UUID ownerId) { + super(ownerId, 124, "Suffocating Blast", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{U}{U}{R}"); + this.expansionSetCode = "APC"; + + // Counter target spell and Suffocating Blast deals 3 damage to target creature. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetSpell()); + Effect effect = new DamageTargetEffect(3); + effect.setText("and {this} deals 3 damage to target creature"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public SuffocatingBlast(final SuffocatingBlast card) { + super(card); + } + + @Override + public SuffocatingBlast copy() { + return new SuffocatingBlast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/SylvanMessenger.java b/Mage.Sets/src/mage/sets/apocalypse/SylvanMessenger.java index 6c865543d5a..ebd4641c225 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/SylvanMessenger.java +++ b/Mage.Sets/src/mage/sets/apocalypse/SylvanMessenger.java @@ -29,29 +29,32 @@ package mage.sets.apocalypse; import java.util.UUID; import mage.MageInt; -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; import mage.abilities.keyword.TrampleAbility; -import mage.cards.Card; import mage.cards.CardImpl; -import mage.cards.Cards; -import mage.cards.CardsImpl; import mage.constants.CardType; -import mage.constants.Outcome; +import mage.constants.Duration; import mage.constants.Rarity; import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; import mage.filter.FilterCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.players.Player; + /** * * @author LevelX2 */ public class SylvanMessenger extends CardImpl { + private static final FilterCard filter = new FilterCard("Elf cards"); + + static { + filter.add(new SubtypePredicate("Elf")); + } + public SylvanMessenger(UUID ownerId) { super(ownerId, 87, "Sylvan Messenger", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); this.expansionSetCode = "APC"; @@ -63,8 +66,7 @@ public class SylvanMessenger extends CardImpl { // Trample this.addAbility(TrampleAbility.getInstance()); // When Sylvan Messenger enters the battlefield, reveal the top four cards of your library. Put all Elf cards revealed this way into your hand and the rest on the bottom of your library in any order. - this.addAbility(new EntersBattlefieldTriggeredAbility(new SylvanMessengerEffect())); - + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); } public SylvanMessenger(final SylvanMessenger card) { @@ -76,45 +78,3 @@ public class SylvanMessenger extends CardImpl { return new SylvanMessenger(this); } } - -class SylvanMessengerEffect extends OneShotEffect { - - private static final FilterCard filter = new FilterCard("Elf"); - static { - filter.add(new SubtypePredicate("Elf")); - } - - public SylvanMessengerEffect() { - super(Outcome.DrawCard); - this.staticText = "reveal the top four cards of your library. Put all Elf cards revealed this way into your hand and the rest on the bottom of your library in any order"; - } - - public SylvanMessengerEffect(final SylvanMessengerEffect effect) { - super(effect); - } - - @Override - public SylvanMessengerEffect copy() { - return new SylvanMessengerEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller == null || sourceObject == null) { - return false; - } - Cards cards = new CardsImpl(); - cards.addAll(controller.getLibrary().getTopCards(game, 4)); - controller.revealCards(sourceObject.getName(), cards, game); - for (Card card: cards.getCards(game)) { - if (filter.match(card, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - cards.remove(card); - } - } - controller.putCardsOnBottomOfLibrary(cards, game, source, true); - return true; - } -} diff --git a/Mage.Sets/src/mage/sets/apocalypse/TidalCourier.java b/Mage.Sets/src/mage/sets/apocalypse/TidalCourier.java new file mode 100644 index 00000000000..a88c420529d --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/TidalCourier.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.EnvoyEffect; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class TidalCourier extends CardImpl { + + private static final FilterCard filter = new FilterCard("Merfolk cards"); + + static { + filter.add(new SubtypePredicate("Merfolk")); + } + + public TidalCourier(UUID ownerId) { + super(ownerId, 31, "Tidal Courier", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "APC"; + this.subtype.add("Merfolk"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // When Tidal Courier enters the battlefield, reveal the top four cards of your library. Put all Merfolk cards revealed this way into your hand and the rest on the bottom of your library in any order. + this.addAbility(new EntersBattlefieldTriggeredAbility(new EnvoyEffect(filter, 4))); + // {3}{U}: Tidal Courier gains flying until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FlyingAbility.getInstance(), + Duration.EndOfTurn), new ManaCostsImpl("{3}{U}"))); + } + + public TidalCourier(final TidalCourier card) { + super(card); + } + + @Override + public TidalCourier copy() { + return new TidalCourier(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/TundraKavu.java b/Mage.Sets/src/mage/sets/apocalypse/TundraKavu.java new file mode 100644 index 00000000000..e1f72960bf5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/TundraKavu.java @@ -0,0 +1,112 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.LinkedHashSet; +import java.util.Set; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class TundraKavu extends CardImpl { + + public TundraKavu(UUID ownerId) { + super(ownerId, 71, "Tundra Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "APC"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {T}: Target land becomes a Plains or an Island until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TundraKavuEffect(), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public TundraKavu(final TundraKavu card) { + super(card); + } + + @Override + public TundraKavu copy() { + return new TundraKavu(this); + } +} + + +class TundraKavuEffect extends BecomesBasicLandTargetEffect { + + public TundraKavuEffect() { + super(Duration.EndOfTurn, false, true, ""); + staticText = "Target land becomes a Plains or an Island until end of turn."; + } + + public TundraKavuEffect(final TundraKavuEffect effect) { + super(effect); + } + + public TundraKavuEffect copy() { + return new TundraKavuEffect(this); + } + + @Override + public void init(Ability source, Game game) { + landTypes.clear(); + Player controller = game.getPlayer(source.getControllerId()); + if(controller != null) { + Set choiceSet = new LinkedHashSet<>(); + choiceSet.add("Island"); + choiceSet.add("Plains"); + ChoiceImpl choice = new ChoiceImpl(true); + choice.setChoices(choiceSet); + choice.setMessage("Choose a basic land type"); + controller.choose(outcome, choice, game); + landTypes.add(choice.getChoice()); + } else { + this.discard(); + } + + super.init(source, game); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/VodalianMystic.java b/Mage.Sets/src/mage/sets/apocalypse/VodalianMystic.java new file mode 100644 index 00000000000..a46c45b9817 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/VodalianMystic.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.apocalypse; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterSpell; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetSpell; + +/** + * + * @author LoneFox + */ +public class VodalianMystic extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("instant or sorcery spell"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.INSTANT), + new CardTypePredicate(CardType.SORCERY))); + } + + public VodalianMystic(UUID ownerId) { + super(ownerId, 33, "Vodalian Mystic", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "APC"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Target instant or sorcery spell becomes the color of your choice. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(Duration.WhileOnStack), new TapSourceCost()); + ability.addTarget(new TargetSpell(filter)); + this.addAbility(ability); + } + + public VodalianMystic(final VodalianMystic card) { + super(card); + } + + @Override + public VodalianMystic copy() { + return new VodalianMystic(this); + } +} diff --git a/Mage.Sets/src/mage/sets/apocalypse/WildResearch.java b/Mage.Sets/src/mage/sets/apocalypse/WildResearch.java index 37eba90ac71..7784cb8d7f8 100644 --- a/Mage.Sets/src/mage/sets/apocalypse/WildResearch.java +++ b/Mage.Sets/src/mage/sets/apocalypse/WildResearch.java @@ -28,6 +28,7 @@ package mage.sets.apocalypse; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ManaCostsImpl; @@ -51,9 +52,10 @@ import mage.target.common.TargetCardInLibrary; * @author emerald000 */ public class WildResearch extends CardImpl { - + private static final FilterCard filterEnchantment = new FilterCard("enchantment card"); private static final FilterCard filterInstant = new FilterCard("instant card"); + static { filterEnchantment.add(new CardTypePredicate(CardType.ENCHANTMENT)); filterInstant.add(new CardTypePredicate(CardType.INSTANT)); @@ -65,7 +67,7 @@ public class WildResearch extends CardImpl { // {1}{W}: Search your library for an enchantment card and reveal that card. Put it into your hand, then discard a card at random. Then shuffle your library. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new WildResearchEffect(filterEnchantment), new ManaCostsImpl<>("{1}{W}"))); - + // {1}{U}: Search your library for an instant card and reveal that card. Put it into your hand, then discard a card at random. Then shuffle your library. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new WildResearchEffect(filterInstant), new ManaCostsImpl<>("{1}{U}"))); @@ -82,43 +84,44 @@ public class WildResearch extends CardImpl { } class WildResearchEffect extends OneShotEffect { - + protected final FilterCard filter; - + WildResearchEffect(FilterCard filter) { super(Outcome.DrawCard); this.staticText = "Search your library for an " + filter.getMessage() + " and reveal that card. Put it into your hand, then discard a card at random. Then shuffle your library."; this.filter = filter; } - + WildResearchEffect(final WildResearchEffect effect) { super(effect); this.filter = effect.filter; } - + @Override public WildResearchEffect copy() { return new WildResearchEffect(this); } - + @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { TargetCardInLibrary target = new TargetCardInLibrary(filter); - if (player.searchLibrary(target, game)) { + if (controller.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { - Card card = player.getLibrary().remove(target.getFirstTarget(), game); + Card card = controller.getLibrary().remove(target.getFirstTarget(), game); if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); Cards cards = new CardsImpl(); cards.add(card); - player.revealCards("Wild Research", cards, game, true); + controller.revealCards(sourceObject.getIdName(), cards, game, true); } } } - player.discardOne(true, source, game); - player.shuffleLibrary(game); + controller.discardOne(true, source, game); + controller.shuffleLibrary(game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/arabiannights/ElHajjaj.java b/Mage.Sets/src/mage/sets/arabiannights/ElHajjaj.java new file mode 100644 index 00000000000..30ee2520dd9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/arabiannights/ElHajjaj.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.arabiannights; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ElHajjaj extends CardImpl { + + public ElHajjaj(UUID ownerId) { + super(ownerId, 2, "El-Hajjaj", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{B}"); + this.expansionSetCode = "ARN"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Whenever El-Hajjâj deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public ElHajjaj(final ElHajjaj card) { + super(card); + } + + @Override + public ElHajjaj copy() { + return new ElHajjaj(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/arabiannights/IfhBiffEfreet.java b/Mage.Sets/src/mage/sets/arabiannights/IfhBiffEfreet.java new file mode 100644 index 00000000000..0b1b20df4c7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/arabiannights/IfhBiffEfreet.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.arabiannights; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class IfhBiffEfreet extends mage.sets.mastersedition.IfhBiffEfreet { + + public IfhBiffEfreet(UUID ownerId) { + super(ownerId); + this.cardNumber = 34; + this.expansionSetCode = "ARN"; + } + + public IfhBiffEfreet(final IfhBiffEfreet card) { + super(card); + } + + @Override + public IfhBiffEfreet copy() { + return new IfhBiffEfreet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/arabiannights/IslandFishJasconius.java b/Mage.Sets/src/mage/sets/arabiannights/IslandFishJasconius.java new file mode 100644 index 00000000000..165b82a7109 --- /dev/null +++ b/Mage.Sets/src/mage/sets/arabiannights/IslandFishJasconius.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.arabiannights; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class IslandFishJasconius extends mage.sets.fourthedition.IslandFishJasconius { + + public IslandFishJasconius(UUID ownerId) { + super(ownerId); + this.cardNumber = 22; + this.expansionSetCode = "ARN"; + } + + public IslandFishJasconius(final IslandFishJasconius card) { + super(card); + } + + @Override + public IslandFishJasconius copy() { + return new IslandFishJasconius(this); + } +} diff --git a/Mage.Sets/src/mage/sets/archenemy/WaxWane.java b/Mage.Sets/src/mage/sets/archenemy/WaxWane.java new file mode 100644 index 00000000000..6a8c6b9c1f3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/archenemy/WaxWane.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.archenemy; + +import java.util.UUID; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.SplitCard; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; +import mage.target.common.TargetEnchantmentPermanent; + +/** + * + * @author LoneFox + */ +public class WaxWane extends SplitCard { + + public WaxWane(UUID ownerId) { + super(ownerId, 101, "Wax", "Wane", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{G}", "{W}", false); + this.expansionSetCode = "ARC"; + + // Wax + // Target creature gets +2/+2 until end of turn. + this.getLeftHalfCard().getSpellAbility().addEffect(new BoostTargetEffect(2, 2, Duration.EndOfTurn)); + this.getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent()); + // Wane + // Destroy target enchantment. + this.getRightHalfCard().getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getRightHalfCard().getSpellAbility().addTarget(new TargetEnchantmentPermanent()); + } + + public WaxWane(final WaxWane card) { + super(card); + } + + @Override + public WaxWane copy() { + return new WaxWane(this); + } +} diff --git a/Mage.Sets/src/mage/sets/avacynrestored/Aggravate.java b/Mage.Sets/src/mage/sets/avacynrestored/Aggravate.java index a4a44b9a1d4..b762c36f219 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/Aggravate.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/Aggravate.java @@ -1,143 +1,143 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.avacynrestored; - -import java.util.List; -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.RequirementEffect; -import mage.cards.CardImpl; -import mage.filter.common.FilterCreaturePermanent; -import mage.filter.predicate.permanent.ControllerIdPredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; -import mage.target.TargetPlayer; -import mage.watchers.common.DamagedByWatcher; - -/** - * - * @author North - */ -public class Aggravate extends CardImpl { - - public Aggravate(UUID ownerId) { - super(ownerId, 125, "Aggravate", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{R}{R}"); - this.expansionSetCode = "AVR"; - - - // Aggravate deals 1 damage to each creature target player controls. - this.getSpellAbility().addEffect(new AggraveteEffect()); - this.getSpellAbility().addTarget(new TargetPlayer()); - // Each creature dealt damage this way attacks this turn if able. - this.getSpellAbility().addEffect(new AggravateRequirementEffect()); - this.getSpellAbility().addWatcher(new DamagedByWatcher()); - } - - public Aggravate(final Aggravate card) { - super(card); - } - - @Override - public Aggravate copy() { - return new Aggravate(this); - } -} - -class AggraveteEffect extends OneShotEffect { - - public AggraveteEffect() { - super(Outcome.Damage); - this.staticText = "{this} deals 1 damage to each creature target player controls"; - } - - public AggraveteEffect(final AggraveteEffect effect) { - super(effect); - } - - @Override - public AggraveteEffect copy() { - return new AggraveteEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getFirstTarget()); - if (player != null) { - FilterCreaturePermanent filter = new FilterCreaturePermanent(); - filter.add(new ControllerIdPredicate(player.getId())); - List creatures = game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game); - for (Permanent creature : creatures) { - creature.damage(1, source.getSourceId(), game, false, true); - } - return true; - } - return false; - } -} - -class AggravateRequirementEffect extends RequirementEffect { - - public AggravateRequirementEffect() { - super(Duration.EndOfTurn); - this.staticText = "Each creature dealt damage this way attacks this turn if able"; - } - - public AggravateRequirementEffect(final AggravateRequirementEffect effect) { - super(effect); - } - - @Override - public AggravateRequirementEffect copy() { - return new AggravateRequirementEffect(this); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - DamagedByWatcher watcher = (DamagedByWatcher) game.getState().getWatchers().get("DamagedByWatcher", source.getSourceId()); - if (watcher != null) { - return watcher.wasDamaged(permanent, game); - } - return false; - } - - @Override - public boolean mustAttack(Game game) { - return true; - } - - @Override - public boolean mustBlock(Game game) { - return false; - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.avacynrestored; + +import java.util.List; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.RequirementEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetPlayer; +import mage.watchers.common.DamagedByWatcher; + +/** + * + * @author North + */ +public class Aggravate extends CardImpl { + + public Aggravate(UUID ownerId) { + super(ownerId, 125, "Aggravate", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{R}{R}"); + this.expansionSetCode = "AVR"; + + + // Aggravate deals 1 damage to each creature target player controls. + this.getSpellAbility().addEffect(new AggravateEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + // Each creature dealt damage this way attacks this turn if able. + this.getSpellAbility().addEffect(new AggravateRequirementEffect()); + this.getSpellAbility().addWatcher(new DamagedByWatcher()); + } + + public Aggravate(final Aggravate card) { + super(card); + } + + @Override + public Aggravate copy() { + return new Aggravate(this); + } +} + +class AggravateEffect extends OneShotEffect { + + public AggravateEffect() { + super(Outcome.Damage); + this.staticText = "{this} deals 1 damage to each creature target player controls"; + } + + public AggravateEffect(final AggravateEffect effect) { + super(effect); + } + + @Override + public AggravateEffect copy() { + return new AggravateEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getFirstTarget()); + if (player != null) { + FilterCreaturePermanent filter = new FilterCreaturePermanent(); + filter.add(new ControllerIdPredicate(player.getId())); + List creatures = game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game); + for (Permanent creature : creatures) { + creature.damage(1, source.getSourceId(), game, false, true); + } + return true; + } + return false; + } +} + +class AggravateRequirementEffect extends RequirementEffect { + + public AggravateRequirementEffect() { + super(Duration.EndOfTurn); + this.staticText = "Each creature dealt damage this way attacks this turn if able"; + } + + public AggravateRequirementEffect(final AggravateRequirementEffect effect) { + super(effect); + } + + @Override + public AggravateRequirementEffect copy() { + return new AggravateRequirementEffect(this); + } + + @Override + public boolean applies(Permanent permanent, Ability source, Game game) { + DamagedByWatcher watcher = (DamagedByWatcher) game.getState().getWatchers().get("DamagedByWatcher", source.getSourceId()); + if (watcher != null) { + return watcher.wasDamaged(permanent, game); + } + return false; + } + + @Override + public boolean mustAttack(Game game) { + return true; + } + + @Override + public boolean mustBlock(Game game) { + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/avacynrestored/BrunaLightOfAlabaster.java b/Mage.Sets/src/mage/sets/avacynrestored/BrunaLightOfAlabaster.java index 50c4d359344..574072de20b 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/BrunaLightOfAlabaster.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/BrunaLightOfAlabaster.java @@ -122,7 +122,7 @@ class BrunaLightOfAlabasterEffect extends OneShotEffect { return false; } - while (player.isInGame() && player.chooseUse(Outcome.Benefit, "Attach an Aura from the battlefield?", source, game)) { + while (player.canRespond() && player.chooseUse(Outcome.Benefit, "Attach an Aura from the battlefield?", source, game)) { Target targetAura = new TargetPermanent(filterAura); if (player.choose(Outcome.Benefit, targetAura, source.getSourceId(), game)) { Permanent aura = game.getPermanent(targetAura.getFirstTarget()); @@ -137,7 +137,7 @@ class BrunaLightOfAlabasterEffect extends OneShotEffect { } int count = player.getHand().count(filterAuraCard, game); - while (player.isInGame() && count > 0 && player.chooseUse(Outcome.Benefit, "Attach an Aura from your hand?", source, game)) { + while (player.canRespond() && count > 0 && player.chooseUse(Outcome.Benefit, "Attach an Aura from your hand?", source, game)) { TargetCard targetAura = new TargetCard(Zone.PICK, filterAuraCard); if (player.choose(Outcome.Benefit, player.getHand(), targetAura, game)) { Card aura = game.getCard(targetAura.getFirstTarget()); @@ -151,7 +151,7 @@ class BrunaLightOfAlabasterEffect extends OneShotEffect { } count = player.getGraveyard().count(filterAuraCard, game); - while (player.isInGame() && count > 0 && player.chooseUse(Outcome.Benefit, "Attach an Aura from your graveyard?", source, game)) { + while (player.canRespond() && count > 0 && player.chooseUse(Outcome.Benefit, "Attach an Aura from your graveyard?", source, game)) { TargetCard targetAura = new TargetCard(Zone.PICK, filterAuraCard); if (player.choose(Outcome.Benefit, player.getGraveyard(), targetAura, game)) { Card aura = game.getCard(targetAura.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/avacynrestored/CavernOfSouls.java b/Mage.Sets/src/mage/sets/avacynrestored/CavernOfSouls.java index bb147a16330..00e88453cb5 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/CavernOfSouls.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/CavernOfSouls.java @@ -115,7 +115,7 @@ class CavernOfSoulsEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.Benefit, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/avacynrestored/DarkImpostor.java b/Mage.Sets/src/mage/sets/avacynrestored/DarkImpostor.java index 1748583e0db..d51cdecde77 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/DarkImpostor.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/DarkImpostor.java @@ -27,7 +27,7 @@ */ package mage.sets.avacynrestored; -import mage.constants.*; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.ActivatedAbility; @@ -40,17 +40,22 @@ import mage.abilities.effects.common.ImprintTargetEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; import mage.counters.CounterType; import mage.game.Game; import mage.game.permanent.Permanent; import mage.target.common.TargetCreaturePermanent; -import java.util.UUID; - /** * * @author noxx - + * */ public class DarkImpostor extends CardImpl { @@ -65,7 +70,7 @@ public class DarkImpostor extends CardImpl { // {4}{B}{B}: Exile target creature and put a +1/+1 counter on Dark Impostor.\ Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ImprintTargetEffect(), new ManaCostsImpl("{4}{B}{B}")); - ability.addEffect(new ExileTargetEffect(null, "Dark Impostor")); + ability.addEffect(new ExileTargetEffect(null, this.getIdName())); ability.addEffect(new AddCountersSourceEffect(CounterType.P1P1.createInstance())); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); @@ -99,10 +104,10 @@ class DarkImpostorContinuousEffect extends ContinuousEffectImpl { public boolean apply(Game game, Ability source) { Permanent perm = game.getPermanent(source.getSourceId()); if (perm != null) { - for (UUID imprintedId: perm.getImprinted()) { + for (UUID imprintedId : perm.getImprinted()) { Card card = game.getCard(imprintedId); if (card != null) { - for (Ability ability: card.getAbilities()) { + for (Ability ability : card.getAbilities()) { if (ability instanceof ActivatedAbility) { perm.addAbility(ability, source.getSourceId(), game); } @@ -118,4 +123,4 @@ class DarkImpostorContinuousEffect extends ContinuousEffectImpl { return new DarkImpostorContinuousEffect(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/avacynrestored/DescentIntoMadness.java b/Mage.Sets/src/mage/sets/avacynrestored/DescentIntoMadness.java index cea5bb7a325..25472b037ab 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/DescentIntoMadness.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/DescentIntoMadness.java @@ -126,7 +126,7 @@ class DescentIntoMadnessEffect extends OneShotEffect { do { selectCards(currentPlayer, selectedObjects, count, source, game); currentPlayer = playerList.getNextInRange(controller, game); - } while (!currentPlayer.equals(controller) && controller.isInGame()); + } while (!currentPlayer.equals(controller) && controller.canRespond()); // move permanents and hand cards to exile for (UUID objectId : selectedObjects) { @@ -159,7 +159,7 @@ class DescentIntoMadnessEffect extends OneShotEffect { int amount = Math.min(count, player.getHand().size() + game.getBattlefield().getAllActivePermanents(player.getId()).size()); int cardsFromHand = 0; - while (player.isInGame() && amount > 0) { + while (player.canRespond() && amount > 0) { Target target; do { @@ -185,7 +185,7 @@ class DescentIntoMadnessEffect extends OneShotEffect { } } } - } while (amount > 0 && !target.getTargets().isEmpty() && player.isInGame()); + } while (amount > 0 && !target.getTargets().isEmpty() && player.canRespond()); if (amount > 0) { TargetCard targetInHand; do { @@ -207,7 +207,7 @@ class DescentIntoMadnessEffect extends OneShotEffect { cardsFromHand++; } } - } while (amount > 0 && !targetInHand.getTargets().isEmpty() && player.isInGame()); + } while (amount > 0 && !targetInHand.getTargets().isEmpty() && player.canRespond()); } } diff --git a/Mage.Sets/src/mage/sets/avacynrestored/Fettergeist.java b/Mage.Sets/src/mage/sets/avacynrestored/Fettergeist.java index 6b8cec80c85..cd1e936ab91 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/Fettergeist.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/Fettergeist.java @@ -102,10 +102,7 @@ class FettergeistUnlessPaysEffect extends OneShotEffect { if (player != null && permanent != null) { PermanentsOnBattlefieldCount amount = new PermanentsOnBattlefieldCount(filter, 1); int count = amount.calculate(game, source, this); - if (count == 0) { - return true; - } - if (player.chooseUse(Outcome.Benefit, "Pay " + count + "?", source, game)) { + if (player.chooseUse(Outcome.Benefit, "Pay " + count + "? Or " + permanent.getName() + " will be sacrificed.", source, game)) { GenericManaCost cost = new GenericManaCost(count); if (cost.pay(source, game, source.getSourceId(), source.getControllerId(), false)) { return true; diff --git a/Mage.Sets/src/mage/sets/avacynrestored/HuntedGhoul.java b/Mage.Sets/src/mage/sets/avacynrestored/HuntedGhoul.java index d50023cd82c..e236033c8c0 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/HuntedGhoul.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/HuntedGhoul.java @@ -27,18 +27,14 @@ */ package mage.sets.avacynrestored; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBlockCreaturesSourceEffect; +import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; -import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.effects.RestrictionEffect; -import mage.cards.CardImpl; -import mage.constants.Duration; -import mage.game.Game; -import mage.game.permanent.Permanent; - -import java.util.UUID; +import mage.filter.common.FilterCreaturePermanent; /** * @author noxx @@ -54,7 +50,7 @@ public class HuntedGhoul extends CardImpl { this.toughness = new MageInt(2); // Hunted Ghoul can't block Humans. - this.addAbility(HuntedGhoulAbility.getInstance()); + this.addAbility(new SimpleEvasionAbility(new CantBlockCreaturesSourceEffect(new FilterCreaturePermanent("Human", "Humans")))); } public HuntedGhoul(final HuntedGhoul card) { @@ -66,61 +62,3 @@ public class HuntedGhoul extends CardImpl { return new HuntedGhoul(this); } } - -class HuntedGhoulAbility extends EvasionAbility { - - private static HuntedGhoulAbility instance; - - public static HuntedGhoulAbility getInstance() { - if (instance == null) { - instance = new HuntedGhoulAbility(); - } - return instance; - } - - private HuntedGhoulAbility() { - this.addEffect(new HuntedGhoulEffect()); - } - - @Override - public String getRule() { - return "{this} can't block Humans."; - } - - @Override - public HuntedGhoulAbility copy() { - return getInstance(); - } -} - -class HuntedGhoulEffect extends RestrictionEffect { - - public HuntedGhoulEffect() { - super(Duration.WhileOnBattlefield); - } - - public HuntedGhoulEffect(final HuntedGhoulEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - if (permanent.getAbilities().containsKey(HuntedGhoulAbility.getInstance().getId())) { - return true; - } - return false; - } - - @Override - public boolean canBlock(Permanent attacker, Permanent blocker, Ability source, Game game) { - if (attacker != null && attacker.hasSubtype("Human")) { - return false; - } - return true; - } - - @Override - public HuntedGhoulEffect copy() { - return new HuntedGhoulEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/avacynrestored/LairDelve.java b/Mage.Sets/src/mage/sets/avacynrestored/LairDelve.java index 2e77a4522c9..0021f383139 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/LairDelve.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/LairDelve.java @@ -107,7 +107,7 @@ class LairDelveEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/avacynrestored/MaalfeldTwins.java b/Mage.Sets/src/mage/sets/avacynrestored/MaalfeldTwins.java index 72bcf6c1af0..503fc720b68 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/MaalfeldTwins.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/MaalfeldTwins.java @@ -28,12 +28,12 @@ package mage.sets.avacynrestored; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.common.DiesTriggeredAbility; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.permanent.token.ZombieToken; /** @@ -51,7 +51,7 @@ public class MaalfeldTwins extends CardImpl { this.toughness = new MageInt(4); // When Maalfeld Twins dies, put two 2/2 black Zombie creature tokens onto the battlefield. - this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new ZombieToken("ALA"), 2))); + this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new ZombieToken(), 2))); } public MaalfeldTwins(final MaalfeldTwins card) { diff --git a/Mage.Sets/src/mage/sets/avacynrestored/PrimalSurge.java b/Mage.Sets/src/mage/sets/avacynrestored/PrimalSurge.java index 7dd2e0918d0..524cd8689c6 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/PrimalSurge.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/PrimalSurge.java @@ -113,7 +113,7 @@ class PrimalSurgeEffect extends OneShotEffect { } } } - } while (player.isInGame() && repeat); + } while (player.canRespond() && repeat); return true; } diff --git a/Mage.Sets/src/mage/sets/avacynrestored/RidersOfGavony.java b/Mage.Sets/src/mage/sets/avacynrestored/RidersOfGavony.java index 724543db09b..8a0ead3bfc9 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/RidersOfGavony.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/RidersOfGavony.java @@ -102,7 +102,7 @@ class RidersOfGavonyEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/avacynrestored/RiteOfRuin.java b/Mage.Sets/src/mage/sets/avacynrestored/RiteOfRuin.java index 093d3868344..7a2a69f37aa 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/RiteOfRuin.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/RiteOfRuin.java @@ -100,7 +100,7 @@ class RiteOfRuinEffect extends OneShotEffect { LinkedList order = new LinkedList<>(); ChoiceImpl choice = new ChoiceImpl(true); choice.setChoices(choices); - while (controller.isInGame() && controller.choose(Outcome.Sacrifice, choice, game) && choices.size() > 1) { + while (controller.canRespond() && controller.choose(Outcome.Sacrifice, choice, game) && choices.size() > 1) { order.add(getCardType(choice.getChoice())); choices.remove(choice.getChoice()); choice.clearChoice(); diff --git a/Mage.Sets/src/mage/sets/avacynrestored/TandemLookout.java b/Mage.Sets/src/mage/sets/avacynrestored/TandemLookout.java index 255339d3844..a2cec673f68 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/TandemLookout.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/TandemLookout.java @@ -30,8 +30,8 @@ package mage.sets.avacynrestored; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.continuous.GainAbilityPairedEffect; import mage.abilities.keyword.SoulbondAbility; diff --git a/Mage.Sets/src/mage/sets/avacynrestored/ThatcherRevolt.java b/Mage.Sets/src/mage/sets/avacynrestored/ThatcherRevolt.java index 141d60e8284..c2fc5802c19 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/ThatcherRevolt.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/ThatcherRevolt.java @@ -28,9 +28,6 @@ package mage.sets.avacynrestored; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; import mage.MageInt; import mage.ObjectColor; import mage.abilities.Ability; @@ -40,7 +37,11 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeTargetEffect; import mage.abilities.keyword.HasteAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.game.permanent.token.Token; import mage.target.targetpointer.FixedTarget; @@ -54,7 +55,6 @@ public class ThatcherRevolt extends CardImpl { super(ownerId, 158, "Thatcher Revolt", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{R}"); this.expansionSetCode = "AVR"; - // Put three 1/1 red Human creature tokens with haste onto the battlefield. Sacrifice those tokens at the beginning of the next end step. this.getSpellAbility().addEffect(new ThatcherRevoltEffect()); } @@ -90,14 +90,16 @@ class ThatcherRevoltEffect extends OneShotEffect { for (int i = 0; i < 3; i++) { RedHumanToken token = new RedHumanToken(); token.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); - - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this token"); - sacrificeEffect.setTargetPointer(new FixedTarget(token.getLastAddedToken())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + Permanent permanent = game.getPermanent(token.getLastAddedToken()); + if (permanent != null) { + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this token", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } } return true; } diff --git a/Mage.Sets/src/mage/sets/avacynrestored/WildDefiance.java b/Mage.Sets/src/mage/sets/avacynrestored/WildDefiance.java index 309a9128d61..858c6b9a858 100644 --- a/Mage.Sets/src/mage/sets/avacynrestored/WildDefiance.java +++ b/Mage.Sets/src/mage/sets/avacynrestored/WildDefiance.java @@ -93,7 +93,7 @@ class CreaturesYouControlBecomesTargetTriggeredAbility extends TriggeredAbilityI if (permanent != null && permanent.getControllerId().equals(this.controllerId) && permanent.getCardType().contains(CardType.CREATURE)) { MageObject object = game.getObject(event.getSourceId()); if (object != null && object instanceof Spell) { - Card c = (Spell)object; + Card c = (Spell) object; if (c.getCardType().contains(CardType.INSTANT) || c.getCardType().contains(CardType.SORCERY)) { if (getTargets().size() == 0) { for (Effect effect : getEffects()) { @@ -109,6 +109,6 @@ class CreaturesYouControlBecomesTargetTriggeredAbility extends TriggeredAbilityI @Override public String getRule() { - return "Whenever a creature you control becomes the target of an instant or sorcery spell, that creature gets +3/+3 until end of turn"; + return "Whenever a creature you control becomes the target of an instant or sorcery spell, that creature gets +3/+3 until end of turn."; } } diff --git a/Mage.Sets/src/mage/sets/battleforzendikar/EvolvingWilds.java b/Mage.Sets/src/mage/sets/battleforzendikar/EvolvingWilds.java new file mode 100644 index 00000000000..eb1aec5ff81 --- /dev/null +++ b/Mage.Sets/src/mage/sets/battleforzendikar/EvolvingWilds.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.battleforzendikar; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class EvolvingWilds extends mage.sets.riseoftheeldrazi.EvolvingWilds { + + public EvolvingWilds(UUID ownerId) { + super(ownerId); + this.cardNumber = 236; + this.expansionSetCode = "BFZ"; + } + + public EvolvingWilds(final EvolvingWilds card) { + super(card); + } + + @Override + public EvolvingWilds copy() { + return new EvolvingWilds(this); + } +} diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/BudokaPupil.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/BudokaPupil.java index b62b7be6920..476c169bda6 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/BudokaPupil.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/BudokaPupil.java @@ -71,13 +71,13 @@ public class BudokaPupil extends CardImpl { this.flipCardName = "Ichiga, Who Topples Oaks"; // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Budoka Pupil. - this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); + this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); // At the beginning of the end step, if there are two or more ki counters on Budoka Pupil, you may flip it. this.addAbility(new ConditionalTriggeredAbility( - new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new IchigaWhoTopplesOaks())), + new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new IchigaWhoTopplesOaks()), true), new SourceHasCounterCondition(CounterType.KI, 2, Integer.MAX_VALUE), - "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.", true)); + "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.")); } public BudokaPupil(final BudokaPupil card) { @@ -107,7 +107,7 @@ class IchigaWhoTopplesOaks extends Token { // Remove a ki counter from Ichiga, Who Topples Oaks: Target creature gets +2/+2 until end of turn. Ability ability = new SimpleActivatedAbility( Zone.BATTLEFIELD, - new BoostTargetEffect(2,2, Duration.EndOfTurn), + new BoostTargetEffect(2, 2, Duration.EndOfTurn), new RemoveCountersSourceCost(CounterType.KI.createInstance())); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/CallowJushi.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/CallowJushi.java index 5398adce4aa..10d30538375 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/CallowJushi.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/CallowJushi.java @@ -70,13 +70,13 @@ public class CallowJushi extends CardImpl { this.flipCardName = "Jaraku the Interloper"; // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Callow Jushi. - this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); + this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); // At the beginning of the end step, if there are two or more ki counters on Callow Jushi, you may flip it. this.addAbility(new ConditionalTriggeredAbility( new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new JarakuTheInterloper())), new SourceHasCounterCondition(CounterType.KI, 2, Integer.MAX_VALUE), - "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.", true)); + "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.")); } public CallowJushi(final CallowJushi card) { diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/CunningBandit.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/CunningBandit.java index e887396724a..33245d2dd50 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/CunningBandit.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/CunningBandit.java @@ -70,13 +70,13 @@ public class CunningBandit extends CardImpl { this.flipCardName = "Azamuki, Treachery Incarnate"; // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Cunning Bandit. - this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); + this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); // At the beginning of the end step, if there are two or more ki counters on Cunning Bandit, you may flip it. this.addAbility(new ConditionalTriggeredAbility( new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new AzamukiTreacheryIncarnate())), new SourceHasCounterCondition(CounterType.KI, 2, Integer.MAX_VALUE), - "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.", true)); + "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.")); } public CunningBandit(final CunningBandit card) { diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/FaithfulSquire.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/FaithfulSquire.java index d9502221675..60cc38d784a 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/FaithfulSquire.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/FaithfulSquire.java @@ -27,16 +27,14 @@ * or implied, of BetaSteward_at_googlemail.com. * */ - package mage.sets.betrayersofkamigawa; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.Zone; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.common.*; +import mage.abilities.common.OnEventTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SpellCastControllerTriggeredAbility; import mage.abilities.condition.common.SourceHasCounterCondition; import mage.abilities.costs.common.RemoveCountersSourceCost; import mage.abilities.decorator.ConditionalTriggeredAbility; @@ -45,15 +43,16 @@ import mage.abilities.effects.common.PreventDamageToTargetEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.common.FilterSpiritOrArcaneCard; import mage.game.events.GameEvent; import mage.game.permanent.token.Token; import mage.target.common.TargetCreaturePermanent; -import java.util.UUID; - - /** * @author LevelX2 */ @@ -79,9 +78,9 @@ public class FaithfulSquire extends CardImpl { this.addAbility(new ConditionalTriggeredAbility( new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new KaisoMemoryOfLoyalty())), new SourceHasCounterCondition(CounterType.KI, 2, Integer.MAX_VALUE), - "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.", true)); + "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.")); - } + } public FaithfulSquire(final FaithfulSquire card) { super(card); diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/FirstVolley.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/FirstVolley.java index 8f20e822b03..58ad9dd54f7 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/FirstVolley.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/FirstVolley.java @@ -28,15 +28,12 @@ package mage.sets.betrayersofkamigawa; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetCreaturePermanent; /** @@ -50,9 +47,11 @@ public class FirstVolley extends CardImpl { this.expansionSetCode = "BOK"; this.subtype.add("Arcane"); - // First Volley deals 1 damage to target creature and 1 damage to that creature's controller. - this.getSpellAbility().addEffect(new FirstVolleyEffect()); + this.getSpellAbility().addEffect(new DamageTargetEffect(1)); + Effect effect = new DamageTargetControllerEffect(1); + effect.setText("and 1 damage to that creature's controller"); + this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); } @@ -66,34 +65,3 @@ public class FirstVolley extends CardImpl { return new FirstVolley(this); } } - -class FirstVolleyEffect extends OneShotEffect { - - public FirstVolleyEffect() { - super(Outcome.Damage); - this.staticText = "{this} deals 1 damage to target creature and 1 damage to that creature's controller"; - } - - public FirstVolleyEffect(final FirstVolleyEffect effect) { - super(effect); - } - - @Override - public FirstVolleyEffect copy() { - return new FirstVolleyEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source)); - if (permanent != null) { - Player controller = game.getPlayer(permanent.getControllerId()); - if (controller != null) { - permanent.damage(1, source.getSourceId(), game, false, true); - controller.damage(1, source.getSourceId(), game, false, true); - return true; - } - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/HiredMuscle.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/HiredMuscle.java index 69d3a50a0a1..d837323a7e3 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/HiredMuscle.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/HiredMuscle.java @@ -70,14 +70,14 @@ public class HiredMuscle extends CardImpl { this.flipCard = true; this.flipCardName = "Scarmaker"; - // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Hired Muscle. + // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Hired Muscle. this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); - + // At the beginning of the end step, if there are two or more ki counters on Hired Muscle, you may flip it. this.addAbility(new ConditionalTriggeredAbility( new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new Scarmaker())), new SourceHasCounterCondition(CounterType.KI, 2, Integer.MAX_VALUE), - "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.", true)); + "At the beginning of the end step, if there are two or more ki counters on {this}, you may flip it.")); } public HiredMuscle(final HiredMuscle card) { diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/HokoriDustDrinker.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/HokoriDustDrinker.java index 62bb2f97366..6a126e4d3de 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/HokoriDustDrinker.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/HokoriDustDrinker.java @@ -62,7 +62,7 @@ public class HokoriDustDrinker extends CardImpl { this.subtype.add("Spirit"); this.power = new MageInt(2); - this.toughness = new MageInt(1); + this.toughness = new MageInt(2); // Lands don't untap during their controllers' untap steps. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, new FilterLandPermanent("Lands")))); diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/PetalmaneBaku.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/PetalmaneBaku.java index 4de0d0d8933..d31abe9b9c1 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/PetalmaneBaku.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/PetalmaneBaku.java @@ -25,24 +25,26 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.betrayersofkamigawa; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.Mana; import mage.abilities.Ability; import mage.abilities.common.SpellCastControllerTriggeredAbility; import mage.abilities.costs.Cost; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; -import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.ManaEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.BasicManaAbility; +import mage.abilities.mana.DynamicManaAbility; import mage.cards.CardImpl; import mage.choices.ChoiceColor; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.counters.CounterType; import mage.filter.common.FilterSpiritOrArcaneCard; import mage.game.Game; @@ -62,14 +64,19 @@ public class PetalmaneBaku extends CardImpl { this.power = new MageInt(1); this.toughness = new MageInt(2); - + // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Skullmane Baku. this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); // {1}, Remove X ki counters from Petalmane Baku: Add X mana of any one color to your mana pool. - Ability ability = new PetalmaneBakuManaAbility(); - ability.addCost(new GenericManaCost(1)); - ability.addCost(new RemoveVariableCountersSourceCost(CounterType.KI.createInstance(1))); + Ability ability = new DynamicManaAbility( + new Mana(0, 0, 0, 0, 0, 0, 1), + new RemovedCountersForCostValue(), + new ManaCostsImpl<>("{1}"), + "Add X mana of any one color to your mana pool", + true, new CountersCount(CounterType.KI)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.KI.createInstance(), + "Remove X ki counters from {this}")); this.addAbility(ability); } @@ -81,8 +88,9 @@ public class PetalmaneBaku extends CardImpl { public PetalmaneBaku copy() { return new PetalmaneBaku(this); } - + private class PetalmaneBakuManaAbility extends BasicManaAbility { + PetalmaneBakuManaAbility() { super(new PetalmaneBakuManaEffect()); this.addChoice(new ChoiceColor()); @@ -96,7 +104,7 @@ public class PetalmaneBaku extends CardImpl { public PetalmaneBakuManaAbility copy() { return new PetalmaneBakuManaAbility(this); } -} + } private class PetalmaneBakuManaEffect extends ManaEffect { @@ -118,9 +126,9 @@ public class PetalmaneBaku extends CardImpl { int numberOfMana = 0; for (Cost cost : source.getCosts()) { if (cost instanceof RemoveVariableCountersSourceCost) { - numberOfMana = ((RemoveVariableCountersSourceCost)cost).getAmount(); + numberOfMana = ((RemoveVariableCountersSourceCost) cost).getAmount(); } - } + } if (choice.getColor().isBlack()) { player.getManaPool().addMana(new Mana(0, 0, 0, 0, numberOfMana, 0, 0), game, source); return true; @@ -152,5 +160,4 @@ public class PetalmaneBaku extends CardImpl { } } - -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/betrayersofkamigawa/QuillmaneBaku.java b/Mage.Sets/src/mage/sets/betrayersofkamigawa/QuillmaneBaku.java index e8b0b354db3..b367b8f020f 100644 --- a/Mage.Sets/src/mage/sets/betrayersofkamigawa/QuillmaneBaku.java +++ b/Mage.Sets/src/mage/sets/betrayersofkamigawa/QuillmaneBaku.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.betrayersofkamigawa; import java.util.UUID; @@ -39,7 +38,6 @@ import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; @@ -69,7 +67,7 @@ public class QuillmaneBaku extends CardImpl { this.power = new MageInt(3); this.toughness = new MageInt(3); - + // Whenever you cast a Spirit or Arcane spell, you may put a ki counter on Skullmane Baku. this.addAbility(new SpellCastControllerTriggeredAbility(new AddCountersSourceEffect(CounterType.KI.createInstance()), filter, true)); @@ -87,11 +85,11 @@ public class QuillmaneBaku extends CardImpl { int maxConvManaCost = 0; for (Cost cost : ability.getCosts()) { if (cost instanceof RemoveVariableCountersSourceCost) { - maxConvManaCost = ((RemoveVariableCountersSourceCost)cost).getAmount(); + maxConvManaCost = ((RemoveVariableCountersSourceCost) cost).getAmount(); } } ability.getTargets().clear(); - FilterCreaturePermanent newFilter = new FilterCreaturePermanent("creature with converted mana cost " + maxConvManaCost + " or less"); + FilterCreaturePermanent newFilter = new FilterCreaturePermanent("creature with converted mana cost " + maxConvManaCost + " or less"); newFilter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, maxConvManaCost + 1)); TargetCreaturePermanent target = new TargetCreaturePermanent(newFilter); ability.getTargets().add(target); @@ -106,7 +104,7 @@ public class QuillmaneBaku extends CardImpl { public QuillmaneBaku copy() { return new QuillmaneBaku(this); } - + class QuillmaneBakuReturnEffect extends OneShotEffect { public QuillmaneBakuReturnEffect() { @@ -125,16 +123,15 @@ public class QuillmaneBaku extends CardImpl { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller == null) { return false; } Permanent permanent = game.getPermanent(this.getTargetPointer().getFirst(game, source)); if (permanent != null) { - player.moveCardToHandWithInfo((Card) permanent, source.getSourceId(), game, Zone.BATTLEFIELD); - return true; + controller.moveCards(permanent, null, Zone.HAND, source, game); } - return false; + return true; } } } diff --git a/Mage.Sets/src/mage/sets/bornofthegods/EverflameEidolon.java b/Mage.Sets/src/mage/sets/bornofthegods/EverflameEidolon.java index 3239aff414b..dc091c0b57f 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/EverflameEidolon.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/EverflameEidolon.java @@ -29,19 +29,22 @@ package mage.sets.bornofthegods; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.SourceHasSubtypeCondition; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.effects.common.continuous.BoostSourceEffect; import mage.abilities.keyword.BestowAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; /** * @@ -60,12 +63,7 @@ public class EverflameEidolon extends CardImpl { // Bestow {2}{R} this.addAbility(new BestowAbility(this, "{2}{R}")); // {R}: Everflame Eidolon gets +1/+0 until end of turn. If it's an Aura, enchanted creature gets +1/+0 until end of turn instead. - this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( - new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), - new BoostSourceEffect(1, 0, Duration.EndOfTurn), - new SourceHasSubtypeCondition("Aura"), - "{this} gets +1/+0 until end of turn. If it's an Aura, enchanted creature gets +1/+0 until end of turn instead"), - new ManaCostsImpl("{R}"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new EverflameEidolonEffect(), new ManaCostsImpl("{R}"))); // Enchanted creature gets +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield))); } @@ -79,3 +77,34 @@ public class EverflameEidolon extends CardImpl { return new EverflameEidolon(this); } } + +class EverflameEidolonEffect extends OneShotEffect { + + public EverflameEidolonEffect() { + super(Outcome.BoostCreature); + this.staticText = "{this} gets +1/+0 until end of turn. If it's an Aura, enchanted creature gets +1/+0 until end of turn instead"; + } + + public EverflameEidolonEffect(final EverflameEidolonEffect effect) { + super(effect); + } + + @Override + public EverflameEidolonEffect copy() { + return new EverflameEidolonEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent sourceObject = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if (sourceObject != null) { + if (sourceObject.getSubtype().contains("Aura")) { + new BoostEnchantedEffect(1, 0, Duration.EndOfTurn).apply(game, source); + } else { + game.addEffect(new BoostSourceEffect(1, 0, Duration.EndOfTurn), source); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/bornofthegods/OracleOfBones.java b/Mage.Sets/src/mage/sets/bornofthegods/OracleOfBones.java index 15fa1489e8a..493f7cc1925 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/OracleOfBones.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/OracleOfBones.java @@ -111,7 +111,7 @@ class OracleOfBonesCastEffect extends OneShotEffect { controller.chooseUse(outcome, "Cast an instant or sorcery card from your hand without paying its mana cost?", source, game)) { Card cardToCast = null; boolean cancel = false; - while (controller.isInGame() && !cancel) { + while (controller.canRespond() && !cancel) { if (controller.chooseTarget(outcome, target, source, game)) { cardToCast = game.getCard(target.getFirstTarget()); if (cardToCast != null && cardToCast.getSpellAbility().canChooseTarget(game)) { diff --git a/Mage.Sets/src/mage/sets/bornofthegods/Peregrination.java b/Mage.Sets/src/mage/sets/bornofthegods/Peregrination.java index 0f0abeabc8c..d5fdc7aca32 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/Peregrination.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/Peregrination.java @@ -27,8 +27,8 @@ */ package mage.sets.bornofthegods; -import java.util.List; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -44,7 +44,6 @@ import mage.constants.Zone; import mage.filter.FilterCard; import mage.filter.common.FilterBasicLandCard; import mage.game.Game; -import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.TargetCard; import mage.target.common.TargetCardInLibrary; @@ -59,7 +58,6 @@ public class Peregrination extends CardImpl { super(ownerId, 132, "Peregrination", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{G}"); this.expansionSetCode = "BNG"; - // Seach your library for up to two basic land cards, reveal those cards, and put one onto the battlefield tapped and the other into your hand. Shuffle your library, then scry 1. this.getSpellAbility().addEffect(new PeregrinationEffect()); Effect effect = new ScryEffect(1); @@ -97,36 +95,39 @@ class PeregrinationEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { + return false; + } TargetCardInLibrary target = new TargetCardInLibrary(0, 2, new FilterBasicLandCard()); - Player player = game.getPlayer(source.getControllerId()); - if (player.searchLibrary(target, game)) { + if (controller.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { Cards revealed = new CardsImpl(); - for (UUID cardId: target.getTargets()) { - Card card = player.getLibrary().getCard(cardId, game); + for (UUID cardId : target.getTargets()) { + Card card = controller.getLibrary().getCard(cardId, game); revealed.add(card); } - player.revealCards("Peregrination", revealed, game); + controller.revealCards(sourceObject.getIdName(), revealed, game); if (target.getTargets().size() == 2) { - TargetCard target2 = new TargetCard(Zone.PICK, filter); - player.choose(Outcome.Benefit, revealed, target2, game); + TargetCard target2 = new TargetCard(Zone.LIBRARY, filter); + controller.choose(Outcome.Benefit, revealed, target2, game); Card card = revealed.get(target2.getFirstTarget(), game); - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); revealed.remove(card); card = revealed.getCards(game).iterator().next(); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - } - else if (target.getTargets().size() == 1) { + controller.moveCards(card, null, Zone.HAND, source, game); + } else if (target.getTargets().size() == 1) { Card card = revealed.getCards(game).iterator().next(); - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); } } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return true; } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return false; } diff --git a/Mage.Sets/src/mage/sets/bornofthegods/SatyrWayfinder.java b/Mage.Sets/src/mage/sets/bornofthegods/SatyrWayfinder.java index 11c738d3975..cd46582a1a4 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/SatyrWayfinder.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/SatyrWayfinder.java @@ -103,13 +103,13 @@ class SatyrWayfinderEffect extends OneShotEffect { if (!cards.isEmpty()) { controller.revealCards(sourceObject.getName(), cards, game); TargetCard target = new TargetCard(Zone.LIBRARY, filterPutInHand); - if (properCardFound && - controller.chooseUse(outcome, "Put a land card into your hand?", source, game) && - controller.choose(Outcome.DrawCard, cards, target, game)) { + if (properCardFound + && controller.chooseUse(outcome, "Put a land card into your hand?", source, game) + && controller.choose(Outcome.DrawCard, cards, target, game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { cards.remove(card); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); } } diff --git a/Mage.Sets/src/mage/sets/bornofthegods/TokenAndCounters/GoldToken.java b/Mage.Sets/src/mage/sets/bornofthegods/TokenAndCounters/GoldToken.java index 353b51e49a1..cfb620594f3 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/TokenAndCounters/GoldToken.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/TokenAndCounters/GoldToken.java @@ -1,53 +1,51 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ - -package mage.sets.bornofthegods.TokenAndCounters; - -import mage.abilities.Ability; -import mage.abilities.costs.common.SacrificeSourceCost; -import mage.abilities.effects.common.AddManaOfAnyColorEffect; -import mage.abilities.mana.SimpleManaAbility; -import mage.choices.ChoiceColor; -import mage.constants.CardType; -import mage.constants.Zone; -import mage.game.permanent.token.Token; - -/** - * - * @author LevelX2 - */ -public class GoldToken extends Token { - - public GoldToken() { - super("Gold", "colorless artifact token named Gold onto the battlefield. It has \"Sacrifice this artifact: Add one mana of any color to your mana pool.\""); - this.setOriginalExpansionSetCode("BNG"); - cardType.add(CardType.ARTIFACT); - - this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(), new SacrificeSourceCost())); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.sets.bornofthegods.TokenAndCounters; + +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.AddManaOfAnyColorEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.constants.CardType; +import mage.constants.Zone; +import mage.game.permanent.token.Token; + +/** + * + * @author LevelX2 + */ +public class GoldToken extends Token { + + public GoldToken() { + super("Gold", "colorless artifact token named Gold onto the battlefield. It has \"Sacrifice this artifact: Add one mana of any color to your mana pool.\""); + this.setOriginalExpansionSetCode("BNG"); + cardType.add(CardType.ARTIFACT); + + this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(), new SacrificeSourceCost())); + } +} diff --git a/Mage.Sets/src/mage/sets/bornofthegods/UnravelTheAEther.java b/Mage.Sets/src/mage/sets/bornofthegods/UnravelTheAEther.java index 94705d22086..fd87b5d72d8 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/UnravelTheAEther.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/UnravelTheAEther.java @@ -53,17 +53,16 @@ public class UnravelTheAEther extends CardImpl { static { filter.add(Predicates.or(new CardTypePredicate(CardType.ARTIFACT), - new CardTypePredicate(CardType.ENCHANTMENT))); + new CardTypePredicate(CardType.ENCHANTMENT))); } public UnravelTheAEther(UUID ownerId) { super(ownerId, 143, "Unravel the AEther", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); this.expansionSetCode = "BNG"; - // Choose target artifact or enchantment. Its owner shuffles it into his or her library. this.getSpellAbility().addEffect(new UnravelTheAEtherShuffleIntoLibraryEffect()); - Target target = new TargetPermanent(1,1,filter,true); + Target target = new TargetPermanent(1, 1, filter, false); this.getSpellAbility().addTarget(target); } @@ -76,6 +75,7 @@ public class UnravelTheAEther extends CardImpl { return new UnravelTheAEther(this); } } + class UnravelTheAEtherShuffleIntoLibraryEffect extends OneShotEffect { public UnravelTheAEtherShuffleIntoLibraryEffect() { @@ -96,7 +96,7 @@ class UnravelTheAEtherShuffleIntoLibraryEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source)); if (permanent != null) { - if (permanent.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true) ) { + if (permanent.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true)) { game.getPlayer(permanent.getOwnerId()).shuffleLibrary(game); return true; } diff --git a/Mage.Sets/src/mage/sets/bornofthegods/WhimsOfTheFates.java b/Mage.Sets/src/mage/sets/bornofthegods/WhimsOfTheFates.java index 0ed12b22c02..448bfea2e8c 100644 --- a/Mage.Sets/src/mage/sets/bornofthegods/WhimsOfTheFates.java +++ b/Mage.Sets/src/mage/sets/bornofthegods/WhimsOfTheFates.java @@ -101,14 +101,14 @@ class WhimsOfTheFateEffect extends OneShotEffect { Map>> playerPermanents = new LinkedHashMap<>(); PlayerList playerList = game.getState().getPlayerList().copy(); - while (!playerList.get().equals(source.getControllerId()) && controller.isInGame()) { + while (!playerList.get().equals(source.getControllerId()) && controller.canRespond()) { playerList.getNext(); } Player currentPlayer = game.getPlayer(playerList.get()); Player nextPlayer; UUID firstNextPlayer = null; - while (!getNextPlayerInDirection(true, playerList, game).equals(firstNextPlayer) && controller.isInGame()) { + while (!getNextPlayerInDirection(true, playerList, game).equals(firstNextPlayer) && controller.canRespond()) { nextPlayer = game.getPlayer(playerList.get()); if (nextPlayer == null) { return false; @@ -116,7 +116,7 @@ class WhimsOfTheFateEffect extends OneShotEffect { if (firstNextPlayer == null) { firstNextPlayer = nextPlayer.getId(); } - if (!nextPlayer.isInGame()) { + if (!nextPlayer.canRespond()) { continue; } // if player is in range of controller he chooses 3 piles with all its permanents diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java b/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java index c4afd226be2..8b363c13144 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/AkkiLavarunner.java @@ -2,6 +2,7 @@ package mage.sets.championsofkamigawa; import java.util.UUID; import mage.MageInt; +import mage.MageObject; import mage.ObjectColor; import mage.abilities.Ability; import mage.abilities.TriggeredAbilityImpl; @@ -10,7 +11,6 @@ import mage.abilities.effects.ReplacementEffectImpl; import mage.abilities.effects.common.FlipSourceEffect; import mage.abilities.keyword.HasteAbility; import mage.abilities.keyword.ProtectionAbility; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; @@ -21,8 +21,9 @@ import mage.filter.FilterCard; import mage.filter.predicate.mageobject.ColorPredicate; import mage.game.Game; import mage.game.events.DamagedPlayerEvent; -import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; import mage.game.permanent.token.Token; /** @@ -126,11 +127,19 @@ class TokTokVolcanoBornEffect extends ReplacementEffectImpl { public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.DAMAGE_PLAYER; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { - Card card = game.getCard(event.getSourceId()); - if (card != null && card.getColor(game).isRed()) { + MageObject sourceObject; + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(event.getSourceId()); + if(sourcePermanent == null) { + sourceObject = game.getObject(event.getSourceId()); + } + else { + sourceObject = sourcePermanent; + } + + if (sourceObject != null && sourceObject.getColor(game).isRed()) { return true; } return false; diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/CranialExtraction.java b/Mage.Sets/src/mage/sets/championsofkamigawa/CranialExtraction.java index e9fa3622af6..948126caae7 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/CranialExtraction.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/CranialExtraction.java @@ -96,7 +96,7 @@ class CranialExtractionEffect extends OneShotEffect { cardChoice.clearChoice(); while (!controller.choose(Outcome.Exile, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/FieldOfReality.java b/Mage.Sets/src/mage/sets/championsofkamigawa/FieldOfReality.java index a7bfc05a864..4e1bc3cb95b 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/FieldOfReality.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/FieldOfReality.java @@ -25,30 +25,24 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.championsofkamigawa; import java.util.UUID; - +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; import mage.constants.AttachmentType; import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.common.SimpleActivatedAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.combat.CantBlockSourceEffect; -import mage.abilities.effects.common.ReturnToHandSourceEffect; -import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; -import mage.abilities.keyword.EnchantAbility; -import mage.cards.CardImpl; -import mage.constants.Outcome; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.filter.common.FilterCreaturePermanent; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -62,13 +56,15 @@ public class FieldOfReality extends CardImpl { this.expansionSetCode = "CHK"; this.subtype.add("Aura"); - - // Enchanted creature can't be blocked by Spirits. + // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); this.addAbility(new EnchantAbility(auraTarget.getTargetName())); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new FieldOfRealityEvasionAbility(), AttachmentType.AURA ))); + + // Enchanted creature can't be blocked by Spirits. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesAttachedEffect( + Duration.WhileOnBattlefield, new FilterCreaturePermanent("Spirit", "Spirits"), AttachmentType.AURA))); // {1}{U}: Return Field of Reality to its owner's hand. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandSourceEffect(true), new ManaCostsImpl("{1}{U}"))); } @@ -83,45 +79,3 @@ public class FieldOfReality extends CardImpl { } } - -class FieldOfRealityEvasionAbility extends EvasionAbility { - - public FieldOfRealityEvasionAbility() { - this.addEffect(new FieldOfRealityEvasionEffect()); - } - - public FieldOfRealityEvasionAbility(final FieldOfRealityEvasionAbility ability) { - super(ability); - } - - @Override - public String getRule() { - return "can't be blocked by Spirits"; - } - - @Override - public FieldOfRealityEvasionAbility copy() { - return new FieldOfRealityEvasionAbility(this); - } -} - -class FieldOfRealityEvasionEffect extends CantBlockSourceEffect { - - public FieldOfRealityEvasionEffect() { - super(Duration.WhileOnBattlefield); - } - - public FieldOfRealityEvasionEffect(final FieldOfRealityEvasionEffect effect) { - super(effect); - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - return !blocker.hasSubtype("Spirit") ; - } - - @Override - public FieldOfRealityEvasionEffect copy() { - return new FieldOfRealityEvasionEffect(this); - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/HoldTheLine.java b/Mage.Sets/src/mage/sets/championsofkamigawa/HoldTheLine.java index 95f5deee3ef..3177a4759f9 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/HoldTheLine.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/HoldTheLine.java @@ -28,11 +28,11 @@ package mage.sets.championsofkamigawa; import java.util.UUID; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.abilities.effects.common.continuous.BoostAllEffect; -import mage.cards.CardImpl; import mage.filter.common.FilterBlockingCreature; /** @@ -44,10 +44,9 @@ public class HoldTheLine extends CardImpl { private static final FilterBlockingCreature filter = new FilterBlockingCreature("Blocking creatures"); public HoldTheLine(UUID ownerId) { - super(ownerId, 13, "Hold the Line", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{2}{W}{W}"); + super(ownerId, 13, "Hold the Line", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{W}{W}"); this.expansionSetCode = "CHK"; - // Blocking creatures get +7/+7 until end of turn. this.getSpellAbility().addEffect(new BoostAllEffect(7, 7, Duration.EndOfTurn, filter, false)); } @@ -60,4 +59,4 @@ public class HoldTheLine extends CardImpl { public HoldTheLine copy() { return new HoldTheLine(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/HorobiDeathsWail.java b/Mage.Sets/src/mage/sets/championsofkamigawa/HorobiDeathsWail.java index a254027b6a5..3e81a41733e 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/HorobiDeathsWail.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/HorobiDeathsWail.java @@ -37,8 +37,6 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; -import mage.filter.common.FilterControlledPermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; @@ -51,11 +49,6 @@ import mage.target.targetpointer.FixedTarget; */ public class HorobiDeathsWail extends CardImpl { - private static final FilterControlledPermanent filter = new FilterControlledPermanent("Demon"); - static { - filter.add(new SubtypePredicate("Demon")); - } - public HorobiDeathsWail(UUID ownerId) { super(ownerId, 117, "Horobi, Death's Wail", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}{B}"); this.expansionSetCode = "CHK"; @@ -67,6 +60,7 @@ public class HorobiDeathsWail extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); + // Whenever a creature becomes the target of a spell or ability, destroy that creature. this.addAbility(new HorobiDeathsWailAbility(new DestroyTargetEffect())); } diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/JunkyoBell.java b/Mage.Sets/src/mage/sets/championsofkamigawa/JunkyoBell.java index 7e1c9efce0f..da08e4cd46b 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/JunkyoBell.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/JunkyoBell.java @@ -25,13 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.championsofkamigawa; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.DelayedTriggeredAbility; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; @@ -41,8 +37,10 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeTargetEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.TargetController; import mage.filter.common.FilterControlledCreaturePermanent; import mage.game.Game; @@ -58,8 +56,8 @@ public class JunkyoBell extends CardImpl { public JunkyoBell(UUID ownerId) { super(ownerId, 258, "Junkyo Bell", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}"); this.expansionSetCode = "CHK"; - - // At the beginning of your upkeep, you may have target creature you control get +X/+X until end of turn, + + // At the beginning of your upkeep, you may have target creature you control get +X/+X until end of turn, // where X is the number of creatures you control. If you do, sacrifice that creature at the beginning of the next end step. PermanentsOnBattlefieldCount amount = new PermanentsOnBattlefieldCount(new FilterControlledCreaturePermanent()); Ability ability = new BeginningOfUpkeepTriggeredAbility(new BoostTargetEffect(amount, amount, Duration.EndOfTurn), TargetController.YOU, true); @@ -77,37 +75,36 @@ public class JunkyoBell extends CardImpl { return new JunkyoBell(this); } - -private class JunkyoBellSacrificeEffect extends OneShotEffect { + private class JunkyoBellSacrificeEffect extends OneShotEffect { - public JunkyoBellSacrificeEffect() { - super(Outcome.Sacrifice); - this.staticText = "If you do, sacrifice that creature at the beginning of the next end step"; - } - - public JunkyoBellSacrificeEffect(final JunkyoBellSacrificeEffect effect) { - super(effect); - } - - @Override - public JunkyoBellSacrificeEffect copy() { - return new JunkyoBellSacrificeEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent creature = game.getPermanent(source.getFirstTarget()); - if (creature != null) { - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice boosted " + creature.getName()); - sacrificeEffect.setTargetPointer(new FixedTarget(source.getFirstTarget())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); - return true; + public JunkyoBellSacrificeEffect() { + super(Outcome.Sacrifice); + this.staticText = "If you do, sacrifice that creature at the beginning of the next end step"; + } + + public JunkyoBellSacrificeEffect(final JunkyoBellSacrificeEffect effect) { + super(effect); + } + + @Override + public JunkyoBellSacrificeEffect copy() { + return new JunkyoBellSacrificeEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent creature = game.getPermanent(source.getFirstTarget()); + if (creature != null) { + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice boosted " + creature.getName(), source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(creature, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + return true; + } + return false; } - return false; } - } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/KikiJikiMirrorBreaker.java b/Mage.Sets/src/mage/sets/championsofkamigawa/KikiJikiMirrorBreaker.java index 3d8eac8a7cd..2cf5cc1ea2b 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/KikiJikiMirrorBreaker.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/KikiJikiMirrorBreaker.java @@ -28,10 +28,6 @@ package mage.sets.championsofkamigawa; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.DelayedTriggeredAbility; @@ -42,7 +38,10 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeTargetEffect; import mage.abilities.keyword.HasteAbility; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterControlledCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.SupertypePredicate; @@ -124,8 +123,7 @@ class KikiJikiMirrorBreakerEffect extends OneShotEffect { token.addAbility(HasteAbility.getInstance()); token.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect(); - sacrificeEffect.setText("Sacrifice the token at the beginning of the next end step"); + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("Sacrifice the token at the beginning of the next end step", source.getControllerId()); sacrificeEffect.setTargetPointer(new FixedTarget(token.getLastAddedToken())); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); delayedAbility.setSourceId(source.getSourceId()); diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/KitsuneMystic.java b/Mage.Sets/src/mage/sets/championsofkamigawa/KitsuneMystic.java index 566d4f8dbae..1d5d17b9d2f 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/KitsuneMystic.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/KitsuneMystic.java @@ -28,10 +28,6 @@ package mage.sets.championsofkamigawa; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.OnEventTriggeredAbility; @@ -42,6 +38,10 @@ import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.FlipSourceEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterEnchantmentPermanent; import mage.filter.predicate.Predicate; import mage.filter.predicate.mageobject.SubtypePredicate; @@ -72,8 +72,7 @@ public class KitsuneMystic extends CardImpl { // At the beginning of the end step, if Kitsune Mystic is enchanted by two or more Auras, flip it. this.addAbility(new ConditionalTriggeredAbility( new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new FlipSourceEffect(new AutumnTailKitsuneSage())), - new EnchantedCondition(2),"At the beginning of the end step, if {this} is enchanted by two or more Auras, flip it.", false - )); + new EnchantedCondition(2), "At the beginning of the end step, if {this} is enchanted by two or more Auras, flip it.")); } public KitsuneMystic(final KitsuneMystic card) { diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/Mindblaze.java b/Mage.Sets/src/mage/sets/championsofkamigawa/Mindblaze.java index 0c0943c2575..00550c441b6 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/Mindblaze.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/Mindblaze.java @@ -106,13 +106,13 @@ class MindblazeEffect extends OneShotEffect { numberChoice.setChoices(numbers); while (!playerControls.choose(Outcome.Neutral, cardChoice, game)) { - if (!playerControls.isInGame()) { + if (!playerControls.canRespond()) { return false; } } while (!playerControls.choose(Outcome.Neutral, numberChoice, game)) { - if (!playerControls.isInGame()) { + if (!playerControls.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/OniPossession.java b/Mage.Sets/src/mage/sets/championsofkamigawa/OniPossession.java index bc1c23d49e2..44fd1be0eb2 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/OniPossession.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/OniPossession.java @@ -30,22 +30,26 @@ package mage.sets.championsofkamigawa; import java.util.ArrayList; import java.util.List; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; import mage.abilities.effects.common.continuous.SetCardSubtypeAttachedEffect; import mage.abilities.keyword.EnchantAbility; import mage.abilities.keyword.TrampleAbility; import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; import mage.filter.common.FilterControlledCreaturePermanent; import mage.target.TargetPermanent; -import mage.target.common.TargetControlledCreaturePermanent; import mage.target.common.TargetCreaturePermanent; /** @@ -54,7 +58,8 @@ import mage.target.common.TargetCreaturePermanent; */ public class OniPossession extends CardImpl { - private static final List setSubtypes = new ArrayList(); + private static final List setSubtypes = new ArrayList<>(); + static { setSubtypes.add("Demon"); setSubtypes.add("Spirit"); @@ -67,13 +72,14 @@ public class OniPossession extends CardImpl { // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); - this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); - Ability ability = new EnchantAbility(auraTarget.getTargetName()); - this.addAbility(ability); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // At the beginning of your upkeep, sacrifice a creature. - Ability ability2 = new BeginningOfUpkeepTriggeredAbility(new SacrificeTargetEffect("sacrifice a creature"), TargetController.YOU, false); - ability2.addTarget(new TargetControlledCreaturePermanent(1,1, new FilterControlledCreaturePermanent(),false)); + Ability ability2 = new BeginningOfUpkeepTriggeredAbility( + new SacrificeControllerEffect(new FilterControlledCreaturePermanent(), 1, ""), TargetController.YOU, false); this.addAbility(ability2); // Enchanted creature gets +3/+3 and has trample. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 3, Duration.WhileOnBattlefield))); diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/RaggedVeins.java b/Mage.Sets/src/mage/sets/championsofkamigawa/RaggedVeins.java index 551f3c750df..2f75078d463 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/RaggedVeins.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/RaggedVeins.java @@ -30,24 +30,21 @@ package mage.sets.championsofkamigawa; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.DamageDealtToAttachedTriggeredAbility; +import mage.abilities.dynamicvalue.common.NumericSetToEffectValues; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.LoseLifeTargetEffect; import mage.abilities.keyword.EnchantAbility; import mage.abilities.keyword.FlashAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; +import mage.constants.SetTargetPointer; import mage.constants.Zone; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; -import mage.target.targetpointer.FixedTarget; /** * @@ -67,11 +64,13 @@ public class RaggedVeins extends CardImpl { // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); this.addAbility(new EnchantAbility(auraTarget.getTargetName())); // Whenever enchanted creature is dealt damage, its controller loses that much life. - this.addAbility(new RaggedVeinsTriggeredAbility()); + Effect effect = new LoseLifeTargetEffect(new NumericSetToEffectValues("that much", "damage")); + effect.setText("its controller loses that much life"); + this.addAbility(new DamageDealtToAttachedTriggeredAbility(Zone.BATTLEFIELD, effect, false, SetTargetPointer.PLAYER)); } public RaggedVeins(final RaggedVeins card) { @@ -83,78 +82,3 @@ public class RaggedVeins extends CardImpl { return new RaggedVeins(this); } } - -class RaggedVeinsTriggeredAbility extends TriggeredAbilityImpl { - - public RaggedVeinsTriggeredAbility() { - super(Zone.BATTLEFIELD, new RaggedVeinsEffect()); - } - - public RaggedVeinsTriggeredAbility(final RaggedVeinsTriggeredAbility ability) { - super(ability); - } - - @Override - public RaggedVeinsTriggeredAbility copy() { - return new RaggedVeinsTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.DAMAGED_CREATURE; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - Permanent enchantment = game.getPermanent(sourceId); - UUID targetId = event.getTargetId(); - if (enchantment != null && enchantment.getAttachedTo() != null && targetId.equals(enchantment.getAttachedTo())) { - this.getEffects().get(0).setValue("damageAmount", event.getAmount()); - this.getEffects().get(0).setTargetPointer(new FixedTarget(targetId)); - return true; - } - return false; - } - - @Override - public String getRule() { - return "Whenever enchanted creature is dealt damage, its controller loses that much life."; - } -} - -class RaggedVeinsEffect extends OneShotEffect { - - public RaggedVeinsEffect() { - super(Outcome.Damage); - this.staticText = "its controller loses that much life"; - } - - public RaggedVeinsEffect(final RaggedVeinsEffect effect) { - super(effect); - } - - @Override - public RaggedVeinsEffect copy() { - return new RaggedVeinsEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Integer damageAmount = (Integer) this.getValue("damageAmount"); - UUID targetId = this.targetPointer.getFirst(game, source); - if (damageAmount != null && targetId != null) { - Permanent permanent = game.getPermanent(targetId); - if (permanent == null) { - permanent = (Permanent) game.getLastKnownInformation(targetId, Zone.BATTLEFIELD); - } - if (permanent != null) { - Player player = game.getPlayer(permanent.getControllerId()); - if (player != null) { - player.loseLife(damageAmount, game); - return true; - } - } - } - return false; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/championsofkamigawa/ThroughTheBreach.java b/Mage.Sets/src/mage/sets/championsofkamigawa/ThroughTheBreach.java index 86980d0f771..bf4e4d5139b 100644 --- a/Mage.Sets/src/mage/sets/championsofkamigawa/ThroughTheBreach.java +++ b/Mage.Sets/src/mage/sets/championsofkamigawa/ThroughTheBreach.java @@ -63,7 +63,6 @@ public class ThroughTheBreach extends CardImpl { this.expansionSetCode = "CHK"; this.subtype.add("Arcane"); - // You may put a creature card from your hand onto the battlefield. That creature gains haste. Sacrifice that creature at the beginning of the next end step. this.getSpellAbility().addEffect(new ThroughTheBreachEffect()); // Splice onto Arcane {2}{R}{R} @@ -81,7 +80,7 @@ public class ThroughTheBreach extends CardImpl { } class ThroughTheBreachEffect extends OneShotEffect { - + private static final String choiceText = "Put a creature card from your hand onto the battlefield?"; public ThroughTheBreachEffect() { @@ -111,10 +110,10 @@ class ThroughTheBreachEffect extends OneShotEffect { Permanent permanent = game.getPermanent(card.getId()); if (permanent != null) { ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); - effect.setTargetPointer(new FixedTarget(permanent.getId())); + effect.setTargetPointer(new FixedTarget(permanent, game)); game.addEffect(effect, source); - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName()); - sacrificeEffect.setTargetPointer(new FixedTarget(card.getId())); + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName(), source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/coldsnap/BlizzardSpecter.java b/Mage.Sets/src/mage/sets/coldsnap/BlizzardSpecter.java index b451efa5ee1..e9e77e9fbdf 100644 --- a/Mage.Sets/src/mage/sets/coldsnap/BlizzardSpecter.java +++ b/Mage.Sets/src/mage/sets/coldsnap/BlizzardSpecter.java @@ -112,7 +112,7 @@ class ReturnToHandEffect extends OneShotEffect { Target target = new TargetControlledPermanent(1, 1, new FilterControlledPermanent(), true); if (target.canChoose(player.getId(), game)) { - while (player.isInGame() && !target.isChosen() && target.canChoose(player.getId(), game)) { + while (player.canRespond() && !target.isChosen() && target.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.ReturnToHand, target, source, game); } diff --git a/Mage.Sets/src/mage/sets/coldsnap/Controvert.java b/Mage.Sets/src/mage/sets/coldsnap/Controvert.java new file mode 100644 index 00000000000..9c5ee267ffe --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/Controvert.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetSpell; + +/** + * + * @author fireshoes + */ +public class Controvert extends CardImpl { + + public Controvert(UUID ownerId) { + super(ownerId, 30, "Controvert", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{U}{U}"); + this.expansionSetCode = "CSP"; + + // Counter target spell. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetSpell()); + + // Recover {2}{U}{U} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{2}{U}{U}"), this)); + } + + public Controvert(final Controvert card) { + super(card); + } + + @Override + public Controvert copy() { + return new Controvert(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/GrimHarvest.java b/Mage.Sets/src/mage/sets/coldsnap/GrimHarvest.java new file mode 100644 index 00000000000..853cd7e6d8b --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/GrimHarvest.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class GrimHarvest extends CardImpl { + + private static FilterCreatureCard filter = new FilterCreatureCard("creature card from your graveyard"); + + public GrimHarvest(UUID ownerId) { + super(ownerId, 58, "Grim Harvest", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "CSP"; + + // Return target creature card from your graveyard to your hand. + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(filter)); + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + + // Recover {2}{B} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{2}{B}"), this)); + } + + public GrimHarvest(final GrimHarvest card) { + super(card); + } + + @Override + public GrimHarvest copy() { + return new GrimHarvest(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/Icefall.java b/Mage.Sets/src/mage/sets/coldsnap/Icefall.java new file mode 100644 index 00000000000..4033532b71f --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/Icefall.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class Icefall extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.LAND))); + } + + public Icefall(UUID ownerId) { + super(ownerId, 85, "Icefall", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{R}{R}"); + this.expansionSetCode = "CSP"; + + // Destroy target artifact or land. + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + + // Recover {R}{R} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{R}{R}"), this)); + } + + public Icefall(final Icefall card) { + super(card); + } + + @Override + public Icefall copy() { + return new Icefall(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/KjeldoranGargoyle.java b/Mage.Sets/src/mage/sets/coldsnap/KjeldoranGargoyle.java new file mode 100644 index 00000000000..4cbcaead223 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/KjeldoranGargoyle.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class KjeldoranGargoyle extends CardImpl { + + public KjeldoranGargoyle(UUID ownerId) { + super(ownerId, 10, "Kjeldoran Gargoyle", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{5}{W}"); + this.expansionSetCode = "CSP"; + this.subtype.add("Gargoyle"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + + // Whenever Kjeldoran Gargoyle deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public KjeldoranGargoyle(final KjeldoranGargoyle card) { + super(card); + } + + @Override + public KjeldoranGargoyle copy() { + return new KjeldoranGargoyle(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/coldsnap/KrovikanRot.java b/Mage.Sets/src/mage/sets/coldsnap/KrovikanRot.java new file mode 100644 index 00000000000..aa39e567721 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/KrovikanRot.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.PowerPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class KrovikanRot extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with power 2 or less"); + + static { + filter.add(new PowerPredicate(Filter.ComparisonType.LessThan, 3)); + } + + public KrovikanRot(UUID ownerId) { + super(ownerId, 63, "Krovikan Rot", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{B}"); + this.expansionSetCode = "CSP"; + + // Destroy target creature with power 2 or less. + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); + + // Recover {1}{B}{B} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{1}{B}{B}"), this)); + } + + public KrovikanRot(final KrovikanRot card) { + super(card); + } + + @Override + public KrovikanRot copy() { + return new KrovikanRot(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/LovisaColdeyes.java b/Mage.Sets/src/mage/sets/coldsnap/LovisaColdeyes.java new file mode 100644 index 00000000000..ebdff5a9086 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/LovisaColdeyes.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class LovisaColdeyes extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature you control that's a Barbarian, a Warrior, or a Berserker"); + + static { + filter.add(Predicates.or(new SubtypePredicate("Barbarian"), new SubtypePredicate("Warrior"), new SubtypePredicate("Berserker"))); + } + + public LovisaColdeyes(UUID ownerId) { + super(ownerId, 90, "Lovisa Coldeyes", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{R}{R}"); + this.expansionSetCode = "CSP"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Each creature you control that's a Barbarian, a Warrior, or a Berserker gets +2/+2 and has haste. + Effect effect = new BoostControlledEffect(2, 2, Duration.WhileOnBattlefield, filter, false); + effect.setText("Each creature you control that's a Barbarian, a Warrior, or a Berserker gets +2/+2"); + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); + effect = new GainAbilityControlledEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield, filter, false); + effect.setText("and has haste"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public LovisaColdeyes(final LovisaColdeyes card) { + super(card); + } + + @Override + public LovisaColdeyes copy() { + return new LovisaColdeyes(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/MysticMelting.java b/Mage.Sets/src/mage/sets/coldsnap/MysticMelting.java new file mode 100644 index 00000000000..df32d4ef617 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/MysticMelting.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterArtifactOrEnchantmentPermanent; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class MysticMelting extends CardImpl { + + public MysticMelting(UUID ownerId) { + super(ownerId, 114, "Mystic Melting", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{G}"); + this.expansionSetCode = "CSP"; + + // Destroy target artifact or enchantment. + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(new FilterArtifactOrEnchantmentPermanent())); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public MysticMelting(final MysticMelting card) { + super(card); + } + + @Override + public MysticMelting copy() { + return new MysticMelting(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/PhyrexianIronfoot.java b/Mage.Sets/src/mage/sets/coldsnap/PhyrexianIronfoot.java new file mode 100644 index 00000000000..e647764b4ac --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/PhyrexianIronfoot.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DontUntapInControllersUntapStepSourceEffect; +import mage.abilities.effects.common.UntapSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class PhyrexianIronfoot extends CardImpl { + + public PhyrexianIronfoot(UUID ownerId) { + super(ownerId, 139, "Phyrexian Ironfoot", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{3}"); + this.expansionSetCode = "CSP"; + this.supertype.add("Snow"); + this.subtype.add("Construct"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Phyrexian Ironfoot doesn't untap during your untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepSourceEffect())); + + // {1}{snow}: Untap Phyrexian Ironfoot. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new ManaCostsImpl("{1}{snow}"))); + } + + public PhyrexianIronfoot(final PhyrexianIronfoot card) { + super(card); + } + + @Override + public PhyrexianIronfoot copy() { + return new PhyrexianIronfoot(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/Resize.java b/Mage.Sets/src/mage/sets/coldsnap/Resize.java new file mode 100644 index 00000000000..c18f25cc007 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/Resize.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Resize extends CardImpl { + + public Resize(UUID ownerId) { + super(ownerId, 117, "Resize", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "CSP"; + + // Target creature gets +3/+3 until end of turn. + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addEffect(new BoostTargetEffect(3, 3, Duration.EndOfTurn)); + + // Recover {1}{G} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{1}{G}"), this)); + } + + public Resize(final Resize card) { + super(card); + } + + @Override + public Resize copy() { + return new Resize(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/ScryingSheets.java b/Mage.Sets/src/mage/sets/coldsnap/ScryingSheets.java index 5196fbb0293..2669da9ec02 100644 --- a/Mage.Sets/src/mage/sets/coldsnap/ScryingSheets.java +++ b/Mage.Sets/src/mage/sets/coldsnap/ScryingSheets.java @@ -28,6 +28,7 @@ package mage.sets.coldsnap; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; @@ -57,7 +58,7 @@ public class ScryingSheets extends CardImpl { // {tap}: Add {1} to your mana pool. this.addAbility(new ColorlessManaAbility()); - + // {1}{snow}, {tap}: Look at the top card of your library. If that card is snow, you may reveal it and put it into your hand. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ScryingSheetsEffect(), new ManaCostsImpl<>("{1}{snow}")); ability.addCost(new TapSourceCost()); @@ -75,35 +76,35 @@ public class ScryingSheets extends CardImpl { } class ScryingSheetsEffect extends OneShotEffect { - + ScryingSheetsEffect() { super(Outcome.Benefit); this.staticText = "Look at the top card of your library. If that card is snow, you may reveal it and put it into your hand"; } - + ScryingSheetsEffect(final ScryingSheetsEffect effect) { super(effect); } - + @Override public ScryingSheetsEffect copy() { return new ScryingSheetsEffect(this); } - + @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null && player.getLibrary().size() > 0) { - Card card = player.getLibrary().getFromTop(game); + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + Card card = controller.getLibrary().getFromTop(game); if (card != null) { CardsImpl cards = new CardsImpl(); cards.add(card); - player.lookAtCards("Scrying Sheets", cards, game); + controller.lookAtCards(sourceObject.getIdName(), cards, game); if (card.getSupertype().contains("Snow")) { - if (player.chooseUse(outcome, new StringBuilder("Reveal ").append(card.getName()).append(" and put it into your hand?").toString(), source, game)) { - card = player.getLibrary().removeFromTop(game); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - player.revealCards("Scrying Sheets", cards, game); + if (controller.chooseUse(outcome, "Reveal " + card.getLogName() + " and put it into your hand?", source, game)) { + controller.moveCards(card, null, Zone.HAND, source, game); + controller.revealCards(sourceObject.getIdName(), cards, game); } } } diff --git a/Mage.Sets/src/mage/sets/coldsnap/SquallDrifter.java b/Mage.Sets/src/mage/sets/coldsnap/SquallDrifter.java new file mode 100644 index 00000000000..a60272e585c --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/SquallDrifter.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.TapTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SquallDrifter extends CardImpl { + + public SquallDrifter(UUID ownerId) { + super(ownerId, 17, "Squall Drifter", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "CSP"; + this.supertype.add("Snow"); + this.subtype.add("Elemental"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {W}, {tap}: Tap target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public SquallDrifter(final SquallDrifter card) { + super(card); + } + + @Override + public SquallDrifter copy() { + return new SquallDrifter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/SunsBounty.java b/Mage.Sets/src/mage/sets/coldsnap/SunsBounty.java new file mode 100644 index 00000000000..5de3e872cf3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/SunsBounty.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.keyword.RecoverAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LevelX2 + */ +public class SunsBounty extends CardImpl { + + public SunsBounty(UUID ownerId) { + super(ownerId, 18, "Sun's Bounty", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "CSP"; + + // You gain 4 life. + this.getSpellAbility().addEffect(new GainLifeEffect(4)); + + // Recover {1}{W} + this.addAbility(new RecoverAbility(new ManaCostsImpl("{1}{W}"), this)); + } + + public SunsBounty(final SunsBounty card) { + super(card); + } + + @Override + public SunsBounty copy() { + return new SunsBounty(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/SurgingDementia.java b/Mage.Sets/src/mage/sets/coldsnap/SurgingDementia.java new file mode 100644 index 00000000000..a7798996a3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/SurgingDementia.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; + +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.abilities.keyword.RippleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; + +/** + * + * @author klayhamn + */ +public class SurgingDementia extends CardImpl { + + public SurgingDementia(UUID ownerId) { + super(ownerId, 72, "Surging Dementia", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{B}"); + this.expansionSetCode = "CSP"; + + // Ripple 4 + this.addAbility(new RippleAbility(4)); + + // Target player discards a card. + this.getSpellAbility().getEffects().add(new DiscardTargetEffect(1)); + this.getSpellAbility().getTargets().add(new TargetPlayer()); + } + + public SurgingDementia(final SurgingDementia card) { + super(card); + } + + @Override + public SurgingDementia copy() { + return new SurgingDementia(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/SwiftManeuver.java b/Mage.Sets/src/mage/sets/coldsnap/SwiftManeuver.java new file mode 100644 index 00000000000..a503d425883 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/SwiftManeuver.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class SwiftManeuver extends CardImpl { + + public SwiftManeuver(UUID ownerId) { + super(ownerId, 21, "Swift Maneuver", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "CSP"; + + // Prevent the next 2 damage that would be dealt to target creature or player this turn. + this.getSpellAbility().addEffect(new PreventDamageToTargetEffect(Duration.EndOfTurn, 2)); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public SwiftManeuver(final SwiftManeuver card) { + super(card); + } + + @Override + public SwiftManeuver copy() { + return new SwiftManeuver(this); + } +} diff --git a/Mage.Sets/src/mage/sets/coldsnap/ThrummingStone.java b/Mage.Sets/src/mage/sets/coldsnap/ThrummingStone.java new file mode 100644 index 00000000000..a7a7b45af73 --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/ThrummingStone.java @@ -0,0 +1,125 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.keyword.RippleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.filter.FilterSpell; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.game.stack.Spell; +import mage.game.stack.StackObject; +import mage.players.Player; + +import java.util.UUID; + +/** + * @author klayhamn + */ +public class ThrummingStone extends CardImpl { + + //applies to all spells + private static final FilterSpell anySpellFilter = new FilterSpell("Spells you cast"); + + public ThrummingStone(UUID ownerId) { + super(ownerId, 142, "Thrumming Stone", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{5}"); + this.expansionSetCode = "CSP"; + this.supertype.add("Legendary"); + + // spells you cast have Ripple 4 + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ThrummingStoneGainAbilitySpellsEffect(new RippleAbility(4), anySpellFilter))); + } + + public ThrummingStone(final ThrummingStone card) { + super(card); + } + + @Override + public ThrummingStone copy() { + return new ThrummingStone(this); + } + +} + +class ThrummingStoneGainAbilitySpellsEffect extends ContinuousEffectImpl { + + private final Ability ability; + private final FilterSpell filter; + + + public ThrummingStoneGainAbilitySpellsEffect(Ability ability, FilterSpell filter) { + super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); + this.ability = ability; + this.filter = filter; + staticText = filter.getMessage() + " have " + ability.getRule(); + } + + public ThrummingStoneGainAbilitySpellsEffect(final ThrummingStoneGainAbilitySpellsEffect effect) { + super(effect); + this.ability = effect.ability.copy(); + this.filter = effect.filter.copy(); + } + + @Override + public ThrummingStoneGainAbilitySpellsEffect copy() { + return new ThrummingStoneGainAbilitySpellsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (player != null && permanent != null) { + for (StackObject stackObject : game.getStack()) { + // only spells cast, so no copies of spells + if ((stackObject instanceof Spell) && !stackObject.isCopy() && stackObject.getControllerId().equals(source.getControllerId())) { + Spell spell = (Spell) stackObject; + if (filter.match(spell, game)) { + if (!spell.getAbilities().contains(ability)) { + game.getState().addOtherAbility(spell.getCard(), ability); + } + } + } + } + return true; + } + return false; + } +} + + diff --git a/Mage.Sets/src/mage/sets/coldsnap/WallOfShards.java b/Mage.Sets/src/mage/sets/coldsnap/WallOfShards.java new file mode 100644 index 00000000000..6ab64f95d8b --- /dev/null +++ b/Mage.Sets/src/mage/sets/coldsnap/WallOfShards.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.coldsnap; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.costs.common.GainLifeOpponentCost; +import mage.abilities.keyword.DefenderAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.CumulativeUpkeepAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author klayhamn + */ +public class WallOfShards extends CardImpl { + + public WallOfShards(UUID ownerId) { + super(ownerId, 23, "Wall of Shards", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "CSP"; + this.supertype.add("Snow"); + this.subtype.add("Wall"); + this.power = new MageInt(1); + this.toughness = new MageInt(8); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Cumulative upkeep-An opponent gains 1 life. + this.addAbility(new CumulativeUpkeepAbility(new GainLifeOpponentCost(1) )); + } + + public WallOfShards(final WallOfShards card) { + super(card); + } + + @Override + public WallOfShards copy() { + return new WallOfShards(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/AllianceOfArms.java b/Mage.Sets/src/mage/sets/commander/AllianceOfArms.java index 3ec3e4b7ee6..a9a20017a44 100644 --- a/Mage.Sets/src/mage/sets/commander/AllianceOfArms.java +++ b/Mage.Sets/src/mage/sets/commander/AllianceOfArms.java @@ -117,7 +117,7 @@ class AllianceOfArmsEffect extends OneShotEffect { protected static int playerPaysXGenericMana(Player player, Ability source, Game game) { int xValue = 0; boolean payed = false; - while (player.isInGame() && !payed) { + while (player.canRespond() && !payed) { xValue = player.announceXMana(0, Integer.MAX_VALUE, "How much mana will you pay?", game, source); if (xValue > 0) { Cost cost = new GenericManaCost(xValue); diff --git a/Mage.Sets/src/mage/sets/commander/AvatarOfSlaughter.java b/Mage.Sets/src/mage/sets/commander/AvatarOfSlaughter.java new file mode 100644 index 00000000000..bfe50914d20 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/AvatarOfSlaughter.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.combat.AttacksIfAbleAllEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.DoubleStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class AvatarOfSlaughter extends CardImpl { + + public AvatarOfSlaughter(UUID ownerId) { + super(ownerId, 111, "Avatar of Slaughter", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{6}{R}{R}"); + this.expansionSetCode = "CMD"; + this.subtype.add("Avatar"); + this.power = new MageInt(8); + this.toughness = new MageInt(8); + + // All creatures have double strike and attack each turn if able. + Effect effect = new GainAbilityAllEffect(DoubleStrikeAbility.getInstance(), Duration.WhileOnBattlefield); + effect.setText("All creatures have double strike"); + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); + effect = new AttacksIfAbleAllEffect(new FilterCreaturePermanent("creatures")); + effect.setText("and attack each turn if able"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public AvatarOfSlaughter(final AvatarOfSlaughter card) { + super(card); + } + + @Override + public AvatarOfSlaughter copy() { + return new AvatarOfSlaughter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/BrionStoutarm.java b/Mage.Sets/src/mage/sets/commander/BrionStoutarm.java index 7443a670474..f500c52af55 100644 --- a/Mage.Sets/src/mage/sets/commander/BrionStoutarm.java +++ b/Mage.Sets/src/mage/sets/commander/BrionStoutarm.java @@ -76,7 +76,7 @@ public class BrionStoutarm extends CardImpl { // {R}, {tap}, Sacrifice a creature other than Brion Stoutarm: Brion Stoutarm deals damage equal to the sacrificed creature's power to target player. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BrionStoutarmEffect(), new ManaCostsImpl("{R}")); ability.addCost(new TapSourceCost()); - ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1,1, filter, true))); + ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, true))); ability.addTarget(new TargetPlayer()); this.addAbility(ability); } @@ -110,9 +110,9 @@ class BrionStoutarmEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { int amount = 0; - for (Cost cost: source.getCosts()) { - if (cost instanceof SacrificeTargetCost && ((SacrificeTargetCost)cost).getPermanents().size() > 0) { - amount = ((SacrificeTargetCost)cost).getPermanents().get(0).getPower().getValue(); + for (Cost cost : source.getCosts()) { + if (cost instanceof SacrificeTargetCost && ((SacrificeTargetCost) cost).getPermanents().size() > 0) { + amount = ((SacrificeTargetCost) cost).getPermanents().get(0).getPower().getValue(); break; } } @@ -120,9 +120,8 @@ class BrionStoutarmEffect extends OneShotEffect { Player player = game.getPlayer(source.getFirstTarget()); if (player != null) { player.damage(amount, source.getSourceId(), game, false, true); - return true; } } - return false; + return true; } } diff --git a/Mage.Sets/src/mage/sets/commander/CollectiveVoyage.java b/Mage.Sets/src/mage/sets/commander/CollectiveVoyage.java index 3c5d7f16a40..4c90f57ebc3 100644 --- a/Mage.Sets/src/mage/sets/commander/CollectiveVoyage.java +++ b/Mage.Sets/src/mage/sets/commander/CollectiveVoyage.java @@ -126,7 +126,7 @@ class CollectiveVoyageEffect extends OneShotEffect { protected static int playerPaysXGenericMana(Player player, Ability source, Game game) { int xValue = 0; boolean payed = false; - while (player.isInGame() && !payed) { + while (player.canRespond() && !payed) { xValue = player.announceXMana(0, Integer.MAX_VALUE, "How much mana will you pay?", game, source); if (xValue > 0) { Cost cost = new GenericManaCost(xValue); diff --git a/Mage.Sets/src/mage/sets/commander/CrescendoOfWar.java b/Mage.Sets/src/mage/sets/commander/CrescendoOfWar.java new file mode 100644 index 00000000000..a2799d9dfc0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/CrescendoOfWar.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class CrescendoOfWar extends mage.sets.vintagemasters.CrescendoOfWar { + + public CrescendoOfWar(UUID ownerId) { + super(ownerId); + this.cardNumber = 12; + this.expansionSetCode = "CMD"; + } + + public CrescendoOfWar(final CrescendoOfWar card) { + super(card); + } + + @Override + public CrescendoOfWar copy() { + return new CrescendoOfWar(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/DesecratorHag.java b/Mage.Sets/src/mage/sets/commander/DesecratorHag.java index e596914c128..6f13d8c35af 100644 --- a/Mage.Sets/src/mage/sets/commander/DesecratorHag.java +++ b/Mage.Sets/src/mage/sets/commander/DesecratorHag.java @@ -113,22 +113,20 @@ class DesecratorHagEffect extends OneShotEffect { } } if (cards.size() == 0) { - return false; + return true; } if (cards.size() > 1 && you.choose(Outcome.DrawCard, cards, target, game)) { if (target != null) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { - return you.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + return you.moveCards(card, null, Zone.HAND, source, game); } } } else { - for (Card card : cards.getCards(game)) { - return you.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } + return you.moveCards(cards, null, Zone.HAND, source, game); } } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/commander/DuergarHedgeMage.java b/Mage.Sets/src/mage/sets/commander/DuergarHedgeMage.java index c8aca6974f8..74cbf400920 100644 --- a/Mage.Sets/src/mage/sets/commander/DuergarHedgeMage.java +++ b/Mage.Sets/src/mage/sets/commander/DuergarHedgeMage.java @@ -60,8 +60,8 @@ public class DuergarHedgeMage extends CardImpl { filter2.add(new SubtypePredicate("Plains")); filter3.add(new CardTypePredicate(CardType.ENCHANTMENT)); } - private String rule1 = "When {this} enters the battlefield, if you control two or more Mountains, you may destroy target artifact."; - private String rule2 = "When {this} enters the battlefield, if you control two or more Plains, you may destroy target enchantment."; + private final String rule1 = "When {this} enters the battlefield, if you control two or more Mountains, you may destroy target artifact."; + private final String rule2 = "When {this} enters the battlefield, if you control two or more Plains, you may destroy target enchantment."; public DuergarHedgeMage(UUID ownerId) { super(ownerId, 195, "Duergar Hedge-Mage", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{R/W}"); diff --git a/Mage.Sets/src/mage/sets/commander/FootbottomFeast.java b/Mage.Sets/src/mage/sets/commander/FootbottomFeast.java new file mode 100644 index 00000000000..4e9e0d6db75 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/FootbottomFeast.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class FootbottomFeast extends CardImpl { + + public FootbottomFeast(UUID ownerId) { + super(ownerId, 84, "Footbottom Feast", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{B}"); + this.expansionSetCode = "CMD"; + + // Put any number of target creature cards from your graveyard on top of your library. + this.getSpellAbility().addEffect(new PutOnLibraryTargetEffect(true)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, Integer.MAX_VALUE, new FilterCreatureCard("creature cards from your graveyard"))); + + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public FootbottomFeast(final FootbottomFeast card) { + super(card); + } + + @Override + public FootbottomFeast copy() { + return new FootbottomFeast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/HydraOmnivore.java b/Mage.Sets/src/mage/sets/commander/HydraOmnivore.java index dd8d6c6eb69..fea88abc3d2 100644 --- a/Mage.Sets/src/mage/sets/commander/HydraOmnivore.java +++ b/Mage.Sets/src/mage/sets/commander/HydraOmnivore.java @@ -31,8 +31,8 @@ import java.util.UUID; import mage.MageInt; import mage.MageObject; import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; diff --git a/Mage.Sets/src/mage/sets/commander/KodamasReach.java b/Mage.Sets/src/mage/sets/commander/KodamasReach.java index 1be260fab28..6b7883e9e8b 100644 --- a/Mage.Sets/src/mage/sets/commander/KodamasReach.java +++ b/Mage.Sets/src/mage/sets/commander/KodamasReach.java @@ -27,8 +27,8 @@ */ package mage.sets.commander; -import java.util.List; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; @@ -57,7 +57,6 @@ public class KodamasReach extends CardImpl { this.expansionSetCode = "CMD"; this.subtype.add("Arcane"); - // Search your library for up to two basic land cards, reveal those cards, and put one onto the battlefield tapped and the other into your hand. Then shuffle your library. this.getSpellAbility().addEffect(new KodamasReachEffect()); } @@ -92,43 +91,46 @@ class KodamasReachEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { + return false; + } TargetCardInLibrary target = new TargetCardInLibrary(0, 2, new FilterBasicLandCard()); - Player player = game.getPlayer(source.getControllerId()); - if (player.searchLibrary(target, game)) { + if (controller.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { Cards revealed = new CardsImpl(); - for (UUID cardId: target.getTargets()) { - Card card = player.getLibrary().getCard(cardId, game); + for (UUID cardId : target.getTargets()) { + Card card = controller.getLibrary().getCard(cardId, game); revealed.add(card); } - player.revealCards("Kodama's Reach", revealed, game); + controller.revealCards(sourceObject.getIdName(), revealed, game); if (target.getTargets().size() == 2) { TargetCard target2 = new TargetCard(Zone.PICK, filter); - player.choose(Outcome.Benefit, revealed, target2, game); + controller.choose(Outcome.Benefit, revealed, target2, game); Card card = revealed.get(target2.getFirstTarget(), game); if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); revealed.remove(card); } card = revealed.getCards(game).iterator().next(); if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); } - } - else if (target.getTargets().size() == 1) { + } else if (target.getTargets().size() == 1) { Card card = revealed.getCards(game).iterator().next(); if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); } } } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return true; } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/commander/ManaChargedDragon.java b/Mage.Sets/src/mage/sets/commander/ManaChargedDragon.java index 116b0b82e47..e12f2e8cbc0 100644 --- a/Mage.Sets/src/mage/sets/commander/ManaChargedDragon.java +++ b/Mage.Sets/src/mage/sets/commander/ManaChargedDragon.java @@ -96,7 +96,7 @@ class ManaChargedDragonEffect extends OneShotEffect { protected static int playerPaysXGenericMana(Player player, Ability source, Game game) { int xValue = 0; boolean payed = false; - while (player.isInGame() && !payed) { + while (player.canRespond() && !payed) { xValue = player.announceXMana(0, Integer.MAX_VALUE, "How much mana will you pay?", game, source); if (xValue > 0) { Cost cost = new GenericManaCost(xValue); diff --git a/Mage.Sets/src/mage/sets/commander/MindsAglow.java b/Mage.Sets/src/mage/sets/commander/MindsAglow.java index 12cba52d24e..5ba8d8bf439 100644 --- a/Mage.Sets/src/mage/sets/commander/MindsAglow.java +++ b/Mage.Sets/src/mage/sets/commander/MindsAglow.java @@ -115,7 +115,7 @@ class MindsAglowEffect extends OneShotEffect { protected static int playerPaysXGenericMana(Player player, Ability source, Game game) { int xValue = 0; boolean payed = false; - while (player.isInGame() && !payed) { + while (player.canRespond() && !payed) { xValue = player.announceXMana(0, Integer.MAX_VALUE, "How much mana will you pay?", game, source); if (xValue > 0) { Cost cost = new GenericManaCost(xValue); diff --git a/Mage.Sets/src/mage/sets/commander/MonkRealist.java b/Mage.Sets/src/mage/sets/commander/MonkRealist.java new file mode 100644 index 00000000000..25d5c90680f --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/MonkRealist.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class MonkRealist extends mage.sets.urzassaga.MonkRealist { + + public MonkRealist(UUID ownerId) { + super(ownerId); + this.cardNumber = 20; + this.expansionSetCode = "CMD"; + } + + public MonkRealist(final MonkRealist card) { + super(card); + } + + @Override + public MonkRealist copy() { + return new MonkRealist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/Pyrohemia.java b/Mage.Sets/src/mage/sets/commander/Pyrohemia.java new file mode 100644 index 00000000000..7512a9fe6f0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/Pyrohemia.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Pyrohemia extends mage.sets.planarchaos.Pyrohemia { + + public Pyrohemia(UUID ownerId) { + super(ownerId); + this.cardNumber = 132; + this.expansionSetCode = "CMD"; + } + + public Pyrohemia(final Pyrohemia card) { + super(card); + } + + @Override + public Pyrohemia copy() { + return new Pyrohemia(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/SharedTrauma.java b/Mage.Sets/src/mage/sets/commander/SharedTrauma.java index bbbee2c23e9..79656863cff 100644 --- a/Mage.Sets/src/mage/sets/commander/SharedTrauma.java +++ b/Mage.Sets/src/mage/sets/commander/SharedTrauma.java @@ -116,7 +116,7 @@ class SharedTraumaEffect extends OneShotEffect { protected static int playerPaysXGenericMana(Player player, Ability source, Game game) { int xValue = 0; boolean payed = false; - while (player.isInGame() && !payed) { + while (player.canRespond() && !payed) { xValue = player.announceXMana(0, Integer.MAX_VALUE, "How much mana will you pay?", game, source); if (xValue > 0) { Cost cost = new GenericManaCost(xValue); diff --git a/Mage.Sets/src/mage/sets/commander/SlipstreamEel.java b/Mage.Sets/src/mage/sets/commander/SlipstreamEel.java new file mode 100644 index 00000000000..acd4a3c155d --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/SlipstreamEel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class SlipstreamEel extends mage.sets.onslaught.SlipstreamEel { + + public SlipstreamEel(UUID ownerId) { + super(ownerId); + this.cardNumber = 62; + this.expansionSetCode = "CMD"; + } + + public SlipstreamEel(final SlipstreamEel card) { + super(card); + } + + @Override + public SlipstreamEel copy() { + return new SlipstreamEel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/SpurnmageAdvocate.java b/Mage.Sets/src/mage/sets/commander/SpurnmageAdvocate.java new file mode 100644 index 00000000000..2391cab356a --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/SpurnmageAdvocate.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.other.OwnerPredicate; +import mage.target.common.TargetAttackingCreature; +import mage.target.common.TargetCardInASingleGraveyard; +import mage.target.targetpointer.SecondTargetPointer; + +/** + * + * @author LevelX2 + */ +public class SpurnmageAdvocate extends CardImpl { + + private static final FilterCard filter = new FilterCard("two target cards from an opponent's graveyard"); + + static { + filter.add(new OwnerPredicate(TargetController.OPPONENT)); + } + + public SpurnmageAdvocate(UUID ownerId) { + super(ownerId, 33, "Spurnmage Advocate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "CMD"; + this.subtype.add("Human"); + this.subtype.add("Nomad"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Return two target cards from an opponent's graveyard to his or her hand. Destroy target attacking creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new TapSourceCost()); + ability.addTarget(new TargetCardInASingleGraveyard(2, 2, filter)); + Effect effect = new DestroyTargetEffect(); + effect.setTargetPointer(new SecondTargetPointer()); + ability.addEffect(effect); + ability.addTarget(new TargetAttackingCreature()); + this.addAbility(ability); + } + + public SpurnmageAdvocate(final SpurnmageAdvocate card) { + super(card); + } + + @Override + public SpurnmageAdvocate copy() { + return new SpurnmageAdvocate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/Squallmonger.java b/Mage.Sets/src/mage/sets/commander/Squallmonger.java new file mode 100644 index 00000000000..2e54b1d3c2b --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/Squallmonger.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageAllEffect; +import mage.abilities.effects.common.DamagePlayersEffect; +import mage.abilities.effects.common.InfoEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.AbilityPredicate; + +/** + * + * @author fireshoes + */ +public class Squallmonger extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying"); + + static { + filter.add(new AbilityPredicate(FlyingAbility.class)); + } + + public Squallmonger(UUID ownerId) { + super(ownerId, 173, "Squallmonger", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "CMD"; + this.subtype.add("Monger"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {2}: Squallmonger deals 1 damage to each creature with flying and each player. Any player may activate this ability. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageAllEffect(1, filter), new ManaCostsImpl("{2}")); + Effect effect = new DamagePlayersEffect(1); + effect.setText("and each player"); + ability.addEffect(effect); + ability.setMayActivate(TargetController.ANY); + ability.addEffect(new InfoEffect("Any player may activate this ability")); + this.addAbility(ability); + } + + public Squallmonger(final Squallmonger card) { + super(card); + } + + @Override + public Squallmonger copy() { + return new Squallmonger(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/StitchTogether.java b/Mage.Sets/src/mage/sets/commander/StitchTogether.java new file mode 100644 index 00000000000..f99b726da56 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/StitchTogether.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.abilities.condition.common.CardsInControllerGraveCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect; +import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class StitchTogether extends CardImpl { + + public StitchTogether(UUID ownerId) { + super(ownerId, 102, "Stitch Together", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{B}{B}"); + this.expansionSetCode = "CMD"; + + // Return target creature card from your graveyard to your hand. + // Threshold - Return that card from your graveyard to the battlefield instead if seven or more cards are in your graveyard. + Effect effect = new ConditionalOneShotEffect( + new ReturnFromGraveyardToBattlefieldTargetEffect(), + new ReturnFromGraveyardToHandTargetEffect(), + new CardsInControllerGraveCondition(7), + "Return target creature card from your graveyard to your hand.

Threshold - Return that card from your graveyard to the battlefield instead if seven or more cards are in your graveyard."); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard"))); + } + + public StitchTogether(final StitchTogether card) { + super(card); + } + + @Override + public StitchTogether copy() { + return new StitchTogether(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/StormHerd.java b/Mage.Sets/src/mage/sets/commander/StormHerd.java new file mode 100644 index 00000000000..ba28212f94a --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/StormHerd.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class StormHerd extends mage.sets.guildpact.StormHerd { + + public StormHerd(UUID ownerId) { + super(ownerId); + this.cardNumber = 34; + this.expansionSetCode = "CMD"; + } + + public StormHerd(final StormHerd card) { + super(card); + } + + @Override + public StormHerd copy() { + return new StormHerd(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/Stranglehold.java b/Mage.Sets/src/mage/sets/commander/Stranglehold.java index e129b6c3108..ae748538b58 100644 --- a/Mage.Sets/src/mage/sets/commander/Stranglehold.java +++ b/Mage.Sets/src/mage/sets/commander/Stranglehold.java @@ -30,6 +30,7 @@ package mage.sets.commander; import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.abilities.effects.ReplacementEffectImpl; import mage.cards.CardImpl; @@ -37,6 +38,7 @@ import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Outcome; import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; @@ -53,10 +55,10 @@ public class Stranglehold extends CardImpl { this.expansionSetCode = "CMD"; // Your opponents can't search libraries. - this.getSpellAbility().addEffect(new OpponentsCantSearchLibarariesEffect()); - + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OpponentsCantSearchLibarariesEffect())); + // If an opponent would begin an extra turn, that player skips that turn instead. - this.getSpellAbility().addEffect(new StrangleholdSkipExtraTurnsEffect()); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new StrangleholdSkipExtraTurnsEffect())); } public Stranglehold(final Stranglehold card) { @@ -103,7 +105,7 @@ class OpponentsCantSearchLibarariesEffect extends ContinuousRuleModifyingEffectI public boolean checksEventType(GameEvent event, Game game) { return EventType.SEARCH_LIBRARY.equals(event.getType()); } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { Player controller = game.getPlayer(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/commander/SulfurousBlast.java b/Mage.Sets/src/mage/sets/commander/SulfurousBlast.java new file mode 100644 index 00000000000..8b40eebcc84 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/SulfurousBlast.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class SulfurousBlast extends mage.sets.timespiral.SulfurousBlast { + + public SulfurousBlast(UUID ownerId) { + super(ownerId); + this.cardNumber = 137; + this.expansionSetCode = "CMD"; + } + + public SulfurousBlast(final SulfurousBlast card) { + super(card); + } + + @Override + public SulfurousBlast copy() { + return new SulfurousBlast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/TarielReckonerOfSouls.java b/Mage.Sets/src/mage/sets/commander/TarielReckonerOfSouls.java new file mode 100644 index 00000000000..7cfe1e0b577 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/TarielReckonerOfSouls.java @@ -0,0 +1,119 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +/** + * + * @author LevelX2 + */ +public class TarielReckonerOfSouls extends CardImpl { + + public TarielReckonerOfSouls(UUID ownerId) { + super(ownerId, 229, "Tariel, Reckoner of Souls", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{4}{W}{B}{R}"); + this.expansionSetCode = "CMD"; + this.supertype.add("Legendary"); + this.subtype.add("Angel"); + this.power = new MageInt(4); + this.toughness = new MageInt(7); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Vigilance + this.addAbility(VigilanceAbility.getInstance()); + // {T}: Choose a creature card at random from target opponent's graveyard. Put that card onto the battlefield under your control. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TarielReckonerOfSoulsEffect(), new TapSourceCost()); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + + } + + public TarielReckonerOfSouls(final TarielReckonerOfSouls card) { + super(card); + } + + @Override + public TarielReckonerOfSouls copy() { + return new TarielReckonerOfSouls(this); + } +} + +class TarielReckonerOfSoulsEffect extends OneShotEffect { + + public TarielReckonerOfSoulsEffect() { + super(Outcome.PutCardInPlay); + this.staticText = "Choose a creature card at random from target opponent's graveyard. Put that card onto the battlefield under your control"; + } + + public TarielReckonerOfSoulsEffect(final TarielReckonerOfSoulsEffect effect) { + super(effect); + } + + @Override + public TarielReckonerOfSoulsEffect copy() { + return new TarielReckonerOfSoulsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Player targetOpponent = game.getPlayer(getTargetPointer().getFirst(game, source)); + if (controller != null && targetOpponent != null) { + Cards creatureCards = new CardsImpl(); + for (Card card : targetOpponent.getGraveyard().getCards(new FilterCreatureCard(), game)) { + creatureCards.add(card); + } + if (!creatureCards.isEmpty()) { + Card card = creatureCards.getRandom(game); + controller.putOntoBattlefieldWithInfo(card, game, Zone.GRAVEYARD, source.getSourceId()); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/commander/Triskelavus.java b/Mage.Sets/src/mage/sets/commander/Triskelavus.java new file mode 100644 index 00000000000..4c7a7f021c3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/Triskelavus.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Triskelavus extends mage.sets.timespiral.Triskelavus { + + public Triskelavus(UUID ownerId) { + super(ownerId); + this.cardNumber = 263; + this.expansionSetCode = "CMD"; + } + + public Triskelavus(final Triskelavus card) { + super(card); + } + + @Override + public Triskelavus copy() { + return new Triskelavus(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/Unnerve.java b/Mage.Sets/src/mage/sets/commander/Unnerve.java new file mode 100644 index 00000000000..f06939f9d4d --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/Unnerve.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Unnerve extends mage.sets.urzassaga.Unnerve { + + public Unnerve(UUID ownerId) { + super(ownerId); + this.cardNumber = 105; + this.expansionSetCode = "CMD"; + } + + public Unnerve(final Unnerve card) { + super(card); + } + + @Override + public Unnerve copy() { + return new Unnerve(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/VedalkenPlotter.java b/Mage.Sets/src/mage/sets/commander/VedalkenPlotter.java new file mode 100644 index 00000000000..2a38229d15f --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/VedalkenPlotter.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class VedalkenPlotter extends mage.sets.guildpact.VedalkenPlotter { + + public VedalkenPlotter(UUID ownerId) { + super(ownerId); + this.cardNumber = 66; + this.expansionSetCode = "CMD"; + } + + public VedalkenPlotter(final VedalkenPlotter card) { + super(card); + } + + @Override + public VedalkenPlotter copy() { + return new VedalkenPlotter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/commander/WhirlpoolWhelm.java b/Mage.Sets/src/mage/sets/commander/WhirlpoolWhelm.java index 88036f444a0..b8c2db6801f 100644 --- a/Mage.Sets/src/mage/sets/commander/WhirlpoolWhelm.java +++ b/Mage.Sets/src/mage/sets/commander/WhirlpoolWhelm.java @@ -51,7 +51,6 @@ public class WhirlpoolWhelm extends CardImpl { super(ownerId, 69, "Whirlpool Whelm", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); this.expansionSetCode = "CMD"; - // Clash with an opponent, then return target creature to its owner's hand. If you win, you may put that creature on top of its owner's library instead. this.getSpellAbility().addEffect(new WhirlpoolWhelmEffect()); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); @@ -90,15 +89,15 @@ class WhirlpoolWhelmEffect extends OneShotEffect { if (controller != null) { boolean topOfLibrary = false; if (ClashEffect.getInstance().apply(game, source)) { - topOfLibrary = controller.chooseUse(outcome, "Put " + creature.getLogName() + " to top of libraray instead?" , source, game); + topOfLibrary = controller.chooseUse(outcome, "Put " + creature.getLogName() + " to top of libraray instead?", source, game); } if (topOfLibrary) { - controller.moveCardToHandWithInfo(creature, source.getSourceId(), game, Zone.BATTLEFIELD); - } else { controller.moveCardToLibraryWithInfo(creature, source.getSourceId(), game, Zone.BATTLEFIELD, true, true); + } else { + controller.moveCards(creature, null, Zone.HAND, source, game); } return true; } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/commander/ZedruuTheGreathearted.java b/Mage.Sets/src/mage/sets/commander/ZedruuTheGreathearted.java new file mode 100644 index 00000000000..d7562042347 --- /dev/null +++ b/Mage.Sets/src/mage/sets/commander/ZedruuTheGreathearted.java @@ -0,0 +1,132 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.commander; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObjectReference; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.PermanentsYouOwnThatOpponentsControlCount; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetOpponent; + +/** + * + * @author andyfries + */ +public class ZedruuTheGreathearted extends CardImpl { + + public ZedruuTheGreathearted(UUID ownerId) { + super(ownerId, 240, "Zedruu the Greathearted", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{1}{R}{W}{U}"); + this.expansionSetCode = "CMD"; + this.supertype.add("Legendary"); + this.subtype.add("Minotaur"); + this.subtype.add("Monk"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // At the beginning of your upkeep, you gain X life and draw X cards, where X is the number of permanents you own that your opponents control. + Effect effect = new GainLifeEffect(new PermanentsYouOwnThatOpponentsControlCount()); + effect.setText("you gain X life"); + Ability ability = new BeginningOfUpkeepTriggeredAbility(effect, TargetController.YOU, false); + effect = new DrawCardSourceControllerEffect(new PermanentsYouOwnThatOpponentsControlCount()); + effect.setText("and draw X cards, where X is the number of permanents you own that your opponents control"); + ability.addEffect(effect); + this.addAbility(ability); + + // {R}{W}{U}: Target opponent gains control of target permanent you control. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ZedruuTheGreatheartedEffect(), new ManaCostsImpl("{R}{W}{U}")); + ability.addTarget(new TargetOpponent()); + ability.addTarget(new TargetControlledPermanent()); + this.addAbility(ability); + } + + public ZedruuTheGreathearted(final ZedruuTheGreathearted card) { + super(card); + } + + @Override + public ZedruuTheGreathearted copy() { + return new ZedruuTheGreathearted(this); + } + + class ZedruuTheGreatheartedEffect extends ContinuousEffectImpl { + + private MageObjectReference targetPermanentReference; + + public ZedruuTheGreatheartedEffect() { + super(Duration.Custom, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); + this.staticText = "Target opponent gains control of target permanent you control"; + } + + public ZedruuTheGreatheartedEffect(final ZedruuTheGreatheartedEffect effect) { + super(effect); + this.targetPermanentReference = effect.targetPermanentReference; + } + + @Override + public ZedruuTheGreatheartedEffect copy() { + return new ZedruuTheGreatheartedEffect(this); + } + + @Override + public void init(Ability source, Game game) { + super.init(source, game); + targetPermanentReference = new MageObjectReference(source.getTargets().get(1).getFirstTarget(), game); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = targetPermanentReference.getPermanent(game); + if (permanent != null) { + return permanent.changeControllerId(source.getFirstTarget(), game); + } else { + discard(); + } + return false; + } + } +} diff --git a/Mage.Sets/src/mage/sets/commander2013/CurseOfShallowGraves.java b/Mage.Sets/src/mage/sets/commander2013/CurseOfShallowGraves.java index fa2e34e982f..d51655b3c7d 100644 --- a/Mage.Sets/src/mage/sets/commander2013/CurseOfShallowGraves.java +++ b/Mage.Sets/src/mage/sets/commander2013/CurseOfShallowGraves.java @@ -28,9 +28,11 @@ package mage.sets.commander2013; import java.util.UUID; +import mage.abilities.Ability; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.CreateTokenTargetEffect; import mage.abilities.keyword.EnchantAbility; @@ -44,6 +46,7 @@ import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; import mage.game.permanent.token.ZombieToken; +import mage.players.Player; import mage.target.TargetPlayer; import mage.target.targetpointer.FixedTarget; @@ -59,7 +62,6 @@ public class CurseOfShallowGraves extends CardImpl { this.subtype.add("Aura"); this.subtype.add("Curse"); - // Enchant player TargetPlayer auraTarget = new TargetPlayer(); this.getSpellAbility().addTarget(auraTarget); @@ -83,7 +85,7 @@ public class CurseOfShallowGraves extends CardImpl { class CurseOfShallowTriggeredAbility extends TriggeredAbilityImpl { public CurseOfShallowTriggeredAbility() { - super(Zone.BATTLEFIELD, new CreateTokenTargetEffect(new ZombieToken(), new StaticValue(1), true, false), true); + super(Zone.BATTLEFIELD, new CurseOfShallowEffect()); } public CurseOfShallowTriggeredAbility(Effect effect, boolean optional, String text) { @@ -105,7 +107,7 @@ class CurseOfShallowTriggeredAbility extends TriggeredAbilityImpl { if (enchantment != null && enchantment.getAttachedTo() != null && game.getCombat().getPlayerDefenders(game).contains(enchantment.getAttachedTo())) { - for (Effect effect: this.getEffects()) { + for (Effect effect : this.getEffects()) { effect.setTargetPointer(new FixedTarget(game.getCombat().getAttackerId())); } return true; @@ -124,3 +126,31 @@ class CurseOfShallowTriggeredAbility extends TriggeredAbilityImpl { } } + +class CurseOfShallowEffect extends OneShotEffect { + + public CurseOfShallowEffect() { + super(Outcome.Benefit); + this.staticText = "that attacking player may put a 2/2 black Zombie creature token onto the battlefield tapped"; + } + + public CurseOfShallowEffect(final CurseOfShallowEffect effect) { + super(effect); + } + + @Override + public CurseOfShallowEffect copy() { + return new CurseOfShallowEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player attacker = game.getPlayer(this.getTargetPointer().getFirst(game, source)); + if (attacker != null && attacker.chooseUse(outcome, "Put a 2/2 black Zombie creature token onto the battlefield tapped?", source, game)) { + Effect effect = new CreateTokenTargetEffect(new ZombieToken(), new StaticValue(1), true, false); + effect.setTargetPointer(targetPointer); + return effect.apply(game, source); + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/commander2013/EndrekSahrMasterBreeder.java b/Mage.Sets/src/mage/sets/commander2013/EndrekSahrMasterBreeder.java index 9396551ffe3..dfed94b5507 100644 --- a/Mage.Sets/src/mage/sets/commander2013/EndrekSahrMasterBreeder.java +++ b/Mage.Sets/src/mage/sets/commander2013/EndrekSahrMasterBreeder.java @@ -30,7 +30,7 @@ package mage.sets.commander2013; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.common.SpellCastControllerTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.CreateTokenEffect; @@ -40,12 +40,11 @@ import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; +import mage.filter.Filter; import mage.filter.FilterSpell; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.CardTypePredicate; -import mage.filter.predicate.mageobject.SubtypePredicate; import mage.game.Game; -import mage.game.events.GameEvent; import mage.game.permanent.token.Token; import mage.game.stack.Spell; import mage.target.targetpointer.FixedTarget; @@ -57,6 +56,7 @@ import mage.target.targetpointer.FixedTarget; public class EndrekSahrMasterBreeder extends CardImpl { private static final FilterSpell filter = new FilterSpell("a creature spell"); + static { filter.add(new CardTypePredicate(CardType.CREATURE)); } @@ -74,7 +74,9 @@ public class EndrekSahrMasterBreeder extends CardImpl { // Whenever you cast a creature spell, put X 1/1 black Thrull creature tokens onto the battlefield, where X is that spell's converted mana cost. this.addAbility(new SpellCastControllerTriggeredAbility(new EndrekSahrMasterBreederEffect(), filter, false, true)); // When you control seven or more Thrulls, sacrifice Endrek Sahr, Master Breeder. - this.addAbility(new EndrekSahrMasterBreederTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterCreaturePermanent("Thrull", "seven or more Thrulls"), Filter.ComparisonType.GreaterThan, 6, + new SacrificeSourceEffect())); } public EndrekSahrMasterBreeder(final EndrekSahrMasterBreeder card) { @@ -87,37 +89,6 @@ public class EndrekSahrMasterBreeder extends CardImpl { } } -class EndrekSahrMasterBreederTriggeredAbility extends StateTriggeredAbility { - - private static final FilterCreaturePermanent filter = new FilterCreaturePermanent(); - static { - filter.add(new SubtypePredicate("Thrull")); - } - - public EndrekSahrMasterBreederTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - public EndrekSahrMasterBreederTriggeredAbility(final EndrekSahrMasterBreederTriggeredAbility ability) { - super(ability); - } - - @Override - public EndrekSahrMasterBreederTriggeredAbility copy() { - return new EndrekSahrMasterBreederTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return (game.getBattlefield().countAll(filter, this.getControllerId(), game) >= 7); - } - - @Override - public String getRule() { - return "When you control seven or more Thrulls, sacrifice {this}."; - } -} - class EndrekSahrMasterBreederEffect extends OneShotEffect { public EndrekSahrMasterBreederEffect() { @@ -138,8 +109,8 @@ class EndrekSahrMasterBreederEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Spell spell = game.getStack().getSpell(targetPointer.getFirst(game, source)); if (spell == null) { - spell = (Spell) game.getLastKnownInformation(((FixedTarget)getTargetPointer()).getTarget(), Zone.STACK); - } + spell = (Spell) game.getLastKnownInformation(((FixedTarget) getTargetPointer()).getTarget(), Zone.STACK); + } if (spell != null) { int cmc = spell.getConvertedManaCost(); if (cmc > 0) { diff --git a/Mage.Sets/src/mage/sets/commander2013/LimDulsVault.java b/Mage.Sets/src/mage/sets/commander2013/LimDulsVault.java index 70324bd4e97..16dfe1a4085 100644 --- a/Mage.Sets/src/mage/sets/commander2013/LimDulsVault.java +++ b/Mage.Sets/src/mage/sets/commander2013/LimDulsVault.java @@ -113,7 +113,7 @@ class LimDulsVaultEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard(doAgain ? textBottom : textTop)); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/commander2013/LuXunScholarGeneral.java b/Mage.Sets/src/mage/sets/commander2013/LuXunScholarGeneral.java index 32ea1712b71..e8e4489d913 100644 --- a/Mage.Sets/src/mage/sets/commander2013/LuXunScholarGeneral.java +++ b/Mage.Sets/src/mage/sets/commander2013/LuXunScholarGeneral.java @@ -29,7 +29,7 @@ package mage.sets.commander2013; import java.util.UUID; import mage.MageInt; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.keyword.HorsemanshipAbility; import mage.cards.CardImpl; diff --git a/Mage.Sets/src/mage/sets/commander2013/MysticBarrier.java b/Mage.Sets/src/mage/sets/commander2013/MysticBarrier.java index d09ebee60d1..51cbccf2b28 100644 --- a/Mage.Sets/src/mage/sets/commander2013/MysticBarrier.java +++ b/Mage.Sets/src/mage/sets/commander2013/MysticBarrier.java @@ -147,7 +147,7 @@ class MysticBarrierChooseEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { DIRECTION_CHOICE.clearChoice(); - while (!DIRECTION_CHOICE.isChosen() && controller.isInGame()) { + while (!DIRECTION_CHOICE.isChosen() && controller.canRespond()) { controller.choose(outcome, DIRECTION_CHOICE, game); } if (!DIRECTION_CHOICE.getChoice().isEmpty()) { diff --git a/Mage.Sets/src/mage/sets/commander2013/OrderOfSuccession.java b/Mage.Sets/src/mage/sets/commander2013/OrderOfSuccession.java index 207d3d143d9..e62790e6d4c 100644 --- a/Mage.Sets/src/mage/sets/commander2013/OrderOfSuccession.java +++ b/Mage.Sets/src/mage/sets/commander2013/OrderOfSuccession.java @@ -100,14 +100,14 @@ class OrderOfSuccessionEffect extends OneShotEffect { boolean left = source.getChoices().get(0).getChoice().equals("Left"); PlayerList playerList = game.getState().getPlayerList().copy(); // set playerlist to controller - while (!playerList.get().equals(source.getControllerId()) && controller.isInGame()) { + while (!playerList.get().equals(source.getControllerId()) && controller.canRespond()) { playerList.getNext(); } Player currentPlayer = game.getPlayer(playerList.get()); Player nextPlayer; UUID firstNextPlayer = null; - while (!getNextPlayerInDirection(left, playerList, game).equals(firstNextPlayer) && controller.isInGame()){ + while (!getNextPlayerInDirection(left, playerList, game).equals(firstNextPlayer) && controller.canRespond()){ nextPlayer = game.getPlayer(playerList.get()); if (nextPlayer == null) { return false; @@ -116,7 +116,7 @@ class OrderOfSuccessionEffect extends OneShotEffect { if (firstNextPlayer == null) { firstNextPlayer = nextPlayer.getId(); } - if (!nextPlayer.isInGame()) { + if (!nextPlayer.canRespond()) { continue; } // if player is in range he chooses a creature to control diff --git a/Mage.Sets/src/mage/sets/commander2013/SunDroplet.java b/Mage.Sets/src/mage/sets/commander2013/SunDroplet.java index acc33c800a6..815034633f3 100644 --- a/Mage.Sets/src/mage/sets/commander2013/SunDroplet.java +++ b/Mage.Sets/src/mage/sets/commander2013/SunDroplet.java @@ -63,10 +63,10 @@ public class SunDroplet extends CardImpl { // Whenever you're dealt damage, put that many charge counters on Sun Droplet. this.addAbility(new SunDropletTriggeredAbility()); // At the beginning of each upkeep, you may remove a charge counter from Sun Droplet. If you do, you gain 1 life. - Effect effect = new DoIfCostPaid(new GainLifeEffect(1),new RemoveCountersSourceCost(CounterType.CHARGE.createInstance(1))); + Effect effect = new DoIfCostPaid(new GainLifeEffect(1), new RemoveCountersSourceCost(CounterType.CHARGE.createInstance(1))); this.addAbility(new ConditionalTriggeredAbility(new BeginningOfUpkeepTriggeredAbility(effect, TargetController.ANY, false), new SourceHasCounterCondition(CounterType.CHARGE, 1), - "At the beginning of each upkeep, you may remove a charge counter from Sun Droplet. If you do, you gain 1 life", false)); + "At the beginning of each upkeep, you may remove a charge counter from Sun Droplet. If you do, you gain 1 life")); } public SunDroplet(final SunDroplet card) { diff --git a/Mage.Sets/src/mage/sets/commander2014/BitterFeud.java b/Mage.Sets/src/mage/sets/commander2014/BitterFeud.java index 91083dff8e9..7ba41f23715 100644 --- a/Mage.Sets/src/mage/sets/commander2014/BitterFeud.java +++ b/Mage.Sets/src/mage/sets/commander2014/BitterFeud.java @@ -60,12 +60,11 @@ public class BitterFeud extends CardImpl { super(ownerId, 32, "Bitter Feud", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{4}{R}"); this.expansionSetCode = "C14"; - // As Bitter Feud enters the battlefield, choose two players. this.addAbility(new AsEntersBattlefieldAbility(new BitterFeudEntersBattlefieldEffect())); // If a source controlled by one of the chosen players would deal damage to the other chosen player or a permanent that player controls, that source deals double that damage to that player or permanent instead. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BitterFeudEffect() )); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BitterFeudEffect())); } public BitterFeud(final BitterFeud card) { @@ -94,16 +93,18 @@ class BitterFeudEntersBattlefieldEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); Permanent permanent = game.getPermanent(source.getSourceId()); if (controller != null && permanent != null) { - TargetPlayer target = new TargetPlayer(2,2, true); + TargetPlayer target = new TargetPlayer(2, 2, true); controller.chooseTarget(outcome, target, source, game); Player player1 = game.getPlayer(target.getFirstTarget()); - Player player2 = game.getPlayer(target.getTargets().get(1)); - if (player1 != null && player2 != null) { - game.getState().setValue(source.getSourceId() + "_player1", player1); - game.getState().setValue(source.getSourceId() + "_player2", player2); - game.informPlayers(permanent.getLogName() + ": " + controller.getLogName() + " has chosen " + player1.getLogName() + " and " + player2.getLogName()); - permanent.addInfo("chosen players", "Chosen players: " + player1.getName() +", " + player2.getName() + "", game); - return true; + if (target.getTargets().size() > 1) { + Player player2 = game.getPlayer(target.getTargets().get(1)); + if (player1 != null && player2 != null) { + game.getState().setValue(source.getSourceId() + "_player1", player1); + game.getState().setValue(source.getSourceId() + "_player2", player2); + game.informPlayers(permanent.getLogName() + ": " + controller.getLogName() + " has chosen " + player1.getLogName() + " and " + player2.getLogName()); + permanent.addInfo("chosen players", "Chosen players: " + player1.getName() + ", " + player2.getName() + "", game); + return true; + } } } return false; @@ -135,9 +136,9 @@ class BitterFeudEffect extends ReplacementEffectImpl { return new BitterFeudEffect(this); } - @Override + @Override public boolean checksEventType(GameEvent event, Game game) { - switch(event.getType()) { + switch (event.getType()) { case DAMAGE_CREATURE: case DAMAGE_PLAYER: case DAMAGE_PLANESWALKER: @@ -146,7 +147,7 @@ class BitterFeudEffect extends ReplacementEffectImpl { return false; } } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { player1 = (Player) game.getState().getValue(source.getSourceId() + "_player1"); @@ -178,9 +179,9 @@ class BitterFeudEffect extends ReplacementEffectImpl { } else if (damageSource instanceof Card) { sourcePlayerId = ((Card) damageSource).getOwnerId(); } - if (sourcePlayerId != null && - (player1.getId().equals(sourcePlayerId) || player2.getId().equals(sourcePlayerId)) && - !sourcePlayerId.equals(targetPlayerId)) { + if (sourcePlayerId != null + && (player1.getId().equals(sourcePlayerId) || player2.getId().equals(sourcePlayerId)) + && !sourcePlayerId.equals(targetPlayerId)) { return true; } } diff --git a/Mage.Sets/src/mage/sets/commander2014/DarettiScrapSavant.java b/Mage.Sets/src/mage/sets/commander2014/DarettiScrapSavant.java index 3436c1fb33d..48b846573c7 100644 --- a/Mage.Sets/src/mage/sets/commander2014/DarettiScrapSavant.java +++ b/Mage.Sets/src/mage/sets/commander2014/DarettiScrapSavant.java @@ -75,7 +75,6 @@ public class DarettiScrapSavant extends CardImpl { this.expansionSetCode = "C14"; this.subtype.add("Daretti"); - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(3)), false)); // +2: Discard up to two cards, then draw that many cards. @@ -126,7 +125,7 @@ class DarettiDiscardDrawEffect extends OneShotEffect { TargetDiscard target = new TargetDiscard(0, 2, new FilterCard(), controller.getId()); target.choose(outcome, controller.getId(), source.getSourceId(), game); int count = 0; - for (UUID cardId: target.getTargets()) { + for (UUID cardId : target.getTargets()) { Card card = game.getCard(cardId); if (card != null) { controller.discard(card, source, game); @@ -160,9 +159,9 @@ class DarettiSacrificeEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - Target target = new TargetControlledPermanent(1,1,new FilterControlledArtifactPermanent(), true); - if (target.canChoose(source.getSourceId(), controller.getId(), game) && - controller.chooseTarget(outcome, target, source, game)) { + Target target = new TargetControlledPermanent(1, 1, new FilterControlledArtifactPermanent(), true); + if (target.canChoose(source.getSourceId(), controller.getId(), game) + && controller.chooseTarget(outcome, target, source, game)) { Permanent artifact = game.getPermanent(target.getFirstTarget()); if (artifact != null && artifact.sacrifice(source.getSourceId(), game)) { Card card = game.getCard(getTargetPointer().getFirst(game, source)); @@ -178,7 +177,9 @@ class DarettiSacrificeEffect extends OneShotEffect { } class DarettiScrapSavantEmblem extends Emblem { + // You get an emblem with "Whenever an artifact is put into your graveyard from the battlefield, return that card to the battlefield at the beginning of the next end step." + public DarettiScrapSavantEmblem() { this.setName("Emblem - Daretti"); this.getAbilities().add(new DarettiScrapSavantTriggeredAbility()); @@ -208,10 +209,10 @@ class DarettiScrapSavantTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { ZoneChangeEvent zEvent = (ZoneChangeEvent) event; - if (zEvent.getToZone() == Zone.GRAVEYARD && - zEvent.getFromZone() == Zone.BATTLEFIELD && - zEvent.getTarget().getCardType().contains(CardType.ARTIFACT) && - zEvent.getTarget().getOwnerId().equals(this.controllerId)) { + if (zEvent.getToZone() == Zone.GRAVEYARD + && zEvent.getFromZone() == Zone.BATTLEFIELD + && zEvent.getTarget().getCardType().contains(CardType.ARTIFACT) + && zEvent.getTarget().getOwnerId().equals(this.controllerId)) { for (Effect effect : this.getEffects()) { effect.setTargetPointer(new FixedTarget(zEvent.getTargetId())); } @@ -245,9 +246,9 @@ class DarettiScrapSavantEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Card card = game.getCard(getTargetPointer().getFirst(game, source)); - if (card != null) { + if (card != null && game.getState().getZone(card.getId()).equals(Zone.GRAVEYARD)) { Effect effect = new ReturnFromGraveyardToBattlefieldTargetEffect(); - effect.setTargetPointer(new FixedTarget(card.getId())); + effect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); effect.setText("return that card to the battlefield at the beginning of the next end step"); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(Zone.COMMAND, effect, TargetController.ANY); delayedAbility.setSourceId(source.getSourceId()); @@ -258,4 +259,4 @@ class DarettiScrapSavantEffect extends OneShotEffect { } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/commander2014/DeployToTheFront.java b/Mage.Sets/src/mage/sets/commander2014/DeployToTheFront.java index 8d0206462e5..add6e65efa1 100644 --- a/Mage.Sets/src/mage/sets/commander2014/DeployToTheFront.java +++ b/Mage.Sets/src/mage/sets/commander2014/DeployToTheFront.java @@ -47,9 +47,8 @@ public class DeployToTheFront extends CardImpl { super(ownerId, 6, "Deploy to the Front", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{5}{W}{W}"); this.expansionSetCode = "C14"; - // Put X 1/1 white Soldier creature tokens onto the battlefield, where X is the number of creatures on the battlefield. - Effect effect = new CreateTokenEffect(new SoldierToken("C14"), new PermanentsOnBattlefieldCount(new FilterCreaturePermanent("the number of creatures on the battlefield"))); + Effect effect = new CreateTokenEffect(new SoldierToken(), new PermanentsOnBattlefieldCount(new FilterCreaturePermanent("the number of creatures on the battlefield"))); effect.setText("Put X 1/1 white Soldier creature tokens onto the battlefield, where X is the number of creatures on the battlefield"); this.getSpellAbility().addEffect(effect); } diff --git a/Mage.Sets/src/mage/sets/commander2014/FeldonOfTheThirdPath.java b/Mage.Sets/src/mage/sets/commander2014/FeldonOfTheThirdPath.java index ad667be3a2f..a3c53ae6d78 100644 --- a/Mage.Sets/src/mage/sets/commander2014/FeldonOfTheThirdPath.java +++ b/Mage.Sets/src/mage/sets/commander2014/FeldonOfTheThirdPath.java @@ -46,6 +46,7 @@ import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.game.permanent.token.EmptyToken; import mage.target.common.TargetCardInYourGraveyard; import mage.target.targetpointer.FixedTarget; @@ -113,15 +114,16 @@ class FeldonOfTheThirdPathEffect extends OneShotEffect { } token.addAbility(HasteAbility.getInstance()); token.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); - - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect(); - sacrificeEffect.setText("Sacrifice the token at the beginning of the next end step"); - sacrificeEffect.setTargetPointer(new FixedTarget(token.getLastAddedToken())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + Permanent permanent = game.getPermanent(token.getLastAddedToken()); + if (permanent != null) { + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("Sacrifice the token at the beginning of the next end step", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } return true; } diff --git a/Mage.Sets/src/mage/sets/commander2014/GhoulcallerGisa.java b/Mage.Sets/src/mage/sets/commander2014/GhoulcallerGisa.java index 24e6fb4e5dd..00c32af9c7f 100644 --- a/Mage.Sets/src/mage/sets/commander2014/GhoulcallerGisa.java +++ b/Mage.Sets/src/mage/sets/commander2014/GhoulcallerGisa.java @@ -72,11 +72,11 @@ public class GhoulcallerGisa extends CardImpl { // {B}, {tap}, Sacrifice another creature: Put X 2/2 black Zombie creature tokens onto the battlefield, where X is the sacrificed creature's power. DynamicValue xValue = new SacrificeCostCreaturesPower(); - Token zombie = new ZombieToken("C14"); + Token zombie = new ZombieToken(); zombie.setTokenType(2); Effect effect = new CreateTokenEffect(zombie, xValue); effect.setText("Put X 2/2 black Zombie creature tokens onto the battlefield, where X is the sacrificed creature's power"); - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{B}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{B}")); ability.addCost(new TapSourceCost()); ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(filter))); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/commander2014/GraveSifter.java b/Mage.Sets/src/mage/sets/commander2014/GraveSifter.java index 11a5d889289..e9dd6df2171 100644 --- a/Mage.Sets/src/mage/sets/commander2014/GraveSifter.java +++ b/Mage.Sets/src/mage/sets/commander2014/GraveSifter.java @@ -32,8 +32,8 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.CardsImpl; import mage.cards.repository.CardRepository; import mage.choices.Choice; import mage.choices.ChoiceImpl; @@ -101,22 +101,17 @@ class GraveSifterEffect extends OneShotEffect { typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - for (UUID playerId: controller.getInRange()) { + for (UUID playerId : controller.getInRange()) { Player player = game.getPlayer(playerId); if (player != null) { typeChoice.clearChoice(); if (player.choose(outcome, typeChoice, game)) { game.informPlayers(player.getLogName() + " has chosen: " + typeChoice.getChoice()); - FilterCard filter = new FilterCreatureCard("creature cards with creature type " + typeChoice.getChoice()+ " from your graveyard"); + FilterCard filter = new FilterCreatureCard("creature cards with creature type " + typeChoice.getChoice() + " from your graveyard"); filter.add(new SubtypePredicate(typeChoice.getChoice())); - Target target = new TargetCardInYourGraveyard(0,Integer.MAX_VALUE, filter); + Target target = new TargetCardInYourGraveyard(0, Integer.MAX_VALUE, filter); player.chooseTarget(outcome, target, source, game); - for (UUID cardId: target.getTargets()) { - Card card = game.getCard(cardId); - if (card !=null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } - } + player.moveCards(new CardsImpl(target.getTargets()), null, Zone.HAND, source, game); } } diff --git a/Mage.Sets/src/mage/sets/commander2014/OverseerOfTheDamned.java b/Mage.Sets/src/mage/sets/commander2014/OverseerOfTheDamned.java index d31d1267b93..b4f79d12684 100644 --- a/Mage.Sets/src/mage/sets/commander2014/OverseerOfTheDamned.java +++ b/Mage.Sets/src/mage/sets/commander2014/OverseerOfTheDamned.java @@ -75,7 +75,7 @@ public class OverseerOfTheDamned extends CardImpl { ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); // Whenever a nontoken creature an opponent controls dies, put a 2/2 black Zombie creature token onto the battlefield tapped. - Token zombie = new ZombieToken("C14"); + Token zombie = new ZombieToken(); zombie.setTokenType(2); this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(zombie, 1, true, false), false, filter)); diff --git a/Mage.Sets/src/mage/sets/commander2014/WakeTheDead.java b/Mage.Sets/src/mage/sets/commander2014/WakeTheDead.java index f196efa60cf..fc1c258ea11 100644 --- a/Mage.Sets/src/mage/sets/commander2014/WakeTheDead.java +++ b/Mage.Sets/src/mage/sets/commander2014/WakeTheDead.java @@ -33,7 +33,6 @@ import mage.abilities.DelayedTriggeredAbility; import mage.abilities.SpellAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; -import mage.abilities.dynamicvalue.common.GetXValue; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -64,7 +63,6 @@ public class WakeTheDead extends CardImpl { super(ownerId, 31, "Wake the Dead", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{X}{B}{B}"); this.expansionSetCode = "C14"; - // Cast Wake the Dead only during combat on an opponent's turn. Ability ability = new SimpleStaticAbility(Zone.ALL, new WakeTheDeadEffect()); ability.setRuleAtTheTop(true); @@ -72,7 +70,7 @@ public class WakeTheDead extends CardImpl { // Return X target creature cards from your graveyard to the battlefield. Sacrifice those creatures at the beginning of the next end step. this.getSpellAbility().addEffect(new WakeTheDeadReturnFromGraveyardToBattlefieldTargetEffect()); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,Integer.MAX_VALUE, new FilterCreatureCard("creature cards from your graveyard"))); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, Integer.MAX_VALUE, new FilterCreatureCard("creature cards from your graveyard"))); } @Override @@ -80,7 +78,7 @@ public class WakeTheDead extends CardImpl { if (ability instanceof SpellAbility) { int xValue = ability.getManaCostsToPay().getX(); ability.getTargets().clear(); - ability.addTarget(new TargetCardInYourGraveyard(xValue,xValue, new FilterCreatureCard("creature cards from your graveyard"))); + ability.addTarget(new TargetCardInYourGraveyard(xValue, xValue, new FilterCreatureCard("creature cards from your graveyard"))); } } @@ -159,8 +157,8 @@ class WakeTheDeadReturnFromGraveyardToBattlefieldTargetEffect extends OneShotEff Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { permanent.changeControllerId(source.getControllerId(), game); - Effect effect = new SacrificeTargetEffect("Sacrifice those creatures at the beginning of the next end step"); - effect.setTargetPointer(new FixedTarget(permanent.getId())); + Effect effect = new SacrificeTargetEffect("Sacrifice those creatures at the beginning of the next end step", source.getControllerId()); + effect.setTargetPointer(new FixedTarget(permanent, game)); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(effect); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/conflux/CharnelhoardWurm.java b/Mage.Sets/src/mage/sets/conflux/CharnelhoardWurm.java index 983fccfc748..7356e7d86ab 100644 --- a/Mage.Sets/src/mage/sets/conflux/CharnelhoardWurm.java +++ b/Mage.Sets/src/mage/sets/conflux/CharnelhoardWurm.java @@ -28,14 +28,14 @@ package mage.sets.conflux; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect; import mage.abilities.keyword.TrampleAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetCardInYourGraveyard; /** diff --git a/Mage.Sets/src/mage/sets/conflux/Dreadwing.java b/Mage.Sets/src/mage/sets/conflux/Dreadwing.java index bb6ceb0e65d..245e544e3e5 100644 --- a/Mage.Sets/src/mage/sets/conflux/Dreadwing.java +++ b/Mage.Sets/src/mage/sets/conflux/Dreadwing.java @@ -25,21 +25,21 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.conflux; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.continuous.BoostSourceEffect; import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; /** * @@ -53,9 +53,15 @@ public class Dreadwing extends CardImpl { this.subtype.add("Zombie"); this.power = new MageInt(1); - this.toughness = new MageInt(1); - SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(3, 0, Duration.EndOfTurn), new ManaCostsImpl(("{1}{U}{B}"))); - ability.getEffects().add(new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn)); + this.toughness = new MageInt(1); + + // {1}{U}{R}: Dreadwing gets +3/+0 and gains flying until end of turn. + Effect effect = new BoostSourceEffect(3, 0, Duration.EndOfTurn); + effect.setText("{this} gets +3/+0"); + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl(("{1}{U}{R}"))); + effect = new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and gains flying until end of turn"); + ability.getEffects().add(effect); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/conflux/GrixisSlavedriver.java b/Mage.Sets/src/mage/sets/conflux/GrixisSlavedriver.java index 3710c6ace36..9897aad58c2 100644 --- a/Mage.Sets/src/mage/sets/conflux/GrixisSlavedriver.java +++ b/Mage.Sets/src/mage/sets/conflux/GrixisSlavedriver.java @@ -25,21 +25,19 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.conflux; -import mage.constants.CardType; -import mage.constants.Rarity; +import java.util.UUID; import mage.MageInt; import mage.abilities.common.LeavesBattlefieldTriggeredAbility; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.keyword.UnearthAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.permanent.token.ZombieToken; -import java.util.UUID; - /** * @author Loki */ @@ -53,7 +51,7 @@ public class GrixisSlavedriver extends CardImpl { this.subtype.add("Giant"); this.power = new MageInt(4); this.toughness = new MageInt(4); - this.addAbility(new LeavesBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken("ALA")), false)); + this.addAbility(new LeavesBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken()), false)); this.addAbility(new UnearthAbility(new ManaCostsImpl("{3}{B}"))); } diff --git a/Mage.Sets/src/mage/sets/conflux/MaelstromArchangel.java b/Mage.Sets/src/mage/sets/conflux/MaelstromArchangel.java index 073e0230c0a..e3b790a50e3 100644 --- a/Mage.Sets/src/mage/sets/conflux/MaelstromArchangel.java +++ b/Mage.Sets/src/mage/sets/conflux/MaelstromArchangel.java @@ -104,7 +104,7 @@ class MaelstromArchangelCastEffect extends OneShotEffect { controller.chooseUse(outcome, "Cast a nonland card from your hand without paying its mana cost?", source, game)) { Card cardToCast = null; boolean cancel = false; - while (controller.isInGame() && !cancel) { + while (controller.canRespond() && !cancel) { if (controller.chooseTarget(outcome, target, source, game)) { cardToCast = game.getCard(target.getFirstTarget()); if (cardToCast != null && cardToCast.getSpellAbility().canChooseTarget(game)) { diff --git a/Mage.Sets/src/mage/sets/conflux/MasterTransmuter.java b/Mage.Sets/src/mage/sets/conflux/MasterTransmuter.java index 98fb20c1ff8..fcae2dcac52 100644 --- a/Mage.Sets/src/mage/sets/conflux/MasterTransmuter.java +++ b/Mage.Sets/src/mage/sets/conflux/MasterTransmuter.java @@ -28,25 +28,19 @@ package mage.sets.conflux; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.ReturnToHandTargetPermanentCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterArtifactCard; import mage.filter.common.FilterControlledArtifactPermanent; -import mage.game.Game; -import mage.players.Player; -import mage.target.Target; -import mage.target.common.TargetCardInHand; import mage.target.common.TargetControlledPermanent; /** @@ -65,7 +59,7 @@ public class MasterTransmuter extends CardImpl { this.toughness = new MageInt(2); // {U}, {tap}, Return an artifact you control to its owner's hand: You may put an artifact card from your hand onto the battlefield. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MasterTransmuterEffect(), new ManaCostsImpl("{U}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutPermanentOnBattlefieldEffect(new FilterArtifactCard("an artifact card")), new ManaCostsImpl("{U}")); ability.addCost(new TapSourceCost()); ability.addCost(new ReturnToHandTargetPermanentCost(new TargetControlledPermanent(new FilterControlledArtifactPermanent("an artifact")))); this.addAbility(ability); @@ -81,38 +75,3 @@ public class MasterTransmuter extends CardImpl { return new MasterTransmuter(this); } } - -class MasterTransmuterEffect extends OneShotEffect { - - public MasterTransmuterEffect() { - super(Outcome.Benefit); - this.staticText = "You may put an artifact card from your hand onto the battlefield"; - } - - public MasterTransmuterEffect(final MasterTransmuterEffect effect) { - super(effect); - } - - @Override - public MasterTransmuterEffect copy() { - return new MasterTransmuterEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - Target target = new TargetCardInHand(new FilterArtifactCard("an artifact card from your hand")); - if (target.canChoose(source.getSourceId(), source.getControllerId(), game) - && controller.chooseUse(outcome, "Put an artifact from your hand to battlefield?", source, game) - && controller.chooseTarget(outcome, target, source, game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } - } - } - - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/conflux/MatcaRioters.java b/Mage.Sets/src/mage/sets/conflux/MatcaRioters.java index ea61c61bbb7..c302f8a8a93 100644 --- a/Mage.Sets/src/mage/sets/conflux/MatcaRioters.java +++ b/Mage.Sets/src/mage/sets/conflux/MatcaRioters.java @@ -29,14 +29,15 @@ package mage.sets.conflux; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.dynamicvalue.common.DomainValue; -import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Rarity; import mage.constants.Zone; /** @@ -55,7 +56,9 @@ public class MatcaRioters extends CardImpl { this.toughness = new MageInt(0); // Domain - Matca Rioters's power and toughness are each equal to the number of basic land types among lands you control. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(new DomainValue(), new DomainValue(), Duration.EndOfGame))); + Effect effect = new SetPowerToughnessSourceEffect(new DomainValue(), Duration.EndOfGame); + effect.setText("Domain - {this}'s power and toughness are each equal to the number of basic land types among lands you control."); + this.addAbility(new SimpleStaticAbility(Zone.ALL, effect)); } public MatcaRioters(final MatcaRioters card) { diff --git a/Mage.Sets/src/mage/sets/conflux/SkywardEyeProphets.java b/Mage.Sets/src/mage/sets/conflux/SkywardEyeProphets.java index f5ceb039692..09778edade8 100644 --- a/Mage.Sets/src/mage/sets/conflux/SkywardEyeProphets.java +++ b/Mage.Sets/src/mage/sets/conflux/SkywardEyeProphets.java @@ -28,10 +28,6 @@ package mage.sets.conflux; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.MageObject; import mage.abilities.Ability; @@ -42,6 +38,10 @@ import mage.abilities.keyword.VigilanceAbility; import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.players.Player; @@ -73,7 +73,7 @@ public class SkywardEyeProphets extends CardImpl { public SkywardEyeProphets copy() { return new SkywardEyeProphets(this); } - + public static class SkywardEyeProphetsEffect extends OneShotEffect { public SkywardEyeProphetsEffect() { @@ -108,7 +108,7 @@ public class SkywardEyeProphets extends CardImpl { if (card.getCardType().contains(CardType.LAND)) { return controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); } else { - return controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); } } return true; diff --git a/Mage.Sets/src/mage/sets/conflux/UnstableFrontier.java b/Mage.Sets/src/mage/sets/conflux/UnstableFrontier.java index e48c369876e..46c79c956f9 100644 --- a/Mage.Sets/src/mage/sets/conflux/UnstableFrontier.java +++ b/Mage.Sets/src/mage/sets/conflux/UnstableFrontier.java @@ -38,8 +38,9 @@ import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; import mage.target.Target; -import mage.target.common.TargetLandPermanent; +import mage.target.common.TargetControlledPermanent; /** * @@ -55,7 +56,7 @@ public class UnstableFrontier extends CardImpl { this.addAbility(new ColorlessManaAbility()); // {tap}: Target land you control becomes the basic land type of your choice until end of turn. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost()); - Target target = new TargetLandPermanent(); + Target target = new TargetControlledPermanent(new FilterControlledLandPermanent()); ability.addTarget(target); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/conspiracy/BarbedShocker.java b/Mage.Sets/src/mage/sets/conspiracy/BarbedShocker.java index 0fb985c6562..70612d8ca05 100644 --- a/Mage.Sets/src/mage/sets/conspiracy/BarbedShocker.java +++ b/Mage.Sets/src/mage/sets/conspiracy/BarbedShocker.java @@ -1,106 +1,104 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.conspiracy; - -import java.util.Set; -import java.util.UUID; -import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.common.DealsDamageToAPlayerTriggeredAbility; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.keyword.TrampleAbility; -import mage.abilities.keyword.HasteAbility; -import mage.cards.Card; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.game.Game; -import mage.players.Player; - -/** - * - * @author markedagain - */ -public class BarbedShocker extends CardImpl { - - public BarbedShocker(UUID ownerId) { - super(ownerId, 136, "Barbed Shocker", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); - this.expansionSetCode = "CNS"; - this.subtype.add("Insect"); - this.power = new MageInt(2); - this.toughness = new MageInt(2); - - // Trample - this.addAbility(TrampleAbility.getInstance()); - // Haste - this.addAbility(HasteAbility.getInstance()); - // Whenever Barbed Shocker deals damage to a player, that player discards all the cards in his or her hand, then draws that many cards. - this.addAbility(new DealsDamageToAPlayerTriggeredAbility(new BarbedShockerEffect(), false, true)); - } - - public BarbedShocker(final BarbedShocker card) { - super(card); - } - - @Override - public BarbedShocker copy() { - return new BarbedShocker(this); - } -} -class BarbedShockerEffect extends OneShotEffect { - - public BarbedShockerEffect() { - super(Outcome.Discard); - this.staticText = " that player discards all the cards in his or her hand, then draws that many cards"; - } - - public BarbedShockerEffect(final BarbedShockerEffect effect) { - super(effect); - } - - @Override - public BarbedShockerEffect copy() { - return new BarbedShockerEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player targetPlayer = game.getPlayer(targetPointer.getFirst(game, source)); - if (targetPlayer != null) { - int count = targetPlayer.getHand().size(); - for (Card card : targetPlayer.getHand().getCards(game)) { - targetPlayer.discard(card, source, game); - } - targetPlayer.drawCards(count, game); - return false; - } - return true; - } +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToAPlayerTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.HasteAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author markedagain + */ +public class BarbedShocker extends CardImpl { + + public BarbedShocker(UUID ownerId) { + super(ownerId, 136, "Barbed Shocker", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "CNS"; + this.subtype.add("Insect"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + // Haste + this.addAbility(HasteAbility.getInstance()); + // Whenever Barbed Shocker deals damage to a player, that player discards all the cards in his or her hand, then draws that many cards. + this.addAbility(new DealsDamageToAPlayerTriggeredAbility(new BarbedShockerEffect(), false, true)); + } + + public BarbedShocker(final BarbedShocker card) { + super(card); + } + + @Override + public BarbedShocker copy() { + return new BarbedShocker(this); + } +} +class BarbedShockerEffect extends OneShotEffect { + + public BarbedShockerEffect() { + super(Outcome.Discard); + this.staticText = " that player discards all the cards in his or her hand, then draws that many cards"; + } + + public BarbedShockerEffect(final BarbedShockerEffect effect) { + super(effect); + } + + @Override + public BarbedShockerEffect copy() { + return new BarbedShockerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player targetPlayer = game.getPlayer(targetPointer.getFirst(game, source)); + if (targetPlayer != null) { + int count = targetPlayer.getHand().size(); + for (Card card : targetPlayer.getHand().getCards(game)) { + targetPlayer.discard(card, source, game); + } + targetPlayer.drawCards(count, game); + return false; + } + return true; + } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/BiteOfTheBlackRose.java b/Mage.Sets/src/mage/sets/conspiracy/BiteOfTheBlackRose.java new file mode 100644 index 00000000000..d8f9840867e --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/BiteOfTheBlackRose.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.ContinuousEffect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.BoostOpponentsEffect; +import mage.abilities.effects.common.discard.DiscardEachPlayerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class BiteOfTheBlackRose extends CardImpl { + + public BiteOfTheBlackRose(UUID ownerId) { + super(ownerId, 26, "Bite of the Black Rose", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{B}"); + this.expansionSetCode = "CNS"; + + // Will of the council - Starting with you, each player votes for sickness or psychosis. If sickness gets more votes, creatures your opponents control get -2/-2 until end of turn. If psychosis gets more votes or the vote is tied, each opponent discards two cards. + this.getSpellAbility().addEffect(new BiteOfTheBlackRoseEffect()); + } + + public BiteOfTheBlackRose(final BiteOfTheBlackRose card) { + super(card); + } + + @Override + public BiteOfTheBlackRose copy() { + return new BiteOfTheBlackRose(this); + } +} + +class BiteOfTheBlackRoseEffect extends OneShotEffect { + + BiteOfTheBlackRoseEffect() { + super(Outcome.Benefit); + this.staticText = "Will of the council - Starting with you, each player votes for sickness or psychosis. If sickness gets more votes, creatures your opponents control get -2/-2 until end of turn. If psychosis gets more votes or the vote is tied, each opponent discards two cards"; + } + + BiteOfTheBlackRoseEffect(final BiteOfTheBlackRoseEffect effect) { + super(effect); + } + + @Override + public BiteOfTheBlackRoseEffect copy() { + return new BiteOfTheBlackRoseEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + int sicknessCount = 0; + int psychosisCount = 0; + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { + Player player = game.getPlayer(playerId); + if (player != null) { + if (player.chooseUse(Outcome.ExtraTurn, "Choose sickness?", source, game)) { + sicknessCount++; + game.informPlayers(player.getLogName() + " has chosen: sickness"); + } else { + psychosisCount++; + game.informPlayers(player.getLogName() + " has chosen: psychosis"); + } + } + } + if (sicknessCount > psychosisCount) { + ContinuousEffect effect = new BoostOpponentsEffect(-2, -2, Duration.EndOfTurn); + game.addEffect(effect, source); + } else { + new DiscardEachPlayerEffect(new StaticValue(2), false, TargetController.OPPONENT).apply(game, source); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/ExtractFromDarkness.java b/Mage.Sets/src/mage/sets/conspiracy/ExtractFromDarkness.java new file mode 100644 index 00000000000..9b30e45ef2c --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/ExtractFromDarkness.java @@ -0,0 +1,130 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.game.Game; +import mage.players.Player; +import mage.target.Target; +import mage.target.common.TargetCardInGraveyard; + +/** + * + * @author fireshoes + */ +public class ExtractFromDarkness extends CardImpl { + + public ExtractFromDarkness(UUID ownerId) { + super(ownerId, 45, "Extract from Darkness", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{U}{B}"); + this.expansionSetCode = "CNS"; + + // Each player puts the top two cards of his or her library into his or her graveyard. + this.getSpellAbility().addEffect(new ExtractFromDarknessMillEffect()); + // Then put a creature card from a graveyard onto the battlefield under your control. + this.getSpellAbility().addEffect(new ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect()); + } + + public ExtractFromDarkness(final ExtractFromDarkness card) { + super(card); + } + + @Override + public ExtractFromDarkness copy() { + return new ExtractFromDarkness(this); + } +} + +class ExtractFromDarknessMillEffect extends OneShotEffect { + + ExtractFromDarknessMillEffect() { + super(Outcome.Detriment); + staticText = "Each player puts the top two cards of his or her library into his or her graveyard"; + } + + ExtractFromDarknessMillEffect(final ExtractFromDarknessMillEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + for (UUID playerId : game.getPlayerList()) { + Player player = game.getPlayer(playerId); + if (player != null) { + player.moveCards(player.getLibrary().getTopCards(game, 2), Zone.LIBRARY, Zone.GRAVEYARD, source, game); + } + } + return true; + } + + @Override + public ExtractFromDarknessMillEffect copy() { + return new ExtractFromDarknessMillEffect(this); + } +} + +class ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect extends OneShotEffect { + + public ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect() { + super(Outcome.PutCreatureInPlay); + staticText = "Put a creature card from a graveyard onto the battlefield under your control"; + } + + public ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect(final ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect effect) { + super(effect); + } + + @Override + public ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect copy() { + return new ExtractFromDarknessReturnFromGraveyardToBattlefieldEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + Target target = new TargetCardInGraveyard(new FilterCreatureCard()); + target.setNotTarget(true); + if (target.canChoose(source.getSourceId(), source.getControllerId(), game) + && player.chooseTarget(outcome, target, source, game)) { + Card card = game.getCard(target.getFirstTarget()); + player.putOntoBattlefieldWithInfo(card, game, Zone.GRAVEYARD, source.getSourceId()); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/Flamewright.java b/Mage.Sets/src/mage/sets/conspiracy/Flamewright.java new file mode 100644 index 00000000000..493ff58eafa --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/Flamewright.java @@ -0,0 +1,111 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.AbilityPredicate; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.permanent.token.Token; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class Flamewright extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("creature with defender"); + + static { + filter.add(new CardTypePredicate(CardType.CREATURE)); + filter.add(new AbilityPredicate(DefenderAbility.class)); + } + + public Flamewright(UUID ownerId) { + super(ownerId, 46, "Flamewright", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{R}{W}"); + this.expansionSetCode = "CNS"; + this.subtype.add("Human"); + this.subtype.add("Artificer"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}, {tap}: Put a 1/1 colorless Construct artifact creature token with defender onto the battlefield. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ConstructToken()), new ManaCostsImpl("{1}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + + // {tap}, Sacrifice a creature with defender: Flamewright deals 1 damage to target creature or player. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new TapSourceCost()); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter))); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public Flamewright(final Flamewright card) { + super(card); + } + + @Override + public Flamewright copy() { + return new Flamewright(this); + } +} + +class ConstructToken extends Token { + + public ConstructToken() { + this("CNS"); + } + + public ConstructToken(String setCode) { + super("Construct", "1/1 colorless Construct artifact creature token with defender"); + this.setOriginalExpansionSetCode(setCode); + cardType.add(CardType.ARTIFACT); + cardType.add(CardType.CREATURE); + subtype.add("Construct"); + power = new MageInt(1); + toughness = new MageInt(1); + + addAbility(DefenderAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/Gamekeeper.java b/Mage.Sets/src/mage/sets/conspiracy/Gamekeeper.java new file mode 100644 index 00000000000..92a52b22662 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/Gamekeeper.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Gamekeeper extends mage.sets.urzasdestiny.Gamekeeper { + + public Gamekeeper(UUID ownerId) { + super(ownerId); + this.cardNumber = 165; + this.expansionSetCode = "CNS"; + } + + public Gamekeeper(final Gamekeeper card) { + super(card); + } + + @Override + public Gamekeeper copy() { + return new Gamekeeper(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/HowlingWolf.java b/Mage.Sets/src/mage/sets/conspiracy/HowlingWolf.java new file mode 100644 index 00000000000..dac9d6b1f4c --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/HowlingWolf.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class HowlingWolf extends mage.sets.mercadianmasques.HowlingWolf { + + public HowlingWolf(UUID ownerId) { + super(ownerId); + this.cardNumber = 167; + this.expansionSetCode = "CNS"; + } + + public HowlingWolf(final HowlingWolf card) { + super(card); + } + + @Override + public HowlingWolf copy() { + return new HowlingWolf(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/MagisterOfWorth.java b/Mage.Sets/src/mage/sets/conspiracy/MagisterOfWorth.java new file mode 100644 index 00000000000..c9ede50c8d7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/MagisterOfWorth.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class MagisterOfWorth extends mage.sets.mediainserts.MagisterOfWorth { + + public MagisterOfWorth(UUID ownerId) { + super(ownerId); + this.cardNumber = 48; + this.expansionSetCode = "CNS"; + this.rarity = Rarity.RARE; + } + + public MagisterOfWorth(final MagisterOfWorth card) { + super(card); + } + + @Override + public MagisterOfWorth copy() { + return new MagisterOfWorth(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/MagusOfTheMirror.java b/Mage.Sets/src/mage/sets/conspiracy/MagusOfTheMirror.java new file mode 100644 index 00000000000..b91f0b27660 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/MagusOfTheMirror.java @@ -0,0 +1,127 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class MagusOfTheMirror extends CardImpl { + + public MagusOfTheMirror(UUID ownerId) { + super(ownerId, 117, "Magus of the Mirror", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{B}{B}"); + this.expansionSetCode = "CNS"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(4); + this.toughness = new MageInt(2); + + // {tap}, Sacrifice Magus of the Mirror: Exchange life totals with target opponent. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility( + Zone.BATTLEFIELD, + new MagusOfTheMirrorEffect(), + new TapSourceCost(), + new IsStepCondition(PhaseStep.UPKEEP), + null); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + } + + public MagusOfTheMirror(final MagusOfTheMirror card) { + super(card); + } + + @Override + public MagusOfTheMirror copy() { + return new MagusOfTheMirror(this); + } +} + +class MagusOfTheMirrorEffect extends OneShotEffect { + + public MagusOfTheMirrorEffect() { + super(Outcome.Neutral); + this.staticText = "Exchange life totals with target opponent"; + } + + public MagusOfTheMirrorEffect(final MagusOfTheMirrorEffect effect) { + super(effect); + } + + @Override + public MagusOfTheMirrorEffect copy() { + return new MagusOfTheMirrorEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Player opponent = game.getPlayer(source.getFirstTarget()); + if (controller != null && opponent != null) { + int lifeController = controller.getLife(); + int lifeOpponent = opponent.getLife(); + + if (lifeController == lifeOpponent) + return false; + + if (!controller.isLifeTotalCanChange() || !opponent.isLifeTotalCanChange()) + return false; + + // 20110930 - 118.7, 118.8 + if (lifeController < lifeOpponent && (!controller.isCanGainLife() || !opponent.isCanLoseLife())) + return false; + + if (lifeController > lifeOpponent && (!controller.isCanLoseLife() || !opponent.isCanGainLife())) + return false; + + controller.setLife(lifeOpponent, game); + opponent.setLife(lifeController, game); + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/MuzzioVisionaryArchitect.java b/Mage.Sets/src/mage/sets/conspiracy/MuzzioVisionaryArchitect.java new file mode 100644 index 00000000000..71a562bab0f --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/MuzzioVisionaryArchitect.java @@ -0,0 +1,144 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.List; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterArtifactCard; +import mage.filter.common.FilterArtifactPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetCard; + +/** + * + * @author fireshoes + */ +public class MuzzioVisionaryArchitect extends CardImpl { + + public MuzzioVisionaryArchitect(UUID ownerId) { + super(ownerId, 23, "Muzzio, Visionary Architect", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "CNS"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Artificer"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // {3}{U}, {tap}: Look at the top X cards of your library, where X is the highest converted mana cost among artifacts you control. You may reveal an artifact card from among them and put it onto the battlefield. Put the rest on the bottom of your library in any order. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MuzzioVisionaryArchitectEffect(), new ManaCostsImpl("{3}{U}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + } + + public MuzzioVisionaryArchitect(final MuzzioVisionaryArchitect card) { + super(card); + } + + @Override + public MuzzioVisionaryArchitect copy() { + return new MuzzioVisionaryArchitect(this); + } +} + +class MuzzioVisionaryArchitectEffect extends OneShotEffect { + + public MuzzioVisionaryArchitectEffect() { + super(Outcome.Benefit); + this.staticText = "Look at the top X cards of your library, where X is the highest converted mana cost among artifacts you control. You may reveal an artifact card from among them and put it onto the battlefield. Put the rest on the bottom of your library in any order"; + } + + public MuzzioVisionaryArchitectEffect(final MuzzioVisionaryArchitectEffect effect) { + super(effect); + } + + @Override + public MuzzioVisionaryArchitectEffect copy() { + return new MuzzioVisionaryArchitectEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if (player == null || sourcePermanent == null) { + return false; + } + + int highCMC = 0; + List controlledArtifacts = game.getBattlefield().getAllActivePermanents(new FilterArtifactPermanent(), player.getId(), game); + for (Permanent permanent : controlledArtifacts) { + if (permanent.getSpellAbility() != null) { + int cmc = permanent.getSpellAbility().getManaCosts().convertedManaCost(); + if (cmc > highCMC) { + highCMC = cmc; + } + } + } + + Cards cards = new CardsImpl(); + + for (int i = 0; i < highCMC; i++) { + Card card = player.getLibrary().removeFromTop(game); + if (card != null) { + cards.add(card); + } + } + player.lookAtCards(sourcePermanent.getName(), cards, game); + + if (!cards.isEmpty()) { + TargetCard target = new TargetCard(Zone.LIBRARY, new FilterArtifactCard("artifact card to put onto the battlefield")); + if (target.canChoose(source.getSourceId(), player.getId(), game) && player.choose(Outcome.Benefit, cards, target, game)) { + Card card = cards.get(target.getFirstTarget(), game); + if (card != null) { + player.revealCards(sourcePermanent.getName(), new CardsImpl(card), game); + cards.remove(card); + player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); + } + } + } + + player.putCardsOnBottomOfLibrary(cards, game, source, true); + return true; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/NecromanticThirst.java b/Mage.Sets/src/mage/sets/conspiracy/NecromanticThirst.java new file mode 100644 index 00000000000..da05bf72cd8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/NecromanticThirst.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class NecromanticThirst extends mage.sets.ravnica.NecromanticThirst { + + public NecromanticThirst(UUID ownerId) { + super(ownerId); + this.cardNumber = 119; + this.expansionSetCode = "CNS"; + } + + public NecromanticThirst(final NecromanticThirst card) { + super(card); + } + + @Override + public NecromanticThirst copy() { + return new NecromanticThirst(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/PredatorsHowl.java b/Mage.Sets/src/mage/sets/conspiracy/PredatorsHowl.java new file mode 100644 index 00000000000..294ccde6cd9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/PredatorsHowl.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.condition.common.MorbidCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.permanent.token.WolfToken; + +/** + * + * @author fireshoes + */ +public class PredatorsHowl extends CardImpl { + + public PredatorsHowl(UUID ownerId) { + super(ownerId, 37, "Predator's Howl", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{G}"); + this.expansionSetCode = "CNS"; + + // Put a 2/2 green Wolf creature token onto the battlefield. + // Morbid - Put three 2/2 green Wolf creature tokens onto the battlefield instead if a creature died this turn. + Effect effect = new ConditionalOneShotEffect( + new CreateTokenEffect(new WolfToken(), 3), + new CreateTokenEffect(new WolfToken(), 1), + new MorbidCondition(), + "Put a 2/2 green Wolf creature token onto the battlefield.

Morbid - Put three 2/2 green Wolf creature tokens onto the battlefield instead if a creature died this turn."); + this.getSpellAbility().addEffect(effect); + } + + public PredatorsHowl(final PredatorsHowl card) { + super(card); + } + + @Override + public PredatorsHowl copy() { + return new PredatorsHowl(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/Respite.java b/Mage.Sets/src/mage/sets/conspiracy/Respite.java new file mode 100644 index 00000000000..cf9230da3d6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/Respite.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Respite extends mage.sets.tempest.Respite { + + public Respite(UUID ownerId) { + super(ownerId); + this.cardNumber = 176; + this.expansionSetCode = "CNS"; + } + + public Respite(final Respite card) { + super(card); + } + + @Override + public Respite copy() { + return new Respite(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/SelvalaExplorerReturned.java b/Mage.Sets/src/mage/sets/conspiracy/SelvalaExplorerReturned.java new file mode 100644 index 00000000000..a455dc71609 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/SelvalaExplorerReturned.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class SelvalaExplorerReturned extends mage.sets.vintagemasters.SelvalaExplorerReturned { + + public SelvalaExplorerReturned(UUID ownerId) { + super(ownerId); + this.cardNumber = 51; + this.expansionSetCode = "CNS"; + } + + public SelvalaExplorerReturned(final SelvalaExplorerReturned card) { + super(card); + } + + @Override + public SelvalaExplorerReturned copy() { + return new SelvalaExplorerReturned(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/SplitDecision.java b/Mage.Sets/src/mage/sets/conspiracy/SplitDecision.java new file mode 100644 index 00000000000..09733d97720 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/SplitDecision.java @@ -0,0 +1,119 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CopyTargetSpellEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterSpell; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetSpell; + +/** + * + * @author fireshoes + */ +public class SplitDecision extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("instant or sorcery spell"); + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.INSTANT), + new CardTypePredicate(CardType.SORCERY))); + } + + public SplitDecision(UUID ownerId) { + super(ownerId, 25, "Split Decision", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "CNS"; + + // Will of the council - Choose target instant or sorcery spell. Starting with you, each player votes for denial or duplication. If denial gets more votes, counter the spell. If duplication gets more votes or the vote is tied, copy the spell. You may choose new targets for the copy. + this.getSpellAbility().addEffect(new SplitDecisionEffect()); + this.getSpellAbility().addTarget(new TargetSpell(filter)); + } + + public SplitDecision(final SplitDecision card) { + super(card); + } + + @Override + public SplitDecision copy() { + return new SplitDecision(this); + } +} + +class SplitDecisionEffect extends OneShotEffect { + + SplitDecisionEffect() { + super(Outcome.Benefit); + this.staticText = "Will of the council - Choose target instant or sorcery spell. Starting with you, each player votes for denial or duplication. If denial gets more votes, counter the spell. If duplication gets more votes or the vote is tied, copy the spell. You may choose new targets for the copy"; + } + + SplitDecisionEffect(final SplitDecisionEffect effect) { + super(effect); + } + + @Override + public SplitDecisionEffect copy() { + return new SplitDecisionEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + int denialCount = 0; + int duplicationCount = 0; + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { + Player player = game.getPlayer(playerId); + if (player != null) { + if (player.chooseUse(Outcome.ExtraTurn, "Choose denial?", source, game)) { + denialCount++; + game.informPlayers(player.getLogName() + " has chosen: denial"); + } else { + duplicationCount++; + game.informPlayers(player.getLogName() + " has chosen: duplication"); + } + } + } + if (denialCount > duplicationCount) { + return game.getStack().counter(getTargetPointer().getFirst(game, source), source.getSourceId(), game); + } else { + return new CopyTargetSpellEffect().apply(game, source); + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/StasisCell.java b/Mage.Sets/src/mage/sets/conspiracy/StasisCell.java new file mode 100644 index 00000000000..dd59b89b4e6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/StasisCell.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class StasisCell extends mage.sets.ravnica.StasisCell { + + public StasisCell(UUID ownerId) { + super(ownerId); + this.cardNumber = 107; + this.expansionSetCode = "CNS"; + } + + public StasisCell(final StasisCell card) { + super(card); + } + + @Override + public StasisCell copy() { + return new StasisCell(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/StrongholdDiscipline.java b/Mage.Sets/src/mage/sets/conspiracy/StrongholdDiscipline.java new file mode 100644 index 00000000000..f6d258cf6e9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/StrongholdDiscipline.java @@ -0,0 +1,98 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class StrongholdDiscipline extends CardImpl { + + public StrongholdDiscipline(UUID ownerId) { + super(ownerId, 126, "Stronghold Discipline", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{B}{B}"); + this.expansionSetCode = "CNS"; + + // Each player loses 1 life for each creature he or she controls. + this.getSpellAbility().addEffect(new StrongholdDisciplineEffect()); + } + + public StrongholdDiscipline(final StrongholdDiscipline card) { + super(card); + } + + @Override + public StrongholdDiscipline copy() { + return new StrongholdDiscipline(this); + } +} + +class StrongholdDisciplineEffect extends OneShotEffect { + + StrongholdDisciplineEffect() { + super(Outcome.Sacrifice); + this.staticText = "Each player loses 1 life for each creature he or she controls"; + } + + StrongholdDisciplineEffect(final StrongholdDisciplineEffect effect) { + super(effect); + } + + @Override + public StrongholdDisciplineEffect copy() { + return new StrongholdDisciplineEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + for (UUID playerId : controller.getInRange()) { + final int count = game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), playerId, game).size(); + if (count > 0) { + Player player = game.getPlayer(playerId); + if (player != null) { + player.loseLife(count, game); + } + } + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/conspiracy/ValorMadeReal.java b/Mage.Sets/src/mage/sets/conspiracy/ValorMadeReal.java new file mode 100644 index 00000000000..4a957e9ea8a --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/ValorMadeReal.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CanBlockAdditionalCreatureEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class ValorMadeReal extends CardImpl { + + public ValorMadeReal(UUID ownerId) { + super(ownerId, 86, "Valor Made Real", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "CNS"; + + // Target creature can block any number of creatures this turn. + Ability gainedAbility = new SimpleStaticAbility(Zone.BATTLEFIELD, new CanBlockAdditionalCreatureEffect(0)); + this.getSpellAbility().addEffect(new GainAbilityTargetEffect(gainedAbility, Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public ValorMadeReal(final ValorMadeReal card) { + super(card); + } + + @Override + public ValorMadeReal copy() { + return new ValorMadeReal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/conspiracy/WrapInVigor.java b/Mage.Sets/src/mage/sets/conspiracy/WrapInVigor.java new file mode 100644 index 00000000000..01c709cb5ae --- /dev/null +++ b/Mage.Sets/src/mage/sets/conspiracy/WrapInVigor.java @@ -0,0 +1,59 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.conspiracy; + +import java.util.UUID; +import mage.abilities.effects.common.RegenerateAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class WrapInVigor extends CardImpl { + + public WrapInVigor(UUID ownerId) { + super(ownerId, 183, "Wrap in Vigor", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "CNS"; + + // Regenerate each creature you control. + this.getSpellAbility().addEffect(new RegenerateAllEffect(new FilterControlledCreaturePermanent())); + } + + public WrapInVigor(final WrapInVigor card) { + super(card); + } + + @Override + public WrapInVigor copy() { + return new WrapInVigor(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darkascension/CallToTheKindred.java b/Mage.Sets/src/mage/sets/darkascension/CallToTheKindred.java index 7d0fcaf0d4d..0e3912d65a8 100644 --- a/Mage.Sets/src/mage/sets/darkascension/CallToTheKindred.java +++ b/Mage.Sets/src/mage/sets/darkascension/CallToTheKindred.java @@ -154,7 +154,7 @@ class CallToTheKindredEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/darkascension/FaithsShield.java b/Mage.Sets/src/mage/sets/darkascension/FaithsShield.java index 8132dccf512..6c1971add28 100644 --- a/Mage.Sets/src/mage/sets/darkascension/FaithsShield.java +++ b/Mage.Sets/src/mage/sets/darkascension/FaithsShield.java @@ -95,7 +95,7 @@ class FaithsShieldEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(Outcome.Protect, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/darkascension/HavengulRunebinder.java b/Mage.Sets/src/mage/sets/darkascension/HavengulRunebinder.java index 44261789760..b4f746332cf 100644 --- a/Mage.Sets/src/mage/sets/darkascension/HavengulRunebinder.java +++ b/Mage.Sets/src/mage/sets/darkascension/HavengulRunebinder.java @@ -28,9 +28,6 @@ package mage.sets.darkascension; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.ExileFromGraveCost; @@ -39,6 +36,9 @@ import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.effects.common.counter.AddCountersAllEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.common.FilterControlledCreaturePermanent; import mage.filter.common.FilterCreatureCard; @@ -71,7 +71,7 @@ public class HavengulRunebinder extends CardImpl { // {2}{U}, {tap}, Exile a creature card from your graveyard: Put a 2/2 black Zombie creature token onto the battlefield, // then put a +1/+1 counter on each Zombie creature you control. SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, - new CreateTokenEffect(new ZombieToken("ISD")), + new CreateTokenEffect(new ZombieToken()), new ManaCostsImpl("{2}{U}")); ability.addCost(new TapSourceCost()); ability.addCost(new ExileFromGraveCost(new TargetCardInYourGraveyard(filter))); diff --git a/Mage.Sets/src/mage/sets/darkascension/ReapTheSeagraf.java b/Mage.Sets/src/mage/sets/darkascension/ReapTheSeagraf.java index cd1d8070e61..7623e13224a 100644 --- a/Mage.Sets/src/mage/sets/darkascension/ReapTheSeagraf.java +++ b/Mage.Sets/src/mage/sets/darkascension/ReapTheSeagraf.java @@ -19,8 +19,7 @@ public class ReapTheSeagraf extends CardImpl { super(ownerId, 72, "Reap the Seagraf", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{B}"); this.expansionSetCode = "DKA"; - - this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken("ISD"))); + this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken())); this.addAbility(new FlashbackAbility(new ManaCostsImpl("{4}{U}"), TimingRule.SORCERY)); } diff --git a/Mage.Sets/src/mage/sets/darkascension/SpitefulShadows.java b/Mage.Sets/src/mage/sets/darkascension/SpitefulShadows.java index a874f847366..942dc372f51 100644 --- a/Mage.Sets/src/mage/sets/darkascension/SpitefulShadows.java +++ b/Mage.Sets/src/mage/sets/darkascension/SpitefulShadows.java @@ -29,7 +29,7 @@ package mage.sets.darkascension; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.DamageDealtToAttachedTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.AttachEffect; import mage.abilities.keyword.EnchantAbility; @@ -37,10 +37,9 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; +import mage.constants.SetTargetPointer; import mage.constants.Zone; import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.TargetPermanent; @@ -65,7 +64,8 @@ public class SpitefulShadows extends CardImpl { this.addAbility(new EnchantAbility(auraTarget.getTargetName())); // Whenever enchanted creature is dealt damage, it deals that much damage to its controller. - this.addAbility(new SpitefulShadowsTriggeredAbility()); + this.addAbility(new DamageDealtToAttachedTriggeredAbility(Zone.BATTLEFIELD, new SpitefulShadowsEffect(), + false, SetTargetPointer.PERMANENT)); } public SpitefulShadows(final SpitefulShadows card) { @@ -78,44 +78,6 @@ public class SpitefulShadows extends CardImpl { } } -class SpitefulShadowsTriggeredAbility extends TriggeredAbilityImpl { - - public SpitefulShadowsTriggeredAbility() { - super(Zone.BATTLEFIELD, new SpitefulShadowsEffect()); - } - - public SpitefulShadowsTriggeredAbility(final SpitefulShadowsTriggeredAbility ability) { - super(ability); - } - - @Override - public SpitefulShadowsTriggeredAbility copy() { - return new SpitefulShadowsTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.DAMAGED_CREATURE; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - Permanent enchantment = game.getPermanent(sourceId); - UUID targetId = event.getTargetId(); - if (enchantment != null && enchantment.getAttachedTo() != null && targetId.equals(enchantment.getAttachedTo())) { - this.getEffects().get(0).setValue("damageAmount", event.getAmount()); - this.getEffects().get(0).setTargetPointer(new FixedTarget(targetId)); - return true; - } - return false; - } - - @Override - public String getRule() { - return "Whenever enchanted creature is dealt damage, it deals that much damage to its controller."; - } -} - class SpitefulShadowsEffect extends OneShotEffect { public SpitefulShadowsEffect() { @@ -134,7 +96,7 @@ class SpitefulShadowsEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Integer damageAmount = (Integer) this.getValue("damageAmount"); + Integer damageAmount = (Integer) this.getValue("damage"); if (damageAmount != null) { Permanent permanent = game.getPermanent(getTargetPointer().getFirst(game, source)); if (permanent == null) { diff --git a/Mage.Sets/src/mage/sets/darkascension/Wakedancer.java b/Mage.Sets/src/mage/sets/darkascension/Wakedancer.java index 2055a9ae024..1324ea54bd7 100644 --- a/Mage.Sets/src/mage/sets/darkascension/Wakedancer.java +++ b/Mage.Sets/src/mage/sets/darkascension/Wakedancer.java @@ -44,6 +44,7 @@ import mage.game.permanent.token.ZombieToken; * @author Loki */ public class Wakedancer extends CardImpl { + private static final String staticText = "Morbid - When {this} enters the battlefield, if a creature died this turn, put a 2/2 black Zombie creature token onto the battlefield."; public Wakedancer(UUID ownerId) { @@ -57,7 +58,7 @@ public class Wakedancer extends CardImpl { this.toughness = new MageInt(2); // Morbid - When Wakedancer enters the battlefield, if a creature died this turn, put a 2/2 black Zombie creature token onto the battlefield. - TriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken("ISD"))); + TriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken())); this.addAbility(new ConditionalTriggeredAbility(ability, MorbidCondition.getInstance(), staticText)); } diff --git a/Mage.Sets/src/mage/sets/darksteel/BarbedLightning.java b/Mage.Sets/src/mage/sets/darksteel/BarbedLightning.java new file mode 100644 index 00000000000..0bd4af01e2b --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/BarbedLightning.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class BarbedLightning extends CardImpl { + + public BarbedLightning(UUID ownerId) { + super(ownerId, 55, "Barbed Lightning", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); + this.expansionSetCode = "DST"; + + // Choose one - Barbed Lightning deals 3 damage to target creature; + this.getSpellAbility().addEffect(new DamageTargetEffect(3)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + + // or Barbed Lightning deals 3 damage to target player. + Mode mode = new Mode(); + mode.getEffects().add(new DamageTargetEffect(3)); + mode.getTargets().add(new TargetPlayer()); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {2} + this.addAbility(new EntwineAbility("{2}")); + } + + public BarbedLightning(final BarbedLightning card) { + super(card); + } + + @Override + public BarbedLightning copy() { + return new BarbedLightning(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/ChromescaleDrake.java b/Mage.Sets/src/mage/sets/darksteel/ChromescaleDrake.java new file mode 100644 index 00000000000..9f06247482a --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/ChromescaleDrake.java @@ -0,0 +1,122 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.AffinityForArtifactsAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class ChromescaleDrake extends CardImpl { + + public ChromescaleDrake(UUID ownerId) { + super(ownerId, 20, "Chromescale Drake", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{6}{U}{U}{U}"); + this.expansionSetCode = "DST"; + this.subtype.add("Drake"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Affinity for artifacts + this.addAbility(new AffinityForArtifactsAbility()); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When Chromescale Drake enters the battlefield, reveal the top three cards of your library. Put all artifact cards revealed this way into your hand and the rest into your graveyard. + this.addAbility(new EntersBattlefieldTriggeredAbility(new ChromescaleDrakeEffect())); + } + + public ChromescaleDrake(final ChromescaleDrake card) { + super(card); + } + + @Override + public ChromescaleDrake copy() { + return new ChromescaleDrake(this); + } +} + +class ChromescaleDrakeEffect extends OneShotEffect { + + public ChromescaleDrakeEffect() { + super(Outcome.Benefit); + staticText = "Reveal the top three cards of your library. Put all artifacts cards revealed this way into your hand and the rest into your graveyard"; + } + + public ChromescaleDrakeEffect(final ChromescaleDrakeEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { + return false; + } + + Cards cards = new CardsImpl(); + Cards cardsToHand = new CardsImpl(); + cards.addAll(controller.getLibrary().getTopCards(game, 3)); + if (!cards.isEmpty()) { + controller.revealCards(sourceObject.getName(), cards, game); + for (Card card: cards.getCards(game)) { + if (card.getCardType().contains(CardType.ARTIFACT)) { + cardsToHand.add(card); + cards.remove(card); + } + } + controller.moveCards(cardsToHand, Zone.LIBRARY, Zone.HAND, source, game); + controller.moveCards(cards, Zone.LIBRARY, Zone.GRAVEYARD, source, game); + } + return true; + } + + @Override + public ChromescaleDrakeEffect copy() { + return new ChromescaleDrakeEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/DarksteelPendant.java b/Mage.Sets/src/mage/sets/darksteel/DarksteelPendant.java index c6bb0a5889c..f3e93931423 100644 --- a/Mage.Sets/src/mage/sets/darksteel/DarksteelPendant.java +++ b/Mage.Sets/src/mage/sets/darksteel/DarksteelPendant.java @@ -32,7 +32,7 @@ import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.GenericManaCost; -import mage.abilities.effects.common.LookLibraryMayPutToBottomEffect; +import mage.abilities.effects.keyword.ScryEffect; import mage.abilities.keyword.IndestructibleAbility; import mage.cards.CardImpl; import mage.constants.CardType; @@ -51,8 +51,8 @@ public class DarksteelPendant extends CardImpl { // Darksteel Pendant is indestructible. this.addAbility(IndestructibleAbility.getInstance()); - // {1}, {tap}: Look at the top card of your library. You may put that card on the bottom of your library. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LookLibraryMayPutToBottomEffect(), new GenericManaCost(1)); + // {1}, {tap}: Scry 1. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ScryEffect(1), new GenericManaCost(1)); ability.addCost(new TapSourceCost()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/darksteel/EaterOfDays.java b/Mage.Sets/src/mage/sets/darksteel/EaterOfDays.java new file mode 100644 index 00000000000..9463deac87e --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/EaterOfDays.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.turn.SkipNextTurnSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LevelX2 + */ +public class EaterOfDays extends CardImpl { + + public EaterOfDays(UUID ownerId) { + super(ownerId, 120, "Eater of Days", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{4}"); + this.expansionSetCode = "DST"; + this.subtype.add("Leviathan"); + this.power = new MageInt(9); + this.toughness = new MageInt(8); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Trample + this.addAbility(TrampleAbility.getInstance()); + // When Eater of Days enters the battlefield, you skip your next two turns. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SkipNextTurnSourceEffect(2))); + } + + public EaterOfDays(final EaterOfDays card) { + super(card); + } + + @Override + public EaterOfDays copy() { + return new EaterOfDays(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/FurnaceDragon.java b/Mage.Sets/src/mage/sets/darksteel/FurnaceDragon.java new file mode 100644 index 00000000000..8c7f749d57b --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/FurnaceDragon.java @@ -0,0 +1,107 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.Condition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.ExileAllEffect; +import mage.abilities.keyword.AffinityForArtifactsAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.watchers.Watcher; +import mage.watchers.common.CastFromHandWatcher; + +/** + * + * @author fireshoes + */ +public class FurnaceDragon extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifacts"); + + static { + filter.add(new CardTypePredicate(CardType.ARTIFACT)); + } + + public FurnaceDragon(UUID ownerId) { + super(ownerId, 62, "Furnace Dragon", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{6}{R}{R}{R}"); + this.expansionSetCode = "DST"; + this.subtype.add("Dragon"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Affinity for artifacts + this.addAbility(new AffinityForArtifactsAbility()); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When Furnace Dragon enters the battlefield, if you cast it from your hand, exile all artifacts. + this.addAbility(new EntersBattlefieldTriggeredAbility(new ConditionalOneShotEffect(new ExileAllEffect(filter), new FurnaceDragonCondition()), false), new CastFromHandWatcher()); + } + + public FurnaceDragon(final FurnaceDragon card) { + super(card); + } + + @Override + public FurnaceDragon copy() { + return new FurnaceDragon(this); + } +} + +class FurnaceDragonCondition implements Condition { + + @Override + public boolean apply(Game game, Ability source) { + boolean applies = false; + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + Watcher watcher = game.getState().getWatchers().get("CastFromHand", source.getSourceId()); + if (watcher != null && watcher.conditionMet()) { + applies = true; + } + } + return applies; + } + + @Override + public String toString() { + return "you cast it from your hand"; + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/PulseOfTheFields.java b/Mage.Sets/src/mage/sets/darksteel/PulseOfTheFields.java index 49191523e34..a6ee275f3b7 100644 --- a/Mage.Sets/src/mage/sets/darksteel/PulseOfTheFields.java +++ b/Mage.Sets/src/mage/sets/darksteel/PulseOfTheFields.java @@ -66,21 +66,21 @@ public class PulseOfTheFields extends CardImpl { } class PulseOfTheFieldsReturnToHandEffect extends OneShotEffect { - + PulseOfTheFieldsReturnToHandEffect() { super(Outcome.Benefit); this.staticText = "Then if an opponent has more life than you, return {this} to its owner's hand"; } - + PulseOfTheFieldsReturnToHandEffect(final PulseOfTheFieldsReturnToHandEffect effect) { super(effect); } - + @Override public PulseOfTheFieldsReturnToHandEffect copy() { return new PulseOfTheFieldsReturnToHandEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -89,7 +89,7 @@ class PulseOfTheFieldsReturnToHandEffect extends OneShotEffect { Player player = game.getPlayer(playerId); if (player != null && player.getLife() > controller.getLife()) { Card card = game.getCard(source.getSourceId()); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.STACK); + controller.moveCards(card, null, Zone.HAND, source, game); return true; } } diff --git a/Mage.Sets/src/mage/sets/darksteel/PulseOfTheGrid.java b/Mage.Sets/src/mage/sets/darksteel/PulseOfTheGrid.java index 74a9349270e..1e8179a260f 100644 --- a/Mage.Sets/src/mage/sets/darksteel/PulseOfTheGrid.java +++ b/Mage.Sets/src/mage/sets/darksteel/PulseOfTheGrid.java @@ -66,21 +66,21 @@ public class PulseOfTheGrid extends CardImpl { } class PulseOfTheGridReturnToHandEffect extends OneShotEffect { - + PulseOfTheGridReturnToHandEffect() { super(Outcome.Benefit); this.staticText = "Draw two cards, then discard a card. Then if an opponent has more cards in hand than you, return {this} to its owner's hand"; } - + PulseOfTheGridReturnToHandEffect(final PulseOfTheGridReturnToHandEffect effect) { super(effect); } - + @Override public PulseOfTheGridReturnToHandEffect copy() { return new PulseOfTheGridReturnToHandEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -89,7 +89,7 @@ class PulseOfTheGridReturnToHandEffect extends OneShotEffect { Player player = game.getPlayer(playerId); if (player != null && player.getHand().size() > controller.getHand().size()) { Card card = game.getCard(source.getSourceId()); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.STACK); + controller.moveCards(card, null, Zone.HAND, source, game); return true; } } diff --git a/Mage.Sets/src/mage/sets/darksteel/RitualOfRestoration.java b/Mage.Sets/src/mage/sets/darksteel/RitualOfRestoration.java new file mode 100644 index 00000000000..22da651aa12 --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/RitualOfRestoration.java @@ -0,0 +1,61 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterArtifactCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class RitualOfRestoration extends CardImpl { + + public RitualOfRestoration(UUID ownerId) { + super(ownerId, 13, "Ritual of Restoration", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{W}"); + this.expansionSetCode = "DST"; + + // Return target artifact card from your graveyard to your hand. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(new FilterArtifactCard("artifact card from your graveyard"))); + } + + public RitualOfRestoration(final RitualOfRestoration card) { + super(card); + } + + @Override + public RitualOfRestoration copy() { + return new RitualOfRestoration(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/StandTogether.java b/Mage.Sets/src/mage/sets/darksteel/StandTogether.java new file mode 100644 index 00000000000..6295029d68a --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/StandTogether.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.counters.CounterType; +import mage.target.Target; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class StandTogether extends CardImpl { + + public StandTogether(UUID ownerId) { + super(ownerId, 84, "Stand Together", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{G}{G}"); + this.expansionSetCode = "DST"; + + // Put two +1/+1 counters on target creature and two +1/+1 counters on another target creature. + Effect effect = new AddCountersTargetEffect(CounterType.P1P1.createInstance(2)); + effect.setText("Put two +1/+1 counters on target creature and two +1/+1 counters on another target creature"); + this.getSpellAbility().addEffect(effect); + Target target = new TargetCreaturePermanent(2,2); + this.getSpellAbility().addTarget(target); + } + + public StandTogether(final StandTogether card) { + super(card); + } + + @Override + public StandTogether copy() { + return new StandTogether(this); + } +} diff --git a/Mage.Sets/src/mage/sets/darksteel/SwordOfLightAndShadow.java b/Mage.Sets/src/mage/sets/darksteel/SwordOfLightAndShadow.java index b090e5ffd8b..7efdd4e8fe6 100644 --- a/Mage.Sets/src/mage/sets/darksteel/SwordOfLightAndShadow.java +++ b/Mage.Sets/src/mage/sets/darksteel/SwordOfLightAndShadow.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.darksteel; import java.util.UUID; @@ -105,7 +104,7 @@ public class SwordOfLightAndShadow extends CardImpl { // Target may only be added if possible target exists. Else the gain life effect won't trigger, becuase there is no valid target for the // return to hand ability if (controller.getGraveyard().count(new FilterCreatureCard(), ability.getSourceId(), ability.getControllerId(), game) > 0) { - ability.addTarget(new TargetCardInYourGraveyard(0,1,new FilterCreatureCard("creature card from your graveyard"))); + ability.addTarget(new TargetCardInYourGraveyard(0, 1, new FilterCreatureCard("creature card from your graveyard"))); } } } @@ -118,7 +117,7 @@ class SwordOfLightAndShadowAbility extends TriggeredAbilityImpl { public SwordOfLightAndShadowAbility() { super(Zone.BATTLEFIELD, new SwordOfLightAndShadowReturnToHandTargetEffect(), false); this.addEffect(new GainLifeEffect(3)); - + } public SwordOfLightAndShadowAbility(final SwordOfLightAndShadowAbility ability) { @@ -178,8 +177,8 @@ class SwordOfLightAndShadowReturnToHandTargetEffect extends OneShotEffect { case GRAVEYARD: Card card = game.getCard(targetId); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } else { + controller.moveCards(card, null, Zone.HAND, source, game); + } else { result = false; } break; diff --git a/Mage.Sets/src/mage/sets/darksteel/VulshokWarBoar.java b/Mage.Sets/src/mage/sets/darksteel/VulshokWarBoar.java new file mode 100644 index 00000000000..60fe264ccea --- /dev/null +++ b/Mage.Sets/src/mage/sets/darksteel/VulshokWarBoar.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.darksteel; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledArtifactPermanent; +import mage.filter.common.FilterControlledPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class VulshokWarBoar extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledArtifactPermanent("an artifact"); + + public VulshokWarBoar(UUID ownerId) { + super(ownerId, 72, "Vulshok War Boar", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{R}{R}"); + this.expansionSetCode = "DST"; + this.subtype.add("Boar"); + this.subtype.add("Beast"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // When Vulshok War Boar enters the battlefield, sacrifice it unless you sacrifice an artifact. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(filter))))); + } + + public VulshokWarBoar(final VulshokWarBoar card) { + super(card); + } + + @Override + public VulshokWarBoar copy() { + return new VulshokWarBoar(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dissension/HaazdaShieldMate.java b/Mage.Sets/src/mage/sets/dissension/HaazdaShieldMate.java new file mode 100644 index 00000000000..54c0f540246 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dissension/HaazdaShieldMate.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.dissension; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventNextDamageFromChosenSourceToYouEffect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author anonymous + */ +public class HaazdaShieldMate extends CardImpl { + + public HaazdaShieldMate(UUID ownerId) { + super(ownerId, 12, "Haazda Shield Mate", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "DIS"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // At the beginning of your upkeep, sacrifice Haazda Shield Mate unless you pay {W}{W}. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new ManaCostsImpl("{W}{W}")), TargetController.YOU, false)); + + // {W}: The next time a source of your choice would deal damage to you this turn, prevent that damage. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventNextDamageFromChosenSourceToYouEffect(Duration.EndOfTurn), new ManaCostsImpl("{W}"))); + } + + public HaazdaShieldMate(final HaazdaShieldMate card) { + super(card); + } + + @Override + public HaazdaShieldMate copy() { + return new HaazdaShieldMate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dissension/NovijenSages.java b/Mage.Sets/src/mage/sets/dissension/NovijenSages.java index 67fb5ceb705..3b0c226850b 100644 --- a/Mage.Sets/src/mage/sets/dissension/NovijenSages.java +++ b/Mage.Sets/src/mage/sets/dissension/NovijenSages.java @@ -49,12 +49,12 @@ import mage.target.TargetPermanent; * @author JotaPeRL */ public class NovijenSages extends CardImpl { - + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("creatures you control with a +1/+1 counter on it"); static { filter.add(new CounterPredicate(CounterType.P1P1)); - } + } public NovijenSages(UUID ownerId) { super(ownerId, 27, "Novijen Sages", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{U}{U}"); @@ -67,10 +67,10 @@ public class NovijenSages extends CardImpl { // Graft 4 this.addAbility(new GraftAbility(this, 4)); - + // {1}, Remove two +1/+1 counters from among creatures you control: Draw a card. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new GenericManaCost(1)); - ability.addCost(new RemoveCounterCost(new TargetPermanent(1, Integer.MAX_VALUE, filter, true), CounterType.P1P1, 2)); + ability.addCost(new RemoveCounterCost(new TargetPermanent(1, 2, filter, true), CounterType.P1P1, 2)); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/dissension/OcularHalo.java b/Mage.Sets/src/mage/sets/dissension/OcularHalo.java new file mode 100644 index 00000000000..9c479298177 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dissension/OcularHalo.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.dissension; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class OcularHalo extends CardImpl { + + public OcularHalo(UUID ownerId) { + super(ownerId, 28, "Ocular Halo", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}"); + this.expansionSetCode = "DIS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature has "{tap}: Draw a card." + Ability gainAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new TapSourceCost()); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(gainAbility, AttachmentType.AURA))); + + // {W}: Enchanted creature gains vigilance until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(VigilanceAbility.getInstance(), + AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl("{W}"))); + } + + public OcularHalo(final OcularHalo card) { + super(card); + } + + @Override + public OcularHalo copy() { + return new OcularHalo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dissension/PalliationAccord.java b/Mage.Sets/src/mage/sets/dissension/PalliationAccord.java new file mode 100644 index 00000000000..0d98ccb2056 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dissension/PalliationAccord.java @@ -0,0 +1,154 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.dissension; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.effects.PreventionEffectImpl; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.permanent.Permanent; + +/** + * + * @author fireshoes + */ +public class PalliationAccord extends CardImpl { + + public PalliationAccord(UUID ownerId) { + super(ownerId, 122, "Palliation Accord", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}{U}"); + this.expansionSetCode = "DIS"; + + // Whenever a creature an opponent controls becomes tapped, put a shield counter on Palliation Accord. + this.addAbility(new PallationAccordTriggeredAbility()); + + // Remove a shield counter from Palliation Accord: Prevent the next 1 damage that would be dealt to you this turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PalliationAccordPreventionEffect(), new RemoveCountersSourceCost(CounterType.SHIELD.createInstance()))); + } + + public PalliationAccord(final PalliationAccord card) { + super(card); + } + + @Override + public PalliationAccord copy() { + return new PalliationAccord(this); + } +} + +class PallationAccordTriggeredAbility extends TriggeredAbilityImpl { + PallationAccordTriggeredAbility() { + super(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.SHIELD.createInstance())); + } + + PallationAccordTriggeredAbility(final PallationAccordTriggeredAbility ability) { + super(ability); + } + + @Override + public PallationAccordTriggeredAbility copy() { + return new PallationAccordTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.TAPPED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Permanent p = game.getPermanent(event.getTargetId()); + if (p != null && p.getCardType().contains(CardType.CREATURE)) { + if (game.getOpponents(this.controllerId).contains(p.getControllerId())) + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever a creature an opponent controls becomes tapped, " + modes.getText(); + } +} + +class PalliationAccordPreventionEffect extends PreventionEffectImpl { + + public PalliationAccordPreventionEffect() { + super(Duration.EndOfTurn); + this.staticText = "Prevent the next 1 damage that would be dealt to you this turn"; + } + + public PalliationAccordPreventionEffect(final PalliationAccordPreventionEffect effect) { + super(effect); + } + + @Override + public PalliationAccordPreventionEffect copy() { + return new PalliationAccordPreventionEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + GameEvent preventEvent = new GameEvent(GameEvent.EventType.PREVENT_DAMAGE, + source.getControllerId(), source.getSourceId(), source.getControllerId(), event.getAmount(), false); + if (!game.replaceEvent(preventEvent)) { + int damage = event.getAmount(); + if (damage > 0) { + event.setAmount(damage - 1); + this.used = true; + game.fireEvent(GameEvent.getEvent(GameEvent.EventType.PREVENTED_DAMAGE, + source.getControllerId(), source.getSourceId(), source.getControllerId(), 1)); + } + } + return false; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (!this.used && super.applies(event, source, game) && event.getTargetId().equals(source.getControllerId())) { + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/dissension/Plaxmanta.java b/Mage.Sets/src/mage/sets/dissension/Plaxmanta.java new file mode 100644 index 00000000000..55eff8520ba --- /dev/null +++ b/Mage.Sets/src/mage/sets/dissension/Plaxmanta.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.dissension; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.common.ManaWasSpentCondition; +import mage.abilities.effects.common.SacrificeSourceUnlessConditionEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.FlashAbility; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.watchers.common.ManaSpentToCastWatcher; + +/** + * + * @author fireshoes + */ +public class Plaxmanta extends CardImpl { + + public Plaxmanta(UUID ownerId) { + super(ownerId, 29, "Plaxmanta", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "DIS"; + this.subtype.add("Beast"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // When Plaxmanta enters the battlefield, creatures you control gain shroud until end of turn. + this.addAbility(new EntersBattlefieldTriggeredAbility( + new GainAbilityControlledEffect(ShroudAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent("creatures")))); + + // When Plaxmanta enters the battlefield, sacrifice it unless {G} was spent to cast it. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessConditionEffect(new ManaWasSpentCondition(ColoredManaSymbol.G)), false), new ManaSpentToCastWatcher()); + } + + public Plaxmanta(final Plaxmanta card) { + super(card); + } + + @Override + public Plaxmanta copy() { + return new Plaxmanta(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dissension/RiseFall.java b/Mage.Sets/src/mage/sets/dissension/RiseFall.java index bfae9994127..91403495f23 100644 --- a/Mage.Sets/src/mage/sets/dissension/RiseFall.java +++ b/Mage.Sets/src/mage/sets/dissension/RiseFall.java @@ -29,15 +29,15 @@ package mage.sets.dissension; import java.util.UUID; import mage.MageObject; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.Cards; import mage.cards.CardsImpl; import mage.cards.SplitCard; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.game.Game; @@ -54,9 +54,9 @@ import mage.target.common.TargetCreaturePermanent; public class RiseFall extends SplitCard { public RiseFall(UUID ownerId) { - super(ownerId, 156, "Rise", "Fall", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{U}{B}","{B}{R}", false ); + super(ownerId, 156, "Rise", "Fall", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{U}{B}", "{B}{R}", false); this.expansionSetCode = "DIS"; - + // Rise // Return target creature card from a graveyard and target creature on the battlefield to their owners' hands. getLeftHalfCard().getSpellAbility().addEffect(new RiseEffect()); @@ -99,14 +99,16 @@ class RiseEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { + Cards cardsToHand = new CardsImpl(); Card cardInGraveyard = game.getCard(getTargetPointer().getFirst(game, source)); if (cardInGraveyard != null) { - controller.moveCardToHandWithInfo(cardInGraveyard, source.getSourceId(), game, Zone.GRAVEYARD); + cardsToHand.add(cardInGraveyard); } Permanent permanent = game.getPermanent(source.getTargets().get(1).getFirstTarget()); if (permanent != null) { - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + cardsToHand.add(permanent); } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; @@ -147,7 +149,7 @@ class FallEffect extends OneShotEffect { cards.add(card); } targetPlayer.revealCards(sourceObject.getName(), cards, game); - for (Card cardToDiscard: cards.getCards(game)) { + for (Card cardToDiscard : cards.getCards(game)) { if (!cardToDiscard.getCardType().contains(CardType.LAND)) { targetPlayer.discard(cardToDiscard, source, game); } diff --git a/Mage.Sets/src/mage/sets/dissension/ShieldingPlax.java b/Mage.Sets/src/mage/sets/dissension/ShieldingPlax.java index 3d42a62d49e..f2367a6c851 100644 --- a/Mage.Sets/src/mage/sets/dissension/ShieldingPlax.java +++ b/Mage.Sets/src/mage/sets/dissension/ShieldingPlax.java @@ -43,8 +43,8 @@ import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.TargetController; import mage.constants.Zone; +import mage.filter.FilterObject; import mage.filter.FilterStackObject; -import mage.filter.predicate.permanent.ControllerPredicate; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -54,12 +54,8 @@ import mage.target.common.TargetCreaturePermanent; */ public class ShieldingPlax extends CardImpl { - private static final FilterStackObject filter = new FilterStackObject("spells or abilities your opponents control"); + private static final FilterObject filter = new FilterStackObject("spells or abilities your opponents control"); - static { - filter.add(new ControllerPredicate(TargetController.OPPONENT)); - } - public ShieldingPlax(UUID ownerId) { super(ownerId, 147, "Shielding Plax", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{G/U}"); this.expansionSetCode = "DIS"; @@ -71,12 +67,13 @@ public class ShieldingPlax extends CardImpl { this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); - + // When Shielding Plax enters the battlefield, draw a card. this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1))); - + // Enchanted creature can't be the target of spells or abilities your opponents control. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeTargetedAttachedEffect(filter, Duration.WhileOnBattlefield, AttachmentType.AURA))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new CantBeTargetedAttachedEffect(filter, Duration.WhileOnBattlefield, AttachmentType.AURA, TargetController.OPPONENT))); } public ShieldingPlax(final ShieldingPlax card) { diff --git a/Mage.Sets/src/mage/sets/dissension/ValorMadeReal.java b/Mage.Sets/src/mage/sets/dissension/ValorMadeReal.java new file mode 100644 index 00000000000..18b8e5b6024 --- /dev/null +++ b/Mage.Sets/src/mage/sets/dissension/ValorMadeReal.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.dissension; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ValorMadeReal extends mage.sets.conspiracy.ValorMadeReal { + + public ValorMadeReal(UUID ownerId) { + super(ownerId); + this.cardNumber = 20; + this.expansionSetCode = "DIS"; + } + + public ValorMadeReal(final ValorMadeReal card) { + super(card); + } + + @Override + public ValorMadeReal copy() { + return new ValorMadeReal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/AEtherling.java b/Mage.Sets/src/mage/sets/dragonsmaze/AEtherling.java index a79869e862a..3dd30d6f2ad 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/AEtherling.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/AEtherling.java @@ -55,7 +55,7 @@ public class AEtherling extends CardImpl { this.toughness = new MageInt(5); // {U}: Exile AEtherling. Return it to the battlefield under its owner's control at the beginning of the next end step. - this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileReturnToBattlefieldOwnerNextEndStepEffect(), new ManaCostsImpl("{U}"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileReturnToBattlefieldOwnerNextEndStepEffect(true), new ManaCostsImpl("{U}"))); // {U}: AEtherling can't be blocked this turn this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBeBlockedSourceEffect(), new ManaCostsImpl("{U}"))); // {1}: AEtherling gets +1/-1 until end of turn. diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/BreakingEntering.java b/Mage.Sets/src/mage/sets/dragonsmaze/BreakingEntering.java index 49ed215dd95..0900fe7685f 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/BreakingEntering.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/BreakingEntering.java @@ -25,15 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.dragonsmaze; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.OneShotEffect; @@ -42,7 +36,11 @@ import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.keyword.HasteAbility; import mage.cards.Card; import mage.cards.SplitCard; +import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.game.Game; import mage.players.Player; @@ -51,12 +49,6 @@ import mage.target.TargetPlayer; import mage.target.common.TargetCardInGraveyard; import mage.target.targetpointer.FixedTarget; -/** - * - * @author LevelX2 - */ - - public class BreakingEntering extends SplitCard { public BreakingEntering(UUID ownerId) { @@ -106,18 +98,18 @@ class EnteringReturnFromGraveyardToBattlefieldEffect extends OneShotEffect { if (player != null) { Target target = new TargetCardInGraveyard(new FilterCreatureCard()); target.setNotTarget(true); - if (target.canChoose(source.getSourceId(), source.getControllerId(), game) && - player.chooseTarget(outcome, target, source, game)) { + if (target.canChoose(source.getSourceId(), source.getControllerId(), game) + && player.chooseTarget(outcome, target, source, game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { if (card.putOntoBattlefield(game, Zone.GRAVEYARD, source.getSourceId(), source.getControllerId())) { ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn); effect.setTargetPointer(new FixedTarget(card.getId())); game.addEffect(effect, source); - return true; } } } + return true; } return false; } diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/CatchRelease.java b/Mage.Sets/src/mage/sets/dragonsmaze/CatchRelease.java index cbb123879ee..e40d9d7265f 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/CatchRelease.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/CatchRelease.java @@ -119,7 +119,7 @@ class ReleaseSacrificeEffect extends OneShotEffect { Target target5 = new TargetControlledPermanent(1, 1, new FilterControlledPlaneswalkerPermanent(), true); if (target1.canChoose(player.getId(), game)) { - while (player.isInGame() && !target1.isChosen() && target1.canChoose(player.getId(), game)) { + while (player.canRespond() && !target1.isChosen() && target1.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target1, source, game); } Permanent artifact = game.getPermanent(target1.getFirstTarget()); @@ -130,7 +130,7 @@ class ReleaseSacrificeEffect extends OneShotEffect { } if (target2.canChoose(player.getId(), game)) { - while (player.isInGame() && !target2.isChosen() && target2.canChoose(player.getId(), game)) { + while (player.canRespond() && !target2.isChosen() && target2.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target2, source, game); } Permanent creature = game.getPermanent(target2.getFirstTarget()); @@ -141,7 +141,7 @@ class ReleaseSacrificeEffect extends OneShotEffect { } if (target3.canChoose(player.getId(), game)) { - while (player.isInGame() && !target3.isChosen() && target3.canChoose(player.getId(), game)) { + while (player.canRespond() && !target3.isChosen() && target3.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target3, source, game); } Permanent enchantment = game.getPermanent(target3.getFirstTarget()); @@ -152,7 +152,7 @@ class ReleaseSacrificeEffect extends OneShotEffect { } if (target4.canChoose(player.getId(), game)) { - while (player.isInGame() && !target4.isChosen() && target4.canChoose(player.getId(), game)) { + while (player.canRespond() && !target4.isChosen() && target4.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target4, source, game); } Permanent land = game.getPermanent(target4.getFirstTarget()); @@ -163,7 +163,7 @@ class ReleaseSacrificeEffect extends OneShotEffect { } if (target5.canChoose(player.getId(), game)) { - while (player.isInGame() && !target5.isChosen() && target5.canChoose(player.getId(), game)) { + while (player.canRespond() && !target5.isChosen() && target5.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target5, source, game); } Permanent planeswalker = game.getPermanent(target5.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/MelekIzzetParagon.java b/Mage.Sets/src/mage/sets/dragonsmaze/MelekIzzetParagon.java index f174c83e2f2..f58645d1781 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/MelekIzzetParagon.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/MelekIzzetParagon.java @@ -117,7 +117,7 @@ class MelekIzzetParagonTriggeredAbility extends TriggeredAbilityImpl { if (event.getZone() == Zone.LIBRARY) { Spell spell = game.getStack().getSpell(event.getTargetId()); if (spell != null - && spell.getControllerId().equals(super.getControllerId()) + && spell.getOwnerId().equals(super.getControllerId()) && (spell.getCardType().contains(CardType.INSTANT) || spell.getCardType().contains(CardType.SORCERY))) { for (Effect effect : this.getEffects()) { diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/MorgueBurst.java b/Mage.Sets/src/mage/sets/dragonsmaze/MorgueBurst.java index 2e3983e47e1..43f7b05fb55 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/MorgueBurst.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/MorgueBurst.java @@ -28,15 +28,14 @@ package mage.sets.dragonsmaze; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.game.Game; @@ -55,7 +54,6 @@ public class MorgueBurst extends CardImpl { super(ownerId, 86, "Morgue Burst", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{4}{B}{R}"); this.expansionSetCode = "DGM"; - // Return target creature card from your graveyard to your hand. Morgue Burst deals damage to target creature or player equal to the power of the card returned this way. this.getSpellAbility().addEffect(new MorgueBurstEffect()); this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard"))); @@ -93,7 +91,7 @@ class MorgueBurstEffect extends OneShotEffect { if (card != null) { Player player = game.getPlayer(card.getOwnerId()); if (player != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.HAND); + player.moveCards(card, null, Zone.HAND, source, game); int damage = card.getPower().getValue(); Permanent creature = game.getPermanent(source.getTargets().get(1).getTargets().get(0)); if (creature != null) { diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/PlasmCapture.java b/Mage.Sets/src/mage/sets/dragonsmaze/PlasmCapture.java index 6d3398e9a0b..88a299b5c98 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/PlasmCapture.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/PlasmCapture.java @@ -135,7 +135,7 @@ class PlasmCaptureManaEffect extends ManaEffect { for(int i = 0; i < amountOfMana; i++){ ChoiceColor choiceColor = new ChoiceColor(); while (!player.choose(Outcome.Benefit, choiceColor, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/dragonsmaze/UbulSarGatekeepers.java b/Mage.Sets/src/mage/sets/dragonsmaze/UbulSarGatekeepers.java index 16ff85ae354..3bc76090b02 100644 --- a/Mage.Sets/src/mage/sets/dragonsmaze/UbulSarGatekeepers.java +++ b/Mage.Sets/src/mage/sets/dragonsmaze/UbulSarGatekeepers.java @@ -25,21 +25,20 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.dragonsmaze; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; -import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.cards.CardImpl; -import mage.counters.CounterType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; import mage.filter.common.FilterControlledPermanent; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.SubtypePredicate; @@ -51,18 +50,17 @@ import mage.target.common.TargetCreaturePermanent; * * @author LevelX2 */ - - public class UbulSarGatekeepers extends CardImpl { private static final FilterControlledPermanent filter = new FilterControlledPermanent(); private static final FilterCreaturePermanent targetFilter = new FilterCreaturePermanent("creature an opponent controls"); + static { filter.add(new SubtypePredicate("Gate")); targetFilter.add(new ControllerPredicate(TargetController.OPPONENT)); } - public UbulSarGatekeepers (UUID ownerId) { + public UbulSarGatekeepers(UUID ownerId) { super(ownerId, 30, "Ubul Sar Gatekeepers", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); this.expansionSetCode = "DGM"; this.subtype.add("Zombie"); @@ -73,7 +71,7 @@ public class UbulSarGatekeepers extends CardImpl { // Whenever Ubul Sar Gatekeepers enters the battlefield, if you control two or more Gates, target creature an opponent controls gets -2/-2 until end of turn. Ability ability = new ConditionalTriggeredAbility( - new EntersBattlefieldTriggeredAbility(new AddCountersTargetEffect(CounterType.M1M1.createInstance(2))), + new EntersBattlefieldTriggeredAbility(new BoostTargetEffect(-2, -2, Duration.EndOfTurn)), new PermanentsOnTheBattlefieldCondition(filter, PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN, 1), "Whenever {this} enters the battlefield, if you control two or more Gates, target creature an opponent controls gets -2/-2 until end of turn."); Target target = new TargetCreaturePermanent(targetFilter); @@ -81,7 +79,7 @@ public class UbulSarGatekeepers extends CardImpl { this.addAbility(ability); } - public UbulSarGatekeepers (final UbulSarGatekeepers card) { + public UbulSarGatekeepers(final UbulSarGatekeepers card) { super(card); } diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/CommuneWithLava.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/CommuneWithLava.java index 4487794cdf5..89fe50de8f2 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/CommuneWithLava.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/CommuneWithLava.java @@ -27,7 +27,7 @@ */ package mage.sets.dragonsoftarkir; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.AsThoughEffectImpl; @@ -94,14 +94,13 @@ class CommuneWithLavaEffect extends OneShotEffect { Card sourceCard = game.getCard(source.getSourceId()); if (controller != null) { int amount = source.getManaCostsToPay().getX(); - List cards = controller.getLibrary().getTopCards(game, amount); + Set cards = controller.getLibrary().getTopCards(game, amount); + controller.moveCardsToExile(cards, source, game, true, CardUtil.getCardExileZoneId(game, source), sourceCard.getIdName()); + for (Card card : cards) { - if (card != null) { - controller.moveCardToExileWithInfo(card, CardUtil.getCardExileZoneId(game, source), sourceCard.getIdName(), source.getSourceId(), game, Zone.LIBRARY, true); - ContinuousEffect effect = new CommuneWithLavaMayPlayEffect(); - effect.setTargetPointer(new FixedTarget(card.getId())); - game.addEffect(effect, source); - } + ContinuousEffect effect = new CommuneWithLavaMayPlayEffect(); + effect.setTargetPointer(new FixedTarget(card.getId())); + game.addEffect(effect, source); } return true; diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/DescentOfTheDragons.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/DescentOfTheDragons.java index bc33b71c2c0..72670999b84 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/DescentOfTheDragons.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/DescentOfTheDragons.java @@ -27,6 +27,7 @@ */ package mage.sets.dragonsoftarkir; +import java.util.HashMap; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; @@ -87,18 +88,27 @@ class DescentOfTheDragonsEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { + HashMap playersWithTargets = new HashMap(); for (Target target : source.getTargets()) { for (UUID permanentId : target.getTargets()) { Permanent permanent = game.getPermanent(permanentId); if (permanent != null) { UUID controllerOfTargetId = permanent.getControllerId(); if (permanent.destroy(source.getSourceId(), game, false)) { - DragonToken dragonToken = new DragonToken(); - dragonToken.putOntoBattlefield(1, game, source.getSourceId(), controllerOfTargetId); + if(playersWithTargets.containsKey(controllerOfTargetId)) { + playersWithTargets.put(controllerOfTargetId, playersWithTargets.get(controllerOfTargetId) + 1); + } + else { + playersWithTargets.put(controllerOfTargetId, 1); + } } } } } + DragonToken dragonToken = new DragonToken(); + for(UUID playerId : playersWithTargets.keySet()) { + dragonToken.putOntoBattlefield(playersWithTargets.get(playerId), game, source.getSourceId(), playerId); + } return true; } return false; diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/FoulRenewal.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/FoulRenewal.java index 7323fddb268..68212d32e00 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/FoulRenewal.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/FoulRenewal.java @@ -95,9 +95,9 @@ class FoulRenewalEffect extends OneShotEffect { Card card = game.getCard(targetPointer.getFirst(game, source)); if (card != null) { int xValue = card.getToughness().getValue() * -1; - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(card, null, Zone.HAND, source, game); if (xValue != 0) { - ContinuousEffect effect = new BoostTargetEffect(xValue,xValue, Duration.EndOfTurn); + ContinuousEffect effect = new BoostTargetEffect(xValue, xValue, Duration.EndOfTurn); effect.setTargetPointer(new FixedTarget(source.getTargets().get(1).getFirstTarget())); game.addEffect(effect, source); } diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/NarsetTranscendent.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/NarsetTranscendent.java index a490b0d3a06..639d3f36c38 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/NarsetTranscendent.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/NarsetTranscendent.java @@ -60,7 +60,6 @@ import mage.game.stack.Spell; import mage.players.Player; import mage.target.targetpointer.FixedTarget; - /** * * @author LevelX2 @@ -73,13 +72,13 @@ public class NarsetTranscendent extends CardImpl { this.subtype.add("Narset"); this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(6)), false)); - + // +1: Look at the top card of your library. If it's a noncreature, nonland card, you may reveal it and put it into your hand. this.addAbility(new LoyaltyAbility(new NarsetTranscendentEffect1(), 1)); - + // -2: When you cast your next instant or sorcery spell from your hand this turn, it gains rebound. this.addAbility(new LoyaltyAbility(new CreateDelayedTriggeredAbilityEffect(new NarsetTranscendentTriggeredAbility()), -2)); - + // -9:You get an emblem with "Your opponents can't cast noncreature spells." this.addAbility(new LoyaltyAbility(new GetEmblemEffect(new NarsetTranscendentEmblem()), -9)); } @@ -119,11 +118,11 @@ class NarsetTranscendentEffect1 extends OneShotEffect { if (card != null) { CardsImpl cards = new CardsImpl(); cards.add(card); - controller.lookAtCards(sourceObject.getName(), cards, game); + controller.lookAtCards(sourceObject.getIdName(), cards, game); if (!card.getCardType().contains(CardType.CREATURE) && !card.getCardType().contains(CardType.LAND)) { - if (controller.chooseUse(outcome, "Reveal " + card.getName() + " and put it into your hand?", source, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - controller.revealCards(sourceObject.getName(), cards, game); + if (controller.chooseUse(outcome, "Reveal " + card.getLogName() + " and put it into your hand?", source, game)) { + controller.moveCards(card, null, Zone.HAND, source, game); + controller.revealCards(sourceObject.getIdName(), cards, game); } } return true; @@ -142,6 +141,7 @@ class NarsetTranscendentTriggeredAbility extends DelayedTriggeredAbility { private NarsetTranscendentTriggeredAbility(final NarsetTranscendentTriggeredAbility ability) { super(ability); } + @Override public NarsetTranscendentTriggeredAbility copy() { return new NarsetTranscendentTriggeredAbility(this); @@ -157,9 +157,9 @@ class NarsetTranscendentTriggeredAbility extends DelayedTriggeredAbility { if (event.getPlayerId().equals(this.getControllerId())) { Spell spell = game.getStack().getSpell(event.getTargetId()); if (spell != null && spell.getFromZone().equals(Zone.HAND)) { - if (spell.getCard() != null && - spell.getCard().getCardType().contains(CardType.INSTANT) || spell.getCard().getCardType().contains(CardType.SORCERY)) { - for(Effect effect: getEffects()) { + if (spell.getCard() != null + && spell.getCard().getCardType().contains(CardType.INSTANT) || spell.getCard().getCardType().contains(CardType.SORCERY)) { + for (Effect effect : getEffects()) { effect.setTargetPointer(new FixedTarget(spell.getId())); } return true; @@ -171,7 +171,7 @@ class NarsetTranscendentTriggeredAbility extends DelayedTriggeredAbility { @Override public String getRule() { - return "When you cast your next instant or sorcery spell from your hand this turn, " + super.getRule() ; + return "When you cast your next instant or sorcery spell from your hand this turn, " + super.getRule(); } } @@ -226,11 +226,11 @@ class NarsetTranscendentGainReboundEffect extends ContinuousEffectImpl { class NarsetTranscendentEmblem extends Emblem { // "Your opponents can't cast noncreature spells. - + public NarsetTranscendentEmblem() { - + this.setName("EMBLEM: Narset Transcendent"); - + this.getAbilities().add(new SimpleStaticAbility(Zone.COMMAND, new NarsetTranscendentCantCastEffect())); } } @@ -269,7 +269,7 @@ class NarsetTranscendentCantCastEffect extends ContinuousRuleModifyingEffectImpl public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.CAST_SPELL; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { Player controller = game.getPlayer(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/ProfanerOfTheDead.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/ProfanerOfTheDead.java index b3c97cb4142..46e06e3a618 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/ProfanerOfTheDead.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/ProfanerOfTheDead.java @@ -34,6 +34,8 @@ import mage.abilities.common.ExploitCreatureTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.keyword.ExploitAbility; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -99,9 +101,11 @@ class ProfanerOfTheDeadReturnEffect extends OneShotEffect { FilterCreaturePermanent filter = new FilterCreaturePermanent(); filter.add(new ControllerPredicate(TargetController.OPPONENT)); filter.add(new ToughnessPredicate(Filter.ComparisonType.LessThan, exploitedCreature.getToughness().getValue())); + Cards cardsToHand = new CardsImpl(); for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + cardsToHand.add(permanent); } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/RakshasaGravecaller.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/RakshasaGravecaller.java index f30c57e4767..ca087c2729a 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/RakshasaGravecaller.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/RakshasaGravecaller.java @@ -53,9 +53,9 @@ public class RakshasaGravecaller extends CardImpl { // Exploit this.addAbility(new ExploitAbility()); - + // When Rakshasa Gravecaller exploits a creature, put two 2/2 black Zombie creature tokens onto the battlefield. - this.addAbility(new ExploitCreatureTriggeredAbility(new CreateTokenEffect(new ZombieToken("DTK"), 2), false)); + this.addAbility(new ExploitCreatureTriggeredAbility(new CreateTokenEffect(new ZombieToken(), 2), false)); } public RakshasaGravecaller(final RakshasaGravecaller card) { diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/RevealingWind.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/RevealingWind.java index 71108179dac..5baca9c6591 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/RevealingWind.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/RevealingWind.java @@ -102,7 +102,7 @@ class RevealingWindEffect extends OneShotEffect { if (controller != null && sourceObject != null) { while (game.getBattlefield().count(filter, source.getOriginalId(), source.getControllerId(), game) > 0 && controller.chooseUse(outcome, "Look at a face-down attacking creature?", source, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } Target target = new TargetCreaturePermanent(filter); diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/ShorecrasherElemental.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/ShorecrasherElemental.java index 05cd4d56750..24779808257 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/ShorecrasherElemental.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/ShorecrasherElemental.java @@ -150,7 +150,7 @@ class ShorecrasherElementalBoostEffect extends OneShotEffect { choice.getChoices().add(CHOICE_1); choice.getChoices().add(CHOICE_2); while (!choice.isChosen()) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } controller.choose(outcome, choice, game); diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/Silkwrap.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/Silkwrap.java index 450283ec59d..9af141380e4 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/Silkwrap.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/Silkwrap.java @@ -53,7 +53,7 @@ import mage.util.CardUtil; * @author jeffwadsworth */ public class Silkwrap extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with converted mana cost 3 or less an opponent controls"); static { @@ -69,8 +69,8 @@ public class Silkwrap extends CardImpl { Ability ability = new EntersBattlefieldTriggeredAbility(new SilkwrapEffect()); ability.addTarget(new TargetPermanent(filter)); ability.addEffect(new CreateDelayedTriggeredAbilityEffect(new OnLeaveReturnExiledToBattlefieldAbility())); - this.addAbility(ability); - + this.addAbility(ability); + } public Silkwrap(final Silkwrap card) { @@ -103,8 +103,8 @@ class SilkwrapEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getIdName()).apply(game, source); } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/SwiftWarkite.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/SwiftWarkite.java index d3a8b1757eb..7cf4b87280b 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/SwiftWarkite.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/SwiftWarkite.java @@ -126,10 +126,10 @@ class SwiftWarkiteEffect extends OneShotEffect { Permanent creature = game.getPermanent(card.getId()); if (creature != null) { ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); - effect.setTargetPointer(new FixedTarget(creature.getId())); + effect.setTargetPointer(new FixedTarget(creature.getId(), creature.getZoneChangeCounter(game))); game.addEffect(effect, source); Effect effect2 = new ReturnToHandTargetEffect(); - effect2.setTargetPointer(new FixedTarget(creature.getId())); + effect2.setTargetPointer(new FixedTarget(creature.getId(), creature.getZoneChangeCounter(game))); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(effect2); delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setSourceId(source.getSourceId()); @@ -147,10 +147,10 @@ class SwiftWarkiteEffect extends OneShotEffect { Permanent creature = game.getPermanent(card.getId()); if (creature != null) { ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); - effect.setTargetPointer(new FixedTarget(creature.getId())); + effect.setTargetPointer(new FixedTarget(creature.getId(), creature.getZoneChangeCounter(game))); game.addEffect(effect, source); Effect effect2 = new ReturnToHandTargetEffect(); - effect2.setTargetPointer(new FixedTarget(creature.getId())); + effect2.setTargetPointer(new FixedTarget(creature.getId(), creature.getZoneChangeCounter(game))); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(effect2); delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setSourceId(source.getSourceId()); diff --git a/Mage.Sets/src/mage/sets/dragonsoftarkir/VolcanicVision.java b/Mage.Sets/src/mage/sets/dragonsoftarkir/VolcanicVision.java index 350cc728fac..b579e59ca82 100644 --- a/Mage.Sets/src/mage/sets/dragonsoftarkir/VolcanicVision.java +++ b/Mage.Sets/src/mage/sets/dragonsoftarkir/VolcanicVision.java @@ -105,10 +105,10 @@ class VolcanicVisionReturnToHandTargetEffect extends OneShotEffect { case GRAVEYARD: Card card = game.getCard(targetId); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(card, null, Zone.HAND, source, game); int damage = card.getManaCost().convertedManaCost(); if (damage > 0) { - for(Permanent creature: game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { + for (Permanent creature : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { creature.damage(damage, source.getSourceId(), game, false, true); } } diff --git a/Mage.Sets/src/mage/sets/eighthedition/BrassHerald.java b/Mage.Sets/src/mage/sets/eighthedition/BrassHerald.java new file mode 100644 index 00000000000..43bb4056503 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eighthedition/BrassHerald.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eighthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class BrassHerald extends mage.sets.apocalypse.BrassHerald { + + public BrassHerald(UUID ownerId) { + super(ownerId); + this.cardNumber = 293; + this.expansionSetCode = "8ED"; + this.rarity = Rarity.RARE; + } + + public BrassHerald(final BrassHerald card) { + super(card); + } + + @Override + public BrassHerald copy() { + return new BrassHerald(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eighthedition/CoastalPiracy.java b/Mage.Sets/src/mage/sets/eighthedition/CoastalPiracy.java new file mode 100644 index 00000000000..25ce5da873e --- /dev/null +++ b/Mage.Sets/src/mage/sets/eighthedition/CoastalPiracy.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eighthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author Xavierv3131 + */ +public class CoastalPiracy extends mage.sets.mercadianmasques.CoastalPiracy { + + public CoastalPiracy(UUID ownerId) { + super(ownerId); + this.cardNumber = 67; + this.expansionSetCode = "8ED"; + this.rarity = Rarity.RARE; + } + + public CoastalPiracy(final CoastalPiracy card) { + super(card); + } + + @Override + public CoastalPiracy copy() { + return new CoastalPiracy(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eighthedition/PrimevalForce.java b/Mage.Sets/src/mage/sets/eighthedition/PrimevalForce.java index 34329114d1f..d5e41013983 100644 --- a/Mage.Sets/src/mage/sets/eighthedition/PrimevalForce.java +++ b/Mage.Sets/src/mage/sets/eighthedition/PrimevalForce.java @@ -1,73 +1,73 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.eighthedition; - -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.MageInt; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.costs.common.SacrificeTargetCost; -import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; -import mage.cards.CardImpl; -import mage.filter.common.FilterControlledLandPermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.target.common.TargetControlledPermanent; - -/** - * - * @author Plopman - */ -public class PrimevalForce extends CardImpl { - - private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("Forest"); - static{ - filter.add(new SubtypePredicate("Forest")); - } - - public PrimevalForce(UUID ownerId) { - super(ownerId, 273, "Primeval Force", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{G}{G}{G}"); - this.expansionSetCode = "8ED"; - this.subtype.add("Elemental"); - - this.power = new MageInt(8); - this.toughness = new MageInt(8); - - // When Primeval Force enters the battlefield, sacrifice it unless you sacrifice three Forests. - this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(3, 3, filter, true))))); - } - - public PrimevalForce(final PrimevalForce card) { - super(card); - } - - @Override - public PrimevalForce copy() { - return new PrimevalForce(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eighthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author Plopman + */ +public class PrimevalForce extends CardImpl { + + private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("three Forests"); + static{ + filter.add(new SubtypePredicate("Forest")); + } + + public PrimevalForce(UUID ownerId) { + super(ownerId, 273, "Primeval Force", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{G}{G}{G}"); + this.expansionSetCode = "8ED"; + this.subtype.add("Elemental"); + + this.power = new MageInt(8); + this.toughness = new MageInt(8); + + // When Primeval Force enters the battlefield, sacrifice it unless you sacrifice three Forests. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(3, 3, filter, true))))); + } + + public PrimevalForce(final PrimevalForce card) { + super(card); + } + + @Override + public PrimevalForce copy() { + return new PrimevalForce(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eighthedition/WarpedDevotion.java b/Mage.Sets/src/mage/sets/eighthedition/WarpedDevotion.java new file mode 100644 index 00000000000..777f332ff05 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eighthedition/WarpedDevotion.java @@ -0,0 +1,104 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eighthedition; + +import java.util.UUID; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.ZoneChangeEvent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + */ +public class WarpedDevotion extends CardImpl { + + public WarpedDevotion(UUID ownerId) { + super(ownerId, 172, "Warped Devotion", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "8ED"; + + // Whenever a permanent is returned to a player's hand, that player discards a card. + this.addAbility(new WarpedDevotionTriggeredAbility()); + } + + public WarpedDevotion(final WarpedDevotion card) { + super(card); + } + + @Override + public WarpedDevotion copy() { + return new WarpedDevotion(this); + } +} + +class WarpedDevotionTriggeredAbility extends TriggeredAbilityImpl { + + public WarpedDevotionTriggeredAbility() { + super(Zone.BATTLEFIELD, new DiscardTargetEffect(1), false); + } + + public WarpedDevotionTriggeredAbility(final WarpedDevotionTriggeredAbility ability) { + super(ability); + } + + public WarpedDevotionTriggeredAbility copy() { + return new WarpedDevotionTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.ZONE_CHANGE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + ZoneChangeEvent zce = (ZoneChangeEvent)event; + if(zce.getFromZone() == Zone.BATTLEFIELD && zce.getToZone() == Zone.HAND) { + for(Effect effect: getEffects()) { + effect.setTargetPointer(new FixedTarget(zce.getTarget().getOwnerId())); + } + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever a permanent is returned to a player's hand, that player discards a card."; + } + +} diff --git a/Mage.Sets/src/mage/sets/elspethvskiora/GustcloakSavior.java b/Mage.Sets/src/mage/sets/elspethvskiora/GustcloakSavior.java new file mode 100644 index 00000000000..0a8b9bbc2fd --- /dev/null +++ b/Mage.Sets/src/mage/sets/elspethvskiora/GustcloakSavior.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.elspethvskiora; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class GustcloakSavior extends mage.sets.onslaught.GustcloakSavior { + + public GustcloakSavior(UUID ownerId) { + super(ownerId); + this.cardNumber = 11; + this.expansionSetCode = "DDO"; + } + + public GustcloakSavior(final GustcloakSavior card) { + super(card); + } + + @Override + public GustcloakSavior copy() { + return new GustcloakSavior(this); + } +} diff --git a/Mage.Sets/src/mage/sets/elspethvstezzeret/EchoingTruth.java b/Mage.Sets/src/mage/sets/elspethvstezzeret/EchoingTruth.java index 772509be82a..2e52c6bcb58 100644 --- a/Mage.Sets/src/mage/sets/elspethvstezzeret/EchoingTruth.java +++ b/Mage.Sets/src/mage/sets/elspethvstezzeret/EchoingTruth.java @@ -32,12 +32,13 @@ import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterPermanent; -import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.NamePredicate; import mage.filter.predicate.permanent.PermanentIdPredicate; import mage.game.Game; @@ -96,11 +97,13 @@ class ReturnToHandAllNamedPermanentsEffect extends OneShotEffect { if (permanent.getName().isEmpty()) { filter.add(new PermanentIdPredicate(permanent.getId())); // if no name (face down creature) only the creature itself is selected } else { - filter.add(new NamePredicate(permanent.getName())); + filter.add(new NamePredicate(permanent.getName())); } - for (Permanent perm: game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game)) { - controller.moveCardToHandWithInfo(perm, source.getSourceId(), game, Zone.BATTLEFIELD); + Cards cardsToHand = new CardsImpl(); + for (Permanent perm : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game)) { + cardsToHand.add(perm); } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return true; diff --git a/Mage.Sets/src/mage/sets/elvesvsgoblins/IbHalfheartGoblinTactician.java b/Mage.Sets/src/mage/sets/elvesvsgoblins/IbHalfheartGoblinTactician.java index 095e9dc2bbc..44cfadd869f 100644 --- a/Mage.Sets/src/mage/sets/elvesvsgoblins/IbHalfheartGoblinTactician.java +++ b/Mage.Sets/src/mage/sets/elvesvsgoblins/IbHalfheartGoblinTactician.java @@ -86,7 +86,7 @@ public class IbHalfheartGoblinTactician extends CardImpl { // Sacrifice two Mountains: Put two 1/1 red Goblin creature tokens onto the battlefield. this.addAbility(new SimpleActivatedAbility( Zone.BATTLEFIELD, - new CreateTokenEffect(new GoblinToken(expansionSetCode), 2), + new CreateTokenEffect(new GoblinToken(), 2), new SacrificeTargetCost(new TargetControlledPermanent(2, 2, filter, true)))); } diff --git a/Mage.Sets/src/mage/sets/elvesvsgoblins/SkirkShaman.java b/Mage.Sets/src/mage/sets/elvesvsgoblins/SkirkShaman.java index a6279964877..e6bad1d45fa 100644 --- a/Mage.Sets/src/mage/sets/elvesvsgoblins/SkirkShaman.java +++ b/Mage.Sets/src/mage/sets/elvesvsgoblins/SkirkShaman.java @@ -30,13 +30,12 @@ package mage.sets.elvesvsgoblins; import java.util.UUID; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; @@ -55,7 +54,7 @@ public class SkirkShaman extends CardImpl { Predicates.or( Predicates.and(new CardTypePredicate(CardType.ARTIFACT), new CardTypePredicate(CardType.CREATURE)), Predicates.and(new CardTypePredicate(CardType.CREATURE), new ColorPredicate(ObjectColor.RED) - )))); + )))); } public SkirkShaman(UUID ownerId) { @@ -68,7 +67,7 @@ public class SkirkShaman extends CardImpl { this.toughness = new MageInt(2); // Skirk Shaman can't be blocked except by artifact creatures and/or red creatures. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } diff --git a/Mage.Sets/src/mage/sets/eventide/AshlingTheExtinguisher.java b/Mage.Sets/src/mage/sets/eventide/AshlingTheExtinguisher.java index 3b525f22126..e8fbba42e5e 100644 --- a/Mage.Sets/src/mage/sets/eventide/AshlingTheExtinguisher.java +++ b/Mage.Sets/src/mage/sets/eventide/AshlingTheExtinguisher.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.eventide; import java.util.UUID; @@ -51,19 +50,20 @@ import mage.target.common.TargetCreaturePermanent; */ public class AshlingTheExtinguisher extends CardImpl { - public AshlingTheExtinguisher (UUID ownerId) { + public AshlingTheExtinguisher(UUID ownerId) { super(ownerId, 33, "Ashling, the Extinguisher", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}{B}"); this.expansionSetCode = "EVE"; this.supertype.add("Legendary"); this.subtype.add("Elemental"); this.subtype.add("Shaman"); + // Whenever Ashling, the Extinguisher deals combat damage to a player, choose target creature that player controls. He or she sacrifices that creature. this.power = new MageInt(4); this.toughness = new MageInt(4); this.addAbility(new AshlingTheExtinguisherTriggeredAbility()); } - public AshlingTheExtinguisher (final AshlingTheExtinguisher card) { + public AshlingTheExtinguisher(final AshlingTheExtinguisher card) { super(card); } @@ -75,6 +75,7 @@ public class AshlingTheExtinguisher extends CardImpl { } class AshlingTheExtinguisherTriggeredAbility extends TriggeredAbilityImpl { + public AshlingTheExtinguisherTriggeredAbility() { super(Zone.BATTLEFIELD, new SacrificeTargetEffect()); this.addTarget(new TargetCreaturePermanent()); @@ -115,4 +116,4 @@ class AshlingTheExtinguisherTriggeredAbility extends TriggeredAbilityImpl { public String getRule() { return "Whenever {this} deals combat damage to a player, choose target creature that player controls. He or she sacrifices that creature."; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/eventide/Evershrike.java b/Mage.Sets/src/mage/sets/eventide/Evershrike.java index f413f47643e..776939f0dcd 100644 --- a/Mage.Sets/src/mage/sets/eventide/Evershrike.java +++ b/Mage.Sets/src/mage/sets/eventide/Evershrike.java @@ -122,7 +122,7 @@ class EvershrikeEffect extends OneShotEffect { filterAuraCard.add(new AuraCardCanAttachToPermanentId(evershrikePermanent.getId())); filterAuraCard.add(new ConvertedManaCostPredicate(ComparisonType.LessThan, xAmount)); int count = controller.getHand().count(filterAuraCard, game); - while (controller.isInGame() && count > 0 && controller.chooseUse(Outcome.Benefit, "Do you wish to put an Aura card from your hand onto Evershrike", source, game)) { + while (controller.canRespond() && count > 0 && controller.chooseUse(Outcome.Benefit, "Do you wish to put an Aura card from your hand onto Evershrike", source, game)) { TargetCard targetAura = new TargetCard(Zone.PICK, filterAuraCard); if (controller.choose(Outcome.Benefit, controller.getHand(), targetAura, game)) { Card aura = game.getCard(targetAura.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/eventide/GroundlingPouncer.java b/Mage.Sets/src/mage/sets/eventide/GroundlingPouncer.java index 1d7e0ead21c..79141ba5cc4 100644 --- a/Mage.Sets/src/mage/sets/eventide/GroundlingPouncer.java +++ b/Mage.Sets/src/mage/sets/eventide/GroundlingPouncer.java @@ -60,7 +60,7 @@ import mage.watchers.Watcher; * */ public class GroundlingPouncer extends CardImpl { - + private String rule = "{this} gets +1/+3 and gains flying until end of turn. Activate this ability only once each turn and only if an opponent controls a creature with flying."; public GroundlingPouncer(UUID ownerId) { @@ -118,7 +118,7 @@ class GroundingPouncerCondition implements Condition { class ActivatedAbilityUsedThisTurnWatcher extends Watcher { - public Set activatedThisTurn = new HashSet(); + public Set activatedThisTurn = new HashSet<>(); public ActivatedAbilityUsedThisTurnWatcher() { super("ActivatedAbilityUsedThisTurn", WatcherScope.GAME); @@ -156,4 +156,4 @@ class ActivatedAbilityUsedThisTurnWatcher extends Watcher { super.reset(); this.activatedThisTurn.clear(); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/eventide/HagHedgeMage.java b/Mage.Sets/src/mage/sets/eventide/HagHedgeMage.java index 05effd0fbab..dc278fa1bbf 100644 --- a/Mage.Sets/src/mage/sets/eventide/HagHedgeMage.java +++ b/Mage.Sets/src/mage/sets/eventide/HagHedgeMage.java @@ -47,18 +47,18 @@ import mage.target.common.TargetCardInYourGraveyard; /** * * @author jeffwadsworth - + * */ public class HagHedgeMage extends CardImpl { - + private final static FilterLandPermanent filter = new FilterLandPermanent(); private final static FilterLandPermanent filter2 = new FilterLandPermanent(); - + static { filter.add(new SubtypePredicate("Swamp")); filter2.add(new SubtypePredicate("Forest")); } - + private String rule = "When {this} enters the battlefield, if you control two or more Swamps, you may have target player discard a card."; private String rule2 = "When {this} enters the battlefield, if you control two or more Forests, you may put target card from your graveyard on top of your library."; @@ -72,12 +72,12 @@ public class HagHedgeMage extends CardImpl { this.toughness = new MageInt(2); // When Hag Hedge-Mage enters the battlefield, if you control two or more Swamps, you may have target player discard a card. - Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DiscardTargetEffect(1), true), new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 1), rule, true); + Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DiscardTargetEffect(1), true), new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 1), rule); ability.addTarget(new TargetPlayer()); this.addAbility(ability); - + // When Hag Hedge-Mage enters the battlefield, if you control two or more Forests, you may put target card from your graveyard on top of your library. - Ability ability2 = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new PutOnLibraryTargetEffect(true), true), new PermanentsOnTheBattlefieldCondition(filter2, CountType.MORE_THAN, 1), rule2, true); + Ability ability2 = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new PutOnLibraryTargetEffect(true), true), new PermanentsOnTheBattlefieldCondition(filter2, CountType.MORE_THAN, 1), rule2); ability2.addTarget(new TargetCardInYourGraveyard()); this.addAbility(ability2); } diff --git a/Mage.Sets/src/mage/sets/eventide/HelixPinnacle.java b/Mage.Sets/src/mage/sets/eventide/HelixPinnacle.java index 4ee82c7e94e..412e96bafd8 100644 --- a/Mage.Sets/src/mage/sets/eventide/HelixPinnacle.java +++ b/Mage.Sets/src/mage/sets/eventide/HelixPinnacle.java @@ -56,7 +56,6 @@ public class HelixPinnacle extends CardImpl { super(ownerId, 68, "Helix Pinnacle", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{G}"); this.expansionSetCode = "EVE"; - // Shroud this.addAbility(ShroudAbility.getInstance()); @@ -64,12 +63,12 @@ public class HelixPinnacle extends CardImpl { this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.TOWER.createInstance(), new ManacostVariableValue(), true), new ManaCostsImpl("{X}"))); - + // At the beginning of your upkeep, if there are 100 or more tower counters on Helix Pinnacle, you win the game. this.addAbility(new ConditionalTriggeredAbility( new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new WinGameSourceControllerEffect(), TargetController.YOU, false), new SourceHasCounterCondition(CounterType.TOWER, 100), - rule, false )); + rule)); } diff --git a/Mage.Sets/src/mage/sets/eventide/MindwrackLiege.java b/Mage.Sets/src/mage/sets/eventide/MindwrackLiege.java index eda9db62341..f0d5714b775 100644 --- a/Mage.Sets/src/mage/sets/eventide/MindwrackLiege.java +++ b/Mage.Sets/src/mage/sets/eventide/MindwrackLiege.java @@ -30,17 +30,14 @@ package mage.sets.eventide; import java.util.UUID; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.abilities.effects.common.continuous.BoostAllEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.TargetController; import mage.constants.Zone; @@ -49,9 +46,6 @@ import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.ColorPredicate; import mage.filter.predicate.permanent.ControllerPredicate; -import mage.game.Game; -import mage.players.Player; -import mage.target.common.TargetCardInHand; /** * @@ -59,15 +53,17 @@ import mage.target.common.TargetCardInHand; */ public class MindwrackLiege extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blue creatures you control"); private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent("red creatures you control"); + private static final FilterCreatureCard filter3 = new FilterCreatureCard("a blue or red creature card"); + static { filter.add(new ColorPredicate(ObjectColor.BLUE)); filter.add(new ControllerPredicate(TargetController.YOU)); - filter2.add(new ColorPredicate(ObjectColor.RED)); filter2.add(new ControllerPredicate(TargetController.YOU)); + filter3.add(Predicates.or(new ColorPredicate(ObjectColor.BLUE), new ColorPredicate(ObjectColor.RED))); } public MindwrackLiege(UUID ownerId) { @@ -80,13 +76,12 @@ public class MindwrackLiege extends CardImpl { // Other blue creatures you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, true))); - + // Other red creatures you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter2, true))); - + // {UR}{UR}{UR}{UR}: You may put a blue or red creature card from your hand onto the battlefield. - this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new MindwrackLiegeEffect(), new ManaCostsImpl("{U/R}{U/R}{U/R}{U/R}"))); - + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutPermanentOnBattlefieldEffect(filter3), new ManaCostsImpl("{U/R}{U/R}{U/R}{U/R}"))); } public MindwrackLiege(final MindwrackLiege card) { @@ -98,48 +93,3 @@ public class MindwrackLiege extends CardImpl { return new MindwrackLiege(this); } } - -class MindwrackLiegeEffect extends OneShotEffect { - - private static final String choiceText = "Put a blue or red creature card from your hand onto the battlefield?"; - - private static final FilterCreatureCard filter = new FilterCreatureCard("a blue or red creature card"); - - static { - filter.add(Predicates.or( - new ColorPredicate(ObjectColor.BLUE), - new ColorPredicate(ObjectColor.RED))); - } - - public MindwrackLiegeEffect() { - super(Outcome.PutCreatureInPlay); - this.staticText = "You may put a blue or red creature card from your hand onto the battlefield"; - } - - public MindwrackLiegeEffect(final MindwrackLiegeEffect effect) { - super(effect); - } - - @Override - public MindwrackLiegeEffect copy() { - return new MindwrackLiegeEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null || !player.chooseUse(Outcome.PutCreatureInPlay, choiceText, source, game)) { - return false; - } - - TargetCardInHand target = new TargetCardInHand(filter); - if (player.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - card.putOntoBattlefield(game, Zone.HAND, source.getSourceId(), source.getControllerId()); - return true; - } - } - return false; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/eventide/Necroskitter.java b/Mage.Sets/src/mage/sets/eventide/Necroskitter.java index e3945c2cc46..309521f8d17 100644 --- a/Mage.Sets/src/mage/sets/eventide/Necroskitter.java +++ b/Mage.Sets/src/mage/sets/eventide/Necroskitter.java @@ -80,7 +80,7 @@ public class Necroskitter extends CardImpl { class NecroskitterTriggeredAbility extends TriggeredAbilityImpl { public NecroskitterTriggeredAbility() { - super(Zone.BATTLEFIELD, new ReturnToBattlefieldUnderYourControlTargetEffect()); + super(Zone.BATTLEFIELD, new ReturnToBattlefieldUnderYourControlTargetEffect(), true); } public NecroskitterTriggeredAbility(NecroskitterTriggeredAbility ability) { @@ -100,18 +100,13 @@ class NecroskitterTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { ZoneChangeEvent zEvent = (ZoneChangeEvent) event; - if (game.getPermanent(sourceId) == null) { - if (game.getLastKnownInformation(sourceId, Zone.BATTLEFIELD) == null) { - return false; - } - } if (zEvent.getFromZone() == Zone.BATTLEFIELD && zEvent.getToZone() == Zone.GRAVEYARD) { - Permanent permanent = (Permanent) game.getLastKnownInformation(event.getTargetId(), Zone.BATTLEFIELD); + Permanent permanent = zEvent.getTarget(); if (permanent != null && permanent.getCounters().containsKey(CounterType.M1M1) && game.getOpponents(controllerId).contains(permanent.getControllerId())) { for (Effect effect : this.getEffects()) { - effect.setTargetPointer(new FixedTarget(event.getTargetId())); + effect.setTargetPointer(new FixedTarget(event.getTargetId(), game.getState().getZoneChangeCounter(event.getTargetId()))); } return true; } diff --git a/Mage.Sets/src/mage/sets/eventide/NoggleBandit.java b/Mage.Sets/src/mage/sets/eventide/NoggleBandit.java index 6c6b494ac48..42a29a32357 100644 --- a/Mage.Sets/src/mage/sets/eventide/NoggleBandit.java +++ b/Mage.Sets/src/mage/sets/eventide/NoggleBandit.java @@ -29,14 +29,13 @@ package mage.sets.eventide; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.DefenderAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; @@ -44,12 +43,12 @@ import mage.filter.predicate.mageobject.AbilityPredicate; /** * * @author jeffwadsworth - + * */ public class NoggleBandit extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("except by creatures with defender"); - + static { filter.add(Predicates.not(new AbilityPredicate(DefenderAbility.class))); } @@ -64,8 +63,8 @@ public class NoggleBandit extends CardImpl { this.toughness = new MageInt(2); // Noggle Bandit can't be blocked except by creatures with defender. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); - + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + } public NoggleBandit(final NoggleBandit card) { diff --git a/Mage.Sets/src/mage/sets/eventide/NoggleHedgeMage.java b/Mage.Sets/src/mage/sets/eventide/NoggleHedgeMage.java index 855a008226f..ca34334442c 100644 --- a/Mage.Sets/src/mage/sets/eventide/NoggleHedgeMage.java +++ b/Mage.Sets/src/mage/sets/eventide/NoggleHedgeMage.java @@ -48,18 +48,18 @@ import mage.target.TargetPlayer; /** * * @author jeffwadsworth - + * */ public class NoggleHedgeMage extends CardImpl { - + private final static FilterLandPermanent filter = new FilterLandPermanent(); private final static FilterLandPermanent filter2 = new FilterLandPermanent(); - + static { filter.add(new SubtypePredicate("Island")); filter2.add(new SubtypePredicate("Mountain")); } - + private String rule = "When {this} enters the battlefield, if you control two or more Islands, you may tap two target permanents."; private String rule2 = "When {this} enters the battlefield, if you control two or more Mountains, you may have {this} deal 2 damage to target player."; @@ -73,12 +73,12 @@ public class NoggleHedgeMage extends CardImpl { this.toughness = new MageInt(2); // When Noggle Hedge-Mage enters the battlefield, if you control two or more Islands, you may tap two target permanents. - Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new TapTargetEffect(), true), new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 1), rule, true); + Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new TapTargetEffect(), true), new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 1), rule); ability.addTarget(new TargetPermanent(2, new FilterPermanent())); this.addAbility(ability); - + // When Noggle Hedge-Mage enters the battlefield, if you control two or more Mountains, you may have Noggle Hedge-Mage deal 2 damage to target player. - Ability ability2 = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DamageTargetEffect(2), true), new PermanentsOnTheBattlefieldCondition(filter2, CountType.MORE_THAN, 1), rule2, true); + Ability ability2 = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DamageTargetEffect(2), true), new PermanentsOnTheBattlefieldCondition(filter2, CountType.MORE_THAN, 1), rule2); ability2.addTarget(new TargetPlayer()); this.addAbility(ability2); } diff --git a/Mage.Sets/src/mage/sets/eventide/SanityGrinding.java b/Mage.Sets/src/mage/sets/eventide/SanityGrinding.java index 063228b681a..3ee98ec4d43 100644 --- a/Mage.Sets/src/mage/sets/eventide/SanityGrinding.java +++ b/Mage.Sets/src/mage/sets/eventide/SanityGrinding.java @@ -27,6 +27,8 @@ */ package mage.sets.eventide; +import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; @@ -43,8 +45,6 @@ import mage.game.Game; import mage.players.Player; import mage.target.common.TargetOpponent; -import java.util.UUID; - /** * * @author jeffwadsworth @@ -56,7 +56,6 @@ public class SanityGrinding extends CardImpl { super(ownerId, 29, "Sanity Grinding", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{U}{U}{U}"); this.expansionSetCode = "EVE"; - // Chroma - Reveal the top ten cards of your library. For each blue mana symbol in the mana costs of the revealed cards, target opponent puts the top card of his or her library into his or her graveyard. Then put the cards you revealed this way on the bottom of your library in any order. this.getSpellAbility().addEffect(new SanityGrindingEffect()); this.getSpellAbility().addTarget(new TargetOpponent()); @@ -86,18 +85,15 @@ class SanityGrindingEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player targetOpponent = game.getPlayer(source.getFirstTarget()); Player controller = game.getPlayer(source.getControllerId()); - Cards revealed = new CardsImpl(); - int amount; - if (controller == null) { + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { return false; } - amount = (Math.min(10, controller.getLibrary().size())); - for (int i = 0; i < amount; i++) { - revealed.add(controller.getLibrary().removeFromTop(game)); - } - controller.revealCards("Sanity Grinding", revealed, game); + Cards revealed = new CardsImpl(); + revealed.addAll(controller.getLibrary().getTopCards(game, 10)); + controller.revealCards(sourceObject.getIdName(), revealed, game); + Player targetOpponent = game.getPlayer(source.getFirstTarget()); if (targetOpponent != null) { targetOpponent.moveCards(targetOpponent.getLibrary().getTopCards(game, new ChromaSanityGrindingCount(revealed).calculate(game, source, this)), Zone.LIBRARY, Zone.GRAVEYARD, source, game); diff --git a/Mage.Sets/src/mage/sets/exodus/Allay.java b/Mage.Sets/src/mage/sets/exodus/Allay.java new file mode 100644 index 00000000000..f9e5abf1b14 --- /dev/null +++ b/Mage.Sets/src/mage/sets/exodus/Allay.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.exodus; + +import java.util.UUID; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.BuybackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterEnchantmentPermanent; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class Allay extends CardImpl { + + public Allay(UUID ownerId) { + super(ownerId, 1, "Allay", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "EXO"; + + // Buyback {3} + this.addAbility(new BuybackAbility("{3}")); + + // Destroy target enchantment. + this.getSpellAbility().addTarget(new TargetPermanent(new FilterEnchantmentPermanent())); + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + } + + public Allay(final Allay card) { + super(card); + } + + @Override + public Allay copy() { + return new Allay(this); + } +} diff --git a/Mage.Sets/src/mage/sets/exodus/Cataclysm.java b/Mage.Sets/src/mage/sets/exodus/Cataclysm.java index e9eac061644..ac1df0bf079 100644 --- a/Mage.Sets/src/mage/sets/exodus/Cataclysm.java +++ b/Mage.Sets/src/mage/sets/exodus/Cataclysm.java @@ -95,7 +95,7 @@ class CataclysmEffect extends OneShotEffect { Target target4 = new TargetControlledPermanent(1, 1, new FilterControlledLandPermanent(), true); if (target1.canChoose(player.getId(), game)) { - while (player.isInGame() && !target1.isChosen() && target1.canChoose(player.getId(), game)) { + while (player.canRespond() && !target1.isChosen() && target1.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target1, source, game); } Permanent artifact = game.getPermanent(target1.getFirstTarget()); @@ -106,7 +106,7 @@ class CataclysmEffect extends OneShotEffect { } if (target2.canChoose(player.getId(), game)) { - while (player.isInGame() && !target2.isChosen() && target2.canChoose(player.getId(), game)) { + while (player.canRespond() && !target2.isChosen() && target2.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target2, source, game); } Permanent creature = game.getPermanent(target2.getFirstTarget()); @@ -117,7 +117,7 @@ class CataclysmEffect extends OneShotEffect { } if (target3.canChoose(player.getId(), game)) { - while (player.isInGame() && !target3.isChosen() && target3.canChoose(player.getId(), game)) { + while (player.canRespond() && !target3.isChosen() && target3.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target3, source, game); } Permanent enchantment = game.getPermanent(target3.getFirstTarget()); @@ -128,7 +128,7 @@ class CataclysmEffect extends OneShotEffect { } if (target4.canChoose(player.getId(), game)) { - while (player.isInGame() && !target4.isChosen() && target4.canChoose(player.getId(), game)) { + while (player.canRespond() && !target4.isChosen() && target4.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target4, source, game); } Permanent land = game.getPermanent(target4.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/exodus/ReapingTheRewards.java b/Mage.Sets/src/mage/sets/exodus/ReapingTheRewards.java new file mode 100644 index 00000000000..e1cd5b7f455 --- /dev/null +++ b/Mage.Sets/src/mage/sets/exodus/ReapingTheRewards.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.exodus; + +import java.util.UUID; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.keyword.BuybackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class ReapingTheRewards extends CardImpl { + + public ReapingTheRewards(UUID ownerId) { + super(ownerId, 16, "Reaping the Rewards", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "EXO"; + + // Buyback-Sacrifice a land. + this.addAbility(new BuybackAbility(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent())))); + + // You gain 2 life. + this.getSpellAbility().addEffect(new GainLifeEffect(2)); + } + + public ReapingTheRewards(final ReapingTheRewards card) { + super(card); + } + + @Override + public ReapingTheRewards copy() { + return new ReapingTheRewards(this); + } +} diff --git a/Mage.Sets/src/mage/sets/exodus/RecurringNightmare.java b/Mage.Sets/src/mage/sets/exodus/RecurringNightmare.java index 7b1e7534779..200cbf81999 100644 --- a/Mage.Sets/src/mage/sets/exodus/RecurringNightmare.java +++ b/Mage.Sets/src/mage/sets/exodus/RecurringNightmare.java @@ -37,7 +37,7 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; -import mage.filter.common.FilterControlledPermanent; +import mage.filter.common.FilterControlledCreaturePermanent; import mage.filter.common.FilterCreatureCard; import mage.target.common.TargetCardInYourGraveyard; import mage.target.common.TargetControlledPermanent; @@ -47,15 +47,14 @@ import mage.target.common.TargetControlledPermanent; * @author jeffwadsworth */ public class RecurringNightmare extends CardImpl { - + private static final FilterCreatureCard filter = new FilterCreatureCard("creature card in your graveyard"); - private static final FilterControlledPermanent filter2 = new FilterControlledPermanent("creature"); + private static final FilterControlledCreaturePermanent filter2 = new FilterControlledCreaturePermanent("creature"); public RecurringNightmare(UUID ownerId) { super(ownerId, 72, "Recurring Nightmare", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); this.expansionSetCode = "EXO"; - // Sacrifice a creature, Return Recurring Nightmare to its owner's hand: Return target creature card from your graveyard to the battlefield. Activate this ability only any time you could cast a sorcery. Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToBattlefieldTargetEffect(), new SacrificeTargetCost(new TargetControlledPermanent(filter2))); ability.addTarget(new TargetCardInYourGraveyard(filter)); diff --git a/Mage.Sets/src/mage/sets/exodus/SonicBurst.java b/Mage.Sets/src/mage/sets/exodus/SonicBurst.java new file mode 100644 index 00000000000..83af8608c9e --- /dev/null +++ b/Mage.Sets/src/mage/sets/exodus/SonicBurst.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.exodus; + +import java.util.UUID; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author markedagain + */ +public class SonicBurst extends CardImpl { + + public SonicBurst(UUID ownerId) { + super(ownerId, 103, "Sonic Burst", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{R}"); + this.expansionSetCode = "EXO"; + + // As an additional cost to cast Sonic Burst, discard a card at random. + this.getSpellAbility().addCost(new DiscardCardCost(true)); + // Sonic Burst deals 4 damage to target creature or player. + this.getSpellAbility().addEffect(new DamageTargetEffect(4)); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + } + + public SonicBurst(final SonicBurst card) { + super(card); + } + + @Override + public SonicBurst copy() { + return new SonicBurst(this); + } +} diff --git a/Mage.Sets/src/mage/sets/exodus/TheftOfDreams.java b/Mage.Sets/src/mage/sets/exodus/TheftOfDreams.java new file mode 100644 index 00000000000..e1b3c1a9fde --- /dev/null +++ b/Mage.Sets/src/mage/sets/exodus/TheftOfDreams.java @@ -0,0 +1,97 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.exodus; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.filter.predicate.permanent.TappedPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class TheftOfDreams extends CardImpl { + + public TheftOfDreams(UUID ownerId) { + super(ownerId, 49, "Theft of Dreams", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{U}"); + this.expansionSetCode = "EXO"; + + // Draw a card for each tapped creature target opponent controls. + this.getSpellAbility().addEffect(new TheftOfDreamsEffect()); + this.getSpellAbility().addTarget(new TargetOpponent()); + } + + public TheftOfDreams(final TheftOfDreams card) { + super(card); + } + + @Override + public TheftOfDreams copy() { + return new TheftOfDreams(this); + } +} + +class TheftOfDreamsEffect extends OneShotEffect { + + public TheftOfDreamsEffect() { + super(Outcome.DrawCard); + this.staticText = "Draw a card for each tapped creature target opponent controls"; + } + + public TheftOfDreamsEffect(final TheftOfDreamsEffect effect) { + super(effect); + } + + @Override + public TheftOfDreamsEffect copy() { + return new TheftOfDreamsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player opponent = game.getPlayer(this.getTargetPointer().getFirst(game, source)); + if (opponent != null) { + FilterCreaturePermanent filter = new FilterCreaturePermanent(); + filter.add(new TappedPredicate()); + filter.add(new ControllerIdPredicate(opponent.getId())); + return new DrawCardSourceControllerEffect(game.getBattlefield().count(filter, source.getSourceId(), source.getControllerId(), game)).apply(game, source); + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/exodus/Workhorse.java b/Mage.Sets/src/mage/sets/exodus/Workhorse.java new file mode 100644 index 00000000000..d681e6b96b9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/exodus/Workhorse.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.exodus; + +import java.util.UUID; +import mage.MageInt; +import mage.Mana; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; + +/** + * + * @author fireshoes + */ +public class Workhorse extends CardImpl { + + public Workhorse(UUID ownerId) { + super(ownerId, 142, "Workhorse", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{6}"); + this.expansionSetCode = "EXO"; + this.subtype.add("Horse"); + this.power = new MageInt(0); + this.toughness = new MageInt(0); + + // Workhorse enters the battlefield with four +1/+1 counters on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(4)), "with four +1/+1 counters on it")); + + // Remove a +1/+1 counter from Workhorse: Add {1} to your mana pool. + this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, + new Mana(new Mana(0, 0, 0, 0, 0, 1, 0)), + new RemoveCountersSourceCost(CounterType.P1P1.createInstance()))); + } + + public Workhorse(final Workhorse card) { + super(card); + } + + @Override + public Workhorse copy() { + return new Workhorse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/Aeolipile.java b/Mage.Sets/src/mage/sets/fallenempires/Aeolipile.java new file mode 100644 index 00000000000..e17cda959c3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/Aeolipile.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fallenempires; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Aeolipile extends mage.sets.masterseditionii.Aeolipile { + + public Aeolipile(UUID ownerId) { + super(ownerId); + this.cardNumber = 166; + this.expansionSetCode = "FEM"; + this.rarity = Rarity.RARE; + } + + public Aeolipile(final Aeolipile card) { + super(card); + } + + @Override + public Aeolipile copy() { + return new Aeolipile(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/BalmOfRestoration.java b/Mage.Sets/src/mage/sets/fallenempires/BalmOfRestoration.java new file mode 100644 index 00000000000..cbb123398ac --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/BalmOfRestoration.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fallenempires; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class BalmOfRestoration extends CardImpl { + + public BalmOfRestoration(UUID ownerId) { + super(ownerId, 167, "Balm of Restoration", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "FEM"; + + // {1}, {tap}, Sacrifice Balm of Restoration: Choose one - You gain 2 life; + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainLifeEffect(2), new GenericManaCost(1)); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + + // or prevent the next 2 damage that would be dealt to target creature or player this turn. + Mode mode = new Mode(); + mode.getEffects().add(new PreventDamageToTargetEffect(Duration.EndOfTurn, 2)); + mode.getTargets().add(new TargetCreatureOrPlayer()); + ability.addMode(mode); + + this.addAbility(ability); + } + + public BalmOfRestoration(final BalmOfRestoration card) { + super(card); + } + + @Override + public BalmOfRestoration copy() { + return new BalmOfRestoration(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/BottomlessVault.java b/Mage.Sets/src/mage/sets/fallenempires/BottomlessVault.java index 85705452450..277cc93571a 100644 --- a/Mage.Sets/src/mage/sets/fallenempires/BottomlessVault.java +++ b/Mage.Sets/src/mage/sets/fallenempires/BottomlessVault.java @@ -35,7 +35,9 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.SourceTappedCondition; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -67,10 +69,14 @@ public class BottomlessVault extends CardImpl { Effect effect = new ConditionalOneShotEffect(addStorageCounter, SourceTappedCondition.getInstance(), "if {this} is tapped, put a storage counter on it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // {tap}, Remove any number of storage counters from Bottomless Vault: Add {B} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.BlackMana, new RemovedCountersForCostValue(), - "Add {B} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.BlackMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {B} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/fallenempires/HollowTrees.java b/Mage.Sets/src/mage/sets/fallenempires/HollowTrees.java index f14cdd1f50b..9253c1fc4f3 100644 --- a/Mage.Sets/src/mage/sets/fallenempires/HollowTrees.java +++ b/Mage.Sets/src/mage/sets/fallenempires/HollowTrees.java @@ -35,7 +35,9 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.SourceTappedCondition; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -67,10 +69,14 @@ public class HollowTrees extends CardImpl { Effect effect = new ConditionalOneShotEffect(addStorageCounter, SourceTappedCondition.getInstance(), "if {this} is tapped, put a storage counter on it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // {tap}, Remove any number of storage counters from Hollow Trees: Add {G} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.BlackMana, new RemovedCountersForCostValue(), - "Add {B} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.GreenMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {G} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/fallenempires/IcatianJavelineers2.java b/Mage.Sets/src/mage/sets/fallenempires/IcatianJavelineers2.java index 793fe6afae1..8bad3390ef6 100644 --- a/Mage.Sets/src/mage/sets/fallenempires/IcatianJavelineers2.java +++ b/Mage.Sets/src/mage/sets/fallenempires/IcatianJavelineers2.java @@ -25,10 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ -package mage.sets.timeshifted; +package mage.sets.fallenempires; import java.util.UUID; -import mage.constants.Rarity; /** * diff --git a/Mage.Sets/src/mage/sets/fallenempires/IcatianStore.java b/Mage.Sets/src/mage/sets/fallenempires/IcatianStore.java index ad30635e7ef..0fbec1161d9 100644 --- a/Mage.Sets/src/mage/sets/fallenempires/IcatianStore.java +++ b/Mage.Sets/src/mage/sets/fallenempires/IcatianStore.java @@ -35,7 +35,9 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.SourceTappedCondition; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -67,10 +69,14 @@ public class IcatianStore extends CardImpl { Effect effect = new ConditionalOneShotEffect(addStorageCounter, SourceTappedCondition.getInstance(), "if {this} is tapped, put a storage counter on it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // {tap}, Remove any number of storage counters from Icatian Store: Add {W} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.WhiteMana, new RemovedCountersForCostValue(), - "Add {W} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.WhiteMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {W} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/fallenempires/ImplementsOfSacrifice.java b/Mage.Sets/src/mage/sets/fallenempires/ImplementsOfSacrifice.java new file mode 100644 index 00000000000..87fb0dbdc03 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ImplementsOfSacrifice.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fallenempires; + +import java.util.UUID; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AddManaOfAnyColorEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class ImplementsOfSacrifice extends CardImpl { + + public ImplementsOfSacrifice(UUID ownerId) { + super(ownerId, 173, "Implements of Sacrifice", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "FEM"; + + // {1}, {tap}, Sacrifice Implements of Sacrifice: Add two mana of any one color to your mana pool. + SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(2), new ManaCostsImpl("{1}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + this.addAbility(ability); + } + + public ImplementsOfSacrifice(final ImplementsOfSacrifice card) { + super(card); + } + + @Override + public ImplementsOfSacrifice copy() { + return new ImplementsOfSacrifice(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/RainbowVale.java b/Mage.Sets/src/mage/sets/fallenempires/RainbowVale.java new file mode 100644 index 00000000000..6a63f8a1244 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/RainbowVale.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fallenempires; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class RainbowVale extends mage.sets.mastersedition.RainbowVale { + + public RainbowVale(UUID ownerId) { + super(ownerId); + this.cardNumber = 184; + this.expansionSetCode = "FEM"; + } + + public RainbowVale(final RainbowVale card) { + super(card); + } + + @Override + public RainbowVale copy() { + return new RainbowVale(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/Seasinger.java b/Mage.Sets/src/mage/sets/fallenempires/Seasinger.java index d5e757065c7..3ded18de716 100644 --- a/Mage.Sets/src/mage/sets/fallenempires/Seasinger.java +++ b/Mage.Sets/src/mage/sets/fallenempires/Seasinger.java @@ -32,7 +32,7 @@ import java.util.UUID; import mage.constants.*; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; @@ -42,13 +42,13 @@ import mage.abilities.decorator.ConditionalContinuousEffect; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.continuous.GainControlTargetEffect; import mage.cards.CardImpl; +import mage.filter.Filter; import mage.filter.FilterPermanent; import mage.filter.common.FilterCreaturePermanent; +import mage.filter.common.FilterLandPermanent; import mage.filter.predicate.mageobject.CardIdPredicate; import mage.filter.predicate.mageobject.SubtypePredicate; import mage.filter.predicate.permanent.ControllerPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; import mage.target.common.TargetCreaturePermanent; import mage.filter.predicate.permanent.ControllerControlsIslandPredicate; @@ -80,7 +80,9 @@ public class Seasinger extends CardImpl { seasinger.add(new CardIdPredicate(this.getId())); // When you control no Islands, sacrifice Seasinger. - this.addAbility(new SeasingerTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); // You may choose not to untap Seasinger during your untap step. this.addAbility(new SkipUntapOptionalAbility()); @@ -104,29 +106,3 @@ public class Seasinger extends CardImpl { return new Seasinger(this); } } - -class SeasingerTriggeredAbility extends StateTriggeredAbility { - - public SeasingerTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - public SeasingerTriggeredAbility(final SeasingerTriggeredAbility ability) { - super(ability); - } - - @Override - public SeasingerTriggeredAbility copy() { - return new SeasingerTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return (game.getBattlefield().countAll(ControllerControlsIslandPredicate.filter, controllerId, game) == 0); - } - - @Override - public String getRule() { - return "When you control no islands, sacrifice {this}."; - } -} diff --git a/Mage.Sets/src/mage/sets/fallenempires/VodalianKnights.java b/Mage.Sets/src/mage/sets/fallenempires/VodalianKnights.java new file mode 100644 index 00000000000..54ea81b3d42 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/VodalianKnights.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fallenempires; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class VodalianKnights extends CardImpl { + + public VodalianKnights(UUID ownerId) { + super(ownerId, 58, "Vodalian Knights", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Merfolk"); + this.subtype.add("Knight"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + + // Vodalian Knights can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // When you control no Islands, sacrifice Vodalian Knights. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + + // {U}: Vodalian Knights gains flying until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{U}"))); + } + + public VodalianKnights(final VodalianKnights card) { + super(card); + } + + @Override + public VodalianKnights copy() { + return new VodalianKnights(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fatereforged/FlamewakePhoenix.java b/Mage.Sets/src/mage/sets/fatereforged/FlamewakePhoenix.java index 6253286a82a..64c1c219294 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/FlamewakePhoenix.java +++ b/Mage.Sets/src/mage/sets/fatereforged/FlamewakePhoenix.java @@ -71,8 +71,7 @@ public class FlamewakePhoenix extends CardImpl { new DoIfCostPaid(new ReturnToBattlefieldUnderOwnerControlSourceEffect(), new ManaCostsImpl("{R")), TargetController.YOU, false, false), FerociousCondition.getInstance(), - "Ferocious — At the beginning of combat on your turn, if you control a creature with power 4 or greater, you may pay {R}. If you do, return {this} from your graveyard to the battlefield.", - false + "Ferocious — At the beginning of combat on your turn, if you control a creature with power 4 or greater, you may pay {R}. If you do, return {this} from your graveyard to the battlefield." )); } diff --git a/Mage.Sets/src/mage/sets/fatereforged/FrontierSiege.java b/Mage.Sets/src/mage/sets/fatereforged/FrontierSiege.java index af1e120216e..f02ca1e3c0b 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/FrontierSiege.java +++ b/Mage.Sets/src/mage/sets/fatereforged/FrontierSiege.java @@ -76,8 +76,8 @@ public class FrontierSiege extends CardImpl { this.expansionSetCode = "FRF"; // As Frontier Siege enters the battlefield, choose Khans or Dragons. - this.addAbility(new EntersBattlefieldAbility(new ChooseModeEffect("Khans or Dragons?","Khans", "Dragons"),null, true, - "As {this} enters the battlefield, choose Khans or Dragons.","")); + this.addAbility(new EntersBattlefieldAbility(new ChooseModeEffect("Khans or Dragons?", "Khans", "Dragons"), null, true, + "As {this} enters the battlefield, choose Khans or Dragons.", "")); // * Khans - At the beginning of each of your main phases, add {G}{G} to your mana pool. this.addAbility(new ConditionalTriggeredAbility( @@ -89,7 +89,7 @@ public class FrontierSiege extends CardImpl { Ability ability2 = new ConditionalTriggeredAbility( new EntersBattlefieldControlledTriggeredAbility(Zone.BATTLEFIELD, new FrontierSiegeFightEffect(), filter, true, SetTargetPointer.PERMANENT, ""), new ModeChoiceSourceCondition("Dragons"), - ruleTrigger2, true); + ruleTrigger2); ability2.addTarget(new TargetCreaturePermanent(filter2)); this.addAbility(ability2); @@ -108,7 +108,7 @@ public class FrontierSiege extends CardImpl { class FrontierSiegeKhansTriggeredAbility extends TriggeredAbilityImpl { public FrontierSiegeKhansTriggeredAbility() { - super(Zone.BATTLEFIELD, new AddManaToManaPoolSourceControllerEffect(new Mana(0,2,0,0,0,0,0)), false); + super(Zone.BATTLEFIELD, new AddManaToManaPoolSourceControllerEffect(new Mana(0, 2, 0, 0, 0, 0, 0)), false); } diff --git a/Mage.Sets/src/mage/sets/fatereforged/MindscourDragon.java b/Mage.Sets/src/mage/sets/fatereforged/MindscourDragon.java index 6e4002d8703..919fef0d1c8 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/MindscourDragon.java +++ b/Mage.Sets/src/mage/sets/fatereforged/MindscourDragon.java @@ -30,7 +30,7 @@ package mage.sets.fatereforged; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.PutLibraryIntoGraveTargetEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; @@ -53,7 +53,7 @@ public class MindscourDragon extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); - + // Whenever Mindscour Dragon deals combat damage to an opponent, target player puts the top four cards of his or her library into his or her graveyard. Ability ability = new DealsDamageToOpponentTriggeredAbility(new PutLibraryIntoGraveTargetEffect(4), false, true); ability.addTarget(new TargetPlayer()); diff --git a/Mage.Sets/src/mage/sets/fatereforged/RallyTheAncestors.java b/Mage.Sets/src/mage/sets/fatereforged/RallyTheAncestors.java index bd820c79eb1..100549a277a 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/RallyTheAncestors.java +++ b/Mage.Sets/src/mage/sets/fatereforged/RallyTheAncestors.java @@ -34,8 +34,8 @@ import mage.abilities.DelayedTriggeredAbility; import mage.abilities.common.delayed.AtTheBeginOfYourNextUpkeepDelayedTriggeredAbility; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.ExileTargetEffect; import mage.abilities.effects.common.ExileSpellEffect; +import mage.abilities.effects.common.ExileTargetEffect; import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; @@ -76,21 +76,21 @@ public class RallyTheAncestors extends CardImpl { } class RallyTheAncestorsEffect extends OneShotEffect { - + RallyTheAncestorsEffect() { super(Outcome.PutCreatureInPlay); this.staticText = "Return each creature card with converted mana cost X or less from your graveyard to the battlefield. Exile those creatures at the beginning of your next upkeep"; } - + RallyTheAncestorsEffect(final RallyTheAncestorsEffect effect) { super(effect); } - + @Override public RallyTheAncestorsEffect copy() { return new RallyTheAncestorsEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getControllerId()); @@ -101,14 +101,15 @@ class RallyTheAncestorsEffect extends OneShotEffect { Set cards = player.getGraveyard().getCards(filter, game); for (Card card : cards) { if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.GRAVEYARD, source.getSourceId()); - Effect exileEffect = new ExileTargetEffect("Exile those creatures at the beginning of your next upkeep"); - exileEffect.setTargetPointer(new FixedTarget(card.getId())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfYourNextUpkeepDelayedTriggeredAbility(exileEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + if (player.putOntoBattlefieldWithInfo(card, game, Zone.GRAVEYARD, source.getSourceId())) { + Effect exileEffect = new ExileTargetEffect("Exile those creatures at the beginning of your next upkeep"); + exileEffect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfYourNextUpkeepDelayedTriggeredAbility(exileEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } } } return true; diff --git a/Mage.Sets/src/mage/sets/fatereforged/RenownedWeaponsmith.java b/Mage.Sets/src/mage/sets/fatereforged/RenownedWeaponsmith.java index 1797c0979be..f82c282471f 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/RenownedWeaponsmith.java +++ b/Mage.Sets/src/mage/sets/fatereforged/RenownedWeaponsmith.java @@ -115,7 +115,7 @@ class RenownedWeaponsmithCondition implements Condition { @Override public boolean apply(Game game, Ability source) { MageObject object = game.getObject(source.getSourceId()); - return (object != null + return (object != null && object.getCardType().contains(CardType.ARTIFACT)); } } @@ -149,8 +149,8 @@ class RenownedWeaponsmithEffect extends OneShotEffect { Card card = game.getCard(target.getFirstTarget()); Cards revealed = new CardsImpl(); revealed.add(card); - controller.revealCards(sourceObject.getName(), revealed, game); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.revealCards(sourceObject.getIdName(), revealed, game); + controller.moveCards(revealed, null, Zone.HAND, source, game); } } controller.shuffleLibrary(game); diff --git a/Mage.Sets/src/mage/sets/fatereforged/SageEyeAvengers.java b/Mage.Sets/src/mage/sets/fatereforged/SageEyeAvengers.java index f14d8c67ae7..191c9540b6b 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/SageEyeAvengers.java +++ b/Mage.Sets/src/mage/sets/fatereforged/SageEyeAvengers.java @@ -100,7 +100,7 @@ class SageEyeAvengersEffect extends OneShotEffect { if (sourceObject != null && controller != null) { Permanent targetCreature = game.getPermanent(getTargetPointer().getFirst(game, source)); if (targetCreature != null && targetCreature.getPower().getValue() < sourceObject.getPower().getValue()) { - controller.moveCardToHandWithInfo(targetCreature, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(targetCreature, null, Zone.HAND, source, game); } return true; } diff --git a/Mage.Sets/src/mage/sets/fatereforged/SoulfireGrandMaster.java b/Mage.Sets/src/mage/sets/fatereforged/SoulfireGrandMaster.java index 00b2744e19f..55fb26acdff 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/SoulfireGrandMaster.java +++ b/Mage.Sets/src/mage/sets/fatereforged/SoulfireGrandMaster.java @@ -130,28 +130,28 @@ class GainAbilitySpellsEffect extends ContinuousEffectImpl { Player player = game.getPlayer(source.getControllerId()); Permanent permanent = game.getPermanent(source.getSourceId()); if (player != null && permanent != null) { - for (Card card: game.getExile().getAllCards(game)) { + for (Card card : game.getExile().getAllCards(game)) { if (card.getOwnerId().equals(source.getControllerId()) && filter.match(card, game)) { game.getState().addOtherAbility(card, ability); } } - for (Card card: player.getLibrary().getCards(game)) { + for (Card card : player.getLibrary().getCards(game)) { if (filter.match(card, game)) { game.getState().addOtherAbility(card, ability); } } - for (Card card: player.getHand().getCards(game)) { + for (Card card : player.getHand().getCards(game)) { if (filter.match(card, game)) { game.getState().addOtherAbility(card, ability); } } - for (Card card: player.getGraveyard().getCards(game)) { + for (Card card : player.getGraveyard().getCards(game)) { if (filter.match(card, game)) { game.getState().addOtherAbility(card, ability); } } for (StackObject stackObject : game.getStack()) { - if (stackObject.getControllerId().equals(source.getControllerId())) { + if (stackObject.getControllerId().equals(source.getControllerId())) { Card card = game.getCard(stackObject.getSourceId()); if (card != null && filter.match(card, game)) { if (!card.getAbilities().contains(ability)) { @@ -199,15 +199,15 @@ class SoulfireGrandMasterCastFromHandReplacementEffect extends ReplacementEffect @Override public boolean replaceEvent(GameEvent event, Ability source, Game game) { - MageObject mageObject = game.getObject(spellId); - if (mageObject == null || !(mageObject instanceof Spell) || ((Spell)mageObject).isCopiedSpell()) { + MageObject mageObject = game.getObject(spellId); + if (mageObject == null || !(mageObject instanceof Spell) || ((Spell) mageObject).isCopiedSpell()) { return false; } else { Card sourceCard = game.getCard(spellId); if (sourceCard != null) { Player player = game.getPlayer(sourceCard.getOwnerId()); if (player != null) { - player.moveCardToHandWithInfo(sourceCard, source.getSourceId(), game, Zone.STACK); + player.moveCards(sourceCard, null, Zone.HAND, source, game); discard(); return true; } @@ -215,6 +215,7 @@ class SoulfireGrandMasterCastFromHandReplacementEffect extends ReplacementEffect } return false; } + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.ZONE_CHANGE; @@ -225,21 +226,21 @@ class SoulfireGrandMasterCastFromHandReplacementEffect extends ReplacementEffect //Something hit the stack from the hand, see if its a spell with this ability. ZoneChangeEvent zEvent = (ZoneChangeEvent) event; if (spellId == null && // because this effect works only once, spellId has to be null here - zEvent.getFromZone() == Zone.HAND && - zEvent.getToZone() == Zone.STACK && - event.getPlayerId().equals(source.getControllerId())) { + zEvent.getFromZone() == Zone.HAND + && zEvent.getToZone() == Zone.STACK + && event.getPlayerId().equals(source.getControllerId())) { MageObject object = game.getObject(event.getTargetId()); if (object instanceof Card) { - if (filter.match((Card)object, game)) { + if (filter.match((Card) object, game)) { this.spellId = event.getTargetId(); } } } else { // the spell goes to graveyard now so move it to hand again - if (zEvent.getFromZone() == Zone.STACK && - zEvent.getToZone() == Zone.GRAVEYARD && - event.getTargetId().equals(spellId)) { - Spell spell = game.getStack().getSpell(spellId); + if (zEvent.getFromZone() == Zone.STACK + && zEvent.getToZone() == Zone.GRAVEYARD + && event.getTargetId().equals(spellId)) { + Spell spell = game.getStack().getSpell(spellId); if (spell != null && !spell.isCountered()) { return true; } diff --git a/Mage.Sets/src/mage/sets/fatereforged/SuddenReclamation.java b/Mage.Sets/src/mage/sets/fatereforged/SuddenReclamation.java index 3d9e62e2566..cb213a637ed 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/SuddenReclamation.java +++ b/Mage.Sets/src/mage/sets/fatereforged/SuddenReclamation.java @@ -33,6 +33,8 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -89,24 +91,26 @@ class SuddenReclamationEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { + Cards cardsToHand = new CardsImpl(); Target target = new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard")); target.setNotTarget(true); - if (target.canChoose(source.getSourceId(), controller.getId(), game) && - controller.chooseTarget(outcome, target, source, game)) { + if (target.canChoose(source.getSourceId(), controller.getId(), game) + && controller.chooseTarget(outcome, target, source, game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + cardsToHand.add(card); } } target = new TargetCardInYourGraveyard(new FilterLandCard("land card from your graveyard")); target.setNotTarget(true); - if (target.canChoose(source.getSourceId(), controller.getId(), game) && - controller.chooseTarget(outcome, target, source, game)) { + if (target.canChoose(source.getSourceId(), controller.getId(), game) + && controller.chooseTarget(outcome, target, source, game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + cardsToHand.add(card); } } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/fatereforged/TasigurTheGoldenFang.java b/Mage.Sets/src/mage/sets/fatereforged/TasigurTheGoldenFang.java index 466312f6bcb..4219bb760d4 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/TasigurTheGoldenFang.java +++ b/Mage.Sets/src/mage/sets/fatereforged/TasigurTheGoldenFang.java @@ -120,7 +120,7 @@ class TasigurTheGoldenFangEffect extends OneShotEffect { opponent.chooseTarget(outcome, target, source, game); Card card = game.getCard(target.getFirstTarget()); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(card, null, Zone.HAND, source, game); } } } diff --git a/Mage.Sets/src/mage/sets/fatereforged/TemurSabertooth.java b/Mage.Sets/src/mage/sets/fatereforged/TemurSabertooth.java index 465bb3dcfda..a953de52613 100644 --- a/Mage.Sets/src/mage/sets/fatereforged/TemurSabertooth.java +++ b/Mage.Sets/src/mage/sets/fatereforged/TemurSabertooth.java @@ -103,13 +103,13 @@ class TemurSabertoothEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - Target target = new TargetPermanent(1,1, filter, true); + Target target = new TargetPermanent(1, 1, filter, true); if (target.canChoose(source.getSourceId(), controller.getId(), game)) { - if (controller.chooseUse(outcome, "Return another creature to hand?", source, game) && - controller.chooseTarget(outcome, target, source, game)) { + if (controller.chooseUse(outcome, "Return another creature to hand?", source, game) + && controller.chooseTarget(outcome, target, source, game)) { Permanent toHand = game.getPermanent(target.getFirstTarget()); if (toHand != null) { - controller.moveCardToHandWithInfo(toHand, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(toHand, null, Zone.HAND, source, game); } game.addEffect(new GainAbilitySourceEffect(IndestructibleAbility.getInstance(), Duration.EndOfTurn), source); } diff --git a/Mage.Sets/src/mage/sets/fifthdawn/DawnsReflection.java b/Mage.Sets/src/mage/sets/fifthdawn/DawnsReflection.java index 8a06a839efe..417381b270e 100644 --- a/Mage.Sets/src/mage/sets/fifthdawn/DawnsReflection.java +++ b/Mage.Sets/src/mage/sets/fifthdawn/DawnsReflection.java @@ -138,7 +138,7 @@ class DawnsReflectionManaEffect extends ManaEffect { Mana mana = new Mana(); for(int i = 0; i < x; i++){ ChoiceColor choiceColor = new ChoiceColor(); - while (controller.isInGame() && !controller.choose(Outcome.Benefit, choiceColor, game)) { + while (controller.canRespond() && !controller.choose(Outcome.Benefit, choiceColor, game)) { } if (choiceColor.getColor().isBlack()) { diff --git a/Mage.Sets/src/mage/sets/fifthedition/BarbedSextant.java b/Mage.Sets/src/mage/sets/fifthedition/BarbedSextant.java new file mode 100644 index 00000000000..39fd118bff4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/BarbedSextant.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class BarbedSextant extends mage.sets.iceage.BarbedSextant { + + public BarbedSextant(UUID ownerId) { + super(ownerId); + this.cardNumber = 351; + this.expansionSetCode = "5ED"; + } + + public BarbedSextant(final BarbedSextant card) { + super(card); + } + + @Override + public BarbedSextant copy() { + return new BarbedSextant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/BlessedWine.java b/Mage.Sets/src/mage/sets/fifthedition/BlessedWine.java new file mode 100644 index 00000000000..2775748e3ea --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/BlessedWine.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class BlessedWine extends CardImpl { + + public BlessedWine(UUID ownerId) { + super(ownerId, 287, "Blessed Wine", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "5ED"; + + // You gain 1 life. + this.getSpellAbility().addEffect(new GainLifeEffect(1)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public BlessedWine(final BlessedWine card) { + super(card); + } + + @Override + public BlessedWine copy() { + return new BlessedWine(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/Crumble.java b/Mage.Sets/src/mage/sets/fifthedition/Crumble.java new file mode 100644 index 00000000000..0611ff890d0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Crumble.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Crumble extends mage.sets.masterseditioniv.Crumble { + + public Crumble(UUID ownerId) { + super(ownerId); + this.cardNumber = 149; + this.expansionSetCode = "5ED"; + this.rarity = Rarity.UNCOMMON; + } + + public Crumble(final Crumble card) { + super(card); + } + + @Override + public Crumble copy() { + return new Crumble(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/Dandan.java b/Mage.Sets/src/mage/sets/fifthedition/Dandan.java index 4d901bd4eee..3d47fc87d5c 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/Dandan.java +++ b/Mage.Sets/src/mage/sets/fifthedition/Dandan.java @@ -29,21 +29,19 @@ package mage.sets.fifthedition; import java.util.UUID; import mage.MageInt; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; import mage.cards.CardImpl; import mage.constants.*; +import mage.filter.Filter; import mage.filter.common.FilterLandPermanent; -import mage.filter.predicate.permanent.ControllerControlsIslandPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; /** * * @author KholdFuzion - + * */ public class Dandan extends CardImpl { @@ -56,10 +54,12 @@ public class Dandan extends CardImpl { this.toughness = new MageInt(1); // Dandan can't attack unless defending player controls an Island. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); - + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + // When you control no Islands, sacrifice Dandan. - this.addAbility(new DandanTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); } public Dandan(final Dandan card) { @@ -71,29 +71,3 @@ public class Dandan extends CardImpl { return new Dandan(this); } } - -class DandanTriggeredAbility extends StateTriggeredAbility { - - public DandanTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - public DandanTriggeredAbility(final DandanTriggeredAbility ability) { - super(ability); - } - - @Override - public DandanTriggeredAbility copy() { - return new DandanTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return (game.getBattlefield().countAll(ControllerControlsIslandPredicate.filter, controllerId, game) == 0); - } - - @Override - public String getRule() { - return "When you control no Islands, sacrifice {this}."; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/fifthedition/Deathgrip.java b/Mage.Sets/src/mage/sets/fifthedition/Deathgrip.java new file mode 100644 index 00000000000..19879354564 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Deathgrip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 16; + this.expansionSetCode = "5ED"; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/DwarvenHold.java b/Mage.Sets/src/mage/sets/fifthedition/DwarvenHold.java index f7e8c8afd0f..ad4bc54a7ab 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/DwarvenHold.java +++ b/Mage.Sets/src/mage/sets/fifthedition/DwarvenHold.java @@ -35,7 +35,9 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.SourceTappedCondition; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -67,10 +69,14 @@ public class DwarvenHold extends CardImpl { Effect effect = new ConditionalOneShotEffect(addStorageCounter, SourceTappedCondition.getInstance(), "if {this} is tapped, put a storage counter on it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // {tap}, Remove any number of storage counters from Dwarven Hold: Add {R} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.RedMana, new RemovedCountersForCostValue(), - "Add {R} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.RedMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {R} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/fifthedition/Enervate.java b/Mage.Sets/src/mage/sets/fifthedition/Enervate.java new file mode 100644 index 00000000000..b89b480d39f --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Enervate.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Enervate extends mage.sets.masterseditionii.Enervate { + + public Enervate(UUID ownerId) { + super(ownerId); + this.cardNumber = 84; + this.expansionSetCode = "5ED"; + } + + public Enervate(final Enervate card) { + super(card); + } + + @Override + public Enervate copy() { + return new Enervate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/EvilEyeOfOrmsByGore.java b/Mage.Sets/src/mage/sets/fifthedition/EvilEyeOfOrmsByGore.java index dbf4cce772d..d3b7008d0c8 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/EvilEyeOfOrmsByGore.java +++ b/Mage.Sets/src/mage/sets/fifthedition/EvilEyeOfOrmsByGore.java @@ -29,6 +29,7 @@ package mage.sets.fifthedition; import java.util.UUID; import mage.MageInt; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.combat.CantAttackAnyPlayerAllEffect; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; @@ -70,7 +71,7 @@ public class EvilEyeOfOrmsByGore extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackAnyPlayerAllEffect(Duration.WhileOnBattlefield, cantAttackFilter))); // Evil Eye of Orms-by-Gore can't be blocked except by Walls. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(cantBeBlockedByFilter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(cantBeBlockedByFilter, Duration.WhileOnBattlefield))); } public EvilEyeOfOrmsByGore(final EvilEyeOfOrmsByGore card) { diff --git a/Mage.Sets/src/mage/sets/fifthedition/Flare.java b/Mage.Sets/src/mage/sets/fifthedition/Flare.java new file mode 100644 index 00000000000..9a11b49dbd9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Flare.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class Flare extends CardImpl { + + public Flare(UUID ownerId) { + super(ownerId, 11, "Flare", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); + this.expansionSetCode = "5ED"; + + // Flare deals 1 damage to target creature or player. + this.getSpellAbility().addEffect(new DamageTargetEffect(1)); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Flare(final Flare card) { + super(card); + } + + @Override + public Flare copy() { + return new Flare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/IslandSanctuary.java b/Mage.Sets/src/mage/sets/fifthedition/IslandSanctuary.java new file mode 100644 index 00000000000..096725df9c9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 315; + this.expansionSetCode = "5ED"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/KrovikanFetish.java b/Mage.Sets/src/mage/sets/fifthedition/KrovikanFetish.java new file mode 100644 index 00000000000..b0737e4e546 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/KrovikanFetish.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class KrovikanFetish extends CardImpl { + + public KrovikanFetish(UUID ownerId) { + super(ownerId, 34, "Krovikan Fetish", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "5ED"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // When Krovikan Fetish enters the battlefield, draw a card at the beginning of the next turn's upkeep. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1), false)); + + // Enchanted creature gets +1/+1. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield))); + } + + public KrovikanFetish(final KrovikanFetish card) { + super(card); + } + + @Override + public KrovikanFetish copy() { + return new KrovikanFetish(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/MindRavel.java b/Mage.Sets/src/mage/sets/fifthedition/MindRavel.java new file mode 100644 index 00000000000..403a463d34b --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/MindRavel.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class MindRavel extends CardImpl { + + public MindRavel(UUID ownerId) { + super(ownerId, 38, "Mind Ravel", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{B}"); + this.expansionSetCode = "5ED"; + + // Target player discards a card. + this.getSpellAbility().addEffect(new DiscardTargetEffect(1)); + this.getSpellAbility().addTarget(new TargetPlayer()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public MindRavel(final MindRavel card) { + super(card); + } + + @Override + public MindRavel copy() { + return new MindRavel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/Panic.java b/Mage.Sets/src/mage/sets/fifthedition/Panic.java new file mode 100644 index 00000000000..589256a6c08 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Panic.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Panic extends mage.sets.masterseditionii.Panic { + + public Panic(UUID ownerId) { + super(ownerId); + this.cardNumber = 260; + this.expansionSetCode = "5ED"; + } + + public Panic(final Panic card) { + super(card); + } + + @Override + public Panic copy() { + return new Panic(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/PrimalClay.java b/Mage.Sets/src/mage/sets/fifthedition/PrimalClay.java index 5ccc37709e5..561def505a0 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/PrimalClay.java +++ b/Mage.Sets/src/mage/sets/fifthedition/PrimalClay.java @@ -29,13 +29,13 @@ package mage.sets.fifthedition; import java.util.UUID; import mage.MageInt; -import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; import mage.abilities.keyword.DefenderAbility; import mage.abilities.keyword.FlyingAbility; -import mage.cards.Card; import mage.cards.CardImpl; import mage.choices.Choice; import mage.choices.ChoiceImpl; @@ -48,9 +48,6 @@ import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; -import mage.game.permanent.PermanentCard; -import mage.game.permanent.PermanentToken; -import mage.game.permanent.token.Token; import mage.players.Player; /** @@ -122,49 +119,38 @@ class PrimalPlasmaReplacementEffect extends ReplacementEffectImpl { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { Choice choice = new ChoiceImpl(true); - choice.setMessage("Choose what the creature becomes to"); + choice.setMessage("Choose what " + permanent.getIdName() + " becomes to"); choice.getChoices().add(choice33); choice.getChoices().add(choice22); choice.getChoices().add(choice16); Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - while(!choice.isChosen()) { + while (!choice.isChosen()) { controller.choose(Outcome.Neutral, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } } - MageObject mageObject; - if (permanent instanceof PermanentCard) { - mageObject = ((PermanentCard) permanent).getCard(); - } else { - mageObject = ((PermanentToken) permanent).getToken(); - } + int power = 0; + int toughness = 0; switch (choice.getChoice()) { case choice33: - mageObject.getPower().setValue(3); - mageObject.getToughness().setValue(3); + power = 3; + toughness = 3; break; case choice22: - mageObject.getPower().setValue(2); - mageObject.getToughness().setValue(2); - if (mageObject instanceof Card) { - game.getState().addOtherAbility((Card)mageObject, FlyingAbility.getInstance()); - } else { - ((Token)mageObject).addAbility(FlyingAbility.getInstance()); - } + power = 2; + toughness = 2; + game.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.Custom), source); break; case choice16: - mageObject.getPower().setValue(1); - mageObject.getToughness().setValue(6); - if (mageObject instanceof Card) { - game.getState().addOtherAbility((Card)mageObject, DefenderAbility.getInstance()); - } else { - ((Token)mageObject).addAbility(DefenderAbility.getInstance()); - } + power = 1; + toughness = 6; + game.addEffect(new GainAbilitySourceEffect(DefenderAbility.getInstance(), Duration.Custom), source); break; } + game.addEffect(new SetPowerToughnessSourceEffect(power, toughness, Duration.Custom), source); } return false; diff --git a/Mage.Sets/src/mage/sets/fifthedition/Recall.java b/Mage.Sets/src/mage/sets/fifthedition/Recall.java index cbbb5e68973..ff5e44b188d 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/Recall.java +++ b/Mage.Sets/src/mage/sets/fifthedition/Recall.java @@ -31,8 +31,9 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ExileSpellEffect; -import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -52,7 +53,6 @@ public class Recall extends CardImpl { super(ownerId, 93, "Recall", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{X}{X}{U}"); this.expansionSetCode = "5ED"; - // Discard X cards, then return a card from your graveyard to your hand for each card discarded this way. this.getSpellAbility().addEffect(new RecallEffect()); // Exile Recall. @@ -75,38 +75,33 @@ class RecallEffect extends OneShotEffect { super(Outcome.ReturnToHand); this.staticText = "Discard X cards, then return a card from your graveyard to your hand for each card discarded this way. "; } - + public RecallEffect(final RecallEffect effect) { super(effect); } - + @Override public RecallEffect copy() { return new RecallEffect(this); } - + @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { // Discard X cards - int amount = source.getManaCostsToPay().getX(); - int discarded = Math.min(amount, player.getHand().size()); - player.discard(amount, false, source, game); - - // then return a card from your graveyard to your hand for each card discarded this way - TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(discarded, new FilterCard()); - target.choose(Outcome.ReturnToHand, player.getId(), source.getSourceId(), game); - for (UUID targetId : target.getTargets()) { - Card card = game.getCard(targetId); - if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } + Cards cardsDiscarded = controller.discard(source.getManaCostsToPay().getX(), false, source, game); + if (!cardsDiscarded.isEmpty()) { + // then return a card from your graveyard to your hand for each card discarded this way + TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(cardsDiscarded.size(), new FilterCard()); + target.setNotTarget(true); + target.choose(Outcome.ReturnToHand, controller.getId(), source.getSourceId(), game); + controller.moveCards(new CardsImpl(target.getTargets()), null, Zone.HAND, source, game); } - + return true; } return false; } - + } diff --git a/Mage.Sets/src/mage/sets/fifthedition/SandSilos.java b/Mage.Sets/src/mage/sets/fifthedition/SandSilos.java index 7e8a942094e..bbc58406a2f 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/SandSilos.java +++ b/Mage.Sets/src/mage/sets/fifthedition/SandSilos.java @@ -35,7 +35,9 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SkipUntapOptionalAbility; import mage.abilities.condition.common.SourceTappedCondition; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; @@ -67,10 +69,14 @@ public class SandSilos extends CardImpl { Effect effect = new ConditionalOneShotEffect(addStorageCounter, SourceTappedCondition.getInstance(), "if {this} is tapped, put a storage counter on it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); // {tap}, Remove any number of storage counters from Sand Silos: Add {U} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.BlueMana, new RemovedCountersForCostValue(), - "Add {U} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.BlueMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {U} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/fifthedition/SylvanLibrary.java b/Mage.Sets/src/mage/sets/fifthedition/SylvanLibrary.java index 107198b3830..e6d7c57a60e 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/SylvanLibrary.java +++ b/Mage.Sets/src/mage/sets/fifthedition/SylvanLibrary.java @@ -130,7 +130,7 @@ class SylvanLibraryEffect extends OneShotEffect { int numberOfCardsToPutBack = cardsPutBack.size(); if (numberOfCardsToPutBack > 1) { TargetCard target2 = new TargetCard(Zone.PICK, new FilterCard("card to put on the top of your library (last chosen will be on top)")); - while (controller.isInGame() && cardsPutBack.size() > 1) { + while (controller.canRespond() && cardsPutBack.size() > 1) { controller.choose(Outcome.Benefit, cardsPutBack, target2, game); Card card = cardsPutBack.get(target2.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/fifthedition/TimeBomb.java b/Mage.Sets/src/mage/sets/fifthedition/TimeBomb.java new file mode 100644 index 00000000000..02b17e3aa86 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/TimeBomb.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class TimeBomb extends mage.sets.masterseditionii.TimeBomb { + + public TimeBomb(UUID ownerId) { + super(ownerId); + this.cardNumber = 404; + this.expansionSetCode = "5ED"; + } + + public TimeBomb(final TimeBomb card) { + super(card); + } + + @Override + public TimeBomb copy() { + return new TimeBomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/TouchOfDeath.java b/Mage.Sets/src/mage/sets/fifthedition/TouchOfDeath.java new file mode 100644 index 00000000000..7b1768d4d94 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/TouchOfDeath.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class TouchOfDeath extends mage.sets.iceage.TouchOfDeath { + + public TouchOfDeath(UUID ownerId) { + super(ownerId); + this.cardNumber = 62; + this.expansionSetCode = "5ED"; + } + + public TouchOfDeath(final TouchOfDeath card) { + super(card); + } + + @Override + public TouchOfDeath copy() { + return new TouchOfDeath(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/Updraft.java b/Mage.Sets/src/mage/sets/fifthedition/Updraft.java new file mode 100644 index 00000000000..7b8982eed8d --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/Updraft.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fifthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Updraft extends mage.sets.iceage.Updraft { + + public Updraft(UUID ownerId) { + super(ownerId); + this.cardNumber = 133; + this.expansionSetCode = "5ED"; + this.rarity = Rarity.COMMON; + } + + public Updraft(final Updraft card) { + super(card); + } + + @Override + public Updraft copy() { + return new Updraft(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/UrzasMine.java b/Mage.Sets/src/mage/sets/fifthedition/UrzasMine.java index b23c2be148a..9d1bb0ab1d5 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/UrzasMine.java +++ b/Mage.Sets/src/mage/sets/fifthedition/UrzasMine.java @@ -28,13 +28,13 @@ package mage.sets.fifthedition; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.Mana; import mage.abilities.Ability; import mage.abilities.dynamicvalue.common.UrzaTerrainValue; import mage.abilities.mana.DynamicManaAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * @@ -43,7 +43,8 @@ import mage.cards.CardImpl; public class UrzasMine extends CardImpl { public UrzasMine(UUID ownerId) { super(ownerId, 447, "Urza's Mine", Rarity.COMMON, new CardType[]{CardType.LAND}, ""); - this.subtype.add("Urza's Mine"); + this.subtype.add("Urza's"); + this.subtype.add("Mine"); this.expansionSetCode = "5ED"; // {T}: Add {1} to your mana pool. If you control an Urza's Power-Plant and an Urza's Tower, add {2} to your mana pool instead. diff --git a/Mage.Sets/src/mage/sets/fifthedition/UrzasPowerPlant.java b/Mage.Sets/src/mage/sets/fifthedition/UrzasPowerPlant.java index dfa679c2fd5..4690665b40c 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/UrzasPowerPlant.java +++ b/Mage.Sets/src/mage/sets/fifthedition/UrzasPowerPlant.java @@ -28,13 +28,13 @@ package mage.sets.fifthedition; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.Mana; import mage.abilities.Ability; import mage.abilities.dynamicvalue.common.UrzaTerrainValue; import mage.abilities.mana.DynamicManaAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * @@ -43,7 +43,8 @@ import mage.cards.CardImpl; public class UrzasPowerPlant extends CardImpl { public UrzasPowerPlant(UUID ownerId) { super(ownerId, 448, "Urza's Power Plant", Rarity.COMMON, new CardType[]{CardType.LAND}, ""); - this.subtype.add("Urza's Power-Plant"); + this.subtype.add("Urza's"); + this.subtype.add("Power-Plant"); this.expansionSetCode = "5ED"; // {T}: Add {1} to your mana pool. If you control an Urza's Mine and an Urza's Tower, add {2} to your mana pool instead. diff --git a/Mage.Sets/src/mage/sets/fifthedition/UrzasTower.java b/Mage.Sets/src/mage/sets/fifthedition/UrzasTower.java index 0fab9d741cb..1096b1dd5e0 100644 --- a/Mage.Sets/src/mage/sets/fifthedition/UrzasTower.java +++ b/Mage.Sets/src/mage/sets/fifthedition/UrzasTower.java @@ -28,13 +28,13 @@ package mage.sets.fifthedition; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.Mana; import mage.abilities.Ability; import mage.abilities.dynamicvalue.common.UrzaTerrainValue; import mage.abilities.mana.DynamicManaAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * @@ -43,7 +43,8 @@ import mage.cards.CardImpl; public class UrzasTower extends CardImpl { public UrzasTower(UUID ownerId) { super(ownerId, 449, "Urza's Tower", Rarity.COMMON, new CardType[]{CardType.LAND}, ""); - this.subtype.add("Urza's Tower"); + this.subtype.add("Urza's"); + this.subtype.add("Tower"); this.expansionSetCode = "5ED"; // {T}: Add {1} to your mana pool. If you control an Urza's Mine and an Urza's Power-Plant, add {3} to your mana pool instead. diff --git a/Mage.Sets/src/mage/sets/fourthedition/Channel.java b/Mage.Sets/src/mage/sets/fourthedition/Channel.java new file mode 100644 index 00000000000..1eba2a06f51 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/Channel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 120; + this.expansionSetCode = "4ED"; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/Crumble.java b/Mage.Sets/src/mage/sets/fourthedition/Crumble.java new file mode 100644 index 00000000000..18d5931db03 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/Crumble.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Crumble extends mage.sets.masterseditioniv.Crumble { + + public Crumble(UUID ownerId) { + super(ownerId); + this.cardNumber = 123; + this.expansionSetCode = "4ED"; + this.rarity = Rarity.UNCOMMON; + } + + public Crumble(final Crumble card) { + super(card); + } + + @Override + public Crumble copy() { + return new Crumble(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/Deathgrip.java b/Mage.Sets/src/mage/sets/fourthedition/Deathgrip.java new file mode 100644 index 00000000000..a99ff56436a --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/Deathgrip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 14; + this.expansionSetCode = "4ED"; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/ElHajjaj.java b/Mage.Sets/src/mage/sets/fourthedition/ElHajjaj.java new file mode 100644 index 00000000000..a8a7adba105 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/ElHajjaj.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ElHajjaj extends mage.sets.arabiannights.ElHajjaj { + + public ElHajjaj(UUID ownerId) { + super(ownerId); + this.cardNumber = 18; + this.expansionSetCode = "4ED"; + } + + public ElHajjaj(final ElHajjaj card) { + super(card); + } + + @Override + public ElHajjaj copy() { + return new ElHajjaj(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/IslandFishJasconius.java b/Mage.Sets/src/mage/sets/fourthedition/IslandFishJasconius.java new file mode 100644 index 00000000000..fd840a61c28 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/IslandFishJasconius.java @@ -0,0 +1,89 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.DontUntapInControllersUntapStepSourceEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.UntapSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class IslandFishJasconius extends CardImpl { + + public IslandFishJasconius(UUID ownerId) { + super(ownerId, 78, "Island Fish Jasconius", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{U}{U}{U}"); + this.expansionSetCode = "4ED"; + this.subtype.add("Fish"); + this.power = new MageInt(6); + this.toughness = new MageInt(8); + + // Island Fish Jasconius doesn't untap during your untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepSourceEffect())); + + // At the beginning of your upkeep, you may pay {U}{U}{U}. If you do, untap Island Fish Jasconius. + this.addAbility(new BeginningOfUpkeepTriggeredAbility( + Zone.BATTLEFIELD, + new DoIfCostPaid(new UntapSourceEffect(), new ManaCostsImpl("{U}{U}{U}")), + TargetController.YOU, + false)); + + // Island Fish Jasconius can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // When you control no Islands, sacrifice Island Fish Jasconius. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public IslandFishJasconius(final IslandFishJasconius card) { + super(card); + } + + @Override + public IslandFishJasconius copy() { + return new IslandFishJasconius(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/IslandSanctuary.java b/Mage.Sets/src/mage/sets/fourthedition/IslandSanctuary.java new file mode 100644 index 00000000000..430788c2d02 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 281; + this.expansionSetCode = "4ED"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fourthedition/ManaClash.java b/Mage.Sets/src/mage/sets/fourthedition/ManaClash.java index 3af50806837..2491e72b18a 100644 --- a/Mage.Sets/src/mage/sets/fourthedition/ManaClash.java +++ b/Mage.Sets/src/mage/sets/fourthedition/ManaClash.java @@ -86,7 +86,7 @@ class ManaClashEffect extends OneShotEffect { if (controller != null && targetOpponent != null) { boolean bothHeads = false; while (!bothHeads) { - if (!targetOpponent.isInGame() || !controller.isInGame()) { + if (!targetOpponent.canRespond() || !controller.canRespond()) { return false; } boolean controllerFlip = controller.flipCoin(game); diff --git a/Mage.Sets/src/mage/sets/fourthedition/WordOfBinding.java b/Mage.Sets/src/mage/sets/fourthedition/WordOfBinding.java new file mode 100644 index 00000000000..ecdfe11b989 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fourthedition/WordOfBinding.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fourthedition; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class WordOfBinding extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures"); + + public WordOfBinding(UUID ownerId) { + super(ownerId, 56, "Word of Binding", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{X}{B}{B}"); + this.expansionSetCode = "4ED"; + + // Tap X target creatures. + this.getSpellAbility().addEffect(new TapTargetEffect("X target creatures")); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(0, 1,filter, false)); + } + + public WordOfBinding(final WordOfBinding card) { + super(card); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability instanceof SpellAbility) { + ability.getTargets().clear(); + int numberToTap = ability.getManaCostsToPay().getX(); + numberToTap = Math.min(game.getBattlefield().count(filter, ability.getSourceId(), ability.getControllerId(), game), numberToTap); + ability.addTarget(new TargetCreaturePermanent(numberToTap, numberToTap, filter, false)); + } + } + + @Override + public WordOfBinding copy() { + return new WordOfBinding(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fridaynightmagic/UltimatePrice.java b/Mage.Sets/src/mage/sets/fridaynightmagic/UltimatePrice.java new file mode 100644 index 00000000000..a4e9057911a --- /dev/null +++ b/Mage.Sets/src/mage/sets/fridaynightmagic/UltimatePrice.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.fridaynightmagic; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class UltimatePrice extends mage.sets.returntoravnica.UltimatePrice { + + public UltimatePrice(UUID ownerId) { + super(ownerId); + this.cardNumber = 185; + this.expansionSetCode = "FNMP"; + } + + public UltimatePrice(final UltimatePrice card) { + super(card); + } + + @Override + public UltimatePrice copy() { + return new UltimatePrice(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfFury.java b/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfFury.java new file mode 100644 index 00000000000..fef9a68257e --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfFury.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class AkromaAngelOfFury extends mage.sets.commander.AkromaAngelOfFury { + + public AkromaAngelOfFury(UUID ownerId) { + super(ownerId); + this.cardNumber = 1; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public AkromaAngelOfFury(final AkromaAngelOfFury card) { + super(card); + } + + @Override + public AkromaAngelOfFury copy() { + return new AkromaAngelOfFury(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfWrath.java b/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfWrath.java new file mode 100644 index 00000000000..79849812f93 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/AkromaAngelOfWrath.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class AkromaAngelOfWrath extends mage.sets.timeshifted.AkromaAngelOfWrath { + + public AkromaAngelOfWrath(UUID ownerId) { + super(ownerId); + this.cardNumber = 2; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public AkromaAngelOfWrath(final AkromaAngelOfWrath card) { + super(card); + } + + @Override + public AkromaAngelOfWrath copy() { + return new AkromaAngelOfWrath(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/AureliaTheWarleader.java b/Mage.Sets/src/mage/sets/ftvangels/AureliaTheWarleader.java new file mode 100644 index 00000000000..d52f76988dd --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/AureliaTheWarleader.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class AureliaTheWarleader extends mage.sets.gatecrash.AureliaTheWarleader { + + public AureliaTheWarleader(UUID ownerId) { + super(ownerId); + this.cardNumber = 4; + this.expansionSetCode = "V15"; + } + + public AureliaTheWarleader(final AureliaTheWarleader card) { + super(card); + } + + @Override + public AureliaTheWarleader copy() { + return new AureliaTheWarleader(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/AvacynAngelOfHope.java b/Mage.Sets/src/mage/sets/ftvangels/AvacynAngelOfHope.java new file mode 100644 index 00000000000..15fe6961aba --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/AvacynAngelOfHope.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class AvacynAngelOfHope extends mage.sets.avacynrestored.AvacynAngelOfHope { + + public AvacynAngelOfHope(UUID ownerId) { + super(ownerId); + this.cardNumber = 5; + this.expansionSetCode = "V15"; + } + + public AvacynAngelOfHope(final AvacynAngelOfHope card) { + super(card); + } + + @Override + public AvacynAngelOfHope copy() { + return new AvacynAngelOfHope(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/BaneslayerAngel.java b/Mage.Sets/src/mage/sets/ftvangels/BaneslayerAngel.java new file mode 100644 index 00000000000..638203f7bdc --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/BaneslayerAngel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class BaneslayerAngel extends mage.sets.magic2010.BaneslayerAngel { + + public BaneslayerAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 6; + this.expansionSetCode = "V15"; + } + + public BaneslayerAngel(final BaneslayerAngel card) { + super(card); + } + + @Override + public BaneslayerAngel copy() { + return new BaneslayerAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/EntreatTheAngels.java b/Mage.Sets/src/mage/sets/ftvangels/EntreatTheAngels.java new file mode 100644 index 00000000000..e0551dd032b --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/EntreatTheAngels.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class EntreatTheAngels extends mage.sets.avacynrestored.EntreatTheAngels { + + public EntreatTheAngels(UUID ownerId) { + super(ownerId); + this.cardNumber = 7; + this.expansionSetCode = "V15"; + } + + public EntreatTheAngels(final EntreatTheAngels card) { + super(card); + } + + @Override + public EntreatTheAngels copy() { + return new EntreatTheAngels(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/ExaltedAngel.java b/Mage.Sets/src/mage/sets/ftvangels/ExaltedAngel.java new file mode 100644 index 00000000000..c5536b6cb37 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/ExaltedAngel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ExaltedAngel extends mage.sets.onslaught.ExaltedAngel { + + public ExaltedAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 8; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public ExaltedAngel(final ExaltedAngel card) { + super(card); + } + + @Override + public ExaltedAngel copy() { + return new ExaltedAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/IonaShieldOfEmeria.java b/Mage.Sets/src/mage/sets/ftvangels/IonaShieldOfEmeria.java new file mode 100644 index 00000000000..498697ebd3b --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/IonaShieldOfEmeria.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class IonaShieldOfEmeria extends mage.sets.zendikar.IonaShieldOfEmeria { + + public IonaShieldOfEmeria(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "V15"; + } + + public IonaShieldOfEmeria(final IonaShieldOfEmeria card) { + super(card); + } + + @Override + public IonaShieldOfEmeria copy() { + return new IonaShieldOfEmeria(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/IridescentAngel.java b/Mage.Sets/src/mage/sets/ftvangels/IridescentAngel.java new file mode 100644 index 00000000000..6e1999d1cbf --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/IridescentAngel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class IridescentAngel extends mage.sets.odyssey.IridescentAngel { + + public IridescentAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 10; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public IridescentAngel(final IridescentAngel card) { + super(card); + } + + @Override + public IridescentAngel copy() { + return new IridescentAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/JenaraAsuraOfWar.java b/Mage.Sets/src/mage/sets/ftvangels/JenaraAsuraOfWar.java new file mode 100644 index 00000000000..53c80937a61 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/JenaraAsuraOfWar.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class JenaraAsuraOfWar extends mage.sets.alarareborn.JenaraAsuraOfWar { + + public JenaraAsuraOfWar(UUID ownerId) { + super(ownerId); + this.cardNumber = 11; + this.expansionSetCode = "V15"; + } + + public JenaraAsuraOfWar(final JenaraAsuraOfWar card) { + super(card); + } + + @Override + public JenaraAsuraOfWar copy() { + return new JenaraAsuraOfWar(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/LightningAngel.java b/Mage.Sets/src/mage/sets/ftvangels/LightningAngel.java new file mode 100644 index 00000000000..1b78d96256c --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/LightningAngel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class LightningAngel extends mage.sets.apocalypse.LightningAngel { + + public LightningAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 12; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public LightningAngel(final LightningAngel card) { + super(card); + } + + @Override + public LightningAngel copy() { + return new LightningAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/PlatinumAngel.java b/Mage.Sets/src/mage/sets/ftvangels/PlatinumAngel.java new file mode 100644 index 00000000000..7a4a5812c1f --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/PlatinumAngel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class PlatinumAngel extends mage.sets.tenthedition.PlatinumAngel { + + public PlatinumAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 13; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public PlatinumAngel(final PlatinumAngel card) { + super(card); + } + + @Override + public PlatinumAngel copy() { + return new PlatinumAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/SerraAngel.java b/Mage.Sets/src/mage/sets/ftvangels/SerraAngel.java new file mode 100644 index 00000000000..f9db2c50cc4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/SerraAngel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class SerraAngel extends mage.sets.tenthedition.SerraAngel { + + public SerraAngel(UUID ownerId) { + super(ownerId); + this.cardNumber = 14; + this.expansionSetCode = "V15"; + this.rarity = Rarity.MYTHIC; + } + + public SerraAngel(final SerraAngel card) { + super(card); + } + + @Override + public SerraAngel copy() { + return new SerraAngel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvangels/TarielReckonerOfSouls.java b/Mage.Sets/src/mage/sets/ftvangels/TarielReckonerOfSouls.java new file mode 100644 index 00000000000..e63b716a94e --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvangels/TarielReckonerOfSouls.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvangels; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class TarielReckonerOfSouls extends mage.sets.commander.TarielReckonerOfSouls { + + public TarielReckonerOfSouls(UUID ownerId) { + super(ownerId); + this.cardNumber = 15; + this.expansionSetCode = "V15"; + } + + public TarielReckonerOfSouls(final TarielReckonerOfSouls card) { + super(card); + } + + @Override + public TarielReckonerOfSouls copy() { + return new TarielReckonerOfSouls(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ftvdragons/Draco.java b/Mage.Sets/src/mage/sets/ftvdragons/Draco.java new file mode 100644 index 00000000000..2335c0a2e92 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvdragons/Draco.java @@ -0,0 +1,147 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvdragons; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.cost.CostModificationEffectImpl; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.*; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.util.CardUtil; + +/** + * + * @author Simown + */ +public class Draco extends CardImpl { + + public Draco(UUID ownerId) { + super(ownerId, 3, "Draco", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{16}"); + this.expansionSetCode = "FVD"; + this.subtype.add("Dragon"); + this.power = new MageInt(9); + this.toughness = new MageInt(9); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Domain - Draco costs {2} less to cast for each basic land type among lands you control. + this.addAbility(new SimpleStaticAbility(Zone.STACK, new DracoCostReductionEffect())); + + // Domain - At the beginning of your upkeep, sacrifice Draco unless you pay {10}. This cost is reduced by {2} for each basic land type among lands you control. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new DracoSacrificeUnlessPaysEffect(), TargetController.YOU, false)); + } + + public Draco(final Draco card) { + super(card); + } + + @Override + public Draco copy() { + return new Draco(this); + } +} + +class DracoCostReductionEffect extends CostModificationEffectImpl { + + public DracoCostReductionEffect() { + super(Duration.WhileOnStack, Outcome.Benefit, CostModificationType.REDUCE_COST); + staticText = "Domain - {this} costs {2} less to cast for each basic land type among lands you control."; + } + + protected DracoCostReductionEffect(final DracoCostReductionEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source, Ability abilityToModify) { + CardUtil.reduceCost(abilityToModify, new DomainValue(2).calculate(game, source, this)); + return true; + } + + public boolean applies(Ability abilityToModify, Ability source, Game game) { + return abilityToModify.getSourceId().equals(source.getSourceId()); + } + + @Override + public DracoCostReductionEffect copy() { + return new DracoCostReductionEffect(this); + } +} + +class DracoSacrificeUnlessPaysEffect extends OneShotEffect { + + public static final int MAX_DOMAIN_VALUE = 10; + + public DracoSacrificeUnlessPaysEffect () { + super(Outcome.Sacrifice); + staticText = "sacrifice {this} unless you pay {10}. This cost is reduced by {2} for each basic land type among lands you control."; + } + + public DracoSacrificeUnlessPaysEffect (final DracoSacrificeUnlessPaysEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (player != null && permanent != null) { + // The cost is reduced by {2} for each basic land type. + int domainValueReduction = new DomainValue(2).calculate(game, source, this); + int count = MAX_DOMAIN_VALUE - domainValueReduction; + if (player.chooseUse(Outcome.Benefit, "Pay {" + count + "}? Or " + permanent.getName() + " will be sacrificed.", source, game)) { + GenericManaCost cost = new GenericManaCost(count); + if (cost.pay(source, game, source.getSourceId(), source.getControllerId(), false)) { + return true; + } + } + permanent.sacrifice(source.getSourceId(), game); + return true; + } + return false; + } + + @Override + public DracoSacrificeUnlessPaysEffect copy() { + return new DracoSacrificeUnlessPaysEffect (this); + } + +} + + diff --git a/Mage.Sets/src/mage/sets/ftvexiled/Channel.java b/Mage.Sets/src/mage/sets/ftvexiled/Channel.java new file mode 100644 index 00000000000..09edbf46012 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ftvexiled/Channel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ftvexiled; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 3; + this.expansionSetCode = "FVE"; + this.rarity = Rarity.MYTHIC; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/AugurIlVec.java b/Mage.Sets/src/mage/sets/futuresight/AugurIlVec.java new file mode 100644 index 00000000000..3b6ffb9b3e0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/AugurIlVec.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.keyword.ShadowAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class AugurIlVec extends CardImpl { + + public AugurIlVec(UUID ownerId) { + super(ownerId, 2, "Augur il-Vec", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Shadow + this.addAbility(ShadowAbility.getInstance()); + + // Sacrifice Augur il-Vec: You gain 4 life. Activate this ability only during your upkeep. + this.addAbility(new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new GainLifeEffect(4), + new SacrificeSourceCost(), + new IsStepCondition(PhaseStep.UPKEEP), null)); + } + + public AugurIlVec(final AugurIlVec card) { + super(card); + } + + @Override + public AugurIlVec copy() { + return new AugurIlVec(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/AvenAugur.java b/Mage.Sets/src/mage/sets/futuresight/AvenAugur.java new file mode 100644 index 00000000000..ba9edfe7fd4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/AvenAugur.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class AvenAugur extends CardImpl { + + public AvenAugur(UUID ownerId) { + super(ownerId, 32, "Aven Augur", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Bird"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Sacrifice Aven Augur: Return up to two target creatures to their owners' hands. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new ReturnToHandTargetEffect(), + new SacrificeSourceCost(), + new IsStepCondition(PhaseStep.UPKEEP), + null); + ability.addTarget(new TargetCreaturePermanent(0, 2)); + this.addAbility(ability); + } + + public AvenAugur(final AvenAugur card) { + super(card); + } + + @Override + public AvenAugur copy() { + return new AvenAugur(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/BarrenGlory.java b/Mage.Sets/src/mage/sets/futuresight/BarrenGlory.java new file mode 100644 index 00000000000..fb6b3661c9e --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/BarrenGlory.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.WinGameSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; + +/** + * + * @author fireshoes + */ +public class BarrenGlory extends CardImpl { + + public BarrenGlory(UUID ownerId) { + super(ownerId, 3, "Barren Glory", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{4}{W}{W}"); + this.expansionSetCode = "FUT"; + + // At the beginning of your upkeep, if you control no permanents other than Barren Glory and have no cards in hand, you win the game. + Condition condition = new CardsInHandCondition(CardsInHandCondition.CountType.EQUAL_TO, 0); + TriggeredAbility ability = new BarrenGloryTriggeredAbility(); + this.addAbility(new ConditionalTriggeredAbility(ability, + condition, + "At the beginning of your upkeep, if you control no permanents other than {this} and have no cards in hand, you win the game")); + } + + public BarrenGlory(final BarrenGlory card) { + super(card); + } + + @Override + public BarrenGlory copy() { + return new BarrenGlory(this); + } +} + +class BarrenGloryTriggeredAbility extends TriggeredAbilityImpl { + + private static final FilterPermanent filter = new FilterPermanent(); + static { + filter.add(new AnotherPredicate()); + } + + BarrenGloryTriggeredAbility() { + super(Zone.BATTLEFIELD, new WinGameSourceControllerEffect()); + } + + BarrenGloryTriggeredAbility(final BarrenGloryTriggeredAbility ability) { + super(ability); + } + + @Override + public BarrenGloryTriggeredAbility copy() { + return new BarrenGloryTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.UPKEEP_STEP_PRE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (event.getPlayerId().equals(this.controllerId)) { + if (game.getBattlefield().count(filter, this.getSourceId(), this.getControllerId(), game) == 0) { + return true; + } + } + return false; + } + + @Override + public String getRule() { + return "At the beginning of your upkeep, if you control no permanents other than {this} and have no cards in hand, you win the game"; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/futuresight/CoalitionRelic.java b/Mage.Sets/src/mage/sets/futuresight/CoalitionRelic.java index 8b07a5d5a3c..1c7ec71523c 100644 --- a/Mage.Sets/src/mage/sets/futuresight/CoalitionRelic.java +++ b/Mage.Sets/src/mage/sets/futuresight/CoalitionRelic.java @@ -103,7 +103,7 @@ class CoalitionRelicEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); for (int i = 0; i < chargeCounters; i++) { while (!choice.isChosen()) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } player.choose(outcome, choice, game); diff --git a/Mage.Sets/src/mage/sets/futuresight/CyclicalEvolution.java b/Mage.Sets/src/mage/sets/futuresight/CyclicalEvolution.java new file mode 100644 index 00000000000..45bcce89468 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/CyclicalEvolution.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.ExileSpellEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.SuspendAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.counters.CounterType; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LevelX2 + */ +public class CyclicalEvolution extends CardImpl { + + public CyclicalEvolution(UUID ownerId) { + super(ownerId, 125, "Cyclical Evolution", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{G}{G}"); + this.expansionSetCode = "FUT"; + + // Target creature gets +3/+3 until end of turn. Exile Cyclical Evolution with three time counters on it. + getSpellAbility().addEffect(new BoostTargetEffect(3, 3, Duration.EndOfTurn)); + getSpellAbility().addTarget(new TargetCreaturePermanent()); + getSpellAbility().addEffect(ExileSpellEffect.getInstance()); + Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(), new StaticValue(3), true, true); + effect.setText("with 3 time counters on it"); + getSpellAbility().addEffect(effect); + + // Suspend 3-{2}{G} + this.addAbility(new SuspendAbility(3, new ManaCostsImpl<>("{2}{G}"), this)); + } + + public CyclicalEvolution(final CyclicalEvolution card) { + super(card); + } + + @Override + public CyclicalEvolution copy() { + return new CyclicalEvolution(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/DustOfMoments.java b/Mage.Sets/src/mage/sets/futuresight/DustOfMoments.java new file mode 100644 index 00000000000..1736ded2689 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/DustOfMoments.java @@ -0,0 +1,249 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.List; +import java.util.UUID; + +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.counters.Counter; +import mage.counters.CounterType; +import mage.filter.Filter; +import mage.filter.FilterCard; +import mage.filter.predicate.permanent.CardCounterPredicate; +import mage.filter.predicate.permanent.CounterPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author Gal Lerman + + */ +public class DustOfMoments extends CardImpl { + + public DustOfMoments(UUID ownerId) { + super(ownerId, 5, "Dust of Moments", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}"); + this.expansionSetCode = "FUT"; + + // Choose one - Remove two time counters from each permanent and each suspended card + this.getSpellAbility().addEffect(new RemoveCountersEffect()); + + // Or put two time counters on each permanent with a time counter on it and each suspended card + Mode mode = new Mode(); + mode.getEffects().add(new AddCountersEffect()); + this.getSpellAbility().addMode(mode); + } + + public DustOfMoments(final DustOfMoments card) { + super(card); + } + + @Override + public DustOfMoments copy() { + return new DustOfMoments(this); + } + + + //TODO: PermanentImpl.getCounters() and CardImpl.getCounters(game) don't return the same value for the same Card + //TODO: This means I can't use a Card generic for Permanents and Exiled cards and use Card.getCounters(game) + //TODO: This is the reason i've copy pasted some logic in DustOfMomentsEffect + //TODO: After this issue is fixed/explained i'll refactor the code + public abstract static class DustOfMomentsEffect extends OneShotEffect { + + private final Counter counter; + private final Filter permFilter; + private final Filter exiledFilter; + + public DustOfMomentsEffect() { + super(Outcome.Benefit); + this.counter = new Counter(CounterType.TIME.getName(), 2); + this.permFilter = new FilterCard("permanent and each suspended card"); + permFilter.add(new CounterPredicate(CounterType.TIME)); + + this.exiledFilter = new FilterCard("permanent and each suspended card"); + exiledFilter.add(new CardCounterPredicate(CounterType.TIME)); + setText(); + } + + public DustOfMomentsEffect(final DustOfMomentsEffect effect) { + super(effect); + this.counter = effect.counter.copy(); + this.permFilter = effect.permFilter.copy(); + this.exiledFilter = effect.exiledFilter.copy(); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + updatePermanents(game, controller, sourceObject); + updateSuspended(game, controller, sourceObject); + return true; + } + return false; + } + + private void updateSuspended(final Game game, final Player controller, final MageObject sourceObject) { + final List exiledCards = game.getExile().getAllCards(game); + execute(game, controller, sourceObject, exiledCards); + } + + private void updatePermanents(final Game game, final Player controller, final MageObject sourceObject) { + List permanents = game.getBattlefield().getAllActivePermanents(); + executeP(game, controller, sourceObject, permanents); + } + + private void executeP(final Game game, final Player controller, final MageObject sourceObject, final List cards) { + if (cards == null || cards.isEmpty()) { + return; + } + for (Permanent card : cards) { + if (permFilter.match(card, game)) { + final String counterName = counter.getName(); + if (shouldRemoveCounters()) { + final Counter existingCounterOfSameType = card.getCounters().get(counterName); + final int countersToRemove = Math.min(existingCounterOfSameType.getCount(), counter.getCount()); + final Counter modifiedCounter = new Counter(counterName, countersToRemove); + card.removeCounters(modifiedCounter, game); + } else { + card.addCounters(counter, game); + } + if (!game.isSimulation()) + game.informPlayers(new StringBuilder(sourceObject.getName()).append(": ") + .append(controller.getLogName()).append(getActionStr()).append("s") + .append(counter.getCount()).append(" ").append(counterName.toLowerCase()) + .append(" counter on ").append(card.getName()).toString()); + } + } + } + + private void execute(final Game game, final Player controller, final MageObject sourceObject, final List cards) { + if (cards == null || cards.isEmpty()) { + return; + } + for (Card card : cards) { + if (exiledFilter.match(card, game)) { + final String counterName = counter.getName(); + if (shouldRemoveCounters()) { + final Counter existingCounterOfSameType = card.getCounters(game).get(counterName); + final int countersToRemove = Math.min(existingCounterOfSameType.getCount(), counter.getCount()); + final Counter modifiedCounter = new Counter(counterName, countersToRemove); + card.removeCounters(modifiedCounter, game); + } else { + card.addCounters(counter, game); + } + if (!game.isSimulation()) + game.informPlayers(new StringBuilder(sourceObject.getName()).append(": ") + .append(controller.getLogName()).append(getActionStr()).append("s ") + .append(counter.getCount()).append(" ").append(counterName.toLowerCase()) + .append(" counter on ").append(card.getName()).toString()); + } + } + } + + protected abstract boolean shouldRemoveCounters(); + + protected abstract String getActionStr(); + + private void setText() { + StringBuilder sb = new StringBuilder(); + sb.append(getActionStr()); + if (counter.getCount() > 1) { + sb.append(Integer.toString(counter.getCount())).append(" ").append(counter.getName().toLowerCase()).append(" counters on each "); + } else { + sb.append("a ").append(counter.getName().toLowerCase()).append(" counter on each "); + } + sb.append(permFilter.getMessage()); + staticText = sb.toString(); + } + } + + public static class AddCountersEffect extends DustOfMomentsEffect { + + public AddCountersEffect() { + super(); + } + + public AddCountersEffect(final DustOfMomentsEffect effect) { + super(effect); + } + + @Override + protected boolean shouldRemoveCounters() { + return false; + } + + @Override + protected String getActionStr() { + return "add"; + } + + @Override + public Effect copy() { + return new AddCountersEffect(this); + } + } + + public static class RemoveCountersEffect extends DustOfMomentsEffect { + + public RemoveCountersEffect() { + super(); + } + + public RemoveCountersEffect(final DustOfMomentsEffect effect) { + super(effect); + } + + @Override + protected boolean shouldRemoveCounters() { + return true; + } + + @Override + protected String getActionStr() { + return "remove"; + } + + @Override + public Effect copy() { + return new RemoveCountersEffect(this); + } + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/EmblemOfTheWarmind.java b/Mage.Sets/src/mage/sets/futuresight/EmblemOfTheWarmind.java new file mode 100644 index 00000000000..68a667d8a1a --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/EmblemOfTheWarmind.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class EmblemOfTheWarmind extends CardImpl { + + public EmblemOfTheWarmind(UUID ownerId) { + super(ownerId, 112, "Emblem of the Warmind", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Aura"); + + // Enchant creature you control + TargetPermanent auraTarget = new TargetControlledCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Benefit)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Creatures you control have haste. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new GainAbilityControlledEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent("creatures")))); + } + + public EmblemOfTheWarmind(final EmblemOfTheWarmind card) { + super(card); + } + + @Override + public EmblemOfTheWarmind copy() { + return new EmblemOfTheWarmind(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/GoldmeadowLookout.java b/Mage.Sets/src/mage/sets/futuresight/GoldmeadowLookout.java new file mode 100644 index 00000000000..c3471c3316f --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/GoldmeadowLookout.java @@ -0,0 +1,94 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.permanent.token.Token; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GoldmeadowLookout extends CardImpl { + + public GoldmeadowLookout(UUID ownerId) { + super(ownerId, 22, "Goldmeadow Lookout", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Kithkin"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {W}, {tap}, Discard a card: Put a 1/1 white Kithkin Soldier creature token named Goldmeadow Harrier onto the battlefield. It has "{W}, {tap}: Tap target creature." + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new GoldmeadowHarrierToken()), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + this.addAbility(ability); + } + + public GoldmeadowLookout(final GoldmeadowLookout card) { + super(card); + } + + @Override + public GoldmeadowLookout copy() { + return new GoldmeadowLookout(this); + } +} + +class GoldmeadowHarrierToken extends Token { + + public GoldmeadowHarrierToken() { + super("Goldmeadow Harrier", "1/1 white Kithkin Soldier creature token named Goldmeadow Harrier with \"{W}, {tap}: Tap target creature.\""); + this.setOriginalExpansionSetCode("FUT"); + cardType.add(CardType.CREATURE); + color.setWhite(true); + subtype.add("Kithkin"); + subtype.add("Soldier"); + power = new MageInt(1); + toughness = new MageInt(1); + + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/futuresight/HenchfiendOfUkor.java b/Mage.Sets/src/mage/sets/futuresight/HenchfiendOfUkor.java new file mode 100644 index 00000000000..e6069dddbea --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/HenchfiendOfUkor.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.EchoAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class HenchfiendOfUkor extends CardImpl { + + public HenchfiendOfUkor(UUID ownerId) { + super(ownerId, 117, "Henchfiend of Ukor", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Ogre"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // Haste + this.addAbility(HasteAbility.getInstance()); + + // Echo {1}{B} + this.addAbility(new EchoAbility("{1}{B}")); + + // {BR}: Henchfiend of Ukor gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{B/R}"))); + } + + public HenchfiendOfUkor(final HenchfiendOfUkor card) { + super(card); + } + + @Override + public HenchfiendOfUkor copy() { + return new HenchfiendOfUkor(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/JudgeUnworthy.java b/Mage.Sets/src/mage/sets/futuresight/JudgeUnworthy.java new file mode 100644 index 00000000000..f233e07da66 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/JudgeUnworthy.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.keyword.ScryEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetAttackingOrBlockingCreature; + +/** + * + * @author fireshoes + */ +public class JudgeUnworthy extends CardImpl { + + public JudgeUnworthy(UUID ownerId) { + super(ownerId, 9, "Judge Unworthy", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "FUT"; + + // Choose target attacking or blocking creature. Scry 3, then reveal the top card of your library. Judge Unworthy deals damage equal to that card's converted mana cost to that creature. + this.getSpellAbility().addTarget(new TargetAttackingOrBlockingCreature()); + Effect effect = new ScryEffect(3); + effect.setText("Choose target attacking or blocking creature. Scry 3"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addEffect(new JudgeUnworthyEffect()); + } + + public JudgeUnworthy(final JudgeUnworthy card) { + super(card); + } + + @Override + public JudgeUnworthy copy() { + return new JudgeUnworthy(this); + } +} + +class JudgeUnworthyEffect extends OneShotEffect { + + public JudgeUnworthyEffect() { + super(Outcome.Damage); + this.staticText = ", then reveal the top card of your library. {this} deals damage equal to that card's converted mana cost to that creature"; + } + + public JudgeUnworthyEffect(final JudgeUnworthyEffect effect) { + super(effect); + } + + @Override + public JudgeUnworthyEffect copy() { + return new JudgeUnworthyEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Card sourceCard = game.getCard(source.getSourceId()); + if (sourceCard != null && controller != null) { + if (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().getFromTop(game); + controller.revealCards(sourceCard.getName(), new CardsImpl(card), game); + Permanent targetCreature = game.getPermanent(this.getTargetPointer().getFirst(game, source)); + if (targetCreature != null) { + targetCreature.damage(card.getManaCost().convertedManaCost(), source.getSourceId(), game, false, true); + return true; + } + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/LeadenFists.java b/Mage.Sets/src/mage/sets/futuresight/LeadenFists.java new file mode 100644 index 00000000000..d333589ef19 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/LeadenFists.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlashAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class LeadenFists extends CardImpl { + + public LeadenFists(UUID ownerId) { + super(ownerId, 38, "Leaden Fists", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Aura"); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Neutral)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature gets +3/+3 and doesn't untap during its controller's untap step. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 3, Duration.WhileOnBattlefield)); + Effect effect = new DontUntapInControllersUntapStepEnchantedEffect(); + effect.setText("and doesn't untap during its controller's untap step"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public LeadenFists(final LeadenFists card) { + super(card); + } + + @Override + public LeadenFists copy() { + return new LeadenFists(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/LinessaZephyrMage.java b/Mage.Sets/src/mage/sets/futuresight/LinessaZephyrMage.java index 16b11f8a818..2d70219a2a8 100644 --- a/Mage.Sets/src/mage/sets/futuresight/LinessaZephyrMage.java +++ b/Mage.Sets/src/mage/sets/futuresight/LinessaZephyrMage.java @@ -76,13 +76,13 @@ public class LinessaZephyrMage extends CardImpl { ability.addCost(new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); - + // Grandeur - Discard another card named Linessa, Zephyr Mage: Target player returns a creature he or she controls to its owner's hand, then repeats this process for an artifact, an enchantment, and a land. ability = new GrandeurAbility(new LinessaZephyrMageEffect(), "Linessa, Zephyr Mage"); ability.addTarget(new TargetPlayer()); this.addAbility(ability); } - + public LinessaZephyrMage(final LinessaZephyrMage card) { super(card); } @@ -105,21 +105,21 @@ public class LinessaZephyrMage extends CardImpl { } class LinessaZephyrMageEffect extends OneShotEffect { - + LinessaZephyrMageEffect() { super(Outcome.ReturnToHand); this.staticText = "Target player returns a creature he or she controls to its owner's hand, then repeats this process for an artifact, an enchantment, and a land"; } - + LinessaZephyrMageEffect(final LinessaZephyrMageEffect effect) { super(effect); } - + @Override public LinessaZephyrMageEffect copy() { return new LinessaZephyrMageEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -132,7 +132,7 @@ class LinessaZephyrMageEffect extends OneShotEffect { if (target.choose(Outcome.ReturnToHand, targetPlayer.getId(), source.getSourceId(), game)) { Permanent permanent = game.getPermanent(target.getFirstTarget()); if (permanent != null) { - targetPlayer.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + targetPlayer.moveCards(permanent, null, Zone.HAND, source, game); } } @@ -144,10 +144,10 @@ class LinessaZephyrMageEffect extends OneShotEffect { if (target.choose(Outcome.ReturnToHand, targetPlayer.getId(), source.getSourceId(), game)) { Permanent permanent = game.getPermanent(target.getFirstTarget()); if (permanent != null) { - targetPlayer.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + targetPlayer.moveCards(permanent, null, Zone.HAND, source, game); } } - + // an enchantment, filter = new FilterControlledPermanent("enchantment you control"); filter.add(new CardTypePredicate(CardType.ENCHANTMENT)); @@ -156,10 +156,10 @@ class LinessaZephyrMageEffect extends OneShotEffect { if (target.choose(Outcome.ReturnToHand, targetPlayer.getId(), source.getSourceId(), game)) { Permanent permanent = game.getPermanent(target.getFirstTarget()); if (permanent != null) { - targetPlayer.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + targetPlayer.moveCards(permanent, null, Zone.HAND, source, game); } } - + // and a land. filter = new FilterControlledPermanent("land you control"); filter.add(new CardTypePredicate(CardType.LAND)); @@ -168,10 +168,10 @@ class LinessaZephyrMageEffect extends OneShotEffect { if (target.choose(Outcome.ReturnToHand, targetPlayer.getId(), source.getSourceId(), game)) { Permanent permanent = game.getPermanent(target.getFirstTarget()); if (permanent != null) { - targetPlayer.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + targetPlayer.moveCards(permanent, null, Zone.HAND, source, game); } } - + return true; } } diff --git a/Mage.Sets/src/mage/sets/futuresight/MarshalingCry.java b/Mage.Sets/src/mage/sets/futuresight/MarshalingCry.java new file mode 100644 index 00000000000..be54d903931 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/MarshalingCry.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.abilities.keyword.FlashbackAbility; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TimingRule; + +/** + * + * @author fireshoes + */ +public class MarshalingCry extends CardImpl { + + public MarshalingCry(UUID ownerId) { + super(ownerId, 13, "Marshaling Cry", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{W}{W}"); + this.expansionSetCode = "FUT"; + + // Creatures you control get +1/+1 and gain vigilance until end of turn. + Effect effect = new BoostControlledEffect(1, 1, Duration.EndOfTurn); + effect.setText("Creatures you control get +1/+1"); + this.getSpellAbility().addEffect(effect); + effect = new GainAbilityControlledEffect(VigilanceAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and vigilance until end of turn"); + this.getSpellAbility().addEffect(effect); + + // Cycling {2} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); + + // Flashback {3}{W} + this.addAbility(new FlashbackAbility(new ManaCostsImpl("{3}{W}"), TimingRule.SORCERY)); + } + + public MarshalingCry(final MarshalingCry card) { + super(card); + } + + @Override + public MarshalingCry copy() { + return new MarshalingCry(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/PetrifiedPlating.java b/Mage.Sets/src/mage/sets/futuresight/PetrifiedPlating.java new file mode 100644 index 00000000000..ae237c7075c --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/PetrifiedPlating.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.SuspendAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class PetrifiedPlating extends CardImpl { + + public PetrifiedPlating(UUID ownerId) { + super(ownerId, 133, "Petrified Plating", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature gets +2/+2. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(2, 2, Duration.WhileOnBattlefield))); + + // Suspend 2-{G} + this.addAbility(new SuspendAbility(2, new ManaCostsImpl("{G}"), this)); + } + + public PetrifiedPlating(final PetrifiedPlating card) { + super(card); + } + + @Override + public PetrifiedPlating copy() { + return new PetrifiedPlating(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/Quagnoth.java b/Mage.Sets/src/mage/sets/futuresight/Quagnoth.java new file mode 100644 index 00000000000..83c191c5817 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/Quagnoth.java @@ -0,0 +1,109 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.abilities.keyword.SplitSecondAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.stack.StackObject; + +/** + * + * @author fireshoes + */ +public class Quagnoth extends CardImpl { + + public Quagnoth(UUID ownerId) { + super(ownerId, 150, "Quagnoth", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{G}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Beast"); + this.power = new MageInt(4); + this.toughness = new MageInt(5); + + // Split second + this.addAbility(new SplitSecondAbility()); + + // Shroud + this.addAbility(ShroudAbility.getInstance()); + + // When a spell or ability an opponent controls causes you to discard Quagnoth, return it to your hand. + this.addAbility(new QuagnothTriggeredAbility()); + } + + public Quagnoth(final Quagnoth card) { + super(card); + } + + @Override + public Quagnoth copy() { + return new Quagnoth(this); + } +} + +class QuagnothTriggeredAbility extends TriggeredAbilityImpl { + + QuagnothTriggeredAbility() { + super(Zone.GRAVEYARD, new ReturnToHandSourceEffect()); + } + + QuagnothTriggeredAbility(final QuagnothTriggeredAbility ability) { + super(ability); + } + + @Override + public QuagnothTriggeredAbility copy() { + return new QuagnothTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.DISCARDED_CARD; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return game.getOpponents(this.getControllerId()).contains(game.getControllerId(event.getSourceId())) && + StackObject.class.isInstance(game.getObject(event.getSourceId())) && + getSourceId().equals(event.getTargetId()); + } + + @Override + public String getRule() { + return "When a spell or ability an opponent controls causes you to discard {this}, " + super.getRule(); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/futuresight/Saltskitter.java b/Mage.Sets/src/mage/sets/futuresight/Saltskitter.java new file mode 100644 index 00000000000..f4e73a800f7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/Saltskitter.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldAllTriggeredAbility; +import mage.abilities.effects.common.ExileReturnToBattlefieldOwnerNextEndStepEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author fireshoes + */ +public class Saltskitter extends CardImpl { + + private static final FilterPermanent filter = new FilterCreaturePermanent("another creature"); + + static { + filter.add(new AnotherPredicate()); + } + + public Saltskitter(UUID ownerId) { + super(ownerId, 14, "Saltskitter", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Wurm"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Whenever another creature enters the battlefield, exile Saltskitter. Return Saltskitter to the battlefield under its owner's control at the beginning of the next end step. + this.addAbility(new EntersBattlefieldAllTriggeredAbility(new ExileReturnToBattlefieldOwnerNextEndStepEffect(true), filter)); + } + + public Saltskitter(final Saltskitter card) { + super(card); + } + + @Override + public Saltskitter copy() { + return new Saltskitter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/SoultetherGolem.java b/Mage.Sets/src/mage/sets/futuresight/SoultetherGolem.java index ca9d9e48c6f..5fb3ab962c1 100644 --- a/Mage.Sets/src/mage/sets/futuresight/SoultetherGolem.java +++ b/Mage.Sets/src/mage/sets/futuresight/SoultetherGolem.java @@ -29,6 +29,7 @@ package mage.sets.futuresight; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.common.EntersBattlefieldAllTriggeredAbility; import mage.abilities.effects.common.counter.AddCountersSourceEffect; @@ -49,7 +50,7 @@ import mage.filter.predicate.permanent.ControllerPredicate; * @author fireshoes */ public class SoultetherGolem extends CardImpl { - + private final static FilterCreaturePermanent filter = new FilterCreaturePermanent("another creature"); static { @@ -65,10 +66,12 @@ public class SoultetherGolem extends CardImpl { this.toughness = new MageInt(3); // Vanishing 1 - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(1)))); + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(1))); + ability.setRuleVisible(false); + this.addAbility(ability); this.addAbility(new VanishingUpkeepAbility(1)); this.addAbility(new VanishingSacrificeAbility()); - + // Whenever another creature enters the battlefield under your control, put a time counter on Soultether Golem. this.addAbility(new EntersBattlefieldAllTriggeredAbility( Zone.BATTLEFIELD, diff --git a/Mage.Sets/src/mage/sets/futuresight/SpiritEnDal.java b/Mage.Sets/src/mage/sets/futuresight/SpiritEnDal.java new file mode 100644 index 00000000000..4a225849ea3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/SpiritEnDal.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.ForecastAbility; +import mage.abilities.keyword.ShadowAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SpiritEnDal extends CardImpl { + + public SpiritEnDal(UUID ownerId) { + super(ownerId, 17, "Spirit en-Dal", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Spirit"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Shadow + this.addAbility(ShadowAbility.getInstance()); + + // Forecast - {1}{W}, Reveal Spirit en-Dal from your hand: Target creature gains shadow until end of turn. + Ability ability = new ForecastAbility(new GainAbilityTargetEffect(ShadowAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{1}{W}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public SpiritEnDal(final SpiritEnDal card) { + super(card); + } + + @Override + public SpiritEnDal copy() { + return new SpiritEnDal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/UtopiaMycon.java b/Mage.Sets/src/mage/sets/futuresight/UtopiaMycon.java new file mode 100644 index 00000000000..45f3a6749af --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/UtopiaMycon.java @@ -0,0 +1,91 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.mana.AnyColorManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.game.permanent.token.SaprolingToken; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class UtopiaMycon extends CardImpl { + + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("Saproling"); + + static { + filter.add(new SubtypePredicate("Saproling")); + } + + public UtopiaMycon(UUID ownerId) { + super(ownerId, 140, "Utopia Mycon", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{G}"); + this.expansionSetCode = "FUT"; + this.subtype.add("Fungus"); + this.power = new MageInt(0); + this.toughness = new MageInt(2); + + // At the beginning of your upkeep, put a spore counter on Utopia Mycon. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.SPORE.createInstance()), TargetController.YOU, false)); + + // Remove three spore counters from Utopia Mycon: Put a 1/1 green Saproling creature token onto the battlefield. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new SaprolingToken()), new RemoveCountersSourceCost(CounterType.SPORE.createInstance(3)))); + + // Sacrifice a Saproling: Add one mana of any color to your mana pool. + Ability ability = new AnyColorManaAbility(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1,1, filter, false))); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + public UtopiaMycon(final UtopiaMycon card) { + super(card); + } + + @Override + public UtopiaMycon copy() { + return new UtopiaMycon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/VenserShaperSavant.java b/Mage.Sets/src/mage/sets/futuresight/VenserShaperSavant.java index 6cf33d4ecbb..1045ba09c7c 100644 --- a/Mage.Sets/src/mage/sets/futuresight/VenserShaperSavant.java +++ b/Mage.Sets/src/mage/sets/futuresight/VenserShaperSavant.java @@ -103,18 +103,19 @@ class VenserShaperSavantEffect extends OneShotEffect { if (controller != null) { Permanent permanent = game.getPermanent(this.getTargetPointer().getFirst(game, source)); if (permanent != null) { - return controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + return controller.moveCards(permanent, null, Zone.HAND, source, game); } /** - * 01.05.2007 If a spell is returned to its owner's hand, it's removed from - * the stack and thus will not resolve. The spell isn't countered; it just no longer exists. - * 01.05.2007 If a copy of a spell is returned to its owner's hand, it's moved there, - * then it will cease to exist as a state-based action. - * 01.05.2007 If Venser's enters-the-battlefield ability targets a spell cast with flashback, - * that spell will be exiled instead of returning to its owner's hand. + * 01.05.2007 If a spell is returned to its owner's hand, it's + * removed from the stack and thus will not resolve. The spell isn't + * countered; it just no longer exists. 01.05.2007 If a copy of a + * spell is returned to its owner's hand, it's moved there, then it + * will cease to exist as a state-based action. 01.05.2007 If + * Venser's enters-the-battlefield ability targets a spell cast with + * flashback, that spell will be exiled instead of returning to its + * owner's hand. */ - Spell spell = game.getStack().getSpell(this.getTargetPointer().getFirst(game, source)); if (spell != null) { Card card = null; @@ -123,7 +124,7 @@ class VenserShaperSavantEffect extends OneShotEffect { } game.getStack().remove(spell); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.STACK); + controller.moveCards(card, null, Zone.HAND, source, game); } return true; } diff --git a/Mage.Sets/src/mage/sets/futuresight/WrapInVigor.java b/Mage.Sets/src/mage/sets/futuresight/WrapInVigor.java new file mode 100644 index 00000000000..73e50b46d3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/futuresight/WrapInVigor.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.futuresight; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class WrapInVigor extends mage.sets.conspiracy.WrapInVigor { + + public WrapInVigor(UUID ownerId) { + super(ownerId); + this.cardNumber = 141; + this.expansionSetCode = "FUT"; + } + + public WrapInVigor(final WrapInVigor card) { + super(card); + } + + @Override + public WrapInVigor copy() { + return new WrapInVigor(this); + } +} diff --git a/Mage.Sets/src/mage/sets/futuresight/YixlidJailer.java b/Mage.Sets/src/mage/sets/futuresight/YixlidJailer.java index 28f969c85bc..4e35a0f736c 100644 --- a/Mage.Sets/src/mage/sets/futuresight/YixlidJailer.java +++ b/Mage.Sets/src/mage/sets/futuresight/YixlidJailer.java @@ -100,7 +100,7 @@ class YixlidJailerEffect extends ContinuousEffectImpl { if (player != null) { for (Card card : player.getGraveyard().getCards(game)) { if (card != null) { - card.getAbilities().clear(); // Will the abilities ever come back???? + card.getAbilities(game).clear(); // Will the abilities ever come back???? // TODO: Fix that (LevelX2) // game.getContinuousEffects().removeGainedEffectsForSource(card.getId()); // game.getState().resetTriggersForSourceId(card.getId()); @@ -127,4 +127,4 @@ class YixlidJailerEffect extends ContinuousEffectImpl { public boolean hasLayer(Layer layer) { return layer == Layer.AbilityAddingRemovingEffects_6; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/gatecrash/AlphaAuthority.java b/Mage.Sets/src/mage/sets/gatecrash/AlphaAuthority.java index c80d59df1c4..c6adbca77b1 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/AlphaAuthority.java +++ b/Mage.Sets/src/mage/sets/gatecrash/AlphaAuthority.java @@ -1,142 +1,144 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.gatecrash; - -import java.util.UUID; - -import mage.constants.AttachmentType; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.SubLayer; -import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; -import mage.abilities.keyword.EnchantAbility; -import mage.abilities.keyword.HexproofAbility; -import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.target.TargetPermanent; -import mage.target.common.TargetCreaturePermanent; -import mage.util.CardUtil; - -/** - * - * @author LevelX2 - */ -public class AlphaAuthority extends CardImpl { - - public AlphaAuthority(UUID ownerId) { - super(ownerId, 114, "Alpha Authority", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); - this.expansionSetCode = "GTC"; - - this.subtype.add("Aura"); - - // Enchant creature - TargetPermanent auraTarget = new TargetCreaturePermanent(); - this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); - Ability ability = new EnchantAbility(auraTarget.getTargetName()); - this.addAbility(ability); - - // Enchanted creature has hexproof and can't be blocked by more than one creature. - ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(HexproofAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield)); - ability.addEffect(new CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType.AURA,1)); - this.addAbility(ability); - } - - public AlphaAuthority(final AlphaAuthority card) { - super(card); - } - - @Override - public AlphaAuthority copy() { - return new AlphaAuthority(this); - } -} - -class CantBeBlockedByMoreThanOneAttachedEffect extends ContinuousEffectImpl { - - protected int amount; - protected AttachmentType attachmentType; - - public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount) { - this(attachmentType, amount, Duration.WhileOnBattlefield); - } - - public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount, Duration duration) { - super(duration, Outcome.Benefit); - this.amount = amount; - this.attachmentType = attachmentType; - staticText = (attachmentType.equals(AttachmentType.AURA) ? "Enchanted" : "Equipped") + " creature can't be blocked by more than " + CardUtil.numberToText(amount) + " creature" + (amount==1 ?"":"s"); - } - - public CantBeBlockedByMoreThanOneAttachedEffect(final CantBeBlockedByMoreThanOneAttachedEffect effect) { - super(effect); - this.amount = effect.amount; - this.attachmentType = effect.attachmentType; - } - - @Override - public CantBeBlockedByMoreThanOneAttachedEffect copy() { - return new CantBeBlockedByMoreThanOneAttachedEffect(this); - } - - @Override - public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { - switch (layer) { - case RulesEffects: - Permanent attachment = game.getPermanent(source.getSourceId()); - if (attachment != null && attachment.getAttachedTo() != null) { - Permanent perm = game.getPermanent(attachment.getAttachedTo()); - if (perm != null) { - perm.setMaxBlockedBy(amount); - return true; - } - } - break; - } - return false; - } - - @Override - public boolean apply(Game game, Ability source) { - return false; - } - - @Override - public boolean hasLayer(Layer layer) { - return layer == Layer.RulesEffects; - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.gatecrash; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.HexproofAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; +import mage.util.CardUtil; + +/** + * + * @author LevelX2 + */ +public class AlphaAuthority extends CardImpl { + + public AlphaAuthority(UUID ownerId) { + super(ownerId, 114, "Alpha Authority", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "GTC"; + + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature has hexproof and can't be blocked by more than one creature. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(HexproofAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield)); + Effect effect = new CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType.AURA,1); + effect.setText("and can't be blocked by more than one creature"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public AlphaAuthority(final AlphaAuthority card) { + super(card); + } + + @Override + public AlphaAuthority copy() { + return new AlphaAuthority(this); + } +} + +class CantBeBlockedByMoreThanOneAttachedEffect extends ContinuousEffectImpl { + + protected int amount; + protected AttachmentType attachmentType; + + public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount) { + this(attachmentType, amount, Duration.WhileOnBattlefield); + } + + public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount, Duration duration) { + super(duration, Outcome.Benefit); + this.amount = amount; + this.attachmentType = attachmentType; + staticText = (attachmentType.equals(AttachmentType.AURA) ? "Enchanted" : "Equipped") + " creature can't be blocked by more than " + CardUtil.numberToText(amount) + " creature" + (amount==1 ?"":"s"); + } + + public CantBeBlockedByMoreThanOneAttachedEffect(final CantBeBlockedByMoreThanOneAttachedEffect effect) { + super(effect); + this.amount = effect.amount; + this.attachmentType = effect.attachmentType; + } + + @Override + public CantBeBlockedByMoreThanOneAttachedEffect copy() { + return new CantBeBlockedByMoreThanOneAttachedEffect(this); + } + + @Override + public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { + switch (layer) { + case RulesEffects: + Permanent attachment = game.getPermanent(source.getSourceId()); + if (attachment != null && attachment.getAttachedTo() != null) { + Permanent perm = game.getPermanent(attachment.getAttachedTo()); + if (perm != null) { + perm.setMaxBlockedBy(amount); + return true; + } + } + break; + } + return false; + } + + @Override + public boolean apply(Game game, Ability source) { + return false; + } + + @Override + public boolean hasLayer(Layer layer) { + return layer == Layer.RulesEffects; + } +} diff --git a/Mage.Sets/src/mage/sets/gatecrash/BiomassMutation.java b/Mage.Sets/src/mage/sets/gatecrash/BiomassMutation.java index 434c10e426b..051d2268d04 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/BiomassMutation.java +++ b/Mage.Sets/src/mage/sets/gatecrash/BiomassMutation.java @@ -28,14 +28,13 @@ package mage.sets.gatecrash; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.ManacostVariableValue; import mage.abilities.effects.common.continuous.SetPowerToughnessAllEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Rarity; import mage.filter.common.FilterControlledCreaturePermanent; /** @@ -49,7 +48,7 @@ public class BiomassMutation extends CardImpl { this.expansionSetCode = "GTC"; - // Creatures you control become X/X until end of turn. + // Creatures you control have base power and toughness X/X until end of turn. DynamicValue variableMana = new ManacostVariableValue(); this.getSpellAbility().addEffect(new SetPowerToughnessAllEffect(variableMana, variableMana, Duration.EndOfTurn, new FilterControlledCreaturePermanent("Creatures you control"), true)); } diff --git a/Mage.Sets/src/mage/sets/gatecrash/DevourFlesh.java b/Mage.Sets/src/mage/sets/gatecrash/DevourFlesh.java index 08c0c7cd7c0..ca6a0813125 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/DevourFlesh.java +++ b/Mage.Sets/src/mage/sets/gatecrash/DevourFlesh.java @@ -94,7 +94,7 @@ class DevourFleshSacrificeEffect extends OneShotEffect { int realCount = game.getBattlefield().countAll(filter, player.getId(), game); if (realCount > 0) { Target target = new TargetControlledPermanent(1, 1, filter, true); - while (player.isInGame() && !target.isChosen() && target.canChoose(player.getId(), game)) { + while (player.canRespond() && !target.isChosen() && target.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Sacrifice, target, source, game); } Permanent permanent = game.getPermanent(target.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/gatecrash/DinrovaHorror.java b/Mage.Sets/src/mage/sets/gatecrash/DinrovaHorror.java index 5eab7a69163..042d85b8e69 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/DinrovaHorror.java +++ b/Mage.Sets/src/mage/sets/gatecrash/DinrovaHorror.java @@ -28,15 +28,15 @@ package mage.sets.gatecrash; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; @@ -95,8 +95,8 @@ class DinrovaHorrorEffect extends OneShotEffect { if (target != null) { Player controller = game.getPlayer(target.getControllerId()); if (controller != null) { - controller.moveCardToHandWithInfo(target, source.getSourceId(), game, Zone.BATTLEFIELD); - controller.discard(1, source, game); + controller.moveCards(target, null, Zone.HAND, source, game); + controller.discard(1, false, source, game); return true; } } diff --git a/Mage.Sets/src/mage/sets/gatecrash/DomriRade.java b/Mage.Sets/src/mage/sets/gatecrash/DomriRade.java index 40ec318e1bd..0d92cdf0bac 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/DomriRade.java +++ b/Mage.Sets/src/mage/sets/gatecrash/DomriRade.java @@ -29,11 +29,6 @@ package mage.sets.gatecrash; import java.util.UUID; import mage.MageObject; - -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.LoyaltyAbility; import mage.abilities.common.EntersBattlefieldAbility; @@ -50,7 +45,11 @@ import mage.abilities.keyword.TrampleAbility; import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Duration; import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.FilterPermanent; import mage.filter.common.FilterControlledCreaturePermanent; @@ -71,8 +70,6 @@ public class DomriRade extends CardImpl { this.expansionSetCode = "GTC"; this.subtype.add("Domri"); - - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(3)), false)); // +1: Look at the top card of your library. If it's a creature card, you may reveal it and put it into your hand. @@ -127,8 +124,8 @@ class DomriRadeEffect1 extends OneShotEffect { controller.lookAtCards(sourceObject.getName(), cards, game); if (card.getCardType().contains(CardType.CREATURE)) { if (controller.chooseUse(outcome, "Reveal " + card.getName() + " and put it into your hand?", source, game)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - controller.revealCards(sourceObject.getName(), cards, game); + controller.moveCards(card, null, Zone.HAND, source, game); + controller.revealCards(sourceObject.getIdName(), cards, game); } } return true; @@ -139,7 +136,9 @@ class DomriRadeEffect1 extends OneShotEffect { } class DomriRadeEmblem extends Emblem { + // "Creatures you control have double strike, trample, hexproof and haste." + public DomriRadeEmblem() { this.setName("EMBLEM: Domri Rade"); FilterPermanent filter = new FilterControlledCreaturePermanent("Creatures"); @@ -156,7 +155,7 @@ class DomriRadeEmblem extends Emblem { } class DomriRadeTargetOtherCreaturePermanent extends TargetCreaturePermanent { - + public DomriRadeTargetOtherCreaturePermanent() { super(); } diff --git a/Mage.Sets/src/mage/sets/gatecrash/DyingWish.java b/Mage.Sets/src/mage/sets/gatecrash/DyingWish.java index 772d3a72ad9..6b98ffc389e 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/DyingWish.java +++ b/Mage.Sets/src/mage/sets/gatecrash/DyingWish.java @@ -28,17 +28,21 @@ package mage.sets.gatecrash; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.common.DiesAttachedTriggeredAbility; import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.LoseLifeTargetEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; import mage.target.TargetPermanent; import mage.target.TargetPlayer; import mage.target.common.TargetControlledCreaturePermanent; @@ -62,9 +66,8 @@ public class DyingWish extends CardImpl { Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); - // When enchanted creature dies, target player loses X life and you gain X life, where X is its power. - DynamicValue attachedPower = new AttachedPermanentPowerCount(); + DynamicValue attachedPower = new DyingWishAttachedPermanentPowerCount(); ability = new DiesAttachedTriggeredAbility(new LoseLifeTargetEffect(attachedPower), "enchanted creature"); ability.addEffect(new GainLifeEffect(attachedPower)); ability.addTarget(new TargetPlayer()); @@ -80,3 +83,38 @@ public class DyingWish extends CardImpl { return new DyingWish(this); } } + +class DyingWishAttachedPermanentPowerCount implements DynamicValue { + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + Permanent attachmentPermanent = game.getPermanent(sourceAbility.getSourceId()); + if (attachmentPermanent == null) { + attachmentPermanent = (Permanent) game.getLastKnownInformation(sourceAbility.getSourceId(), Zone.BATTLEFIELD, sourceAbility.getSourceObjectZoneChangeCounter()); + } + if (attachmentPermanent != null && attachmentPermanent.getAttachedTo() != null) { + if (effect.getValue("attachedTo") != null) { + Permanent attached = (Permanent) effect.getValue("attachedTo"); + if (attached != null) { + return attached.getPower().getValue(); + } + } + } + return 0; + } + + @Override + public DynamicValue copy() { + return new DyingWishAttachedPermanentPowerCount(); + } + + @Override + public String toString() { + return "X"; + } + + @Override + public String getMessage() { + return "its power"; + } +} diff --git a/Mage.Sets/src/mage/sets/gatecrash/HellkiteTyrant.java b/Mage.Sets/src/mage/sets/gatecrash/HellkiteTyrant.java index 20a1c1781f9..ff32625bf78 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/HellkiteTyrant.java +++ b/Mage.Sets/src/mage/sets/gatecrash/HellkiteTyrant.java @@ -77,13 +77,13 @@ public class HellkiteTyrant extends CardImpl { // Trample this.addAbility(TrampleAbility.getInstance()); // Whenever Hellkite Tyrant deals combat damage to a player, gain control of all artifacts that player controls. - this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new HellkiteTyrantEffect(),false, true)); + this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new HellkiteTyrantEffect(), false, true)); // At the beginning of your upkeep, if you control twenty or more artifacts, you win the game. TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(new WinGameSourceControllerEffect(), TargetController.YOU, false); this.addAbility(new ConditionalTriggeredAbility( ability, - new PermanentsOnTheBattlefieldCondition(new FilterArtifactPermanent(), PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN,19), + new PermanentsOnTheBattlefieldCondition(new FilterArtifactPermanent(), PermanentsOnTheBattlefieldCondition.CountType.MORE_THAN, 19), "At the beginning of your upkeep, if you control twenty or more artifacts, you win the game.")); } @@ -123,7 +123,7 @@ class HellkiteTyrantEffect extends OneShotEffect { FilterPermanent filter = new FilterArtifactPermanent(); filter.add(new ControllerIdPredicate(player.getId())); - List permanents = game.getBattlefield().getActivePermanents(filter, source.getControllerId() , game); + List permanents = game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game); for (Permanent permanent : permanents) { ContinuousEffect effect = new HellkiteTyrantControlEffect(source.getControllerId()); effect.setTargetPointer(new FixedTarget(permanent.getId())); diff --git a/Mage.Sets/src/mage/sets/gatecrash/SimicManipulator.java b/Mage.Sets/src/mage/sets/gatecrash/SimicManipulator.java index 195737b5175..2c846394b3e 100644 --- a/Mage.Sets/src/mage/sets/gatecrash/SimicManipulator.java +++ b/Mage.Sets/src/mage/sets/gatecrash/SimicManipulator.java @@ -1,40 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.sets.gatecrash; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.SubLayer; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.Mode; @@ -45,6 +38,13 @@ import mage.abilities.costs.common.TapSourceCost; import mage.abilities.effects.ContinuousEffectImpl; import mage.abilities.keyword.EvolveAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.common.FilterCreaturePermanent; import mage.game.Game; @@ -52,16 +52,17 @@ import mage.game.permanent.Permanent; import mage.target.common.TargetCreaturePermanent; /** -* Gatecrash FAQ (01.2013) -* -* The power of the target creature is checked both as you target it and as the ability -* resolves. If the power of the target creature when the ability resolves is greater -* than the number of +1/+1 counters removed from Simic Manipulator, the ability will -* be countered and none of its effects will happen. You won't gain control of any -* creature, but the counters removed as a cost remain removed. -* -* @author LevelX2 -*/ + * Gatecrash FAQ (01.2013) + * + * The power of the target creature is checked both as you target it and as the + * ability resolves. If the power of the target creature when the ability + * resolves is greater than the number of +1/+1 counters removed from Simic + * Manipulator, the ability will be countered and none of its effects will + * happen. You won't gain control of any creature, but the counters removed as a + * cost remain removed. + * + * @author LevelX2 + */ public class SimicManipulator extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with power less than or equal to the number of +1/+1 counters removed this way"); @@ -78,12 +79,12 @@ public class SimicManipulator extends CardImpl { // Evolve this.addAbility(new EvolveAbility()); - // {tap}, Remove one or more +1/+1 counters from Simic Manipulator: Gain control of target creature with power less than or equal to the number of +1/+1 counters removed this way. + // {T}, Remove one or more +1/+1 counters from Simic Manipulator: Gain control of target creature with power less than or equal to the number of +1/+1 counters removed this way. // TODO: Improve targeting, that only valid targets (power <= removed counters) can be choosen // Disadvantage now is, that a creature can be targeted that couldn't be targeted by rules. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SimicManipulatorGainControlTargetEffect(Duration.Custom), new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent(filter)); - ability.addCost(new RemoveVariableCountersSourceCost(CounterType.P1P1.createInstance(),1)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.P1P1.createInstance(), 1, "Remove one or more +1/+1 counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/guildpact/Ghostway.java b/Mage.Sets/src/mage/sets/guildpact/Ghostway.java index 776e27e8ac7..ab0e57b2cc7 100644 --- a/Mage.Sets/src/mage/sets/guildpact/Ghostway.java +++ b/Mage.Sets/src/mage/sets/guildpact/Ghostway.java @@ -31,8 +31,9 @@ import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; +import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.ReturnFromExileEffect; +import mage.abilities.effects.common.ReturnToBattlefieldUnderOwnerControlTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; @@ -45,6 +46,7 @@ import mage.filter.predicate.permanent.ControllerPredicate; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; +import mage.target.targetpointer.FixedTarget; import mage.util.CardUtil; /** @@ -94,22 +96,23 @@ class GhostwayEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = source.getSourceObject(game); if (sourceObject != null && controller != null) { - int numberCreatures = 0; UUID exileId = CardUtil.getExileZoneId(game, source.getSourceId(), source.getSourceObjectZoneChangeCounter()); for (Permanent creature : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game)) { if (creature != null) { - controller.moveCardToExileWithInfo(creature, exileId,sourceObject.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true); - numberCreatures++; + int zcc = game.getState().getZoneChangeCounter(creature.getId()); + controller.moveCardToExileWithInfo(creature, exileId, sourceObject.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true); + if (zcc == game.getState().getZoneChangeCounter(creature.getId()) - 1) { + Effect effect = new ReturnToBattlefieldUnderOwnerControlTargetEffect(); + effect.setTargetPointer(new FixedTarget(creature.getId(), zcc + 1)); + AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(effect); + + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } } } - if (numberCreatures > 0) { - AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility( - new ReturnFromExileEffect(exileId, Zone.BATTLEFIELD, false)); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); - } return true; } return false; diff --git a/Mage.Sets/src/mage/sets/guildpact/MizziumTransreliquat.java b/Mage.Sets/src/mage/sets/guildpact/MizziumTransreliquat.java new file mode 100644 index 00000000000..c1c75827a9b --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/MizziumTransreliquat.java @@ -0,0 +1,134 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetArtifactPermanent; +import mage.util.functions.EmptyApplyToPermanent; + +/** + * + * @author fireshoes + */ +public class MizziumTransreliquat extends CardImpl { + + public MizziumTransreliquat(UUID ownerId) { + super(ownerId, 153, "Mizzium Transreliquat", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "GPT"; + + // {3}: Mizzium Transreliquat becomes a copy of target artifact until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MizziumTransreliquatCopyEffect(), new ManaCostsImpl("{3}")); + ability.addTarget(new TargetArtifactPermanent()); + this.addAbility(ability); + + // {1}{U}{R}: Mizzium Transreliquat becomes a copy of target artifact and gains this ability. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MizziumTransreliquatCopyAndGainAbilityEffect(), new ManaCostsImpl("{1}{U}{R}")); + ability.addTarget(new TargetArtifactPermanent()); + this.addAbility(ability); + } + + public MizziumTransreliquat(final MizziumTransreliquat card) { + super(card); + } + + @Override + public MizziumTransreliquat copy() { + return new MizziumTransreliquat(this); + } +} + + +class MizziumTransreliquatCopyEffect extends OneShotEffect { + + public MizziumTransreliquatCopyEffect() { + super(Outcome.Copy); + this.staticText = "Mizzium Transreliquat becomes a copy of target artifact until end of turn"; + } + + public MizziumTransreliquatCopyEffect(final MizziumTransreliquatCopyEffect effect) { + super(effect); + } + + @Override + public MizziumTransreliquatCopyEffect copy() { + return new MizziumTransreliquatCopyEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent sourcePermanent = game.getPermanent(source.getSourceId()); + Permanent copyFromPermanent = game.getPermanent(getTargetPointer().getFirst(game, source)); + if (sourcePermanent != null && copyFromPermanent != null) { + game.copyPermanent(Duration.EndOfTurn, copyFromPermanent, sourcePermanent, source, new EmptyApplyToPermanent()); + return true; + } + return false; + } +} +class MizziumTransreliquatCopyAndGainAbilityEffect extends OneShotEffect { + + public MizziumTransreliquatCopyAndGainAbilityEffect() { + super(Outcome.Benefit); + this.staticText = "Mizzium Transreliquat becomes a copy of target artifact and gains this ability"; + } + + public MizziumTransreliquatCopyAndGainAbilityEffect(final MizziumTransreliquatCopyAndGainAbilityEffect effect) { + super(effect); + } + + @Override + public MizziumTransreliquatCopyAndGainAbilityEffect copy() { + return new MizziumTransreliquatCopyAndGainAbilityEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent sourcePermanent = game.getPermanent(source.getSourceId()); + Permanent copyFromPermanent = game.getPermanent(getTargetPointer().getFirst(game, source)); + if (sourcePermanent != null && copyFromPermanent != null) { + Permanent newPermanent = game.copyPermanent(copyFromPermanent, sourcePermanent, source, new EmptyApplyToPermanent()); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MizziumTransreliquatCopyAndGainAbilityEffect(), new ManaCostsImpl("{1}{U}{R}")); + ability.addTarget(new TargetArtifactPermanent()); + newPermanent.addAbility(ability, source.getSourceId(), game); + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/guildpact/OrderOfTheStars.java b/Mage.Sets/src/mage/sets/guildpact/OrderOfTheStars.java new file mode 100644 index 00000000000..aa78673766f --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/OrderOfTheStars.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.ChooseColorEffect; +import mage.abilities.effects.keyword.ProtectionChosenColorSourceEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class OrderOfTheStars extends CardImpl { + + public OrderOfTheStars(UUID ownerId) { + super(ownerId, 13, "Order of the Stars", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "GPT"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(0); + this.toughness = new MageInt(1); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // As Order of the Stars enters the battlefield, choose a color. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Benefit))); + + // Order of the Stars has protection from the chosen color. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ProtectionChosenColorSourceEffect())); + } + + public OrderOfTheStars(final OrderOfTheStars card) { + super(card); + } + + @Override + public OrderOfTheStars copy() { + return new OrderOfTheStars(this); + } +} diff --git a/Mage.Sets/src/mage/sets/guildpact/RumblingSlum.java b/Mage.Sets/src/mage/sets/guildpact/RumblingSlum.java new file mode 100644 index 00000000000..4b5834b987a --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/RumblingSlum.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamagePlayersEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class RumblingSlum extends CardImpl { + + public RumblingSlum(UUID ownerId) { + super(ownerId, 126, "Rumbling Slum", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{R}{G}{G}"); + this.expansionSetCode = "GPT"; + this.subtype.add("Elemental"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // At the beginning of your upkeep, Rumbling Slum deals 1 damage to each player. + Effect effect = new DamagePlayersEffect(1, TargetController.ANY); + effect.setText("{this} deals 1 damage to each player"); + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false)); + } + + public RumblingSlum(final RumblingSlum card) { + super(card); + } + + @Override + public RumblingSlum copy() { + return new RumblingSlum(this); + } +} diff --git a/Mage/src/mage/abilities/effects/common/continuous/SetCardColorSourceEffect.java b/Mage.Sets/src/mage/sets/guildpact/Schismotivate.java similarity index 50% rename from Mage/src/mage/abilities/effects/common/continuous/SetCardColorSourceEffect.java rename to Mage.Sets/src/mage/sets/guildpact/Schismotivate.java index e45ed9f9a42..4a1b7ac9ecb 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/SetCardColorSourceEffect.java +++ b/Mage.Sets/src/mage/sets/guildpact/Schismotivate.java @@ -1,101 +1,97 @@ -/* - * - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - * - */ - -package mage.abilities.effects.common.continuous; - -import mage.MageObject; -import mage.ObjectColor; -import mage.abilities.Ability; -import mage.abilities.Mode; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.SubLayer; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.game.stack.StackObject; - - -/** - * - * @author nicolas.perrenou - */ - - -public class SetCardColorSourceEffect extends ContinuousEffectImpl { - - private ObjectColor setColor; - - public SetCardColorSourceEffect(ObjectColor setColor, Duration duration, String text) { - super(duration, Layer.ColorChangingEffects_5, SubLayer.NA, Outcome.Benefit); - this.setColor = setColor; - staticText = text; - } - - public SetCardColorSourceEffect(ObjectColor setColor, Duration duration) { - super(duration, Layer.ColorChangingEffects_5, SubLayer.NA, Outcome.Benefit); - this.setColor = setColor; - } - - public SetCardColorSourceEffect(final SetCardColorSourceEffect effect) { - super(effect); - this.setColor = effect.setColor; - } - - @Override - public boolean apply(Game game, Ability source) { - MageObject o = game.getObject(source.getSourceId()); - if (o != null) { - if (o instanceof Permanent || o instanceof StackObject) { - o.getColor(game).setColor(setColor); - } - } - - return false; - } - - @Override - public SetCardColorSourceEffect copy() { - return new SetCardColorSourceEffect(this); - } - - @Override - public String getText(Mode mode) { - StringBuilder sb = new StringBuilder(); - sb.append("{this} "); - if (mode.getTargets().size() > 0) { - sb.append(mode.getTargets().get(0).getTargetName()); - } - sb.append(" becomes ").append(setColor.getDescription()); - sb.append(" ").append(duration.toString()); - return sb.toString(); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Schismotivate extends CardImpl { + + public Schismotivate(UUID ownerId) { + super(ownerId, 129, "Schismotivate", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{U}{R}"); + this.expansionSetCode = "GPT"; + + // Target creature gets +4/+0 until end of turn. Another target creature gets -4/-0 until end of turn. + this.getSpellAbility().addEffect(new SchismotivateEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(2)); + } + + public Schismotivate(final Schismotivate card) { + super(card); + } + + @Override + public Schismotivate copy() { + return new Schismotivate(this); + } +} + +class SchismotivateEffect extends ContinuousEffectImpl { + + public SchismotivateEffect() { + super(Duration.EndOfTurn, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, Outcome.BoostCreature); + this.staticText = "Target creature gets +4/+0 until end of turn. Another target creature gets -4/-0 until end of turn"; + } + + public SchismotivateEffect(final SchismotivateEffect effect) { + super(effect); + } + + @Override + public SchismotivateEffect copy() { + return new SchismotivateEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getFirstTarget()); + if (permanent != null) { + permanent.addPower(4); + } + permanent = game.getPermanent(source.getTargets().get(0).getTargets().get(1)); + if (permanent != null) { + permanent.addPower(-4); + } + return true; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/guildpact/StormHerd.java b/Mage.Sets/src/mage/sets/guildpact/StormHerd.java new file mode 100644 index 00000000000..0e623afe8bf --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/StormHerd.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.dynamicvalue.common.ControllerLifeCount; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.permanent.token.Token; + +/** + * + * @author fireshoes + */ +public class StormHerd extends CardImpl { + + public StormHerd(UUID ownerId) { + super(ownerId, 19, "Storm Herd", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{8}{W}{W}"); + this.expansionSetCode = "GPT"; + + // Put X 1/1 white Pegasus creature tokens with flying onto the battlefield, where X is your life total. + this.getSpellAbility().addEffect(new CreateTokenEffect(new PegasusToken(), new ControllerLifeCount())); + } + + public StormHerd(final StormHerd card) { + super(card); + } + + @Override + public StormHerd copy() { + return new StormHerd(this); + } +} + +class PegasusToken extends Token { + + public PegasusToken() { + super("Pegasus", "1/1 white Pegasus creature tokens with flying"); + cardType.add(CardType.CREATURE); + color.setWhite(true); + subtype.add("Pegasus"); + power = new MageInt(1); + toughness = new MageInt(1); + addAbility(FlyingAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/guildpact/VedalkenPlotter.java b/Mage.Sets/src/mage/sets/guildpact/VedalkenPlotter.java new file mode 100644 index 00000000000..6661a3cc3d1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/VedalkenPlotter.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.ExchangeControlTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class VedalkenPlotter extends CardImpl { + + private static final String rule = "exchange control of target land you control and target land an opponent controls"; + + private static final FilterLandPermanent filter = new FilterLandPermanent("land an opponent controls"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public VedalkenPlotter(UUID ownerId) { + super(ownerId, 41, "Vedalken Plotter", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "GPT"; + this.subtype.add("Vedalken"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // When Vedalken Plotter enters the battlefield, exchange control of target land you control and target land an opponent controls. + Effect effect = new ExchangeControlTargetEffect(Duration.EndOfGame, rule, false, true); + effect.setText("exchange control of target land you control and target land an opponent controls"); + Ability ability = new EntersBattlefieldTriggeredAbility(effect, false, true); + ability.addTarget(new TargetControlledPermanent(new FilterControlledLandPermanent())); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + public VedalkenPlotter(final VedalkenPlotter card) { + super(card); + } + + @Override + public VedalkenPlotter copy() { + return new VedalkenPlotter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/guildpact/YoreTillerNephilim.java b/Mage.Sets/src/mage/sets/guildpact/YoreTillerNephilim.java new file mode 100644 index 00000000000..9dae8433031 --- /dev/null +++ b/Mage.Sets/src/mage/sets/guildpact/YoreTillerNephilim.java @@ -0,0 +1,109 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.guildpact; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class YoreTillerNephilim extends CardImpl { + + public YoreTillerNephilim(UUID ownerId) { + super(ownerId, 140, "Yore-Tiller Nephilim", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W}{U}{B}{R}"); + this.expansionSetCode = "GPT"; + this.subtype.add("Nephilim"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Yore-Tiller Nephilim attacks, return target creature card from your graveyard to the battlefield tapped and attacking. + Ability ability = new AttacksTriggeredAbility(new YoreTillerNephilimEffect(), false); + ability.addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard())); + this.addAbility(ability); + } + + public YoreTillerNephilim(final YoreTillerNephilim card) { + super(card); + } + + @Override + public YoreTillerNephilim copy() { + return new YoreTillerNephilim(this); + } +} + +class YoreTillerNephilimEffect extends OneShotEffect { + + public YoreTillerNephilimEffect() { + super(Outcome.PutCreatureInPlay); + this.staticText = "return target creature card from your graveyard to the battlefield tapped and attacking"; + } + + public YoreTillerNephilimEffect(final YoreTillerNephilimEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + + if (controller != null) { + Card card = game.getCard(getTargetPointer().getFirst(game, source)); + if (card != null) { + if (card.putOntoBattlefield(game, Zone.GRAVEYARD, source.getSourceId(), source.getControllerId(), true)) { + Permanent permanent = game.getPermanent(card.getId()); + game.getCombat().addAttackingCreature(permanent.getId(), game); + } + } + return true; + + } + return false; + } + + @Override + public YoreTillerNephilimEffect copy() { + return new YoreTillerNephilimEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/heroesvsmonsters/OrcishLumberjack.java b/Mage.Sets/src/mage/sets/heroesvsmonsters/OrcishLumberjack.java index c6505ff9f7c..93277aa22f2 100644 --- a/Mage.Sets/src/mage/sets/heroesvsmonsters/OrcishLumberjack.java +++ b/Mage.Sets/src/mage/sets/heroesvsmonsters/OrcishLumberjack.java @@ -117,7 +117,7 @@ class OrcishLumberjackManaEffect extends ManaEffect { Mana mana = new Mana(); for(int i = 0; i < 3; i++){ while (!player.choose(Outcome.Benefit, manaChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/homelands/AnabaAncestor.java b/Mage.Sets/src/mage/sets/homelands/AnabaAncestor.java new file mode 100644 index 00000000000..5074961e95d --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/AnabaAncestor.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class AnabaAncestor extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Another target Minotaur creature"); + + static { + filter.add(new SubtypePredicate("Minotaur")); + filter.add(new AnotherPredicate()); + } + + public AnabaAncestor(UUID ownerId) { + super(ownerId, 81, "Anaba Ancestor", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "HML"; + this.subtype.add("Minotaur"); + this.subtype.add("Spirit"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Another target Minotaur creature gets +1/+1 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public AnabaAncestor(final AnabaAncestor card) { + super(card); + } + + @Override + public AnabaAncestor copy() { + return new AnabaAncestor(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/AnabaSpiritCrafter.java b/Mage.Sets/src/mage/sets/homelands/AnabaSpiritCrafter.java new file mode 100644 index 00000000000..53536b05900 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/AnabaSpiritCrafter.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class AnabaSpiritCrafter extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Minotaur creatures"); + + static { + filter.add(new SubtypePredicate("Minotaur")); + } + + public AnabaSpiritCrafter(UUID ownerId) { + super(ownerId, 86, "Anaba Spirit Crafter", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}{R}"); + this.expansionSetCode = "HML"; + this.subtype.add("Minotaur"); + this.subtype.add("Shaman"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Minotaur creatures get +1/+0. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 0, Duration.WhileOnBattlefield, filter, false))); + } + + public AnabaSpiritCrafter(final AnabaSpiritCrafter card) { + super(card); + } + + @Override + public AnabaSpiritCrafter copy() { + return new AnabaSpiritCrafter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/BaronSengir.java b/Mage.Sets/src/mage/sets/homelands/BaronSengir.java new file mode 100644 index 00000000000..1acc37a4fdc --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/BaronSengir.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class BaronSengir extends mage.sets.mastersedition.BaronSengir { + + public BaronSengir(UUID ownerId) { + super(ownerId); + this.cardNumber = 1; + this.expansionSetCode = "HML"; + } + + public BaronSengir(final BaronSengir card) { + super(card); + } + + @Override + public BaronSengir copy() { + return new BaronSengir(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/Didgeridoo.java b/Mage.Sets/src/mage/sets/homelands/Didgeridoo.java new file mode 100644 index 00000000000..96609bf2e04 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/Didgeridoo.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterPermanentCard; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class Didgeridoo extends CardImpl { + + private static final FilterPermanentCard filter = new FilterPermanentCard("a Minotaur permanent card"); + + static { + filter.add(new SubtypePredicate("Minotaur")); + } + + public Didgeridoo(UUID ownerId) { + super(ownerId, 130, "Didgeridoo", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "HML"; + + // {3}: You may put a Minotaur permanent card from your hand onto the battlefield. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutPermanentOnBattlefieldEffect(filter), new ManaCostsImpl("{3}"))); + } + + public Didgeridoo(final Didgeridoo card) { + super(card); + } + + @Override + public Didgeridoo copy() { + return new Didgeridoo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/Headstone.java b/Mage.Sets/src/mage/sets/homelands/Headstone.java new file mode 100644 index 00000000000..789598ae7ac --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/Headstone.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCardInGraveyard; + +/** + * + * @author fireshoes + */ +public class Headstone extends CardImpl { + + public Headstone(UUID ownerId) { + super(ownerId, 15, "Headstone", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "HML"; + + // Exile target card from a graveyard. + this.getSpellAbility().addEffect(new ExileTargetEffect()); + this.getSpellAbility().addTarget(new TargetCardInGraveyard()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Headstone(final Headstone card) { + super(card); + } + + @Override + public Headstone copy() { + return new Headstone(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/Jinx.java b/Mage.Sets/src/mage/sets/homelands/Jinx.java new file mode 100644 index 00000000000..7cadd458908 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/Jinx.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class Jinx extends CardImpl { + + public Jinx(UUID ownerId) { + super(ownerId, 36, "Jinx", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "HML"; + + // Target land becomes the basic land type of your choice until end of turn. + this.getSpellAbility().addEffect(new BecomesBasicLandTargetEffect(Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetLandPermanent()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Jinx(final Jinx card) { + super(card); + } + + @Override + public Jinx copy() { + return new Jinx(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/Marjhan.java b/Mage.Sets/src/mage/sets/homelands/Marjhan.java new file mode 100644 index 00000000000..d29651eddc9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/Marjhan.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Marjhan extends mage.sets.masterseditionii.Marjhan { + + public Marjhan(UUID ownerId) { + super(ownerId); + this.cardNumber = 39; + this.expansionSetCode = "HML"; + } + + public Marjhan(final Marjhan card) { + super(card); + } + + @Override + public Marjhan copy() { + return new Marjhan(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/Renewal.java b/Mage.Sets/src/mage/sets/homelands/Renewal.java new file mode 100644 index 00000000000..eea9df9d5cc --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/Renewal.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterBasicLandCard; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetCardInLibrary; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class Renewal extends CardImpl { + + public Renewal(UUID ownerId) { + super(ownerId, 66, "Renewal", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}"); + this.expansionSetCode = "HML"; + + // As an additional cost to cast Renewal, sacrifice a land. + this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land")))); + + // Search your library for a basic land card and put that card onto the battlefield. Then shuffle your library. + this.getSpellAbility().addEffect(new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(new FilterBasicLandCard()))); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Renewal(final Renewal card) { + super(card); + } + + @Override + public Renewal copy() { + return new Renewal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/SpectralBears.java b/Mage.Sets/src/mage/sets/homelands/SpectralBears.java new file mode 100644 index 00000000000..998177e34e2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/SpectralBears.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class SpectralBears extends mage.sets.mastersedition.SpectralBears { + + public SpectralBears(UUID ownerId) { + super(ownerId); + this.cardNumber = 72; + this.expansionSetCode = "HML"; + } + + public SpectralBears(final SpectralBears card) { + super(card); + } + + @Override + public SpectralBears copy() { + return new SpectralBears(this); + } +} diff --git a/Mage.Sets/src/mage/sets/homelands/WallOfKelp.java b/Mage.Sets/src/mage/sets/homelands/WallOfKelp.java new file mode 100644 index 00000000000..b3d29836185 --- /dev/null +++ b/Mage.Sets/src/mage/sets/homelands/WallOfKelp.java @@ -0,0 +1,91 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.homelands; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.permanent.token.Token; + +/** + * + * @author fireshoes + */ +public class WallOfKelp extends CardImpl { + + public WallOfKelp(UUID ownerId) { + super(ownerId, 50, "Wall of Kelp", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{U}{U}"); + this.expansionSetCode = "HML"; + this.subtype.add("Plant"); + this.subtype.add("Wall"); + this.power = new MageInt(0); + this.toughness = new MageInt(3); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // {U}{U}, {tap}: Put a 0/1 blue Plant Wall creature token with defender named Kelp onto the battlefield. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new KelpToken()), new ManaCostsImpl("{U}{U}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + } + + public WallOfKelp(final WallOfKelp card) { + super(card); + } + + @Override + public WallOfKelp copy() { + return new WallOfKelp(this); + } +} + +class KelpToken extends Token { + + public KelpToken() { + super("Kelp", "0/1 blue Plant Wall creature token with defender named Kelp"); + this.setOriginalExpansionSetCode("MIR"); + cardType.add(CardType.CREATURE); + color.setBlue(true); + subtype.add("Plant"); + subtype.add("Wall"); + power = new MageInt(0); + toughness = new MageInt(1); + + this.addAbility(DefenderAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/iceage/BarbedSextant.java b/Mage.Sets/src/mage/sets/iceage/BarbedSextant.java new file mode 100644 index 00000000000..1e75700d9ab --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/BarbedSextant.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.AnyColorManaAbility; +import mage.abilities.mana.ManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class BarbedSextant extends CardImpl { + + public BarbedSextant(UUID ownerId) { + super(ownerId, 287, "Barbed Sextant", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ICE"; + + // {1}, {tap}, Sacrifice Barbed Sextant: Add one mana of any color to your mana pool. Draw a card at the beginning of the next turn's upkeep. + ManaAbility ability = new AnyColorManaAbility(new GenericManaCost(1)); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1), Duration.OneUse), false)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public BarbedSextant(final BarbedSextant card) { + super(card); + } + + @Override + public BarbedSextant copy() { + return new BarbedSextant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/BlessedWine.java b/Mage.Sets/src/mage/sets/iceage/BlessedWine.java new file mode 100644 index 00000000000..106007dcc35 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/BlessedWine.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class BlessedWine extends mage.sets.fifthedition.BlessedWine { + + public BlessedWine(UUID ownerId) { + super(ownerId); + this.cardNumber = 231; + this.expansionSetCode = "ICE"; + } + + public BlessedWine(final BlessedWine card) { + super(card); + } + + @Override + public BlessedWine copy() { + return new BlessedWine(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/CurseOfMaritLage.java b/Mage.Sets/src/mage/sets/iceage/CurseOfMaritLage.java new file mode 100644 index 00000000000..4306cce6ccb --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/CurseOfMaritLage.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.abilities.effects.common.TapAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class CurseOfMaritLage extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Islands"); + + static { + filter.add(new SubtypePredicate("Island")); + } + + public CurseOfMaritLage(UUID ownerId) { + super(ownerId, 181, "Curse of Marit Lage", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{R}{R}"); + this.expansionSetCode = "ICE"; + + // When Curse of Marit Lage enters the battlefield, tap all Islands. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapAllEffect(filter))); + + // Islands don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); + } + + public CurseOfMaritLage(final CurseOfMaritLage card) { + super(card); + } + + @Override + public CurseOfMaritLage copy() { + return new CurseOfMaritLage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/DanceOfTheDead.java b/Mage.Sets/src/mage/sets/iceage/DanceOfTheDead.java index 8c694ba376d..5f308525d87 100644 --- a/Mage.Sets/src/mage/sets/iceage/DanceOfTheDead.java +++ b/Mage.Sets/src/mage/sets/iceage/DanceOfTheDead.java @@ -1,313 +1,312 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.iceage; - -import java.util.UUID; -import mage.MageObjectReference; -import mage.abilities.Ability; -import mage.abilities.Mode; -import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.common.LeavesBattlefieldTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.condition.common.SourceOnBattlefieldCondition; -import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.decorator.ConditionalTriggeredAbility; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.abilities.effects.Effect; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.DoIfCostPaid; -import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; -import mage.abilities.effects.common.DontUntapInControllersUntapStepSourceEffect; -import mage.abilities.effects.common.UntapEnchantedEffect; -import mage.abilities.effects.common.continuous.BoostEnchantedEffect; -import mage.abilities.effects.common.continuous.SourceEffect; -import mage.abilities.keyword.EnchantAbility; -import mage.cards.Card; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.SubLayer; -import mage.constants.TargetController; -import mage.constants.Zone; -import mage.filter.common.FilterCreatureCard; -import mage.filter.common.FilterCreaturePermanent; -import mage.filter.predicate.permanent.PermanentIdPredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; -import mage.target.Target; -import mage.target.common.TargetCardInGraveyard; -import mage.target.common.TargetCreaturePermanent; - -/** - * - * @author LevelX2 - */ -public class DanceOfTheDead extends CardImpl { - - public DanceOfTheDead(UUID ownerId) { - super(ownerId, 6, "Dance of the Dead", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); - this.expansionSetCode = "ICE"; - this.subtype.add("Aura"); - - - // Enchant creature card in a graveyard - TargetCardInGraveyard auraTarget = new TargetCardInGraveyard(new FilterCreatureCard("creature card in a graveyard")); - this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new DanceOfTheDeadAttachEffect(Outcome.PutCreatureInPlay)); - Ability enchantAbility = new EnchantAbility(auraTarget.getTargetName()); - this.addAbility(enchantAbility); - // When Dance of the Dead enters the battlefield, if it's on the battlefield, it loses "enchant creature card in a graveyard" and gains "enchant creature put onto the battlefield with Dance of the Dead." Put enchanted creature card to the battlefield tapped under your control and attach Dance of the Dead to it. When Dance of the Dead leaves the battlefield, that creature's controller sacrifices it. - Ability ability = new ConditionalTriggeredAbility( - new EntersBattlefieldTriggeredAbility(new DanceOfTheDeadReAttachEffect(), false), - SourceOnBattlefieldCondition.getInstance(), - "When {this} enters the battlefield, if it's on the battlefield, it loses \"enchant creature card in a graveyard\" and gains \"enchant creature put onto the battlefield with {this}.\" Return enchanted creature card to the battlefield under your control and attach {this} to it."); - ability.addEffect(new DanceOfTheDeadChangeAbilityEffect()); - this.addAbility(ability); - this.addAbility(new LeavesBattlefieldTriggeredAbility(new DanceOfTheDeadLeavesBattlefieldTriggeredEffect(), false)); - - // Enchanted creature gets +1/+1 and doesn't untap during its controller's untap step. - ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield)); - Effect effect = new DontUntapInControllersUntapStepEnchantedEffect(); - effect.setText("and doesn't untap during its controller's untap step"); - ability.addEffect(effect); - this.addAbility(ability); - - // At the beginning of the upkeep of enchanted creature's controller, that player may pay {1}{B}. If he or she does, untap that creature. - this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DanceOfTheDeadDoIfCostPaidEffect(), TargetController.CONTROLLER_ATTACHED_TO, false)); - - } - - public DanceOfTheDead(final DanceOfTheDead card) { - super(card); - } - - @Override - public DanceOfTheDead copy() { - return new DanceOfTheDead(this); - } -} - -class DanceOfTheDeadReAttachEffect extends OneShotEffect { - - public DanceOfTheDeadReAttachEffect() { - super(Outcome.Benefit); - this.staticText = "Return enchanted creature card to the battlefield under your control and attach {this} to it"; - } - - public DanceOfTheDeadReAttachEffect(final DanceOfTheDeadReAttachEffect effect) { - super(effect); - } - - @Override - public DanceOfTheDeadReAttachEffect copy() { - return new DanceOfTheDeadReAttachEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - Permanent enchantment = game.getPermanent(source.getSourceId()); - - if (controller != null && enchantment != null) { - Card cardInGraveyard = game.getCard(enchantment.getAttachedTo()); - if (cardInGraveyard == null) { - return true; - } - - // put card into play - controller.putOntoBattlefieldWithInfo(cardInGraveyard, game, Zone.GRAVEYARD, source.getSourceId(), true); - Permanent enchantedCreature = game.getPermanent(cardInGraveyard.getId()); - - FilterCreaturePermanent filter = new FilterCreaturePermanent("enchant creature put onto the battlefield with Dance of the Dead"); - filter.add(new PermanentIdPredicate(cardInGraveyard.getId())); - Target target = new TargetCreaturePermanent(filter); - //enchantAbility.setTargetName(target.getTargetName()); - if (enchantedCreature != null) { - target.addTarget(enchantedCreature.getId(), source, game); - enchantment.getSpellAbility().getTargets().clear(); - enchantment.getSpellAbility().getTargets().add(target); - enchantedCreature.addAttachment(enchantment.getId(), game); - } - return true; - } - - return false; - } -} - -class DanceOfTheDeadLeavesBattlefieldTriggeredEffect extends OneShotEffect { - - public DanceOfTheDeadLeavesBattlefieldTriggeredEffect() { - super(Outcome.Benefit); - this.staticText = "enchanted creature's controller sacrifices it"; - } - - public DanceOfTheDeadLeavesBattlefieldTriggeredEffect(final DanceOfTheDeadLeavesBattlefieldTriggeredEffect effect) { - super(effect); - } - - @Override - public DanceOfTheDeadLeavesBattlefieldTriggeredEffect copy() { - return new DanceOfTheDeadLeavesBattlefieldTriggeredEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); - if (controller != null && sourcePermanent != null) { - if (sourcePermanent.getAttachedTo() != null) { - Permanent attachedTo = game.getPermanent(sourcePermanent.getAttachedTo()); - if (attachedTo != null) { - attachedTo.sacrifice(source.getSourceId(), game); - } - } - return true; - } - return false; - } -} - -class DanceOfTheDeadAttachEffect extends OneShotEffect { - - public DanceOfTheDeadAttachEffect(Outcome outcome) { - super(outcome); - } - - public DanceOfTheDeadAttachEffect(Outcome outcome, String rule) { - super(outcome); - staticText = rule; - } - - public DanceOfTheDeadAttachEffect(final DanceOfTheDeadAttachEffect effect) { - super(effect); - } - - @Override - public DanceOfTheDeadAttachEffect copy() { - return new DanceOfTheDeadAttachEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Card card = game.getCard(source.getFirstTarget()); - if (card != null && game.getState().getZone(source.getFirstTarget()).equals(Zone.GRAVEYARD)) { - // Card have no attachedTo attribute yet so write ref only to enchantment now - Permanent enchantment = game.getPermanent(source.getSourceId()); - if (enchantment != null) { - enchantment.attachTo(card.getId(), game); - } - return true; - } - return false; - } - -} - -class DanceOfTheDeadChangeAbilityEffect extends ContinuousEffectImpl implements SourceEffect { - - private final static Ability newAbility = new EnchantAbility("creature put onto the battlefield with Dance of the Dead"); - - static { - newAbility.setRuleAtTheTop(true); - } - - public DanceOfTheDeadChangeAbilityEffect() { - super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); - staticText = "it loses \"enchant creature card in a graveyard\" and gains \"enchant creature put onto the battlefield with Dance of the Dead\""; - } - - - public DanceOfTheDeadChangeAbilityEffect(final DanceOfTheDeadChangeAbilityEffect effect) { - super(effect); - } - - @Override - public DanceOfTheDeadChangeAbilityEffect copy() { - return new DanceOfTheDeadChangeAbilityEffect(this); - } - - @Override - public void init(Ability source, Game game) { - super.init(source, game); - affectedObjectList.add(new MageObjectReference(source.getSourceId(), game)); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = affectedObjectList.get(0).getPermanent(game);; - if (permanent != null) { - Ability abilityToRemove = null; - for (Ability ability: permanent.getAbilities()) { - if (ability instanceof EnchantAbility) { - abilityToRemove = ability; - } - } - if (abilityToRemove != null) { - permanent.getAbilities().remove(abilityToRemove); - } - permanent.addAbility(newAbility, source.getSourceId(), game); - return true; - } - return false; - } -} - -class DanceOfTheDeadDoIfCostPaidEffect extends DoIfCostPaid { - - public DanceOfTheDeadDoIfCostPaidEffect() { - super(new UntapEnchantedEffect(), new ManaCostsImpl("{1}{B}")); - } - - public DanceOfTheDeadDoIfCostPaidEffect(final DanceOfTheDeadDoIfCostPaidEffect effect) { - super(effect); - } - - @Override - public DanceOfTheDeadDoIfCostPaidEffect copy() { - return new DanceOfTheDeadDoIfCostPaidEffect(this); - } - - @Override - protected Player getPayingPlayer(Game game, Ability source) { - Permanent attachment = game.getPermanent(source.getSourceId()); - Permanent attachedTo = game.getPermanent(attachment.getAttachedTo()); - return game.getPlayer(attachedTo.getControllerId()); - } - - @Override - public String getText(Mode mode) { - return new StringBuilder("that player may ").append(getCostText()) - .append(". If he or she does, ").append(executingEffects.getText(mode)).toString(); - } +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.MageObjectReference; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.SourceOnBattlefieldCondition; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.UntapEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.SourceEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.PermanentIdPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.Target; +import mage.target.common.TargetCardInGraveyard; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LevelX2 + */ +public class DanceOfTheDead extends CardImpl { + + public DanceOfTheDead(UUID ownerId) { + super(ownerId, 6, "Dance of the Dead", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); + this.expansionSetCode = "ICE"; + this.subtype.add("Aura"); + + + // Enchant creature card in a graveyard + TargetCardInGraveyard auraTarget = new TargetCardInGraveyard(new FilterCreatureCard("creature card in a graveyard")); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new DanceOfTheDeadAttachEffect(Outcome.PutCreatureInPlay)); + Ability enchantAbility = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(enchantAbility); + // When Dance of the Dead enters the battlefield, if it's on the battlefield, it loses "enchant creature card in a graveyard" and gains "enchant creature put onto the battlefield with Dance of the Dead." Put enchanted creature card to the battlefield tapped under your control and attach Dance of the Dead to it. When Dance of the Dead leaves the battlefield, that creature's controller sacrifices it. + Ability ability = new ConditionalTriggeredAbility( + new EntersBattlefieldTriggeredAbility(new DanceOfTheDeadReAttachEffect(), false), + SourceOnBattlefieldCondition.getInstance(), + "When {this} enters the battlefield, if it's on the battlefield, it loses \"enchant creature card in a graveyard\" and gains \"enchant creature put onto the battlefield with {this}.\" Return enchanted creature card to the battlefield under your control and attach {this} to it."); + ability.addEffect(new DanceOfTheDeadChangeAbilityEffect()); + this.addAbility(ability); + this.addAbility(new LeavesBattlefieldTriggeredAbility(new DanceOfTheDeadLeavesBattlefieldTriggeredEffect(), false)); + + // Enchanted creature gets +1/+1 and doesn't untap during its controller's untap step. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield)); + Effect effect = new DontUntapInControllersUntapStepEnchantedEffect(); + effect.setText("and doesn't untap during its controller's untap step"); + ability.addEffect(effect); + this.addAbility(ability); + + // At the beginning of the upkeep of enchanted creature's controller, that player may pay {1}{B}. If he or she does, untap that creature. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DanceOfTheDeadDoIfCostPaidEffect(), TargetController.CONTROLLER_ATTACHED_TO, false)); + + } + + public DanceOfTheDead(final DanceOfTheDead card) { + super(card); + } + + @Override + public DanceOfTheDead copy() { + return new DanceOfTheDead(this); + } +} + +class DanceOfTheDeadReAttachEffect extends OneShotEffect { + + public DanceOfTheDeadReAttachEffect() { + super(Outcome.Benefit); + this.staticText = "Return enchanted creature card to the battlefield under your control and attach {this} to it"; + } + + public DanceOfTheDeadReAttachEffect(final DanceOfTheDeadReAttachEffect effect) { + super(effect); + } + + @Override + public DanceOfTheDeadReAttachEffect copy() { + return new DanceOfTheDeadReAttachEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent enchantment = game.getPermanent(source.getSourceId()); + + if (controller != null && enchantment != null) { + Card cardInGraveyard = game.getCard(enchantment.getAttachedTo()); + if (cardInGraveyard == null) { + return true; + } + + // put card into play + controller.putOntoBattlefieldWithInfo(cardInGraveyard, game, Zone.GRAVEYARD, source.getSourceId(), true); + Permanent enchantedCreature = game.getPermanent(cardInGraveyard.getId()); + + FilterCreaturePermanent filter = new FilterCreaturePermanent("enchant creature put onto the battlefield with Dance of the Dead"); + filter.add(new PermanentIdPredicate(cardInGraveyard.getId())); + Target target = new TargetCreaturePermanent(filter); + //enchantAbility.setTargetName(target.getTargetName()); + if (enchantedCreature != null) { + target.addTarget(enchantedCreature.getId(), source, game); + enchantment.getSpellAbility().getTargets().clear(); + enchantment.getSpellAbility().getTargets().add(target); + enchantedCreature.addAttachment(enchantment.getId(), game); + } + return true; + } + + return false; + } +} + +class DanceOfTheDeadLeavesBattlefieldTriggeredEffect extends OneShotEffect { + + public DanceOfTheDeadLeavesBattlefieldTriggeredEffect() { + super(Outcome.Benefit); + this.staticText = "enchanted creature's controller sacrifices it"; + } + + public DanceOfTheDeadLeavesBattlefieldTriggeredEffect(final DanceOfTheDeadLeavesBattlefieldTriggeredEffect effect) { + super(effect); + } + + @Override + public DanceOfTheDeadLeavesBattlefieldTriggeredEffect copy() { + return new DanceOfTheDeadLeavesBattlefieldTriggeredEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if (controller != null && sourcePermanent != null) { + if (sourcePermanent.getAttachedTo() != null) { + Permanent attachedTo = game.getPermanent(sourcePermanent.getAttachedTo()); + if (attachedTo != null) { + attachedTo.sacrifice(source.getSourceId(), game); + } + } + return true; + } + return false; + } +} + +class DanceOfTheDeadAttachEffect extends OneShotEffect { + + public DanceOfTheDeadAttachEffect(Outcome outcome) { + super(outcome); + } + + public DanceOfTheDeadAttachEffect(Outcome outcome, String rule) { + super(outcome); + staticText = rule; + } + + public DanceOfTheDeadAttachEffect(final DanceOfTheDeadAttachEffect effect) { + super(effect); + } + + @Override + public DanceOfTheDeadAttachEffect copy() { + return new DanceOfTheDeadAttachEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Card card = game.getCard(source.getFirstTarget()); + if (card != null && game.getState().getZone(source.getFirstTarget()).equals(Zone.GRAVEYARD)) { + // Card have no attachedTo attribute yet so write ref only to enchantment now + Permanent enchantment = game.getPermanent(source.getSourceId()); + if (enchantment != null) { + enchantment.attachTo(card.getId(), game); + } + return true; + } + return false; + } + +} + +class DanceOfTheDeadChangeAbilityEffect extends ContinuousEffectImpl implements SourceEffect { + + private final static Ability newAbility = new EnchantAbility("creature put onto the battlefield with Dance of the Dead"); + + static { + newAbility.setRuleAtTheTop(true); + } + + public DanceOfTheDeadChangeAbilityEffect() { + super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); + staticText = "it loses \"enchant creature card in a graveyard\" and gains \"enchant creature put onto the battlefield with Dance of the Dead\""; + } + + + public DanceOfTheDeadChangeAbilityEffect(final DanceOfTheDeadChangeAbilityEffect effect) { + super(effect); + } + + @Override + public DanceOfTheDeadChangeAbilityEffect copy() { + return new DanceOfTheDeadChangeAbilityEffect(this); + } + + @Override + public void init(Ability source, Game game) { + super.init(source, game); + affectedObjectList.add(new MageObjectReference(source.getSourceId(), game)); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = affectedObjectList.get(0).getPermanent(game);; + if (permanent != null) { + Ability abilityToRemove = null; + for (Ability ability: permanent.getAbilities()) { + if (ability instanceof EnchantAbility) { + abilityToRemove = ability; + } + } + if (abilityToRemove != null) { + permanent.getAbilities().remove(abilityToRemove); + } + permanent.addAbility(newAbility, source.getSourceId(), game); + return true; + } + return false; + } +} + +class DanceOfTheDeadDoIfCostPaidEffect extends DoIfCostPaid { + + public DanceOfTheDeadDoIfCostPaidEffect() { + super(new UntapEnchantedEffect(), new ManaCostsImpl("{1}{B}")); + } + + public DanceOfTheDeadDoIfCostPaidEffect(final DanceOfTheDeadDoIfCostPaidEffect effect) { + super(effect); + } + + @Override + public DanceOfTheDeadDoIfCostPaidEffect copy() { + return new DanceOfTheDeadDoIfCostPaidEffect(this); + } + + @Override + protected Player getPayingPlayer(Game game, Ability source) { + Permanent attachment = game.getPermanent(source.getSourceId()); + Permanent attachedTo = game.getPermanent(attachment.getAttachedTo()); + return game.getPlayer(attachedTo.getControllerId()); + } + + @Override + public String getText(Mode mode) { + return new StringBuilder("that player may ").append(getCostText()) + .append(". If he or she does, ").append(executingEffects.getText(mode)).toString(); + } } \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/iceage/DemonicConsultation.java b/Mage.Sets/src/mage/sets/iceage/DemonicConsultation.java index 3400dc1a706..79f6528f5b4 100644 --- a/Mage.Sets/src/mage/sets/iceage/DemonicConsultation.java +++ b/Mage.Sets/src/mage/sets/iceage/DemonicConsultation.java @@ -28,6 +28,7 @@ package mage.sets.iceage; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; @@ -54,7 +55,6 @@ public class DemonicConsultation extends CardImpl { super(ownerId, 9, "Demonic Consultation", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{B}"); this.expansionSetCode = "ICE"; - // Name a card. Exile the top six cards of your library, then reveal cards from the top of your library until you reveal the named card. Put that card into your hand and exile all other cards revealed this way. this.getSpellAbility().addEffect(new DemonicConsultationEffect()); } @@ -70,63 +70,58 @@ public class DemonicConsultation extends CardImpl { } class DemonicConsultationEffect extends OneShotEffect { - + DemonicConsultationEffect() { super(Outcome.Benefit); this.staticText = "Name a card. Exile the top six cards of your library, then reveal cards from the top of your library until you reveal the named card. Put that card into your hand and exile all other cards revealed this way"; } - + DemonicConsultationEffect(final DemonicConsultationEffect effect) { super(effect); } - + @Override public DemonicConsultationEffect copy() { return new DemonicConsultationEffect(this); } - + @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { // Name a card. Choice choice = new ChoiceImpl(); choice.setChoices(CardRepository.instance.getNames()); - while (!player.choose(Outcome.Benefit, choice, game)) { - if (!player.isInGame()) { + while (!controller.choose(Outcome.Benefit, choice, game)) { + if (!controller.canRespond()) { return false; } } String name = choice.getChoice(); game.informPlayers("Card named: " + name); - + // Exile the top six cards of your library, - int num = Math.min(6, player.getLibrary().size()); - for (int i = 0; i < num; i++) { - Card card = player.getLibrary().removeFromTop(game); - if (card != null) { - player.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true); - } - } - + controller.moveCards(controller.getLibrary().getTopCards(game, 6), null, Zone.EXILED, source, game); + // then reveal cards from the top of your library until you reveal the named card. - Cards cards = new CardsImpl(Zone.LIBRARY); - while (player.getLibrary().size() > 0) { - Card card = player.getLibrary().removeFromTop(game); + Cards cardsToReaveal = new CardsImpl(); + Card cardToHand = null; + while (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().removeFromTop(game); if (card != null) { - cards.add(card); + cardsToReaveal.add(card); // Put that card into your hand if (card.getName().equals(name)) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + cardToHand = card; break; } - // and exile all other cards revealed this way. - else { - player.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true); - } } } - player.revealCards("Demonic Consultation", cards, game); + controller.moveCards(cardToHand, null, Zone.HAND, source, game); + controller.revealCards(sourceObject.getIdName(), cardsToReaveal, game); + cardsToReaveal.remove(cardToHand); + controller.moveCards(cardsToReaveal, null, Zone.EXILED, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/iceage/DwarvenArmory.java b/Mage.Sets/src/mage/sets/iceage/DwarvenArmory.java new file mode 100644 index 00000000000..4cc9dedfa91 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/DwarvenArmory.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class DwarvenArmory extends CardImpl { + + public DwarvenArmory(UUID ownerId) { + super(ownerId, 182, "Dwarven Armory", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}{R}"); + this.expansionSetCode = "ICE"; + + // {2}, Sacrifice a land: Put a +2/+2 counter on target creature. Activate this ability only during any upkeep step. + Ability ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new AddCountersTargetEffect(CounterType.P2P2.createInstance()), + new ManaCostsImpl("{2}"), + new IsStepCondition(PhaseStep.UPKEEP, false), + null); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent()))); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public DwarvenArmory(final DwarvenArmory card) { + super(card); + } + + @Override + public DwarvenArmory copy() { + return new DwarvenArmory(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Enervate.java b/Mage.Sets/src/mage/sets/iceage/Enervate.java new file mode 100644 index 00000000000..fa18468d1e0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Enervate.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Enervate extends mage.sets.masterseditionii.Enervate { + + public Enervate(UUID ownerId) { + super(ownerId); + this.cardNumber = 67; + this.expansionSetCode = "ICE"; + } + + public Enervate(final Enervate card) { + super(card); + } + + @Override + public Enervate copy() { + return new Enervate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Flare.java b/Mage.Sets/src/mage/sets/iceage/Flare.java new file mode 100644 index 00000000000..417b3ffdb1e --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Flare.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Flare extends mage.sets.fifthedition.Flare { + + public Flare(UUID ownerId) { + super(ownerId); + this.cardNumber = 185; + this.expansionSetCode = "ICE"; + } + + public Flare(final Flare card) { + super(card); + } + + @Override + public Flare copy() { + return new Flare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/ForgottenLore.java b/Mage.Sets/src/mage/sets/iceage/ForgottenLore.java new file mode 100644 index 00000000000..48aeebbb97b --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/ForgottenLore.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ForgottenLore extends mage.sets.masterseditionii.ForgottenLore { + + public ForgottenLore(UUID ownerId) { + super(ownerId); + this.cardNumber = 125; + this.expansionSetCode = "ICE"; + } + + public ForgottenLore(final ForgottenLore card) { + super(card); + } + + @Override + public ForgottenLore copy() { + return new ForgottenLore(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/GorillaPack.java b/Mage.Sets/src/mage/sets/iceage/GorillaPack.java new file mode 100644 index 00000000000..8e7d6c4e10e --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/GorillaPack.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class GorillaPack extends CardImpl { + + public GorillaPack(UUID ownerId) { + super(ownerId, 135, "Gorilla Pack", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "ICE"; + this.subtype.add("Ape"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Gorilla Pack can't attack unless defending player controls a Forest. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Forest", "a Forest")))); + + // When you control no Forests, sacrifice Gorilla Pack. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Forest", "no Forests"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public GorillaPack(final GorillaPack card) { + super(card); + } + + @Override + public GorillaPack copy() { + return new GorillaPack(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Infuse.java b/Mage.Sets/src/mage/sets/iceage/Infuse.java new file mode 100644 index 00000000000..d531e6be499 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Infuse.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class Infuse extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public Infuse(UUID ownerId) { + super(ownerId, 80, "Infuse", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{U}"); + this.expansionSetCode = "ICE"; + + // Untap target artifact, creature, or land. + this.getSpellAbility().addEffect(new UntapTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Infuse(final Infuse card) { + super(card); + } + + @Override + public Infuse copy() { + return new Infuse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/KarplusanYeti.java b/Mage.Sets/src/mage/sets/iceage/KarplusanYeti.java new file mode 100644 index 00000000000..6012dd2abe1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/KarplusanYeti.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageEachOtherEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class KarplusanYeti extends CardImpl { + + public KarplusanYeti(UUID ownerId) { + super(ownerId, 197, "Karplusan Yeti", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{R}{R}"); + this.expansionSetCode = "ICE"; + this.subtype.add("Yeti"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {T}: Karplusan Yeti deals damage equal to its power to target creature. That creature deals damage equal to its power to Karplusan Yeti. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEachOtherEffect(), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public KarplusanYeti(final KarplusanYeti card) { + super(card); + } + + @Override + public KarplusanYeti copy() { + return new KarplusanYeti(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/KrovikanFetish.java b/Mage.Sets/src/mage/sets/iceage/KrovikanFetish.java new file mode 100644 index 00000000000..88688aeb24d --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/KrovikanFetish.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class KrovikanFetish extends mage.sets.fifthedition.KrovikanFetish { + + public KrovikanFetish(UUID ownerId) { + super(ownerId); + this.cardNumber = 28; + this.expansionSetCode = "ICE"; + } + + public KrovikanFetish(final KrovikanFetish card) { + super(card); + } + + @Override + public KrovikanFetish copy() { + return new KrovikanFetish(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/MindRavel.java b/Mage.Sets/src/mage/sets/iceage/MindRavel.java new file mode 100644 index 00000000000..2495044d096 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/MindRavel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class MindRavel extends mage.sets.fifthedition.MindRavel { + + public MindRavel(UUID ownerId) { + super(ownerId); + this.cardNumber = 35; + this.expansionSetCode = "ICE"; + } + + public MindRavel(final MindRavel card) { + super(card); + } + + @Override + public MindRavel copy() { + return new MindRavel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/MindWarp.java b/Mage.Sets/src/mage/sets/iceage/MindWarp.java index d64c55a9dc5..0d6cbb17f83 100644 --- a/Mage.Sets/src/mage/sets/iceage/MindWarp.java +++ b/Mage.Sets/src/mage/sets/iceage/MindWarp.java @@ -43,7 +43,7 @@ import mage.target.TargetPlayer; public class MindWarp extends CardImpl { public MindWarp(UUID ownerId) { - super(ownerId, 14, "Mind Warp", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{X}{3}{B}"); + super(ownerId, 36, "Mind Warp", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{X}{3}{B}"); this.expansionSetCode = "ICE"; diff --git a/Mage.Sets/src/mage/sets/iceage/Necropotence.java b/Mage.Sets/src/mage/sets/iceage/Necropotence.java index 60044a1b7bd..40d11e6a202 100644 --- a/Mage.Sets/src/mage/sets/iceage/Necropotence.java +++ b/Mage.Sets/src/mage/sets/iceage/Necropotence.java @@ -64,14 +64,14 @@ public class Necropotence extends CardImpl { this.expansionSetCode = "ICE"; // Skip your draw step. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new SkipDrawStepEffect())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new SkipDrawStepEffect())); // Whenever you discard a card, exile that card from your graveyard. Effect effect = new ExileTargetEffect(null, "", Zone.GRAVEYARD); effect.setText("exile that card from your graveyard"); this.addAbility(new NecropotenceTriggeredAbility(effect)); // Pay 1 life: Exile the top card of your library face down. Put that card into your hand at the beginning of your next end step. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new NecropotenceEffect(), new PayLifeCost(1))); - + } public Necropotence(final Necropotence card) { @@ -85,8 +85,9 @@ public class Necropotence extends CardImpl { } class NecropotenceTriggeredAbility extends TriggeredAbilityImpl { + NecropotenceTriggeredAbility(Effect effect) { - super(Zone.BATTLEFIELD, effect , false); + super(Zone.BATTLEFIELD, effect, false); } NecropotenceTriggeredAbility(final NecropotenceTriggeredAbility ability) { @@ -105,10 +106,10 @@ class NecropotenceTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - if (getControllerId().equals(event.getPlayerId())) { - this.getEffects().get(0).setTargetPointer(new FixedTarget(event.getTargetId())); - return true; - } + if (getControllerId().equals(event.getPlayerId())) { + this.getEffects().get(0).setTargetPointer(new FixedTarget(event.getTargetId())); + return true; + } return false; } @@ -119,21 +120,21 @@ class NecropotenceTriggeredAbility extends TriggeredAbilityImpl { } class NecropotenceEffect extends OneShotEffect { - + public NecropotenceEffect() { super(Outcome.Benefit); this.staticText = "Exile the top card of your library face down. Put that card into your hand at the beginning of your next end step"; } - + public NecropotenceEffect(final NecropotenceEffect effect) { super(effect); } - + @Override public NecropotenceEffect copy() { return new NecropotenceEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -142,14 +143,14 @@ class NecropotenceEffect extends OneShotEffect { Card card = controller.getLibrary().removeFromTop(game); if (controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, false)) { card.setFaceDown(true, game); - Effect returnToHandeffect = new ReturnToHandTargetEffect(false); - returnToHandeffect.setText("put that face down card into your hand"); - returnToHandeffect.setTargetPointer(new FixedTarget(card.getId())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(returnToHandeffect, TargetController.YOU); + Effect returnToHandEffect = new ReturnToHandTargetEffect(false); + returnToHandEffect.setText("put that face down card into your hand"); + returnToHandEffect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(returnToHandEffect, TargetController.YOU); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + game.addDelayedTriggeredAbility(delayedAbility); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/iceage/OrcishLibrarian.java b/Mage.Sets/src/mage/sets/iceage/OrcishLibrarian.java index d222dabce1b..2d1db6c7eb2 100644 --- a/Mage.Sets/src/mage/sets/iceage/OrcishLibrarian.java +++ b/Mage.Sets/src/mage/sets/iceage/OrcishLibrarian.java @@ -121,7 +121,7 @@ class OrcishLibrarianEffect extends OneShotEffect { } player.lookAtCards("OrcishLibrarian", cards, game); TargetCard target = new TargetCard (Zone.PICK, new FilterCard("card to put on the top of target player's library")); - while (player.isInGame() && cards.size() > 0) { + while (player.canRespond() && cards.size() > 0) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/iceage/Panic.java b/Mage.Sets/src/mage/sets/iceage/Panic.java new file mode 100644 index 00000000000..65e1c110b94 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Panic.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Panic extends mage.sets.masterseditionii.Panic { + + public Panic(UUID ownerId) { + super(ownerId); + this.cardNumber = 212; + this.expansionSetCode = "ICE"; + } + + public Panic(final Panic card) { + super(card); + } + + @Override + public Panic copy() { + return new Panic(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Seizures.java b/Mage.Sets/src/mage/sets/iceage/Seizures.java new file mode 100644 index 00000000000..5fdc2881cc2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Seizures.java @@ -0,0 +1,121 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BecomesTappedAttachedTriggeredAbility; +import mage.abilities.costs.Cost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Seizures extends CardImpl { + + public Seizures(UUID ownerId) { + super(ownerId, 47, "Seizures", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); + this.expansionSetCode = "ICE"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Whenever enchanted creature becomes tapped, Seizures deals 3 damage to that creature's controller unless that player pays {3}. + this.addAbility(new BecomesTappedAttachedTriggeredAbility(new SeizuresEffect(), false)); + } + + public Seizures(final Seizures card) { + super(card); + } + + @Override + public Seizures copy() { + return new Seizures(this); + } +} + + +class SeizuresEffect extends OneShotEffect { + + public SeizuresEffect() { + super(Outcome.Damage); + staticText = "{this} deals 3 damage to that creature's controller unless that player pays {3}"; + } + + public SeizuresEffect(final SeizuresEffect effect) { + super(effect); + } + + @Override + public SeizuresEffect copy() { + return new SeizuresEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent enchantment = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if(enchantment == null) { + return false; + } + Permanent enchanted = game.getPermanentOrLKIBattlefield(enchantment.getAttachedTo()); + if(enchanted == null) { + return false; + } + Player player = game.getPlayer(enchanted.getControllerId()); + if(player != null) { + Cost cost = new ManaCostsImpl("{3}"); + if(cost.canPay(source, source.getSourceId(), player.getId(), game) + && player.chooseUse(Outcome.Benefit, "Pay " + cost.getText() + " to avoid damage?", source, game)) { + cost.clearPaid(); + if(cost.pay(source, game, source.getSourceId(), player.getId(), false)) { + return true; + } + } + player.damage(3, source.getSourceId(), game, false, true); + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/ShieldOfTheAges.java b/Mage.Sets/src/mage/sets/iceage/ShieldOfTheAges.java new file mode 100644 index 00000000000..62bebd747b7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/ShieldOfTheAges.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ShieldOfTheAges extends mage.sets.mastersedition.ShieldOfTheAges { + + public ShieldOfTheAges(UUID ownerId) { + super(ownerId); + this.cardNumber = 310; + this.expansionSetCode = "ICE"; + } + + public ShieldOfTheAges(final ShieldOfTheAges card) { + super(card); + } + + @Override + public ShieldOfTheAges copy() { + return new ShieldOfTheAges(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/SkeletonShip.java b/Mage.Sets/src/mage/sets/iceage/SkeletonShip.java new file mode 100644 index 00000000000..38a31f5b63c --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/SkeletonShip.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SkeletonShip extends CardImpl { + + public SkeletonShip(UUID ownerId) { + super(ownerId, 379, "Skeleton Ship", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "ICE"; + this.supertype.add("Legendary"); + this.subtype.add("Skeleton"); + this.power = new MageInt(0); + this.toughness = new MageInt(3); + + // When you control no Islands, sacrifice Skeleton Ship. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + + // {tap}: Put a -1/-1 counter on target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.M1M1.createInstance()), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public SkeletonShip(final SkeletonShip card) { + super(card); + } + + @Override + public SkeletonShip copy() { + return new SkeletonShip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Stonehands.java b/Mage.Sets/src/mage/sets/iceage/Stonehands.java new file mode 100644 index 00000000000..f95b429eb5b --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Stonehands.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Stonehands extends CardImpl { + + public Stonehands(UUID ownerId) { + super(ownerId, 219, "Stonehands", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}"); + this.expansionSetCode = "ICE"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature gets +0/+2. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(0,2, Duration.WhileOnBattlefield))); + + // {R}: Enchanted creature gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.R))); + } + + public Stonehands(final Stonehands card) { + super(card); + } + + @Override + public Stonehands copy() { + return new Stonehands(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/TimeBomb.java b/Mage.Sets/src/mage/sets/iceage/TimeBomb.java new file mode 100644 index 00000000000..a707e9dc092 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/TimeBomb.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class TimeBomb extends mage.sets.masterseditionii.TimeBomb { + + public TimeBomb(UUID ownerId) { + super(ownerId); + this.cardNumber = 317; + this.expansionSetCode = "ICE"; + } + + public TimeBomb(final TimeBomb card) { + super(card); + } + + @Override + public TimeBomb copy() { + return new TimeBomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/TouchOfDeath.java b/Mage.Sets/src/mage/sets/iceage/TouchOfDeath.java new file mode 100644 index 00000000000..a10fd45d37f --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/TouchOfDeath.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class TouchOfDeath extends CardImpl { + + public TouchOfDeath(UUID ownerId) { + super(ownerId, 55, "Touch of Death", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{B}"); + this.expansionSetCode = "ICE"; + + // Touch of Death deals 1 damage to target player. You gain 1 life. + this.getSpellAbility().addEffect(new DamageTargetEffect(1)); + this.getSpellAbility().addTarget(new TargetPlayer()); + this.getSpellAbility().addEffect(new GainLifeEffect(1)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public TouchOfDeath(final TouchOfDeath card) { + super(card); + } + + @Override + public TouchOfDeath copy() { + return new TouchOfDeath(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/Updraft.java b/Mage.Sets/src/mage/sets/iceage/Updraft.java new file mode 100644 index 00000000000..64254f22b38 --- /dev/null +++ b/Mage.Sets/src/mage/sets/iceage/Updraft.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Updraft extends CardImpl { + + public Updraft(UUID ownerId) { + super(ownerId, 105, "Updraft", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "ICE"; + + // Target creature gains flying until end of turn. + this.getSpellAbility().addEffect(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Updraft(final Updraft card) { + super(card); + } + + @Override + public Updraft copy() { + return new Updraft(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/WrathOfMaritLage.java b/Mage.Sets/src/mage/sets/iceage/WrathOfMaritLage.java index ba13bc802ba..c190395735e 100644 --- a/Mage.Sets/src/mage/sets/iceage/WrathOfMaritLage.java +++ b/Mage.Sets/src/mage/sets/iceage/WrathOfMaritLage.java @@ -1,109 +1,77 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.iceage; - -import java.util.List; -import java.util.UUID; -import mage.ObjectColor; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.constants.Zone; -import mage.filter.common.FilterCreaturePermanent; -import mage.filter.predicate.mageobject.ColorPredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; - -/** - * - * @author Plopman - */ -public class WrathOfMaritLage extends CardImpl { - - public static final FilterCreaturePermanent filter = new FilterCreaturePermanent("red creatures"); - - static { - filter.add(new ColorPredicate(ObjectColor.RED)); - } - - - public WrathOfMaritLage(UUID ownerId) { - super(ownerId, 109, "Wrath of Marit Lage", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}{U}"); - this.expansionSetCode = "ICE"; - - - // When Wrath of Marit Lage enters the battlefield, tap all red creatures. - this.addAbility(new EntersBattlefieldTriggeredAbility(new TapAllEffect())); - // Red creatures don't untap during their controllers' untap steps. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); - } - - public WrathOfMaritLage(final WrathOfMaritLage card) { - super(card); - } - - @Override - public WrathOfMaritLage copy() { - return new WrathOfMaritLage(this); - } -} - -class TapAllEffect extends OneShotEffect { - - public TapAllEffect() { - super(Outcome.Tap); - staticText = "tap all red creatures"; - } - - public TapAllEffect(final TapAllEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - - List creatures = game.getBattlefield().getActivePermanents(WrathOfMaritLage.filter, source.getSourceId(), game); - for (Permanent creature : creatures) { - creature.tap(game); - } - return true; - } - - @Override - public TapAllEffect copy() { - return new TapAllEffect(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.iceage; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.abilities.effects.common.TapAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author Plopman + */ +public class WrathOfMaritLage extends CardImpl { + + public static final FilterCreaturePermanent filter = new FilterCreaturePermanent("red creatures"); + + static { + filter.add(new ColorPredicate(ObjectColor.RED)); + } + + public WrathOfMaritLage(UUID ownerId) { + super(ownerId, 109, "Wrath of Marit Lage", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}{U}"); + this.expansionSetCode = "ICE"; + + + // When Wrath of Marit Lage enters the battlefield, tap all red creatures. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapAllEffect(filter))); + // Red creatures don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); + } + + public WrathOfMaritLage(final WrathOfMaritLage card) { + super(card); + } + + @Override + public WrathOfMaritLage copy() { + return new WrathOfMaritLage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/iceage/ZursWeirding.java b/Mage.Sets/src/mage/sets/iceage/ZursWeirding.java index ebee9cfe3df..7d722651097 100644 --- a/Mage.Sets/src/mage/sets/iceage/ZursWeirding.java +++ b/Mage.Sets/src/mage/sets/iceage/ZursWeirding.java @@ -31,17 +31,16 @@ import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.ContinuousEffectImpl; import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.continuous.PlayWithHandRevealedEffect; import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Layer; import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.SubLayer; +import mage.constants.TargetController; import mage.constants.Zone; import mage.game.Game; import mage.game.events.GameEvent; @@ -59,8 +58,8 @@ public class ZursWeirding extends CardImpl { this.expansionSetCode = "ICE"; // Players play with their hands revealed. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayerRevealHandCardsEffect())); - + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithHandRevealedEffect(TargetController.ANY))); + // If a player would draw a card, he or she reveals it instead. Then any other player may pay 2 life. If a player does, put that card into its owner's graveyard. Otherwise, that player draws a card. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ZursWeirdingReplacementEffect())); } @@ -81,7 +80,7 @@ class ZursWeirdingReplacementEffect extends ReplacementEffectImpl { super(Duration.WhileOnBattlefield, Outcome.Neutral); this.staticText = "If a player would draw a card, he or she reveals it instead. Then any other player may pay 2 life. If a player does, put that card into its owner's graveyard. Otherwise, that player draws a card."; } - + public ZursWeirdingReplacementEffect(final ZursWeirdingReplacementEffect effect) { super(effect); } @@ -90,7 +89,7 @@ class ZursWeirdingReplacementEffect extends ReplacementEffectImpl { public ZursWeirdingReplacementEffect copy() { return new ZursWeirdingReplacementEffect(this); } - + @Override public boolean apply(Game game, Ability source) { return true; @@ -105,7 +104,7 @@ class ZursWeirdingReplacementEffect extends ReplacementEffectImpl { if (card != null) { // reveals it instead player.revealCards(sourceObject.getIdName() + " next draw of " + player.getName() + " (" + game.getTurnNum()+"|"+game.getPhase().getType() +")", new CardsImpl(card), game); - + // Then any other player may pay 2 life. If a player does, put that card into its owner's graveyard PlayerList playerList = game.getPlayerList().copy(); playerList.setCurrent(player.getId()); @@ -116,14 +115,14 @@ class ZursWeirdingReplacementEffect extends ReplacementEffectImpl { currentPlayer.getLife() >= 2 && currentPlayer.chooseUse(Outcome.Benefit, message, source, game)) { currentPlayer.loseLife(2, game); - player.moveCards(card, Zone.LIBRARY, Zone.GRAVEYARD, source, game); + player.moveCards(card, Zone.LIBRARY, Zone.GRAVEYARD, source, game); // game.getState().getRevealed().reset(); return true; } - + currentPlayer = playerList.getNext(game); } - + // game.getState().getRevealed().reset(); } } @@ -132,43 +131,11 @@ class ZursWeirdingReplacementEffect extends ReplacementEffectImpl { @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.DRAW_CARD; - } + } @Override public boolean applies(GameEvent event, Ability source, Game game) { return true; } - -} -class PlayerRevealHandCardsEffect extends ContinuousEffectImpl { - - public PlayerRevealHandCardsEffect() { - super(Duration.WhileOnBattlefield, Layer.PlayerEffects, SubLayer.NA, Outcome.Detriment); - staticText = "Players play with their hands revealed"; - } - - public PlayerRevealHandCardsEffect(final PlayerRevealHandCardsEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - for (UUID playerID : controller.getInRange()) { - Player player = game.getPlayer(playerID); - if (player != null) { - player.revealCards(player.getName() + "'s hand cards", player.getHand(), game, false); - } - } - return true; - } - return false; - } - - @Override - public PlayerRevealHandCardsEffect copy() { - return new PlayerRevealHandCardsEffect(this); - } } diff --git a/Mage.Sets/src/mage/sets/innistrad/ArmyOfTheDamned.java b/Mage.Sets/src/mage/sets/innistrad/ArmyOfTheDamned.java index 1ab4ba853f5..a80ff5eac53 100644 --- a/Mage.Sets/src/mage/sets/innistrad/ArmyOfTheDamned.java +++ b/Mage.Sets/src/mage/sets/innistrad/ArmyOfTheDamned.java @@ -37,7 +37,6 @@ import mage.constants.Rarity; import mage.constants.TimingRule; import mage.game.permanent.token.ZombieToken; - /** * @author nantuko */ @@ -47,9 +46,8 @@ public class ArmyOfTheDamned extends CardImpl { super(ownerId, 87, "Army of the Damned", Rarity.MYTHIC, new CardType[]{CardType.SORCERY}, "{5}{B}{B}{B}"); this.expansionSetCode = "ISD"; - // Put thirteen 2/2 black Zombie creature tokens onto the battlefield tapped. - this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken("ISD"), 13, true, false)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken(), 13, true, false)); // Flashback {7}{B}{B}{B} this.addAbility(new FlashbackAbility(new ManaCostsImpl("{7}{B}{B}{B}"), TimingRule.SORCERY)); diff --git a/Mage.Sets/src/mage/sets/innistrad/CaravanVigil.java b/Mage.Sets/src/mage/sets/innistrad/CaravanVigil.java index aed1c1e2af2..4dc4e3bd417 100644 --- a/Mage.Sets/src/mage/sets/innistrad/CaravanVigil.java +++ b/Mage.Sets/src/mage/sets/innistrad/CaravanVigil.java @@ -29,10 +29,6 @@ package mage.sets.innistrad; import java.util.UUID; import mage.MageObject; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.condition.common.MorbidCondition; import mage.abilities.effects.OneShotEffect; @@ -40,6 +36,10 @@ import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterBasicLandCard; import mage.game.Game; import mage.players.Player; @@ -55,7 +55,6 @@ public class CaravanVigil extends CardImpl { super(ownerId, 173, "Caravan Vigil", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{G}"); this.expansionSetCode = "ISD"; - // Search your library for a basic land card, reveal it, put it into your hand, then shuffle your library. // Morbid - You may put that card onto the battlefield instead of putting it into your hand if a creature died this turn. this.getSpellAbility().addEffect(new CaravanVigilEffect()); @@ -103,10 +102,10 @@ class CaravanVigilEffect extends OneShotEffect { && controller.chooseUse(Outcome.PutLandInPlay, "Do you wish to put the card onto the battlefield instead?", source, game)) { controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); } else { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); } - controller.revealCards(sourceObject.getName(), cards, game); - } + controller.revealCards(sourceObject.getIdName(), cards, game); + } } controller.shuffleLibrary(game); return true; diff --git a/Mage.Sets/src/mage/sets/innistrad/CellarDoor.java b/Mage.Sets/src/mage/sets/innistrad/CellarDoor.java index e209ee7f2d4..869b49fbebc 100644 --- a/Mage.Sets/src/mage/sets/innistrad/CellarDoor.java +++ b/Mage.Sets/src/mage/sets/innistrad/CellarDoor.java @@ -28,10 +28,6 @@ package mage.sets.innistrad; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; @@ -39,6 +35,10 @@ import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.token.ZombieToken; import mage.players.Player; @@ -95,7 +95,7 @@ class CellarDoorEffect extends OneShotEffect { if (card != null) { player.moveCards(card, Zone.LIBRARY, Zone.GRAVEYARD, source, game); if (card.getCardType().contains(CardType.CREATURE)) { - ZombieToken token = new ZombieToken("ISD"); + ZombieToken token = new ZombieToken(); token.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); } } diff --git a/Mage.Sets/src/mage/sets/innistrad/Claustrophobia.java b/Mage.Sets/src/mage/sets/innistrad/Claustrophobia.java index 8bec3eda852..2261417a9a7 100644 --- a/Mage.Sets/src/mage/sets/innistrad/Claustrophobia.java +++ b/Mage.Sets/src/mage/sets/innistrad/Claustrophobia.java @@ -1,76 +1,77 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.innistrad; - -import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; -import mage.abilities.effects.common.TapEnchantedEffect; -import mage.abilities.keyword.EnchantAbility; -import mage.cards.CardImpl; -import mage.target.TargetPermanent; -import mage.target.common.TargetCreaturePermanent; - -/** - * @author Loki - */ -public class Claustrophobia extends CardImpl { - - public Claustrophobia(UUID ownerId) { - super(ownerId, 48, "Claustrophobia", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}{U}"); - this.expansionSetCode = "ISD"; - this.subtype.add("Aura"); - - - // Enchant creature - TargetPermanent auraTarget = new TargetCreaturePermanent(); - this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); - this.addAbility(new EnchantAbility(auraTarget.getTargetName())); - // When Claustrophobia enters the battlefield, tap enchanted creature. - this.addAbility(new EntersBattlefieldTriggeredAbility(new TapEnchantedEffect())); - // Enchanted creature doesn't untap during its controller's untap step. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepEnchantedEffect())); - } - - public Claustrophobia(final Claustrophobia card) { - super(card); - } - - @Override - public Claustrophobia copy() { - return new Claustrophobia(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.innistrad; + +import java.util.UUID; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.TapEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * @author Loki + */ +public class Claustrophobia extends CardImpl { + + public Claustrophobia(UUID ownerId) { + super(ownerId, 48, "Claustrophobia", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}{U}"); + this.expansionSetCode = "ISD"; + this.subtype.add("Aura"); + + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // When Claustrophobia enters the battlefield, tap enchanted creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapEnchantedEffect())); + + // Enchanted creature doesn't untap during its controller's untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepEnchantedEffect())); + } + + public Claustrophobia(final Claustrophobia card) { + super(card); + } + + @Override + public Claustrophobia copy() { + return new Claustrophobia(this); + } +} diff --git a/Mage.Sets/src/mage/sets/innistrad/CreepingRenaissance.java b/Mage.Sets/src/mage/sets/innistrad/CreepingRenaissance.java index 1049985b973..d43daaec59b 100644 --- a/Mage.Sets/src/mage/sets/innistrad/CreepingRenaissance.java +++ b/Mage.Sets/src/mage/sets/innistrad/CreepingRenaissance.java @@ -93,7 +93,7 @@ class CreepingRenaissanceEffect extends OneShotEffect { typeChoice.getChoices().add(CardType.LAND.toString()); typeChoice.getChoices().add(CardType.PLANESWALKER.toString()); - while (controller.isInGame() && !controller.choose(Outcome.ReturnToHand, typeChoice, game)) { + while (controller.canRespond() && !controller.choose(Outcome.ReturnToHand, typeChoice, game)) { } String typeName = typeChoice.getChoice(); diff --git a/Mage.Sets/src/mage/sets/innistrad/DivineReckoning.java b/Mage.Sets/src/mage/sets/innistrad/DivineReckoning.java index e6b2260326a..f1a5bdd979c 100644 --- a/Mage.Sets/src/mage/sets/innistrad/DivineReckoning.java +++ b/Mage.Sets/src/mage/sets/innistrad/DivineReckoning.java @@ -95,7 +95,7 @@ class DivineReckoningEffect extends OneShotEffect { Target target = new TargetControlledPermanent(1, 1, new FilterControlledCreaturePermanent(), true); if (target.canChoose(player.getId(), game)) { - while (player.isInGame() && !target.isChosen() && target.canChoose(player.getId(), game)) { + while (player.canRespond() && !target.isChosen() && target.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.Benefit, target, source, game); } Permanent permanent = game.getPermanent(target.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/innistrad/EndlessRanksOfTheDead.java b/Mage.Sets/src/mage/sets/innistrad/EndlessRanksOfTheDead.java index 28d7a191a35..dfc6815538f 100644 --- a/Mage.Sets/src/mage/sets/innistrad/EndlessRanksOfTheDead.java +++ b/Mage.Sets/src/mage/sets/innistrad/EndlessRanksOfTheDead.java @@ -27,6 +27,7 @@ */ package mage.sets.innistrad; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.common.OnEventTriggeredAbility; import mage.abilities.dynamicvalue.DynamicValue; @@ -41,8 +42,6 @@ import mage.game.Game; import mage.game.events.GameEvent.EventType; import mage.game.permanent.token.ZombieToken; -import java.util.UUID; - /** * * @author BetaSteward @@ -53,11 +52,10 @@ public class EndlessRanksOfTheDead extends CardImpl { super(ownerId, 99, "Endless Ranks of the Dead", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}{B}"); this.expansionSetCode = "ISD"; - // At the beginning of your upkeep, put X 2/2 black Zombie creature tokens onto the battlefield, // where X is half the number of Zombies you control, rounded down. this.addAbility(new OnEventTriggeredAbility(EventType.UPKEEP_STEP_PRE, "beginning of your upkeep", - new CreateTokenEffect(new ZombieToken("ISD"), new HalfZombiesCount()))); + new CreateTokenEffect(new ZombieToken(), new HalfZombiesCount()))); } diff --git a/Mage.Sets/src/mage/sets/innistrad/GarrukTheVeilCursed.java b/Mage.Sets/src/mage/sets/innistrad/GarrukTheVeilCursed.java index b702789950c..4a5d8e531d0 100644 --- a/Mage.Sets/src/mage/sets/innistrad/GarrukTheVeilCursed.java +++ b/Mage.Sets/src/mage/sets/innistrad/GarrukTheVeilCursed.java @@ -153,7 +153,7 @@ class GarrukTheVeilCursedEffect extends OneShotEffect { Target target = new TargetControlledPermanent(1, 1, filterCreature, false); boolean sacrificed = false; if (target.canChoose(controller.getId(), game)) { - while (controller.isInGame() && !target.isChosen() && target.canChoose(controller.getId(), game)) { + while (controller.canRespond() && !target.isChosen() && target.canChoose(controller.getId(), game)) { controller.chooseTarget(Outcome.Sacrifice, target, source, game); } diff --git a/Mage.Sets/src/mage/sets/innistrad/HereticsPunishment.java b/Mage.Sets/src/mage/sets/innistrad/HereticsPunishment.java index bfd17fe119d..770680727cc 100644 --- a/Mage.Sets/src/mage/sets/innistrad/HereticsPunishment.java +++ b/Mage.Sets/src/mage/sets/innistrad/HereticsPunishment.java @@ -27,18 +27,18 @@ */ package mage.sets.innistrad; -import java.util.List; +import java.util.Set; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; @@ -54,7 +54,6 @@ public class HereticsPunishment extends CardImpl { super(ownerId, 147, "Heretic's Punishment", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{4}{R}"); this.expansionSetCode = "ISD"; - // {3}{R}: Choose target creature or player, then put the top three cards of your library into your graveyard. Heretic's Punishment deals damage to that creature or player equal to the highest converted mana cost among those cards. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new HereticsPunishmentEffect(), new ManaCostsImpl("{3}{R}")); ability.addTarget(new TargetCreatureOrPlayer()); @@ -87,12 +86,12 @@ class HereticsPunishmentEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { int maxCost = 0; - List cardList = controller.getLibrary().getTopCards(game, 3); - for (Card card: cardList) { + Set cardList = controller.getLibrary().getTopCards(game, 3); + for (Card card : cardList) { int test = card.getManaCost().convertedManaCost(); if (test > maxCost) { maxCost = test; - } + } } controller.moveCards(cardList, Zone.LIBRARY, Zone.GRAVEYARD, source, game); Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source)); @@ -114,4 +113,4 @@ class HereticsPunishmentEffect extends OneShotEffect { return new HereticsPunishmentEffect(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/innistrad/MoanOfTheUnhallowed.java b/Mage.Sets/src/mage/sets/innistrad/MoanOfTheUnhallowed.java index a981392e93d..82b16d77bc2 100644 --- a/Mage.Sets/src/mage/sets/innistrad/MoanOfTheUnhallowed.java +++ b/Mage.Sets/src/mage/sets/innistrad/MoanOfTheUnhallowed.java @@ -47,9 +47,8 @@ public class MoanOfTheUnhallowed extends CardImpl { super(ownerId, 109, "Moan of the Unhallowed", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{B}{B}"); this.expansionSetCode = "ISD"; - // Put two 2/2 black Zombie creature tokens onto the battlefield. - this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken("ISD"), 2)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken(), 2)); // Flashback {5}{B}{B} this.addAbility(new FlashbackAbility(new ManaCostsImpl("{5}{B}{B}"), TimingRule.SORCERY)); diff --git a/Mage.Sets/src/mage/sets/innistrad/Nevermore.java b/Mage.Sets/src/mage/sets/innistrad/Nevermore.java index c5a02b4cbd0..dee67c6f07f 100644 --- a/Mage.Sets/src/mage/sets/innistrad/Nevermore.java +++ b/Mage.Sets/src/mage/sets/innistrad/Nevermore.java @@ -100,7 +100,7 @@ class NevermoreEffect1 extends OneShotEffect { cardChoice.setChoices(CardRepository.instance.getNonLandNames()); cardChoice.clearChoice(); while (!controller.choose(Outcome.Detriment, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/innistrad/OrchardSpirit.java b/Mage.Sets/src/mage/sets/innistrad/OrchardSpirit.java index e16f95e77af..d256f83ba64 100644 --- a/Mage.Sets/src/mage/sets/innistrad/OrchardSpirit.java +++ b/Mage.Sets/src/mage/sets/innistrad/OrchardSpirit.java @@ -28,18 +28,18 @@ package mage.sets.innistrad; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.effects.RestrictionEffect; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.ReachAbility; import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.AbilityPredicate; /** * @@ -47,6 +47,17 @@ import mage.game.permanent.Permanent; */ public class OrchardSpirit extends CardImpl { + private final static FilterCreaturePermanent notFlyingorReachCreatures = new FilterCreaturePermanent("except by creatures with flying or reach"); + + static { + notFlyingorReachCreatures.add(Predicates.not( + Predicates.or( + new AbilityPredicate(FlyingAbility.class), + new AbilityPredicate(ReachAbility.class) + ) + )); + } + public OrchardSpirit(UUID ownerId) { super(ownerId, 198, "Orchard Spirit", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); this.expansionSetCode = "ISD"; @@ -56,7 +67,7 @@ public class OrchardSpirit extends CardImpl { this.toughness = new MageInt(2); // Orchard Spirit can't be blocked except by creatures with flying or reach. - this.addAbility(OrchardSpiritAbility.getInstance()); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(notFlyingorReachCreatures, Duration.WhileOnBattlefield))); } @@ -69,61 +80,3 @@ public class OrchardSpirit extends CardImpl { return new OrchardSpirit(this); } } - -class OrchardSpiritAbility extends EvasionAbility { - - private static OrchardSpiritAbility instance; - - public static OrchardSpiritAbility getInstance() { - if (instance == null) { - instance = new OrchardSpiritAbility(); - } - return instance; - } - - private OrchardSpiritAbility() { - this.addEffect(new OrchardSpiritEffect()); - } - - @Override - public String getRule() { - return "{this} can't be blocked except by creatures with flying or reach."; - } - - @Override - public OrchardSpiritAbility copy() { - return getInstance(); - } -} - -class OrchardSpiritEffect extends RestrictionEffect { - - public OrchardSpiritEffect() { - super(Duration.WhileOnBattlefield); - } - - public OrchardSpiritEffect(final OrchardSpiritEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - if (permanent.getAbilities().containsKey(OrchardSpiritAbility.getInstance().getId())) { - return true; - } - return false; - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - if (blocker.getAbilities().contains(FlyingAbility.getInstance()) || blocker.getAbilities().contains(ReachAbility.getInstance())) { - return true; - } - return false; - } - - @Override - public OrchardSpiritEffect copy() { - return new OrchardSpiritEffect(this); - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/innistrad/ScreechingBat.java b/Mage.Sets/src/mage/sets/innistrad/ScreechingBat.java index 5948bfa65c0..b3453bcd2e6 100644 --- a/Mage.Sets/src/mage/sets/innistrad/ScreechingBat.java +++ b/Mage.Sets/src/mage/sets/innistrad/ScreechingBat.java @@ -68,7 +68,7 @@ public class ScreechingBat extends CardImpl { // At the beginning of your upkeep, you may pay {2}{B}{B}. If you do, transform Screeching Bat. this.addAbility(new TransformAbility()); - this.addAbility(new ConditionalTriggeredAbility(new ScreechingBatBeginningOfUpkeepTriggeredAbility(), new TransformedCondition(true), "", true)); + this.addAbility(new ConditionalTriggeredAbility(new ScreechingBatBeginningOfUpkeepTriggeredAbility(), new TransformedCondition(true), "")); } public ScreechingBat(final ScreechingBat card) { @@ -84,7 +84,7 @@ public class ScreechingBat extends CardImpl { class ScreechingBatBeginningOfUpkeepTriggeredAbility extends TriggeredAbilityImpl { public ScreechingBatBeginningOfUpkeepTriggeredAbility() { - super(Zone.BATTLEFIELD, new ScreechingBatTransformSourceEffect()); + super(Zone.BATTLEFIELD, new ScreechingBatTransformSourceEffect(), true); } public ScreechingBatBeginningOfUpkeepTriggeredAbility(final ScreechingBatBeginningOfUpkeepTriggeredAbility ability) { diff --git a/Mage.Sets/src/mage/sets/innistrad/StalkingVampire.java b/Mage.Sets/src/mage/sets/innistrad/StalkingVampire.java index ad2db3b4221..2535c9ccb8e 100644 --- a/Mage.Sets/src/mage/sets/innistrad/StalkingVampire.java +++ b/Mage.Sets/src/mage/sets/innistrad/StalkingVampire.java @@ -27,14 +27,13 @@ */ package mage.sets.innistrad; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.MageInt; -import mage.cards.CardImpl; - import java.util.UUID; +import mage.MageInt; import mage.abilities.condition.common.TransformedCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * @author nantuko @@ -54,7 +53,7 @@ public class StalkingVampire extends CardImpl { this.toughness = new MageInt(5); // At the beginning of your upkeep, you may pay {2}{B}{B}. If you do, transform Stalking Vampire. - this.addAbility(new ConditionalTriggeredAbility(new ScreechingBatBeginningOfUpkeepTriggeredAbility(), new TransformedCondition(), "", true)); + this.addAbility(new ConditionalTriggeredAbility(new ScreechingBatBeginningOfUpkeepTriggeredAbility(), new TransformedCondition(), "")); } public StalkingVampire(final StalkingVampire card) { diff --git a/Mage.Sets/src/mage/sets/innistrad/UndeadAlchemist.java b/Mage.Sets/src/mage/sets/innistrad/UndeadAlchemist.java index 884fc9e016a..4e39289c8df 100644 --- a/Mage.Sets/src/mage/sets/innistrad/UndeadAlchemist.java +++ b/Mage.Sets/src/mage/sets/innistrad/UndeadAlchemist.java @@ -86,7 +86,7 @@ class UndeadAlchemistTriggeredAbility extends TriggeredAbilityImpl { public UndeadAlchemistTriggeredAbility() { super(Zone.BATTLEFIELD, new ExileTargetEffect(), true); - this.addEffect(new CreateTokenEffect(new ZombieToken("ISD"))); + this.addEffect(new CreateTokenEffect(new ZombieToken())); } public UndeadAlchemistTriggeredAbility(final UndeadAlchemistTriggeredAbility ability) { @@ -105,7 +105,7 @@ class UndeadAlchemistTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - ZoneChangeEvent zEvent = (ZoneChangeEvent)event; + ZoneChangeEvent zEvent = (ZoneChangeEvent) event; if (zEvent.getFromZone() == Zone.LIBRARY && zEvent.getToZone() == Zone.GRAVEYARD && game.getOpponents(this.getControllerId()).contains(zEvent.getPlayerId())) { Card card = game.getCard(event.getTargetId()); if (card != null && card.getCardType().contains(CardType.CREATURE)) { diff --git a/Mage.Sets/src/mage/sets/invasion/Addle.java b/Mage.Sets/src/mage/sets/invasion/Addle.java new file mode 100644 index 00000000000..c24d025e91e --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Addle.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class Addle extends mage.sets.vintagemasters.Addle { + + public Addle(UUID ownerId) { + super(ownerId); + this.cardNumber = 91; + this.expansionSetCode = "INV"; + this.rarity = Rarity.UNCOMMON; + } + + public Addle(final Addle card) { + super(card); + } + + @Override + public Addle copy() { + return new Addle(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/AlabasterLeech.java b/Mage.Sets/src/mage/sets/invasion/AlabasterLeech.java new file mode 100644 index 00000000000..68d3990309a --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/AlabasterLeech.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.cost.SpellsCostIncreasementControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class AlabasterLeech extends CardImpl { + + private static final FilterCard filter = new FilterCard("White spells"); + + static { + filter.add(new ColorPredicate(ObjectColor.WHITE)); + } + + public AlabasterLeech(UUID ownerId) { + super(ownerId, 1, "Alabaster Leech", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "INV"; + this.subtype.add("Leech"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // White spells you cast cost {W} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new SpellsCostIncreasementControllerEffect(filter, new ManaCostsImpl("{W}")))); + } + + public AlabasterLeech(final AlabasterLeech card) { + super(card); + } + + @Override + public AlabasterLeech copy() { + return new AlabasterLeech(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/AncientKavu.java b/Mage.Sets/src/mage/sets/invasion/AncientKavu.java new file mode 100644 index 00000000000..9a2e595139c --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/AncientKavu.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesColorSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class AncientKavu extends CardImpl { + + public AncientKavu(UUID ownerId) { + super(ownerId, 136, "Ancient Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {2}: Ancient Kavu becomes colorless until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorSourceEffect(new ObjectColor(), Duration.EndOfTurn), new ManaCostsImpl("{2}"))); + } + + public AncientKavu(final AncientKavu card) { + super(card); + } + + @Override + public AncientKavu copy() { + return new AncientKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/AndraditeLeech.java b/Mage.Sets/src/mage/sets/invasion/AndraditeLeech.java new file mode 100644 index 00000000000..a506047da25 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/AndraditeLeech.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.cost.SpellsCostIncreasementControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class AndraditeLeech extends CardImpl { + + private static final FilterCard filter = new FilterCard("Black spells"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public AndraditeLeech(UUID ownerId) { + super(ownerId, 93, "Andradite Leech", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "INV"; + this.subtype.add("Leech"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Black spells you cast cost {B} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new SpellsCostIncreasementControllerEffect(filter, new ManaCostsImpl("{B}")))); + // {B}: Andradite Leech gets +1/+1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostSourceEffect(1, 1, Duration.EndOfTurn), new ManaCostsImpl("{B}"))); + } + + public AndraditeLeech(final AndraditeLeech card) { + super(card); + } + + @Override + public AndraditeLeech copy() { + return new AndraditeLeech(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Bind.java b/Mage.Sets/src/mage/sets/invasion/Bind.java new file mode 100644 index 00000000000..07372a3655f --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Bind.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetActivatedAbility; + +/** + * + * @author LoneFox + + */ +public class Bind extends CardImpl { + + public Bind(UUID ownerId) { + super(ownerId, 182, "Bind", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "INV"; + + // Counter target activated ability. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetActivatedAbility()); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public Bind(final Bind card) { + super(card); + } + + @Override + public Bind copy() { + return new Bind(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/CanopySurge.java b/Mage.Sets/src/mage/sets/invasion/CanopySurge.java new file mode 100644 index 00000000000..60d7b425bab --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/CanopySurge.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.AbilityPredicate; + +/** + * + * @author LoneFox + */ +public class CanopySurge extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying"); + + static { + filter.add(new AbilityPredicate(FlyingAbility.class)); + } + + public CanopySurge(UUID ownerId) { + super(ownerId, 184, "Canopy Surge", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{G}"); + this.expansionSetCode = "INV"; + + // Kicker {2} + this.addAbility(new KickerAbility("{2}")); + // Canopy Surge deals 1 damage to each creature with flying and each player. If Canopy Surge was kicked, it deals 4 damage to each creature with flying and each player instead. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageEverythingEffect(4, filter), + new DamageEverythingEffect(1, filter), KickedCondition.getInstance(), + "{this} deals 1 damage to each creature with flying and each player. If {this} was kicked, it deals 4 damage to each creature with flying and each player instead.")); + } + + public CanopySurge(final CanopySurge card) { + super(card); + } + + @Override + public CanopySurge copy() { + return new CanopySurge(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/CollapsingBorders.java b/Mage.Sets/src/mage/sets/invasion/CollapsingBorders.java index 81e3f9c120c..323704a268c 100644 --- a/Mage.Sets/src/mage/sets/invasion/CollapsingBorders.java +++ b/Mage.Sets/src/mage/sets/invasion/CollapsingBorders.java @@ -42,7 +42,7 @@ import mage.constants.TargetController; /** * * @author LoneFox - + * */ public class CollapsingBorders extends CardImpl { @@ -51,7 +51,7 @@ public class CollapsingBorders extends CardImpl { this.expansionSetCode = "INV"; // Domain - At the beginning of each player's upkeep, that player gains 1 life for each basic land type among lands he or she controls. Then Collapsing Borders deals 3 damage to him or her. - Effect effect = new GainLifeTargetEffect(new DomainValue()); + Effect effect = new GainLifeTargetEffect(new DomainValue(true)); effect.setText("that player gains 1 life for each basic land type among lands he or she controls."); Ability ability = new BeginningOfUpkeepTriggeredAbility(effect, TargetController.ANY, false); effect = new DamageTargetEffect(3); diff --git a/Mage.Sets/src/mage/sets/invasion/CollectiveRestraint.java b/Mage.Sets/src/mage/sets/invasion/CollectiveRestraint.java new file mode 100644 index 00000000000..2fc2c38da18 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/CollectiveRestraint.java @@ -0,0 +1,100 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; + +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCostImpl; +import mage.abilities.costs.mana.ManaCosts; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.PayCostToAttackBlockEffectImpl; +import mage.abilities.effects.common.combat.CantAttackYouUnlessPayManaAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterEnchantmentPermanent; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author Simown + */ +public class CollectiveRestraint extends CardImpl { + + public CollectiveRestraint(UUID ownerId) { + super(ownerId, 49, "Collective Restraint", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}"); + this.expansionSetCode = "INV"; + + // Domain - Creatures can't attack you unless their controller pays {X} for each creature he or she controls that's attacking you, where X is the number of basic land types you control. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CollectiveRestraintPayManaToAttackAllEffect())); + + } + + public CollectiveRestraint(final CollectiveRestraint card) { + super(card); + } + + @Override + public CollectiveRestraint copy() { + return new CollectiveRestraint(this); + } +} + +class CollectiveRestraintPayManaToAttackAllEffect extends CantAttackYouUnlessPayManaAllEffect { + + CollectiveRestraintPayManaToAttackAllEffect() { + super(null, true); + staticText = "Creatures can't attack you unless their controller pays {X} for each creature he or she controls that's attacking you, where X is the number of basic land types you control."; + } + + CollectiveRestraintPayManaToAttackAllEffect(CollectiveRestraintPayManaToAttackAllEffect effect) { + super(effect); + } + + @Override + public ManaCosts getManaCostToPay(GameEvent event, Ability source, Game game) { + int domainValue = new DomainValue().calculate(game, source, this); + if (domainValue > 0) { + return new ManaCostsImpl<>("{" + domainValue + "}"); + } + return null; + } + + @Override + public CollectiveRestraintPayManaToAttackAllEffect copy() { + return new CollectiveRestraintPayManaToAttackAllEffect(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/invasion/CrosisThePurger.java b/Mage.Sets/src/mage/sets/invasion/CrosisThePurger.java new file mode 100644 index 00000000000..2f40090c3d0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/CrosisThePurger.java @@ -0,0 +1,127 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + + +import java.util.ArrayList; +import java.util.List; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.choices.ChoiceColor; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author LoneFox + + */ +public class CrosisThePurger extends CardImpl { + + public CrosisThePurger(UUID ownerId) { + super(ownerId, 242, "Crosis, the Purger", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}{B}{R}"); + this.expansionSetCode = "INV"; + this.supertype.add("Legendary"); + this.subtype.add("Dragon"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Whenever Crosis, the Purger deals combat damage to a player, you may pay {2}{B}. If you do, choose a color, then that player reveals his or her hand and discards all cards of that color. + this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new DoIfCostPaid(new CrosisThePurgerEffect(), + new ManaCostsImpl("{2}{B}")), false, true)); + } + + public CrosisThePurger(final CrosisThePurger card) { + super(card); + } + + @Override + public CrosisThePurger copy() { + return new CrosisThePurger(this); + } +} + +class CrosisThePurgerEffect extends OneShotEffect { + + CrosisThePurgerEffect() { + super(Outcome.Discard); + this.staticText = "choose a color, then that player reveals his or her hand and discards all cards of that color."; + } + + CrosisThePurgerEffect(final CrosisThePurgerEffect effect) { + super(effect); + } + + @Override + public CrosisThePurgerEffect copy() { + return new CrosisThePurgerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if(player != null) { + ChoiceColor choice = new ChoiceColor(); + player.choose(outcome, choice, game); + if(choice.getColor() != null) { + game.informPlayers(new StringBuilder(player.getLogName()).append(" chooses ").append(choice.getColor()).toString()); + Player damagedPlayer = game.getPlayer(this.getTargetPointer().getFirst(game, source)); + damagedPlayer.revealCards("hand of " + damagedPlayer.getName(), damagedPlayer.getHand(), game); + FilterCard filter = new FilterCard(); + filter.add(new ColorPredicate(choice.getColor())); + List toDiscard = new ArrayList<>(); + for(UUID cardId : damagedPlayer.getHand()) { + Card card = game.getCard(cardId); + if(filter.match(card, game)) { + toDiscard.add(card); + } + } + for(Card card: toDiscard) { + damagedPlayer.discard(card, source, game); + } + return true; + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/DevouringStrossus.java b/Mage.Sets/src/mage/sets/invasion/DevouringStrossus.java new file mode 100644 index 00000000000..96baa61d2d8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/DevouringStrossus.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.abilities.effects.common.SacrificeEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class DevouringStrossus extends CardImpl { + + public DevouringStrossus(UUID ownerId) { + super(ownerId, 101, "Devouring Strossus", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{B}{B}{B}"); + this.expansionSetCode = "INV"; + this.subtype.add("Horror"); + this.power = new MageInt(9); + this.toughness = new MageInt(9); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Trample + this.addAbility(TrampleAbility.getInstance()); + // At the beginning of your upkeep, sacrifice a creature. + Ability ability = new BeginningOfUpkeepTriggeredAbility(new SacrificeEffect(new FilterControlledCreaturePermanent("creature"), 1, null), + TargetController.YOU, false); + this.addAbility(ability); + // Sacrifice a creature: Regenerate Devouring Strossus. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), + new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, new FilterControlledCreaturePermanent("a creature"), true)))); + } + + public DevouringStrossus(final DevouringStrossus card) { + super(card); + } + + @Override + public DevouringStrossus copy() { + return new DevouringStrossus(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/DivinePresence.java b/Mage.Sets/src/mage/sets/invasion/DivinePresence.java new file mode 100644 index 00000000000..99deb0039ba --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/DivinePresence.java @@ -0,0 +1,110 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ReplacementEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; + +/** + * + * @author LoneFox + */ +public class DivinePresence extends CardImpl { + + public DivinePresence(UUID ownerId) { + super(ownerId, 15, "Divine Presence", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "INV"; + + // If a source would deal 4 or more damage to a creature or player, that source deals 3 damage to that creature or player instead. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DivinePresenceEffect())); + } + + public DivinePresence(final DivinePresence card) { + super(card); + } + + @Override + public DivinePresence copy() { + return new DivinePresence(this); + } +} + +class DivinePresenceEffect extends ReplacementEffectImpl { + + public DivinePresenceEffect() { + super(Duration.WhileOnBattlefield, Outcome.Neutral); + staticText = "If a source would deal 4 or more damage to a creature or player, that source deals 3 damage to that creature or player instead."; + } + + public DivinePresenceEffect(final DivinePresenceEffect effect) { + super(effect); + } + + @Override + public DivinePresenceEffect copy() { + return new DivinePresenceEffect(this); + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + switch(event.getType()) { + case DAMAGE_CREATURE: + case DAMAGE_PLAYER: + return true; + default: + return false; + } + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + return event.getAmount() > 3; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + event.setAmount(3); + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/DoOrDie.java b/Mage.Sets/src/mage/sets/invasion/DoOrDie.java new file mode 100644 index 00000000000..20689f03e0e --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/DoOrDie.java @@ -0,0 +1,132 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.ArrayList; +import java.util.List; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetPlayer; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class DoOrDie extends CardImpl { + + public DoOrDie(UUID ownerId) { + super(ownerId, 102, "Do or Die", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{1}{B}"); + this.expansionSetCode = "INV"; + + // Separate all creatures target player controls into two piles. Destroy all creatures in the pile of that player's choice. They can't be regenerated. + this.getSpellAbility().addEffect(new DoOrDieEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + } + + public DoOrDie(final DoOrDie card) { + super(card); + } + + @Override + public DoOrDie copy() { + return new DoOrDie(this); + } +} + +class DoOrDieEffect extends OneShotEffect { + + public DoOrDieEffect() { + super(Outcome.Sacrifice); + this.staticText = "Separate all creatures target player controls into two piles. Destroy all creatures in the pile of that player's choice. They can't be regenerated"; + } + + public DoOrDieEffect(final DoOrDieEffect effect) { + super(effect); + } + + @Override + public DoOrDieEffect copy() { + return new DoOrDieEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + Player targetPlayer = game.getPlayer(source.getFirstTarget()); + if (player != null && targetPlayer != null) { + int count = game.getBattlefield().countAll(new FilterCreaturePermanent(), targetPlayer.getId(), game); + TargetCreaturePermanent creatures = new TargetCreaturePermanent(0, count, new FilterCreaturePermanent("creatures to put in the first pile"), true); + List pile1 = new ArrayList<>(); + creatures.setRequired(false); + if (player.choose(Outcome.Neutral, creatures, source.getSourceId(), game)) { + List targets = creatures.getTargets(); + for (UUID targetId : targets) { + Permanent p = game.getPermanent(targetId); + if (p != null) { + pile1.add(p); + } + } + } + List pile2 = new ArrayList<>(); + for (Permanent p: game.getBattlefield().getAllActivePermanents(targetPlayer.getId())) { + if (!pile1.contains(p)) { + pile2.add(p); + } + } + + boolean choice = targetPlayer.choosePile(Outcome.DestroyPermanent, "Choose a pile to destroy.", pile1, pile2, game); + + if (choice) { + destroyPermanents(pile1, game, source); + } else { + destroyPermanents(pile2, game, source); + } + + return true; + } + return false; + } + + private void destroyPermanents(List pile, Game game, Ability source) { + for (Permanent permanent : pile) { + if (permanent != null) { + permanent.destroy(source.getSourceId(), game, true); + } + } + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Dredge.java b/Mage.Sets/src/mage/sets/invasion/Dredge.java index 9f9d27e9ced..9d0d8a0f142 100644 --- a/Mage.Sets/src/mage/sets/invasion/Dredge.java +++ b/Mage.Sets/src/mage/sets/invasion/Dredge.java @@ -30,14 +30,12 @@ package mage.sets.invasion; import java.util.UUID; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.SacrificeControllerEffect; -import mage.abilities.effects.common.SacrificeTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; import mage.filter.FilterPermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; -import mage.target.TargetPermanent; /** * @@ -46,18 +44,18 @@ import mage.target.TargetPermanent; public class Dredge extends CardImpl { private static final FilterPermanent filter = new FilterPermanent("a creature or land"); - + static { filter.add(Predicates.or(new CardTypePredicate(CardType.CREATURE), new CardTypePredicate(CardType.LAND))); } - + public Dredge(UUID ownerId) { super(ownerId, 103, "Dredge", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{B}"); this.expansionSetCode = "INV"; // Sacrifice a creature or land. this.getSpellAbility().addEffect(new SacrificeControllerEffect(filter, 1, "")); - + // Draw a card. this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); } diff --git a/Mage.Sets/src/mage/sets/invasion/ExplosiveGrowth.java b/Mage.Sets/src/mage/sets/invasion/ExplosiveGrowth.java index 8862c23620a..6b71c14bc36 100644 --- a/Mage.Sets/src/mage/sets/invasion/ExplosiveGrowth.java +++ b/Mage.Sets/src/mage/sets/invasion/ExplosiveGrowth.java @@ -28,6 +28,7 @@ package mage.sets.invasion; import java.util.UUID; +import mage.abilities.condition.LockedInCondition; import mage.abilities.condition.common.KickedCondition; import mage.abilities.decorator.ConditionalContinuousEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; @@ -50,11 +51,11 @@ public class ExplosiveGrowth extends CardImpl { // Kicker {5} this.addAbility(new KickerAbility("{5}")); - + // Target creature gets +2/+2 until end of turn. If Explosive Growth was kicked, that creature gets +5/+5 until end of turn instead. this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addEffect(new ConditionalContinuousEffect(new BoostTargetEffect(5, 5, Duration.EndOfTurn), - new BoostTargetEffect(2, 2, Duration.EndOfTurn), KickedCondition.getInstance(), + new BoostTargetEffect(2, 2, Duration.EndOfTurn), new LockedInCondition(KickedCondition.getInstance()), "Target creature gets +2/+2 until end of turn. If Explosive Growth was kicked, that creature gets +5/+5 until end of turn instead.")); } @@ -66,4 +67,4 @@ public class ExplosiveGrowth extends CardImpl { public ExplosiveGrowth copy() { return new ExplosiveGrowth(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/invasion/FirebrandRanger.java b/Mage.Sets/src/mage/sets/invasion/FirebrandRanger.java index 0f293697d6e..17e16b89c30 100644 --- a/Mage.Sets/src/mage/sets/invasion/FirebrandRanger.java +++ b/Mage.Sets/src/mage/sets/invasion/FirebrandRanger.java @@ -41,12 +41,10 @@ import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterCard; -import mage.filter.common.FilterLandCard; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.filter.predicate.mageobject.SupertypePredicate; import mage.game.Game; -import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.common.TargetCardInHand; @@ -82,7 +80,7 @@ public class FirebrandRanger extends CardImpl { class PutLandOnBattlefieldEffect extends OneShotEffect { - private static final FilterCard filter = new FilterCard("card other than a basic land card"); + private static final FilterCard filter = new FilterCard("basic land card"); static { filter.add(Predicates.and(new CardTypePredicate(CardType.LAND), new SupertypePredicate("Basic"))); @@ -116,10 +114,7 @@ class PutLandOnBattlefieldEffect extends OneShotEffect { Card card = game.getCard(target.getFirstTarget()); if (card != null) { card.putOntoBattlefield(game, Zone.HAND, source.getSourceId(), source.getControllerId()); - Permanent permanent = game.getPermanent(card.getId()); - if (permanent != null) { - permanent.setTapped(true); - } + return true; } } diff --git a/Mage.Sets/src/mage/sets/invasion/HornedCheetah.java b/Mage.Sets/src/mage/sets/invasion/HornedCheetah.java new file mode 100644 index 00000000000..ce0fe58daa3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/HornedCheetah.java @@ -0,0 +1,62 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class HornedCheetah extends CardImpl { + + public HornedCheetah(UUID ownerId) { + super(ownerId, 251, "Horned Cheetah", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{W}"); + this.expansionSetCode = "INV"; + this.subtype.add("Cat"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Horned Cheetah deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public HornedCheetah(final HornedCheetah card) { + super(card); + } + + @Override + public HornedCheetah copy() { + return new HornedCheetah(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/JadeLeech.java b/Mage.Sets/src/mage/sets/invasion/JadeLeech.java new file mode 100644 index 00000000000..31d429ffa21 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/JadeLeech.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.cost.SpellsCostIncreasementControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class JadeLeech extends CardImpl { + + private static final FilterCard filter = new FilterCard("Green spells"); + + static { + filter.add(new ColorPredicate(ObjectColor.GREEN)); + } + + public JadeLeech(UUID ownerId) { + super(ownerId, 190, "Jade Leech", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); + this.expansionSetCode = "INV"; + this.subtype.add("Leech"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Green spells you cast cost {G} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new SpellsCostIncreasementControllerEffect(filter, new ManaCostsImpl("{G}")))); + } + + public JadeLeech(final JadeLeech card) { + super(card); + } + + @Override + public JadeLeech copy() { + return new JadeLeech(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/JuntuStakes.java b/Mage.Sets/src/mage/sets/invasion/JuntuStakes.java new file mode 100644 index 00000000000..785f9e98b67 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/JuntuStakes.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.PowerPredicate; + +/** + * + * @author LoneFox + */ +public class JuntuStakes extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures with power 1 or less"); + + static { + filter.add(new PowerPredicate(Filter.ComparisonType.LessThan, 2)); + } + + public JuntuStakes(UUID ownerId) { + super(ownerId, 304, "Juntu Stakes", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "INV"; + + // Creatures with power 1 or less don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); + } + + public JuntuStakes(final JuntuStakes card) { + super(card); + } + + @Override + public JuntuStakes copy() { + return new JuntuStakes(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/KavuMonarch.java b/Mage.Sets/src/mage/sets/invasion/KavuMonarch.java new file mode 100644 index 00000000000..1a4cd916450 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/KavuMonarch.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldAllTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author LoneFox + */ +public class KavuMonarch extends CardImpl { + + private static final FilterCreaturePermanent filter1 = new FilterCreaturePermanent("Kavu creatures"); + private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent("another Kavu"); + + static { + filter1.add(new SubtypePredicate("Kavu")); + filter2.add(new SubtypePredicate("Kavu")); + filter2.add(new AnotherPredicate()); + } + + public KavuMonarch(UUID ownerId) { + super(ownerId, 149, "Kavu Monarch", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Kavu creatures have trample. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(TrampleAbility.getInstance(), + Duration.WhileOnBattlefield, filter1))); + + // Whenever another Kavu enters the battlefield, put a +1/+1 counter on Kavu Monarch. + this.addAbility(new EntersBattlefieldAllTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance()), filter2)); + } + + public KavuMonarch(final KavuMonarch card) { + super(card); + } + + @Override + public KavuMonarch copy() { + return new KavuMonarch(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/KavuRunner.java b/Mage.Sets/src/mage/sets/invasion/KavuRunner.java new file mode 100644 index 00000000000..14a00fbb7b7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/KavuRunner.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.InvertCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition.CountType; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class KavuRunner extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white or blue creature"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.WHITE), new ColorPredicate(ObjectColor.BLUE))); + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public KavuRunner(UUID ownerId) { + super(ownerId, 150, "Kavu Runner", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Kavu Runner has haste as long as no opponent controls a white or blue creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new ConditionalContinuousEffect(new GainAbilitySourceEffect(HasteAbility.getInstance(), + Duration.WhileOnBattlefield), new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 0, false)), + "{this} has haste as long as no opponent controls a white or blue creature"))); + } + + public KavuRunner(final KavuRunner card) { + super(card); + } + + @Override + public KavuRunner copy() { + return new KavuRunner(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/LlanowarVanguard.java b/Mage.Sets/src/mage/sets/invasion/LlanowarVanguard.java new file mode 100644 index 00000000000..2a64d4a36b9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/LlanowarVanguard.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class LlanowarVanguard extends CardImpl { + + public LlanowarVanguard(UUID ownerId) { + super(ownerId, 197, "Llanowar Vanguard", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "INV"; + this.subtype.add("Dryad"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Llanowar Vanguard gets +0/+4 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostSourceEffect(0, 4, Duration.EndOfTurn), new TapSourceCost())); + } + + public LlanowarVanguard(final LlanowarVanguard card) { + super(card); + } + + @Override + public LlanowarVanguard copy() { + return new LlanowarVanguard(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java b/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java new file mode 100644 index 00000000000..e650e7f25aa --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class MetathranTransport extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blue creatures"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLUE)); + } + + public MetathranTransport(UUID ownerId) { + super(ownerId, 62, "Metathran Transport", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Metathran"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Metathran Transport can't be blocked by blue creatures. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + // {U}: Target creature becomes blue until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(ObjectColor.BLUE, + Duration.EndOfTurn), new ManaCostsImpl("{U}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public MetathranTransport(final MetathranTransport card) { + super(card); + } + + @Override + public MetathranTransport copy() { + return new MetathranTransport(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Opt.java b/Mage.Sets/src/mage/sets/invasion/Opt.java index 00a8fe58780..132c5a085a8 100644 --- a/Mage.Sets/src/mage/sets/invasion/Opt.java +++ b/Mage.Sets/src/mage/sets/invasion/Opt.java @@ -29,7 +29,7 @@ package mage.sets.invasion; import java.util.UUID; import mage.abilities.effects.common.DrawCardSourceControllerEffect; -import mage.abilities.effects.common.LookLibraryMayPutToBottomEffect; +import mage.abilities.effects.keyword.ScryEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; @@ -44,9 +44,8 @@ public class Opt extends CardImpl { super(ownerId, 64, "Opt", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{U}"); this.expansionSetCode = "INV"; - - // Look at the top card of your library. You may put that card on the bottom of your library. - this.getSpellAbility().addEffect(new LookLibraryMayPutToBottomEffect()); + // Scry 1. + this.getSpellAbility().addEffect(new ScryEffect(1)); // Draw a card. this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); diff --git a/Mage.Sets/src/mage/sets/invasion/OrimsTouch.java b/Mage.Sets/src/mage/sets/invasion/OrimsTouch.java new file mode 100644 index 00000000000..bec89d9ae44 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/OrimsTouch.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.condition.LockedInCondition; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalReplacementEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class OrimsTouch extends CardImpl { + + public OrimsTouch(UUID ownerId) { + super(ownerId, 23, "Orim's Touch", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "INV"; + + // Kicker {1} + this.addAbility(new KickerAbility("{1}")); + + // Prevent the next 2 damage that would be dealt to target creature or player this turn. If Orim's Touch was kicked, prevent the next 4 damage that would be dealt to that creature or player this turn instead. + Effect effect = new ConditionalReplacementEffect( + new PreventDamageToTargetEffect(Duration.EndOfTurn, 4), + new LockedInCondition(KickedCondition.getInstance()), + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2)); + effect.setText("Prevent the next 2 damage that would be dealt to target creature or player this turn. If Orim's Touch was kicked, prevent the next 4 damage that would be dealt to that creature or player this turn instead"); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + this.getSpellAbility().addEffect(effect); + } + + public OrimsTouch(final OrimsTouch card) { + super(card); + } + + @Override + public OrimsTouch copy() { + return new OrimsTouch(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/invasion/Overload.java b/Mage.Sets/src/mage/sets/invasion/Overload.java new file mode 100644 index 00000000000..a68c354a336 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Overload.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterArtifactPermanent; +import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; +import mage.game.Game; +import mage.target.common.TargetArtifactPermanent; + +/** + * + * @author LoneFox + */ +public class Overload extends CardImpl { + + private static final FilterArtifactPermanent filter2 = new FilterArtifactPermanent("artifact if its converted mana cost is 2 or less"); + private static final FilterArtifactPermanent filter5 = new FilterArtifactPermanent("artifact if its converted mana cost is 5 or less"); + + static { + filter2.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, 3)); + filter5.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, 5)); + } + + public Overload(UUID ownerId) { + super(ownerId, 157, "Overload", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{R}"); + this.expansionSetCode = "INV"; + + // Kicker {2} + this.addAbility(new KickerAbility("{2}")); + // Destroy target artifact if its converted mana cost is 2 or less. If Overload was kicked, destroy that artifact if its converted mana cost is 5 or less instead. + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getSpellAbility().addTarget(new TargetArtifactPermanent(filter5)); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if(ability instanceof SpellAbility) { + if(!KickedCondition.getInstance().apply(game, ability)) { + ability.getTargets().clear(); + ability.getTargets().add(new TargetArtifactPermanent(filter2)); + } + } + } + + public Overload(final Overload card) { + super(card); + } + + @Override + public Overload copy() { + return new Overload(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/PhyrexianInfiltrator.java b/Mage.Sets/src/mage/sets/invasion/PhyrexianInfiltrator.java new file mode 100644 index 00000000000..788b052ddf1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/PhyrexianInfiltrator.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.ExchangeControlTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class PhyrexianInfiltrator extends CardImpl { + + public PhyrexianInfiltrator(UUID ownerId) { + super(ownerId, 116, "Phyrexian Infiltrator", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "INV"; + this.subtype.add("Minion"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {2}{U}{U}: Exchange control of Phyrexian Infiltrator and target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExchangeControlTargetEffect(Duration.EndOfGame, + "Exchange control of {this} and target creature", true), new ManaCostsImpl("{2}{U}{U}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + } + + public PhyrexianInfiltrator(final PhyrexianInfiltrator card) { + super(card); + } + + @Override + public PhyrexianInfiltrator copy() { + return new PhyrexianInfiltrator(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/PouncingKavu.java b/Mage.Sets/src/mage/sets/invasion/PouncingKavu.java new file mode 100644 index 00000000000..966430d562d --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/PouncingKavu.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.HasteAbility; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.counters.CounterType; + +/** + * + * @author LoneFox + + */ +public class PouncingKavu extends CardImpl { + + public PouncingKavu(UUID ownerId) { + super(ownerId, 158, "Pouncing Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Kicker {2}{R} + this.addAbility(new KickerAbility("{2}{R}")); + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + // If Pouncing Kavu was kicked, it enters the battlefield with two +1/+1 counters on it and with haste. + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(2)), + KickedCondition.getInstance(), true, "If {this} was kicked, it enters the battlefield with two +1/+1 counters on it and with haste.", ""); + ability.addEffect(new GainAbilitySourceEffect(HasteAbility.getInstance(), Duration.WhileOnBattlefield)); + this.addAbility(ability); + } + + public PouncingKavu(final PouncingKavu card) { + super(card); + } + + @Override + public PouncingKavu copy() { + return new PouncingKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/PyreZombie.java b/Mage.Sets/src/mage/sets/invasion/PyreZombie.java new file mode 100644 index 00000000000..b9a1ace8379 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/PyreZombie.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class PyreZombie extends CardImpl { + + public PyreZombie(UUID ownerId) { + super(ownerId, 261, "Pyre Zombie", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Zombie"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // At the beginning of your upkeep, if Pyre Zombie is in your graveyard, you may pay {1}{B}{B}. If you do, return Pyre Zombie to your hand. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.GRAVEYARD, + new DoIfCostPaid(new ReturnToHandSourceEffect(), new ManaCostsImpl("{1}{B}{B}")), + TargetController.YOU, false)); + // {1}{R}{R}, Sacrifice Pyre Zombie: Pyre Zombie deals 2 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), new ManaCostsImpl("{1}{R}{R}")); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public PyreZombie(final PyreZombie card) { + super(card); + } + + @Override + public PyreZombie copy() { + return new PyreZombie(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/RampantElephant.java b/Mage.Sets/src/mage/sets/invasion/RampantElephant.java new file mode 100644 index 00000000000..2d65858275a --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/RampantElephant.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.MustBeBlockedByTargetSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class RampantElephant extends CardImpl { + + public RampantElephant(UUID ownerId) { + super(ownerId, 28, "Rampant Elephant", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "INV"; + this.subtype.add("Elephant"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {G}: Target creature blocks Rampant Elephant this turn if able. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MustBeBlockedByTargetSourceEffect(), new ManaCostsImpl("{G}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public RampantElephant(final RampantElephant card) { + super(card); + } + + @Override + public RampantElephant copy() { + return new RampantElephant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Recoil.java b/Mage.Sets/src/mage/sets/invasion/Recoil.java index f062d0bb68b..8b220966d18 100644 --- a/Mage.Sets/src/mage/sets/invasion/Recoil.java +++ b/Mage.Sets/src/mage/sets/invasion/Recoil.java @@ -50,11 +50,10 @@ public class Recoil extends CardImpl { super(ownerId, 264, "Recoil", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}{B}"); this.expansionSetCode = "INV"; - // Return target permanent to its owner's hand. Then that player discards a card. this.getSpellAbility().addEffect(new RecoilEffect()); - this.getSpellAbility().addTarget(new TargetPermanent()); - + this.getSpellAbility().addTarget(new TargetPermanent()); + } public Recoil(final Recoil card) { @@ -86,13 +85,11 @@ class RecoilEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Permanent target = game.getPermanent(source.getFirstTarget()); - if (target != null) { - Player controller = game.getPlayer(target.getControllerId()); - if (controller != null) { - controller.moveCardToHandWithInfo(target, source.getSourceId(), game, Zone.BATTLEFIELD); - controller.discard(1, source, game); - return true; - } + Player controller = game.getPlayer(target.getControllerId()); + if (target != null && controller != null) { + controller.moveCards(target, null, Zone.HAND, source, game); + controller.discard(1, false, source, game); + return true; } return false; } diff --git a/Mage.Sets/src/mage/sets/invasion/Restrain.java b/Mage.Sets/src/mage/sets/invasion/Restrain.java new file mode 100644 index 00000000000..02883862e1e --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Restrain.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.PreventDamageByTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetAttackingCreature; + +/** + * + * @author LoneFox + */ +public class Restrain extends CardImpl { + + public Restrain(UUID ownerId) { + super(ownerId, 30, "Restrain", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{W}"); + this.expansionSetCode = "INV"; + + // Prevent all combat damage that would be dealt by target attacking creature this turn. + Effect effect = new PreventDamageByTargetEffect(Duration.EndOfTurn, true); + effect.setText("Prevent all combat damage that would be dealt by target attacking creature this turn"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetAttackingCreature()); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public Restrain(final Restrain card) { + super(card); + } + + @Override + public Restrain copy() { + return new Restrain(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/RewardsOfDiversity.java b/Mage.Sets/src/mage/sets/invasion/RewardsOfDiversity.java new file mode 100644 index 00000000000..5505662f76d --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/RewardsOfDiversity.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.common.SpellCastOpponentTriggeredAbility; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.FilterSpell; +import mage.filter.predicate.mageobject.MulticoloredPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class RewardsOfDiversity extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("multicolored spell"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + filter.add(new MulticoloredPredicate()); + } + + public RewardsOfDiversity(UUID ownerId) { + super(ownerId, 32, "Rewards of Diversity", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "INV"; + + // Whenever an opponent casts a multicolored spell, you gain 4 life. + this.addAbility(new SpellCastOpponentTriggeredAbility(new GainLifeEffect(4), filter, false)); + } + + public RewardsOfDiversity(final RewardsOfDiversity card) { + super(card); + } + + @Override + public RewardsOfDiversity copy() { + return new RewardsOfDiversity(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/RubyLeech.java b/Mage.Sets/src/mage/sets/invasion/RubyLeech.java new file mode 100644 index 00000000000..1f09b7471a3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/RubyLeech.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.cost.SpellsCostIncreasementControllerEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class RubyLeech extends CardImpl { + + private static final FilterCard filter = new FilterCard("Red spells"); + + static { + filter.add(new ColorPredicate(ObjectColor.RED)); + } + + public RubyLeech(UUID ownerId) { + super(ownerId, 161, "Ruby Leech", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Leech"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + // Red spells you cast cost {R} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new SpellsCostIncreasementControllerEffect(filter, new ManaCostsImpl("{R}")))); + } + + public RubyLeech(final RubyLeech card) { + super(card); + } + + @Override + public RubyLeech copy() { + return new RubyLeech(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SapphireLeech.java b/Mage.Sets/src/mage/sets/invasion/SapphireLeech.java new file mode 100644 index 00000000000..b1e8a9fb239 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SapphireLeech.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.cost.SpellsCostIncreasementControllerEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class SapphireLeech extends CardImpl { + + private static final FilterCard filter = new FilterCard("Blue spells"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLUE)); + } + + public SapphireLeech(UUID ownerId) { + super(ownerId, 71, "Sapphire Leech", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Leech"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Blue spells you cast cost {U} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new SpellsCostIncreasementControllerEffect(filter, new ManaCostsImpl("{U}")))); + } + + public SapphireLeech(final SapphireLeech card) { + super(card); + } + + @Override + public SapphireLeech copy() { + return new SapphireLeech(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SavageOffensive.java b/Mage.Sets/src/mage/sets/invasion/SavageOffensive.java new file mode 100644 index 00000000000..405ed30e595 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SavageOffensive.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.AddContinuousEffectToGame; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author fireshoes + */ +public class SavageOffensive extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures you control"); + + static { + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public SavageOffensive(UUID ownerId) { + super(ownerId, 162, "Savage Offensive", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{R}"); + this.expansionSetCode = "INV"; + + // Kicker {G} + this.addAbility(new KickerAbility("{G}")); + + // Creatures you control gain first strike until end of turn. + this.getSpellAbility().addEffect(new GainAbilityAllEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn, filter)); + + // If Savage Offensive was kicked, they get +1/+1 until end of turn. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new AddContinuousEffectToGame(new BoostControlledEffect(1, 1, Duration.EndOfTurn)), + KickedCondition.getInstance(), + "If {this} was kicked, they get +1/+1 until end of turn.")); + } + + public SavageOffensive(final SavageOffensive card) { + super(card); + } + + @Override + public SavageOffensive copy() { + return new SavageOffensive(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/ScorchingLava.java b/Mage.Sets/src/mage/sets/invasion/ScorchingLava.java new file mode 100644 index 00000000000..89e042afc84 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/ScorchingLava.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.condition.LockedInCondition; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalContinuousRuleModifyingEffect; +import mage.abilities.decorator.ConditionalReplacementEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.replacement.DealtDamageToCreatureBySourceDies; +import mage.abilities.effects.common.ruleModifying.CantRegenerateTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; +import mage.watchers.common.DamagedByWatcher; + +/** + * + * @author LoneFox + */ +public class ScorchingLava extends CardImpl { + + public ScorchingLava(UUID ownerId) { + super(ownerId, 164, "Scorching Lava", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{R}"); + this.expansionSetCode = "INV"; + + // Kicker {R} + this.addAbility(new KickerAbility("{R}")); + // Scorching Lava deals 2 damage to target creature or player. If Scorching Lava was kicked, that creature can't be regenerated this turn and if it would die this turn, exile it instead. + this.getSpellAbility().addEffect(new DamageTargetEffect(2)); + this.getSpellAbility().addEffect(new ConditionalContinuousRuleModifyingEffect( + new CantRegenerateTargetEffect(Duration.EndOfTurn, "That creature"), new LockedInCondition(KickedCondition.getInstance()))); + Effect effect = new ConditionalReplacementEffect(new DealtDamageToCreatureBySourceDies(this, Duration.EndOfTurn), + new LockedInCondition(KickedCondition.getInstance())); + effect.setText("and if it would die this turn, exile it instead"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + this.getSpellAbility().addWatcher(new DamagedByWatcher()); + } + + public ScorchingLava(final ScorchingLava card) { + super(card); + } + + @Override + public ScorchingLava copy() { + return new ScorchingLava(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SeersVision.java b/Mage.Sets/src/mage/sets/invasion/SeersVision.java new file mode 100644 index 00000000000..e2cb73ad3bb --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SeersVision.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.ActivateAsSorceryActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.continuous.PlayWithHandRevealedEffect; +import mage.abilities.effects.common.discard.DiscardCardYouChooseTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.TargetPlayer; + +/** + * + * @author LoneFox + */ +public class SeersVision extends CardImpl { + + public SeersVision(UUID ownerId) { + super(ownerId, 270, "Seer's Vision", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}{B}"); + this.expansionSetCode = "INV"; + + // Your opponents play with their hands revealed. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithHandRevealedEffect(TargetController.OPPONENT))); + // Sacrifice Seer's Vision: Look at target player's hand and choose a card from it. That player discards that card. Activate this ability only any time you could cast a sorcery. + Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new DiscardCardYouChooseTargetEffect(), new SacrificeSourceCost()); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + } + + public SeersVision(final SeersVision card) { + super(card); + } + + @Override + public SeersVision copy() { + return new SeersVision(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Simoon.java b/Mage.Sets/src/mage/sets/invasion/Simoon.java new file mode 100644 index 00000000000..eb8fc2cd18c --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Simoon.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Simoon extends mage.sets.visions.Simoon { + + public Simoon(UUID ownerId) { + super(ownerId); + this.cardNumber = 272; + this.expansionSetCode = "INV"; + } + + public Simoon(final Simoon card) { + super(card); + } + + @Override + public Simoon copy() { + return new Simoon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SkittishKavu.java b/Mage.Sets/src/mage/sets/invasion/SkittishKavu.java new file mode 100644 index 00000000000..d5d4ad43552 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SkittishKavu.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.InvertCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition.CountType; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class SkittishKavu extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white or blue creature"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.WHITE), new ColorPredicate(ObjectColor.BLUE))); + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public SkittishKavu(UUID ownerId) { + super(ownerId, 168, "Skittish Kavu", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Skittish Kavu gets +1/+1 as long as no opponent controls a white or blue creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new ConditionalContinuousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), + new InvertCondition(new PermanentsOnTheBattlefieldCondition(filter, CountType.MORE_THAN, 0, false)), + "{this} gets +1/+1 as long as no opponent controls a white or blue creature"))); + } + + public SkittishKavu(final SkittishKavu card) { + super(card); + } + + @Override + public SkittishKavu copy() { + return new SkittishKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java b/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java new file mode 100644 index 00000000000..2f32f766387 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class SlimyKavu extends CardImpl { + + public SlimyKavu(UUID ownerId) { + super(ownerId, 170, "Slimy Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {T}: Target land becomes a Swamp until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Swamp"), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public SlimyKavu(final SlimyKavu card) { + super(card); + } + + @Override + public SlimyKavu copy() { + return new SlimyKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/StandDeliver.java b/Mage.Sets/src/mage/sets/invasion/StandDeliver.java new file mode 100644 index 00000000000..2496b7cd4ef --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/StandDeliver.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.cards.SplitCard; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class StandDeliver extends SplitCard { + + public StandDeliver(UUID ownerId) { + super(ownerId, 292, "Stand", "Deliver", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{W}", "{2}{U}", false); + this.expansionSetCode = "INV"; + + // Stand + // Prevent the next 2 damage that would be dealt to target creature this turn. + this.getLeftHalfCard().getSpellAbility().addEffect(new PreventDamageToTargetEffect(Duration.EndOfTurn, 2)); + this.getLeftHalfCard().getSpellAbility().addTarget(new TargetCreaturePermanent()); + // Deliver + // Return target permanent to its owner's hand. + this.getRightHalfCard().getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + this.getRightHalfCard().getSpellAbility().addTarget(new TargetPermanent()); + } + + public StandDeliver(final StandDeliver card) { + super(card); + } + + @Override + public StandDeliver copy() { + return new StandDeliver(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/ThicketElemental.java b/Mage.Sets/src/mage/sets/invasion/ThicketElemental.java new file mode 100644 index 00000000000..142a7b4fc14 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/ThicketElemental.java @@ -0,0 +1,124 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class ThicketElemental extends CardImpl { + + public ThicketElemental(UUID ownerId) { + super(ownerId, 214, "Thicket Elemental", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); + this.expansionSetCode = "INV"; + this.subtype.add("Elemental"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Kicker {1}{G} + this.addAbility(new KickerAbility("{1}{G}")); + + // When Thicket Elemental enters the battlefield, if it was kicked, you may reveal cards from the top of your library until you reveal a creature card. If you do, put that card onto the battlefield and shuffle all other cards revealed this way into your library. + TriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new ThicketElementalEffect()); + this.addAbility(new ConditionalTriggeredAbility(ability, KickedCondition.getInstance(), + "When {this} enters the battlefield, if it was kicked, you may reveal cards from the top of your library until you reveal a creature card. If you do, put that card onto the battlefield and shuffle all other cards revealed this way into your library.")); + } + + public ThicketElemental(final ThicketElemental card) { + super(card); + } + + @Override + public ThicketElemental copy() { + return new ThicketElemental(this); + } +} + +class ThicketElementalEffect extends OneShotEffect { + + + + public ThicketElementalEffect() { + super(Outcome.Benefit); + staticText = "if {this} was kicked, reveal cards from the top of your library until you reveal a creature card. Put that card onto the battlefield and shuffle all other cards revealed this way into your library"; + } + + public ThicketElementalEffect(final ThicketElementalEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + Cards revealedCards = new CardsImpl(); + while (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().removeFromTop(game); + if (card.getCardType().contains(CardType.CREATURE)) { + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); + break; + } + revealedCards.add(card); + } + controller.revealCards("ThicketElemental", revealedCards, game); + for (Card card: revealedCards.getCards(game)) { + card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); + } + controller.shuffleLibrary(game); + return true; + } + return false; + } + + @Override + public ThicketElementalEffect copy() { + return new ThicketElementalEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/invasion/TidalVisionary.java b/Mage.Sets/src/mage/sets/invasion/TidalVisionary.java new file mode 100644 index 00000000000..8bbbc694c72 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/TidalVisionary.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class TidalVisionary extends CardImpl { + + public TidalVisionary(UUID ownerId) { + super(ownerId, 80, "Tidal Visionary", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Target creature becomes the color of your choice until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(Duration.EndOfTurn), + new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public TidalVisionary(final TidalVisionary card) { + super(card); + } + + @Override + public TidalVisionary copy() { + return new TidalVisionary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/TreefolkHealer.java b/Mage.Sets/src/mage/sets/invasion/TreefolkHealer.java new file mode 100644 index 00000000000..3f20252cb18 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/TreefolkHealer.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class TreefolkHealer extends CardImpl { + + public TreefolkHealer(UUID ownerId) { + super(ownerId, 218, "Treefolk Healer", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{G}"); + this.expansionSetCode = "INV"; + this.subtype.add("Treefolk"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // {2}{W}, {tap}: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), + new ManaCostsImpl("{2}{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public TreefolkHealer(final TreefolkHealer card) { + super(card); + } + + @Override + public TreefolkHealer copy() { + return new TreefolkHealer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/UrborgPhantom.java b/Mage.Sets/src/mage/sets/invasion/UrborgPhantom.java new file mode 100644 index 00000000000..f308c862049 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/UrborgPhantom.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.CantBlockAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.PreventCombatDamageBySourceEffect; +import mage.abilities.effects.common.PreventCombatDamageToSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class UrborgPhantom extends CardImpl { + + public UrborgPhantom(UUID ownerId) { + super(ownerId, 132, "Urborg Phantom", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "INV"; + this.subtype.add("Spirit"); + this.subtype.add("Minion"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // Urborg Phantom can't block. + this.addAbility(new CantBlockAbility()); + // {U}: Prevent all combat damage that would be dealt to and dealt by Urborg Phantom this turn. + Effect effect = new PreventCombatDamageToSourceEffect(Duration.EndOfTurn); + effect.setText("Prevent all combat damage that would be dealt to"); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{U}")); + effect = new PreventCombatDamageBySourceEffect(Duration.EndOfTurn); + effect.setText("and dealt by {this} this turn"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public UrborgPhantom(final UrborgPhantom card) { + super(card); + } + + @Override + public UrborgPhantom copy() { + return new UrborgPhantom(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/ViciousKavu.java b/Mage.Sets/src/mage/sets/invasion/ViciousKavu.java new file mode 100644 index 00000000000..e6bb20543db --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/ViciousKavu.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + + */ +public class ViciousKavu extends CardImpl { + + public ViciousKavu(UUID ownerId) { + super(ownerId, 284, "Vicious Kavu", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{B}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Vicious Kavu attacks, it gets +2/+0 until end of turn. + this.addAbility(new AttacksTriggeredAbility(new BoostSourceEffect(2, 0, Duration.EndOfTurn), false)); + } + + public ViciousKavu(final ViciousKavu card) { + super(card); + } + + @Override + public ViciousKavu copy() { + return new ViciousKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/VileConsumption.java b/Mage.Sets/src/mage/sets/invasion/VileConsumption.java new file mode 100644 index 00000000000..17af127878c --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/VileConsumption.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class VileConsumption extends CardImpl { + + public VileConsumption(UUID ownerId) { + super(ownerId, 285, "Vile Consumption", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}{B}"); + this.expansionSetCode = "INV"; + + // All creatures have "At the beginning of your upkeep, sacrifice this creature unless you pay 1 life." + Effect effect = new SacrificeSourceUnlessPaysEffect(new PayLifeCost(1)); + effect.setText("sacrifice this creature unless you pay 1 life"); + Effect effect2 = new GainAbilityAllEffect(new BeginningOfUpkeepTriggeredAbility(effect, TargetController.YOU, false), + Duration.WhileOnBattlefield, new FilterCreaturePermanent("all creatures")); + effect2.setText("All creatures have \"At the beginning of your upkeep, sacrifice this creature unless you pay 1 life.\""); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect2)); + } + + public VileConsumption(final VileConsumption card) { + super(card); + } + + @Override + public VileConsumption copy() { + return new VileConsumption(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/VodalianHypnotist.java b/Mage.Sets/src/mage/sets/invasion/VodalianHypnotist.java new file mode 100644 index 00000000000..40f09955e6c --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/VodalianHypnotist.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ActivateAsSorceryActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPlayer; + +/** + * + * @author LoneFox + */ +public class VodalianHypnotist extends CardImpl { + + public VodalianHypnotist(UUID ownerId) { + super(ownerId, 84, "Vodalian Hypnotist", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {2}{B}, {T}: Target player discards a card. Activate this ability only any time you could cast a sorcery. + Ability ability = new ActivateAsSorceryActivatedAbility(Zone.BATTLEFIELD, new DiscardTargetEffect(1), + new ManaCostsImpl("{2}{B}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + } + + public VodalianHypnotist(final VodalianHypnotist card) { + super(card); + } + + @Override + public VodalianHypnotist copy() { + return new VodalianHypnotist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/VodalianSerpent.java b/Mage.Sets/src/mage/sets/invasion/VodalianSerpent.java new file mode 100644 index 00000000000..02703289141 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/VodalianSerpent.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author LoneFox + + */ +public class VodalianSerpent extends CardImpl { + + public VodalianSerpent(UUID ownerId) { + super(ownerId, 86, "Vodalian Serpent", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Serpent"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Kicker {2} + this.addAbility(new KickerAbility("{2}")); + // Vodalian Serpent can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + // If Vodalian Serpent was kicked, it enters the battlefield with four +1/+1 counters on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(4)), + KickedCondition.getInstance(), true, "If {this} was kicked, it enters the battlefield with four +1/+1 counters on it.", "")); + } + + public VodalianSerpent(final VodalianSerpent card) { + super(card); + } + + @Override + public VodalianSerpent copy() { + return new VodalianSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/WanderingStream.java b/Mage.Sets/src/mage/sets/invasion/WanderingStream.java new file mode 100644 index 00000000000..e2808415610 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/WanderingStream.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.dynamicvalue.MultipliedValue; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class WanderingStream extends CardImpl { + + public WanderingStream(UUID ownerId) { + super(ownerId, 224, "Wandering Stream", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}"); + this.expansionSetCode = "INV"; + + // Domain - You gain 2 life for each basic land type among lands you control. + Effect effect = new GainLifeEffect(new MultipliedValue(new DomainValue(), 2)); + effect.setText("Domain - You gain 2 life for each basic land type among lands you control"); + this.getSpellAbility().addEffect(effect); + } + + public WanderingStream(final WanderingStream card) { + super(card); + } + + @Override + public WanderingStream copy() { + return new WanderingStream(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/WaxWane.java b/Mage.Sets/src/mage/sets/invasion/WaxWane.java new file mode 100644 index 00000000000..d400f69ee06 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/WaxWane.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class WaxWane extends mage.sets.archenemy.WaxWane { + + public WaxWane(UUID ownerId) { + super(ownerId); + this.cardNumber = 296; + this.expansionSetCode = "INV"; + } + + public WaxWane(final WaxWane card) { + super(card); + } + + @Override + public WaxWane copy() { + return new WaxWane(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java b/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java new file mode 100644 index 00000000000..5475eba52ef --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class WingsOfHope extends CardImpl { + + public WingsOfHope(UUID ownerId) { + super(ownerId, 289, "Wings of Hope", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Enchanted creature gets +1/+3 and has flying. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 3, Duration.WhileOnBattlefield)); + Effect effect = new GainAbilityAttachedEffect(FlyingAbility.getInstance(), AttachmentType.AURA); + effect.setText("and has flying"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public WingsOfHope(final WingsOfHope card) { + super(card); + } + + @Override + public WingsOfHope copy() { + return new WingsOfHope(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/Winnow.java b/Mage.Sets/src/mage/sets/invasion/Winnow.java new file mode 100644 index 00000000000..c309612be7c --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/Winnow.java @@ -0,0 +1,100 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetNonlandPermanent; + +/** + * + * @author LoneFox + */ +public class Winnow extends CardImpl { + + public Winnow(UUID ownerId) { + super(ownerId, 45, "Winnow", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "INV"; + + // Destroy target nonland permanent if another permanent with the same name is on the battlefield. + this.getSpellAbility().addEffect(new WinnowEffect()); + this.getSpellAbility().addTarget(new TargetNonlandPermanent()); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public Winnow(final Winnow card) { + super(card); + } + + @Override + public Winnow copy() { + return new Winnow(this); + } +} + +class WinnowEffect extends DestroyTargetEffect { + + public WinnowEffect() { + super(); + staticText = "Destroy target nonland permanent if another permanent with the same name is on the battlefield."; + } + + public WinnowEffect(final WinnowEffect effect) { + super(effect); + } + + @Override + public WinnowEffect copy() { + return new WinnowEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent target = game.getPermanent(source.getFirstTarget()); + if(target != null) { + FilterPermanent filter = new FilterPermanent(); + filter.add(new NamePredicate(target.getName())); + if(new PermanentsOnBattlefieldCount(filter).calculate(game, source, this) > 1) { + super.apply(game, source); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/izzetvsgolgari/FeastOrFamine.java b/Mage.Sets/src/mage/sets/izzetvsgolgari/FeastOrFamine.java new file mode 100644 index 00000000000..b94cd837924 --- /dev/null +++ b/Mage.Sets/src/mage/sets/izzetvsgolgari/FeastOrFamine.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.izzetvsgolgari; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Mode; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.permanent.token.ZombieToken; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FeastOrFamine extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("nonartifact, nonblack creature"); + + static { + filter.add(Predicates.not(new CardTypePredicate(CardType.ARTIFACT))); + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + + public FeastOrFamine(UUID ownerId) { + super(ownerId, 72, "Feast or Famine", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{B}"); + this.expansionSetCode = "DDJ"; + + // Choose one - Put a 2/2 black Zombie creature token onto the battlefield; + this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken())); + + // or destroy target nonartifact, nonblack creature and it can't be regenerated. + Mode mode = new Mode(); + mode.getEffects().add(new DestroyTargetEffect(true)); + mode.getTargets().add(new TargetCreaturePermanent(filter)); + this.getSpellAbility().addMode(mode); + } + + public FeastOrFamine(final FeastOrFamine card) { + super(card); + } + + @Override + public FeastOrFamine copy() { + return new FeastOrFamine(this); + } +} diff --git a/Mage.Sets/src/mage/sets/izzetvsgolgari/GhoulsFeast.java b/Mage.Sets/src/mage/sets/izzetvsgolgari/GhoulsFeast.java new file mode 100644 index 00000000000..97f1d248683 --- /dev/null +++ b/Mage.Sets/src/mage/sets/izzetvsgolgari/GhoulsFeast.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.izzetvsgolgari; + +import java.util.UUID; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.common.CardsInControllerGraveyardCount; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GhoulsFeast extends CardImpl { + + public GhoulsFeast(UUID ownerId) { + super(ownerId, 67, "Ghoul's Feast", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "DDJ"; + + // Target creature gets +X/+0 until end of turn, where X is the number of creature cards in your graveyard. + DynamicValue xValue = new CardsInControllerGraveyardCount(new FilterCreatureCard("creature card")); + this.getSpellAbility().addEffect(new BoostTargetEffect(xValue, new StaticValue(0), Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public GhoulsFeast(final GhoulsFeast card) { + super(card); + } + + @Override + public GhoulsFeast copy() { + return new GhoulsFeast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/izzetvsgolgari/Gleancrawler.java b/Mage.Sets/src/mage/sets/izzetvsgolgari/Gleancrawler.java new file mode 100644 index 00000000000..79b57a8c2f4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/izzetvsgolgari/Gleancrawler.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.izzetvsgolgari; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LevelX2 + */ +public class Gleancrawler extends mage.sets.prereleaseevents.Gleancrawler { + + public Gleancrawler(UUID ownerId) { + super(ownerId); + this.cardNumber = 64; + this.expansionSetCode = "DDJ"; + this.rarity = Rarity.RARE; + } + + public Gleancrawler(final Gleancrawler card) { + super(card); + } + + @Override + public Gleancrawler copy() { + return new Gleancrawler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/AthreosGodOfPassage.java b/Mage.Sets/src/mage/sets/journeyintonyx/AthreosGodOfPassage.java index b5024166052..788102604eb 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/AthreosGodOfPassage.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/AthreosGodOfPassage.java @@ -64,12 +64,12 @@ import mage.target.common.TargetOpponent; public class AthreosGodOfPassage extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("another creature you own"); - + static { filter.add(new AnotherPredicate()); filter.add(new OwnerPredicate(TargetController.YOU)); } - + public AthreosGodOfPassage(UUID ownerId) { super(ownerId, 146, "Athreos, God of Passage", Rarity.MYTHIC, new CardType[]{CardType.ENCHANTMENT, CardType.CREATURE}, "{1}{W}{B}"); this.expansionSetCode = "JOU"; @@ -84,12 +84,12 @@ public class AthreosGodOfPassage extends CardImpl { // As long as your devotion to white and black is less than seven, Athreos isn't a creature. Effect effect = new LoseCreatureTypeSourceEffect(new DevotionCount(ColoredManaSymbol.W, ColoredManaSymbol.B), 7); effect.setText("As long as your devotion to white and black is less than seven, Athreos isn't a creature"); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); // Whenever another creature you own dies, return it to your hand unless target opponent pays 3 life. Ability ability = new AthreosDiesCreatureTriggeredAbility(new AthreosGodOfPassageReturnEffect(), false, filter); ability.addTarget(new TargetOpponent()); this.addAbility(ability); - + } public AthreosGodOfPassage(final AthreosGodOfPassage card) { @@ -103,21 +103,21 @@ public class AthreosGodOfPassage extends CardImpl { } class AthreosGodOfPassageReturnEffect extends OneShotEffect { - + public AthreosGodOfPassageReturnEffect() { super(Outcome.Benefit); this.staticText = "return it to your hand unless target opponent pays 3 life"; } - + public AthreosGodOfPassageReturnEffect(final AthreosGodOfPassageReturnEffect effect) { super(effect); } - + @Override public AthreosGodOfPassageReturnEffect copy() { return new AthreosGodOfPassageReturnEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -134,13 +134,13 @@ class AthreosGodOfPassageReturnEffect extends OneShotEffect { if (cost.pay(source, game, source.getSourceId(), opponent.getId(), false)) { paid = true; } - } + } } if (opponent == null || !paid) { if (game.getState().getZone(creature.getId()).equals(Zone.GRAVEYARD)) { - controller.moveCardToHandWithInfo(creature, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(game.getCard(creatureId), null, Zone.HAND, source, game); } - } + } } return true; } diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/BanishingLight.java b/Mage.Sets/src/mage/sets/journeyintonyx/BanishingLight.java index feaed29eaec..392e925c027 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/BanishingLight.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/BanishingLight.java @@ -53,21 +53,20 @@ import mage.util.CardUtil; public class BanishingLight extends CardImpl { private final static FilterNonlandPermanent filter = new FilterNonlandPermanent("nonland permanent an opponent controls"); - + static { filter.add(new ControllerPredicate(TargetController.OPPONENT)); - } - + } + public BanishingLight(UUID ownerId) { super(ownerId, 5, "Banishing Light", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); this.expansionSetCode = "JOU"; - // When Banishing Light enters the battlefield, exile target nonland permanent an opponent controls until Banishing Light leaves the battlefield. Ability ability = new EntersBattlefieldTriggeredAbility(new BanishingLightExileEffect()); ability.addTarget(new TargetPermanent(filter)); ability.addEffect(new CreateDelayedTriggeredAbilityEffect(new OnLeaveReturnExiledToBattlefieldAbility())); - this.addAbility(ability); + this.addAbility(ability); } public BanishingLight(final BanishingLight card) { @@ -102,7 +101,7 @@ class BanishingLightExileEffect extends OneShotEffect { // If Banishing Light leaves the battlefield before its triggered ability resolves, // the target won't be exiled. if (permanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/BrainMaggot.java b/Mage.Sets/src/mage/sets/journeyintonyx/BrainMaggot.java index e2ce4ed1bcb..3f758c3321a 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/BrainMaggot.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/BrainMaggot.java @@ -27,7 +27,6 @@ */ package mage.sets.journeyintonyx; -import java.util.LinkedList; import java.util.UUID; import mage.MageInt; import mage.MageObject; @@ -74,7 +73,7 @@ public class BrainMaggot extends CardImpl { Ability ability = new EntersBattlefieldTriggeredAbility(new BrainMaggotExileEffect()); ability.addTarget(new TargetOpponent()); ability.addEffect(new CreateDelayedTriggeredAbilityEffect(new BrainMaggotReturnExiledCardAbility())); - this.addAbility(ability); + this.addAbility(ability); } public BrainMaggot(final BrainMaggot card) { @@ -110,7 +109,7 @@ class BrainMaggotExileEffect extends OneShotEffect { Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); if (controller != null && opponent != null && sourcePermanent != null) { if (!opponent.getHand().isEmpty()) { - opponent.revealCards(sourcePermanent.getName(), opponent.getHand(), game); + opponent.revealCards(sourcePermanent.getIdName(), opponent.getHand(), game); FilterCard filter = new FilterNonlandCard("nonland card to exile"); TargetCard target = new TargetCard(Zone.HAND, filter); @@ -130,11 +129,10 @@ class BrainMaggotExileEffect extends OneShotEffect { } /** - * Returns the exiled card as source permanent leaves battlefield - * Uses no stack + * Returns the exiled card as source permanent leaves battlefield Uses no stack + * * @author LevelX2 */ - class BrainMaggotReturnExiledCardAbility extends DelayedTriggeredAbility { public BrainMaggotReturnExiledCardAbility() { @@ -190,18 +188,13 @@ class BrainMaggotReturnExiledCardEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = source.getSourceObject(game); if (sourceObject != null && controller != null) { - int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() -1; + int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() - 1; ExileZone exile = game.getExile().getExileZone(CardUtil.getExileZoneId(game, source.getSourceId(), zoneChangeCounter)); Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); if (exile != null && sourcePermanent != null) { - LinkedList cards = new LinkedList<>(exile); - for (UUID cardId : cards) { - Card card = game.getCard(cardId); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.EXILED); - } - exile.clear(); + controller.moveCards(exile, null, Zone.HAND, source, game); return true; - } + } } return false; } diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/HallOfTriumph.java b/Mage.Sets/src/mage/sets/journeyintonyx/HallOfTriumph.java index 8e4ad8a781f..6fb34b789b2 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/HallOfTriumph.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/HallOfTriumph.java @@ -95,7 +95,7 @@ class HallOfTriumphEffect extends OneShotEffect { ChoiceColor colorChoice = new ChoiceColor(); colorChoice.setMessage("Choose color"); while (!player.choose(Outcome.BoostCreature, colorChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/Hubris.java b/Mage.Sets/src/mage/sets/journeyintonyx/Hubris.java index c9ac8245496..0193cf32751 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/Hubris.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/Hubris.java @@ -31,6 +31,8 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -52,12 +54,10 @@ public class Hubris extends CardImpl { super(ownerId, 41, "Hubris", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); this.expansionSetCode = "JOU"; - // Return target creature and all Auras attached to it to their owners' hand. this.getSpellAbility().addEffect(new HubrisReturnEffect()); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); - } public Hubris(final Hubris card) { @@ -96,16 +96,12 @@ class HubrisReturnEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - for (UUID targetId: targetPointer.getTargets(game, source)) { + for (UUID targetId : targetPointer.getTargets(game, source)) { Permanent creature = game.getPermanent(targetId); if (creature != null) { - controller.moveCardToHandWithInfo(creature, source.getSourceId(), game, Zone.BATTLEFIELD); - for (UUID attachementId: creature.getAttachments()) { - Permanent attachment = game.getPermanent(attachementId); - if (attachment != null && filter.match(attachment, game)) { - controller.moveCardToHandWithInfo(attachment, source.getSourceId(), game, Zone.BATTLEFIELD); - } - } + Cards cardsToHand = new CardsImpl(creature.getAttachments()); + cardsToHand.add(creature); + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); } } return true; diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/MarketFestival.java b/Mage.Sets/src/mage/sets/journeyintonyx/MarketFestival.java index 6075982ce44..affa7e15e95 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/MarketFestival.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/MarketFestival.java @@ -148,7 +148,7 @@ class MarketFestivalManaEffect extends ManaEffect { choiceColor.setMessage("Second mana color for " + sourceObject.getLogName()); } while (!controller.choose(Outcome.Benefit, choiceColor, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/NessianGameWarden.java b/Mage.Sets/src/mage/sets/journeyintonyx/NessianGameWarden.java index 4fc4e9d651e..2926899d604 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/NessianGameWarden.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/NessianGameWarden.java @@ -1,151 +1,130 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.journeyintonyx; - -import java.util.UUID; -import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; -import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; -import mage.cards.CardImpl; -import mage.cards.Cards; -import mage.cards.CardsImpl; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.filter.FilterCard; -import mage.filter.common.FilterControlledPermanent; -import mage.filter.common.FilterCreatureCard; -import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; -import mage.target.TargetCard; - -/** - * - * @author LevelX2 - */ -public class NessianGameWarden extends CardImpl { - - public NessianGameWarden(UUID ownerId) { - super(ownerId, 132, "Nessian Game Warden", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); - this.expansionSetCode = "JOU"; - this.subtype.add("Beast"); - - this.power = new MageInt(4); - this.toughness = new MageInt(5); - - // When Nessian Game Warden enters the battlefield, look at the top X cards of your library, where X is the number of forests you control. You may reveal a creature card from among them and put it into your hand. Put the rest on the bottom of your library in any order. - this.addAbility(new EntersBattlefieldTriggeredAbility(new NessianGameWardenEffect(), false)); - } - - public NessianGameWarden(final NessianGameWarden card) { - super(card); - } - - @Override - public NessianGameWarden copy() { - return new NessianGameWarden(this); - } -} - -class NessianGameWardenEffect extends OneShotEffect { - - private static final FilterControlledPermanent filter = new FilterControlledPermanent("forests you control"); - - static { - filter.add(new SubtypePredicate("Forest")); - } - - public NessianGameWardenEffect() { - super(Outcome.DrawCard); - this.staticText = "look at the top X cards of your library, where X is the number of forests you control. You may reveal a creature card from among them and put it into your hand. Put the rest on the bottom of your library in any order"; - } - - public NessianGameWardenEffect(final NessianGameWardenEffect effect) { - super(effect); - } - - @Override - public NessianGameWardenEffect copy() { - return new NessianGameWardenEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); - if (player == null || sourcePermanent == null) { - return false; - } - - Cards cards = new CardsImpl(); - int count = new PermanentsOnBattlefieldCount(filter).calculate(game, source, this); - count = Math.min(player.getLibrary().size(), count); - for (int i = 0; i < count; i++) { - Card card = player.getLibrary().removeFromTop(game); - if (card != null) { - cards.add(card); - } - } - player.lookAtCards(sourcePermanent.getName(), cards, game); - - if (!cards.isEmpty()) { - TargetCard target = new TargetCard(Zone.LIBRARY, new FilterCreatureCard("creature card to put into your hand")); - if (target.canChoose(source.getSourceId(), player.getId(), game) && player.choose(Outcome.DrawCard, cards, target, game)) { - Card card = cards.get(target.getFirstTarget(), game); - if (card != null) { - player.revealCards(sourcePermanent.getName(), new CardsImpl(card), game); - cards.remove(card); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - } - } - } - - - TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { - player.choose(Outcome.Neutral, cards, target, game); - Card card = cards.get(target.getFirstTarget(), game); - if (card != null) { - cards.remove(card); - card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, false); - } - target.clearChosen(); - } - if (cards.size() == 1) { - Card card = cards.get(cards.iterator().next(), game); - card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, false); - } - return true; - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.journeyintonyx; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.common.FilterCreatureCard; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetCard; + +/** + * + * @author LevelX2 + */ +public class NessianGameWarden extends CardImpl { + + public NessianGameWarden(UUID ownerId) { + super(ownerId, 132, "Nessian Game Warden", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); + this.expansionSetCode = "JOU"; + this.subtype.add("Beast"); + + this.power = new MageInt(4); + this.toughness = new MageInt(5); + + // When Nessian Game Warden enters the battlefield, look at the top X cards of your library, where X is the number of forests you control. You may reveal a creature card from among them and put it into your hand. Put the rest on the bottom of your library in any order. + this.addAbility(new EntersBattlefieldTriggeredAbility(new NessianGameWardenEffect(), false)); + } + + public NessianGameWarden(final NessianGameWarden card) { + super(card); + } + + @Override + public NessianGameWarden copy() { + return new NessianGameWarden(this); + } +} + +class NessianGameWardenEffect extends OneShotEffect { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("forests you control"); + + static { + filter.add(new SubtypePredicate("Forest")); + } + + public NessianGameWardenEffect() { + super(Outcome.DrawCard); + this.staticText = "look at the top X cards of your library, where X is the number of forests you control. You may reveal a creature card from among them and put it into your hand. Put the rest on the bottom of your library in any order"; + } + + public NessianGameWardenEffect(final NessianGameWardenEffect effect) { + super(effect); + } + + @Override + public NessianGameWardenEffect copy() { + return new NessianGameWardenEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if (controller == null || sourcePermanent == null) { + return false; + } + + Cards cards = new CardsImpl(); + int count = new PermanentsOnBattlefieldCount(filter).calculate(game, source, this); + cards.addAll(controller.getLibrary().getTopCards(game, count)); + controller.lookAtCards(sourcePermanent.getIdName(), cards, game); + + if (!cards.isEmpty()) { + TargetCard target = new TargetCard(Zone.LIBRARY, new FilterCreatureCard("creature card to put into your hand")); + if (target.canChoose(source.getSourceId(), controller.getId(), game) && controller.choose(Outcome.DrawCard, cards, target, game)) { + Card card = cards.get(target.getFirstTarget(), game); + if (card != null) { + controller.revealCards(sourcePermanent.getName(), new CardsImpl(card), game); + cards.remove(card); + controller.moveCards(card, null, Zone.HAND, source, game); + } + } + } + + controller.putCardsOnBottomOfLibrary(cards, game, source, true); + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/journeyintonyx/ScourgeOfFleets.java b/Mage.Sets/src/mage/sets/journeyintonyx/ScourgeOfFleets.java index b6b3b9e6720..29a3a66637f 100644 --- a/Mage.Sets/src/mage/sets/journeyintonyx/ScourgeOfFleets.java +++ b/Mage.Sets/src/mage/sets/journeyintonyx/ScourgeOfFleets.java @@ -33,6 +33,8 @@ import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -78,27 +80,27 @@ public class ScourgeOfFleets extends CardImpl { } class ScourgeOfFleetsEffect extends OneShotEffect { - + private static final FilterControlledPermanent filter = new FilterControlledPermanent("number of Islands you control"); - + static { filter.add(new SubtypePredicate("Island")); } - + public ScourgeOfFleetsEffect() { super(Outcome.Benefit); this.staticText = "return each creature your opponents control with toughness X or less, where X is the number of Islands you control"; } - + public ScourgeOfFleetsEffect(final ScourgeOfFleetsEffect effect) { super(effect); } - + @Override public ScourgeOfFleetsEffect copy() { return new ScourgeOfFleetsEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -106,10 +108,12 @@ class ScourgeOfFleetsEffect extends OneShotEffect { int islands = game.getBattlefield().count(filter, source.getSourceId(), source.getControllerId(), game); FilterPermanent creatureFilter = new FilterCreaturePermanent(); creatureFilter.add(new ControllerPredicate(TargetController.OPPONENT)); - creatureFilter.add(new ToughnessPredicate(Filter.ComparisonType.LessThan, islands +1)); - for (Permanent permanent: game.getBattlefield().getActivePermanents(creatureFilter, source.getControllerId(), source.getSourceId(), game)) { - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + creatureFilter.add(new ToughnessPredicate(Filter.ComparisonType.LessThan, islands + 1)); + Cards cardsToHand = new CardsImpl(); + for (Permanent permanent : game.getBattlefield().getActivePermanents(creatureFilter, source.getControllerId(), source.getSourceId(), game)) { + cardsToHand.add(permanent); } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/judgment/AnuridBrushhopper.java b/Mage.Sets/src/mage/sets/judgment/AnuridBrushhopper.java new file mode 100644 index 00000000000..d3be1aaddbb --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/AnuridBrushhopper.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardTargetCost; +import mage.abilities.effects.common.ExileReturnToBattlefieldOwnerNextEndStepEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.target.common.TargetCardInHand; + +/** + * + * @author fireshoes + */ +public class AnuridBrushhopper extends CardImpl { + + public AnuridBrushhopper(UUID ownerId) { + super(ownerId, 137, "Anurid Brushhopper", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{G}{W}"); + this.expansionSetCode = "JUD"; + this.subtype.add("Frog"); + this.subtype.add("Beast"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Discard two cards: Exile Anurid Brushhopper. Return it to the battlefield under its owner's control at the beginning of the next end step. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new ExileReturnToBattlefieldOwnerNextEndStepEffect(true), + new DiscardTargetCost(new TargetCardInHand(2, new FilterCard("two cards"))))); + } + + public AnuridBrushhopper(final AnuridBrushhopper card) { + super(card); + } + + @Override + public AnuridBrushhopper copy() { + return new AnuridBrushhopper(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/CabalTherapy.java b/Mage.Sets/src/mage/sets/judgment/CabalTherapy.java index b6c15bf2768..524c6e205e3 100644 --- a/Mage.Sets/src/mage/sets/judgment/CabalTherapy.java +++ b/Mage.Sets/src/mage/sets/judgment/CabalTherapy.java @@ -101,7 +101,7 @@ class CabalTherapyEffect extends OneShotEffect { cardChoice.clearChoice(); while (!controller.choose(Outcome.Discard, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/judgment/CabalTrainee.java b/Mage.Sets/src/mage/sets/judgment/CabalTrainee.java new file mode 100644 index 00000000000..fb0817a70c9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/CabalTrainee.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CabalTrainee extends CardImpl { + + public CabalTrainee(UUID ownerId) { + super(ownerId, 63, "Cabal Trainee", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); + this.expansionSetCode = "JUD"; + this.subtype.add("Human"); + this.subtype.add("Minion"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Sacrifice Cabal Trainee: Target creature gets -2/-0 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(-2, 0, Duration.EndOfTurn), new SacrificeSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public CabalTrainee(final CabalTrainee card) { + super(card); + } + + @Override + public CabalTrainee copy() { + return new CabalTrainee(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/FlashOfInsight.java b/Mage.Sets/src/mage/sets/judgment/FlashOfInsight.java index 421391c7998..7d3422aac21 100644 --- a/Mage.Sets/src/mage/sets/judgment/FlashOfInsight.java +++ b/Mage.Sets/src/mage/sets/judgment/FlashOfInsight.java @@ -141,7 +141,7 @@ class FlashOfInsightEffect extends OneShotEffect { .append(" card").append(cards.size() > 1 ? "s":"") .append(" on the bottom of his or her library").toString()); } - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/judgment/JeskaWarriorAdept.java b/Mage.Sets/src/mage/sets/judgment/JeskaWarriorAdept.java new file mode 100644 index 00000000000..7d12fb0dd3a --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/JeskaWarriorAdept.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class JeskaWarriorAdept extends CardImpl { + + public JeskaWarriorAdept(UUID ownerId) { + super(ownerId, 93, "Jeska, Warrior Adept", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}{R}"); + this.expansionSetCode = "JUD"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Barbarian"); + this.subtype.add("Warrior"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + // Haste + this.addAbility(HasteAbility.getInstance()); + // {tap}: Jeska, Warrior Adept deals 1 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public JeskaWarriorAdept(final JeskaWarriorAdept card) { + super(card); + } + + @Override + public JeskaWarriorAdept copy() { + return new JeskaWarriorAdept(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/KrosanReclamation.java b/Mage.Sets/src/mage/sets/judgment/KrosanReclamation.java new file mode 100644 index 00000000000..70ba3409027 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/KrosanReclamation.java @@ -0,0 +1,145 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.List; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FlashbackAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TimingRule; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetCard; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class KrosanReclamation extends CardImpl { + + public KrosanReclamation(UUID ownerId) { + super(ownerId, 122, "Krosan Reclamation", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "JUD"; + + // Target player shuffles up to two target cards from his or her graveyard into his or her library. + this.getSpellAbility().addEffect(new KrosanReclamationEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + this.getSpellAbility().addTarget(new KrosanReclamationTarget()); + + // Flashback {1}{G} + this.addAbility(new FlashbackAbility(new ManaCostsImpl("{1}{G}"), TimingRule.INSTANT)); + } + + public KrosanReclamation(final KrosanReclamation card) { + super(card); + } + + @Override + public KrosanReclamation copy() { + return new KrosanReclamation(this); + } +} + +class KrosanReclamationEffect extends OneShotEffect { + + public KrosanReclamationEffect() { + super(Outcome.Neutral); + this.staticText = "Target player shuffles up to two target cards from his or her graveyard into his or her library"; + } + + public KrosanReclamationEffect(final KrosanReclamationEffect effect) { + super(effect); + } + + @Override + public KrosanReclamationEffect copy() { + return new KrosanReclamationEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getFirstTarget()); + if (player != null) { + List targets = source.getTargets().get(1).getTargets(); + boolean shuffle = false; + for (UUID targetId : targets) { + Card card = game.getCard(targetId); + if (card != null) { + if (player.getGraveyard().contains(card.getId())) { + player.getGraveyard().remove(card); + card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); + shuffle = true; + } + } + } + if (shuffle) { + player.shuffleLibrary(game); + } + return true; + } + return false; + } +} + +class KrosanReclamationTarget extends TargetCard { + + public KrosanReclamationTarget() { + super(0, 2, Zone.GRAVEYARD, new FilterCard()); + } + + public KrosanReclamationTarget(final KrosanReclamationTarget target) { + super(target); + } + + @Override + public boolean canTarget(UUID id, Ability source, Game game) { + Card card = game.getCard(id); + if (card != null && game.getState().getZone(card.getId()) == Zone.GRAVEYARD) { + UUID firstTarget = source.getFirstTarget(); + if (firstTarget != null && game.getPlayer(firstTarget).getGraveyard().contains(id)) { + return filter.match(card, game); + } + } + return false; + } + + @Override + public KrosanReclamationTarget copy() { + return new KrosanReclamationTarget(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/LavaDart.java b/Mage.Sets/src/mage/sets/judgment/LavaDart.java new file mode 100644 index 00000000000..0d992950f94 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/LavaDart.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.FlashbackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TimingRule; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class LavaDart extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("a Mountain"); + + static { + filter.add(new SubtypePredicate("Mountain")); + } + + public LavaDart(UUID ownerId) { + super(ownerId, 94, "Lava Dart", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{R}"); + this.expansionSetCode = "JUD"; + + // Lava Dart deals 1 damage to target creature or player. + this.getSpellAbility().addEffect(new DamageTargetEffect(1)); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + + // Flashback-Sacrifice a Mountain. + this.addAbility(new FlashbackAbility(new SacrificeTargetCost(new TargetControlledPermanent(filter)), TimingRule.INSTANT)); + } + + public LavaDart(final LavaDart card) { + super(card); + } + + @Override + public LavaDart copy() { + return new LavaDart(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/MirarisWake.java b/Mage.Sets/src/mage/sets/judgment/MirarisWake.java index c0dbc7a9af3..c59f9b7f1bf 100644 --- a/Mage.Sets/src/mage/sets/judgment/MirarisWake.java +++ b/Mage.Sets/src/mage/sets/judgment/MirarisWake.java @@ -54,8 +54,10 @@ public class MirarisWake extends CardImpl { // Creatures you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(1,1,Duration.WhileOnBattlefield))); // Whenever you tap a land for mana, add one mana to your mana pool of any type that land produced. + AddManaOfAnyTypeProducedEffect effect = new AddManaOfAnyTypeProducedEffect(); + effect.setText("add one mana to your mana pool of any type that land produced"); this.addAbility(new TapForManaAllTriggeredManaAbility( - new AddManaOfAnyTypeProducedEffect(), + effect, new FilterControlledLandPermanent("you tap a land"), SetTargetPointer.PERMANENT)); diff --git a/Mage.Sets/src/mage/sets/judgment/NantukoTracer.java b/Mage.Sets/src/mage/sets/judgment/NantukoTracer.java new file mode 100644 index 00000000000..e0752b818d2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/NantukoTracer.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCardInGraveyard; + +/** + * + * @author fireshoes + */ +public class NantukoTracer extends CardImpl { + + public NantukoTracer(UUID ownerId) { + super(ownerId, 125, "Nantuko Tracer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "JUD"; + this.subtype.add("Insect"); + this.subtype.add("Druid"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // When Nantuko Tracer enters the battlefield, you may put target card from a graveyard on the bottom of its owner's library. + Ability ability = new EntersBattlefieldTriggeredAbility(new PutOnLibraryTargetEffect(false), true); + ability.addTarget(new TargetCardInGraveyard()); + this.addAbility(ability); + } + + public NantukoTracer(final NantukoTracer card) { + super(card); + } + + @Override + public NantukoTracer copy() { + return new NantukoTracer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/PhantomNishoba.java b/Mage.Sets/src/mage/sets/judgment/PhantomNishoba.java new file mode 100644 index 00000000000..51cb80804d3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/PhantomNishoba.java @@ -0,0 +1,155 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.PreventionEffectImpl; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.game.turn.Step; + +/** + * + * @author fireshoes + */ +public class PhantomNishoba extends CardImpl { + + public PhantomNishoba(UUID ownerId) { + super(ownerId, 140, "Phantom Nishoba", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{G}{W}"); + this.expansionSetCode = "JUD"; + this.subtype.add("Cat"); + this.subtype.add("Beast"); + this.subtype.add("Spirit"); + this.power = new MageInt(0); + this.toughness = new MageInt(0); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // Phantom Nishoba enters the battlefield with seven +1/+1 counters on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(7), true), "with seven +1/+1 counters on it")); + + // Whenever Phantom Nishoba deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + + // If damage would be dealt to Phantom Nishoba, prevent that damage. Remove a +1/+1 counter from Phantom Nishoba. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PhantomNishobaPreventionEffect())); + } + + public PhantomNishoba(final PhantomNishoba card) { + super(card); + } + + @Override + public PhantomNishoba copy() { + return new PhantomNishoba(this); + } +} + +class PhantomNishobaPreventionEffect extends PreventionEffectImpl { + + // remember turn and phase step to check if counter in this step was already removed + private int turn = 0; + private Step combatPhaseStep = null; + + public PhantomNishobaPreventionEffect() { + super(Duration.WhileOnBattlefield); + staticText = "If damage would be dealt to {this}, prevent that damage. Remove a +1/+1 counter from {this}"; + } + + public PhantomNishobaPreventionEffect(final PhantomNishobaPreventionEffect effect) { + super(effect); + this.turn = effect.turn; + this.combatPhaseStep = effect.combatPhaseStep; + } + + @Override + public PhantomNishobaPreventionEffect copy() { + return new PhantomNishobaPreventionEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + preventDamageAction(event, source, game); + + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + boolean removeCounter = true; + // check if in the same combat damage step already a counter was removed + if (game.getTurn().getPhase().getStep().getType().equals(PhaseStep.COMBAT_DAMAGE)) { + if (game.getTurnNum() == turn + && game.getTurn().getStep().equals(combatPhaseStep)) { + removeCounter = false; + } else { + turn = game.getTurnNum(); + combatPhaseStep = game.getTurn().getStep(); + } + } + + if(removeCounter && permanent.getCounters().containsKey(CounterType.P1P1)) { + StringBuilder sb = new StringBuilder(permanent.getName()).append(": "); + permanent.removeCounters(CounterType.P1P1.createInstance(), game); + sb.append("Removed a +1/+1 counter "); + game.informPlayers(sb.toString()); + } + } + + return false; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (super.applies(event, source, game)) { + if (event.getTargetId().equals(source.getSourceId())) { + return true; + } + } + return false; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/judgment/PlanarChaos.java b/Mage.Sets/src/mage/sets/judgment/PlanarChaos.java new file mode 100644 index 00000000000..6820fc2da3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/PlanarChaos.java @@ -0,0 +1,132 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SpellCastAllTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SetTargetPointer; +import mage.constants.TargetController; +import mage.filter.FilterSpell; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class PlanarChaos extends CardImpl { + + public PlanarChaos(UUID ownerId) { + super(ownerId, 97, "Planar Chaos", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}"); + this.expansionSetCode = "JUD"; + + // At the beginning of your upkeep, flip a coin. If you lose the flip, sacrifice Planar Chaos. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new PlanarChaosUpkeepEffect(), TargetController.YOU, false)); + + // Whenever a player casts a spell, that player flips a coin. If he or she loses the flip, counter that spell. + this.addAbility(new SpellCastAllTriggeredAbility(new PlanarChaosCastAllEffect(), new FilterSpell("a spell"), false, SetTargetPointer.SPELL)); + } + + public PlanarChaos(final PlanarChaos card) { + super(card); + } + + @Override + public PlanarChaos copy() { + return new PlanarChaos(this); + } +} + +class PlanarChaosUpkeepEffect extends OneShotEffect { + + PlanarChaosUpkeepEffect() { + super(Outcome.Damage); + staticText = "flip a coin. If you lose the flip, sacrifice {this}"; + } + + PlanarChaosUpkeepEffect(final PlanarChaosUpkeepEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + if (!player.flipCoin(game)) { + Permanent perm = game.getPermanent(source.getSourceId()); + if (perm != null) { + perm.sacrifice(source.getSourceId(), game); + } + return true; + } + } + return false; + } + + @Override + public PlanarChaosUpkeepEffect copy() { + return new PlanarChaosUpkeepEffect(this); + } +} + +class PlanarChaosCastAllEffect extends OneShotEffect { + + public PlanarChaosCastAllEffect() { + super(Outcome.Benefit); + this.staticText = "that player flips a coin. If he or she loses the flip, counter that spell"; + } + + public PlanarChaosCastAllEffect(final PlanarChaosCastAllEffect effect) { + super(effect); + } + + @Override + public PlanarChaosCastAllEffect copy() { + return new PlanarChaosCastAllEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + if (!controller.flipCoin(game)) { + game.informPlayers("Planar Chaos: Spell countered"); + return game.getStack().counter(getTargetPointer().getFirst(game, source), source.getSourceId(), game); + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/judgment/SpurnmageAdvocate.java b/Mage.Sets/src/mage/sets/judgment/SpurnmageAdvocate.java new file mode 100644 index 00000000000..7ac6d852660 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/SpurnmageAdvocate.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class SpurnmageAdvocate extends mage.sets.commander.SpurnmageAdvocate { + + public SpurnmageAdvocate(UUID ownerId) { + super(ownerId); + this.cardNumber = 27; + this.expansionSetCode = "JUD"; + } + + public SpurnmageAdvocate(final SpurnmageAdvocate card) { + super(card); + } + + @Override + public SpurnmageAdvocate copy() { + return new SpurnmageAdvocate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/judgment/StitchTogether.java b/Mage.Sets/src/mage/sets/judgment/StitchTogether.java new file mode 100644 index 00000000000..a1a294f5612 --- /dev/null +++ b/Mage.Sets/src/mage/sets/judgment/StitchTogether.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.judgment; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class StitchTogether extends mage.sets.commander.StitchTogether { + + public StitchTogether(UUID ownerId) { + super(ownerId); + this.cardNumber = 72; + this.expansionSetCode = "JUD"; + } + + public StitchTogether(final StitchTogether card) { + super(card); + } + + @Override + public StitchTogether copy() { + return new StitchTogether(this); + } +} diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/ButcherOfTheHorde.java b/Mage.Sets/src/mage/sets/khansoftarkir/ButcherOfTheHorde.java index d24de33f7a5..cab7e99034a 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/ButcherOfTheHorde.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/ButcherOfTheHorde.java @@ -118,7 +118,7 @@ class ButcherOfTheHordeEffect extends OneShotEffect { abilityChoice.setChoices(abilities); while (!abilityChoice.isChosen()) { controller.choose(Outcome.AddAbility, abilityChoice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/HordelingOutburst.java b/Mage.Sets/src/mage/sets/khansoftarkir/HordelingOutburst.java index 663895c7925..d812a84e0d4 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/HordelingOutburst.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/HordelingOutburst.java @@ -44,9 +44,8 @@ public class HordelingOutburst extends CardImpl { super(ownerId, 111, "Hordeling Outburst", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{R}{R}"); this.expansionSetCode = "KTK"; - // Put 3 1/1 red Goblin creature tokens onto the battlefield. - this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(expansionSetCode), 3)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(), 3)); } public HordelingOutburst(final HordelingOutburst card) { diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MarduAscendancy.java b/Mage.Sets/src/mage/sets/khansoftarkir/MarduAscendancy.java index 86f5efc4b4e..13e222bca19 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MarduAscendancy.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MarduAscendancy.java @@ -64,9 +64,8 @@ public class MarduAscendancy extends CardImpl { super(ownerId, 185, "Mardu Ascendancy", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{R}{W}{B}"); this.expansionSetCode = "KTK"; - // Whenever a nontoken creature you control attacks, put a 1/1 red Goblin creature token onto the battlefield tapped and attacking. - this.addAbility(new AttacksCreatureYouControlTriggeredAbility(new CreateTokenEffect(new GoblinToken(expansionSetCode), 1, true, true), false, attackFilter)); + this.addAbility(new AttacksCreatureYouControlTriggeredAbility(new CreateTokenEffect(new GoblinToken(), 1, true, true), false, attackFilter)); // Sacrifice Mardu Ascendancy: Creatures you control get +0/+3 until end of turn. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostAllEffect(0, 3, Duration.EndOfTurn, filter, false), diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MarduHeartPiercer.java b/Mage.Sets/src/mage/sets/khansoftarkir/MarduHeartPiercer.java index 033f51b6ca2..f1c30c2f600 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MarduHeartPiercer.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MarduHeartPiercer.java @@ -56,8 +56,8 @@ public class MarduHeartPiercer extends CardImpl { this.toughness = new MageInt(3); // Raid - When Mardu Heart-Piercer enters the battlefield, if you attacked with a creature this turn, Mardu Heart-Piercer deals 2 damage to target creature or player. - Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DamageTargetEffect(2)), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, {this} deals 2 damage to target creature or player.", false); + Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DamageTargetEffect(2)), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, {this} deals 2 damage to target creature or player."); ability.addTarget(new TargetCreatureOrPlayer()); this.addAbility(ability, new PlayerAttackedWatcher()); } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MarduHordechief.java b/Mage.Sets/src/mage/sets/khansoftarkir/MarduHordechief.java index 299076753d0..4452b0dd55b 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MarduHordechief.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MarduHordechief.java @@ -55,8 +55,8 @@ public class MarduHordechief extends CardImpl { this.toughness = new MageInt(3); // Raid - When Mardu Hordechief enters the battlefield, if you attacked with a creature this turn, put a 1/1 white Warrior creature token onto the battlefield - this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new MarduHordechiefToken())), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, put a 1/1 white Warrior creature token onto the battlefield.", false), + this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new MarduHordechiefToken())), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, put a 1/1 white Warrior creature token onto the battlefield."), new PlayerAttackedWatcher()); } @@ -82,4 +82,4 @@ class MarduHordechiefToken extends Token { power = new MageInt(1); toughness = new MageInt(1); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MarduSkullhunter.java b/Mage.Sets/src/mage/sets/khansoftarkir/MarduSkullhunter.java index 30527e67f8b..edf6cec6f80 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MarduSkullhunter.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MarduSkullhunter.java @@ -58,10 +58,10 @@ public class MarduSkullhunter extends CardImpl { // Mardu Skullhunter enters the battlefield tapped. this.addAbility(new EntersBattlefieldTappedAbility()); - + // Raid - When Mardu Skullhunter enters the battlefield, if you attacked with a creature this turn, target opponent discards a card. - Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DiscardTargetEffect(1)), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, target opponent discards a card.", false); + Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new DiscardTargetEffect(1)), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, target opponent discards a card."); ability.addTarget(new TargetOpponent()); this.addAbility(ability, new PlayerAttackedWatcher()); } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MarduWarshrieker.java b/Mage.Sets/src/mage/sets/khansoftarkir/MarduWarshrieker.java index f9b1153e60e..754c0bfdc42 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MarduWarshrieker.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MarduWarshrieker.java @@ -55,8 +55,8 @@ public class MarduWarshrieker extends CardImpl { this.toughness = new MageInt(3); // Raid - When Mardu Warshrieker enters the battlefield, if you attacked with a creature this turn, add {R}{W}{B} to your mana pool. - this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(1,0,0,1,1,0,0))), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, add {R}{W}{B} to your mana pool.", false), + this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new AddManaToManaPoolSourceControllerEffect(new Mana(1, 0, 0, 1, 1, 0, 0))), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, add {R}{W}{B} to your mana pool."), new PlayerAttackedWatcher()); } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/MysticOfTheHiddenWay.java b/Mage.Sets/src/mage/sets/khansoftarkir/MysticOfTheHiddenWay.java index 31cc916d8b7..b305db9becc 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/MysticOfTheHiddenWay.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/MysticOfTheHiddenWay.java @@ -30,9 +30,8 @@ package mage.sets.khansoftarkir; import java.util.UUID; import mage.MageInt; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; -import mage.abilities.keyword.MorphAbility; import mage.abilities.keyword.CantBeBlockedSourceAbility; +import mage.abilities.keyword.MorphAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/NarsetEnlightenedMaster.java b/Mage.Sets/src/mage/sets/khansoftarkir/NarsetEnlightenedMaster.java index 70d9517368d..a5093dcec42 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/NarsetEnlightenedMaster.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/NarsetEnlightenedMaster.java @@ -27,7 +27,7 @@ */ package mage.sets.khansoftarkir; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.MageInt; import mage.MageObject; @@ -49,7 +49,6 @@ import mage.constants.Zone; import mage.game.Game; import mage.players.Player; import mage.target.targetpointer.FixedTarget; -import mage.util.CardUtil; /** * @@ -89,12 +88,12 @@ public class NarsetEnlightenedMaster extends CardImpl { class NarsetEnlightenedMasterExileEffect extends OneShotEffect { public NarsetEnlightenedMasterExileEffect() { - super(Outcome.Discard); - staticText = "exile the top four cards of your library. Until end of turn, you may cast noncreature cards exiled with {this} this turn without paying their mana costs"; + super(Outcome.Discard); + staticText = "exile the top four cards of your library. Until end of turn, you may cast noncreature cards exiled with {this} this turn without paying their mana costs"; } public NarsetEnlightenedMasterExileEffect(final NarsetEnlightenedMasterExileEffect effect) { - super(effect); + super(effect); } @Override @@ -102,16 +101,16 @@ class NarsetEnlightenedMasterExileEffect extends OneShotEffect { Player player = game.getPlayer(source.getControllerId()); MageObject sourceObject = game.getObject(source.getSourceId()); if (player != null && sourceObject != null) { - List cards = player.getLibrary().getTopCards(game, 4); + Set cards = player.getLibrary().getTopCards(game, 4); player.moveCards(cards, Zone.LIBRARY, Zone.EXILED, source, game); for (Card card : cards) { - if (game.getState().getZone(card.getId()) == Zone.EXILED && - !card.getCardType().contains(CardType.CREATURE) && - !card.getCardType().contains(CardType.LAND)) { + if (game.getState().getZone(card.getId()) == Zone.EXILED + && !card.getCardType().contains(CardType.CREATURE) + && !card.getCardType().contains(CardType.LAND)) { ContinuousEffect effect = new NarsetEnlightenedMasterCastFromExileEffect(); effect.setTargetPointer(new FixedTarget(card.getId())); game.addEffect(effect, source); - } + } } return true; } @@ -120,7 +119,7 @@ class NarsetEnlightenedMasterExileEffect extends OneShotEffect { @Override public NarsetEnlightenedMasterExileEffect copy() { - return new NarsetEnlightenedMasterExileEffect(this); + return new NarsetEnlightenedMasterExileEffect(this); } } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/PonybackBrigade.java b/Mage.Sets/src/mage/sets/khansoftarkir/PonybackBrigade.java index f6f03ca9d0d..fde44d673ef 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/PonybackBrigade.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/PonybackBrigade.java @@ -60,7 +60,7 @@ public class PonybackBrigade extends CardImpl { this.toughness = new MageInt(2); // When Ponyback Brigade enters the battlefield or is turned face up, put three 1/1 red Goblin creature tokens onto the battlefield. - this.addAbility(new PonybackBrigadeAbility(new GoblinToken(expansionSetCode))); + this.addAbility(new PonybackBrigadeAbility(new GoblinToken())); // Morph {2}{R}{W}{B} this.addAbility(new MorphAbility(this, new ManaCostsImpl("{2}{R}{W}{B}"))); @@ -102,7 +102,7 @@ class PonybackBrigadeAbility extends TriggeredAbilityImpl { if (event.getType() == EventType.TURNEDFACEUP && event.getTargetId().equals(this.getSourceId())) { return true; } - if (event.getType() == EventType.ENTERS_THE_BATTLEFIELD && event.getTargetId().equals(this.getSourceId()) ) { + if (event.getType() == EventType.ENTERS_THE_BATTLEFIELD && event.getTargetId().equals(this.getSourceId())) { Permanent sourcePermanent = game.getPermanent(getSourceId()); if (sourcePermanent != null && !sourcePermanent.isFaceDown(game)) { return true; diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/SidisiBroodTyrant.java b/Mage.Sets/src/mage/sets/khansoftarkir/SidisiBroodTyrant.java index 6eda6b2e4ea..be677f414d2 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/SidisiBroodTyrant.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/SidisiBroodTyrant.java @@ -112,7 +112,7 @@ class SidisiBroodTyrantAbility extends TriggeredAbilityImpl { class SidisiBroodTyrantTriggeredAbility extends TriggeredAbilityImpl { public SidisiBroodTyrantTriggeredAbility() { - super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken("KTK")), false); + super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken()), false); } public SidisiBroodTyrantTriggeredAbility(final SidisiBroodTyrantTriggeredAbility ability) { @@ -126,12 +126,12 @@ class SidisiBroodTyrantTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - ZoneChangeGroupEvent zEvent = (ZoneChangeGroupEvent)event; + ZoneChangeGroupEvent zEvent = (ZoneChangeGroupEvent) event; if (Zone.LIBRARY == zEvent.getFromZone() && Zone.GRAVEYARD == zEvent.getToZone()) { - for (Card card: zEvent.getCards()) { + for (Card card : zEvent.getCards()) { if (card.getOwnerId().equals(getControllerId()) && card.getCardType().contains(CardType.CREATURE)) { return true; - } + } } } return false; @@ -142,7 +142,6 @@ class SidisiBroodTyrantTriggeredAbility extends TriggeredAbilityImpl { return new SidisiBroodTyrantTriggeredAbility(this); } - @Override public String getRule() { return "Whenever one or more creature cards are put into your graveyard from your library, put a 2/2 black Zombie creature token onto the battlefield."; diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/SuspensionField.java b/Mage.Sets/src/mage/sets/khansoftarkir/SuspensionField.java index 419d131632d..087631b2a71 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/SuspensionField.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/SuspensionField.java @@ -53,15 +53,15 @@ import mage.util.CardUtil; public class SuspensionField extends CardImpl { private final static FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with toughness 3 or greater"); + static { filter.add(new ToughnessPredicate(ComparisonType.GreaterThan, 2)); - } - + } + public SuspensionField(UUID ownerId) { super(ownerId, 25, "Suspension Field", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); this.expansionSetCode = "KTK"; - // When Suspension Field enters the battlefield, you may exile target creature with toughness 3 or greater until Suspension Field leaves the battlefield. Ability ability = new EntersBattlefieldTriggeredAbility(new SuspensionFieldExileEffect(), true); ability.addTarget(new TargetCreaturePermanent(filter)); @@ -101,7 +101,7 @@ class SuspensionFieldExileEffect extends OneShotEffect { Permanent sourcePermanent = game.getPermanent(source.getSourceId()); // If Suspension Field leaves the battlefield before its triggered ability resolves, the target won't be exiled. if (sourcePermanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), sourcePermanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), sourcePermanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/TimelyHordemate.java b/Mage.Sets/src/mage/sets/khansoftarkir/TimelyHordemate.java index d6887609b9e..752f4feaa87 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/TimelyHordemate.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/TimelyHordemate.java @@ -65,8 +65,8 @@ public class TimelyHordemate extends CardImpl { this.toughness = new MageInt(2); // Raid - When Timely Hordemate enters the battlefield, if you attacked this turn, return target creature card with converted mana cost 2 or less from your graveyard to the battlefield. - Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new ReturnFromGraveyardToBattlefieldTargetEffect()), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, return target creature card with converted mana cost 2 or less from your graveyard to the battlefield.", false); + Ability ability = new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new ReturnFromGraveyardToBattlefieldTargetEffect()), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, return target creature card with converted mana cost 2 or less from your graveyard to the battlefield."); ability.addTarget(new TargetCardInYourGraveyard(filter)); this.addAbility(ability, new PlayerAttackedWatcher()); diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/VillainousWealth.java b/Mage.Sets/src/mage/sets/khansoftarkir/VillainousWealth.java index 05f841c7266..4780c7e18a2 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/VillainousWealth.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/VillainousWealth.java @@ -33,6 +33,8 @@ import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -41,7 +43,6 @@ import mage.filter.Filter; import mage.filter.FilterCard; import mage.filter.common.FilterNonlandCard; import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; -import mage.game.ExileZone; import mage.game.Game; import mage.players.Player; import mage.target.common.TargetCardInExile; @@ -58,7 +59,6 @@ public class VillainousWealth extends CardImpl { super(ownerId, 211, "Villainous Wealth", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{X}{B}{G}{U}"); this.expansionSetCode = "KTK"; - // Target opponent exiles the top X cards of his or her library. You may cast any number of nonland cards with converted mana cost X or less from among them without paying their mana cost. this.getSpellAbility().addTarget(new TargetOpponent()); this.getSpellAbility().addEffect(new VillainousWealthEffect()); @@ -101,30 +101,26 @@ class VillainousWealthEffect extends OneShotEffect { filter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, source.getManaCostsToPay().getX() + 1)); UUID exileId = CardUtil.getCardExileZoneId(game, source); if (player != null) { - - // putting cards to exile shouldn't end the game, so getting minimun available - int cardsCount = Math.min(source.getManaCostsToPay().getX(), player.getLibrary().size()); - for (int i = 0; i < cardsCount; i++) { - Card card = player.getLibrary().getFromTop(game); - if (card != null) { - controller.moveCardToExileWithInfo(card, exileId, mageObject.getIdName(), source.getSourceId(), game, Zone.LIBRARY, true); + Cards cardsToExile = new CardsImpl(); + cardsToExile.addAll(player.getLibrary().getTopCards(game, source.getManaCostsToPay().getX())); + controller.moveCards(cardsToExile, null, Zone.EXILED, source, game); + if (controller.chooseUse(Outcome.PlayForFree, "Cast cards exiled with " + mageObject.getLogName() + " without paying its mana cost?", source, game)) { + OuterLoop: + while (cardsToExile.count(filter, game) > 0) { + TargetCardInExile target = new TargetCardInExile(0, 1, filter, exileId, false); + while (cardsToExile.count(filter, game) > 0 && controller.choose(Outcome.PlayForFree, cardsToExile, target, game)) { + Card card = game.getCard(target.getFirstTarget()); + if (card != null) { + controller.cast(card.getSpellAbility(), game, true); + cardsToExile.remove(card); + } else { + break OuterLoop; + } + target.clearChosen(); + } } } } - ExileZone exileZone = game.getExile().getExileZone(exileId); - while (exileZone != null && exileZone.count(filter, game) > 0 - && controller.chooseUse(Outcome.PlayForFree, "Cast cards exiled with " + mageObject.getLogName() +" without paying its mana cost?", source, game)) { - TargetCardInExile target = new TargetCardInExile(0,1, filter, exileId, false); - while (exileZone.count(filter, game) > 0 && controller.choose(Outcome.PlayForFree, exileZone, target, game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.cast(card.getSpellAbility(), game, true); - } else { - break; - } - target.clearChosen(); - } - } return true; } diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/WarNameAspirant.java b/Mage.Sets/src/mage/sets/khansoftarkir/WarNameAspirant.java index de69d67f53d..d319410e590 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/WarNameAspirant.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/WarNameAspirant.java @@ -30,7 +30,7 @@ package mage.sets.khansoftarkir; import java.util.UUID; import mage.MageInt; import mage.abilities.common.EntersBattlefieldAbility; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.condition.common.RaidCondition; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; @@ -38,7 +38,6 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.Filter; import mage.filter.common.FilterCreaturePermanent; @@ -50,8 +49,9 @@ import mage.watchers.common.PlayerAttackedWatcher; * @author emerald000 */ public class WarNameAspirant extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures with power 1 or less"); + static { filter.add(new PowerPredicate(Filter.ComparisonType.LessThan, 2)); } @@ -66,15 +66,15 @@ public class WarNameAspirant extends CardImpl { this.toughness = new MageInt(1); // Raid - War-Name Aspirant enters the battlefield with a +1/+1 counter on it if you attacked with a creature this turn. - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1), false), - RaidCondition.getInstance(), - true, - "Raid - {this} enters the battlefield with a +1/+1 counter on it if you attacked with a creature this turn", - "{this} enters the battlefield with a +1/+1 counter"), + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(1), false), + RaidCondition.getInstance(), + true, + "Raid - {this} enters the battlefield with a +1/+1 counter on it if you attacked with a creature this turn", + "{this} enters the battlefield with a +1/+1 counter"), new PlayerAttackedWatcher()); // War-Name Aspirant can't be blocked by creatures with power 1 or less. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public WarNameAspirant(final WarNameAspirant card) { diff --git a/Mage.Sets/src/mage/sets/khansoftarkir/WingmateRoc.java b/Mage.Sets/src/mage/sets/khansoftarkir/WingmateRoc.java index 4d8acfaf0de..900b263134d 100644 --- a/Mage.Sets/src/mage/sets/khansoftarkir/WingmateRoc.java +++ b/Mage.Sets/src/mage/sets/khansoftarkir/WingmateRoc.java @@ -60,10 +60,10 @@ public class WingmateRoc extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); - + // Raid - When Wingmate Roc enters the battlefield, if you attacked with a creature this turn, put a 3/4 white Bird creature token with flying onto the battlefield. - this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new WingmateRocToken())), RaidCondition.getInstance(), - "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, put a 3/4 white Bird creature token with flying onto the battlefield.", false), + this.addAbility(new ConditionalTriggeredAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new WingmateRocToken())), RaidCondition.getInstance(), + "Raid - When {this} enters the battlefield, if you attacked with a creature this turn, put a 3/4 white Bird creature token with flying onto the battlefield."), new PlayerAttackedWatcher()); // Whenever Wingmate Roc attacks, you gain 1 life for each attacking creature. diff --git a/Mage.Sets/src/mage/sets/legends/HellsCaretaker.java b/Mage.Sets/src/mage/sets/legends/HellsCaretaker.java new file mode 100644 index 00000000000..1c12ff1dc20 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/HellsCaretaker.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class HellsCaretaker extends mage.sets.ninthedition.HellsCaretaker { + + public HellsCaretaker(UUID ownerId) { + super(ownerId); + this.cardNumber = 19; + this.expansionSetCode = "LEG"; + } + + public HellsCaretaker(final HellsCaretaker card) { + super(card); + } + + @Override + public HellsCaretaker copy() { + return new HellsCaretaker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/HorrorOfHorrors.java b/Mage.Sets/src/mage/sets/legends/HorrorOfHorrors.java new file mode 100644 index 00000000000..99db10a8060 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/HorrorOfHorrors.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.RegenerateTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class HorrorOfHorrors extends CardImpl { + + private static final FilterControlledPermanent filter1 = new FilterControlledPermanent("a Swamp"); + private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent("black creature"); + + static { + filter1.add(new SubtypePredicate("Swamp")); + filter2.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public HorrorOfHorrors(UUID ownerId) { + super(ownerId, 20, "Horror of Horrors", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{B}{B}"); + this.expansionSetCode = "LEG"; + + // Sacrifice a Swamp: Regenerate target black creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), + new SacrificeTargetCost(new TargetControlledPermanent(filter1))); + ability.addTarget(new TargetCreaturePermanent(filter2)); + this.addAbility(ability); + } + + public HorrorOfHorrors(final HorrorOfHorrors card) { + super(card); + } + + @Override + public HorrorOfHorrors copy() { + return new HorrorOfHorrors(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/KeiTakahashi.java b/Mage.Sets/src/mage/sets/legends/KeiTakahashi.java new file mode 100644 index 00000000000..ebc26302d2c --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/KeiTakahashi.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class KeiTakahashi extends mage.sets.masterseditioniii.KeiTakahashi { + + public KeiTakahashi(UUID ownerId) { + super(ownerId); + this.cardNumber = 278; + this.expansionSetCode = "LEG"; + this.rarity = Rarity.RARE; + } + + public KeiTakahashi(final KeiTakahashi card) { + super(card); + } + + @Override + public KeiTakahashi copy() { + return new KeiTakahashi(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/LandTax.java b/Mage.Sets/src/mage/sets/legends/LandTax.java index e88e6284dc2..ffd80349b0c 100644 --- a/Mage.Sets/src/mage/sets/legends/LandTax.java +++ b/Mage.Sets/src/mage/sets/legends/LandTax.java @@ -52,12 +52,11 @@ public class LandTax extends CardImpl { // At the beginning of your upkeep, if an opponent controls more lands than you, you may search your library for up to three basic land cards, reveal them, and put them into your hand. If you do, shuffle your library. this.addAbility(new ConditionalTriggeredAbility( - new BeginningOfUpkeepTriggeredAbility(new SearchLibraryPutInHandEffect(new TargetCardInLibrary(0, 3, new FilterBasicLandCard()), true),TargetController.YOU, true), + new BeginningOfUpkeepTriggeredAbility(new SearchLibraryPutInHandEffect(new TargetCardInLibrary(0, 3, new FilterBasicLandCard()), true), TargetController.YOU, true), new OpponentControllsMoreCondition(new FilterLandPermanent("lands")), - "At the beginning of your upkeep, if an opponent controls more lands than you, you may search your library for up to three basic land cards, reveal them, and put them into your hand. If you do, shuffle your library", - true + "At the beginning of your upkeep, if an opponent controls more lands than you, you may search your library for up to three basic land cards, reveal them, and put them into your hand. If you do, shuffle your library" )); - + } public LandTax(final LandTax card) { diff --git a/Mage.Sets/src/mage/sets/legends/LivingPlane.java b/Mage.Sets/src/mage/sets/legends/LivingPlane.java new file mode 100644 index 00000000000..d495e69b3bc --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/LivingPlane.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BecomesCreatureAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.permanent.token.Token; + +/** + * + * @author fireshoes + */ +public class LivingPlane extends CardImpl { + + public LivingPlane(UUID ownerId) { + super(ownerId, 107, "Living Plane", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}{G}"); + this.expansionSetCode = "LEG"; + this.supertype.add("World"); + + // All lands are 1/1 creatures that are still lands. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BecomesCreatureAllEffect(new LivingPlaneToken(), "lands", new FilterLandPermanent("lands"), Duration.WhileOnBattlefield))); + } + + public LivingPlane(final LivingPlane card) { + super(card); + } + + @Override + public LivingPlane copy() { + return new LivingPlane(this); + } +} + +class LivingPlaneToken extends Token { + public LivingPlaneToken() { + super("Land", "1/1 creature"); + cardType.add(CardType.CREATURE); + power = new MageInt(1); + toughness = new MageInt(1); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/legends/MoldDemon.java b/Mage.Sets/src/mage/sets/legends/MoldDemon.java new file mode 100644 index 00000000000..4ba53333fad --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/MoldDemon.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class MoldDemon extends CardImpl { + + private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("two Swamps"); + + static{ + filter.add(new SubtypePredicate("Swamp")); + } + + public MoldDemon(UUID ownerId) { + super(ownerId, 26, "Mold Demon", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{B}{B}"); + this.expansionSetCode = "LEG"; + this.subtype.add("Fungus"); + this.subtype.add("Demon"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // When Mold Demon enters the battlefield, sacrifice it unless you sacrifice two Swamps. + this.addAbility(new EntersBattlefieldTriggeredAbility( + new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, filter, true))))); + } + + public MoldDemon(final MoldDemon card) { + super(card); + } + + @Override + public MoldDemon copy() { + return new MoldDemon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/NicolBolas.java b/Mage.Sets/src/mage/sets/legends/NicolBolas.java index 55a7c2b4ab2..8bf534631e0 100644 --- a/Mage.Sets/src/mage/sets/legends/NicolBolas.java +++ b/Mage.Sets/src/mage/sets/legends/NicolBolas.java @@ -30,8 +30,8 @@ package mage.sets.legends; import java.util.UUID; import mage.MageInt; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; import mage.abilities.effects.common.discard.DiscardHandTargetEffect; import mage.abilities.keyword.FlyingAbility; @@ -60,7 +60,7 @@ public class NicolBolas extends CardImpl { this.addAbility(FlyingAbility.getInstance()); // At the beginning of your upkeep, sacrifice Nicol Bolas unless you pay {U}{B}{R}. this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new ManaCostsImpl("{U}{B}{R}")), TargetController.YOU, false)); - + // Whenever Nicol Bolas deals damage to an opponent, that player discards his or her hand. this.addAbility(new DealsDamageToOpponentTriggeredAbility(new DiscardHandTargetEffect("that player"), false)); } diff --git a/Mage.Sets/src/mage/sets/legends/PresenceOfTheMaster.java b/Mage.Sets/src/mage/sets/legends/PresenceOfTheMaster.java new file mode 100644 index 00000000000..d09c89d9de4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/PresenceOfTheMaster.java @@ -0,0 +1,130 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.stack.Spell; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author fireshoes + */ +public class PresenceOfTheMaster extends CardImpl { + + public PresenceOfTheMaster(UUID ownerId) { + super(ownerId, 200, "Presence of the Master", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}"); + this.expansionSetCode = "LEG"; + + // Whenever a player casts an enchantment spell, counter it. + this.addAbility(new PresenceOfTheMasterTriggeredAbility()); + } + + public PresenceOfTheMaster(final PresenceOfTheMaster card) { + super(card); + } + + @Override + public PresenceOfTheMaster copy() { + return new PresenceOfTheMaster(this); + } +} + +class PresenceOfTheMasterTriggeredAbility extends TriggeredAbilityImpl { + + + public PresenceOfTheMasterTriggeredAbility() { + super(Zone.BATTLEFIELD, new CounterEffect()); + } + + + public PresenceOfTheMasterTriggeredAbility(final PresenceOfTheMasterTriggeredAbility abiltity) { + super(abiltity); + } + + @java.lang.Override + public PresenceOfTheMasterTriggeredAbility copy() { + return new PresenceOfTheMasterTriggeredAbility(this); + } + + @java.lang.Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.SPELL_CAST; + } + + @java.lang.Override + public boolean checkTrigger(GameEvent event, Game game) { + Spell spell = game.getStack().getSpell(event.getTargetId()); + if (spell != null && (spell.getCardType().contains(CardType.ENCHANTMENT))){ + for (Effect effect : this.getEffects()) { + effect.setTargetPointer(new FixedTarget(event.getTargetId())); + } + return true; + } + return false; + } + + @java.lang.Override + public String getRule() { + return "Whenever a player casts an enchantment spell, counter it"; + } +} + + +class CounterEffect extends OneShotEffect { + + public CounterEffect() { + super(Outcome.Detriment); + } + + public CounterEffect(final CounterEffect effect) { + super(effect); + } + + @java.lang.Override + public CounterEffect copy() { + return new CounterEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + return game.getStack().counter(this.getTargetPointer().getFirst(game, source), source.getSourceId(), game); + } + +} diff --git a/Mage.Sets/src/mage/sets/legends/Revelation.java b/Mage.Sets/src/mage/sets/legends/Revelation.java new file mode 100644 index 00000000000..bf24c939253 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/Revelation.java @@ -0,0 +1,62 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.PlayWithHandRevealedEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class Revelation extends CardImpl { + + public Revelation(UUID ownerId) { + super(ownerId, 116, "Revelation", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{G}"); + this.expansionSetCode = "LEG"; + this.supertype.add("World"); + + // Players play with their hands revealed. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithHandRevealedEffect(TargetController.ANY))); + } + + public Revelation(final Revelation card) { + super(card); + } + + @Override + public Revelation copy() { + return new Revelation(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/TheAbyss.java b/Mage.Sets/src/mage/sets/legends/TheAbyss.java index 3664e65ad01..6124421c61b 100644 --- a/Mage.Sets/src/mage/sets/legends/TheAbyss.java +++ b/Mage.Sets/src/mage/sets/legends/TheAbyss.java @@ -29,11 +29,9 @@ package mage.sets.legends; import java.util.UUID; import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.Effect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; @@ -45,7 +43,6 @@ import mage.game.events.GameEvent; import mage.players.Player; import mage.target.Target; import mage.target.common.TargetCreaturePermanent; -import mage.target.targetpointer.FixedTarget; /** * @@ -73,15 +70,15 @@ public class TheAbyss extends CardImpl { } class TheAbyssTriggeredAbility extends TriggeredAbilityImpl { - + TheAbyssTriggeredAbility() { super(Zone.BATTLEFIELD, new DestroyTargetEffect(true), false); } - + TheAbyssTriggeredAbility(final TheAbyssTriggeredAbility ability) { super(ability); } - + @Override public TheAbyssTriggeredAbility copy() { return new TheAbyssTriggeredAbility(this); @@ -91,7 +88,7 @@ class TheAbyssTriggeredAbility extends TriggeredAbilityImpl { public boolean checkEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.UPKEEP_STEP_PRE; } - + @Override public boolean checkTrigger(GameEvent event, Game game) { Player player = game.getPlayer(event.getPlayerId()); @@ -100,18 +97,15 @@ class TheAbyssTriggeredAbility extends TriggeredAbilityImpl { filter.add(Predicates.not(new CardTypePredicate(CardType.ARTIFACT))); filter.add(new ControllerIdPredicate(player.getId())); Target target = new TargetCreaturePermanent(filter); - if (target.canChoose(this.getSourceId(), this.getControllerId(), game) && player.chooseTarget(Outcome.DestroyPermanent, target, this, game)) { - for (Effect effect: this.getEffects()) { - if (effect instanceof DestroyTargetEffect) { - effect.setTargetPointer(new FixedTarget(target.getFirstTarget())); - } - } - return true; - } + target.setAbilityController(getControllerId()); + target.setTargetController(player.getId()); + this.getTargets().clear(); + this.getTargets().add(target); + return true; } return false; } - + @Override public String getRule() { return "At the beginning of each player's upkeep, destroy target nonartifact creature that player controls of his or her choice. It can't be regenerated."; diff --git a/Mage.Sets/src/mage/sets/legends/Transmutation.java b/Mage.Sets/src/mage/sets/legends/Transmutation.java new file mode 100644 index 00000000000..cd32941e71d --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/Transmutation.java @@ -0,0 +1,61 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.abilities.effects.common.continuous.SwitchPowerToughnessTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Transmutation extends CardImpl { + + public Transmutation(UUID ownerId) { + super(ownerId, 37, "Transmutation", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "LEG"; + + // Switch target creature's power and toughness until end of turn. + this.getSpellAbility().addEffect(new SwitchPowerToughnessTargetEffect(Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public Transmutation(final Transmutation card) { + super(card); + } + + @Override + public Transmutation copy() { + return new Transmutation(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legends/TriassicEgg.java b/Mage.Sets/src/mage/sets/legends/TriassicEgg.java new file mode 100644 index 00000000000..f7c9714cc40 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legends/TriassicEgg.java @@ -0,0 +1,93 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legends; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.condition.common.SourceHasCounterCondition; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; +import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterCreatureCard; +import mage.target.Target; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class TriassicEgg extends CardImpl { + + public TriassicEgg(UUID ownerId) { + super(ownerId, 242, "Triassic Egg", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}"); + this.expansionSetCode = "LEG"; + + // {3}, {tap}: Put a hatchling counter on Triassic Egg. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new AddCountersSourceEffect(CounterType.HATCHLING.createInstance(), true), + new GenericManaCost(3)); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + + // Sacrifice Triassic Egg: Choose one - You may put a creature card from your hand onto the battlefield; + ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new PutPermanentOnBattlefieldEffect(new FilterCreatureCard("a creature card")), + new SacrificeSourceCost(), + new SourceHasCounterCondition(CounterType.HATCHLING, 2, Integer.MAX_VALUE), + "Sacrifice Triassic Egg: Choose one - You may put a creature card from your hand onto the battlefield; or return target creature card from your graveyard to the battlefield. Activate this ability only if two or more hatchling counters are on {this}."); + + // or return target creature card from your graveyard to the battlefield. Activate this ability only if two or more hatchling counters are on Triassic Egg. + Mode mode = new Mode(); + mode.getEffects().add(new ReturnFromGraveyardToBattlefieldTargetEffect()); + Target target = new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard")); + mode.getTargets().add(target); + ability.addMode(mode); + + this.addAbility(ability); + } + + public TriassicEgg(final TriassicEgg card) { + super(card); + } + + @Override + public TriassicEgg copy() { + return new TriassicEgg(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/legions/AvenRedeemer.java b/Mage.Sets/src/mage/sets/legions/AvenRedeemer.java new file mode 100644 index 00000000000..e8cfc75f388 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/AvenRedeemer.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class AvenRedeemer extends CardImpl { + + public AvenRedeemer(UUID ownerId) { + super(ownerId, 3, "Aven Redeemer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Bird"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {tap}: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public AvenRedeemer(final AvenRedeemer card) { + super(card); + } + + @Override + public AvenRedeemer copy() { + return new AvenRedeemer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legions/BaneOfTheLiving.java b/Mage.Sets/src/mage/sets/legions/BaneOfTheLiving.java new file mode 100644 index 00000000000..d78865f6a06 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/BaneOfTheLiving.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.TurnedFaceUpSourceTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.common.MorphManacostVariableValue; +import mage.abilities.dynamicvalue.common.SignInversionDynamicValue; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author LevelX2 + */ +public class BaneOfTheLiving extends CardImpl { + + public BaneOfTheLiving(UUID ownerId) { + super(ownerId, 60, "Bane of the Living", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}{B}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Insect"); + this.power = new MageInt(4); + this.toughness = new MageInt(3); + + // Morph {X}{B}{B} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{X}{B}{B}"))); + // When Bane of the Living is turned face up, all creatures get -X/-X until end of turn. + DynamicValue morphX = new SignInversionDynamicValue(new MorphManacostVariableValue()); + this.addAbility(new TurnedFaceUpSourceTriggeredAbility(new BoostAllEffect(morphX, morphX, Duration.EndOfTurn, new FilterCreaturePermanent(), false, "", true))); + } + + public BaneOfTheLiving(final BaneOfTheLiving card) { + super(card); + } + + @Override + public BaneOfTheLiving copy() { + return new BaneOfTheLiving(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legions/CrestedCraghorn.java b/Mage.Sets/src/mage/sets/legions/CrestedCraghorn.java new file mode 100644 index 00000000000..aed2e22cc9d --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/CrestedCraghorn.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.HasteAbility; +import mage.abilities.keyword.ProvokeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class CrestedCraghorn extends CardImpl { + + public CrestedCraghorn(UUID ownerId) { + super(ownerId, 91, "Crested Craghorn", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{R}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Goat"); + this.subtype.add("Beast"); + this.power = new MageInt(4); + this.toughness = new MageInt(1); + + // Haste + this.addAbility(HasteAbility.getInstance()); + // Provoke + this.addAbility(new ProvokeAbility()); + } + + public CrestedCraghorn(final CrestedCraghorn card) { + super(card); + } + + @Override + public CrestedCraghorn copy() { + return new CrestedCraghorn(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legions/Glowrider.java b/Mage.Sets/src/mage/sets/legions/Glowrider.java new file mode 100644 index 00000000000..15dbdef8c44 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/Glowrider.java @@ -0,0 +1,109 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.cost.CostModificationEffectImpl; +import mage.abilities.keyword.FlashbackAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.CostModificationType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.util.CardUtil; + +/** + * + * @author fireshoes + */ +public class Glowrider extends CardImpl { + + public Glowrider(UUID ownerId) { + super(ownerId, 15, "Glowrider", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Noncreature spells cost {1} more to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GlowriderCostReductionEffect())); + } + + public Glowrider(final Glowrider card) { + super(card); + } + + @Override + public Glowrider copy() { + return new Glowrider(this); + } +} + +class GlowriderCostReductionEffect extends CostModificationEffectImpl { + + GlowriderCostReductionEffect ( ) { + super(Duration.WhileOnBattlefield, Outcome.Benefit, CostModificationType.INCREASE_COST); + staticText = "Noncreature spells cost {1} more to cast"; + } + + GlowriderCostReductionEffect(GlowriderCostReductionEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source, Ability abilityToModify) { + CardUtil.increaseCost(abilityToModify, 1); + return true; + } + + @Override + public boolean applies(Ability abilityToModify, Ability source, Game game) { + if (abilityToModify instanceof SpellAbility || abilityToModify instanceof FlashbackAbility) { + Card card = game.getCard(abilityToModify.getSourceId()); + if (card != null && !card.getCardType().contains(CardType.CREATURE)) { + return true; + } + } + return false; + } + + @Override + public GlowriderCostReductionEffect copy() { + return new GlowriderCostReductionEffect(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/legions/GoblinFirebug.java b/Mage.Sets/src/mage/sets/legions/GoblinFirebug.java new file mode 100644 index 00000000000..67a12a03a7c --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/GoblinFirebug.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.common.SacrificeControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class GoblinFirebug extends CardImpl { + + public GoblinFirebug(UUID ownerId) { + super(ownerId, 98, "Goblin Firebug", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Goblin"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // When Goblin Firebug leaves the battlefield, sacrifice a land. + this.addAbility(new LeavesBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterLandPermanent(), 1, ""), false)); + } + + public GoblinFirebug(final GoblinFirebug card) { + super(card); + } + + @Override + public GoblinFirebug copy() { + return new GoblinFirebug(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legions/GoblinGrappler.java b/Mage.Sets/src/mage/sets/legions/GoblinGrappler.java new file mode 100644 index 00000000000..445dffe7832 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/GoblinGrappler.java @@ -0,0 +1,62 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.ProvokeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class GoblinGrappler extends CardImpl { + + public GoblinGrappler(UUID ownerId) { + super(ownerId, 100, "Goblin Grappler", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Goblin"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Provoke + this.addAbility(new ProvokeAbility()); + } + + public GoblinGrappler(final GoblinGrappler card) { + super(card); + } + + @Override + public GoblinGrappler copy() { + return new GoblinGrappler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/legions/MistformSliver.java b/Mage.Sets/src/mage/sets/legions/MistformSliver.java index 495458f4e11..d401e139c89 100644 --- a/Mage.Sets/src/mage/sets/legions/MistformSliver.java +++ b/Mage.Sets/src/mage/sets/legions/MistformSliver.java @@ -103,7 +103,7 @@ public class MistformSliver extends CardImpl { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.Detriment, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/legions/RiptideDirector.java b/Mage.Sets/src/mage/sets/legions/RiptideDirector.java new file mode 100644 index 00000000000..436c04b4260 --- /dev/null +++ b/Mage.Sets/src/mage/sets/legions/RiptideDirector.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.legions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class RiptideDirector extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledCreaturePermanent("Wizard you control"); + + static { + filter.add(new SubtypePredicate("Wizard")); + } + + public RiptideDirector(UUID ownerId) { + super(ownerId, 50, "Riptide Director", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{U}{U}"); + this.expansionSetCode = "LGN"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // {2}{U}{U}, {tap}: Draw a card for each Wizard you control. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new DrawCardSourceControllerEffect(new PermanentsOnBattlefieldCount(filter)), + new ManaCostsImpl("{2}{U}{U}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + } + + public RiptideDirector(final RiptideDirector card) { + super(card); + } + + @Override + public RiptideDirector copy() { + return new RiptideDirector(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedalpha/Channel.java b/Mage.Sets/src/mage/sets/limitedalpha/Channel.java new file mode 100644 index 00000000000..a69890bb8e7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedalpha/Channel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedalpha; + +import java.util.UUID; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 97; + this.expansionSetCode = "LEA"; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedalpha/Deathgrip.java b/Mage.Sets/src/mage/sets/limitedalpha/Deathgrip.java new file mode 100644 index 00000000000..021a7712be6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedalpha/Deathgrip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedalpha; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "LEA"; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedalpha/IslandSanctuary.java b/Mage.Sets/src/mage/sets/limitedalpha/IslandSanctuary.java new file mode 100644 index 00000000000..e6c8441f235 --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedalpha/IslandSanctuary.java @@ -0,0 +1,123 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedalpha; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.combat.CantAttackYouAllEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.IslandwalkAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.AbilityPredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.players.Player; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends CardImpl { + + public IslandSanctuary(UUID ownerId) { + super(ownerId, 209, "Island Sanctuary", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + this.expansionSetCode = "LEA"; + + // If you would draw a card during your draw step, instead you may skip that draw. If you do, until your next turn, you can't be attacked except by creatures with flying and/or islandwalk. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new IslandSanctuaryEffect())); + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} + +class IslandSanctuaryEffect extends ReplacementEffectImpl { + + private final static FilterCreaturePermanent notFlyingorIslandwalkCreatures = new FilterCreaturePermanent("except by creatures with flying and/or islandwalk"); + + static { + notFlyingorIslandwalkCreatures.add(Predicates.not(new AbilityPredicate(FlyingAbility.class))); + notFlyingorIslandwalkCreatures.add(Predicates.not(new AbilityPredicate(IslandwalkAbility.class))); + } + + IslandSanctuaryEffect() { + super(Duration.WhileOnBattlefield, Outcome.Benefit); + staticText = "If you would draw a card during your draw step, instead you may skip that draw. If you do, until your next turn, you can't be attacked except by creatures with flying and/or islandwalk"; + } + + IslandSanctuaryEffect(final IslandSanctuaryEffect effect) { + super(effect); + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + Player controller = game.getPlayer(event.getPlayerId()); + if (controller != null && controller.chooseUse(outcome, "Skip draw card? (If you do, until your next turn, you can't be attacked except by creatures with flying and/or islandwalk)", source, game)) { + game.informPlayers(controller.getLogName() + " skips his or her draw card action. Until his or her next turn, he or she can't be attacked except by creatures with flying and/or islandwalk"); + game.addEffect(new CantAttackYouAllEffect(Duration.UntilYourNextTurn, notFlyingorIslandwalkCreatures), source); + return true; + } + return false; + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.DRAW_CARD; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + return source.getControllerId().equals(event.getPlayerId()) && game.getTurn().getStepType().equals(PhaseStep.DRAW); + } + + @Override + public boolean apply(Game game, Ability source) { + return false; + } + + @Override + public IslandSanctuaryEffect copy() { + return new IslandSanctuaryEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedalpha/ManaVault.java b/Mage.Sets/src/mage/sets/limitedalpha/ManaVault.java index c363dc2eeea..be0e1a38f9f 100644 --- a/Mage.Sets/src/mage/sets/limitedalpha/ManaVault.java +++ b/Mage.Sets/src/mage/sets/limitedalpha/ManaVault.java @@ -62,14 +62,14 @@ public class ManaVault extends CardImpl { // At the beginning of your upkeep, you may pay {4}. If you do, untap Mana Vault. this.addAbility(new BeginningOfUpkeepTriggeredAbility( Zone.BATTLEFIELD, - new DoIfCostPaid(new UntapSourceEffect(), new GenericManaCost(4),"Pay {4} to untap {this}?"), + new DoIfCostPaid(new UntapSourceEffect(), new GenericManaCost(4), "Pay {4} to untap {this}?"), TargetController.YOU, false)); // At the beginning of your draw step, if Mana Vault is tapped, it deals 1 damage to you. this.addAbility(new ConditionalTriggeredAbility( new BeginningOfDrawTriggeredAbility(Zone.BATTLEFIELD, new DamageControllerEffect(1), TargetController.YOU, false), SourceTappedCondition.getInstance(), - "At the beginning of your draw step, if {this} is tapped, it deals 1 damage to you.", false)); + "At the beginning of your draw step, if {this} is tapped, it deals 1 damage to you.")); // {tap}: Add {3} to your mana pool. this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, Mana.ColorlessMana(3), new TapSourceCost())); } diff --git a/Mage.Sets/src/mage/sets/limitedalpha/NaturalSelection.java b/Mage.Sets/src/mage/sets/limitedalpha/NaturalSelection.java index 38657372332..0a160360c1e 100644 --- a/Mage.Sets/src/mage/sets/limitedalpha/NaturalSelection.java +++ b/Mage.Sets/src/mage/sets/limitedalpha/NaturalSelection.java @@ -108,7 +108,7 @@ class NaturalSelectionEffect extends OneShotEffect { you.lookAtCards("Natural Selection", cards, game); TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the top of target player's library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { you.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/limitedalpha/PirateShip.java b/Mage.Sets/src/mage/sets/limitedalpha/PirateShip.java index f350c41d9b9..e74e2995916 100644 --- a/Mage.Sets/src/mage/sets/limitedalpha/PirateShip.java +++ b/Mage.Sets/src/mage/sets/limitedalpha/PirateShip.java @@ -30,7 +30,7 @@ package mage.sets.limitedalpha; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.TapSourceCost; @@ -38,17 +38,17 @@ import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; import mage.cards.CardImpl; -import mage.constants.*; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; import mage.filter.common.FilterLandPermanent; -import mage.filter.predicate.permanent.ControllerControlsIslandPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; import mage.target.common.TargetCreatureOrPlayer; /** * * @author KholdFuzion - + * */ public class PirateShip extends CardImpl { @@ -62,13 +62,15 @@ public class PirateShip extends CardImpl { this.toughness = new MageInt(3); // Pirate Ship can't attack unless defending player controls an Island. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); // {tap}: Pirate Ship deals 1 damage to target creature or player. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new TapSourceCost()); ability.addTarget(new TargetCreatureOrPlayer()); this.addAbility(ability); // When you control no Islands, sacrifice Pirate Ship. - this.addAbility(new PirateShipTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); } public PirateShip(final PirateShip card) { @@ -80,29 +82,3 @@ public class PirateShip extends CardImpl { return new PirateShip(this); } } - -class PirateShipTriggeredAbility extends StateTriggeredAbility { - - public PirateShipTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - public PirateShipTriggeredAbility(final PirateShipTriggeredAbility ability) { - super(ability); - } - - @Override - public PirateShipTriggeredAbility copy() { - return new PirateShipTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return (game.getBattlefield().countAll(ControllerControlsIslandPredicate.filter, controllerId, game) == 0); - } - - @Override - public String getRule() { - return "When you control no islands, sacrifice {this}."; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/limitedalpha/SeaSerpent.java b/Mage.Sets/src/mage/sets/limitedalpha/SeaSerpent.java index 9ef628a1817..2a34b6d3ffd 100644 --- a/Mage.Sets/src/mage/sets/limitedalpha/SeaSerpent.java +++ b/Mage.Sets/src/mage/sets/limitedalpha/SeaSerpent.java @@ -29,7 +29,7 @@ package mage.sets.limitedalpha; import java.util.UUID; import mage.MageInt; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; @@ -37,16 +37,14 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; +import mage.filter.Filter; import mage.filter.common.FilterLandPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.filter.predicate.permanent.ControllerControlsIslandPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; /** * * @author KholdFuzion - + * */ public class SeaSerpent extends CardImpl { @@ -67,7 +65,9 @@ public class SeaSerpent extends CardImpl { // Sea Serpent can't attack unless defending player controls an Island. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(filter))); // When you control no Islands, sacrifice Sea Serpent. - this.addAbility(new SeaSerpentTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); } public SeaSerpent(final SeaSerpent card) { @@ -79,29 +79,3 @@ public class SeaSerpent extends CardImpl { return new SeaSerpent(this); } } - -class SeaSerpentTriggeredAbility extends StateTriggeredAbility { - - public SeaSerpentTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - public SeaSerpentTriggeredAbility(final SeaSerpentTriggeredAbility ability) { - super(ability); - } - - @Override - public SeaSerpentTriggeredAbility copy() { - return new SeaSerpentTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return (game.getBattlefield().countAll(ControllerControlsIslandPredicate.filter, controllerId, game) == 0); - } - - @Override - public String getRule() { - return "When you control no islands, sacrifice {this}."; - } -} diff --git a/Mage.Sets/src/mage/sets/limitedbeta/Channel.java b/Mage.Sets/src/mage/sets/limitedbeta/Channel.java new file mode 100644 index 00000000000..b461cfea6fe --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedbeta/Channel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedbeta; + +import java.util.UUID; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 97; + this.expansionSetCode = "LEB"; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedbeta/Deathgrip.java b/Mage.Sets/src/mage/sets/limitedbeta/Deathgrip.java new file mode 100644 index 00000000000..7d7bb2a9ce3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedbeta/Deathgrip.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedbeta; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterSpell; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.TargetSpell; + +/** + * + * @author markedagain + */ +public class Deathgrip extends CardImpl { + private static final FilterSpell filter = new FilterSpell("green spell"); + static{ + filter.add(new ColorPredicate(ObjectColor.GREEN)); + } + + public Deathgrip(UUID ownerId) { + super(ownerId, 9, "Deathgrip", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{B}{B}"); + this.expansionSetCode = "LEB"; + + // {B}{B}: Counter target green spell. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetSpell(filter)); + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/limitedbeta/IslandSanctuary.java b/Mage.Sets/src/mage/sets/limitedbeta/IslandSanctuary.java new file mode 100644 index 00000000000..3e66149dbb5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/limitedbeta/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.limitedbeta; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 211; + this.expansionSetCode = "LEB"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/ChangelingBerserker.java b/Mage.Sets/src/mage/sets/lorwyn/ChangelingBerserker.java new file mode 100644 index 00000000000..524432df7b4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/ChangelingBerserker.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.ChampionAbility; +import mage.abilities.keyword.ChangelingAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ChangelingBerserker extends CardImpl { + + public ChangelingBerserker(UUID ownerId) { + super(ownerId, 160, "Changeling Berserker", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Shapeshifter"); + this.power = new MageInt(5); + this.toughness = new MageInt(3); + + // Changeling + this.addAbility(ChangelingAbility.getInstance()); + + // Haste + this.addAbility(HasteAbility.getInstance()); + + // Champion a creature + this.addAbility(new ChampionAbility(this, "")); + } + + public ChangelingBerserker(final ChangelingBerserker card) { + super(card); + } + + @Override + public ChangelingBerserker copy() { + return new ChangelingBerserker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/ChangelingTitan.java b/Mage.Sets/src/mage/sets/lorwyn/ChangelingTitan.java new file mode 100644 index 00000000000..99915222520 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/ChangelingTitan.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.ChampionAbility; +import mage.abilities.keyword.ChangelingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ChangelingTitan extends CardImpl { + + public ChangelingTitan(UUID ownerId) { + super(ownerId, 200, "Changeling Titan", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{G}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Shapeshifter"); + this.power = new MageInt(7); + this.toughness = new MageInt(7); + + // Changeling + this.addAbility(ChangelingAbility.getInstance()); + + // Champion a creature + this.addAbility(new ChampionAbility(this, "")); + } + + public ChangelingTitan(final ChangelingTitan card) { + super(card); + } + + @Override + public ChangelingTitan copy() { + return new ChangelingTitan(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/EtherealWhiskergill.java b/Mage.Sets/src/mage/sets/lorwyn/EtherealWhiskergill.java new file mode 100644 index 00000000000..9bea327e587 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/EtherealWhiskergill.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class EtherealWhiskergill extends CardImpl { + + public EtherealWhiskergill(UUID ownerId) { + super(ownerId, 60, "Ethereal Whiskergill", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Elemental"); + this.power = new MageInt(4); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Ethereal Whiskergill can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public EtherealWhiskergill(final EtherealWhiskergill card) { + super(card); + } + + @Override + public EtherealWhiskergill copy() { + return new EtherealWhiskergill(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/EyesOfTheWisent.java b/Mage.Sets/src/mage/sets/lorwyn/EyesOfTheWisent.java index 3ccd3418d76..643ea3ea7b2 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/EyesOfTheWisent.java +++ b/Mage.Sets/src/mage/sets/lorwyn/EyesOfTheWisent.java @@ -58,13 +58,12 @@ public class EyesOfTheWisent extends CardImpl { this.expansionSetCode = "LRW"; this.subtype.add("Elemental"); - // Whenever an opponent casts a blue spell during your turn, you may put a 4/4 green Elemental creature token onto the battlefield. this.addAbility(new ConditionalTriggeredAbility( new SpellCastOpponentTriggeredAbility(new CreateTokenEffect(new EyesOfTheWisentElementalToken()), filter, true), new MyTurnCondition(), - "Whenever an opponent casts a blue spell during your turn, you may put a 4/4 green Elemental creature token onto the battlefield.", - true)); + "Whenever an opponent casts a blue spell during your turn, you may put a 4/4 green Elemental creature token onto the battlefield." + )); } public EyesOfTheWisent(final EyesOfTheWisent card) { @@ -89,4 +88,4 @@ class EyesOfTheWisentElementalToken extends Token { toughness = new MageInt(4); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/FootbottomFeast.java b/Mage.Sets/src/mage/sets/lorwyn/FootbottomFeast.java new file mode 100644 index 00000000000..f411ff2a2fb --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/FootbottomFeast.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class FootbottomFeast extends mage.sets.commander.FootbottomFeast { + + public FootbottomFeast(UUID ownerId) { + super(ownerId); + this.cardNumber = 115; + this.expansionSetCode = "LRW"; + } + + public FootbottomFeast(final FootbottomFeast card) { + super(card); + } + + @Override + public FootbottomFeast copy() { + return new FootbottomFeast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/GiantsIre.java b/Mage.Sets/src/mage/sets/lorwyn/GiantsIre.java new file mode 100644 index 00000000000..82e62f769a0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/GiantsIre.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class GiantsIre extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Giant"); + + static { + filter.add(new SubtypePredicate("Giant")); + } + + public GiantsIre(UUID ownerId) { + super(ownerId, 170, "Giant's Ire", Rarity.COMMON, new CardType[]{CardType.TRIBAL, CardType.SORCERY}, "{3}{R}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Giant"); + + // Giant's Ire deals 4 damage to target player. + this.getSpellAbility().addEffect(new DamageTargetEffect(4)); + this.getSpellAbility().addTarget(new TargetPlayer()); + + // If you control a Giant, draw a card. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), + new PermanentsOnTheBattlefieldCondition(filter),"If you control a Giant, draw a card")); + } + + public GiantsIre(final GiantsIre card) { + super(card); + } + + @Override + public GiantsIre copy() { + return new GiantsIre(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/GoldmeadowDodger.java b/Mage.Sets/src/mage/sets/lorwyn/GoldmeadowDodger.java index a957e34130f..802b0fda7ec 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/GoldmeadowDodger.java +++ b/Mage.Sets/src/mage/sets/lorwyn/GoldmeadowDodger.java @@ -29,13 +29,12 @@ package mage.sets.lorwyn; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.Filter; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.PowerPredicate; @@ -51,7 +50,7 @@ public class GoldmeadowDodger extends CardImpl { static { filter.add(new PowerPredicate(Filter.ComparisonType.GreaterThan, 3)); } - + public GoldmeadowDodger(UUID ownerId) { super(ownerId, 16, "Goldmeadow Dodger", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}"); this.expansionSetCode = "LRW"; @@ -61,7 +60,7 @@ public class GoldmeadowDodger extends CardImpl { this.toughness = new MageInt(1); // Goldmeadow Dodger can't be blocked by creatures with power 4 or greater. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public GoldmeadowDodger(final GoldmeadowDodger card) { diff --git a/Mage.Sets/src/mage/sets/lorwyn/HoardersGreed.java b/Mage.Sets/src/mage/sets/lorwyn/HoardersGreed.java index 1fca4665842..0b05ef52053 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/HoardersGreed.java +++ b/Mage.Sets/src/mage/sets/lorwyn/HoardersGreed.java @@ -86,7 +86,7 @@ class HoardersGreedEffect extends OneShotEffect { do { controller.loseLife(2, game); controller.drawCards(2, game); - } while (controller.isInGame() && ClashEffect.getInstance().apply(game, source)); + } while (controller.canRespond() && ClashEffect.getInstance().apply(game, source)); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/lorwyn/IncandescentSoulstoke.java b/Mage.Sets/src/mage/sets/lorwyn/IncandescentSoulstoke.java index 1d2c1474769..f3ceefded0e 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/IncandescentSoulstoke.java +++ b/Mage.Sets/src/mage/sets/lorwyn/IncandescentSoulstoke.java @@ -70,7 +70,7 @@ public class IncandescentSoulstoke extends CardImpl { static { filter.add(new SubtypePredicate("Elemental")); } - + public IncandescentSoulstoke(UUID ownerId) { super(ownerId, 178, "Incandescent Soulstoke", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}"); this.expansionSetCode = "LRW"; @@ -81,13 +81,12 @@ public class IncandescentSoulstoke extends CardImpl { // Other Elemental creatures you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(1, 1, Duration.WhileOnBattlefield, filter, true))); - - + // {1}{R}, {T}: You may put an Elemental creature card from your hand onto the battlefield. That creature gains haste until end of turn. Sacrifice it at the beginning of the next end step. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new IncandescentSoulstokeEffect(), new ManaCostsImpl<>("{1}{R}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); - + } public IncandescentSoulstoke(final IncandescentSoulstoke card) { @@ -101,7 +100,7 @@ public class IncandescentSoulstoke extends CardImpl { } class IncandescentSoulstokeEffect extends OneShotEffect { - + private static final String choiceText = "Put an Elemental creature card from your hand onto the battlefield?"; public IncandescentSoulstokeEffect() { @@ -133,10 +132,10 @@ class IncandescentSoulstokeEffect extends OneShotEffect { Permanent permanent = game.getPermanent(card.getId()); if (permanent != null) { ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); - effect.setTargetPointer(new FixedTarget(permanent.getId())); + effect.setTargetPointer(new FixedTarget(permanent, game)); game.addEffect(effect, source); - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName()); - sacrificeEffect.setTargetPointer(new FixedTarget(card.getId())); + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName(), source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/lorwyn/KnuckleboneWitch.java b/Mage.Sets/src/mage/sets/lorwyn/KnuckleboneWitch.java new file mode 100644 index 00000000000..998d28eb901 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/KnuckleboneWitch.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DiesCreatureTriggeredAbility; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author markedagain + */ +public class KnuckleboneWitch extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Goblin you control"); + + static { + filter.add(new ControllerPredicate(TargetController.YOU)); + filter.add(new SubtypePredicate("Goblin")); + } + + public KnuckleboneWitch(UUID ownerId) { + super(ownerId, 120, "Knucklebone Witch", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{B}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Goblin"); + this.subtype.add("Shaman"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Whenever a Goblin you control dies, you may put a +1/+1 counter on Knucklebone Witch. + this.addAbility(new DiesCreatureTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance()), true, filter )); + } + + public KnuckleboneWitch(final KnuckleboneWitch card) { + super(card); + } + + @Override + public KnuckleboneWitch copy() { + return new KnuckleboneWitch(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/MistbindClique.java b/Mage.Sets/src/mage/sets/lorwyn/MistbindClique.java index 3809f1350bc..b2efb5c1b1c 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/MistbindClique.java +++ b/Mage.Sets/src/mage/sets/lorwyn/MistbindClique.java @@ -1,120 +1,116 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.lorwyn; - -import java.util.UUID; - -import mage.MageInt; -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.common.ZoneChangeTriggeredAbility; -import mage.abilities.effects.common.TapAllTargetPlayerControlsEffect; -import mage.abilities.keyword.ChampionAbility; -import mage.abilities.keyword.FlashAbility; -import mage.abilities.keyword.FlyingAbility; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.filter.common.FilterLandPermanent; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.ZoneChangeEvent; -import mage.target.TargetPlayer; - -/** - * - * @author LevelX2 - */ -public class MistbindClique extends CardImpl { - - public MistbindClique(UUID ownerId) { - super(ownerId, 75, "Mistbind Clique", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); - this.expansionSetCode = "LRW"; - this.subtype.add("Faerie"); - this.subtype.add("Wizard"); - - this.power = new MageInt(4); - this.toughness = new MageInt(4); - - // Flash - this.addAbility(FlashAbility.getInstance()); - // Flying - this.addAbility(FlyingAbility.getInstance()); - // Champion a Faerie - this.addAbility(new ChampionAbility(this, "Faerie")); - // When a Faerie is championed with Mistbind Clique, tap all lands target player controls. - this.addAbility(new MistbindCliqueAbility()); - - - } - - public MistbindClique(final MistbindClique card) { - super(card); - } - - @Override - public MistbindClique copy() { - return new MistbindClique(this); - } -} - -class MistbindCliqueAbility extends ZoneChangeTriggeredAbility { - - public MistbindCliqueAbility() { - // ability has to trigger independant where the source object is now - super(Zone.ALL, Zone.BATTLEFIELD, Zone.EXILED, new TapAllTargetPlayerControlsEffect(new FilterLandPermanent("lands")), "When a Faerie is championed with {this}, ", false); - this.addTarget(new TargetPlayer()); - } - - public MistbindCliqueAbility(MistbindCliqueAbility ability) { - super(ability); - } - - @Override - public MistbindCliqueAbility copy() { - return new MistbindCliqueAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == GameEvent.EventType.ZONE_CHANGE; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - if (event.getSourceId() != null && event.getSourceId().equals(getSourceId())) { - ZoneChangeEvent zEvent = (ZoneChangeEvent)event; - if (zEvent.getTarget() != null && zEvent.getTarget().hasSubtype("Faerie")) { - return true; - } - } - return false; - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ZoneChangeTriggeredAbility; +import mage.abilities.effects.common.TapAllTargetPlayerControlsEffect; +import mage.abilities.keyword.ChampionAbility; +import mage.abilities.keyword.FlashAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.ZoneChangeEvent; +import mage.target.TargetPlayer; + +/** + * + * @author LevelX2 + */ +public class MistbindClique extends CardImpl { + + public MistbindClique(UUID ownerId) { + super(ownerId, 75, "Mistbind Clique", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Faerie"); + this.subtype.add("Wizard"); + + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Flash + this.addAbility(FlashAbility.getInstance()); + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Champion a Faerie + this.addAbility(new ChampionAbility(this, "Faerie")); + // When a Faerie is championed with Mistbind Clique, tap all lands target player controls. + this.addAbility(new MistbindCliqueAbility()); + + + } + + public MistbindClique(final MistbindClique card) { + super(card); + } + + @Override + public MistbindClique copy() { + return new MistbindClique(this); + } +} + +class MistbindCliqueAbility extends ZoneChangeTriggeredAbility { + + public MistbindCliqueAbility() { + // ability has to trigger independant where the source object is now + super(Zone.ALL, Zone.BATTLEFIELD, Zone.EXILED, new TapAllTargetPlayerControlsEffect(new FilterLandPermanent("lands")), "When a Faerie is championed with {this}, ", false); + this.addTarget(new TargetPlayer()); + } + + public MistbindCliqueAbility(MistbindCliqueAbility ability) { + super(ability); + } + + @Override + public MistbindCliqueAbility copy() { + return new MistbindCliqueAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.ZONE_CHANGE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (event.getSourceId() != null && event.getSourceId().equals(getSourceId())) { + ZoneChangeEvent zEvent = (ZoneChangeEvent)event; + if (zEvent.getTarget() != null && zEvent.getTarget().hasSubtype("Faerie")) { + return true; + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/NovaChaser.java b/Mage.Sets/src/mage/sets/lorwyn/NovaChaser.java new file mode 100644 index 00000000000..a36f051d3c7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/NovaChaser.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.ChampionAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class NovaChaser extends CardImpl { + + public NovaChaser(UUID ownerId) { + super(ownerId, 187, "Nova Chaser", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Elemental"); + this.subtype.add("Warrior"); + this.power = new MageInt(10); + this.toughness = new MageInt(2); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // Champion an Elemental + this.addAbility(new ChampionAbility(this, "Elemental")); + } + + public NovaChaser(final NovaChaser card) { + super(card); + } + + @Override + public NovaChaser copy() { + return new NovaChaser(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/SurgeOfThoughtweft.java b/Mage.Sets/src/mage/sets/lorwyn/SurgeOfThoughtweft.java new file mode 100644 index 00000000000..371828e4318 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/SurgeOfThoughtweft.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class SurgeOfThoughtweft extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Kithkin"); + + static { + filter.add(new SubtypePredicate("Kithkin")); + } + + public SurgeOfThoughtweft(UUID ownerId) { + super(ownerId, 43, "Surge of Thoughtweft", Rarity.COMMON, new CardType[]{CardType.TRIBAL, CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Kithkin"); + + // Creatures you control get +1/+1 until end of turn. + this.getSpellAbility().addEffect(new BoostControlledEffect(1, 1, Duration.EndOfTurn)); + + // If you control a Kithkin, draw a card. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), + new PermanentsOnTheBattlefieldCondition(filter),"If you control a Kithkin, draw a card")); + } + + public SurgeOfThoughtweft(final SurgeOfThoughtweft card) { + super(card); + } + + @Override + public SurgeOfThoughtweft copy() { + return new SurgeOfThoughtweft(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/ThoughtweftTrio.java b/Mage.Sets/src/mage/sets/lorwyn/ThoughtweftTrio.java new file mode 100644 index 00000000000..0aefa5956e3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/ThoughtweftTrio.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CanBlockAdditionalCreatureEffect; +import mage.abilities.keyword.ChampionAbility; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class ThoughtweftTrio extends CardImpl { + + public ThoughtweftTrio(UUID ownerId) { + super(ownerId, 44, "Thoughtweft Trio", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}{W}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Kithkin"); + this.subtype.add("Soldier"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + + // Vigilance + this.addAbility(VigilanceAbility.getInstance()); + + // Champion a Kithkin + this.addAbility(new ChampionAbility(this, "Kithkin")); + + // Thoughtweft Trio can block any number of creatures. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CanBlockAdditionalCreatureEffect(0))); + } + + public ThoughtweftTrio(final ThoughtweftTrio card) { + super(card); + } + + @Override + public ThoughtweftTrio copy() { + return new ThoughtweftTrio(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/TideshaperMystic.java b/Mage.Sets/src/mage/sets/lorwyn/TideshaperMystic.java new file mode 100644 index 00000000000..38dfda46dfe --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/TideshaperMystic.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ActivateIfConditionActivatedAbility; +import mage.abilities.condition.common.MyTurnCondition; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class TideshaperMystic extends CardImpl { + + public TideshaperMystic(UUID ownerId) { + super(ownerId, 93, "Tideshaper Mystic", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {tap}: Target land becomes the basic land type of your choice until end of turn. Activate this ability only during your turn. + Ability ability = new ActivateIfConditionActivatedAbility(Zone.BATTLEFIELD, + new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost(), MyTurnCondition.getInstance()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public TideshaperMystic(final TideshaperMystic card) { + super(card); + } + + @Override + public TideshaperMystic copy() { + return new TideshaperMystic(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/TriclopeanSight.java b/Mage.Sets/src/mage/sets/lorwyn/TriclopeanSight.java new file mode 100644 index 00000000000..89883601195 --- /dev/null +++ b/Mage.Sets/src/mage/sets/lorwyn/TriclopeanSight.java @@ -0,0 +1,89 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.lorwyn; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.UntapEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlashAbility; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class TriclopeanSight extends CardImpl { + + public TriclopeanSight(UUID ownerId) { + super(ownerId, 45, "Triclopean Sight", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + this.expansionSetCode = "LRW"; + this.subtype.add("Aura"); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Neutral)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // When Triclopean Sight enters the battlefield, untap enchanted creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new UntapEnchantedEffect())); + + // Enchanted creature gets +1/+1 and has vigilance. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1,1, Duration.WhileOnBattlefield)); + ability.addEffect(new GainAbilityAttachedEffect(VigilanceAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield)); + this.addAbility(ability); + } + + public TriclopeanSight(final TriclopeanSight card) { + super(card); + } + + @Override + public TriclopeanSight copy() { + return new TriclopeanSight(this); + } +} diff --git a/Mage.Sets/src/mage/sets/lorwyn/WortBoggartAuntie.java b/Mage.Sets/src/mage/sets/lorwyn/WortBoggartAuntie.java index 2d319bc0743..05c93371dfd 100644 --- a/Mage.Sets/src/mage/sets/lorwyn/WortBoggartAuntie.java +++ b/Mage.Sets/src/mage/sets/lorwyn/WortBoggartAuntie.java @@ -27,21 +27,20 @@ */ package mage.sets.lorwyn; -import mage.constants.CardType; -import mage.constants.Rarity; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.effects.common.ReturnToHandTargetEffect; import mage.abilities.keyword.FearAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.TargetController; import mage.filter.FilterCard; import mage.filter.predicate.mageobject.SubtypePredicate; import mage.target.common.TargetCardInYourGraveyard; -import java.util.UUID; - /** * * @author Loki @@ -61,10 +60,11 @@ public class WortBoggartAuntie extends CardImpl { this.subtype.add("Goblin"); this.subtype.add("Shaman"); - this.power = new MageInt(3); this.toughness = new MageInt(3); + this.addAbility(FearAbility.getInstance()); + // At the beginning of your upkeep, you may return target Goblin card from your graveyard to your hand. Ability ability = new BeginningOfUpkeepTriggeredAbility(new ReturnToHandTargetEffect(), TargetController.YOU, true); ability.addTarget(new TargetCardInYourGraveyard(filter)); diff --git a/Mage.Sets/src/mage/sets/magic2010/DreadWarlock.java b/Mage.Sets/src/mage/sets/magic2010/DreadWarlock.java index 4d6639a4fc5..555286fb413 100644 --- a/Mage.Sets/src/mage/sets/magic2010/DreadWarlock.java +++ b/Mage.Sets/src/mage/sets/magic2010/DreadWarlock.java @@ -28,16 +28,17 @@ package mage.sets.magic2010; import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; +import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.effects.RestrictionEffect; -import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; /** * @@ -45,6 +46,12 @@ import mage.game.permanent.Permanent; */ public class DreadWarlock extends CardImpl { + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("except by black creatures"); + + static { + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + public DreadWarlock(UUID ownerId) { super(ownerId, 94, "Dread Warlock", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{B}{B}"); this.expansionSetCode = "M10"; @@ -55,7 +62,7 @@ public class DreadWarlock extends CardImpl { this.toughness = new MageInt(2); // Dread Warlock can't be blocked except by black creatures. - this.addAbility(DreadWarlockAbility.getInstance()); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public DreadWarlock(final DreadWarlock card) { @@ -67,61 +74,3 @@ public class DreadWarlock extends CardImpl { return new DreadWarlock(this); } } - -class DreadWarlockAbility extends EvasionAbility { - - private static DreadWarlockAbility instance; - - public static DreadWarlockAbility getInstance() { - if (instance == null) { - instance = new DreadWarlockAbility(); - } - return instance; - } - - private DreadWarlockAbility() { - this.addEffect(new DreadWarlockEffect()); - } - - @Override - public String getRule() { - return "{this} can't be blocked except by black creatures."; - } - - @Override - public DreadWarlockAbility copy() { - return getInstance(); - } -} - -class DreadWarlockEffect extends RestrictionEffect { - - public DreadWarlockEffect() { - super(Duration.WhileOnBattlefield); - } - - public DreadWarlockEffect(final DreadWarlockEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - if (permanent.getAbilities().containsKey(DreadWarlockAbility.getInstance().getId())) { - return true; - } - return false; - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - if (blocker.getColor(game).isBlack()) { - return true; - } - return false; - } - - @Override - public DreadWarlockEffect copy() { - return new DreadWarlockEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/magic2010/ElvishPiper.java b/Mage.Sets/src/mage/sets/magic2010/ElvishPiper.java index c29ae7ffdd7..2ce8555a73b 100644 --- a/Mage.Sets/src/mage/sets/magic2010/ElvishPiper.java +++ b/Mage.Sets/src/mage/sets/magic2010/ElvishPiper.java @@ -27,17 +27,18 @@ */ package mage.sets.magic2010; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; + +import java.util.UUID; import mage.MageInt; -import mage.abilities.effects.common.PutCreatureOnBattlefieldEffect; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; - -import java.util.UUID; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; /** * @@ -56,7 +57,7 @@ public class ElvishPiper extends CardImpl { // {G}, {tap}: You may put a creature card from your hand onto the battlefield. SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, - new PutCreatureOnBattlefieldEffect(), + new PutPermanentOnBattlefieldEffect(new FilterCreatureCard("a creature card")), new ManaCostsImpl("{G}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/magic2010/HypnoticSpecter.java b/Mage.Sets/src/mage/sets/magic2010/HypnoticSpecter.java index c72c755c858..e120011e380 100644 --- a/Mage.Sets/src/mage/sets/magic2010/HypnoticSpecter.java +++ b/Mage.Sets/src/mage/sets/magic2010/HypnoticSpecter.java @@ -27,13 +27,13 @@ */ package mage.sets.magic2010; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.discard.DiscardTargetEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import java.util.UUID; @@ -65,4 +65,4 @@ public class HypnoticSpecter extends CardImpl { public HypnoticSpecter copy() { return new HypnoticSpecter(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magic2010/IceCage.java b/Mage.Sets/src/mage/sets/magic2010/IceCage.java index 911d57ec0d6..9c8f2b22653 100644 --- a/Mage.Sets/src/mage/sets/magic2010/IceCage.java +++ b/Mage.Sets/src/mage/sets/magic2010/IceCage.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -30,7 +30,7 @@ package mage.sets.magic2010; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.BecomesTargetAttachedTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.DestroySourceEffect; @@ -41,10 +41,6 @@ import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.game.permanent.Permanent; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -71,7 +67,7 @@ public class IceCage extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBlockAttackActivateAttachedEffect())); // When enchanted creature becomes the target of a spell or ability, destroy Ice Cage. - this.addAbility(new IceCageAbility()); + this.addAbility(new BecomesTargetAttachedTriggeredAbility(new DestroySourceEffect())); } public IceCage(final IceCage card) { @@ -83,41 +79,3 @@ public class IceCage extends CardImpl { return new IceCage(this); } } - -class IceCageAbility extends TriggeredAbilityImpl { - - public IceCageAbility() { - super(Zone.BATTLEFIELD, new DestroySourceEffect()); - } - - public IceCageAbility(final IceCageAbility ability) { - super(ability); - } - - @Override - public IceCageAbility copy() { - return new IceCageAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.TARGETED; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - Permanent enchantment = game.getPermanent(sourceId); - if (enchantment != null && enchantment.getAttachedTo() != null) { - if (event.getTargetId().equals(enchantment.getAttachedTo())) { - return true; - } - } - return false; - } - - @Override - public String getRule() { - return "When enchanted creature becomes the target of a spell or ability, destroy {this}."; - } - -} diff --git a/Mage.Sets/src/mage/sets/magic2010/MirrorOfFate.java b/Mage.Sets/src/mage/sets/magic2010/MirrorOfFate.java index 501a3d8bafa..2452f5850b2 100644 --- a/Mage.Sets/src/mage/sets/magic2010/MirrorOfFate.java +++ b/Mage.Sets/src/mage/sets/magic2010/MirrorOfFate.java @@ -114,7 +114,7 @@ class MirrorOfFateEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on top of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/magic2010/SphinxAmbassador.java b/Mage.Sets/src/mage/sets/magic2010/SphinxAmbassador.java index d45e92ec373..595a34013f8 100644 --- a/Mage.Sets/src/mage/sets/magic2010/SphinxAmbassador.java +++ b/Mage.Sets/src/mage/sets/magic2010/SphinxAmbassador.java @@ -116,7 +116,7 @@ class SphinxAmbassadorEffect extends OneShotEffect { cardChoice.setChoices(choices); cardChoice.clearChoice(); while (!targetPlayer.choose(Outcome.Benefit, cardChoice, game)) { - if (!targetPlayer.isInGame()) { + if (!targetPlayer.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/magic2011/ChandrasOutrage.java b/Mage.Sets/src/mage/sets/magic2011/ChandrasOutrage.java index a5ee07e9ce7..98d75760c25 100644 --- a/Mage.Sets/src/mage/sets/magic2011/ChandrasOutrage.java +++ b/Mage.Sets/src/mage/sets/magic2011/ChandrasOutrage.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -29,15 +29,12 @@ package mage.sets.magic2011; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetCreaturePermanent; /** @@ -50,7 +47,11 @@ public class ChandrasOutrage extends CardImpl { super(ownerId, 128, "Chandra's Outrage", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}{R}"); this.expansionSetCode = "M11"; - this.getSpellAbility().addEffect(new ChandrasOutrageEffect()); + // Chandra's Outrage deals 4 damage to target creature and 2 damage to that creature's controller. + this.getSpellAbility().addEffect(new DamageTargetEffect(4)); + Effect effect = new DamageTargetControllerEffect(2); + effect.setText("and 2 damage to that creature's controller"); + this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); } @@ -64,35 +65,3 @@ public class ChandrasOutrage extends CardImpl { } } - -class ChandrasOutrageEffect extends OneShotEffect { - - public ChandrasOutrageEffect() { - super(Outcome.Damage); - staticText = "{this} deals 4 damage to target creature and 2 damage to that creature's controller"; - } - - public ChandrasOutrageEffect(final ChandrasOutrageEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(source.getFirstTarget()); - if (permanent != null) { - Player player = game.getPlayer(permanent.getControllerId()); - if (player != null) { - permanent.damage(4, source.getSourceId(), game, false, true); - player.damage(2, source.getSourceId(), game, false, true); - return true; - } - } - return false; - } - - @Override - public ChandrasOutrageEffect copy() { - return new ChandrasOutrageEffect(this); - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/magic2011/ConundrumSphinx.java b/Mage.Sets/src/mage/sets/magic2011/ConundrumSphinx.java index b8143876eb4..18776c87e2f 100644 --- a/Mage.Sets/src/mage/sets/magic2011/ConundrumSphinx.java +++ b/Mage.Sets/src/mage/sets/magic2011/ConundrumSphinx.java @@ -95,8 +95,8 @@ class ConundrumSphinxEffect extends OneShotEffect { for (Player player: game.getPlayers().values()) { if(player.getLibrary().size() > 0){ cardChoice.clearChoice(); - while (!player.choose(Outcome.DrawCard, cardChoice, game) && player.isInGame()) { - if (!player.isInGame()) { + while (!player.choose(Outcome.DrawCard, cardChoice, game) && player.canRespond()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/magic2011/Cultivate.java b/Mage.Sets/src/mage/sets/magic2011/Cultivate.java index b4fe191ce45..b68d4a6bdeb 100644 --- a/Mage.Sets/src/mage/sets/magic2011/Cultivate.java +++ b/Mage.Sets/src/mage/sets/magic2011/Cultivate.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,16 +20,15 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2011; -import java.util.List; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; @@ -93,41 +92,44 @@ class CultivateEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { + return false; + } TargetCardInLibrary target = new TargetCardInLibrary(0, 2, new FilterBasicLandCard()); - Player player = game.getPlayer(source.getControllerId()); - if (player.searchLibrary(target, game)) { + if (controller.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { Cards revealed = new CardsImpl(); - for (UUID cardId: (List)target.getTargets()) { - Card card = player.getLibrary().getCard(cardId, game); + for (UUID cardId : target.getTargets()) { + Card card = controller.getLibrary().getCard(cardId, game); revealed.add(card); } - player.revealCards("Cultivate", revealed, game); + controller.revealCards(sourceObject.getIdName(), revealed, game); if (target.getTargets().size() == 2) { TargetCard target2 = new TargetCard(Zone.LIBRARY, filter); - player.choose(Outcome.Benefit, revealed, target2, game); + controller.choose(Outcome.Benefit, revealed, target2, game); Card card = revealed.get(target2.getFirstTarget(), game); if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); revealed.remove(card); } card = revealed.getCards(game).iterator().next(); if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); } - } - else if (target.getTargets().size() == 1) { + } else if (target.getTargets().size() == 1) { Card card = revealed.getCards(game).iterator().next(); if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId(), true); } } } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return true; } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return false; } diff --git a/Mage.Sets/src/mage/sets/magic2011/GaeasRevenge.java b/Mage.Sets/src/mage/sets/magic2011/GaeasRevenge.java index d09fae31897..1c174e38e8e 100644 --- a/Mage.Sets/src/mage/sets/magic2011/GaeasRevenge.java +++ b/Mage.Sets/src/mage/sets/magic2011/GaeasRevenge.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,19 +20,14 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2011; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.ObjectColor; import mage.abilities.common.SimpleStaticAbility; @@ -40,6 +35,11 @@ import mage.abilities.effects.common.CantBeCounteredSourceEffect; import mage.abilities.effects.common.CantBeTargetedSourceEffect; import mage.abilities.keyword.HasteAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterObject; import mage.filter.FilterStackObject; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.ColorPredicate; @@ -50,7 +50,7 @@ import mage.filter.predicate.mageobject.ColorPredicate; */ public class GaeasRevenge extends CardImpl { - private static final FilterStackObject filter = new FilterStackObject("nongreen spells or abilities from nongreen sources"); + private static final FilterObject filter = new FilterStackObject("nongreen spells or abilities from nongreen sources"); static { filter.add(Predicates.not(new ColorPredicate(ObjectColor.GREEN))); diff --git a/Mage.Sets/src/mage/sets/magic2011/GraveTitan.java b/Mage.Sets/src/mage/sets/magic2011/GraveTitan.java index b478145b76c..22f1f6bfa4b 100644 --- a/Mage.Sets/src/mage/sets/magic2011/GraveTitan.java +++ b/Mage.Sets/src/mage/sets/magic2011/GraveTitan.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2011; import java.util.UUID; @@ -74,7 +73,7 @@ public class GraveTitan extends CardImpl { class GraveTitanAbility extends TriggeredAbilityImpl { public GraveTitanAbility() { - super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken("M11"), 2), false); + super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken(), 2), false); } public GraveTitanAbility(final GraveTitanAbility ability) { @@ -96,7 +95,7 @@ class GraveTitanAbility extends TriggeredAbilityImpl { if (event.getType() == EventType.ATTACKER_DECLARED && event.getSourceId().equals(this.getSourceId())) { return true; } - if (event.getType() == EventType.ENTERS_THE_BATTLEFIELD && event.getTargetId().equals(this.getSourceId()) ) { + if (event.getType() == EventType.ENTERS_THE_BATTLEFIELD && event.getTargetId().equals(this.getSourceId())) { return true; } return false; diff --git a/Mage.Sets/src/mage/sets/magic2011/ObstinateBaloth.java b/Mage.Sets/src/mage/sets/magic2011/ObstinateBaloth.java index f4675b3bc48..b4ec4152be9 100644 --- a/Mage.Sets/src/mage/sets/magic2011/ObstinateBaloth.java +++ b/Mage.Sets/src/mage/sets/magic2011/ObstinateBaloth.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -29,25 +29,15 @@ package mage.sets.magic2011; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; -import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.DiscardOntoBattlefieldEffect; import mage.abilities.effects.common.GainLifeEffect; -import mage.cards.Card; import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.game.events.ZoneChangeEvent; -import mage.game.stack.StackObject; -import mage.players.Player; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; /** * @@ -65,9 +55,9 @@ public class ObstinateBaloth extends CardImpl { // When Obstinate Baloth enters the battlefield, you gain 4 life. this.addAbility(new EntersBattlefieldTriggeredAbility(new GainLifeEffect(4), false)); - + // If a spell or ability an opponent controls causes you to discard Obstinate Baloth, put it onto the battlefield instead of putting it into your graveyard. - this.addAbility(new SimpleStaticAbility(Zone.HAND, new ObstinateBalothEffect())); + this.addAbility(new SimpleStaticAbility(Zone.HAND, new DiscardOntoBattlefieldEffect())); } public ObstinateBaloth(final ObstinateBaloth card) { @@ -81,53 +71,3 @@ public class ObstinateBaloth extends CardImpl { } -class ObstinateBalothEffect extends ReplacementEffectImpl { - - public ObstinateBalothEffect() { - super(Duration.EndOfGame, Outcome.PutCardInPlay); - staticText = "If a spell or ability an opponent controls causes you to discard {this}, put it onto the battlefield instead of putting it into your graveyard"; - } - - public ObstinateBalothEffect(final ObstinateBalothEffect effect) { - super(effect); - } - - @Override - public ObstinateBalothEffect copy() { - return new ObstinateBalothEffect(this); - } - - @Override - public boolean checksEventType(GameEvent event, Game game) { - return event.getType() == EventType.ZONE_CHANGE; - } - - @Override - public boolean applies(GameEvent event, Ability source, Game game) { - if (event.getTargetId().equals(source.getSourceId())) { - ZoneChangeEvent zcEvent = (ZoneChangeEvent) event; - if (zcEvent.getFromZone() == Zone.HAND && zcEvent.getToZone() == Zone.GRAVEYARD) { - StackObject spell = game.getStack().getStackObject(event.getSourceId()); - if (spell != null && game.getOpponents(source.getControllerId()).contains(spell.getControllerId())) { - return true; - } - } - } - return false; - } - - @Override - public boolean replaceEvent(GameEvent event, Ability source, Game game) { - Card card = game.getCard(source.getSourceId()); - if (card != null) { - Player owner = game.getPlayer(card.getOwnerId()); - if (owner != null) { - if (owner.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId())) { - return true; - } - } - } - return false; - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/magic2011/PyreticRitual.java b/Mage.Sets/src/mage/sets/magic2011/PyreticRitual.java index 9000bb19c95..5b75d3cb028 100644 --- a/Mage.Sets/src/mage/sets/magic2011/PyreticRitual.java +++ b/Mage.Sets/src/mage/sets/magic2011/PyreticRitual.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,20 +20,19 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2011; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.Mana; import mage.abilities.effects.common.BasicManaEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * @@ -45,6 +44,7 @@ public class PyreticRitual extends CardImpl { super(ownerId, 153, "Pyretic Ritual", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{R}"); this.expansionSetCode = "M11"; + // Add {R}{R}{R} to your mana pool. this.getSpellAbility().addEffect(new BasicManaEffect(Mana.RedMana(3))); } diff --git a/Mage.Sets/src/mage/sets/magic2012/AdaptiveAutomaton.java b/Mage.Sets/src/mage/sets/magic2012/AdaptiveAutomaton.java index dcce392fd61..d6af2a5a2ab 100644 --- a/Mage.Sets/src/mage/sets/magic2012/AdaptiveAutomaton.java +++ b/Mage.Sets/src/mage/sets/magic2012/AdaptiveAutomaton.java @@ -27,24 +27,31 @@ */ package mage.sets.magic2012; -import mage.constants.*; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.AsEntersBattlefieldAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ContinuousEffectImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ChooseCreatureTypeEffect; +import mage.abilities.effects.common.continuous.BoostAllEffect; import mage.cards.CardImpl; -import mage.cards.repository.CardRepository; -import mage.choices.Choice; -import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.TargetController; +import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; -import java.util.UUID; - /** * @author nantuko */ @@ -59,11 +66,15 @@ public class AdaptiveAutomaton extends CardImpl { this.toughness = new MageInt(2); // As Adaptive Automaton enters the battlefield, choose a creature type. - this.addAbility(new AsEntersBattlefieldAbility(new AdaptiveAutomatonEffect())); + this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.BoostCreature))); // Adaptive Automaton is the chosen type in addition to its other types. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new AdaptiveAutomatonAddSubtypeEffect())); // Other creatures you control of the chosen type get +1/+1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new AdaptiveAutomatonBoostControlledEffect())); + FilterCreaturePermanent filter = new FilterCreaturePermanent("Other creatures you control of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + filter.add(new AnotherPredicate()); + filter.add(new ControllerPredicate(TargetController.YOU)); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, false))); } public AdaptiveAutomaton(final AdaptiveAutomaton card) { @@ -76,43 +87,6 @@ public class AdaptiveAutomaton extends CardImpl { } } -class AdaptiveAutomatonEffect extends OneShotEffect { - - public AdaptiveAutomatonEffect() { - super(Outcome.BoostCreature); - staticText = "choose a creature type"; - } - - public AdaptiveAutomatonEffect(final AdaptiveAutomatonEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - Permanent permanent = game.getPermanent(source.getSourceId()); - if (player != null && permanent != null) { - Choice typeChoice = new ChoiceImpl(true); - typeChoice.setMessage("Choose creature type"); - typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); - while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { - return false; - } - } - game.informPlayers(permanent.getName() + ": " + player.getLogName() + " has chosen " + typeChoice.getChoice()); - game.getState().setValue(permanent.getId() + "_type", typeChoice.getChoice()); - permanent.addInfo("chosen type", "Chosen type: " + typeChoice.getChoice().toString() + "", game); - } - return false; - } - - @Override - public AdaptiveAutomatonEffect copy() { - return new AdaptiveAutomatonEffect(this); - } - -} class AdaptiveAutomatonAddSubtypeEffect extends ContinuousEffectImpl { public AdaptiveAutomatonAddSubtypeEffect() { @@ -141,40 +115,3 @@ class AdaptiveAutomatonAddSubtypeEffect extends ContinuousEffectImpl { return new AdaptiveAutomatonAddSubtypeEffect(this); } } - -class AdaptiveAutomatonBoostControlledEffect extends ContinuousEffectImpl { - - private static final FilterCreaturePermanent filter = new FilterCreaturePermanent(); - - public AdaptiveAutomatonBoostControlledEffect() { - super(Duration.WhileOnBattlefield, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, Outcome.BoostCreature); - staticText = "Other creatures you control of the chosen type get +1/+1"; - } - - public AdaptiveAutomatonBoostControlledEffect(final AdaptiveAutomatonBoostControlledEffect effect) { - super(effect); - } - - @Override - public AdaptiveAutomatonBoostControlledEffect copy() { - return new AdaptiveAutomatonBoostControlledEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null) { - String subtype = (String) game.getState().getValue(permanent.getId() + "_type"); - if (subtype != null) { - for (Permanent perm: game.getBattlefield().getAllActivePermanents(filter, source.getControllerId(), game)) { - if (!perm.getId().equals(source.getSourceId()) && perm.hasSubtype(subtype)) { - perm.addPower(1); - perm.addToughness(1); - } - } - } - } - return true; - } - -} diff --git a/Mage.Sets/src/mage/sets/magic2012/CemeteryReaper.java b/Mage.Sets/src/mage/sets/magic2012/CemeteryReaper.java index 91a639adbb4..54bc7b115d9 100644 --- a/Mage.Sets/src/mage/sets/magic2012/CemeteryReaper.java +++ b/Mage.Sets/src/mage/sets/magic2012/CemeteryReaper.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2012; import java.util.UUID; @@ -55,7 +54,7 @@ import mage.target.common.TargetCardInGraveyard; public class CemeteryReaper extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Zombie creatures"); - + static { filter.add(new SubtypePredicate("Zombie")); } @@ -66,14 +65,14 @@ public class CemeteryReaper extends CardImpl { this.subtype.add("Zombie"); this.power = new MageInt(2); this.toughness = new MageInt(2); - + // Other Zombie creatures you control get +1/+1. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostControlledEffect(1, 1, Duration.WhileOnBattlefield, filter, true))); - - // {2}{B}, {T} : Exile target creature card from a graveyard. Put a 2/2 black Zombie creature token onto the battlefield. + + // {2}{B}, {T} : Exile target creature card from a graveyard. Put a 2/2 black Zombie creature token onto the battlefield. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new ManaCostsImpl("{2}{B}")); ability.addCost(new TapSourceCost()); - ability.addEffect(new CreateTokenEffect(new ZombieToken("M12"))); + ability.addEffect(new CreateTokenEffect(new ZombieToken())); ability.addTarget(new TargetCardInGraveyard(new FilterCreatureCard("creature card from a graveyard"))); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2012/Firebreathing.java b/Mage.Sets/src/mage/sets/magic2012/Firebreathing.java index 6cd00148230..e7d349cee9f 100644 --- a/Mage.Sets/src/mage/sets/magic2012/Firebreathing.java +++ b/Mage.Sets/src/mage/sets/magic2012/Firebreathing.java @@ -25,12 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.magic2012; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ColoredManaCost; @@ -38,6 +35,12 @@ import mage.abilities.effects.common.AttachEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -47,20 +50,23 @@ import mage.target.common.TargetCreaturePermanent; */ public class Firebreathing extends CardImpl { - public Firebreathing (UUID ownerId) { + public Firebreathing(UUID ownerId) { super(ownerId, 132, "Firebreathing", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{R}"); this.expansionSetCode = "M12"; this.subtype.add("Aura"); + // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); + + // {R}: Enchanted creature gets +1/+0 until end of turn. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.R))); } - public Firebreathing (final Firebreathing card) { + public Firebreathing(final Firebreathing card) { super(card); } diff --git a/Mage.Sets/src/mage/sets/magic2012/GarruksHorde.java b/Mage.Sets/src/mage/sets/magic2012/GarruksHorde.java index 0d13b2816d5..440a833ad87 100644 --- a/Mage.Sets/src/mage/sets/magic2012/GarruksHorde.java +++ b/Mage.Sets/src/mage/sets/magic2012/GarruksHorde.java @@ -27,19 +27,19 @@ */ package mage.sets.magic2012; -import mage.constants.CardType; -import mage.constants.Rarity; +import java.util.UUID; import mage.MageInt; import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.continuous.PlayTheTopCardEffect; import mage.abilities.effects.common.continuous.PlayWithTheTopCardRevealedEffect; import mage.abilities.keyword.TrampleAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; -import java.util.UUID; - /** * @author nantuko */ @@ -57,7 +57,9 @@ public class GarruksHorde extends CardImpl { // Play with the top card of your library revealed. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithTheTopCardRevealedEffect())); // You may cast the top card of your library if it's a creature card. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayTheTopCardEffect(new FilterCreatureCard()))); + Effect effect = new PlayTheTopCardEffect(new FilterCreatureCard()); + effect.setText("You may cast the top card of your library if it's a creature card"); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } public GarruksHorde(final GarruksHorde card) { diff --git a/Mage.Sets/src/mage/sets/magic2012/JacesArchivist.java b/Mage.Sets/src/mage/sets/magic2012/JacesArchivist.java index 5836f1f85d2..7c944d51a83 100644 --- a/Mage.Sets/src/mage/sets/magic2012/JacesArchivist.java +++ b/Mage.Sets/src/mage/sets/magic2012/JacesArchivist.java @@ -27,20 +27,22 @@ */ package mage.sets.magic2012; -import mage.constants.*; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ColoredManaCost; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.players.Player; -import java.util.UUID; - /** * @author Loki */ @@ -55,6 +57,7 @@ public class JacesArchivist extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); + // {U}, {T}: Each player discards his or her hand, then draws cards equal to the greatest number of cards a player discarded this way. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new JacesArchivistEffect(), new ColoredManaCost(ColoredManaSymbol.U)); ability.addCost(new TapSourceCost()); this.addAbility(ability); @@ -71,6 +74,7 @@ public class JacesArchivist extends CardImpl { } class JacesArchivistEffect extends OneShotEffect { + JacesArchivistEffect() { super(Outcome.Discard); staticText = "Each player discards his or her hand, then draws cards equal to the greatest number of cards a player discarded this way"; @@ -83,20 +87,18 @@ class JacesArchivistEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { int maxDiscarded = 0; - Player sourcePlayer = game.getPlayer(source.getControllerId()); - for (UUID playerId : sourcePlayer.getInRange()) { + Player controller = game.getPlayer(source.getControllerId()); + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { Player player = game.getPlayer(playerId); if (player != null) { - int discarded = 0; - for (Card c : player.getHand().getCards(game)) { - if (player.discard(c, source, game)) - discarded++; - } - if (discarded > maxDiscarded) + int discarded = player.getHand().size(); + player.discard(discarded, false, source, game); + if (discarded > maxDiscarded) { maxDiscarded = discarded; + } } } - for (UUID playerId : sourcePlayer.getInRange()) { + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { Player player = game.getPlayer(playerId); if (player != null) { player.drawCards(maxDiscarded, game); diff --git a/Mage.Sets/src/mage/sets/magic2012/QuicksilverAmulet.java b/Mage.Sets/src/mage/sets/magic2012/QuicksilverAmulet.java index c220e08f282..5789dcd3403 100644 --- a/Mage.Sets/src/mage/sets/magic2012/QuicksilverAmulet.java +++ b/Mage.Sets/src/mage/sets/magic2012/QuicksilverAmulet.java @@ -30,11 +30,12 @@ package mage.sets.magic2012; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; -import mage.abilities.effects.common.PutCreatureOnBattlefieldEffect; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.cards.CardImpl; +import mage.filter.common.FilterCreatureCard; import java.util.UUID; @@ -50,7 +51,7 @@ public class QuicksilverAmulet extends CardImpl { // {4}, {tap}: You may put a creature card from your hand onto the battlefield. SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, - new PutCreatureOnBattlefieldEffect(), + new PutPermanentOnBattlefieldEffect(new FilterCreatureCard("a creature card")), new ManaCostsImpl("{4}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/magic2012/ZombieInfestation.java b/Mage.Sets/src/mage/sets/magic2012/ZombieInfestation.java index 09c3d728579..e557f401005 100644 --- a/Mage.Sets/src/mage/sets/magic2012/ZombieInfestation.java +++ b/Mage.Sets/src/mage/sets/magic2012/ZombieInfestation.java @@ -28,13 +28,13 @@ package mage.sets.magic2012; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.DiscardTargetCost; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.FilterCard; import mage.game.permanent.token.ZombieToken; import mage.target.common.TargetCardInHand; @@ -49,10 +49,9 @@ public class ZombieInfestation extends CardImpl { super(ownerId, 120, "Zombie Infestation", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); this.expansionSetCode = "M12"; - // Discard two cards: Put a 2/2 black Zombie creature token onto the battlefield. SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, - new CreateTokenEffect(new ZombieToken("M12")), + new CreateTokenEffect(new ZombieToken()), new DiscardTargetCost(new TargetCardInHand(2, new FilterCard("two cards")))); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2013/KnightOfGlory.java b/Mage.Sets/src/mage/sets/magic2013/KnightOfGlory.java index 53572bddc40..eec4e15a582 100644 --- a/Mage.Sets/src/mage/sets/magic2013/KnightOfGlory.java +++ b/Mage.Sets/src/mage/sets/magic2013/KnightOfGlory.java @@ -1,77 +1,77 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.magic2013; - -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.MageInt; -import mage.ObjectColor; -import mage.abilities.keyword.ExaltedAbility; -import mage.abilities.keyword.ProtectionAbility; -import mage.cards.CardImpl; -import mage.filter.FilterCard; -import mage.filter.predicate.mageobject.ColorPredicate; - -/** - * - * @author jeffwadsworth - */ -public class KnightOfGlory extends CardImpl { - - private static final FilterCard filter = new FilterCard("Black"); - - static { - filter.add(new ColorPredicate(ObjectColor.BLACK)); - } - - public KnightOfGlory(UUID ownerId) { - super(ownerId, 21, "Knight of Glory", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); - this.expansionSetCode = "M13"; - this.subtype.add("Human"); - this.subtype.add("Knight"); - - this.power = new MageInt(2); - this.toughness = new MageInt(1); - - // Protection from black - this.addAbility(new ProtectionAbility(filter)); - - // Exalted - this.addAbility(new ExaltedAbility()); - } - - public KnightOfGlory(final KnightOfGlory card) { - super(card); - } - - @Override - public KnightOfGlory copy() { - return new KnightOfGlory(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.magic2013; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.keyword.ExaltedAbility; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author jeffwadsworth + */ +public class KnightOfGlory extends CardImpl { + + private static final FilterCard filter = new FilterCard("black"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public KnightOfGlory(UUID ownerId) { + super(ownerId, 21, "Knight of Glory", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "M13"; + this.subtype.add("Human"); + this.subtype.add("Knight"); + + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Protection from black + this.addAbility(new ProtectionAbility(filter)); + + // Exalted + this.addAbility(new ExaltedAbility()); + } + + public KnightOfGlory(final KnightOfGlory card) { + super(card); + } + + @Override + public KnightOfGlory copy() { + return new KnightOfGlory(this); + } +} diff --git a/Mage.Sets/src/mage/sets/magic2013/Omniscience.java b/Mage.Sets/src/mage/sets/magic2013/Omniscience.java index 6c9b7cf9322..155d366fce3 100644 --- a/Mage.Sets/src/mage/sets/magic2013/Omniscience.java +++ b/Mage.Sets/src/mage/sets/magic2013/Omniscience.java @@ -28,7 +28,6 @@ package mage.sets.magic2013; import java.util.UUID; - import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; @@ -39,6 +38,7 @@ import mage.abilities.costs.AlternativeCostSourceAbility; import mage.abilities.effects.ContinuousEffectImpl; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.SplitCardHalf; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Layer; @@ -61,7 +61,6 @@ public class Omniscience extends CardImpl { super(ownerId, 63, "Omniscience", Rarity.MYTHIC, new CardType[]{CardType.ENCHANTMENT}, "{7}{U}{U}{U}"); this.expansionSetCode = "M13"; - // You may cast nonland cards from your hand without paying their mana costs. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OmniscienceCastingEffect())); } @@ -116,19 +115,22 @@ class OmniscienceCastingEffect extends ContinuousEffectImpl { class IsBeingCastFromHandCondition implements Condition { - @Override - public boolean apply(Game game, Ability source) { + @Override + public boolean apply(Game game, Ability source) { MageObject object = game.getObject(source.getSourceId()); - if(object instanceof Spell) { - Spell spell = (Spell) object; - return spell != null && spell.getFromZone() == Zone.HAND; - } - if(object instanceof Card) { - Card card = (Card)object; - return game.getPlayer(card.getOwnerId()).getHand().get(card.getId(), game) != null; - } - - return false; - } + if (object instanceof SplitCardHalf) { + UUID splitCardId = ((Card) object).getMainCard().getId(); + object = game.getObject(splitCardId); + } + if (object instanceof Spell) { // needed to check if it can be cast by alternate cost + Spell spell = (Spell) object; + return spell.getFromZone() == Zone.HAND; + } + if (object instanceof Card) { // needed for the check what's playable + Card card = (Card) object; + return game.getPlayer(card.getOwnerId()).getHand().get(card.getId(), game) != null; + } + return false; + } } diff --git a/Mage.Sets/src/mage/sets/magic2013/VileRebirth.java b/Mage.Sets/src/mage/sets/magic2013/VileRebirth.java index 2daa3aca0f9..f62b22cdeaa 100644 --- a/Mage.Sets/src/mage/sets/magic2013/VileRebirth.java +++ b/Mage.Sets/src/mage/sets/magic2013/VileRebirth.java @@ -37,8 +37,6 @@ import mage.filter.common.FilterCreatureCard; import mage.game.permanent.token.ZombieToken; import mage.target.common.TargetCardInGraveyard; - - /** * * @author North @@ -49,13 +47,12 @@ public class VileRebirth extends CardImpl { super(ownerId, 115, "Vile Rebirth", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{B}"); this.expansionSetCode = "M13"; - // Exile target creature card from a graveyard. this.getSpellAbility().addEffect(new ExileTargetEffect()); this.getSpellAbility().addTarget(new TargetCardInGraveyard(new FilterCreatureCard("creature card from a graveyard"))); // Put a 2/2 black Zombie creature token onto the battlefield. - this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken("M13"))); + this.getSpellAbility().addEffect(new CreateTokenEffect(new ZombieToken())); } public VileRebirth(final VileRebirth card) { diff --git a/Mage.Sets/src/mage/sets/magic2014/BanisherPriest.java b/Mage.Sets/src/mage/sets/magic2014/BanisherPriest.java index 6f3baeec946..f907e0226d6 100644 --- a/Mage.Sets/src/mage/sets/magic2014/BanisherPriest.java +++ b/Mage.Sets/src/mage/sets/magic2014/BanisherPriest.java @@ -54,6 +54,7 @@ import mage.util.CardUtil; public class BanisherPriest extends CardImpl { private final static FilterCreaturePermanent filter = new FilterCreaturePermanent("creature an opponent controls"); + static { filter.add(new ControllerPredicate(TargetController.OPPONENT)); } @@ -106,7 +107,7 @@ class BanisherPriestExileEffect extends OneShotEffect { // If Banisher Priest leaves the battlefield before its triggered ability resolves, // the target creature won't be exiled. if (permanent != null) { - return new ExileTargetEffect(CardUtil.getExileZoneId(game, source.getSourceId(), source.getSourceObjectZoneChangeCounter()), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getExileZoneId(game, source.getSourceId(), source.getSourceObjectZoneChangeCounter()), permanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/magic2014/ColossalWhale.java b/Mage.Sets/src/mage/sets/magic2014/ColossalWhale.java index 187439dba28..1838807ab83 100644 --- a/Mage.Sets/src/mage/sets/magic2014/ColossalWhale.java +++ b/Mage.Sets/src/mage/sets/magic2014/ColossalWhale.java @@ -146,7 +146,7 @@ class ColossalWhaleExileEffect extends OneShotEffect { // If Whale leaves the battlefield before its triggered ability resolves, // the target creature won't be exiled. if (permanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/magic2014/DarkProphecy.java b/Mage.Sets/src/mage/sets/magic2014/DarkProphecy.java index 416208588f3..fcd3c1e9aa5 100644 --- a/Mage.Sets/src/mage/sets/magic2014/DarkProphecy.java +++ b/Mage.Sets/src/mage/sets/magic2014/DarkProphecy.java @@ -30,6 +30,7 @@ package mage.sets.magic2014; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.common.DiesCreatureTriggeredAbility; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.LoseLifeSourceControllerEffect; import mage.cards.CardImpl; @@ -55,9 +56,13 @@ public class DarkProphecy extends CardImpl { this.expansionSetCode = "M14"; - // Whenever a creature you control dies, you draw a card and lose 1 life. - Ability ability = new DiesCreatureTriggeredAbility(new DrawCardSourceControllerEffect(1), false, filter); - ability.addEffect(new LoseLifeSourceControllerEffect(1)); + // Whenever a creature you control dies, you draw a card and you lose 1 life. + Effect effect = new DrawCardSourceControllerEffect(1); + effect.setText("you draw a card"); + Ability ability = new DiesCreatureTriggeredAbility(effect, false, filter); + effect = new LoseLifeSourceControllerEffect(1); + effect.setText("and you lose 1 life"); + ability.addEffect(effect); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2014/DevoutInvocation.java b/Mage.Sets/src/mage/sets/magic2014/DevoutInvocation.java index 6e918f15df8..3f71b0c0a72 100644 --- a/Mage.Sets/src/mage/sets/magic2014/DevoutInvocation.java +++ b/Mage.Sets/src/mage/sets/magic2014/DevoutInvocation.java @@ -94,7 +94,7 @@ class DevoutInvocationEffect extends OneShotEffect { if (controller != null) { int tappedAmount = 0; TargetPermanent target = new TargetPermanent(0,1,filter, false); - while (true && controller.isInGame()) { + while (true && controller.canRespond()) { target.clearChosen(); if (target.canChoose(source.getControllerId(), game)) { Map options = new HashMap<>(); diff --git a/Mage.Sets/src/mage/sets/magic2014/DoorOfDestinies.java b/Mage.Sets/src/mage/sets/magic2014/DoorOfDestinies.java index 5cbd32e4098..95ef1ee6103 100644 --- a/Mage.Sets/src/mage/sets/magic2014/DoorOfDestinies.java +++ b/Mage.Sets/src/mage/sets/magic2014/DoorOfDestinies.java @@ -107,7 +107,7 @@ class ChooseCreatureTypeEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } @@ -155,7 +155,7 @@ class AddCounterAbility extends TriggeredAbilityImpl { filter.add(new ControllerPredicate(TargetController.YOU)); filter.add(new SubtypePredicate(subtype)); Spell spell = game.getStack().getSpell(event.getTargetId()); - if (spell != null && filter.match(spell, controllerId, game)) { + if (spell != null && filter.match(spell, getSourceId(), getControllerId(), game)) { return true; } } @@ -169,7 +169,6 @@ class AddCounterAbility extends TriggeredAbilityImpl { } } - class BoostCreatureEffectEffect extends ContinuousEffectImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent(); @@ -194,7 +193,7 @@ class BoostCreatureEffectEffect extends ContinuousEffectImpl { if (permanent != null) { String subtype = (String) game.getState().getValue(permanent.getId() + "_type"); if (subtype != null) { - for (Permanent perm: game.getBattlefield().getAllActivePermanents(filter, source.getControllerId(), game)) { + for (Permanent perm : game.getBattlefield().getAllActivePermanents(filter, source.getControllerId(), game)) { if (perm.hasSubtype(subtype)) { int boost = permanent.getCounters().getCount(CounterType.CHARGE); perm.addPower(boost); diff --git a/Mage.Sets/src/mage/sets/magic2014/GarrukCallerOfBeasts.java b/Mage.Sets/src/mage/sets/magic2014/GarrukCallerOfBeasts.java index a4fc59d7c98..6cf8ee79c45 100644 --- a/Mage.Sets/src/mage/sets/magic2014/GarrukCallerOfBeasts.java +++ b/Mage.Sets/src/mage/sets/magic2014/GarrukCallerOfBeasts.java @@ -34,12 +34,11 @@ import mage.abilities.LoyaltyAbility; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.common.SpellCastControllerTriggeredAbility; import mage.abilities.effects.Effect; -import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.GetEmblemEffect; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.abilities.effects.common.RevealLibraryPutIntoHandEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; @@ -50,11 +49,7 @@ import mage.filter.FilterSpell; import mage.filter.common.FilterCreatureCard; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.filter.predicate.mageobject.ColorPredicate; -import mage.game.Game; import mage.game.command.Emblem; -import mage.players.Player; -import mage.target.Target; -import mage.target.common.TargetCardInHand; import mage.target.common.TargetCardInLibrary; /** @@ -63,7 +58,8 @@ import mage.target.common.TargetCardInLibrary; */ public class GarrukCallerOfBeasts extends CardImpl { - private static final FilterCreatureCard filterGreenCreature = new FilterCreatureCard("a green creature card from your hand"); + private static final FilterCreatureCard filterGreenCreature = new FilterCreatureCard("a green creature card"); + static { filterGreenCreature.add(new ColorPredicate(ObjectColor.GREEN)); } @@ -80,7 +76,7 @@ public class GarrukCallerOfBeasts extends CardImpl { this.addAbility(new LoyaltyAbility(new RevealLibraryPutIntoHandEffect(5, new FilterCreatureCard("all creature cards"),true), 1)); // -3: You may put a green creature card from your hand onto the battlefield. - this.addAbility(new LoyaltyAbility(new GarrukCallerOfBeastsPutOntoBattlefieldEffect(), -3)); + this.addAbility(new LoyaltyAbility(new PutPermanentOnBattlefieldEffect(filterGreenCreature), -3)); // -7: You get an emblem with "Whenever you cast a creature spell, you may search your library for a creature card, put it onto the battlefield, then shuffle your library."); this.addAbility(new LoyaltyAbility(new GetEmblemEffect(new GarrukCallerOfBeastsEmblem()), -7)); @@ -96,6 +92,7 @@ public class GarrukCallerOfBeasts extends CardImpl { return new GarrukCallerOfBeasts(this); } } + /** * Emblem: "Whenever you cast a creature spell, you may search your library for a creature card, put it onto the battlefield, then shuffle your library." */ @@ -113,48 +110,3 @@ class GarrukCallerOfBeastsEmblem extends Emblem { this.getAbilities().add(ability); } } - -class GarrukCallerOfBeastsPutOntoBattlefieldEffect extends OneShotEffect { - - private static final FilterCreatureCard filterGreenCreature = new FilterCreatureCard("a green creature card from your hand"); - - static { - filterGreenCreature.add(new ColorPredicate(ObjectColor.GREEN)); - } - - public GarrukCallerOfBeastsPutOntoBattlefieldEffect() { - super(Outcome.PutCreatureInPlay); - this.staticText = "You may put a green creature card from your hand onto the battlefield"; - } - - public GarrukCallerOfBeastsPutOntoBattlefieldEffect(final GarrukCallerOfBeastsPutOntoBattlefieldEffect effect) { - super(effect); - } - - @Override - public GarrukCallerOfBeastsPutOntoBattlefieldEffect copy() { - return new GarrukCallerOfBeastsPutOntoBattlefieldEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - if (controller.getHand().count(filterGreenCreature, game) > 0) { - - if (controller.chooseUse(Outcome.PutCreatureInPlay, - "Put a green creature card onto the battlefield?", source, game)) { - Target target = new TargetCardInHand(filterGreenCreature); - if (controller.chooseTarget(outcome, target, source, game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } - } - } - } - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/magic2014/GrimReturn.java b/Mage.Sets/src/mage/sets/magic2014/GrimReturn.java index 0a93db0e9f8..ef9a63a835f 100644 --- a/Mage.Sets/src/mage/sets/magic2014/GrimReturn.java +++ b/Mage.Sets/src/mage/sets/magic2014/GrimReturn.java @@ -30,6 +30,7 @@ package mage.sets.magic2014; import java.util.ArrayList; import java.util.List; import java.util.UUID; +import mage.MageObjectReference; import mage.abilities.Ability; import mage.abilities.effects.Effect; import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect; @@ -56,7 +57,6 @@ public class GrimReturn extends CardImpl { super(ownerId, 100, "Grim Return", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{2}{B}"); this.expansionSetCode = "M14"; - // Choose target creature card in a graveyard that was put there from the battlefield this turn. Put that card onto the battlefield under your control. Effect effect = new ReturnFromGraveyardToBattlefieldTargetEffect(); effect.setText("Choose target creature card in a graveyard that was put there from the battlefield this turn. Put that card onto the battlefield under your control"); @@ -80,8 +80,10 @@ public class GrimReturn extends CardImpl { if (watcher != null) { FilterCard filter = new FilterCreatureCard(textFilter); List uuidPredicates = new ArrayList<>(); - for (UUID uuid :watcher.getCardsPutToGraveyardFromBattlefield()) { - uuidPredicates.add(new CardIdPredicate(uuid)); + for (MageObjectReference mor : watcher.getCardsPutToGraveyardFromBattlefield()) { + if (game.getState().getZoneChangeCounter(mor.getSourceId()) == mor.getZoneChangeCounter()) { + uuidPredicates.add(new CardIdPredicate(mor.getSourceId())); + } } filter.add(Predicates.or(uuidPredicates)); ability.getTargets().clear(); diff --git a/Mage.Sets/src/mage/sets/magic2014/IllusionaryArmor.java b/Mage.Sets/src/mage/sets/magic2014/IllusionaryArmor.java index 07129d69f2f..d536c5102cc 100644 --- a/Mage.Sets/src/mage/sets/magic2014/IllusionaryArmor.java +++ b/Mage.Sets/src/mage/sets/magic2014/IllusionaryArmor.java @@ -28,10 +28,10 @@ package mage.sets.magic2014; import java.util.UUID; -import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.BecomesTargetAttachedTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.DestroySourceEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; @@ -40,10 +40,6 @@ import mage.constants.Duration; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.game.permanent.Permanent; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -67,7 +63,7 @@ public class IllusionaryArmor extends CardImpl { // Enchanted creature gets +4/+4. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(4, 4, Duration.WhileOnBattlefield))); // When enchanted creature becomes the target of a spell or ability, sacrifice Illusionary Armor. - this.addAbility(new IllusionaryArmorAbility()); + this.addAbility(new BecomesTargetAttachedTriggeredAbility(new SacrificeSourceEffect())); } public IllusionaryArmor(final IllusionaryArmor card) { @@ -79,42 +75,3 @@ public class IllusionaryArmor extends CardImpl { return new IllusionaryArmor(this); } } - - -class IllusionaryArmorAbility extends TriggeredAbilityImpl { - - public IllusionaryArmorAbility() { - super(Zone.BATTLEFIELD, new DestroySourceEffect()); - } - - public IllusionaryArmorAbility(final IllusionaryArmorAbility ability) { - super(ability); - } - - @Override - public IllusionaryArmorAbility copy() { - return new IllusionaryArmorAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.TARGETED; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - Permanent enchantment = game.getPermanent(sourceId); - if (enchantment != null && enchantment.getAttachedTo() != null) { - if (event.getTargetId().equals(enchantment.getAttachedTo())) { - return true; - } - } - return false; - } - - @Override - public String getRule() { - return "When enchanted creature becomes the target of a spell or ability, destroy {this}."; - } - -} diff --git a/Mage.Sets/src/mage/sets/magic2014/JacesMindseeker.java b/Mage.Sets/src/mage/sets/magic2014/JacesMindseeker.java index bf8354a2869..9877bd2dfbc 100644 --- a/Mage.Sets/src/mage/sets/magic2014/JacesMindseeker.java +++ b/Mage.Sets/src/mage/sets/magic2014/JacesMindseeker.java @@ -27,7 +27,7 @@ */ package mage.sets.magic2014; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; @@ -66,7 +66,7 @@ public class JacesMindseeker extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); - // When Jace's Mindseeker enters the battlefield, target opponent puts the top five cards of his or her library into his or her graveyard. + // When Jace's Mindseeker enters the battlefield, target opponent puts the top five cards of his or her library into his or her graveyard. // You may cast an instant or sorcery card from among them without paying its mana cost. Ability ability = new EntersBattlefieldTriggeredAbility(new JaceMindseekerEffect()); ability.addTarget(new TargetOpponent()); @@ -106,17 +106,17 @@ class JaceMindseekerEffect extends OneShotEffect { Cards cardsToCast = new CardsImpl(); Player targetOpponent = game.getPlayer(targetPointer.getFirst(game, source)); if (targetOpponent != null) { - List allCards = targetOpponent.getLibrary().getTopCards(game, 5); + Set allCards = targetOpponent.getLibrary().getTopCards(game, 5); targetOpponent.moveCards(allCards, Zone.LIBRARY, Zone.GRAVEYARD, source, game); - for(Card card : allCards) { + for (Card card : allCards) { if (filter.match(card, game)) { Zone zone = game.getState().getZone(card.getId()); - // If the five cards are put into a public zone such as exile instead of a graveyard (perhaps due to the ability of Rest in Peace), - // you can cast one of those instant or sorcery cards from that zone. - if (zone.equals(Zone.GRAVEYARD) || zone.equals(Zone.EXILED)) { + // If the five cards are put into a public zone such as exile instead of a graveyard (perhaps due to the ability of Rest in Peace), + // you can cast one of those instant or sorcery cards from that zone. + if (zone.equals(Zone.GRAVEYARD) || zone.equals(Zone.EXILED)) { cardsToCast.add(card); } - } + } } } @@ -127,14 +127,14 @@ class JaceMindseekerEffect extends OneShotEffect { TargetCard target = new TargetCard(Zone.GRAVEYARD, filter); // zone should be ignored here target.setNotTarget(true); if (controller.chooseUse(outcome, "Cast an instant or sorcery card from among them for free?", source, game) - && controller.choose(outcome, cardsToCast, target, game)) { + && controller.choose(outcome, cardsToCast, target, game)) { Card card = cardsToCast.get(target.getFirstTarget(), game); if (card != null) { controller.cast(card.getSpellAbility(), game, true); } } } - + } return false; diff --git a/Mage.Sets/src/mage/sets/magic2014/LilianasReaver.java b/Mage.Sets/src/mage/sets/magic2014/LilianasReaver.java index 8e1cc16edf6..d2094078eb9 100644 --- a/Mage.Sets/src/mage/sets/magic2014/LilianasReaver.java +++ b/Mage.Sets/src/mage/sets/magic2014/LilianasReaver.java @@ -57,8 +57,8 @@ public class LilianasReaver extends CardImpl { this.addAbility(DeathtouchAbility.getInstance()); // Whenever Liliana's Reaver deals combat damage to a player, that player discards a card and you put a 2/2 black Zombie creature token onto the battlefield tapped. - Ability ability = new DealsCombatDamageToAPlayerTriggeredAbility(new DiscardTargetEffect(1),false, true); - ability.addEffect(new CreateTokenEffect(new ZombieToken("M14"), 1, true, false)); + Ability ability = new DealsCombatDamageToAPlayerTriggeredAbility(new DiscardTargetEffect(1), false, true); + ability.addEffect(new CreateTokenEffect(new ZombieToken(), 1, true, false)); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2014/ShadowbornDemon.java b/Mage.Sets/src/mage/sets/magic2014/ShadowbornDemon.java index 08eda6473f3..c81ad6839b1 100644 --- a/Mage.Sets/src/mage/sets/magic2014/ShadowbornDemon.java +++ b/Mage.Sets/src/mage/sets/magic2014/ShadowbornDemon.java @@ -30,14 +30,13 @@ package mage.sets.magic2014; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.TriggeredAbility; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.condition.Condition; import mage.abilities.condition.InvertCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.DestroyTargetEffect; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.constants.CardType; @@ -50,7 +49,6 @@ import mage.filter.predicate.mageobject.SubtypePredicate; import mage.game.Game; import mage.players.Player; import mage.target.Target; -import mage.target.common.TargetControlledCreaturePermanent; import mage.target.common.TargetCreaturePermanent; /** @@ -60,6 +58,7 @@ import mage.target.common.TargetCreaturePermanent; public class ShadowbornDemon extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("non-Demon creature"); + static { filter.add(Predicates.not(new SubtypePredicate("Demon"))); } @@ -75,17 +74,14 @@ public class ShadowbornDemon extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); // When Shadowborn Demon enters the battlefield, destroy target non-Demon creature. - Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect(),false); + Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect(), false); Target target = new TargetCreaturePermanent(filter); ability.addTarget(target); this.addAbility(ability); + // At the beginning of your upkeep, if there are fewer than six creature cards in your graveyard, sacrifice a creature. - TriggeredAbility triggeredAbility = new BeginningOfUpkeepTriggeredAbility(new SacrificeTargetEffect(), TargetController.YOU, false); - target = new TargetControlledCreaturePermanent(); - target.setNotTarget(false); - triggeredAbility.addTarget(target); this.addAbility(new ConditionalTriggeredAbility( - triggeredAbility, + new BeginningOfUpkeepTriggeredAbility(new SacrificeControllerEffect(new FilterCreaturePermanent(), 1, ""), TargetController.YOU, false), new InvertCondition(new CreatureCardsInControllerGraveCondition(6)), "At the beginning of your upkeep, if there are fewer than six creature cards in your graveyard, sacrifice a creature")); @@ -102,6 +98,7 @@ public class ShadowbornDemon extends CardImpl { } class CreatureCardsInControllerGraveCondition implements Condition { + private int value; public CreatureCardsInControllerGraveCondition(int value) { @@ -111,10 +108,9 @@ class CreatureCardsInControllerGraveCondition implements Condition { @Override public boolean apply(Game game, Ability source) { Player p = game.getPlayer(source.getControllerId()); - if (p != null && p.getGraveyard().count(new FilterCreatureCard(), game) >= value) - { - return true; + if (p != null && p.getGraveyard().count(new FilterCreatureCard(), game) >= value) { + return true; } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magic2014/XathridNecromancer.java b/Mage.Sets/src/mage/sets/magic2014/XathridNecromancer.java index 32b7487ad92..cb5fd961888 100644 --- a/Mage.Sets/src/mage/sets/magic2014/XathridNecromancer.java +++ b/Mage.Sets/src/mage/sets/magic2014/XathridNecromancer.java @@ -49,6 +49,7 @@ import mage.game.permanent.token.ZombieToken; public class XathridNecromancer extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Human creature you control"); + static { filter.add(new ControllerPredicate(TargetController.YOU)); filter.add(new SubtypePredicate("Human")); @@ -64,7 +65,7 @@ public class XathridNecromancer extends CardImpl { this.toughness = new MageInt(2); // Whenever Xathrid Necromancer or another Human creature you control dies, put a 2/2 black Zombie creature token onto the battlefield tapped. - Effect effect = new CreateTokenEffect(new ZombieToken("M14"), 1, true, false); + Effect effect = new CreateTokenEffect(new ZombieToken(), 1, true, false); Ability ability = new DiesThisOrAnotherCreatureTriggeredAbility(effect, false, filter); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/magic2015/AEtherspouts.java b/Mage.Sets/src/mage/sets/magic2015/AEtherspouts.java index c0590adff87..eeff32b8b5c 100644 --- a/Mage.Sets/src/mage/sets/magic2015/AEtherspouts.java +++ b/Mage.Sets/src/mage/sets/magic2015/AEtherspouts.java @@ -135,7 +135,7 @@ class AEtherspoutsEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.BATTLEFIELD, new FilterCard("order to put on the top of library (last choosen will be the top most)")); while (cards.size() > 1) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } player.choose(Outcome.Neutral, cards, target, game); @@ -174,7 +174,7 @@ class AEtherspoutsEffect extends OneShotEffect { } } target = new TargetCard(Zone.BATTLEFIELD, new FilterCard("order to put on bottom of library (last choosen will be bottommost card)")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); @@ -199,7 +199,7 @@ class AEtherspoutsEffect extends OneShotEffect { player.moveCardToLibraryWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD, false, false); } player = playerList.getNext(game); - } while (player != null && !player.getId().equals(game.getActivePlayerId()) && activePlayer.isInGame()); + } while (player != null && !player.getId().equals(game.getActivePlayerId()) && activePlayer.canRespond()); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/magic2015/ConstrictingSliver.java b/Mage.Sets/src/mage/sets/magic2015/ConstrictingSliver.java index 5e2e5682c94..e16e2afde9e 100644 --- a/Mage.Sets/src/mage/sets/magic2015/ConstrictingSliver.java +++ b/Mage.Sets/src/mage/sets/magic2015/ConstrictingSliver.java @@ -64,7 +64,6 @@ public class ConstrictingSliver extends CardImpl { filterTarget.add(new ControllerPredicate(TargetController.OPPONENT)); } - public ConstrictingSliver(UUID ownerId) { super(ownerId, 7, "Constricting Sliver", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{5}{W}"); this.expansionSetCode = "M15"; @@ -73,15 +72,15 @@ public class ConstrictingSliver extends CardImpl { this.power = new MageInt(3); this.toughness = new MageInt(3); - // Sliver creatures you control have "When this creature enters the battlefield, you may exile target creature an opponent controls + // Sliver creatures you control have "When this creature enters the battlefield, you may exile target creature an opponent controls // until this creature leaves the battlefield." Ability ability = new EntersBattlefieldTriggeredAbility(new ConstrictingSliverExileEffect(), true); ability.addTarget(new TargetCreaturePermanent(filterTarget)); ability.addEffect(new CreateDelayedTriggeredAbilityEffect(new OnLeaveReturnExiledToBattlefieldAbility())); this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(ability, - Duration.WhileOnBattlefield, new FilterControlledCreaturePermanent("Sliver","Sliver creatures"), - "Sliver creatures you control have \"When this creature enters the battlefield, you may exile target creature an opponent controls until this creature leaves the battlefield.\""))); + Duration.WhileOnBattlefield, new FilterControlledCreaturePermanent("Sliver", "Sliver creatures"), + "Sliver creatures you control have \"When this creature enters the battlefield, you may exile target creature an opponent controls until this creature leaves the battlefield.\""))); } @@ -117,7 +116,7 @@ class ConstrictingSliverExileEffect extends OneShotEffect { // If the creature leaves the battlefield before its triggered ability resolves, // the target creature won't be exiled. if (permanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/magic2015/FeralIncarnation.java b/Mage.Sets/src/mage/sets/magic2015/FeralIncarnation.java index 0123ea48b26..2f4d8900e7f 100644 --- a/Mage.Sets/src/mage/sets/magic2015/FeralIncarnation.java +++ b/Mage.Sets/src/mage/sets/magic2015/FeralIncarnation.java @@ -45,11 +45,10 @@ public class FeralIncarnation extends CardImpl { super(ownerId, 174, "Feral Incarnation", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{8}{G}"); this.expansionSetCode = "M15"; - // Convoke this.addAbility(new ConvokeAbility()); // Put three 3/3 green Beast creature tokens onto the battlefield. - this.getSpellAbility().addEffect(new CreateTokenEffect(new BeastToken("M15", 1), 3)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new BeastToken(), 3)); } public FeralIncarnation(final FeralIncarnation card) { diff --git a/Mage.Sets/src/mage/sets/magic2015/FirstResponse.java b/Mage.Sets/src/mage/sets/magic2015/FirstResponse.java index 87dc7ad335c..f83349340d7 100644 --- a/Mage.Sets/src/mage/sets/magic2015/FirstResponse.java +++ b/Mage.Sets/src/mage/sets/magic2015/FirstResponse.java @@ -51,7 +51,6 @@ public class FirstResponse extends CardImpl { super(ownerId, 12, "First Response", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}"); this.expansionSetCode = "M15"; - // At the beginning of each upkeep, if you lost life last turn, put a 1/1 white Soldier creature token onto the battlefield. this.addAbility(new BeginningOfUpkeepTriggeredAbility(new FirstResponseEffect(), TargetController.ANY, false), new PlayerLostLifeWatcher()); @@ -88,7 +87,7 @@ class FirstResponseEffect extends OneShotEffect { PlayerLostLifeWatcher watcher = (PlayerLostLifeWatcher) game.getState().getWatchers().get("PlayerLostLifeWatcher"); if (watcher != null) { if (watcher.getLiveLostLastTurn(source.getControllerId()) > 0) { - return new CreateTokenEffect(new SoldierToken("M15")).apply(game, source); + return new CreateTokenEffect(new SoldierToken()).apply(game, source); } return true; } diff --git a/Mage.Sets/src/mage/sets/magic2015/GarrukApexPredator.java b/Mage.Sets/src/mage/sets/magic2015/GarrukApexPredator.java index 7bcaa7023c1..955c9019f01 100644 --- a/Mage.Sets/src/mage/sets/magic2015/GarrukApexPredator.java +++ b/Mage.Sets/src/mage/sets/magic2015/GarrukApexPredator.java @@ -81,7 +81,6 @@ public class GarrukApexPredator extends CardImpl { this.expansionSetCode = "M15"; this.subtype.add("Garruk"); - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(5)), false)); // +1: Destroy another target planeswalker. @@ -100,7 +99,9 @@ public class GarrukApexPredator extends CardImpl { this.addAbility(ability); // -8: Target opponent gets an emblem with "Whenever a creature attacks you, it gets +5/+5 and gains trample until end of turn." - ability = new LoyaltyAbility(new GetEmblemTargetPlayerEffect(new GarrukApexPredatorEmblem()), -8); + Effect effect = new GetEmblemTargetPlayerEffect(new GarrukApexPredatorEmblem()); + effect.setText("Target opponent gets an emblem with \"Whenever a creature attacks you, it gets +5/+5 and gains trample until end of turn.\""); + ability = new LoyaltyAbility(effect, -8); ability.addTarget(new TargetOpponent()); this.addAbility(ability); } @@ -148,7 +149,7 @@ class GarrukApexPredatorBeastToken extends Token { public GarrukApexPredatorBeastToken() { super("Beast", "3/3 black Beast creature token with deathtouch"); setOriginalExpansionSetCode("M15"); - setTokenType(2); + setTokenType(1); cardType.add(CardType.CREATURE); color.setBlack(true); subtype.add("Beast"); @@ -162,13 +163,14 @@ class GarrukApexPredatorBeastToken extends Token { } /** - * Emblem with "Whenever a creature attacks you, it gets +5/+5 and gains trample until end of turn." + * Emblem with "Whenever a creature attacks you, it gets +5/+5 and gains trample + * until end of turn." */ class GarrukApexPredatorEmblem extends Emblem { public GarrukApexPredatorEmblem() { setName("EMBLEM: Garruk, Apex Predator"); - Effect effect = new BoostTargetEffect(5,5,Duration.EndOfTurn); + Effect effect = new BoostTargetEffect(5, 5, Duration.EndOfTurn); effect.setText("it gets +5/+5"); Ability ability = new AttackedByCreatureTriggeredAbility(Zone.COMMAND, effect, false, SetTargetPointer.PERMANENT); effect = new GainAbilityTargetEffect(TrampleAbility.getInstance(), Duration.EndOfTurn, @@ -176,4 +178,4 @@ class GarrukApexPredatorEmblem extends Emblem { ability.addEffect(effect); this.getAbilities().add(ability); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magic2015/HushwingGryff.java b/Mage.Sets/src/mage/sets/magic2015/HushwingGryff.java index 3cbc4aba1c6..c644c080918 100644 --- a/Mage.Sets/src/mage/sets/magic2015/HushwingGryff.java +++ b/Mage.Sets/src/mage/sets/magic2015/HushwingGryff.java @@ -98,28 +98,23 @@ class HushwingGryffEffect extends ContinuousRuleModifyingEffectImpl { } return null; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.ENTERS_THE_BATTLEFIELD; } - @Override + @Override public boolean applies(GameEvent event, Ability source, Game game) { Ability ability = (Ability) getValue("targetAbility"); if (ability != null && AbilityType.TRIGGERED.equals(ability.getAbilityType())) { - Permanent p = game.getPermanent(event.getTargetId()); - if (p != null && p.getCardType().contains(CardType.CREATURE)) { + Permanent permanent = game.getPermanent(event.getTargetId()); + if (permanent != null && permanent.getCardType().contains(CardType.CREATURE)) { return true; } } return false; } - - @Override - public boolean apply(Game game, Ability source) { - return true; - } @Override public HushwingGryffEffect copy() { diff --git a/Mage.Sets/src/mage/sets/magic2015/NecromancersStockpile.java b/Mage.Sets/src/mage/sets/magic2015/NecromancersStockpile.java index c3f5a323e46..51af6f7dedf 100644 --- a/Mage.Sets/src/mage/sets/magic2015/NecromancersStockpile.java +++ b/Mage.Sets/src/mage/sets/magic2015/NecromancersStockpile.java @@ -27,6 +27,7 @@ */ package mage.sets.magic2015; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.CostImpl; @@ -47,8 +48,6 @@ import mage.game.permanent.token.ZombieToken; import mage.players.Player; import mage.target.common.TargetCardInHand; -import java.util.UUID; - /** * @author noxx */ @@ -60,7 +59,6 @@ public class NecromancersStockpile extends CardImpl { super(ownerId, 108, "Necromancer's Stockpile", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); this.expansionSetCode = "M15"; - // {1}{B}, Discard a creature card: Draw a card. // If the discarded card was a Zombie card, put a 2/2 black Zombie creature token onto the battlefield tapped. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{1}{B}")); @@ -97,7 +95,7 @@ class NecromancersStockpileDiscardTargetCost extends CostImpl { public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { if (targets.choose(Outcome.Discard, controllerId, sourceId, game)) { Player player = game.getPlayer(controllerId); - for (UUID targetId: targets.get(0).getTargets()) { + for (UUID targetId : targets.get(0).getTargets()) { Card card = player.getHand().get(targetId, game); if (card == null) { return false; @@ -127,6 +125,7 @@ class NecromancersStockpileDiscardTargetCost extends CostImpl { } class NecromancersStockpilePutTokenEffect extends OneShotEffect { + NecromancersStockpilePutTokenEffect() { super(Outcome.Neutral); staticText = "If the discarded card was a Zombie card, put a 2/2 black Zombie creature token onto the battlefield tapped"; @@ -140,7 +139,7 @@ class NecromancersStockpilePutTokenEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { NecromancersStockpileDiscardTargetCost cost = (NecromancersStockpileDiscardTargetCost) source.getCosts().get(0); if (cost != null && cost.isZombieCard()) { - new CreateTokenEffect(new ZombieToken("M15"), 1, true, false).apply(game, source); + new CreateTokenEffect(new ZombieToken(), 1, true, false).apply(game, source); } return true; } @@ -150,4 +149,3 @@ class NecromancersStockpilePutTokenEffect extends OneShotEffect { return new NecromancersStockpilePutTokenEffect(this); } } - diff --git a/Mage.Sets/src/mage/sets/magic2015/ObeliskOfUrd.java b/Mage.Sets/src/mage/sets/magic2015/ObeliskOfUrd.java index 4b7687d0e3f..d4a6c4f3a15 100644 --- a/Mage.Sets/src/mage/sets/magic2015/ObeliskOfUrd.java +++ b/Mage.Sets/src/mage/sets/magic2015/ObeliskOfUrd.java @@ -106,7 +106,7 @@ class ObeliskOfUrdEnterBattlefieldEffect extends OneShotEffect { typeChoice.setMessage("Choose a creature type:"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/magic2015/Quickling.java b/Mage.Sets/src/mage/sets/magic2015/Quickling.java index 21d407e9e75..569c612cf4b 100644 --- a/Mage.Sets/src/mage/sets/magic2015/Quickling.java +++ b/Mage.Sets/src/mage/sets/magic2015/Quickling.java @@ -79,6 +79,7 @@ public class Quickling extends CardImpl { return new Quickling(this); } } + class QuicklingEffect extends OneShotEffect { private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("another creature you control"); @@ -88,12 +89,12 @@ class QuicklingEffect extends OneShotEffect { filter.add(new AnotherPredicate()); } - QuicklingEffect ( ) { + QuicklingEffect() { super(Outcome.ReturnToHand); staticText = effectText; } - QuicklingEffect ( QuicklingEffect effect ) { + QuicklingEffect(QuicklingEffect effect) { super(effect); } @@ -106,13 +107,13 @@ class QuicklingEffect extends OneShotEffect { if (target.canChoose(controller.getId(), game) && controller.chooseUse(outcome, "Return another creature you control to its owner's hand?", source, game)) { controller.chooseTarget(Outcome.ReturnToHand, target, source, game); Permanent permanent = game.getPermanent(target.getFirstTarget()); - if ( permanent != null ) { + if (permanent != null) { targetChosen = true; - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(permanent, null, Zone.HAND, source, game); } } - if ( !targetChosen ) { + if (!targetChosen) { new SacrificeSourceEffect().apply(game, source); } return true; diff --git a/Mage.Sets/src/mage/sets/magic2015/ScuttlingDoomEngine.java b/Mage.Sets/src/mage/sets/magic2015/ScuttlingDoomEngine.java index 9372ebf2010..8cbfe7e7b42 100644 --- a/Mage.Sets/src/mage/sets/magic2015/ScuttlingDoomEngine.java +++ b/Mage.Sets/src/mage/sets/magic2015/ScuttlingDoomEngine.java @@ -31,14 +31,13 @@ import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.DiesTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.Filter; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.PowerPredicate; @@ -49,14 +48,15 @@ import mage.target.common.TargetOpponent; * @author emerald000 */ public class ScuttlingDoomEngine extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures with power 2 or less"); + static { filter.add(new PowerPredicate(Filter.ComparisonType.LessThan, 3)); } public ScuttlingDoomEngine(UUID ownerId) { - + super(ownerId, 229, "Scuttling Doom Engine", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{6}"); this.expansionSetCode = "M15"; this.subtype.add("Construct"); @@ -65,7 +65,7 @@ public class ScuttlingDoomEngine extends CardImpl { this.toughness = new MageInt(6); // Scuttling Doom Engine can't be blocked by creatures with power 2 or less. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); // When Scuttling Doom Engine dies, it deals 6 damage to target opponnent Ability ability = new DiesTriggeredAbility(new DamageTargetEffect(6), false); ability.addTarget(new TargetOpponent()); diff --git a/Mage.Sets/src/mage/sets/magic2015/SoulOfZendikar.java b/Mage.Sets/src/mage/sets/magic2015/SoulOfZendikar.java index 7c09f0eb7c4..09593c16223 100644 --- a/Mage.Sets/src/mage/sets/magic2015/SoulOfZendikar.java +++ b/Mage.Sets/src/mage/sets/magic2015/SoulOfZendikar.java @@ -58,9 +58,9 @@ public class SoulOfZendikar extends CardImpl { // Reach this.addAbility(ReachAbility.getInstance()); // {3}{G}{G}: Put a 3/3 green Beast creature token onto the battlefield. - this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new BeastToken("M15")), new ManaCostsImpl("{3}{G}{G}"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new BeastToken()), new ManaCostsImpl("{3}{G}{G}"))); // {3}{G}{G}, Exile Soul of Zendikar from your graveyard: Put a 3/3 green Beast creature token onto the battlefield. - Ability ability = new SimpleActivatedAbility(Zone.GRAVEYARD, new CreateTokenEffect(new BeastToken("M15")), new ManaCostsImpl("{3}{G}{G}")); + Ability ability = new SimpleActivatedAbility(Zone.GRAVEYARD, new CreateTokenEffect(new BeastToken()), new ManaCostsImpl("{3}{G}{G}")); ability.addCost(new ExileSourceFromGraveCost()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magic2015/StainTheMind.java b/Mage.Sets/src/mage/sets/magic2015/StainTheMind.java index cb50105e033..804ef524c2f 100644 --- a/Mage.Sets/src/mage/sets/magic2015/StainTheMind.java +++ b/Mage.Sets/src/mage/sets/magic2015/StainTheMind.java @@ -92,7 +92,7 @@ class StainTheMindEffect extends SearchTargetGraveyardHandLibraryForCardNameAndE cardChoice.setMessage("Name a nonland card"); while (!controller.choose(Outcome.Exile, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/magic2015/WasteNot.java b/Mage.Sets/src/mage/sets/magic2015/WasteNot.java index 4fba77c7a41..ed5690362ef 100644 --- a/Mage.Sets/src/mage/sets/magic2015/WasteNot.java +++ b/Mage.Sets/src/mage/sets/magic2015/WasteNot.java @@ -53,13 +53,12 @@ public class WasteNot extends CardImpl { super(ownerId, 122, "Waste Not", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); this.expansionSetCode = "M15"; - // Whenever an opponent discards a creature card, put a 2/2 black Zombie creature token onto the battlefield. this.addAbility(new WasteNotCreatureTriggeredAbility()); - + // Whenever an opponent discards a land card, add {B}{B} to your mana pool. this.addAbility(new WasteNotLandTriggeredAbility()); - + // Whenever an opponent discards a noncreature, nonland card, draw a card. this.addAbility(new WasteNotOtherTriggeredAbility()); } @@ -75,15 +74,15 @@ public class WasteNot extends CardImpl { } class WasteNotCreatureTriggeredAbility extends TriggeredAbilityImpl { - + WasteNotCreatureTriggeredAbility() { - super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken("M15")), false); + super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken()), false); } - + WasteNotCreatureTriggeredAbility(final WasteNotCreatureTriggeredAbility ability) { super(ability); } - + @Override public WasteNotCreatureTriggeredAbility copy() { return new WasteNotCreatureTriggeredAbility(this); @@ -93,7 +92,7 @@ class WasteNotCreatureTriggeredAbility extends TriggeredAbilityImpl { public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DISCARDED_CARD; } - + @Override public boolean checkTrigger(GameEvent event, Game game) { if (game.getOpponents(this.getControllerId()).contains(event.getPlayerId())) { @@ -104,7 +103,7 @@ class WasteNotCreatureTriggeredAbility extends TriggeredAbilityImpl { } return false; } - + @Override public String getRule() { return "Whenever an opponent discards a creature card, put a 2/2 black Zombie creature token onto the battlefield."; @@ -112,15 +111,15 @@ class WasteNotCreatureTriggeredAbility extends TriggeredAbilityImpl { } class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl { - + WasteNotLandTriggeredAbility() { super(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 2, 0, 0)), false); } - + WasteNotLandTriggeredAbility(final WasteNotLandTriggeredAbility ability) { super(ability); } - + @Override public WasteNotLandTriggeredAbility copy() { return new WasteNotLandTriggeredAbility(this); @@ -130,7 +129,7 @@ class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl { public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DISCARDED_CARD; } - + @Override public boolean checkTrigger(GameEvent event, Game game) { if (game.getOpponents(this.getControllerId()).contains(event.getPlayerId())) { @@ -141,7 +140,7 @@ class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl { } return false; } - + @Override public String getRule() { return "Whenever an opponent discards a land card, add {B}{B} to your mana pool."; @@ -149,15 +148,15 @@ class WasteNotLandTriggeredAbility extends TriggeredAbilityImpl { } class WasteNotOtherTriggeredAbility extends TriggeredAbilityImpl { - + WasteNotOtherTriggeredAbility() { super(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), false); } - + WasteNotOtherTriggeredAbility(final WasteNotOtherTriggeredAbility ability) { super(ability); } - + @Override public WasteNotOtherTriggeredAbility copy() { return new WasteNotOtherTriggeredAbility(this); @@ -167,7 +166,7 @@ class WasteNotOtherTriggeredAbility extends TriggeredAbilityImpl { public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DISCARDED_CARD; } - + @Override public boolean checkTrigger(GameEvent event, Game game) { if (game.getOpponents(this.getControllerId()).contains(event.getPlayerId())) { @@ -178,9 +177,9 @@ class WasteNotOtherTriggeredAbility extends TriggeredAbilityImpl { } return false; } - + @Override public String getRule() { return "Whenever an opponent discards a noncreature, nonland card, draw a card."; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/ArtificersEpiphany.java b/Mage.Sets/src/mage/sets/magicorigins/ArtificersEpiphany.java index dc5b68d353f..cab1d89f252 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/ArtificersEpiphany.java +++ b/Mage.Sets/src/mage/sets/magicorigins/ArtificersEpiphany.java @@ -44,8 +44,8 @@ import mage.filter.predicate.mageobject.CardTypePredicate; * @author fireshoes */ public class ArtificersEpiphany extends CardImpl { - - private static final FilterControlledPermanent filter = new FilterControlledPermanent("artifacts"); + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("you control no artifacts"); static { filter.add(new CardTypePredicate(CardType.ARTIFACT)); diff --git a/Mage.Sets/src/mage/sets/magicorigins/AspiringAeronaut.java b/Mage.Sets/src/mage/sets/magicorigins/AspiringAeronaut.java index 4af2005c389..c05f943cc9a 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/AspiringAeronaut.java +++ b/Mage.Sets/src/mage/sets/magicorigins/AspiringAeronaut.java @@ -53,9 +53,9 @@ public class AspiringAeronaut extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); - + // When Aspiring Aeronaut enters the battlefield, put a 1/1 colorless Thopter artifact creature token with flying onto the battlefield. - this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken("ORI")))); + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken()))); } public AspiringAeronaut(final AspiringAeronaut card) { diff --git a/Mage.Sets/src/mage/sets/magicorigins/BloodCursedKnight.java b/Mage.Sets/src/mage/sets/magicorigins/BloodCursedKnight.java index fb33c0423cb..c7c9fee158a 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/BloodCursedKnight.java +++ b/Mage.Sets/src/mage/sets/magicorigins/BloodCursedKnight.java @@ -29,6 +29,7 @@ package mage.sets.magicorigins; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; import mage.abilities.decorator.ConditionalContinuousEffect; @@ -47,9 +48,9 @@ import mage.filter.common.FilterControlledEnchantmentPermanent; * @author fireshoes */ public class BloodCursedKnight extends CardImpl { - - final static private String rule1 = "{this} gets +1/+1 as long as you control an enchantment"; - final static private String rule2 = "{this} has lifelink as long as you control an enchantment"; + + final static private String rule1 = "As long as you control an enchantment, {this} gets +1/+1"; + final static private String rule2 = "and has lifelink"; public BloodCursedKnight(UUID ownerId) { super(ownerId, 211, "Blood-Cursed Knight", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W}{B}"); @@ -60,10 +61,14 @@ public class BloodCursedKnight extends CardImpl { this.toughness = new MageInt(2); // As long as you control an enchantment, Blood-Cursed Knight gets +1/+1 and has lifelink. - ConditionalContinuousEffect effect1 = new ConditionalContinuousEffect(new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), new PermanentsOnTheBattlefieldCondition(new FilterControlledEnchantmentPermanent()), rule1); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect1)); - ConditionalContinuousEffect effect2 = new ConditionalContinuousEffect(new GainAbilitySourceEffect(LifelinkAbility.getInstance(), Duration.WhileOnBattlefield), new PermanentsOnTheBattlefieldCondition(new FilterControlledEnchantmentPermanent()), rule2); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect2)); + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, + new ConditionalContinuousEffect( + new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), + new PermanentsOnTheBattlefieldCondition(new FilterControlledEnchantmentPermanent()), rule1)); + ability.addEffect(new ConditionalContinuousEffect( + new GainAbilitySourceEffect(LifelinkAbility.getInstance(), Duration.WhileOnBattlefield), + new PermanentsOnTheBattlefieldCondition(new FilterControlledEnchantmentPermanent()), rule2)); + this.addAbility(ability); } public BloodCursedKnight(final BloodCursedKnight card) { diff --git a/Mage.Sets/src/mage/sets/magicorigins/DaysUndoing.java b/Mage.Sets/src/mage/sets/magicorigins/DaysUndoing.java index 6f576a90b9e..a77cbe2b199 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/DaysUndoing.java +++ b/Mage.Sets/src/mage/sets/magicorigins/DaysUndoing.java @@ -81,25 +81,26 @@ class DaysUndoingEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Player sourcePlayer = game.getPlayer(source.getControllerId()); - for (UUID playerId: sourcePlayer.getInRange()) { + for (UUID playerId : sourcePlayer.getInRange()) { Player player = game.getPlayer(playerId); if (player != null) { - for (Card card: player.getHand().getCards(game)) { + for (Card card : player.getHand().getCards(game)) { card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); } - for (Card card: player.getGraveyard().getCards(game)) { + for (Card card : player.getGraveyard().getCards(game)) { card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); } + game.informPlayers(player.getLogName() + " puts his or her hand and graveyard into his or her library"); player.shuffleLibrary(game); - + } } - game.getState().handleSimultaneousEvent(game); // needed here so state based triggered effects - for (UUID playerId: sourcePlayer.getInRange()) { + game.getState().handleSimultaneousEvent(game); // needed here so state based triggered effects + for (UUID playerId : sourcePlayer.getInRange()) { Player player = game.getPlayer(playerId); if (player != null) { player.drawCards(7, game); - } + } } return true; } @@ -109,4 +110,4 @@ class DaysUndoingEffect extends OneShotEffect { return new DaysUndoingEffect(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/ElementalBond.java b/Mage.Sets/src/mage/sets/magicorigins/ElementalBond.java index 4c0b67a0c3f..c0f1d5fbbda 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/ElementalBond.java +++ b/Mage.Sets/src/mage/sets/magicorigins/ElementalBond.java @@ -43,8 +43,9 @@ import mage.filter.predicate.mageobject.PowerPredicate; * @author emerald000 */ public class ElementalBond extends CardImpl { - - private static final FilterPermanent filter = new FilterControlledCreaturePermanent("creature with power 3 or greater"); + + private static final FilterPermanent filter = new FilterControlledCreaturePermanent("a creature with power 3 or greater"); + static { filter.add(new PowerPredicate(ComparisonType.GreaterThan, 2)); } diff --git a/Mage.Sets/src/mage/sets/magicorigins/EmbermawHellion.java b/Mage.Sets/src/mage/sets/magicorigins/EmbermawHellion.java index 5632b9cfcf4..05c357c6bbe 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/EmbermawHellion.java +++ b/Mage.Sets/src/mage/sets/magicorigins/EmbermawHellion.java @@ -29,11 +29,11 @@ package mage.sets.magicorigins; import java.util.UUID; import mage.MageInt; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ReplacementEffectImpl; import mage.abilities.keyword.TrampleAbility; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; @@ -44,6 +44,7 @@ import mage.game.Game; import mage.game.events.DamagedPlayerEvent; import mage.game.events.GameEvent.EventType; import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; /** * @@ -101,11 +102,19 @@ class EmbermawHellionEffect extends ReplacementEffectImpl { @Override public boolean applies(GameEvent event, Ability source, Game game) { if(source.getControllerId().equals(game.getControllerId(event.getSourceId()))) { - Card card = game.getCard(event.getSourceId()); - return card != null && card.getColor(game).isRed() && !card.getId().equals(source.getSourceId()); + MageObject sourceObject; + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(event.getSourceId()); + if(sourcePermanent == null) { + sourceObject = game.getObject(event.getSourceId()); + } + else { + sourceObject = sourcePermanent; + } + return sourceObject != null && sourceObject.getColor(game).isRed() && !sourceObject.getId().equals(source.getSourceId()); } return false; } + @Override public boolean apply(Game game, Ability source) { return true; diff --git a/Mage.Sets/src/mage/sets/magicorigins/FieryConclusion.java b/Mage.Sets/src/mage/sets/magicorigins/FieryConclusion.java index b0e9b90f317..cf262b2af5c 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/FieryConclusion.java +++ b/Mage.Sets/src/mage/sets/magicorigins/FieryConclusion.java @@ -28,6 +28,7 @@ package mage.sets.magicorigins; import java.util.UUID; +import mage.constants.Rarity; /** * @@ -39,6 +40,7 @@ public class FieryConclusion extends mage.sets.ravnica.FieryConclusion { super(ownerId); this.cardNumber = 144; this.expansionSetCode = "ORI"; + this.rarity = Rarity.UNCOMMON; } public FieryConclusion(final FieryConclusion card) { diff --git a/Mage.Sets/src/mage/sets/magicorigins/FoundryOfTheConsuls.java b/Mage.Sets/src/mage/sets/magicorigins/FoundryOfTheConsuls.java index 954e9edf44c..d6b8561812d 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/FoundryOfTheConsuls.java +++ b/Mage.Sets/src/mage/sets/magicorigins/FoundryOfTheConsuls.java @@ -44,7 +44,7 @@ import mage.game.permanent.token.ThopterColorlessToken; /** * * @author LoneFox - + * */ public class FoundryOfTheConsuls extends CardImpl { @@ -55,8 +55,8 @@ public class FoundryOfTheConsuls extends CardImpl { // {T}: Add {1} to your mana pool. this.addAbility(new ColorlessManaAbility()); // {5}, {T}, Sacrifice Foundry of the Consuls: Put two 1/1 colorless Thopter artifact creature tokens with flying onto the battlefield. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ThopterColorlessToken("ORI"), 2), - new ManaCostsImpl("{5}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new ThopterColorlessToken(), 2), + new ManaCostsImpl("{5}")); ability.addCost(new TapSourceCost()); ability.addCost(new SacrificeSourceCost()); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/magicorigins/GatherThePack.java b/Mage.Sets/src/mage/sets/magicorigins/GatherThePack.java index 31888fd17a7..c6087d29b07 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/GatherThePack.java +++ b/Mage.Sets/src/mage/sets/magicorigins/GatherThePack.java @@ -31,7 +31,6 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.condition.common.SpellMasteryCondition; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; @@ -98,10 +97,10 @@ class GatherThePackEffect extends OneShotEffect { } TargetCard target = new TargetCard(0, max, Zone.LIBRARY, new FilterCreatureCard("creature card" + (max > 1 ? "s" : "") + " to put into your hand")); if (controller.choose(Outcome.PutCreatureInPlay, cards, target, game)) { - Card card = cards.get(target.getFirstTarget(), game); - if (card != null) { - cards.remove(card); - controller.moveCards(card, Zone.LIBRARY, Zone.HAND, source, game); + Cards cardsToHand = new CardsImpl(target.getTargets()); + if (cardsToHand.size() > 0) { + cards.removeAll(cardsToHand); + controller.moveCards(cardsToHand, Zone.LIBRARY, Zone.HAND, source, game); } } } diff --git a/Mage.Sets/src/mage/sets/magicorigins/GideonsPhalanx.java b/Mage.Sets/src/mage/sets/magicorigins/GideonsPhalanx.java index fe0af645a1a..58afd8bc82e 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/GideonsPhalanx.java +++ b/Mage.Sets/src/mage/sets/magicorigins/GideonsPhalanx.java @@ -79,7 +79,7 @@ public class GideonsPhalanx extends CardImpl { class GideonsPhalanxKnightToken extends Token { public GideonsPhalanxKnightToken() { - super("Soldier", "2/2 white Knight creature tokens with vigilance"); + super("Knight", "2/2 white Knight creature tokens with vigilance"); this.setOriginalExpansionSetCode("ORI"); cardType.add(CardType.CREATURE); color.setColor(ObjectColor.WHITE); diff --git a/Mage.Sets/src/mage/sets/magicorigins/HangarbackWalker.java b/Mage.Sets/src/mage/sets/magicorigins/HangarbackWalker.java index 025ce206117..6a1aa70c7c5 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/HangarbackWalker.java +++ b/Mage.Sets/src/mage/sets/magicorigins/HangarbackWalker.java @@ -66,10 +66,10 @@ public class HangarbackWalker extends CardImpl { // Hangarback Walker enters the battlefield with X +1/+1 counters on it. this.addAbility(new EntersBattlefieldAbility(new HangarbackWalkerEffect(), "with X +1/+1 counters on it")); - + // When Hangarback Walker dies, put a 1/1 colorless Thopter artifact creature token with flying onto the battlefield for each +1/+1 counter on Hangarback Walker. - this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken("ORI"), new CountersCount(CounterType.P1P1)), false)); - + this.addAbility(new DiesTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken(), new CountersCount(CounterType.P1P1)), false)); + // {1}, {t}: Put a +1/+1 counter on Hangarback Walker. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.P1P1.createInstance()), new GenericManaCost(1)); ability.addCost(new TapSourceCost()); @@ -88,33 +88,33 @@ public class HangarbackWalker extends CardImpl { class HangarbackWalkerEffect extends OneShotEffect { - public HangarbackWalkerEffect() { - super(Outcome.BoostCreature); - staticText = "{this} enters the battlefield with X +1/+1 counters on it"; - } + public HangarbackWalkerEffect() { + super(Outcome.BoostCreature); + staticText = "{this} enters the battlefield with X +1/+1 counters on it"; + } - public HangarbackWalkerEffect(final HangarbackWalkerEffect effect) { - super(effect); - } + public HangarbackWalkerEffect(final HangarbackWalkerEffect effect) { + super(effect); + } - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null) { - Object obj = getValue(EntersBattlefieldEffect.SOURCE_CAST_SPELL_ABILITY); - if (obj != null && obj instanceof SpellAbility) { - int amount = ((SpellAbility)obj).getManaCostsToPay().getX(); - if (amount > 0) { - permanent.addCounters(CounterType.P1P1.createInstance(amount), game); - } + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + Object obj = getValue(EntersBattlefieldEffect.SOURCE_CAST_SPELL_ABILITY); + if (obj != null && obj instanceof SpellAbility) { + int amount = ((SpellAbility) obj).getManaCostsToPay().getX(); + if (amount > 0) { + permanent.addCounters(CounterType.P1P1.createInstance(amount), game); } } - return true; } + return true; + } - @Override - public HangarbackWalkerEffect copy() { - return new HangarbackWalkerEffect(this); - } + @Override + public HangarbackWalkerEffect copy() { + return new HangarbackWalkerEffect(this); + } - } \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/InfiniteObliteration.java b/Mage.Sets/src/mage/sets/magicorigins/InfiniteObliteration.java index 3c432dcc1b6..030db436a14 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/InfiniteObliteration.java +++ b/Mage.Sets/src/mage/sets/magicorigins/InfiniteObliteration.java @@ -90,7 +90,7 @@ class InfiniteObliterationEffect extends SearchTargetGraveyardHandLibraryForCard cardChoice.setMessage("Name a creature card"); while (!controller.choose(Outcome.Exile, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/magicorigins/JaceTelepathUnbound.java b/Mage.Sets/src/mage/sets/magicorigins/JaceTelepathUnbound.java index 968cc70af62..32b4489ce85 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/JaceTelepathUnbound.java +++ b/Mage.Sets/src/mage/sets/magicorigins/JaceTelepathUnbound.java @@ -50,6 +50,7 @@ import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.counters.CounterType; +import mage.filter.FilterSpell; import mage.filter.common.FilterInstantOrSorceryCard; import mage.game.Game; import mage.game.command.Emblem; @@ -72,13 +73,16 @@ public class JaceTelepathUnbound extends CardImpl { this.expansionSetCode = "ORI"; this.subtype.add("Jace"); + this.color.setBlue(true); this.nightCard = true; this.canTransform = true; this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(5)), false)); // +1: Up to one target creature gets -2/-0 until your next turn. - Ability ability = new LoyaltyAbility(new BoostTargetEffect(-2, 0, Duration.UntilYourNextTurn), 1); + Effect effect = new BoostTargetEffect(-2, 0, Duration.UntilYourNextTurn); + effect.setText("Up to one target creature gets -2/-0 until your next turn"); + Ability ability = new LoyaltyAbility(effect, 1); ability.addTarget(new TargetCreaturePermanent(0, 1)); this.addAbility(ability); @@ -205,12 +209,11 @@ class JaceTelepathUnboundReplacementEffect extends ReplacementEffectImpl { class JaceTelepathUnboundEmblem extends Emblem { // You get an emblem with "Whenever you cast a spell, target opponent puts the top five cards of his or her library into his or her graveyard". - public JaceTelepathUnboundEmblem() { this.setName("Emblem - Jace"); Effect effect = new PutTopCardOfLibraryIntoGraveTargetEffect(5); effect.setText("target opponent puts the top five cards of his or her library into his or her graveyard"); - Ability ability = new SpellCastControllerTriggeredAbility(effect, false); + Ability ability = new SpellCastControllerTriggeredAbility(Zone.COMMAND, effect, new FilterSpell("a spell"), false, false); ability.addTarget(new TargetOpponent()); getAbilities().add(ability); } diff --git a/Mage.Sets/src/mage/sets/magicorigins/LilianaDefiantNecromancer.java b/Mage.Sets/src/mage/sets/magicorigins/LilianaDefiantNecromancer.java index 13f59c35e1a..68e4320e8b6 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/LilianaDefiantNecromancer.java +++ b/Mage.Sets/src/mage/sets/magicorigins/LilianaDefiantNecromancer.java @@ -139,7 +139,8 @@ class LilianaDefiantNecromancerEmblem extends Emblem { // You get an emblem with "Whenever a creature you control dies, return it to the battlefield under your control at the beginning of the next end step." public LilianaDefiantNecromancerEmblem() { this.setName("Emblem - Liliana"); - this.getAbilities().add(new DiesCreatureTriggeredAbility(new LilianaDefiantNecromancerEmblemEffect(), false, filter, true)); + Ability ability = new DiesCreatureTriggeredAbility(Zone.COMMAND, new LilianaDefiantNecromancerEmblemEffect(), false, filter, true); + this.getAbilities().add(ability); } } @@ -164,7 +165,7 @@ class LilianaDefiantNecromancerEmblemEffect extends OneShotEffect { Card card = game.getCard(getTargetPointer().getFirst(game, source)); if (card != null) { Effect effect = new ReturnFromGraveyardToBattlefieldTargetEffect(); - effect.setTargetPointer(new FixedTarget(card.getId())); + effect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); effect.setText("return that card to the battlefield at the beginning of the next end step"); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(Zone.COMMAND, effect, TargetController.ANY); delayedAbility.setSourceId(source.getSourceId()); diff --git a/Mage.Sets/src/mage/sets/magicorigins/LilianaHereticalHealer.java b/Mage.Sets/src/mage/sets/magicorigins/LilianaHereticalHealer.java index a3a6bc156b0..265fa04b4e9 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/LilianaHereticalHealer.java +++ b/Mage.Sets/src/mage/sets/magicorigins/LilianaHereticalHealer.java @@ -77,7 +77,7 @@ public class LilianaHereticalHealer extends CardImpl { // Whenever another nontoken creature you control dies, exile Liliana Heretical Healer, then return her to the battlefield transformed under her owner's control. If you do, put a 2/2 black Zombie creature token onto the battlefield. this.addAbility(new DiesCreatureTriggeredAbility(new ExileAndReturnTransformedSourceEffect(ExileAndReturnTransformedSourceEffect.Gender.FEMAL, - new CreateTokenEffect(new ZombieToken(expansionSetCode))), false, filter)); + new CreateTokenEffect(new ZombieToken())), false, filter)); } public LilianaHereticalHealer(final LilianaHereticalHealer card) { diff --git a/Mage.Sets/src/mage/sets/magicorigins/MageRingNetwork.java b/Mage.Sets/src/mage/sets/magicorigins/MageRingNetwork.java index 6ee273ea26e..fe953e08e6d 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/MageRingNetwork.java +++ b/Mage.Sets/src/mage/sets/magicorigins/MageRingNetwork.java @@ -34,6 +34,7 @@ import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.ColorlessManaAbility; @@ -47,7 +48,7 @@ import mage.counters.CounterType; /** * * @author LoneFox - + * */ public class MageRingNetwork extends CardImpl { @@ -55,17 +56,22 @@ public class MageRingNetwork extends CardImpl { super(ownerId, 249, "Mage-Ring Network", Rarity.UNCOMMON, new CardType[]{CardType.LAND}, ""); this.expansionSetCode = "ORI"; - // {t}: Add {1} to your mana pool. + // {T}: Add {1} to your mana pool. this.addAbility(new ColorlessManaAbility()); - // {1}, {t}: Put a storage counter on Mage-Ring Network. + // {1}, {T}: Put a storage counter on Mage-Ring Network. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), - new ManaCostsImpl("{1}")); + new ManaCostsImpl("{1}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); - // {t}, Remove X storage counters from Mage-Ring Network: Add {x} to your mana pool. - ability = new DynamicManaAbility(Mana.ColorlessMana, new RemovedCountersForCostValue(), "Add {X} to your mana pool"); + // {T}, Remove X storage counters from Mage-Ring Network: Add {x} to your mana pool. + ability = new DynamicManaAbility( + Mana.ColorlessMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {X} to your mana pool", + true, new CountersCount(CounterType.STORAGE)); ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), - "Remove X storage counters from {this}")); + "Remove X storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/magicorigins/NecromanticSummons.java b/Mage.Sets/src/mage/sets/magicorigins/NecromanticSummons.java index b8bcb491aa1..1c4a58253cb 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/NecromanticSummons.java +++ b/Mage.Sets/src/mage/sets/magicorigins/NecromanticSummons.java @@ -57,10 +57,10 @@ public class NecromanticSummons extends CardImpl { // Put target creature card from a graveyard onto the battlefield under your control. this.getSpellAbility().addEffect(new ReturnFromGraveyardToBattlefieldTargetEffect()); this.getSpellAbility().addTarget(new TargetCardInGraveyard(new FilterCreatureCard("creature card from a graveyard"))); - + // Spell mastery - If there are two or more instant and/or sorcery cards in your graveyard, that creature enters the battlefield with two additional +1/+1 counters on it. Effect effect = new ConditionalOneShotEffect(new NecromanticSummoningEffect(), - SpellMasteryCondition.getInstance(), "
Spell mastery - If there are two or more instant and/or sorcery cards in your graveyard, add {B}{B}{B} to your mana pool"); + SpellMasteryCondition.getInstance(), "
Spell mastery - If there are two or more instant and/or sorcery cards in your graveyard, that creature enters the battlefield with two additional +1/+1 counters on it"); this.getSpellAbility().addEffect(effect); } @@ -99,4 +99,4 @@ class NecromanticSummoningEffect extends OneShotEffect { } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/NissaSageAnimist.java b/Mage.Sets/src/mage/sets/magicorigins/NissaSageAnimist.java index ff93fac4615..7959cf7f6b3 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/NissaSageAnimist.java +++ b/Mage.Sets/src/mage/sets/magicorigins/NissaSageAnimist.java @@ -65,10 +65,9 @@ public class NissaSageAnimist extends CardImpl { this.expansionSetCode = "ORI"; this.subtype.add("Nissa"); this.color.setGreen(true); - + this.nightCard = true; - this.canTransform = true; - + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(3)), false)); // +1: Reveal the top card of your library. If it's a land card, put it onto the battlefield. Otherwise, put it into your hand. @@ -95,21 +94,21 @@ public class NissaSageAnimist extends CardImpl { } class NissaSageAnimistPlusOneEffect extends OneShotEffect { - + NissaSageAnimistPlusOneEffect() { super(Outcome.Benefit); this.staticText = "Reveal the top card of your library. If it's a land card, put it onto the battlefield. Otherwise, put it into your hand."; } - + NissaSageAnimistPlusOneEffect(final NissaSageAnimistPlusOneEffect effect) { super(effect); } - + @Override public NissaSageAnimistPlusOneEffect copy() { return new NissaSageAnimistPlusOneEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -195,4 +194,4 @@ class NissaSageAnimistMinusSevenEffect extends ContinuousEffectImpl { public boolean hasLayer(Layer layer) { return layer == Layer.TypeChangingEffects_4 || layer == Layer.PTChangingEffects_7; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/OrbsOfWarding.java b/Mage.Sets/src/mage/sets/magicorigins/OrbsOfWarding.java index a244007d356..fc6732b14ce 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/OrbsOfWarding.java +++ b/Mage.Sets/src/mage/sets/magicorigins/OrbsOfWarding.java @@ -89,7 +89,7 @@ class OrbsOfWardingEffect extends PreventionEffectImpl { public boolean applies(GameEvent event, Ability source, Game game) { if (event.getTargetId().equals(source.getControllerId())) { Permanent permanent = game.getPermanentOrLKIBattlefield(event.getSourceId()); - if (permanent.getCardType().contains(CardType.CREATURE)) { + if (permanent != null && permanent.getCardType().contains(CardType.CREATURE)) { return super.applies(event, source, game); } } diff --git a/Mage.Sets/src/mage/sets/magicorigins/PiaAndKiranNalaar.java b/Mage.Sets/src/mage/sets/magicorigins/PiaAndKiranNalaar.java index f6e8eff77fe..a0d055231c0 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/PiaAndKiranNalaar.java +++ b/Mage.Sets/src/mage/sets/magicorigins/PiaAndKiranNalaar.java @@ -61,11 +61,11 @@ public class PiaAndKiranNalaar extends CardImpl { this.toughness = new MageInt(2); // When Pia and Kiran Nalaar enters the battlefield put 2 1/1 colorless Thopter artifact creature tokens with flying onto the battlefield. - this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken("ORI"), 2))); - + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ThopterColorlessToken(), 2))); + // {2}{R}, Sacrifice an artifact: Pia and Kiran Nalaar deals 2 damage to target creature or player. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), new ManaCostsImpl("{2}{R}")); - ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(1,1, new FilterControlledArtifactPermanent("an artifact"),true))); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(1, 1, new FilterControlledArtifactPermanent("an artifact"), true))); ability.addTarget(new TargetCreatureOrPlayer()); this.addAbility(ability); } @@ -78,4 +78,4 @@ public class PiaAndKiranNalaar extends CardImpl { public PiaAndKiranNalaar copy() { return new PiaAndKiranNalaar(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/PriestOfTheBloodRite.java b/Mage.Sets/src/mage/sets/magicorigins/PriestOfTheBloodRite.java index f57eaaa2614..6eed42819e2 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/PriestOfTheBloodRite.java +++ b/Mage.Sets/src/mage/sets/magicorigins/PriestOfTheBloodRite.java @@ -56,7 +56,7 @@ public class PriestOfTheBloodRite extends CardImpl { // When Priest of the Blood Rite enters the battlefield, put a 5/5 black Demon creature token with flying onto the battlefield. this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new DemonToken()))); - + // At the beginning of your upkeep, you lose 2 life. this.addAbility(new BeginningOfUpkeepTriggeredAbility(new LoseLifeSourceControllerEffect(2), TargetController.YOU, false)); } @@ -77,6 +77,7 @@ class DemonToken extends Token { super("Demon", "5/5 black Demon creature token with flying"); cardType.add(CardType.CREATURE); subtype.add("Demon"); + setOriginalExpansionSetCode("ORI"); color.setBlack(true); power = new MageInt(5); @@ -84,4 +85,4 @@ class DemonToken extends Token { addAbility(FlyingAbility.getInstance()); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/PyromancersGoggles.java b/Mage.Sets/src/mage/sets/magicorigins/PyromancersGoggles.java index f9729a180dd..02e4590a04b 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/PyromancersGoggles.java +++ b/Mage.Sets/src/mage/sets/magicorigins/PyromancersGoggles.java @@ -112,7 +112,7 @@ class PyromancersGogglesTriggeredAbility extends TriggeredAbilityImpl { public boolean checkTrigger(GameEvent event, Game game) { if (event.getData().equals(abilityOriginalId)) { Spell spell = game.getStack().getSpell(event.getTargetId()); - if (spell != null && filter.match(spell, getControllerId(), game)) { + if (spell != null && filter.match(spell, getSourceId(), getControllerId(), game)) { for (Effect effect : getEffects()) { effect.setTargetPointer(new FixedTarget(event.getTargetId())); } diff --git a/Mage.Sets/src/mage/sets/magicorigins/RavagingBlaze.java b/Mage.Sets/src/mage/sets/magicorigins/RavagingBlaze.java index 15d9672c16f..a22d8aa8feb 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/RavagingBlaze.java +++ b/Mage.Sets/src/mage/sets/magicorigins/RavagingBlaze.java @@ -28,16 +28,14 @@ package mage.sets.magicorigins; import java.util.UUID; -import mage.abilities.Ability; import mage.abilities.condition.common.SpellMasteryCondition; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.effects.common.DamageTargetControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.common.TargetCreaturePermanent; /** @@ -50,10 +48,12 @@ public class RavagingBlaze extends CardImpl { super(ownerId, 159, "Ravaging Blaze", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{X}{R}{R}"); this.expansionSetCode = "ORI"; - // Ravaging Blaze deals X damage to target creature. - // Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, Ravaging Blaze also deals X damage to that creature's controller. - this.getSpellAbility().addEffect(new RavagingBlazeEffect()); + // Ravaging Blaze deals X damage to target creature. + this.getSpellAbility().addEffect(new DamageTargetEffect(new ManacostVariableValue())); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + // Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, Ravaging Blaze also deals X damage to that creature's controller. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DamageTargetControllerEffect(new ManacostVariableValue()), + SpellMasteryCondition.getInstance(), "
Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, Ravaging Blaze also deals X damage to that creature's controller.")); } public RavagingBlaze(final RavagingBlaze card) { @@ -65,41 +65,3 @@ public class RavagingBlaze extends CardImpl { return new RavagingBlaze(this); } } - -class RavagingBlazeEffect extends OneShotEffect { - - public RavagingBlazeEffect() { - super(Outcome.Damage); - staticText = "{this} deals X damage to target creature.
" - + "Spell mastery — If there are two or more instant and/or sorcery cards in your graveyard, {this} also deals X damage to that creature's controller."; - } - - public RavagingBlazeEffect(final RavagingBlazeEffect effect) { - super(effect); - } - - @Override - public RavagingBlazeEffect copy() { - return new RavagingBlazeEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(getTargetPointer().getFirst(game, source)); - if (permanent != null) { - int xValue = source.getManaCostsToPay().getX(); - if (xValue > 0) { - permanent.damage(xValue, source.getSourceId(), game, false, true); - if (SpellMasteryCondition.getInstance().apply(game, source)) { - Player targetController = game.getPlayer(permanent.getControllerId()); - if (targetController != null) { - targetController.damage(xValue, source.getSourceId(), game, false, true); - } - } - } - return true; - } - return false; - } - -} diff --git a/Mage.Sets/src/mage/sets/magicorigins/SigilOfValor.java b/Mage.Sets/src/mage/sets/magicorigins/SigilOfValor.java index 4dc297988ff..bc849bbcf50 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/SigilOfValor.java +++ b/Mage.Sets/src/mage/sets/magicorigins/SigilOfValor.java @@ -101,10 +101,14 @@ class SigilOfValorTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - if (game.getActivePlayerId().equals(this.controllerId)) { + if (game.getActivePlayerId().equals(getControllerId())) { if (game.getCombat().attacksAlone()) { - this.getEffects().get(0).setTargetPointer(new FixedTarget(game.getCombat().getAttackers().get(0))); - return true; + Permanent equipment = game.getPermanent(getSourceId()); + UUID attackerId = game.getCombat().getAttackers().get(0); + if (equipment != null && equipment.getAttachedTo() == attackerId) { + this.getEffects().get(0).setTargetPointer(new FixedTarget(attackerId)); + return true; + } } } return false; diff --git a/Mage.Sets/src/mage/sets/magicorigins/SphinxsTutelage.java b/Mage.Sets/src/mage/sets/magicorigins/SphinxsTutelage.java index 7e75184c2d9..b97b16398ba 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/SphinxsTutelage.java +++ b/Mage.Sets/src/mage/sets/magicorigins/SphinxsTutelage.java @@ -121,7 +121,7 @@ class SphinxsTutelageEffect extends OneShotEffect { } } targetPlayer.moveCards(cards, Zone.LIBRARY, Zone.GRAVEYARD, source, game); - } while (colorShared && targetPlayer.isInGame()); + } while (colorShared && targetPlayer.canRespond()); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/magicorigins/TalentOfTheTelepath.java b/Mage.Sets/src/mage/sets/magicorigins/TalentOfTheTelepath.java index 9094d046dcb..3ece67c3790 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/TalentOfTheTelepath.java +++ b/Mage.Sets/src/mage/sets/magicorigins/TalentOfTheTelepath.java @@ -27,7 +27,7 @@ */ package mage.sets.magicorigins; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; @@ -100,7 +100,7 @@ class TalentOfTheTelepathEffect extends OneShotEffect { Player targetOpponent = game.getPlayer(targetPointer.getFirst(game, source)); MageObject sourceObject = source.getSourceObject(game); if (targetOpponent != null && sourceObject != null) { - List allCards = targetOpponent.getLibrary().getTopCards(game, 7); + Set allCards = targetOpponent.getLibrary().getTopCards(game, 7); Cards cards = new CardsImpl(Zone.LIBRARY, allCards); targetOpponent.revealCards(sourceObject.getIdName() + " - " + targetOpponent.getName() + "'s top library cards", cards, game); for (Card card : allCards) { @@ -130,7 +130,7 @@ class TalentOfTheTelepathEffect extends OneShotEffect { cardsToCast.remove(card); allCards.remove(card); } - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } target.clearChosen(); diff --git a/Mage.Sets/src/mage/sets/magicorigins/TheGreatAurora.java b/Mage.Sets/src/mage/sets/magicorigins/TheGreatAurora.java index 4b9654bfcf8..dd5b0b2a6ca 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/TheGreatAurora.java +++ b/Mage.Sets/src/mage/sets/magicorigins/TheGreatAurora.java @@ -99,9 +99,9 @@ class TheGreatAuroraEffect extends OneShotEffect { List list = permanentsOwned.get(permanent.getOwnerId()); if (list == null) { list = new ArrayList<>(); + permanentsOwned.put(permanent.getOwnerId(), list); } list.add(permanent); - permanentsOwned.put(permanent.getOwnerId(), list); } // shuffle permanents and hand cards into owner's library @@ -115,13 +115,13 @@ class TheGreatAuroraEffect extends OneShotEffect { List list = permanentsOwned.remove(player.getId()); permanentsCount.put(playerId, handCards + (list != null ? list.size() : 0)); for (Permanent permanent : list) { - permanent.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); + player.moveCardToLibraryWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD, true, true); } player.getLibrary().shuffle(); } } - // Draw cards + // Draw cards for (UUID playerId : game.getState().getPlayersInRange(source.getControllerId(), game)) { Player player = game.getPlayer(playerId); if (player != null) { @@ -141,7 +141,7 @@ class TheGreatAuroraEffect extends OneShotEffect { for (UUID cardId : target.getTargets()) { Card card = game.getCard(cardId); if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId(), true); + player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId(), false); } } diff --git a/Mage.Sets/src/mage/sets/magicorigins/ThopterSpyNetwork.java b/Mage.Sets/src/mage/sets/magicorigins/ThopterSpyNetwork.java index d5df94f6bc4..b56f9b7c0d9 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/ThopterSpyNetwork.java +++ b/Mage.Sets/src/mage/sets/magicorigins/ThopterSpyNetwork.java @@ -56,7 +56,7 @@ public class ThopterSpyNetwork extends CardImpl { // At the beginning of your upkeep, if you control an artifact, put a 1/1 colorless Thopter artifact creature token with flying onto the battlefield. this.addAbility(new ThopterSpyNetworkUpkeepTriggeredAbility()); - + // Whenever one or more artifact creatures you control deals combat damage to a player, draw a card. this.addAbility(new ThopterSpyNetworkDamageTriggeredAbility()); } @@ -74,7 +74,7 @@ public class ThopterSpyNetwork extends CardImpl { class ThopterSpyNetworkUpkeepTriggeredAbility extends TriggeredAbilityImpl { public ThopterSpyNetworkUpkeepTriggeredAbility() { - super(Zone.BATTLEFIELD, new CreateTokenEffect(new ThopterColorlessToken("ORI"), 1), false); + super(Zone.BATTLEFIELD, new CreateTokenEffect(new ThopterColorlessToken(), 1), false); } public ThopterSpyNetworkUpkeepTriggeredAbility(final ThopterSpyNetworkUpkeepTriggeredAbility ability) { @@ -98,7 +98,7 @@ class ThopterSpyNetworkUpkeepTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkInterveningIfClause(Game game) { - return game.getBattlefield().countAll(new FilterArtifactPermanent(), this.controllerId, game) >= 1; + return game.getBattlefield().countAll(new FilterArtifactPermanent(), this.controllerId, game) >= 1; } @Override @@ -108,7 +108,7 @@ class ThopterSpyNetworkUpkeepTriggeredAbility extends TriggeredAbilityImpl { } class ThopterSpyNetworkDamageTriggeredAbility extends TriggeredAbilityImpl { - + List damagedPlayerIds = new ArrayList<>(); public ThopterSpyNetworkDamageTriggeredAbility() { @@ -127,7 +127,7 @@ class ThopterSpyNetworkDamageTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.DAMAGED_PLAYER - || event.getType() == GameEvent.EventType.END_COMBAT_STEP_POST; + || event.getType() == GameEvent.EventType.END_COMBAT_STEP_POST; } @Override @@ -135,14 +135,14 @@ class ThopterSpyNetworkDamageTriggeredAbility extends TriggeredAbilityImpl { if (event.getType() == GameEvent.EventType.DAMAGED_PLAYER) { if (((DamagedPlayerEvent) event).isCombatDamage()) { Permanent creature = game.getPermanent(event.getSourceId()); - if (creature != null && creature.getControllerId().equals(controllerId) - && creature.getCardType().contains(CardType.ARTIFACT) && !damagedPlayerIds.contains(event.getTargetId())) { - damagedPlayerIds.add(event.getTargetId()); - return true; + if (creature != null && creature.getControllerId().equals(controllerId) + && creature.getCardType().contains(CardType.ARTIFACT) && !damagedPlayerIds.contains(event.getTargetId())) { + damagedPlayerIds.add(event.getTargetId()); + return true; } } } - if (event.getType().equals(GameEvent.EventType.END_COMBAT_STEP_POST)){ + if (event.getType().equals(GameEvent.EventType.END_COMBAT_STEP_POST)) { damagedPlayerIds.clear(); } return false; @@ -152,4 +152,4 @@ class ThopterSpyNetworkDamageTriggeredAbility extends TriggeredAbilityImpl { public String getRule() { return "Whenever one or more artifact creatures you control deals combat damage to a player, draw a card"; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/magicorigins/TouchOfMoonglove.java b/Mage.Sets/src/mage/sets/magicorigins/TouchOfMoonglove.java index b5faf222d09..07c52503d96 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/TouchOfMoonglove.java +++ b/Mage.Sets/src/mage/sets/magicorigins/TouchOfMoonglove.java @@ -69,7 +69,6 @@ public class TouchOfMoonglove extends CardImpl { DeathtouchAbility.getInstance(), Duration.EndOfTurn, "and gains deathtouch until end of turn")); this.getSpellAbility().addTarget(new TargetControlledCreaturePermanent()); // Whenever a creature dealt damage by that creature this turn dies, its controller loses 2 life. - // this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(null)); this.getSpellAbility().addEffect(new TouchOfMoongloveAddTriggerEffect()); } @@ -119,7 +118,7 @@ class TouchOfMoongloveDelayedTriggeredAbility extends DelayedTriggeredAbility { private final MageObjectReference creatureToCheck; public TouchOfMoongloveDelayedTriggeredAbility(MageObjectReference creatureToCheck) { - super(new DamageTargetEffect(2), Duration.EndOfTurn); + super(new DamageTargetEffect(2), Duration.EndOfTurn, false); this.creatureToCheck = creatureToCheck; } diff --git a/Mage.Sets/src/mage/sets/magicorigins/UndeadServant.java b/Mage.Sets/src/mage/sets/magicorigins/UndeadServant.java index de8bbce4967..559d0248210 100644 --- a/Mage.Sets/src/mage/sets/magicorigins/UndeadServant.java +++ b/Mage.Sets/src/mage/sets/magicorigins/UndeadServant.java @@ -59,7 +59,7 @@ public class UndeadServant extends CardImpl { this.toughness = new MageInt(2); // When Undead Servant enters the battlefield, put a 2/2 black Zombie creature token onto the battlefield for each card named Undead Servant in your graveyard. - this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken(expansionSetCode), new CardsInControllerGraveyardCount(filter)))); + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken(), new CardsInControllerGraveyardCount(filter)))); } public UndeadServant(final UndeadServant card) { diff --git a/Mage.Sets/src/mage/sets/mastersedition/BaronSengir.java b/Mage.Sets/src/mage/sets/mastersedition/BaronSengir.java new file mode 100644 index 00000000000..b18a14d8f97 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/BaronSengir.java @@ -0,0 +1,90 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DiesAndDealtDamageThisTurnTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.RegenerateTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class BaronSengir extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("another Vampire"); + + static { + filter.add(new SubtypePredicate("Vampire")); + filter.add(new AnotherPredicate()); + } + + public BaronSengir(UUID ownerId) { + super(ownerId, 58, "Baron Sengir", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{B}{B}{B}"); + this.expansionSetCode = "MED"; + this.supertype.add("Legendary"); + this.subtype.add("Vampire"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Whenever a creature dealt damage by Baron Sengir this turn dies, put a +2/+2 counter on Baron Sengir. + this.addAbility(new DiesAndDealtDamageThisTurnTriggeredAbility(new AddCountersSourceEffect(CounterType.P2P2.createInstance()), false)); + + // {tap}: Regenerate another target Vampire. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateTargetEffect(), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent(1, 1, filter, true)); + this.addAbility(ability); + } + + public BaronSengir(final BaronSengir card) { + super(card); + } + + @Override + public BaronSengir copy() { + return new BaronSengir(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/FeastOrFamine.java b/Mage.Sets/src/mage/sets/mastersedition/FeastOrFamine.java new file mode 100644 index 00000000000..3111226a3e8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/FeastOrFamine.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class FeastOrFamine extends mage.sets.izzetvsgolgari.FeastOrFamine { + + public FeastOrFamine(UUID ownerId) { + super(ownerId); + this.cardNumber = 70; + this.expansionSetCode = "MED"; + } + + public FeastOrFamine(final FeastOrFamine card) { + super(card); + } + + @Override + public FeastOrFamine copy() { + return new FeastOrFamine(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/GoblinsOfTheFlarg.java b/Mage.Sets/src/mage/sets/mastersedition/GoblinsOfTheFlarg.java new file mode 100644 index 00000000000..0fa43306c59 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/GoblinsOfTheFlarg.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class GoblinsOfTheFlarg extends mage.sets.thedark.GoblinsOfTheFlarg { + + public GoblinsOfTheFlarg(UUID ownerId) { + super(ownerId); + this.cardNumber = 98; + this.expansionSetCode = "MED"; + } + + public GoblinsOfTheFlarg(final GoblinsOfTheFlarg card) { + super(card); + } + + @Override + public GoblinsOfTheFlarg copy() { + return new GoblinsOfTheFlarg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/IfhBiffEfreet.java b/Mage.Sets/src/mage/sets/mastersedition/IfhBiffEfreet.java new file mode 100644 index 00000000000..1b657394d49 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/IfhBiffEfreet.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageAllEffect; +import mage.abilities.effects.common.DamagePlayersEffect; +import mage.abilities.effects.common.InfoEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.AbilityPredicate; + +/** + * + * @author fireshoes + */ +public class IfhBiffEfreet extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying"); + + static { + filter.add(new AbilityPredicate(FlyingAbility.class)); + } + + public IfhBiffEfreet(UUID ownerId) { + super(ownerId, 123, "Ifh-Biff Efreet", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); + this.expansionSetCode = "MED"; + this.subtype.add("Efreet"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {G}: Ifh-Biff Efreet deals 1 damage to each creature with flying and each player. Any player may activate this ability. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageAllEffect(1, filter), new ManaCostsImpl("{G}")); + Effect effect = new DamagePlayersEffect(1); + effect.setText("and each player"); + ability.addEffect(effect); + ability.setMayActivate(TargetController.ANY); + ability.addEffect(new InfoEffect("Any player may activate this ability")); + this.addAbility(ability); + } + + public IfhBiffEfreet(final IfhBiffEfreet card) { + super(card); + } + + @Override + public IfhBiffEfreet copy() { + return new IfhBiffEfreet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/PhyrexianWarBeast.java b/Mage.Sets/src/mage/sets/mastersedition/PhyrexianWarBeast.java new file mode 100644 index 00000000000..cfc764e03a9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/PhyrexianWarBeast.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class PhyrexianWarBeast extends mage.sets.alliances.PhyrexianWarBeast1 { + + public PhyrexianWarBeast(UUID ownerId) { + super(ownerId); + this.cardNumber = 162; + this.expansionSetCode = "MED"; + this.rarity = Rarity.UNCOMMON; + } + + public PhyrexianWarBeast(final PhyrexianWarBeast card) { + super(card); + } + + @Override + public PhyrexianWarBeast copy() { + return new PhyrexianWarBeast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/RainbowVale.java b/Mage.Sets/src/mage/sets/mastersedition/RainbowVale.java new file mode 100644 index 00000000000..4cc33020179 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/RainbowVale.java @@ -0,0 +1,160 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.mana.AnyColorManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.Target; +import mage.target.common.TargetOpponent; + +/** + * + * @author andyfries + */ +public class RainbowVale extends CardImpl { + + public RainbowVale(UUID ownerId) { + super(ownerId, 179, "Rainbow Vale", Rarity.RARE, new CardType[]{CardType.LAND}, ""); + this.expansionSetCode = "MED"; + + // {tap}: Add one mana of any color to your mana pool. An opponent gains control of Rainbow Vale at the beginning of the next end step. + Ability ability = new AnyColorManaAbility(); + ability.addEffect(new RainbowValeEffect()); + this.addAbility(ability); + } + + public RainbowVale(final RainbowVale card) { + super(card); + } + + @Override + public RainbowVale copy() { + return new RainbowVale(this); + } + + class RainbowValeEffect extends OneShotEffect { + + public RainbowValeEffect() { + super(Outcome.PutManaInPool); + staticText = "An opponent gains control of {this} at the beginning of the next end step."; + } + + public RainbowValeEffect(final RainbowValeEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(new OpponentGainControlEffect()); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + return true; + } + return false; + } + + @Override + public RainbowValeEffect copy() { + return new RainbowValeEffect(this); + } + } +} + +class OpponentGainControlEffect extends ContinuousEffectImpl { + + private UUID opponentId; + + public OpponentGainControlEffect() { + super(Duration.Custom, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.Detriment); + this.staticText = "an opponent gains control of {this}"; + opponentId = null; + } + + public OpponentGainControlEffect(final OpponentGainControlEffect effect) { + super(effect); + this.opponentId = effect.opponentId; + } + + @Override + public void init(Ability source, Game game) { + super.init(source, game); + Player controller = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (controller != null && permanent != null) { + if (game.getOpponents(controller.getId()).size() == 1) { + opponentId = game.getOpponents(controller.getId()).iterator().next(); + } else { + Target target = new TargetOpponent(true); + controller.chooseTarget(outcome, target, source, game); + opponentId = target.getFirstTarget(); + } + } + Player targetOpponent = game.getPlayer(opponentId); + if (targetOpponent != null && permanent != null) { + game.informPlayers(permanent.getLogName() + " is now controlled by " + targetOpponent.getLogName()); + } else { + discard(); + } + } + + @Override + public OpponentGainControlEffect copy() { + return new OpponentGainControlEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player targetOpponent = game.getPlayer(opponentId); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null && targetOpponent != null) { + permanent.changeControllerId(opponentId, game); + } else { + // no valid target exists, effect can be discarded + discard(); + } + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/ShieldOfTheAges.java b/Mage.Sets/src/mage/sets/mastersedition/ShieldOfTheAges.java new file mode 100644 index 00000000000..41cb5a5c322 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/ShieldOfTheAges.java @@ -0,0 +1,111 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.PreventionEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author fireshoes + */ +public class ShieldOfTheAges extends CardImpl { + + public ShieldOfTheAges(UUID ownerId) { + super(ownerId, 165, "Shield of the Ages", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "MED"; + + // {2}: Prevent the next 1 damage that would be dealt to you this turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ShieldOfTheAgesEffect(), new GenericManaCost(2))); + } + + public ShieldOfTheAges(final ShieldOfTheAges card) { + super(card); + } + + @Override + public ShieldOfTheAges copy() { + return new ShieldOfTheAges(this); + } +} + +class ShieldOfTheAgesEffect extends PreventionEffectImpl { + + public ShieldOfTheAgesEffect() { + super(Duration.EndOfTurn); + this.staticText = "Prevent the next 1 damage that would be dealt to you this turn"; + } + + public ShieldOfTheAgesEffect(final ShieldOfTheAgesEffect effect) { + super(effect); + } + + @Override + public ShieldOfTheAgesEffect copy() { + return new ShieldOfTheAgesEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + GameEvent preventEvent = new GameEvent(GameEvent.EventType.PREVENT_DAMAGE, + source.getControllerId(), source.getSourceId(), source.getControllerId(), event.getAmount(), false); + if (!game.replaceEvent(preventEvent)) { + int damage = event.getAmount(); + if (damage > 0) { + event.setAmount(damage - 1); + this.used = true; + game.fireEvent(GameEvent.getEvent(GameEvent.EventType.PREVENTED_DAMAGE, + source.getControllerId(), source.getSourceId(), source.getControllerId(), 1)); + } + } + return false; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (!this.used && super.applies(event, source, game) && event.getTargetId().equals(source.getControllerId())) { + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mastersedition/SpectralBears.java b/Mage.Sets/src/mage/sets/mastersedition/SpectralBears.java new file mode 100644 index 00000000000..e364e177ea7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/SpectralBears.java @@ -0,0 +1,117 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.common.DontUntapInControllersNextUntapStepSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.TokenPredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; + +/** + * + * @author fireshoes + */ +public class SpectralBears extends CardImpl { + + public SpectralBears(UUID ownerId) { + super(ownerId, 131, "Spectral Bears", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "HML"; + this.subtype.add("Bear"); + this.subtype.add("Spirit"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Whenever Spectral Bears attacks, if defending player controls no black nontoken permanents, it doesn't untap during your next untap step. + this.addAbility(new SpectralBearsTriggeredAbility()); + } + + public SpectralBears(final SpectralBears card) { + super(card); + } + + @Override + public SpectralBears copy() { + return new SpectralBears(this); + } +} + +class SpectralBearsTriggeredAbility extends TriggeredAbilityImpl { + + private static final FilterPermanent filter = new FilterPermanent("black nontoken permanents"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + filter.add(Predicates.not(new TokenPredicate())); + } + + public SpectralBearsTriggeredAbility() { + super(Zone.BATTLEFIELD, new DontUntapInControllersNextUntapStepSourceEffect()); + } + + public SpectralBearsTriggeredAbility(final SpectralBearsTriggeredAbility ability) { + super(ability); + } + + @Override + public SpectralBearsTriggeredAbility copy() { + return new SpectralBearsTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.ATTACKER_DECLARED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return event.getSourceId().equals(this.getSourceId()); + } + + @Override + public boolean checkInterveningIfClause(Game game) { + UUID defendingPlayerId = game.getCombat().getDefendingPlayerId(getSourceId(), game); + return defendingPlayerId != null && game.getBattlefield().countAll(filter, defendingPlayerId, game) < 1; + } + + @Override + public String getRule() { + return "Whenever {this} attacks, if defending player controls no black nontoken permanents, it doesn't untap during your next untap step."; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mastersedition/VodalianKnights.java b/Mage.Sets/src/mage/sets/mastersedition/VodalianKnights.java new file mode 100644 index 00000000000..7fc270f0757 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/VodalianKnights.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mastersedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class VodalianKnights extends mage.sets.fallenempires.VodalianKnights { + + public VodalianKnights(UUID ownerId) { + super(ownerId); + this.cardNumber = 55; + this.expansionSetCode = "MED"; + this.rarity = Rarity.UNCOMMON; + } + + public VodalianKnights(final VodalianKnights card) { + super(card); + } + + @Override + public VodalianKnights copy() { + return new VodalianKnights(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Aeolipile.java b/Mage.Sets/src/mage/sets/masterseditionii/Aeolipile.java new file mode 100644 index 00000000000..5d1ae57078a --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Aeolipile.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class Aeolipile extends CardImpl { + + public Aeolipile(UUID ownerId) { + super(ownerId, 202, "Aeolipile", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "ME2"; + + // {1}, {tap}, Sacrifice Aeolipile: Aeolipile deals 2 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), new ManaCostsImpl("{1}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public Aeolipile(final Aeolipile card) { + super(card); + } + + @Override + public Aeolipile copy() { + return new Aeolipile(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/BarbedSextant.java b/Mage.Sets/src/mage/sets/masterseditionii/BarbedSextant.java new file mode 100644 index 00000000000..64eb1ca5d74 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/BarbedSextant.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class BarbedSextant extends mage.sets.iceage.BarbedSextant { + + public BarbedSextant(UUID ownerId) { + super(ownerId); + this.cardNumber = 204; + this.expansionSetCode = "ME2"; + } + + public BarbedSextant(final BarbedSextant card) { + super(card); + } + + @Override + public BarbedSextant copy() { + return new BarbedSextant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Enervate.java b/Mage.Sets/src/mage/sets/masterseditionii/Enervate.java new file mode 100644 index 00000000000..a0cb61ea422 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Enervate.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class Enervate extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public Enervate(UUID ownerId) { + super(ownerId, 47, "Enervate", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "ME2"; + + // Tap target artifact, creature, or land. + this.getSpellAbility().addEffect(new TapTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Enervate(final Enervate card) { + super(card); + } + + @Override + public Enervate copy() { + return new Enervate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/ForgottenLore.java b/Mage.Sets/src/mage/sets/masterseditionii/ForgottenLore.java new file mode 100644 index 00000000000..3fc2f88f87e --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/ForgottenLore.java @@ -0,0 +1,140 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.Cost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardIdPredicate; +import mage.filter.predicate.other.OwnerIdPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInGraveyard; +import mage.target.common.TargetOpponent; +/** + * + * @author LoneFox + */ +public class ForgottenLore extends CardImpl { + + public ForgottenLore(UUID ownerId) { + super(ownerId, 164, "Forgotten Lore", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{G}"); + this.expansionSetCode = "ME2"; + + // Target opponent chooses a card in your graveyard. You may pay {G}. If you do, repeat this process except that opponent can't choose a card already chosen for Forgotten Lore. Then put the last chosen card into your hand. + this.getSpellAbility().addEffect(new ForgottenLoreEffect()); + this.getSpellAbility().addTarget(new TargetOpponent()); + } + + public ForgottenLore(final ForgottenLore card) { + super(card); + } + + @Override + public ForgottenLore copy() { + return new ForgottenLore(this); + } +} + +class ForgottenLoreEffect extends OneShotEffect { + + public ForgottenLoreEffect() { + super(Outcome.Benefit); + staticText = "Target opponent chooses a card in your graveyard. You may pay {G}. If you do, repeat this process except that opponent can't choose a card already chosen for {this}. Then put the last chosen card into your hand."; + } + + public ForgottenLoreEffect(final ForgottenLoreEffect effect) { + super(effect); + } + + @Override + public ForgottenLoreEffect copy() { + return new ForgottenLoreEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player you = game.getPlayer(source.getControllerId()); + Player opponent = game.getPlayer(targetPointer.getFirst(game, source)); + if(you != null && opponent != null) + { + FilterCard filter = new FilterCard(); + filter.add(new OwnerIdPredicate(you.getId())); + Cost cost = new ManaCostsImpl("{G}"); + TargetCardInGraveyard chosenCard; + Card card = null; + boolean done = false; + do { + chosenCard = new TargetCardInGraveyard(filter); + chosenCard.setNotTarget(true); + if(chosenCard.canChoose(opponent.getId(), game)) { + opponent.chooseTarget(Outcome.ReturnToHand, chosenCard, source, game); + card = game.getCard(chosenCard.getFirstTarget()); + filter.add(Predicates.not(new CardIdPredicate(card.getId()))); + game.informPlayers("Forgotten Lore: " + opponent.getLogName() + " has chosen " + card.getLogName()); + } + else { + done = true; + } + + if(!done) { + if(cost.canPay(source, source.getSourceId(), you.getId(), game) && you.chooseUse(Outcome.Benefit, "Pay {G} to choose a different card ?", source, game)) { + cost.clearPaid(); + if(!cost.pay(source, game, source.getSourceId(), you.getId(), false)) { + done = true; + } + } + else { + done = true; + } + } + + } while(!done); + + if(card != null) { + Cards cardsToHand = new CardsImpl(); + cardsToHand.add(card); + you.moveCards(cardsToHand, Zone.GRAVEYARD, Zone.HAND, source, game); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/GorillaShaman.java b/Mage.Sets/src/mage/sets/masterseditionii/GorillaShaman.java new file mode 100644 index 00000000000..e9d1bdf4bbc --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/GorillaShaman.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class GorillaShaman extends mage.sets.alliances.GorillaShaman1 { + + public GorillaShaman(UUID ownerId) { + super(ownerId); + this.cardNumber = 129; + this.expansionSetCode = "ME2"; + this.rarity = Rarity.UNCOMMON; + } + + public GorillaShaman(final GorillaShaman card) { + super(card); + } + + @Override + public GorillaShaman copy() { + return new GorillaShaman(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/KrovikanFetish.java b/Mage.Sets/src/mage/sets/masterseditionii/KrovikanFetish.java new file mode 100644 index 00000000000..dd4f06c1a9b --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/KrovikanFetish.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class KrovikanFetish extends mage.sets.fifthedition.KrovikanFetish { + + public KrovikanFetish(UUID ownerId) { + super(ownerId); + this.cardNumber = 100; + this.expansionSetCode = "ME2"; + } + + public KrovikanFetish(final KrovikanFetish card) { + super(card); + } + + @Override + public KrovikanFetish copy() { + return new KrovikanFetish(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Marjhan.java b/Mage.Sets/src/mage/sets/masterseditionii/Marjhan.java new file mode 100644 index 00000000000..f980073b9f6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Marjhan.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepSourceEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.UntapSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterAttackingCreature; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.AbilityPredicate; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Marjhan extends CardImpl { + + private static final FilterAttackingCreature filter = new FilterAttackingCreature("attacking creature without flying"); + + static { + filter.add(Predicates.not(new AbilityPredicate(FlyingAbility.class))); + } + + public Marjhan(UUID ownerId) { + super(ownerId, 54, "Marjhan", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{U}{U}"); + this.expansionSetCode = "ME2"; + this.subtype.add("Leviathan"); + this.power = new MageInt(8); + this.toughness = new MageInt(8); + + // Marjhan doesn't untap during your untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepSourceEffect())); + + // {U}{U}, Sacrifice a creature: Untap Marjhan. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new UntapSourceEffect(), new ManaCostsImpl("{U}{U}"), new IsStepCondition(PhaseStep.UPKEEP), null); + ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + this.addAbility(ability); + + // Marjhan can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // {U}{U}: Marjhan gets -1/-0 until end of turn and deals 1 damage to target attacking creature without flying. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(-1, 0, Duration.EndOfTurn), new ManaCostsImpl("{U}{U}")); + Effect effect = new DamageTargetEffect(1); + ability.addEffect(effect); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + + // When you control no Islands, sacrifice Marjhan. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public Marjhan(final Marjhan card) { + super(card); + } + + @Override + public Marjhan copy() { + return new Marjhan(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Panic.java b/Mage.Sets/src/mage/sets/masterseditionii/Panic.java new file mode 100644 index 00000000000..16b034a6316 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Panic.java @@ -0,0 +1,120 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.combat.CantBlockTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.TurnPhase; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Panic extends CardImpl { + + public Panic(UUID ownerId) { + super(ownerId, 145, "Panic", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{R}"); + this.expansionSetCode = "ME2"; + + // Cast Panic only during combat before blockers are declared. + Ability ability = new SimpleStaticAbility(Zone.ALL, new PanicRuleModifyingEffect()); + ability.setRuleAtTheTop(true); + this.addAbility(ability); + + // Target creature can't block this turn. + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addEffect(new CantBlockTargetEffect(Duration.EndOfTurn)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Panic(final Panic card) { + super(card); + } + + @Override + public Panic copy() { + return new Panic(this); + } +} + +class PanicRuleModifyingEffect extends ContinuousRuleModifyingEffectImpl { + + PanicRuleModifyingEffect() { + super(Duration.EndOfGame, Outcome.Detriment); + staticText = "Cast {this} only during combat before blockers are declared"; + } + + PanicRuleModifyingEffect(final PanicRuleModifyingEffect effect) { + super(effect); + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType().equals(GameEvent.EventType.CAST_SPELL); + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getSourceId().equals(source.getSourceId())) { + return !TurnPhase.COMBAT.equals(game.getTurn().getPhaseType()) || + game.getStep().getType().equals(PhaseStep.DECLARE_BLOCKERS) || + game.getStep().getType().equals(PhaseStep.FIRST_COMBAT_DAMAGE) || + game.getStep().getType().equals(PhaseStep.COMBAT_DAMAGE) || + game.getStep().getType().equals(PhaseStep.END_COMBAT); + } + return false; + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public PanicRuleModifyingEffect copy() { + return new PanicRuleModifyingEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/RedCliffsArmada.java b/Mage.Sets/src/mage/sets/masterseditionii/RedCliffsArmada.java new file mode 100644 index 00000000000..58337a7778f --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/RedCliffsArmada.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class RedCliffsArmada extends CardImpl { + + public RedCliffsArmada(UUID ownerId) { + super(ownerId, 62, "Red Cliffs Armada", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "ME2"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(5); + this.toughness = new MageInt(4); + + // Red Cliffs Armada can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public RedCliffsArmada(final RedCliffsArmada card) { + super(card); + } + + @Override + public RedCliffsArmada copy() { + return new RedCliffsArmada(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Reinforcements.java b/Mage.Sets/src/mage/sets/masterseditionii/Reinforcements.java new file mode 100644 index 00000000000..b348961ba26 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Reinforcements.java @@ -0,0 +1,61 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class Reinforcements extends CardImpl { + + public Reinforcements(UUID ownerId) { + super(ownerId, 28, "Reinforcements", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "ME2"; + + // Put up to three target creature cards from your graveyard on top of your library. + this.getSpellAbility().addEffect(new PutOnLibraryTargetEffect(true)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 3, new FilterCreatureCard("creature cards from your graveyard"))); + } + + public Reinforcements(final Reinforcements card) { + super(card); + } + + @Override + public Reinforcements copy() { + return new Reinforcements(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/SkeletonShip.java b/Mage.Sets/src/mage/sets/masterseditionii/SkeletonShip.java new file mode 100644 index 00000000000..96b1af5b4e6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/SkeletonShip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class SkeletonShip extends mage.sets.iceage.SkeletonShip { + + public SkeletonShip(UUID ownerId) { + super(ownerId); + this.cardNumber = 197; + this.expansionSetCode = "ME2"; + } + + public SkeletonShip(final SkeletonShip card) { + super(card); + } + + @Override + public SkeletonShip copy() { + return new SkeletonShip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/SoldeviDigger.java b/Mage.Sets/src/mage/sets/masterseditionii/SoldeviDigger.java new file mode 100644 index 00000000000..bc4d929132d --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/SoldeviDigger.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class SoldeviDigger extends mage.sets.alliances.SoldeviDigger { + + public SoldeviDigger(UUID ownerId) { + super(ownerId); + this.cardNumber = 221; + this.expansionSetCode = "ME2"; + this.rarity = Rarity.UNCOMMON; + } + + public SoldeviDigger(final SoldeviDigger card) { + super(card); + } + + @Override + public SoldeviDigger copy() { + return new SoldeviDigger(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/Stonehands.java b/Mage.Sets/src/mage/sets/masterseditionii/Stonehands.java new file mode 100644 index 00000000000..6e666840ffa --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/Stonehands.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Stonehands extends mage.sets.iceage.Stonehands { + + public Stonehands(UUID ownerId) { + super(ownerId); + this.cardNumber = 151; + this.expansionSetCode = "ME2"; + } + + public Stonehands(final Stonehands card) { + super(card); + } + + @Override + public Stonehands copy() { + return new Stonehands(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/TimeBomb.java b/Mage.Sets/src/mage/sets/masterseditionii/TimeBomb.java new file mode 100644 index 00000000000..d71d59a7ea7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/TimeBomb.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class TimeBomb extends CardImpl { + + public TimeBomb(UUID ownerId) { + super(ownerId, 223, "Time Bomb", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}"); + this.expansionSetCode = "ME2"; + + // At the beginning of your upkeep, put a time counter on Time Bomb. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(), true), TargetController.YOU, false)); + + // {1}, {tap}, Sacrifice Time Bomb: Time Bomb deals damage equal to the number of time counters on it to each creature and each player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new DamageEverythingEffect(new CountersCount(CounterType.TIME), new FilterCreaturePermanent()), + new GenericManaCost(1)); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + this.addAbility(ability); + } + + public TimeBomb(final TimeBomb card) { + super(card); + } + + @Override + public TimeBomb copy() { + return new TimeBomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/WallOfKelp.java b/Mage.Sets/src/mage/sets/masterseditionii/WallOfKelp.java new file mode 100644 index 00000000000..46ee3344444 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/WallOfKelp.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditionii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class WallOfKelp extends mage.sets.homelands.WallOfKelp { + + public WallOfKelp(UUID ownerId) { + super(ownerId); + this.cardNumber = 74; + this.expansionSetCode = "ME2"; + this.rarity = Rarity.COMMON; + } + + public WallOfKelp(final WallOfKelp card) { + super(card); + } + + @Override + public WallOfKelp copy() { + return new WallOfKelp(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/AnabaAncestor.java b/Mage.Sets/src/mage/sets/masterseditioniii/AnabaAncestor.java new file mode 100644 index 00000000000..be8739bea49 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/AnabaAncestor.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class AnabaAncestor extends mage.sets.homelands.AnabaAncestor { + + public AnabaAncestor(UUID ownerId) { + super(ownerId); + this.cardNumber = 86; + this.expansionSetCode = "ME3"; + this.rarity = Rarity.COMMON; + } + + public AnabaAncestor(final AnabaAncestor card) { + super(card); + } + + @Override + public AnabaAncestor copy() { + return new AnabaAncestor(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/AnabaSpiritCrafter.java b/Mage.Sets/src/mage/sets/masterseditioniii/AnabaSpiritCrafter.java new file mode 100644 index 00000000000..c4168cb5a36 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/AnabaSpiritCrafter.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class AnabaSpiritCrafter extends mage.sets.homelands.AnabaSpiritCrafter { + + public AnabaSpiritCrafter(UUID ownerId) { + super(ownerId); + this.cardNumber = 87; + this.expansionSetCode = "ME3"; + this.rarity = Rarity.COMMON; + } + + public AnabaSpiritCrafter(final AnabaSpiritCrafter card) { + super(card); + } + + @Override + public AnabaSpiritCrafter copy() { + return new AnabaSpiritCrafter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/Astrolabe.java b/Mage.Sets/src/mage/sets/masterseditioniii/Astrolabe.java new file mode 100644 index 00000000000..ee37519a079 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/Astrolabe.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AddManaOfAnyColorEffect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class Astrolabe extends CardImpl { + + public Astrolabe(UUID ownerId) { + super(ownerId, 189, "Astrolabe", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "ME3"; + + // {1}, {tap}, Sacrifice Astrolabe: Add two mana of any one color to your mana pool. Draw a card at the beginning of the next turn's upkeep. + SimpleManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(2), new ManaCostsImpl("{1}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1), Duration.OneUse), false)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public Astrolabe(final Astrolabe card) { + super(card); + } + + @Override + public Astrolabe copy() { + return new Astrolabe(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/Didgeridoo.java b/Mage.Sets/src/mage/sets/masterseditioniii/Didgeridoo.java new file mode 100644 index 00000000000..21531411cb9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/Didgeridoo.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class Didgeridoo extends mage.sets.homelands.Didgeridoo { + + public Didgeridoo(UUID ownerId) { + super(ownerId); + this.cardNumber = 194; + this.expansionSetCode = "ME3"; + this.rarity = Rarity.UNCOMMON; + } + + public Didgeridoo(final Didgeridoo card) { + super(card); + } + + @Override + public Didgeridoo copy() { + return new Didgeridoo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/DongZhouTheTyrant.java b/Mage.Sets/src/mage/sets/masterseditioniii/DongZhouTheTyrant.java new file mode 100644 index 00000000000..979841a4a14 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/DongZhouTheTyrant.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class DongZhouTheTyrant extends mage.sets.portalthreekingdoms.DongZhouTheTyrant { + + public DongZhouTheTyrant(UUID ownerId) { + super(ownerId); + this.cardNumber = 96; + this.expansionSetCode = "ME3"; + } + + public DongZhouTheTyrant(final DongZhouTheTyrant card) { + super(card); + } + + @Override + public DongZhouTheTyrant copy() { + return new DongZhouTheTyrant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/Infuse.java b/Mage.Sets/src/mage/sets/masterseditioniii/Infuse.java new file mode 100644 index 00000000000..a67a3b3f188 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/Infuse.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Infuse extends mage.sets.iceage.Infuse { + + public Infuse(UUID ownerId) { + super(ownerId); + this.cardNumber = 38; + this.expansionSetCode = "ME3"; + } + + public Infuse(final Infuse card) { + super(card); + } + + @Override + public Infuse copy() { + return new Infuse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/KeiTakahashi.java b/Mage.Sets/src/mage/sets/masterseditioniii/KeiTakahashi.java new file mode 100644 index 00000000000..a1042182d0e --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/KeiTakahashi.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class KeiTakahashi extends CardImpl { + + public KeiTakahashi(UUID ownerId) { + super(ownerId, 155, "Kei Takahashi", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{W}"); + this.expansionSetCode = "ME3"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {tap}: Prevent the next 2 damage that would be dealt to target creature this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public KeiTakahashi(final KeiTakahashi card) { + super(card); + } + + @Override + public KeiTakahashi copy() { + return new KeiTakahashi(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/LivingPlane.java b/Mage.Sets/src/mage/sets/masterseditioniii/LivingPlane.java new file mode 100644 index 00000000000..65120905f42 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/LivingPlane.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class LivingPlane extends mage.sets.legends.LivingPlane { + + public LivingPlane(UUID ownerId) { + super(ownerId); + this.cardNumber = 127; + this.expansionSetCode = "ME3"; + } + + public LivingPlane(final LivingPlane card) { + super(card); + } + + @Override + public LivingPlane copy() { + return new LivingPlane(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/ManaVortex.java b/Mage.Sets/src/mage/sets/masterseditioniii/ManaVortex.java new file mode 100644 index 00000000000..6cf19b12be0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/ManaVortex.java @@ -0,0 +1,163 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CastSourceTriggeredAbility; +import mage.abilities.effects.common.SacrificeEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.stack.Spell; +import mage.game.stack.StackObject; +import mage.players.Player; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class ManaVortex extends CardImpl { + + public static final FilterLandPermanent filter = new FilterLandPermanent(); + + public ManaVortex(UUID ownerId) { + super(ownerId, 44, "Mana Vortex", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}{U}"); + this.expansionSetCode = "ME3"; + + // When you cast Mana Vortex, counter it unless you sacrifice a land. + this.addAbility(new CastSourceTriggeredAbility(new CounterSourceEffect())); + + // At the beginning of each player's upkeep, that player sacrifices a land. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeEffect(new FilterLandPermanent(), 1, "that player"), + TargetController.ANY, false)); + + // When there are no lands on the battlefield, sacrifice Mana Vortex. + this.addAbility(new ManaVortexStateTriggeredAbility()); + } + + public ManaVortex(final ManaVortex card) { + super(card); + } + + @Override + public ManaVortex copy() { + return new ManaVortex(this); + } +} + +class CounterSourceEffect extends OneShotEffect { + + public CounterSourceEffect() { + super(Outcome.Detriment); + } + + public CounterSourceEffect(final CounterSourceEffect effect) { + super(effect); + } + + @Override + public CounterSourceEffect copy() { + return new CounterSourceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + + StackObject spell = null; + for(StackObject objet : game.getStack()){ + if(objet instanceof Spell && objet.getSourceId().equals(source.getSourceId())){ + spell = objet; + } + } + if(spell != null){ + Player controller = game.getPlayer(source.getControllerId()); + if(controller.chooseUse(Outcome.Detriment, "Sacrifice a land to not counter " + spell.getName() + "?", source, game)){ + SacrificeTargetCost cost = new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent())); + if(cost.pay(source, game, source.getSourceId(), source.getControllerId(), false)){ + game.informPlayers(controller.getLogName() + " sacrifices a land to not counter " + spell.getName() + "."); + return true; + } + else { + game.getStack().counter(spell.getId(), source.getSourceId(), game); + } + } + return true; + } + return false; + } + + @Override + public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } + return "counter it unless you sacrifice a land"; + } +} + +class ManaVortexStateTriggeredAbility extends StateTriggeredAbility { + + public ManaVortexStateTriggeredAbility() { + super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); + } + + public ManaVortexStateTriggeredAbility(final ManaVortexStateTriggeredAbility ability) { + super(ability); + } + + @Override + public ManaVortexStateTriggeredAbility copy() { + return new ManaVortexStateTriggeredAbility(this); + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return game.getBattlefield().count(ManaVortex.filter, this.getSourceId(), this.getControllerId(), game) == 0; + } + + @Override + public String getRule() { + return new StringBuilder("When there are no lands on the battlefield, ").append(super.getRule()).toString() ; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/MengHuoBarbarianKing.java b/Mage.Sets/src/mage/sets/masterseditioniii/MengHuoBarbarianKing.java new file mode 100644 index 00000000000..7b638613517 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/MengHuoBarbarianKing.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class MengHuoBarbarianKing extends mage.sets.portalthreekingdoms.MengHuoBarbarianKing { + + public MengHuoBarbarianKing(UUID ownerId) { + super(ownerId); + this.cardNumber = 128; + this.expansionSetCode = "ME3"; + } + + public MengHuoBarbarianKing(final MengHuoBarbarianKing card) { + super(card); + } + + @Override + public MengHuoBarbarianKing copy() { + return new MengHuoBarbarianKing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/Tracker.java b/Mage.Sets/src/mage/sets/masterseditioniii/Tracker.java new file mode 100644 index 00000000000..1f81dac24ad --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/Tracker.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageEachOtherEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Tracker extends CardImpl { + + public Tracker(UUID ownerId) { + super(ownerId, 136, "Tracker", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "ME3"; + this.subtype.add("Human"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {G}{G}, {tap}: Tracker deals damage equal to its power to target creature. That creature deals damage equal to its power to Tracker. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEachOtherEffect(), new ManaCostsImpl("{G}{G}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public Tracker(final Tracker card) { + super(card); + } + + @Override + public Tracker copy() { + return new Tracker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/WanderingMage.java b/Mage.Sets/src/mage/sets/masterseditioniii/WanderingMage.java new file mode 100644 index 00000000000..a09c453c49b --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/WanderingMage.java @@ -0,0 +1,140 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.CostImpl; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.Target; +import mage.target.TargetPlayer; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class WanderingMage extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Cleric or Wizard"); + + static { + filter.add(Predicates.or( + new SubtypePredicate("Cleric"), + new SubtypePredicate("Wizard"))); + } + + public WanderingMage(UUID ownerId) { + super(ownerId, 186, "Wandering Mage", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W}{U}{B}"); + this.expansionSetCode = "ME3"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.subtype.add("Wizard"); + this.power = new MageInt(0); + this.toughness = new MageInt(3); + + // {W}, Pay 1 life: Prevent the next 2 damage that would be dealt to target creature this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new ManaCostsImpl("{W}")); + ability.addCost(new PayLifeCost(1)); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // {U}: Prevent the next 1 damage that would be dealt to target Cleric or Wizard creature this turn. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 1), new ManaCostsImpl("{U}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + + // {B}, Put a -1/-1 counter on a creature you control: Prevent the next 2 damage that would be dealt to target player this turn. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new ManaCostsImpl("{B}")); + ability.addCost(new WanderingMageCost()); + ability.addTarget(new TargetPlayer()); + Target target = new TargetControlledCreaturePermanent(); + target.setNotTarget(true); + ability.addTarget(target); + this.addAbility(ability); + } + + public WanderingMage(final WanderingMage card) { + super(card); + } + + @Override + public WanderingMage copy() { + return new WanderingMage(this); + } +} + +class WanderingMageCost extends CostImpl { + + public WanderingMageCost() { + this.text = "Put a -1/-1 counter on a creature you control"; + } + + public WanderingMageCost(WanderingMageCost cost) { + super(cost); + } + + @Override + public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { + return true; + } + + @Override + public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { + Permanent permanent = game.getPermanent(ability.getTargets().get(1).getFirstTarget()); + if (permanent != null) { + permanent.addCounters(CounterType.M1M1.createInstance(), game); + this.paid = true; + } + return paid; + } + + @Override + public WanderingMageCost copy() { + return new WanderingMageCost(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniii/WuWarship.java b/Mage.Sets/src/mage/sets/masterseditioniii/WuWarship.java new file mode 100644 index 00000000000..06fc2fa12f0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniii/WuWarship.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class WuWarship extends CardImpl { + + public WuWarship(UUID ownerId) { + super(ownerId, 56, "Wu Warship", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "ME3"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Wu Warship can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public WuWarship(final WuWarship card) { + super(card); + } + + @Override + public WuWarship copy() { + return new WuWarship(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/ArgivianBlacksmith.java b/Mage.Sets/src/mage/sets/masterseditioniv/ArgivianBlacksmith.java new file mode 100644 index 00000000000..39f60c163ab --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/ArgivianBlacksmith.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ArgivianBlacksmith extends mage.sets.antiquities.ArgivianBlacksmith { + + public ArgivianBlacksmith(UUID ownerId) { + super(ownerId); + this.cardNumber = 4; + this.expansionSetCode = "ME4"; + this.rarity = Rarity.UNCOMMON; + } + + public ArgivianBlacksmith(final ArgivianBlacksmith card) { + super(card); + } + + @Override + public ArgivianBlacksmith copy() { + return new ArgivianBlacksmith(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/Channel.java b/Mage.Sets/src/mage/sets/masterseditioniv/Channel.java new file mode 100644 index 00000000000..fbc0c4dbe74 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/Channel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 145; + this.expansionSetCode = "ME4"; + this.rarity = Rarity.RARE; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/Crumble.java b/Mage.Sets/src/mage/sets/masterseditioniv/Crumble.java new file mode 100644 index 00000000000..6c6708362da --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/Crumble.java @@ -0,0 +1,100 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetArtifactPermanent; + +/** + * + * @author fireshoes + */ +public class Crumble extends CardImpl { + + public Crumble(UUID ownerId) { + super(ownerId, 147, "Crumble", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{G}"); + this.expansionSetCode = "ME4"; + + // Destroy target artifact. It can't be regenerated. + this.getSpellAbility().addTarget(new TargetArtifactPermanent()); + this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); + + // That artifact's controller gains life equal to its converted mana cost. + this.getSpellAbility().addEffect(new CrumbleEffect()); + } + + public Crumble(final Crumble card) { + super(card); + } + + @Override + public Crumble copy() { + return new Crumble(this); + } +} + +class CrumbleEffect extends OneShotEffect { + + public CrumbleEffect() { + super(Outcome.GainLife); + staticText = "That artifact's controller gains life equal to its converted mana cost"; + } + + public CrumbleEffect(final CrumbleEffect effect) { + super(effect); + } + + @Override + public CrumbleEffect copy() { + return new CrumbleEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanentOrLKIBattlefield(getTargetPointer().getFirst(game, source)); + if (permanent != null) { + int cost = permanent.getManaCost().convertedManaCost(); + Player player = game.getPlayer(permanent.getControllerId()); + if (player != null) { + player.gainLife(cost, game); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/Deathgrip.java b/Mage.Sets/src/mage/sets/masterseditioniv/Deathgrip.java new file mode 100644 index 00000000000..e5d9b196a87 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/Deathgrip.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 75; + this.expansionSetCode = "ME4"; + this.rarity = Rarity.RARE; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/FloodwaterDam.java b/Mage.Sets/src/mage/sets/masterseditioniv/FloodwaterDam.java new file mode 100644 index 00000000000..66466c4dc3b --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/FloodwaterDam.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class FloodwaterDam extends CardImpl { + + private final UUID originalId; + + public FloodwaterDam(UUID ownerId) { + super(ownerId, 200, "Floodwater Dam", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "ME4"; + + // {X}{X}{1}, {tap}: Tap X target lands. + Effect effect = new TapTargetEffect(); + effect.setText("tap X target lands"); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}{X}{1}")); + ability.addCost(new TapSourceCost()); + originalId = ability.getOriginalId(); + this.addAbility(ability); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability.getOriginalId().equals(originalId)){ + int xValue = ability.getManaCostsToPay().getX(); + ability.getTargets().clear(); + ability.addTarget(new TargetLandPermanent(xValue, xValue, new FilterLandPermanent(), false)); + } + } + + public FloodwaterDam(final FloodwaterDam card) { + super(card); + this.originalId = card.originalId; + } + + @Override + public FloodwaterDam copy() { + return new FloodwaterDam(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/FoulSpirit.java b/Mage.Sets/src/mage/sets/masterseditioniv/FoulSpirit.java new file mode 100644 index 00000000000..4a00e1cc953 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/FoulSpirit.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.SacrificeControllerEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class FoulSpirit extends CardImpl { + + public FoulSpirit(UUID ownerId) { + super(ownerId, 81, "Foul Spirit", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "ME4"; + this.subtype.add("Spirit"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When Foul Spirit enters the battlefield, sacrifice a land. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterLandPermanent(), 1, ""), false)); + } + + public FoulSpirit(final FoulSpirit card) { + super(card); + } + + @Override + public FoulSpirit copy() { + return new FoulSpirit(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/GorillaWarCry.java b/Mage.Sets/src/mage/sets/masterseditioniv/GorillaWarCry.java new file mode 100644 index 00000000000..8fdd8972bf2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/GorillaWarCry.java @@ -0,0 +1,124 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.MenaceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.TurnPhase; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author fireshoes + */ +public class GorillaWarCry extends CardImpl { + + public GorillaWarCry(UUID ownerId) { + super(ownerId, 124, "Gorilla War Cry", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{R}"); + this.expansionSetCode = "ME4"; + + // Cast Gorilla War Cry only during combat before blockers are declared. + Ability ability = new SimpleStaticAbility(Zone.ALL, new GorillaWarCryRuleModifyingEffect()); + ability.setRuleAtTheTop(true); + this.addAbility(ability); + + // All creatures gain menace until end of turn. (They can't be blocked except by two or more creatures.) + Effect effect = new GainAbilityAllEffect(new MenaceAbility(), Duration.EndOfTurn, new FilterCreaturePermanent()); + effect.setText("All creatures gain menace until end of turn. (They can't be blocked except by two or more creatures.)"); + this.getSpellAbility().addEffect(effect); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public GorillaWarCry(final GorillaWarCry card) { + super(card); + } + + @Override + public GorillaWarCry copy() { + return new GorillaWarCry(this); + } +} + +class GorillaWarCryRuleModifyingEffect extends ContinuousRuleModifyingEffectImpl { + + GorillaWarCryRuleModifyingEffect() { + super(Duration.EndOfGame, Outcome.Detriment); + staticText = "Cast {this} only during combat before blockers are declared"; + } + + GorillaWarCryRuleModifyingEffect(final GorillaWarCryRuleModifyingEffect effect) { + super(effect); + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType().equals(GameEvent.EventType.CAST_SPELL); + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getSourceId().equals(source.getSourceId())) { + return !TurnPhase.COMBAT.equals(game.getTurn().getPhaseType()) || + game.getStep().getType().equals(PhaseStep.DECLARE_BLOCKERS) || + game.getStep().getType().equals(PhaseStep.FIRST_COMBAT_DAMAGE) || + game.getStep().getType().equals(PhaseStep.COMBAT_DAMAGE) || + game.getStep().getType().equals(PhaseStep.END_COMBAT); + } + return false; + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public GorillaWarCryRuleModifyingEffect copy() { + return new GorillaWarCryRuleModifyingEffect(this); + } +} + diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/IslandSanctuary.java b/Mage.Sets/src/mage/sets/masterseditioniv/IslandSanctuary.java new file mode 100644 index 00000000000..8dc77ce2315 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 15; + this.expansionSetCode = "ME4"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/ProwlingNightstalker.java b/Mage.Sets/src/mage/sets/masterseditioniv/ProwlingNightstalker.java new file mode 100644 index 00000000000..1c9cbe92997 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/ProwlingNightstalker.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class ProwlingNightstalker extends CardImpl { + + private final static FilterCreaturePermanent notBlackCreatures = new FilterCreaturePermanent("except by black creatures"); + + static { + notBlackCreatures.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + + public ProwlingNightstalker(UUID ownerId) { + super(ownerId, 93, "Prowling Nightstalker", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "ME4"; + this.subtype.add("Nightstalker"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Prowling Nightstalker can't be blocked except by black creatures. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(notBlackCreatures, Duration.WhileOnBattlefield))); + } + + public ProwlingNightstalker(final ProwlingNightstalker card) { + super(card); + } + + @Override + public ProwlingNightstalker copy() { + return new ProwlingNightstalker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/Reconstruction.java b/Mage.Sets/src/mage/sets/masterseditioniv/Reconstruction.java new file mode 100644 index 00000000000..c4658e255d3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/Reconstruction.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Reconstruction extends mage.sets.antiquities.Reconstruction { + + public Reconstruction(UUID ownerId) { + super(ownerId); + this.cardNumber = 59; + this.expansionSetCode = "ME4"; + } + + public Reconstruction(final Reconstruction card) { + super(card); + } + + @Override + public Reconstruction copy() { + return new Reconstruction(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/TheftOfDreams.java b/Mage.Sets/src/mage/sets/masterseditioniv/TheftOfDreams.java new file mode 100644 index 00000000000..fa21c71af72 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/TheftOfDreams.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class TheftOfDreams extends mage.sets.exodus.TheftOfDreams { + + public TheftOfDreams(UUID ownerId) { + super(ownerId); + this.cardNumber = 67; + this.expansionSetCode = "ME4"; + this.rarity = Rarity.UNCOMMON; + } + + public TheftOfDreams(final TheftOfDreams card) { + super(card); + } + + @Override + public TheftOfDreams copy() { + return new TheftOfDreams(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/TriassicEgg.java b/Mage.Sets/src/mage/sets/masterseditioniv/TriassicEgg.java new file mode 100644 index 00000000000..ff16671e170 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/TriassicEgg.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.masterseditioniv; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class TriassicEgg extends mage.sets.legends.TriassicEgg { + + public TriassicEgg(UUID ownerId) { + super(ownerId); + this.cardNumber = 235; + this.expansionSetCode = "ME4"; + } + + public TriassicEgg(final TriassicEgg card) { + super(card); + } + + @Override + public TriassicEgg copy() { + return new TriassicEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mediainserts/MagisterOfWorth.java b/Mage.Sets/src/mage/sets/mediainserts/MagisterOfWorth.java new file mode 100644 index 00000000000..8730131d3ba --- /dev/null +++ b/Mage.Sets/src/mage/sets/mediainserts/MagisterOfWorth.java @@ -0,0 +1,196 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mediainserts; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreatureCard; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class MagisterOfWorth extends CardImpl { + + public MagisterOfWorth(UUID ownerId) { + super(ownerId, 86, "Magister of Worth", Rarity.SPECIAL, new CardType[]{CardType.CREATURE}, "{4}{W}{B}"); + this.expansionSetCode = "MBP"; + this.subtype.add("Angel"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Will of the council - When Magister of Worth enters the battlefield, starting with you, each player votes for grace or condemnation. If grace gets more votes, each player returns each creature card from his or her graveyard to the battlefield. If condemnation gets more votes or the vote is tied, destroy all creatures other than Magister of Worth. + Effect effect = new MagisterOfWorthVoteEffect(); + effect.setText("Will of the council - When Magister of Worth enters the battlefield, starting with you, each player votes for grace or condemnation. If grace gets more votes, each player returns each creature card from his or her graveyard to the battlefield. If condemnation gets more votes or the vote is tied, destroy all creatures other than Magister of Worth"); + this.addAbility(new EntersBattlefieldTriggeredAbility(effect, false, true)); + } + + public MagisterOfWorth(final MagisterOfWorth card) { + super(card); + } + + @Override + public MagisterOfWorth copy() { + return new MagisterOfWorth(this); + } +} + +class MagisterOfWorthVoteEffect extends OneShotEffect { + + MagisterOfWorthVoteEffect() { + super(Outcome.Benefit); + this.staticText = "Will of the council - When {this} enters the battlefield, starting with you, each player votes for grace or condemnation. If grace gets more votes, each player returns each creature card from his or her graveyard to the battlefield. If condemnation gets more votes or the vote is tied, destroy all creatures other than {this}."; + } + + MagisterOfWorthVoteEffect(final MagisterOfWorthVoteEffect effect) { + super(effect); + } + + @Override + public MagisterOfWorthVoteEffect copy() { + return new MagisterOfWorthVoteEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + int graceCount = 0; + int condemnationCount = 0; + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { + Player player = game.getPlayer(playerId); + if (player != null) { + if (player.chooseUse(Outcome.DestroyPermanent, "Choose grace?", source, game)) { + graceCount++; + game.informPlayers(player.getLogName() + " has chosen: grace"); + } + else { + condemnationCount++; + game.informPlayers(player.getLogName() + " has chosen: condemnation"); + } + } + } + if (graceCount > condemnationCount) { + new MagisterOfWorthReturnFromGraveyardEffect().apply(game, source); + } else { + new MagisterOfWorthDestroyEffect().apply(game, source); + } + return true; + } + return false; + } +} + +class MagisterOfWorthDestroyEffect extends OneShotEffect { + + private static final FilterPermanent filter = new FilterCreaturePermanent("creatures other than {this}"); + + static { + filter.add(new AnotherPredicate()); + } + + public MagisterOfWorthDestroyEffect() { + super(Outcome.DestroyPermanent); + staticText = "destroy all creatures other than {this}"; + } + + public MagisterOfWorthDestroyEffect(final MagisterOfWorthDestroyEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { + permanent.destroy(source.getSourceId(), game, false); + } + return true; + } + + @Override + public MagisterOfWorthDestroyEffect copy() { + return new MagisterOfWorthDestroyEffect(this); + } + +} + +class MagisterOfWorthReturnFromGraveyardEffect extends OneShotEffect { + + public MagisterOfWorthReturnFromGraveyardEffect() { + super(Outcome.PutCreatureInPlay); + staticText = "each player returns each creature card from his or her graveyard to the battlefield"; + } + + public MagisterOfWorthReturnFromGraveyardEffect(final MagisterOfWorthReturnFromGraveyardEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + for (UUID playerId: controller.getInRange()) { + Player player = game.getPlayer(playerId); + if (player != null) { + for (Card card :player.getGraveyard().getCards(new FilterCreatureCard(), game)) { + player.putOntoBattlefieldWithInfo(card, game, Zone.GRAVEYARD, source.getSourceId()); + } + } + } + return true; + } + return false; + } + + @Override + public MagisterOfWorthReturnFromGraveyardEffect copy() { + return new MagisterOfWorthReturnFromGraveyardEffect(this); + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mediainserts/VoidmageHusher.java b/Mage.Sets/src/mage/sets/mediainserts/VoidmageHusher.java new file mode 100644 index 00000000000..869e1f69887 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mediainserts/VoidmageHusher.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mediainserts; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SpellCastControllerTriggeredAbility; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.keyword.FlashAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetActivatedAbility; + +/** + * + * @author andyfries + */ +public class VoidmageHusher extends CardImpl { + + public VoidmageHusher(UUID ownerId) { + super(ownerId, 62, "Voidmage Husher", Rarity.SPECIAL, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "MBP"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // When Voidmage Husher enters the battlefield, counter target activated ability. + Ability ability = new EntersBattlefieldTriggeredAbility(new CounterTargetEffect()); + ability.addTarget(new TargetActivatedAbility()); + this.addAbility(ability); + + // Whenever you cast a spell, you may return Voidmage Husher to its owner's hand. + this.addAbility(new SpellCastControllerTriggeredAbility(new ReturnToHandSourceEffect(true), true)); + } + + public VoidmageHusher(final VoidmageHusher card) { + super(card); + } + + @Override + public VoidmageHusher copy() { + return new VoidmageHusher(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/AncestralMask.java b/Mage.Sets/src/mage/sets/mercadianmasques/AncestralMask.java new file mode 100644 index 00000000000..fe79df7e3f0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/AncestralMask.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterEnchantmentPermanent; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class AncestralMask extends CardImpl { + + private static final FilterEnchantmentPermanent filter = new FilterEnchantmentPermanent("each other enchantment on the battlefield"); + + static { + filter.add(new AnotherPredicate()); + } + + public AncestralMask(UUID ownerId) { + super(ownerId, 229, "Ancestral Mask", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // Enchanted creature gets +2/+2 for each other enchantment on the battlefield. + PermanentsOnBattlefieldCount countEnchantments = new PermanentsOnBattlefieldCount(new FilterEnchantmentPermanent(filter), 2); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(countEnchantments, countEnchantments, Duration.WhileOnBattlefield))); + } + + public AncestralMask(final AncestralMask card) { + super(card); + } + + @Override + public AncestralMask copy() { + return new AncestralMask(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/CacklingWitch.java b/Mage.Sets/src/mage/sets/mercadianmasques/CacklingWitch.java new file mode 100644 index 00000000000..93bc1c8ca47 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/CacklingWitch.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CacklingWitch extends CardImpl { + + public CacklingWitch(UUID ownerId) { + super(ownerId, 119, "Cackling Witch", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {X}{B}, {tap}, Discard a card: Target creature gets +X/+0 until end of turn. + ManacostVariableValue manaX = new ManacostVariableValue(); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostTargetEffect(manaX, new StaticValue(0), Duration.EndOfTurn), + new ManaCostsImpl("{X}{B}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public CacklingWitch(final CacklingWitch card) { + super(card); + } + + @Override + public CacklingWitch copy() { + return new CacklingWitch(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimAlchemist.java b/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimAlchemist.java new file mode 100644 index 00000000000..27d31e4d615 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimAlchemist.java @@ -0,0 +1,134 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.PreventionEffectData; +import mage.abilities.effects.PreventionEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.players.Player; +import mage.target.TargetSource; + +/** + * + * @author anonymous + */ +public class ChoArrimAlchemist extends CardImpl { + + public ChoArrimAlchemist(UUID ownerId) { + super(ownerId, 8, "Cho-Arrim Alchemist", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}{W}{W}, {tap}, Discard a card: The next time a source of your choice would deal damage to you this turn, prevent that damage. You gain life equal to the damage prevented this way. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ChoArrimAlchemistEffect(), new ManaCostsImpl("{1}{W}{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + this.addAbility(ability); + } + + public ChoArrimAlchemist(final ChoArrimAlchemist card) { + super(card); + } + + @Override + public ChoArrimAlchemist copy() { + return new ChoArrimAlchemist(this); + } +} + +class ChoArrimAlchemistEffect extends PreventionEffectImpl { + + private final TargetSource target; + + public ChoArrimAlchemistEffect() { + super(Duration.EndOfTurn, Integer.MAX_VALUE, false, false); + this.staticText = "The next time a source of your choice would deal damage to you this turn, prevent that damage. You gain life equal to the damage prevented this way."; + this.target = new TargetSource(); + } + + public ChoArrimAlchemistEffect(final ChoArrimAlchemistEffect effect) { + super(effect); + this.target = effect.target.copy(); + } + + @Override + public ChoArrimAlchemistEffect copy() { + return new ChoArrimAlchemistEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public void init(Ability source, Game game) { + this.target.choose(Outcome.PreventDamage, source.getControllerId(), source.getSourceId(), game); + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + PreventionEffectData preventionData = preventDamageAction(event, source, game); + this.used = true; + this.discard(); // only one use + if (preventionData.getPreventedDamage() > 0) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + player.gainLife(preventionData.getPreventedDamage(), game); + } + } + return true; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (!this.used && super.applies(event, source, game)) { + if (event.getTargetId().equals(source.getControllerId()) && event.getSourceId().equals(target.getFirstTarget())) { + return true; + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimLegate.java b/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimLegate.java new file mode 100644 index 00000000000..208c1e41a3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/ChoArrimLegate.java @@ -0,0 +1,89 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class ChoArrimLegate extends CardImpl { + + private static final FilterPermanent filterPlains = new FilterPermanent(); + private static final FilterPermanent filterSwamp = new FilterPermanent(); + private static final FilterCard filter = new FilterCard("black"); + + static { + filterPlains.add(new SubtypePredicate(("Plains"))); + filterSwamp.add(new SubtypePredicate(("Swamp"))); + filter.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public ChoArrimLegate(UUID ownerId) { + super(ownerId, 10, "Cho-Arrim Legate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // Protection from black + this.addAbility(new ProtectionAbility(filter)); + + // If an opponent controls a Swamp and you control a Plains, you may cast Cho-Arrim Legate without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Swamp and you control a Plains", + new OpponentControlsPermanentCondition(filterSwamp), + new PermanentsOnTheBattlefieldCondition(filterPlains)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + } + + public ChoArrimLegate(final ChoArrimLegate card) { + super(card); + } + + @Override + public ChoArrimLegate copy() { + return new ChoArrimLegate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/ChoMannosBlessing.java b/Mage.Sets/src/mage/sets/mercadianmasques/ChoMannosBlessing.java new file mode 100644 index 00000000000..03962c5f987 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/ChoMannosBlessing.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ChooseColorEffect; +import mage.abilities.effects.keyword.ProtectionChosenColorAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlashAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class ChoMannosBlessing extends CardImpl { + + public ChoMannosBlessing(UUID ownerId) { + super(ownerId, 12, "Cho-Manno's Blessing", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}{W}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Aura"); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Protect)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // As Cho-Manno's Blessing enters the battlefield, choose a color. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Benefit))); + + // Enchanted creature has protection from the chosen color. This effect doesn't remove Cho-Manno's Blessing. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ProtectionChosenColorAttachedEffect(true))); + } + + public ChoMannosBlessing(final ChoMannosBlessing card) { + super(card); + } + + @Override + public ChoMannosBlessing copy() { + return new ChoMannosBlessing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/CoastalPiracy.java b/Mage.Sets/src/mage/sets/mercadianmasques/CoastalPiracy.java new file mode 100644 index 00000000000..775da107107 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/CoastalPiracy.java @@ -0,0 +1,105 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.DamagedPlayerEvent; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.permanent.Permanent; + +/** + * + * @author Xavierv3131 + */ +public class CoastalPiracy extends CardImpl { + + public CoastalPiracy(UUID ownerId) { + super(ownerId, 68, "Coastal Piracy", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}{U}"); + this.expansionSetCode = "MMQ"; + + // Whenever a creature you control deals combat damage to an opponent, you may draw a card. + this.addAbility(new CoastalPiracyTriggeredAbility()); + } + + public CoastalPiracy(final CoastalPiracy card) { + super(card); + } + + @Override + public CoastalPiracy copy() { + return new CoastalPiracy(this); + } +} + +class CoastalPiracyTriggeredAbility extends TriggeredAbilityImpl { + + public CoastalPiracyTriggeredAbility() { + super(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1)); + this.optional = true; + } + + public CoastalPiracyTriggeredAbility(final CoastalPiracyTriggeredAbility ability) { + super(ability); + } + + @Override + public CoastalPiracyTriggeredAbility copy() { + return new CoastalPiracyTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.DAMAGED_PLAYER; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (((DamagedPlayerEvent) event).isCombatDamage() + && game.getOpponents(this.controllerId).contains(((DamagedPlayerEvent) event).getPlayerId())) { + Permanent creature = game.getPermanent(event.getSourceId()); + if (creature != null && creature.getControllerId().equals(controllerId)) { + return true; + } + } + return false; + } + + @Override + public String getRule() { + return "Whenever a creature you control deals combat damage to an opponent, you may draw a card."; + } + +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/DeepwoodLegate.java b/Mage.Sets/src/mage/sets/mercadianmasques/DeepwoodLegate.java new file mode 100644 index 00000000000..e6d3132a399 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/DeepwoodLegate.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class DeepwoodLegate extends CardImpl { + + private static final FilterPermanent filterForest = new FilterPermanent(); + private static final FilterPermanent filterSwamp = new FilterPermanent(); + + static { + filterForest.add(new SubtypePredicate(("Forest"))); + filterSwamp.add(new SubtypePredicate(("Swamp"))); + } + + public DeepwoodLegate(UUID ownerId) { + super(ownerId, 132, "Deepwood Legate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Shade"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // If an opponent controls a Forest and you control a Swamp, you may cast Deepwood Legate without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Forest and you control a Swamp", + new OpponentControlsPermanentCondition(filterForest), + new PermanentsOnTheBattlefieldCondition(filterSwamp)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + + // {B}: Deepwood Legate gets +1/+1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 1, Duration.EndOfTurn), new ManaCostsImpl("{B}"))); + } + + public DeepwoodLegate(final DeepwoodLegate card) { + super(card); + } + + @Override + public DeepwoodLegate copy() { + return new DeepwoodLegate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Embargo.java b/Mage.Sets/src/mage/sets/mercadianmasques/Embargo.java new file mode 100644 index 00000000000..b23284d6211 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Embargo.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.abilities.effects.common.LoseLifeSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterNonlandPermanent; + +/** + * + * @author fireshoes + */ +public class Embargo extends CardImpl { + + private static final FilterPermanent filter = new FilterNonlandPermanent(); + + public Embargo(UUID ownerId) { + super(ownerId, 77, "Embargo", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}"); + this.expansionSetCode = "MMQ"; + + // Nonland permanents don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); + + // At the beginning of your upkeep, you lose 2 life. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new LoseLifeSourceControllerEffect(2), TargetController.YOU, false)); + } + + public Embargo(final Embargo card) { + super(card); + } + + @Override + public Embargo copy() { + return new Embargo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/FountainOfCho.java b/Mage.Sets/src/mage/sets/mercadianmasques/FountainOfCho.java index 5074f07c584..d60cf95b01f 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/FountainOfCho.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/FountainOfCho.java @@ -34,6 +34,7 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.DynamicManaAbility; @@ -57,11 +58,15 @@ public class FountainOfCho extends CardImpl { this.addAbility(new EntersBattlefieldTappedAbility()); // {tap}: Put a storage counter on Fountain of Cho. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost())); - // {tap}, Remove any number of storage counters from Fountain of Cho: Add {W} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.WhiteMana, new RemovedCountersForCostValue(), - "Add {W} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + // {T}, Remove any number of storage counters from Fountain of Cho: Add {W} to your mana pool for each storage counter removed this way. + Ability ability = new DynamicManaAbility( + Mana.WhiteMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {W} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/GhoulsFeast.java b/Mage.Sets/src/mage/sets/mercadianmasques/GhoulsFeast.java new file mode 100644 index 00000000000..1e1bd80f0dd --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/GhoulsFeast.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class GhoulsFeast extends mage.sets.izzetvsgolgari.GhoulsFeast { + + public GhoulsFeast(UUID ownerId) { + super(ownerId); + this.cardNumber = 137; + this.expansionSetCode = "MMQ"; + } + + public GhoulsFeast(final GhoulsFeast card) { + super(card); + } + + @Override + public GhoulsFeast copy() { + return new GhoulsFeast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Groundskeeper.java b/Mage.Sets/src/mage/sets/mercadianmasques/Groundskeeper.java new file mode 100644 index 00000000000..3c4157e5900 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Groundskeeper.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Groundskeeper extends mage.sets.ninthedition.Groundskeeper { + + public Groundskeeper(UUID ownerId) { + super(ownerId); + this.cardNumber = 250; + this.expansionSetCode = "MMQ"; + } + + public Groundskeeper(final Groundskeeper card) { + super(card); + } + + @Override + public Groundskeeper copy() { + return new Groundskeeper(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/HowlingWolf.java b/Mage.Sets/src/mage/sets/mercadianmasques/HowlingWolf.java new file mode 100644 index 00000000000..ff491524b39 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/HowlingWolf.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.search.SearchLibraryPutInHandEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.target.common.TargetCardInLibrary; + +/** + * + * @author fireshoes + */ +public class HowlingWolf extends CardImpl { + + private static final FilterCard filter = new FilterCard("cards named Howling Wolf"); + + static { + filter.add(new NamePredicate("Howling Wolf")); + } + + public HowlingWolf(UUID ownerId) { + super(ownerId, 252, "Howling Wolf", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Wolf"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // When Howling Wolf enters the battlefield, you may search your library for up to three cards named Howling Wolf, reveal them, and put them into your hand. If you do, shuffle your library. + TargetCardInLibrary target = new TargetCardInLibrary(0, 3, filter); + this.addAbility(new EntersBattlefieldTriggeredAbility(new SearchLibraryPutInHandEffect(target, true, true), true)); + } + + public HowlingWolf(final HowlingWolf card) { + super(card); + } + + @Override + public HowlingWolf copy() { + return new HowlingWolf(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/KyrenLegate.java b/Mage.Sets/src/mage/sets/mercadianmasques/KyrenLegate.java new file mode 100644 index 00000000000..2ab15e70803 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/KyrenLegate.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class KyrenLegate extends CardImpl { + + private static final FilterPermanent filterPlains = new FilterPermanent(); + private static final FilterPermanent filterMountain = new FilterPermanent(); + + static { + filterPlains.add(new SubtypePredicate(("Plains"))); + filterMountain.add(new SubtypePredicate(("Mountain"))); + } + + public KyrenLegate(UUID ownerId) { + super(ownerId, 197, "Kyren Legate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Goblin"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Haste + this.addAbility(HasteAbility.getInstance()); + + // If an opponent controls a Plains and you control a Mountain, you may cast Kyren Legate without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Plains and you control a Mountain", + new OpponentControlsPermanentCondition(filterPlains), + new PermanentsOnTheBattlefieldCondition(filterMountain)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + } + + public KyrenLegate(final KyrenLegate card) { + super(card); + } + + @Override + public KyrenLegate copy() { + return new KyrenLegate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/LumberingSatyr.java b/Mage.Sets/src/mage/sets/mercadianmasques/LumberingSatyr.java new file mode 100644 index 00000000000..60bec905e18 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/LumberingSatyr.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.ForestwalkAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class LumberingSatyr extends CardImpl { + + public LumberingSatyr(UUID ownerId) { + super(ownerId, 257, "Lumbering Satyr", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Satyr"); + this.subtype.add("Beast"); + this.power = new MageInt(5); + this.toughness = new MageInt(4); + + // All creatures have forestwalk. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new GainAbilityAllEffect(new ForestwalkAbility(), Duration.WhileOnBattlefield, new FilterCreaturePermanent()))); + } + + public LumberingSatyr(final LumberingSatyr card) { + super(card); + } + + @Override + public LumberingSatyr copy() { + return new LumberingSatyr(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesScepter.java b/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesScepter.java new file mode 100644 index 00000000000..7188340f9ad --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesScepter.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.effects.common.turn.AddExtraTurnControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; + +/** + * + * @author fireshoes + */ +public class MagistratesScepter extends CardImpl { + + public MagistratesScepter(UUID ownerId) { + super(ownerId, 304, "Magistrate's Scepter", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "MMQ"; + + // {4}, {tap}: Put a charge counter on Magistrate's Scepter. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.CHARGE.createInstance()), new GenericManaCost(4)); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + + // {tap}, Remove three charge counters from Magistrate's Scepter: Take an extra turn after this one. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddExtraTurnControllerEffect(), new TapSourceCost()); + ability.addCost(new RemoveCountersSourceCost(CounterType.CHARGE.createInstance(3))); + this.addAbility(ability); + } + + public MagistratesScepter(final MagistratesScepter card) { + super(card); + } + + @Override + public MagistratesScepter copy() { + return new MagistratesScepter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesVeto.java b/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesVeto.java new file mode 100644 index 00000000000..88a61653bb4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/MagistratesVeto.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantBlockAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class MagistratesVeto extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white creatures and blue creatures"); + + static { + filter.add(Predicates.or( + new ColorPredicate(ObjectColor.WHITE), + new ColorPredicate(ObjectColor.BLUE))); + } + + public MagistratesVeto(UUID ownerId) { + super(ownerId, 204, "Magistrate's Veto", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}"); + this.expansionSetCode = "MMQ"; + + // White creatures and blue creatures can't block. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBlockAllEffect(filter, Duration.WhileOnBattlefield))); + } + + public MagistratesVeto(final MagistratesVeto card) { + super(card); + } + + @Override + public MagistratesVeto copy() { + return new MagistratesVeto(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/MercadianBazaar.java b/Mage.Sets/src/mage/sets/mercadianmasques/MercadianBazaar.java index b89398ad4a3..f361fba4a78 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/MercadianBazaar.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/MercadianBazaar.java @@ -34,6 +34,7 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.DynamicManaAbility; @@ -58,10 +59,14 @@ public class MercadianBazaar extends CardImpl { // {tap}: Put a storage counter on Mercadian Bazaar. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost())); // {tap}, Remove any number of storage counters from Mercadian Bazaar: Add {R} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.RedMana, new RemovedCountersForCostValue(), - "Add {R} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.RedMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {R} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/NetherSpirit.java b/Mage.Sets/src/mage/sets/mercadianmasques/NetherSpirit.java index 25fed1974c5..5502ad72413 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/NetherSpirit.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/NetherSpirit.java @@ -61,7 +61,7 @@ public class NetherSpirit extends CardImpl { // At the beginning of your upkeep, if Nether Spirit is the only creature card in your graveyard, you may return Nether Spirit to the battlefield. TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.GRAVEYARD, new ReturnSourceFromGraveyardToBattlefieldEffect(), TargetController.YOU, true); - this.addAbility(new ConditionalTriggeredAbility(ability, new NetherSpiritCondition(), "At the beginning of your upkeep, if Nether Spirit is the only creature card in your graveyard, you may return Nether Spirit to the battlefield.", true)); + this.addAbility(new ConditionalTriggeredAbility(ability, new NetherSpiritCondition(), "At the beginning of your upkeep, if {this} is the only creature card in your graveyard, you may return {this} to the battlefield.")); } public NetherSpirit(final NetherSpirit card) { @@ -75,7 +75,7 @@ public class NetherSpirit extends CardImpl { } class NetherSpiritCondition implements Condition { - + @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Overtaker.java b/Mage.Sets/src/mage/sets/mercadianmasques/Overtaker.java new file mode 100644 index 00000000000..ecc066adc56 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Overtaker.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.effects.common.continuous.GainControlTargetEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Overtaker extends CardImpl { + + public Overtaker(UUID ownerId) { + super(ownerId, 89, "Overtaker", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Merfolk"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {3}{U}, {tap}, Discard a card: Untap target creature and gain control of it until end of turn. That creature gains haste until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new ManaCostsImpl("{3}{U}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + Effect effect = new GainControlTargetEffect(Duration.EndOfTurn); + ability.addEffect(effect); + effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn); + ability.addEffect(effect); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public Overtaker(final Overtaker card) { + super(card); + } + + @Override + public Overtaker copy() { + return new Overtaker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/RighteousAura.java b/Mage.Sets/src/mage/sets/mercadianmasques/RighteousAura.java new file mode 100644 index 00000000000..dafd9416aa8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/RighteousAura.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author anonymous + */ +public class RighteousAura extends mage.sets.visions.RighteousAura { + + public RighteousAura(UUID ownerId) { + super(ownerId); + this.cardNumber = 45; + this.expansionSetCode = "MMQ"; + this.rarity = Rarity.UNCOMMON; + } + + public RighteousAura(final RighteousAura card) { + super(card); + } + + @Override + public RighteousAura copy() { + return new RighteousAura(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodGrove.java b/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodGrove.java index df971fa382f..7aeef255e35 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodGrove.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodGrove.java @@ -34,6 +34,7 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.DynamicManaAbility; @@ -55,13 +56,17 @@ public class RushwoodGrove extends CardImpl { // Rushwood Grove enters the battlefield tapped. this.addAbility(new EntersBattlefieldTappedAbility()); - // {tap}: Put a storage counter on Rushwood Grove. + // {T}: Put a storage counter on Rushwood Grove. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost())); - // {tap}, Remove any number of storage counters from Rushwood Grove: Add {G} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.GreenMana, new RemovedCountersForCostValue(), - "Add {G} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + // {T}, Remove any number of storage counters from Rushwood Grove: Add {G} to your mana pool for each storage counter removed this way. + Ability ability = new DynamicManaAbility( + Mana.GreenMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {G} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodLegate.java b/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodLegate.java new file mode 100644 index 00000000000..7283f179eae --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/RushwoodLegate.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class RushwoodLegate extends CardImpl { + + private static final FilterPermanent filterIsland = new FilterPermanent(); + private static final FilterPermanent filterForest = new FilterPermanent(); + + static { + filterForest.add(new SubtypePredicate(("Forest"))); + filterIsland.add(new SubtypePredicate(("Island"))); + } + + public RushwoodLegate(UUID ownerId) { + super(ownerId, 266, "Rushwood Legate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Dryad"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // If an opponent controls an Island and you control a Forest, you may cast Rushwood Legate without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls an Island and you control a Forest", + new OpponentControlsPermanentCondition(filterIsland), + new PermanentsOnTheBattlefieldCondition(filterForest)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + } + + public RushwoodLegate(final RushwoodLegate card) { + super(card); + } + + @Override + public RushwoodLegate copy() { + return new RushwoodLegate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanCove.java b/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanCove.java index 7d841973f70..f6fa90c5fab 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanCove.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanCove.java @@ -34,13 +34,12 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; -import mage.abilities.effects.common.AddManaInAnyCombinationEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.DynamicManaAbility; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.ColoredManaSymbol; import mage.constants.Rarity; import mage.constants.Zone; import mage.counters.CounterType; @@ -60,10 +59,14 @@ public class SaprazzanCove extends CardImpl { // {tap}: Put a storage counter on Saprazzan Cove. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost())); // {tap}, Remove any number of storage counters from Saprazzan Cove: Add {U} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.BlueMana, new RemovedCountersForCostValue(), - "Add {U} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.BlueMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {U} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanLegate.java b/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanLegate.java new file mode 100644 index 00000000000..cdc5afabcb2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/SaprazzanLegate.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class SaprazzanLegate extends CardImpl { + + private static final FilterPermanent filterMountain = new FilterPermanent(); + private static final FilterPermanent filterIsland = new FilterPermanent(); + + static { + filterMountain.add(new SubtypePredicate(("Mountain"))); + filterIsland.add(new SubtypePredicate(("Island"))); + } + + public SaprazzanLegate(UUID ownerId) { + super(ownerId, 100, "Saprazzan Legate", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "MMQ"; + this.subtype.add("Merfolk"); + this.subtype.add("Soldier"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // If an opponent controls a Mountain and you control an Island, you may cast Saprazzan Legate without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Mountain and you control an Island", + new OpponentControlsPermanentCondition(filterMountain), + new PermanentsOnTheBattlefieldCondition(filterIsland)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + } + + public SaprazzanLegate(final SaprazzanLegate card) { + super(card); + } + + @Override + public SaprazzanLegate copy() { + return new SaprazzanLegate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Squallmonger.java b/Mage.Sets/src/mage/sets/mercadianmasques/Squallmonger.java new file mode 100644 index 00000000000..48d394544f5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Squallmonger.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Squallmonger extends mage.sets.commander.Squallmonger { + + public Squallmonger(UUID ownerId) { + super(ownerId); + this.cardNumber = 276; + this.expansionSetCode = "MMQ"; + } + + public Squallmonger(final Squallmonger card) { + super(card); + } + + @Override + public Squallmonger copy() { + return new Squallmonger(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Squeeze.java b/Mage.Sets/src/mage/sets/mercadianmasques/Squeeze.java new file mode 100644 index 00000000000..554723aecaf --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Squeeze.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.cost.SpellsCostIncreasementAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.CardTypePredicate; + +/** + * + * @author fireshoes + */ +public class Squeeze extends CardImpl { + + private static final FilterCard filter = new FilterCard("Sorcery spells"); + + static { + filter.add(new CardTypePredicate(CardType.SORCERY)); + } + + public Squeeze(UUID ownerId) { + super(ownerId, 105, "Squeeze", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}"); + this.expansionSetCode = "MMQ"; + + // Sorcery spells cost {3} more to cast. + Effect effect = new SpellsCostIncreasementAllEffect(filter, 3); + effect.setText("Sorcery spells cost {3} more to cast"); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + } + + public Squeeze(final Squeeze card) { + super(card); + } + + @Override + public Squeeze copy() { + return new Squeeze(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/SubterraneanHangar.java b/Mage.Sets/src/mage/sets/mercadianmasques/SubterraneanHangar.java index 245b09cbd4a..21a9634814b 100644 --- a/Mage.Sets/src/mage/sets/mercadianmasques/SubterraneanHangar.java +++ b/Mage.Sets/src/mage/sets/mercadianmasques/SubterraneanHangar.java @@ -34,6 +34,7 @@ import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveVariableCountersSourceCost; import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; import mage.abilities.dynamicvalue.common.RemovedCountersForCostValue; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.mana.DynamicManaAbility; @@ -58,10 +59,14 @@ public class SubterraneanHangar extends CardImpl { // {tap}: Put a storage counter on Subterranean Hangar. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost())); // {tap}, Remove any number of storage counters from Subterranean Hangar: Add {B} to your mana pool for each storage counter removed this way. - Ability ability = new DynamicManaAbility(Mana.BlackMana, new RemovedCountersForCostValue(), - "Add {B} to your mana pool for each storage counter removed this way"); - ability.addCost(new RemoveVariableCountersSourceCost( - CounterType.STORAGE.createInstance(), "Remove any number of storage counters from {this}")); + Ability ability = new DynamicManaAbility( + Mana.BlackMana, + new RemovedCountersForCostValue(), + new TapSourceCost(), + "Add {B} to your mana pool for each storage counter removed this way", + true, new CountersCount(CounterType.STORAGE)); + ability.addCost(new RemoveVariableCountersSourceCost(CounterType.STORAGE.createInstance(), + "Remove any number of storage counters from {this}")); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/Sustenance.java b/Mage.Sets/src/mage/sets/mercadianmasques/Sustenance.java new file mode 100644 index 00000000000..cb3e9f21445 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/Sustenance.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Sustenance extends CardImpl { + + public Sustenance(UUID ownerId) { + super(ownerId, 278, "Sustenance", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "MMQ"; + + // {1}, Sacrifice a land: Target creature gets +1/+1 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 1, Duration.EndOfTurn), new ManaCostsImpl("{1}")); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("land")))); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public Sustenance(final Sustenance card) { + super(card); + } + + @Override + public Sustenance copy() { + return new Sustenance(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/TerritorialDispute.java b/Mage.Sets/src/mage/sets/mercadianmasques/TerritorialDispute.java new file mode 100644 index 00000000000..8f5d15435a3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/TerritorialDispute.java @@ -0,0 +1,110 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class TerritorialDispute extends CardImpl { + + public TerritorialDispute(UUID ownerId) { + super(ownerId, 217, "Territorial Dispute", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{4}{R}{R}"); + this.expansionSetCode = "MMQ"; + + // At the beginning of your upkeep, sacrifice Territorial Dispute unless you sacrifice a land. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, + new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land")))), + TargetController.YOU, + false)); + + // Players can't play lands. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new TerritorialDisputeEffect())); + } + + public TerritorialDispute(final TerritorialDispute card) { + super(card); + } + + @Override + public TerritorialDispute copy() { + return new TerritorialDispute(this); + } +} + +class TerritorialDisputeEffect extends ContinuousRuleModifyingEffectImpl { + + public TerritorialDisputeEffect() { + super(Duration.WhileOnBattlefield, Outcome.Neutral); + this.staticText = "Players can't play lands"; + } + + public TerritorialDisputeEffect(final TerritorialDisputeEffect effect) { + super(effect); + } + + @Override + public TerritorialDisputeEffect copy() { + return new TerritorialDisputeEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.PLAY_LAND; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + return true; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mercadianmasques/TidalBore.java b/Mage.Sets/src/mage/sets/mercadianmasques/TidalBore.java new file mode 100644 index 00000000000..abd9bf620da --- /dev/null +++ b/Mage.Sets/src/mage/sets/mercadianmasques/TidalBore.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mercadianmasques; + +import java.util.UUID; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.costs.common.ReturnToHandTargetPermanentCost; +import mage.abilities.effects.common.MayTapOrUntapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author markedagain + */ +public class TidalBore extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("an Island"); + + static { + filter.add(new SubtypePredicate("Island")); + filter.add(new CardTypePredicate(CardType.LAND)); + } + + public TidalBore(UUID ownerId) { + super(ownerId, 109, "Tidal Bore", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "MMQ"; + + // You may return an Island you control to its owner's hand rather than pay Tidal Bore's mana cost. + this.addAbility(new AlternativeCostSourceAbility(new ReturnToHandTargetPermanentCost(new TargetControlledPermanent(filter)))); + // You may tap or untap target creature. + this.getSpellAbility().addEffect(new MayTapOrUntapTargetEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public TidalBore(final TidalBore card) { + super(card); + } + + @Override + public TidalBore copy() { + return new TidalBore(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/ArmorerGuildmage.java b/Mage.Sets/src/mage/sets/mirage/ArmorerGuildmage.java new file mode 100644 index 00000000000..666cd572dab --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/ArmorerGuildmage.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class ArmorerGuildmage extends CardImpl { + + public ArmorerGuildmage(UUID ownerId) { + super(ownerId, 156, "Armorer Guildmage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {B}, {tap}: Target creature gets +1/+0 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{B}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // {G}, {tap}: Target creature gets +0/+1 until end of turn. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(0, 1, Duration.EndOfTurn), new ManaCostsImpl("{G}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public ArmorerGuildmage(final ArmorerGuildmage card) { + super(card); + } + + @Override + public ArmorerGuildmage copy() { + return new ArmorerGuildmage(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/BindingAgony.java b/Mage.Sets/src/mage/sets/mirage/BindingAgony.java new file mode 100644 index 00000000000..5be6d6400a7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/BindingAgony.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.DamageDealtToAttachedTriggeredAbility; +import mage.abilities.dynamicvalue.common.NumericSetToEffectValues; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SetTargetPointer; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class BindingAgony extends CardImpl { + + public BindingAgony(UUID ownerId) { + super(ownerId, 4, "Binding Agony", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Whenever enchanted creature is dealt damage, Binding Agony deals that much damage to that creature's controller. + Effect effect = new DamageTargetEffect(new NumericSetToEffectValues("that much", "damage")); + effect.setText("{this} deals that much damage to that creature's controller"); + this.addAbility(new DamageDealtToAttachedTriggeredAbility(Zone.BATTLEFIELD, effect, false, SetTargetPointer.PLAYER)); + } + + public BindingAgony(final BindingAgony card) { + super(card); + } + + @Override + public BindingAgony copy() { + return new BindingAgony(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/BoneHarvest.java b/Mage.Sets/src/mage/sets/mirage/BoneHarvest.java new file mode 100644 index 00000000000..0d770f08eaf --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/BoneHarvest.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class BoneHarvest extends CardImpl { + + public BoneHarvest(UUID ownerId) { + super(ownerId, 6, "Bone Harvest", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{B}"); + this.expansionSetCode = "MIR"; + + // Put any number of target creature cards from your graveyard on top of your library. + this.getSpellAbility().addEffect(new PutOnLibraryTargetEffect(true)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, Integer.MAX_VALUE, new FilterCreatureCard("creature cards from your graveyard"))); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public BoneHarvest(final BoneHarvest card) { + super(card); + } + + @Override + public BoneHarvest copy() { + return new BoneHarvest(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/CivicGuildmage.java b/Mage.Sets/src/mage/sets/mirage/CivicGuildmage.java new file mode 100644 index 00000000000..2a697a9af2b --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/CivicGuildmage.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CivicGuildmage extends CardImpl { + + public CivicGuildmage(UUID ownerId) { + super(ownerId, 211, "Civic Guildmage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {G}, {tap}: Target creature gets +0/+1 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(0, 1, Duration.EndOfTurn), new ManaCostsImpl("{G}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // {U}, {tap}: Put target creature you control on top of its owner's library. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutOnLibraryTargetEffect(true), new ManaCostsImpl("{U}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetControlledCreaturePermanent()); + this.addAbility(ability); + } + + public CivicGuildmage(final CivicGuildmage card) { + super(card); + } + + @Override + public CivicGuildmage copy() { + return new CivicGuildmage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/CloakOfInvisibility.java b/Mage.Sets/src/mage/sets/mirage/CloakOfInvisibility.java new file mode 100644 index 00000000000..1e9f7b1c966 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/CloakOfInvisibility.java @@ -0,0 +1,118 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.RestrictionEffect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.PhasingAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CloakOfInvisibility extends CardImpl { + + public CloakOfInvisibility(UUID ownerId) { + super(ownerId, 58, "Cloak of Invisibility", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature has phasing and can't be blocked except by Walls. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(PhasingAbility.getInstance(), AttachmentType.AURA)); + ability.addEffect(new CantBeBlockedByWallsEffect()); + this.addAbility(ability); + } + + public CloakOfInvisibility(final CloakOfInvisibility card) { + super(card); + } + + @Override + public CloakOfInvisibility copy() { + return new CloakOfInvisibility(this); + } +} + +class CantBeBlockedByWallsEffect extends RestrictionEffect { + + public CantBeBlockedByWallsEffect() { + super(Duration.WhileOnBattlefield); + staticText = "Enchanted creature can't be blocked except by Walls"; + } + + public CantBeBlockedByWallsEffect(final CantBeBlockedByWallsEffect effect) { + super(effect); + } + + @Override + public boolean applies(Permanent permanent, Ability source, Game game) { + Permanent enchantment = game.getPermanent(source.getSourceId()); + if (enchantment != null && enchantment.getAttachedTo() != null) { + if (permanent.getId().equals(enchantment.getAttachedTo())) { + return true; + } + } + return false; + } + + @Override + public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { + if (!blocker.hasSubtype("Wall")) { + return false; + } + return true; + } + + @Override + public CantBeBlockedByWallsEffect copy() { + return new CantBeBlockedByWallsEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/CrystalGolem.java b/Mage.Sets/src/mage/sets/mirage/CrystalGolem.java new file mode 100644 index 00000000000..4b069186add --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/CrystalGolem.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.effects.common.PhaseOutSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; + +/** + * + * @author fireshoes + */ +public class CrystalGolem extends CardImpl { + + public CrystalGolem(UUID ownerId) { + super(ownerId, 263, "Crystal Golem", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{4}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Golem"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // At the beginning of your end step, Crystal Golem phases out. + this.addAbility(new BeginningOfEndStepTriggeredAbility(new PhaseOutSourceEffect(), TargetController.YOU, false)); + } + + public CrystalGolem(final CrystalGolem card) { + super(card); + } + + @Override + public CrystalGolem copy() { + return new CrystalGolem(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/EbonyCharm.java b/Mage.Sets/src/mage/sets/mirage/EbonyCharm.java new file mode 100644 index 00000000000..ced14bb8364 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/EbonyCharm.java @@ -0,0 +1,141 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FearAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInASingleGraveyard; +import mage.target.common.TargetCreaturePermanent; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class EbonyCharm extends CardImpl { + + public EbonyCharm(UUID ownerId) { + super(ownerId, 18, "Ebony Charm", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{B}"); + this.expansionSetCode = "MIR"; + + // Choose one - Target opponent loses 1 life and you gain 1 life; + this.getSpellAbility().addEffect(new EbonyCharmDrainEffect()); + this.getSpellAbility().addTarget(new TargetOpponent()); + + // or exile up to three target cards from a single graveyard; + Mode mode = new Mode(); + mode.getEffects().add(new EbonyCharmExileEffect()); + mode.getTargets().add((new TargetCardInASingleGraveyard(0, 3, new FilterCard("up to three target cards from a single graveyard")))); + this.getSpellAbility().addMode(mode); + + // or target creature gains fear until end of turn. + mode = new Mode(); + mode.getTargets().add(new TargetCreaturePermanent()); + mode.getEffects().add(new GainAbilityTargetEffect(FearAbility.getInstance(), Duration.EndOfTurn)); + this.getSpellAbility().addMode(mode); + } + + public EbonyCharm(final EbonyCharm card) { + super(card); + } + + @Override + public EbonyCharm copy() { + return new EbonyCharm(this); + } +} + +class EbonyCharmDrainEffect extends OneShotEffect { + + EbonyCharmDrainEffect() { + super(Outcome.Damage); + staticText = "target opponent loses 1 life and you gain 1 life"; + } + + EbonyCharmDrainEffect(final EbonyCharmDrainEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player targetPlayer = game.getPlayer(source.getFirstTarget()); + Player controllerPlayer = game.getPlayer(source.getControllerId()); + if (targetPlayer != null && controllerPlayer != null) { + targetPlayer.damage(1, source.getSourceId(), game, false, true); + controllerPlayer.gainLife(1, game); + } + return false; + } + + @Override + public EbonyCharmDrainEffect copy() { + return new EbonyCharmDrainEffect(this); + } + +} + +class EbonyCharmExileEffect extends OneShotEffect { + + public EbonyCharmExileEffect() { + super(Outcome.Exile); + this.staticText = "Exile up to three target cards from a single graveyard"; + } + + public EbonyCharmExileEffect(final EbonyCharmExileEffect effect) { + super(effect); + } + + @Override + public EbonyCharmExileEffect copy() { + return new EbonyCharmExileEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (UUID targetID : source.getTargets().get(0).getTargets()) { + Card card = game.getCard(targetID); + if (card != null) { + card.moveToExile(null, "", source.getSourceId(), game); + } + } + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/Flare.java b/Mage.Sets/src/mage/sets/mirage/Flare.java new file mode 100644 index 00000000000..967557d19a9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Flare.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Flare extends mage.sets.fifthedition.Flare { + + public Flare(UUID ownerId) { + super(ownerId); + this.cardNumber = 176; + this.expansionSetCode = "MIR"; + } + + public Flare(final Flare card) { + super(card); + } + + @Override + public Flare copy() { + return new Flare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/ForbiddenCrypt.java b/Mage.Sets/src/mage/sets/mirage/ForbiddenCrypt.java index e886dc432b5..ef346c00eac 100644 --- a/Mage.Sets/src/mage/sets/mirage/ForbiddenCrypt.java +++ b/Mage.Sets/src/mage/sets/mirage/ForbiddenCrypt.java @@ -57,7 +57,6 @@ public class ForbiddenCrypt extends CardImpl { super(ownerId, 22, "Forbidden Crypt", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{B}{B}"); this.expansionSetCode = "MIR"; - // If you would draw a card, return a card from your graveyard to your hand instead. If you can't, you lose the game. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ForbiddenCryptDrawCardReplacementEffect())); // If a card would be put into your graveyard from anywhere, exile that card instead. @@ -80,7 +79,7 @@ class ForbiddenCryptDrawCardReplacementEffect extends ReplacementEffectImpl { super(Duration.WhileOnBattlefield, Outcome.Neutral); this.staticText = "If you would draw a card, return a card from your graveyard to your hand instead. If you can't, you lose the game"; } - + public ForbiddenCryptDrawCardReplacementEffect(final ForbiddenCryptDrawCardReplacementEffect effect) { super(effect); } @@ -92,22 +91,23 @@ class ForbiddenCryptDrawCardReplacementEffect extends ReplacementEffectImpl { @Override public boolean replaceEvent(GameEvent event, Ability source, Game game) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { boolean cardReturned = false; TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(); - if (target.canChoose(source.getSourceId(), player.getId(), game)) { - if (target.choose(Outcome.ReturnToHand, player.getId(), source.getSourceId(), game)) { + target.setNotTarget(true); + if (target.canChoose(source.getSourceId(), controller.getId(), game)) { + if (target.choose(Outcome.ReturnToHand, controller.getId(), source.getSourceId(), game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(card, null, Zone.HAND, source, game); cardReturned = true; } } } if (!cardReturned) { - game.informPlayers(new StringBuilder(player.getLogName()).append(" can't return a card from graveyard to hand.").toString()); - player.lost(game); + game.informPlayers(controller.getLogName() + " can't return a card from graveyard to hand."); + controller.lost(game); } return true; } @@ -118,12 +118,12 @@ class ForbiddenCryptDrawCardReplacementEffect extends ReplacementEffectImpl { public boolean checksEventType(GameEvent event, Game game) { return event.getType() == EventType.DRAW_CARD; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { return event.getPlayerId().equals(source.getControllerId()); } - + } class ForbiddenCryptPutIntoYourGraveyardReplacementEffect extends ReplacementEffectImpl { @@ -132,7 +132,7 @@ class ForbiddenCryptPutIntoYourGraveyardReplacementEffect extends ReplacementEff super(Duration.WhileOnBattlefield, Outcome.Detriment); this.staticText = "If a card would be put into your graveyard from anywhere, exile that card instead"; } - + public ForbiddenCryptPutIntoYourGraveyardReplacementEffect(final ForbiddenCryptPutIntoYourGraveyardReplacementEffect effect) { super(effect); } @@ -141,7 +141,7 @@ class ForbiddenCryptPutIntoYourGraveyardReplacementEffect extends ReplacementEff public ForbiddenCryptPutIntoYourGraveyardReplacementEffect copy() { return new ForbiddenCryptPutIntoYourGraveyardReplacementEffect(this); } - + @Override public boolean apply(Game game, Ability source) { return true; @@ -166,12 +166,12 @@ class ForbiddenCryptPutIntoYourGraveyardReplacementEffect extends ReplacementEff } return true; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == EventType.ZONE_CHANGE; - } - + } + @Override public boolean applies(GameEvent event, Ability source, Game game) { if (((ZoneChangeEvent) event).getToZone() == Zone.GRAVEYARD) { @@ -185,5 +185,5 @@ class ForbiddenCryptPutIntoYourGraveyardReplacementEffect extends ReplacementEff } return false; } - + } diff --git a/Mage.Sets/src/mage/sets/mirage/ForsakenWastes.java b/Mage.Sets/src/mage/sets/mirage/ForsakenWastes.java new file mode 100644 index 00000000000..00612501e4e --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/ForsakenWastes.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageObject; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.LoseLifeTargetEffect; +import mage.abilities.effects.common.continuous.CantGainLifeAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.stack.Spell; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author fireshoes + */ +public class ForsakenWastes extends CardImpl { + + public ForsakenWastes(UUID ownerId) { + super(ownerId, 23, "Forsaken Wastes", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "MIR"; + this.supertype.add("World"); + + // Players can't gain life. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantGainLifeAllEffect())); + + // At the beginning of each player's upkeep, that player loses 1 life. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(1), TargetController.ANY, false, true)); + + // Whenever Forsaken Wastes becomes the target of a spell, that spell's controller loses 5 life. + this.addAbility(new ForsakenWastesTriggeredAbility()); + } + + public ForsakenWastes(final ForsakenWastes card) { + super(card); + } + + @Override + public ForsakenWastes copy() { + return new ForsakenWastes(this); + } +} + +class ForsakenWastesTriggeredAbility extends TriggeredAbilityImpl { + + public ForsakenWastesTriggeredAbility() { + super(Zone.BATTLEFIELD, new LoseLifeTargetEffect(5), false); + } + + public ForsakenWastesTriggeredAbility(final ForsakenWastesTriggeredAbility ability) { + super(ability); + } + + @Override + public ForsakenWastesTriggeredAbility copy() { + return new ForsakenWastesTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.TARGETED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + MageObject eventSourceObject = game.getObject(event.getSourceId()); + if (eventSourceObject != null && event.getTargetId().equals(this.getSourceId())&& eventSourceObject instanceof Spell ) { + getEffects().get(0).setTargetPointer(new FixedTarget(event.getPlayerId())); + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever {this} becomes the target of a spell, that spell's controller loses 5 life."; + } + +} diff --git a/Mage.Sets/src/mage/sets/mirage/FreneticEfreet.java b/Mage.Sets/src/mage/sets/mirage/FreneticEfreet.java new file mode 100644 index 00000000000..3cefcde4f4e --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/FreneticEfreet.java @@ -0,0 +1,106 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class FreneticEfreet extends CardImpl { + + public FreneticEfreet(UUID ownerId) { + super(ownerId, 324, "Frenetic Efreet", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}{R}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Efreet"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {0}: Flip a coin. If you win the flip, Frenetic Efreet phases out. If you lose the flip, sacrifice Frenetic Efreet. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new FreneticEfreetEffect(), new GenericManaCost(0))); + } + + public FreneticEfreet(final FreneticEfreet card) { + super(card); + } + + @Override + public FreneticEfreet copy() { + return new FreneticEfreet(this); + } +} + +class FreneticEfreetEffect extends OneShotEffect { + + public FreneticEfreetEffect() { + super(Outcome.Damage); + staticText = "Flip a coin. If you win the flip, Frenetic Efreet phases out. If you lose the flip, sacrifice Frenetic Efreet"; + } + + public FreneticEfreetEffect(FreneticEfreetEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null && permanent != null) { + if (controller.flipCoin(game)) { + return permanent.phaseOut(game); + } else { + permanent.sacrifice(source.getSourceId(), game); + return true; + } + } + return false; + } + + @Override + public FreneticEfreetEffect copy() { + return new FreneticEfreetEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/GrangerGuildmage.java b/Mage.Sets/src/mage/sets/mirage/GrangerGuildmage.java new file mode 100644 index 00000000000..04609c2db9e --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/GrangerGuildmage.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GrangerGuildmage extends CardImpl { + + public GrangerGuildmage(UUID ownerId) { + super(ownerId, 118, "Granger Guildmage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{G}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {R}, {tap}: Granger Guildmage deals 1 damage to target creature or player and 1 damage to you. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new ManaCostsImpl("{R}")); + ability.addCost(new TapSourceCost()); + ability.addEffect(new DamageControllerEffect(1)); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + + // {W}, {tap}: Target creature gains first strike until end of turn. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public GrangerGuildmage(final GrangerGuildmage card) { + super(card); + } + + @Override + public GrangerGuildmage copy() { + return new GrangerGuildmage(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/HammerOfBogardan.java b/Mage.Sets/src/mage/sets/mirage/HammerOfBogardan.java index 43bce3d67f7..fc954383305 100644 --- a/Mage.Sets/src/mage/sets/mirage/HammerOfBogardan.java +++ b/Mage.Sets/src/mage/sets/mirage/HammerOfBogardan.java @@ -29,15 +29,15 @@ package mage.sets.mirage; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.condition.common.IsStepCondition; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.decorator.ConditionalActivatedAbility; import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.effects.common.ReturnSourceFromGraveyardToHandEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.PhaseStep; +import mage.constants.Rarity; import mage.constants.Zone; import mage.target.common.TargetCreatureOrPlayer; @@ -58,8 +58,8 @@ public class HammerOfBogardan extends CardImpl { this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); // {2}{R}{R}{R}: Return Hammer of Bogardan from your graveyard to your hand. Activate this ability only during your upkeep. - this.addAbility(new ConditionalActivatedAbility(Zone.GRAVEYARD, - new ReturnSourceFromGraveyardToHandEffect(), new ManaCostsImpl("{2}{R}{R}{R}"), new IsStepCondition(PhaseStep.END_COMBAT), null)); + this.addAbility(new ConditionalActivatedAbility(Zone.GRAVEYARD, + new ReturnSourceFromGraveyardToHandEffect(), new ManaCostsImpl("{2}{R}{R}{R}"), new IsStepCondition(PhaseStep.UPKEEP), null)); } public HammerOfBogardan(final HammerOfBogardan card) { diff --git a/Mage.Sets/src/mage/sets/mirage/Illumination.java b/Mage.Sets/src/mage/sets/mirage/Illumination.java new file mode 100644 index 00000000000..cbf7f23238c --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Illumination.java @@ -0,0 +1,121 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterSpell; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.game.stack.Spell; +import mage.players.Player; +import mage.target.TargetSpell; + +/** + * + * @author fireshoes + */ +public class Illumination extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("artifact or enchantment spell"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.ENCHANTMENT))); + } + + public Illumination(UUID ownerId) { + super(ownerId, 225, "Illumination", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{W}{W}"); + this.expansionSetCode = "MIR"; + + // Counter target artifact or enchantment spell. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetSpell(filter)); + + // Its controller gains life equal to its converted mana cost. + this.getSpellAbility().addEffect(new IlluminationEffect()); + } + + public Illumination(final Illumination card) { + super(card); + } + + @Override + public Illumination copy() { + return new Illumination(this); + } +} + +class IlluminationEffect extends OneShotEffect { + + public IlluminationEffect() { + super(Outcome.GainLife); + staticText = "Its controller gains life equal to its converted mana cost"; + } + + public IlluminationEffect(final IlluminationEffect effect) { + super(effect); + } + + @Override + public IlluminationEffect copy() { + return new IlluminationEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + UUID targetId = source.getFirstTarget(); + Player controller = null; + boolean countered = false; + if (targetId != null) { + controller = game.getPlayer(game.getControllerId(targetId)); + } + if (targetId != null + && game.getStack().counter(targetId, source.getSourceId(), game)) { + countered = true; + } + if (controller != null) { + Spell spell = game.getStack().getSpell(targetPointer.getFirst(game, source)); + int cost = spell.getManaCost().convertedManaCost(); + Player player = game.getPlayer(spell.getControllerId()); + if (player != null) { + player.gainLife(cost, game); + } + return true; + } + return countered; + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/Jolt.java b/Mage.Sets/src/mage/sets/mirage/Jolt.java new file mode 100644 index 00000000000..820ea3ba0e0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Jolt.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.MayTapOrUntapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class Jolt extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public Jolt(UUID ownerId) { + super(ownerId, 70, "Jolt", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{U}"); + this.expansionSetCode = "MIR"; + + // You may tap or untap target artifact, creature, or land. + this.getSpellAbility().addEffect(new MayTapOrUntapTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + + // Draw a card at the beginning of the next turn's upkeep. + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false)); + } + + public Jolt(final Jolt card) { + super(card); + } + + @Override + public Jolt copy() { + return new Jolt(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/JunglePatrol.java b/Mage.Sets/src/mage/sets/mirage/JunglePatrol.java new file mode 100644 index 00000000000..e7c75ea8bb2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/JunglePatrol.java @@ -0,0 +1,106 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.Mana; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.BasicManaEffect; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.filter.predicate.permanent.TokenPredicate; +import mage.game.permanent.token.Token; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class JunglePatrol extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("a token named Wood"); + + static { + filter.add(new NamePredicate("Wood")); + filter.add(new TokenPredicate()); + } + + public JunglePatrol(UUID ownerId) { + super(ownerId, 121, "Jungle Patrol", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // {1}{G}, {tap}: Put a 0/1 green Wall creature token with defender named Wood onto the battlefield. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new WoodToken()), new ManaCostsImpl("{1}{G}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + + // Sacrifice a token named Wood: Add {R} to your mana pool. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BasicManaEffect(Mana.RedMana), + new SacrificeTargetCost(new TargetControlledPermanent(1, 1, filter, true)))); + } + + public JunglePatrol(final JunglePatrol card) { + super(card); + } + + @Override + public JunglePatrol copy() { + return new JunglePatrol(this); + } +} + +class WoodToken extends Token { + + public WoodToken() { + super("Wood", "0/1 green Wall creature token with defender named Wood"); + this.setOriginalExpansionSetCode("MIR"); + cardType.add(CardType.CREATURE); + color.setGreen(true); + subtype.add("Wall"); + power = new MageInt(0); + toughness = new MageInt(1); + + this.addAbility(DefenderAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/JungleTroll.java b/Mage.Sets/src/mage/sets/mirage/JungleTroll.java new file mode 100644 index 00000000000..90d9e7671bf --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/JungleTroll.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class JungleTroll extends CardImpl { + + public JungleTroll(UUID ownerId) { + super(ownerId, 329, "Jungle Troll", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}{G}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Troll"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // {R}: Regenerate Jungle Troll. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{R}"))); + + // {G}: Regenerate Jungle Troll. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{G}"))); + } + + public JungleTroll(final JungleTroll card) { + super(card); + } + + @Override + public JungleTroll copy() { + return new JungleTroll(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/KukemssaSerpent.java b/Mage.Sets/src/mage/sets/mirage/KukemssaSerpent.java new file mode 100644 index 00000000000..783848eb3a4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/KukemssaSerpent.java @@ -0,0 +1,99 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class KukemssaSerpent extends CardImpl { + + private static final FilterLandPermanent filterOpponentLand = new FilterLandPermanent("land an opponent controls"); + private static final FilterControlledLandPermanent filterControlledLand = new FilterControlledLandPermanent("an Island"); + + static { + filterOpponentLand.add(new ControllerPredicate(TargetController.OPPONENT)); + filterControlledLand.add(new SubtypePredicate("Island")); + } + + public KukemssaSerpent(UUID ownerId) { + super(ownerId, 72, "Kukemssa Serpent", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Serpent"); + this.power = new MageInt(4); + this.toughness = new MageInt(3); + + // Kukemssa Serpent can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // {U}, Sacrifice an Island: Target land an opponent controls becomes an Island until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Island"), new ManaCostsImpl("{U}")); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(1, 1, filterControlledLand, true))); + ability.addTarget(new TargetLandPermanent(filterOpponentLand)); + this.addAbility(ability); + + // When you control no Islands, sacrifice Kukemssa Serpent. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public KukemssaSerpent(final KukemssaSerpent card) { + super(card); + } + + @Override + public KukemssaSerpent copy() { + return new KukemssaSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/LocustSwarm.java b/Mage.Sets/src/mage/sets/mirage/LocustSwarm.java new file mode 100644 index 00000000000..03326978950 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/LocustSwarm.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.LimitedTimesPerTurnActivatedAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.abilities.effects.common.UntapSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class LocustSwarm extends CardImpl { + + public LocustSwarm(UUID ownerId) { + super(ownerId, 124, "Locust Swarm", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Insect"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {G}: Regenerate Locust Swarm. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{G}"))); + + // {G}: Untap Locust Swarm. Activate this ability only once each turn. + this.addAbility(new LimitedTimesPerTurnActivatedAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new ManaCostsImpl("{G}"))); + } + + public LocustSwarm(final LocustSwarm card) { + super(card); + } + + @Override + public LocustSwarm copy() { + return new LocustSwarm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/MistDragon.java b/Mage.Sets/src/mage/sets/mirage/MistDragon.java new file mode 100644 index 00000000000..672b23b45e5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/MistDragon.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PhaseOutSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.effects.common.continuous.LoseAbilitySourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class MistDragon extends CardImpl { + + public MistDragon(UUID ownerId) { + super(ownerId, 79, "Mist Dragon", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{U}{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Dragon"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // {0}: Mist Dragon gains flying. This effect lasts indefinitely + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield), new GenericManaCost(0))); + + // {0}: Mist Dragon loses flying. This effect lasts indefinitely + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new LoseAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield), new GenericManaCost(0))); + + // {3}{U}{U}: Mist Dragon phases out. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PhaseOutSourceEffect(), new ManaCostsImpl("{3}{U}{U}"))); + } + + public MistDragon(final MistDragon card) { + super(card); + } + + @Override + public MistDragon copy() { + return new MistDragon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/PaupersCage.java b/Mage.Sets/src/mage/sets/mirage/PaupersCage.java new file mode 100644 index 00000000000..7a2d0d3741d --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/PaupersCage.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class PaupersCage extends CardImpl { + + public PaupersCage(UUID ownerId) { + super(ownerId, 279, "Paupers' Cage", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "MIR"; + + // At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, Paupers' Cage deals 2 damage to him or her. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, + new DamageTargetEffect(2), TargetController.OPPONENT, false, true); + CardsInHandCondition condition = new CardsInHandCondition(CardsInHandCondition.CountType.FEWER_THAN, 3); + this.addAbility(new ConditionalTriggeredAbility(ability, condition, "At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, {this} deals 2 damage to him or her.")); + } + + public PaupersCage(final PaupersCage card) { + super(card); + } + + @Override + public PaupersCage copy() { + return new PaupersCage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/PoliticalTrickery.java b/Mage.Sets/src/mage/sets/mirage/PoliticalTrickery.java new file mode 100644 index 00000000000..75727938267 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/PoliticalTrickery.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; + +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.ExchangeControlTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author andyfries + */ +public class PoliticalTrickery extends CardImpl { + + private static final String rule = "exchange control of target land you control and target land an opponent controls"; + + private static final FilterLandPermanent filter = new FilterLandPermanent("land an opponent controls"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public PoliticalTrickery(UUID ownerId) { + super(ownerId, 81, "Political Trickery", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{2}{U}"); + this.expansionSetCode = "MIR"; + + // Exchange control of target land you control and target land an opponent controls. + Effect effect = new ExchangeControlTargetEffect(Duration.EndOfGame, rule, false, true); + effect.setText("exchange control of target land you control and target land an opponent controls"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetControlledPermanent(new FilterControlledLandPermanent())); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + } + + public PoliticalTrickery(final PoliticalTrickery card) { + super(card); + } + + @Override + public PoliticalTrickery copy() { + return new PoliticalTrickery(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/RagingSpirit.java b/Mage.Sets/src/mage/sets/mirage/RagingSpirit.java new file mode 100644 index 00000000000..436e9f76045 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/RagingSpirit.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesColorSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class RagingSpirit extends CardImpl { + + public RagingSpirit(UUID ownerId) { + super(ownerId, 188, "Raging Spirit", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Spirit"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {2}: Raging Spirit becomes colorless until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorSourceEffect(new ObjectColor(), Duration.EndOfTurn), new ManaCostsImpl("{2}"))); + } + + public RagingSpirit(final RagingSpirit card) { + super(card); + } + + @Override + public RagingSpirit copy() { + return new RagingSpirit(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/RealityRipple.java b/Mage.Sets/src/mage/sets/mirage/RealityRipple.java new file mode 100644 index 00000000000..1ec6929a7c6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/RealityRipple.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.effects.common.PhaseOutTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class RealityRipple extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public RealityRipple(UUID ownerId) { + super(ownerId, 87, "Reality Ripple", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{U}"); + this.expansionSetCode = "MIR"; + + // Target artifact, creature, or land phases out. + this.getSpellAbility().addEffect(new PhaseOutTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + } + + public RealityRipple(final RealityRipple card) { + super(card); + } + + @Override + public RealityRipple copy() { + return new RealityRipple(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/RitualOfSteel.java b/Mage.Sets/src/mage/sets/mirage/RitualOfSteel.java new file mode 100644 index 00000000000..b3e56b3a3e9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/RitualOfSteel.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class RitualOfSteel extends CardImpl { + + public RitualOfSteel(UUID ownerId) { + super(ownerId, 240, "Ritual of Steel", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // When Ritual of Steel enters the battlefield, draw a card at the beginning of the next turn's upkeep. + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateDelayedTriggeredAbilityEffect(new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(new DrawCardSourceControllerEffect(1)), false))); + + // Enchanted creature gets +0/+2. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(0,2, Duration.WhileOnBattlefield))); + } + + public RitualOfSteel(final RitualOfSteel card) { + super(card); + } + + @Override + public RitualOfSteel copy() { + return new RitualOfSteel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/SapphireCharm.java b/Mage.Sets/src/mage/sets/mirage/SapphireCharm.java new file mode 100644 index 00000000000..187e8399b5f --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/SapphireCharm.java @@ -0,0 +1,93 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.common.delayed.AtTheBeginOfNextUpkeepDelayedTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.DrawCardTargetEffect; +import mage.abilities.effects.common.PhaseOutTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.TargetPlayer; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SapphireCharm extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature an opponent controls"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public SapphireCharm(UUID ownerId) { + super(ownerId, 89, "Sapphire Charm", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{U}"); + this.expansionSetCode = "MIR"; + + // Choose one - Target player draws a card at the beginning of the next turn's upkeep; + Effect effect = new DrawCardTargetEffect(1); + effect.setText("Target player draws a card"); + this.getSpellAbility().addEffect(new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextUpkeepDelayedTriggeredAbility(effect), true)); + this.getSpellAbility().addTarget(new TargetPlayer()); + + // or target creature gains flying until end of turn; + Mode mode = new Mode(); + mode.getEffects().add(new GainAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn)); + mode.getTargets().add(new TargetCreaturePermanent()); + this.getSpellAbility().addMode(mode); + + // or target creature an opponent controls phases out. + mode = new Mode(); + mode.getEffects().add(new PhaseOutTargetEffect()); + mode.getTargets().add(new TargetCreaturePermanent(filter)); + this.getSpellAbility().addMode(mode); + } + + public SapphireCharm(final SapphireCharm card) { + super(card); + } + + @Override + public SapphireCharm copy() { + return new SapphireCharm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/ShadowGuildmage.java b/Mage.Sets/src/mage/sets/mirage/ShadowGuildmage.java new file mode 100644 index 00000000000..a85110dc505 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/ShadowGuildmage.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageControllerEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class ShadowGuildmage extends CardImpl { + + public ShadowGuildmage(UUID ownerId) { + super(ownerId, 38, "Shadow Guildmage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {U}, {tap}: Put target creature you control on top of its owner's library. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutOnLibraryTargetEffect(true), new ManaCostsImpl("{U}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetControlledCreaturePermanent()); + this.addAbility(ability); + + // {R}, {tap}: Shadow Guildmage deals 1 damage to target creature or player and 1 damage to you. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new ManaCostsImpl("{R}")); + ability.addCost(new TapSourceCost()); + ability.addEffect(new DamageControllerEffect(1)); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public ShadowGuildmage(final ShadowGuildmage card) { + super(card); + } + + @Override + public ShadowGuildmage copy() { + return new ShadowGuildmage(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/ShaperGuildmage.java b/Mage.Sets/src/mage/sets/mirage/ShaperGuildmage.java new file mode 100644 index 00000000000..9a7f7354b6e --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/ShaperGuildmage.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class ShaperGuildmage extends CardImpl { + + public ShaperGuildmage(UUID ownerId) { + super(ownerId, 91, "Shaper Guildmage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {W}, {tap}: Target creature gains first strike until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // {B}, {tap}: Target creature gets +1/+0 until end of turn. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{B}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public ShaperGuildmage(final ShaperGuildmage card) { + super(card); + } + + @Override + public ShaperGuildmage copy() { + return new ShaperGuildmage(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/Shimmer.java b/Mage.Sets/src/mage/sets/mirage/Shimmer.java new file mode 100644 index 00000000000..0f17fa2768d --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Shimmer.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.ChooseLandTypeEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.PhasingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; + +/** + * + * @author fireshoes + */ +public class Shimmer extends CardImpl { + + public Shimmer(UUID ownerId) { + super(ownerId, 92, "Shimmer", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}{U}"); + this.expansionSetCode = "MIR"; + + // As Shimmer enters the battlefield, choose a land type. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseLandTypeEffect(Outcome.Detriment))); + + // Each land of the chosen type has phasing. + FilterLandPermanent filter = new FilterLandPermanent("Each land of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(PhasingAbility.getInstance(), Duration.WhileOnBattlefield, filter, false))); + } + + public Shimmer(final Shimmer card) { + super(card); + } + + @Override + public Shimmer copy() { + return new Shimmer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/SkulkingGhost.java b/Mage.Sets/src/mage/sets/mirage/SkulkingGhost.java new file mode 100644 index 00000000000..e6c67922517 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/SkulkingGhost.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BecomesTargetTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class SkulkingGhost extends CardImpl { + + public SkulkingGhost(UUID ownerId) { + super(ownerId, 41, "Skulking Ghost", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Spirit"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // When Skulking Ghost becomes the target of a spell or ability, sacrifice it. + this.addAbility(new BecomesTargetTriggeredAbility(new SacrificeSourceEffect())); + } + + public SkulkingGhost(final SkulkingGhost card) { + super(card); + } + + @Override + public SkulkingGhost copy() { + return new SkulkingGhost(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/Taniwha.java b/Mage.Sets/src/mage/sets/mirage/Taniwha.java new file mode 100644 index 00000000000..15b0e0426ff --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Taniwha.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.PhasingAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterControlledLandPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class Taniwha extends CardImpl { + + public Taniwha(UUID ownerId) { + super(ownerId, 95, "Taniwha", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "MIR"; + this.supertype.add("Legendary"); + this.subtype.add("Serpent"); + this.power = new MageInt(7); + this.toughness = new MageInt(7); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // Phasing + this.addAbility(PhasingAbility.getInstance()); + + // At the beginning of your upkeep, all lands you control phase out. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new TaniwhaEffect(), TargetController.YOU, false)); + } + + public Taniwha(final Taniwha card) { + super(card); + } + + @Override + public Taniwha copy() { + return new Taniwha(this); + } +} + +class TaniwhaEffect extends OneShotEffect { + + public TaniwhaEffect() { + super(Outcome.Detriment); + this.staticText = "all lands you control phase out"; + } + + public TaniwhaEffect(final TaniwhaEffect effect) { + super(effect); + } + + @Override + public TaniwhaEffect copy() { + return new TaniwhaEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + for (Permanent permanent : game.getBattlefield().getActivePermanents(new FilterControlledLandPermanent(), controller.getId(), game)) { + permanent.phaseOut(game); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/TeferisCurse.java b/Mage.Sets/src/mage/sets/mirage/TeferisCurse.java new file mode 100644 index 00000000000..340d1172f01 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/TeferisCurse.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.PhasingAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class TeferisCurse extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact or creature"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.ARTIFACT))); + } + + public TeferisCurse(UUID ownerId) { + super(ownerId, 96, "Teferi's Curse", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Aura"); + + // Enchant artifact or creature + TargetPermanent auraTarget = new TargetPermanent(filter); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted permanent has phasing. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(PhasingAbility.getInstance(), AttachmentType.AURA))); + } + + public TeferisCurse(final TeferisCurse card) { + super(card); + } + + @Override + public TeferisCurse copy() { + return new TeferisCurse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/Thirst.java b/Mage.Sets/src/mage/sets/mirage/Thirst.java new file mode 100644 index 00000000000..db2df103b70 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/Thirst.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.TapEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Thirst extends CardImpl { + + public Thirst(UUID ownerId) { + super(ownerId, 104, "Thirst", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + // When Thirst enters the battlefield, tap enchanted creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapEnchantedEffect())); + // Enchanted creature doesn't untap during its controller's untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepEnchantedEffect())); + // At the beginning of your upkeep, sacrifice Thirst unless you pay {U}. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new ManaCostsImpl("{U}")), + TargetController.YOU, false)); + } + + public Thirst(final Thirst card) { + super(card); + } + + @Override + public Thirst copy() { + return new Thirst(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/VaporousDjinn.java b/Mage.Sets/src/mage/sets/mirage/VaporousDjinn.java new file mode 100644 index 00000000000..5d264035798 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/VaporousDjinn.java @@ -0,0 +1,109 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.costs.Cost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class VaporousDjinn extends CardImpl { + + public VaporousDjinn(UUID ownerId) { + super(ownerId, 101, "Vaporous Djinn", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{U}{U}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Djinn"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // At the beginning of your upkeep, Vaporous Djinn phases out unless you pay {U}{U}. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new VaporousDjinnEffect(), TargetController.YOU, false)); + } + + public VaporousDjinn(final VaporousDjinn card) { + super(card); + } + + @Override + public VaporousDjinn copy() { + return new VaporousDjinn(this); + } +} + +class VaporousDjinnEffect extends OneShotEffect { + + public VaporousDjinnEffect() { + super(Outcome.Damage); + this.staticText = "{this} phases out unless you pay {U}{U}"; + } + + public VaporousDjinnEffect(final VaporousDjinnEffect effect) { + super(effect); + } + + @Override + public VaporousDjinnEffect copy() { + return new VaporousDjinnEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + Cost cost = new ManaCostsImpl("{U}{U}"); + String message = "Would you like to pay {U}{U} to prevent {this} from phasing out?"; + if (!(controller.chooseUse(Outcome.Benefit, message, source, game) + && cost.pay(source, game, source.getSourceId(), controller.getId(), false))) { + permanent.phaseOut(game); + } + return true; + } + return false; + } + +} diff --git a/Mage.Sets/src/mage/sets/mirage/WildfireEmissary.java b/Mage.Sets/src/mage/sets/mirage/WildfireEmissary.java new file mode 100644 index 00000000000..bfb6722778d --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/WildfireEmissary.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class WildfireEmissary extends CardImpl { + + private static final FilterCard filter = new FilterCard("white"); + + static { + filter.add(new ColorPredicate(ObjectColor.WHITE)); + } + + public WildfireEmissary(UUID ownerId) { + super(ownerId, 203, "Wildfire Emissary", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Efreet"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // Protection from white + this.addAbility(new ProtectionAbility(filter)); + + // {1}{R}: Wildfire Emissary gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{1}{R}"))); + } + + public WildfireEmissary(final WildfireEmissary card) { + super(card); + } + + @Override + public WildfireEmissary copy() { + return new WildfireEmissary(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirage/WitheringBoon.java b/Mage.Sets/src/mage/sets/mirage/WitheringBoon.java new file mode 100644 index 00000000000..60bf5a1f635 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/WitheringBoon.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterSpell; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetSpell; + +/** + * + * @author markedagain + */ +public class WitheringBoon extends CardImpl { + private static final FilterSpell filter = new FilterSpell("creature spell"); + + static { + filter.add(new CardTypePredicate(CardType.CREATURE)); + } + public WitheringBoon(UUID ownerId) { + super(ownerId, 50, "Withering Boon", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "MIR"; + + // As an additional cost to cast Withering Boon, pay 3 life. + this.getSpellAbility().addCost(new PayLifeCost(3)); + // Counter target creature spell. + this.getSpellAbility().addEffect(new CounterTargetEffect()); + this.getSpellAbility().addTarget(new TargetSpell(filter)); + } + + public WitheringBoon(final WitheringBoon card) { + super(card); + } + + @Override + public WitheringBoon copy() { + return new WitheringBoon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirage/ZebraUnicorn.java b/Mage.Sets/src/mage/sets/mirage/ZebraUnicorn.java new file mode 100644 index 00000000000..0997b3149db --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirage/ZebraUnicorn.java @@ -0,0 +1,62 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ZebraUnicorn extends CardImpl { + + public ZebraUnicorn(UUID ownerId) { + super(ownerId, 350, "Zebra Unicorn", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{W}"); + this.expansionSetCode = "MIR"; + this.subtype.add("Unicorn"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Zebra Unicorn deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public ZebraUnicorn(final ZebraUnicorn card) { + super(card); + } + + @Override + public ZebraUnicorn copy() { + return new ZebraUnicorn(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/AEtherSpellbomb.java b/Mage.Sets/src/mage/sets/mirrodin/AEtherSpellbomb.java index f13888a6974..c27b2d019f5 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AEtherSpellbomb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AEtherSpellbomb.java @@ -45,7 +45,7 @@ public class AEtherSpellbomb extends mage.sets.elspethvstezzeret.AEtherSpellbomb super(card); } - @Override + @java.lang.Override public AEtherSpellbomb copy() { return new AEtherSpellbomb(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AlphaMyr.java b/Mage.Sets/src/mage/sets/mirrodin/AlphaMyr.java index 613bb3e4333..8928b1b1576 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AlphaMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AlphaMyr.java @@ -52,7 +52,7 @@ public class AlphaMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public AlphaMyr copy() { return new AlphaMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AltarsLight.java b/Mage.Sets/src/mage/sets/mirrodin/AltarsLight.java index 4bc72f29f63..adc976a3857 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AltarsLight.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AltarsLight.java @@ -63,7 +63,7 @@ public class AltarsLight extends CardImpl { super(card); } - @Override + @java.lang.Override public AltarsLight copy() { return new AltarsLight(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AncientDen.java b/Mage.Sets/src/mage/sets/mirrodin/AncientDen.java index 8093e62ee86..6d813331cc8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AncientDen.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AncientDen.java @@ -50,7 +50,7 @@ public class AncientDen extends CardImpl { super(card); } - @Override + @java.lang.Override public AncientDen copy() { return new AncientDen(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Annul.java b/Mage.Sets/src/mage/sets/mirrodin/Annul.java index 9399d38cfeb..c24d2101e2c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Annul.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Annul.java @@ -63,7 +63,7 @@ public class Annul extends CardImpl { super(card); } - @Override + @java.lang.Override public Annul copy() { return new Annul(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ArcSlogger.java b/Mage.Sets/src/mage/sets/mirrodin/ArcSlogger.java index 55669920259..a69747adbeb 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ArcSlogger.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ArcSlogger.java @@ -65,7 +65,7 @@ public class ArcSlogger extends CardImpl { super(card); } - @Override + @java.lang.Override public ArcSlogger copy() { return new ArcSlogger(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Arrest.java b/Mage.Sets/src/mage/sets/mirrodin/Arrest.java index aaf206d24f5..6cd9dafc0ca 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Arrest.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Arrest.java @@ -70,7 +70,7 @@ public class Arrest extends CardImpl { super(card); } - @Override + @java.lang.Override public Arrest copy() { return new Arrest(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AssertAuthority.java b/Mage.Sets/src/mage/sets/mirrodin/AssertAuthority.java index a392b15f731..3651291548e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AssertAuthority.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AssertAuthority.java @@ -58,7 +58,7 @@ public class AssertAuthority extends CardImpl { super(card); } - @Override + @java.lang.Override public AssertAuthority copy() { return new AssertAuthority(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Atog.java b/Mage.Sets/src/mage/sets/mirrodin/Atog.java index 5a31d2ef6ec..5d9f5f00368 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Atog.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Atog.java @@ -68,7 +68,7 @@ public class Atog extends CardImpl { super(card); } - @Override + @java.lang.Override public Atog copy() { return new Atog(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AuriokBladewarden.java b/Mage.Sets/src/mage/sets/mirrodin/AuriokBladewarden.java index cc710102337..0c0565c3884 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AuriokBladewarden.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AuriokBladewarden.java @@ -67,7 +67,7 @@ public class AuriokBladewarden extends CardImpl { super(card); } - @Override + @java.lang.Override public AuriokBladewarden copy() { return new AuriokBladewarden(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/AuriokSteelshaper.java b/Mage.Sets/src/mage/sets/mirrodin/AuriokSteelshaper.java index bc0d94da411..fdd7ffdd470 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AuriokSteelshaper.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AuriokSteelshaper.java @@ -82,7 +82,7 @@ public class AuriokSteelshaper extends CardImpl { super(card); } - @Override + @java.lang.Override public AuriokSteelshaper copy() { return new AuriokSteelshaper(this); } @@ -99,18 +99,18 @@ class AuriokSteelshaperCostReductionEffect extends CostModificationEffectImpl { super(effect); } - @Override + @java.lang.Override public AuriokSteelshaperCostReductionEffect copy() { return new AuriokSteelshaperCostReductionEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source, Ability abilityToModify) { CardUtil.reduceCost(abilityToModify, 1); return true; } - @Override + @java.lang.Override public boolean applies(Ability abilityToModify, Ability source, Game game) { return abilityToModify.getControllerId().equals(source.getControllerId()) && (abilityToModify instanceof EquipAbility); diff --git a/Mage.Sets/src/mage/sets/mirrodin/AuriokTransfixer.java b/Mage.Sets/src/mage/sets/mirrodin/AuriokTransfixer.java index f2cf65be8f3..2c0ee1ec022 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/AuriokTransfixer.java +++ b/Mage.Sets/src/mage/sets/mirrodin/AuriokTransfixer.java @@ -73,7 +73,7 @@ public class AuriokTransfixer extends CardImpl { super(card); } - @Override + @java.lang.Override public AuriokTransfixer copy() { return new AuriokTransfixer(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BansheesBlade.java b/Mage.Sets/src/mage/sets/mirrodin/BansheesBlade.java index 896454e6952..f3fe9728c3b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BansheesBlade.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BansheesBlade.java @@ -71,7 +71,7 @@ public class BansheesBlade extends CardImpl { super(card); } - @Override + @java.lang.Override public BansheesBlade copy() { return new BansheesBlade(this); } @@ -91,12 +91,12 @@ class BansheesBladeAbility extends TriggeredAbilityImpl { this.usedInPhase = ability.usedInPhase; } - @Override + @java.lang.Override public BansheesBladeAbility copy() { return new BansheesBladeAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DAMAGED_PLAYER || event.getType() == EventType.DAMAGED_CREATURE @@ -104,7 +104,7 @@ class BansheesBladeAbility extends TriggeredAbilityImpl { || event.getType() == EventType.COMBAT_DAMAGE_STEP_PRE; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { if (event instanceof DamagedEvent && ((DamagedEvent) event).isCombatDamage() && !usedInPhase) { Permanent permanent = game.getPermanent(event.getSourceId()); @@ -119,7 +119,7 @@ class BansheesBladeAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever equipped creature deals combat damage, put a charge counter on {this}."; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BarterInBlood.java b/Mage.Sets/src/mage/sets/mirrodin/BarterInBlood.java index 7ffb3d2db32..b4b2d060adf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BarterInBlood.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BarterInBlood.java @@ -45,7 +45,7 @@ public class BarterInBlood extends mage.sets.avacynrestored.BarterInBlood { super(card); } - @Override + @java.lang.Override public BarterInBlood copy() { return new BarterInBlood(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Battlegrowth.java b/Mage.Sets/src/mage/sets/mirrodin/Battlegrowth.java index 266267c2f83..cb5efc7db18 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Battlegrowth.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Battlegrowth.java @@ -53,7 +53,7 @@ public class Battlegrowth extends CardImpl { super(card); } - @Override + @java.lang.Override public Battlegrowth copy() { return new Battlegrowth(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BetrayalOfFlesh.java b/Mage.Sets/src/mage/sets/mirrodin/BetrayalOfFlesh.java index 50d0a33d43e..c03a0219135 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BetrayalOfFlesh.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BetrayalOfFlesh.java @@ -73,7 +73,7 @@ public class BetrayalOfFlesh extends CardImpl { super(card); } - @Override + @java.lang.Override public BetrayalOfFlesh copy() { return new BetrayalOfFlesh(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BlindingBeam.java b/Mage.Sets/src/mage/sets/mirrodin/BlindingBeam.java index b762ddbc0c6..18f2b179b66 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BlindingBeam.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BlindingBeam.java @@ -45,7 +45,7 @@ public class BlindingBeam extends mage.sets.elspethvstezzeret.BlindingBeam { super(card); } - @Override + @java.lang.Override public BlindingBeam copy() { return new BlindingBeam(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BlinkmothUrn.java b/Mage.Sets/src/mage/sets/mirrodin/BlinkmothUrn.java index 5eea8cdfb57..a5ac16b9a1c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BlinkmothUrn.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BlinkmothUrn.java @@ -41,7 +41,7 @@ public class BlinkmothUrn extends CardImpl { super(card); } - @Override + @java.lang.Override public BlinkmothUrn copy() { return new BlinkmothUrn(this); } @@ -59,12 +59,12 @@ class BlinkmothUrnEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public BlinkmothUrnEffect copy() { return new BlinkmothUrnEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(game.getActivePlayerId()); FilterArtifactPermanent filter = new FilterArtifactPermanent("artifacts you control"); diff --git a/Mage.Sets/src/mage/sets/mirrodin/BlinkmothWell.java b/Mage.Sets/src/mage/sets/mirrodin/BlinkmothWell.java index cd023737f93..894222dbb6f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BlinkmothWell.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BlinkmothWell.java @@ -72,7 +72,7 @@ public class BlinkmothWell extends CardImpl { super(card); } - @Override + @java.lang.Override public BlinkmothWell copy() { return new BlinkmothWell(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Bloodscent.java b/Mage.Sets/src/mage/sets/mirrodin/Bloodscent.java index 8fc50760428..2780de6bd8f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Bloodscent.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Bloodscent.java @@ -55,7 +55,7 @@ public class Bloodscent extends CardImpl { super(card); } - @Override + @java.lang.Override public Bloodscent copy() { return new Bloodscent(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Bonesplitter.java b/Mage.Sets/src/mage/sets/mirrodin/Bonesplitter.java index ccf8f2c157c..b2d4c29045e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Bonesplitter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Bonesplitter.java @@ -58,7 +58,7 @@ public class Bonesplitter extends CardImpl { super(card); } - @Override + @java.lang.Override public Bonesplitter copy() { return new Bonesplitter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BoshIronGolem.java b/Mage.Sets/src/mage/sets/mirrodin/BoshIronGolem.java index cd6d64cc785..051bd6d3b9c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BoshIronGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BoshIronGolem.java @@ -45,7 +45,7 @@ public class BoshIronGolem extends mage.sets.planechase.BoshIronGolem { super(card); } - @Override + @java.lang.Override public BoshIronGolem copy() { return new BoshIronGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/BottleGnomes.java b/Mage.Sets/src/mage/sets/mirrodin/BottleGnomes.java index df238073ae0..cf8f159ef17 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/BottleGnomes.java +++ b/Mage.Sets/src/mage/sets/mirrodin/BottleGnomes.java @@ -45,7 +45,7 @@ public class BottleGnomes extends mage.sets.tempest.BottleGnomes { super(card); } - @Override + @java.lang.Override public BottleGnomes copy() { return new BottleGnomes(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Broodstar.java b/Mage.Sets/src/mage/sets/mirrodin/Broodstar.java index 47d749000fe..ae4662db8bb 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Broodstar.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Broodstar.java @@ -45,7 +45,7 @@ public class Broodstar extends mage.sets.planechase.Broodstar { super(card); } - @Override + @java.lang.Override public Broodstar copy() { return new Broodstar(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Cathodion.java b/Mage.Sets/src/mage/sets/mirrodin/Cathodion.java index 8f38f129a8b..6ca82d31e62 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Cathodion.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Cathodion.java @@ -55,7 +55,7 @@ public class Cathodion extends CardImpl { super(card); } - @Override + @java.lang.Override public Cathodion copy() { return new Cathodion(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ChaliceOfTheVoid.java b/Mage.Sets/src/mage/sets/mirrodin/ChaliceOfTheVoid.java index 92255a1111e..9547ef0150b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ChaliceOfTheVoid.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ChaliceOfTheVoid.java @@ -68,7 +68,7 @@ public class ChaliceOfTheVoid extends CardImpl { super(card); } - @Override + @java.lang.Override public ChaliceOfTheVoid copy() { return new ChaliceOfTheVoid(this); } @@ -84,7 +84,7 @@ class ChaliceOfTheVoidEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { @@ -101,7 +101,7 @@ class ChaliceOfTheVoidEffect extends OneShotEffect { return true; } - @Override + @java.lang.Override public ChaliceOfTheVoidEffect copy() { return new ChaliceOfTheVoidEffect(this); } @@ -119,17 +119,17 @@ class ChaliceOfTheVoidTriggeredAbility extends TriggeredAbilityImpl { super(abiltity); } - @Override + @java.lang.Override public ChaliceOfTheVoidTriggeredAbility copy() { return new ChaliceOfTheVoidTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.SPELL_CAST; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { Permanent chalice = game.getPermanent(getSourceId()); Spell spell = game.getStack().getSpell(event.getTargetId()); @@ -142,7 +142,7 @@ class ChaliceOfTheVoidTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever a player casts a spell with converted mana cost equal to the number of charge counters on {this}, counter that spell."; } @@ -159,12 +159,12 @@ class CounterEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public CounterEffect copy() { return new CounterEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { return game.getStack().counter(this.getTargetPointer().getFirst(game, source), source.getSourceId(), game); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ChromaticSphere.java b/Mage.Sets/src/mage/sets/mirrodin/ChromaticSphere.java index 0d8ee852342..1b9b2c20aee 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ChromaticSphere.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ChromaticSphere.java @@ -61,7 +61,7 @@ public class ChromaticSphere extends CardImpl { super(card); } - @Override + @java.lang.Override public ChromaticSphere copy() { return new ChromaticSphere(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ChromeMox.java b/Mage.Sets/src/mage/sets/mirrodin/ChromeMox.java index 00e8256abb9..af94a37a999 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ChromeMox.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ChromeMox.java @@ -73,7 +73,7 @@ public class ChromeMox extends CardImpl { super(card); } - @Override + @java.lang.Override public ChromeMox copy() { return new ChromeMox(this); } @@ -94,7 +94,7 @@ class ChromeMoxEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getControllerId()); if (player.getHand().size() > 0) { @@ -113,7 +113,7 @@ class ChromeMoxEffect extends OneShotEffect { return true; } - @Override + @java.lang.Override public ChromeMoxEffect copy() { return new ChromeMoxEffect(this); } @@ -135,12 +135,12 @@ class ChromeMoxManaEffect extends ManaEffect { - @Override + @java.lang.Override public ChromeMoxManaEffect copy() { return new ChromeMoxManaEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(source.getSourceId()); Player player = game.getPlayer(source.getControllerId()); @@ -197,7 +197,7 @@ class ChromeMoxManaEffect extends ManaEffect { return true; } - @Override + @java.lang.Override public Mana getMana(Game game, Ability source) { return null; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ClockworkBeetle.java b/Mage.Sets/src/mage/sets/mirrodin/ClockworkBeetle.java index 7f91eb2f87d..f544032e83b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ClockworkBeetle.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ClockworkBeetle.java @@ -65,7 +65,7 @@ public class ClockworkBeetle extends CardImpl { super(card); } - @Override + @java.lang.Override public ClockworkBeetle copy() { return new ClockworkBeetle(this); } @@ -81,7 +81,7 @@ class ClockworkBeetleEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent p = game.getPermanent(source.getSourceId()); if (p != null) { @@ -93,7 +93,7 @@ class ClockworkBeetleEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public ClockworkBeetleEffect copy() { return new ClockworkBeetleEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ClockworkCondor.java b/Mage.Sets/src/mage/sets/mirrodin/ClockworkCondor.java index 6a01b421d45..d995f968486 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ClockworkCondor.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ClockworkCondor.java @@ -68,7 +68,7 @@ public class ClockworkCondor extends CardImpl { super(card); } - @Override + @java.lang.Override public ClockworkCondor copy() { return new ClockworkCondor(this); } @@ -84,7 +84,7 @@ class ClockworkCondorEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent p = game.getPermanent(source.getSourceId()); if (p != null) { @@ -96,7 +96,7 @@ class ClockworkCondorEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public ClockworkCondorEffect copy() { return new ClockworkCondorEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ClockworkDragon.java b/Mage.Sets/src/mage/sets/mirrodin/ClockworkDragon.java index 89edef7ff4d..d478eb1a378 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ClockworkDragon.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ClockworkDragon.java @@ -72,7 +72,7 @@ public class ClockworkDragon extends CardImpl { super(card); } - @Override + @java.lang.Override public ClockworkDragon copy() { return new ClockworkDragon(this); } @@ -88,7 +88,7 @@ class ClockworkDragonEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent p = game.getPermanent(source.getSourceId()); if (p != null) { @@ -100,7 +100,7 @@ class ClockworkDragonEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public ClockworkDragonEffect copy() { return new ClockworkDragonEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ClockworkVorrac.java b/Mage.Sets/src/mage/sets/mirrodin/ClockworkVorrac.java index f51b7517beb..e783cbcbbb4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ClockworkVorrac.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ClockworkVorrac.java @@ -72,7 +72,7 @@ public class ClockworkVorrac extends CardImpl { super(card); } - @Override + @java.lang.Override public ClockworkVorrac copy() { return new ClockworkVorrac(this); } @@ -88,7 +88,7 @@ class ClockworkVorracEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent p = game.getPermanent(source.getSourceId()); if (p != null) { @@ -100,7 +100,7 @@ class ClockworkVorracEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public ClockworkVorracEffect copy() { return new ClockworkVorracEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Cloudpost.java b/Mage.Sets/src/mage/sets/mirrodin/Cloudpost.java index 2de82786bbe..ea6e278bc9e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Cloudpost.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Cloudpost.java @@ -65,7 +65,7 @@ public class Cloudpost extends CardImpl { super(card); } - @Override + @java.lang.Override public Cloudpost copy() { return new Cloudpost(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/CobaltGolem.java b/Mage.Sets/src/mage/sets/mirrodin/CobaltGolem.java index 01c3b87feee..af9c86341d7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/CobaltGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/CobaltGolem.java @@ -59,7 +59,7 @@ public class CobaltGolem extends CardImpl { super(card); } - @Override + @java.lang.Override public CobaltGolem copy() { return new CobaltGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ConsumeSpirit.java b/Mage.Sets/src/mage/sets/mirrodin/ConsumeSpirit.java index c0bea16de08..6c5da656565 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ConsumeSpirit.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ConsumeSpirit.java @@ -47,7 +47,7 @@ public class ConsumeSpirit extends mage.sets.magic2010.ConsumeSpirit { super(card); } - @Override + @java.lang.Override public ConsumeSpirit copy() { return new ConsumeSpirit(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ContaminatedBond.java b/Mage.Sets/src/mage/sets/mirrodin/ContaminatedBond.java index e38e9aa0c8c..b89a4f8a8f0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ContaminatedBond.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ContaminatedBond.java @@ -45,7 +45,7 @@ public class ContaminatedBond extends mage.sets.ninthedition.ContaminatedBond { super(card); } - @Override + @java.lang.Override public ContaminatedBond copy() { return new ContaminatedBond(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/CopperMyr.java b/Mage.Sets/src/mage/sets/mirrodin/CopperMyr.java index 6891e88e69f..395c564520f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/CopperMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/CopperMyr.java @@ -54,7 +54,7 @@ public class CopperMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public CopperMyr copy() { return new CopperMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/CreepingMold.java b/Mage.Sets/src/mage/sets/mirrodin/CreepingMold.java index a6400e102f9..307d6dfea73 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/CreepingMold.java +++ b/Mage.Sets/src/mage/sets/mirrodin/CreepingMold.java @@ -45,7 +45,7 @@ public class CreepingMold extends mage.sets.tenthedition.CreepingMold { super(card); } - @Override + @java.lang.Override public CreepingMold copy() { return new CreepingMold(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/CrystalShard.java b/Mage.Sets/src/mage/sets/mirrodin/CrystalShard.java index 5b6e779b376..5068a42903b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/CrystalShard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/CrystalShard.java @@ -70,7 +70,7 @@ public class CrystalShard extends CardImpl { super(card); } - @Override + @java.lang.Override public CrystalShard copy() { return new CrystalShard(this); } @@ -91,12 +91,12 @@ class CrystalShardEffect extends OneShotEffect { this.cost = effect.cost.copy(); } - @Override + @java.lang.Override public CrystalShardEffect copy() { return new CrystalShardEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/DampingMatrix.java b/Mage.Sets/src/mage/sets/mirrodin/DampingMatrix.java index 491766f4fd2..fb7dfb0f0da 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/DampingMatrix.java +++ b/Mage.Sets/src/mage/sets/mirrodin/DampingMatrix.java @@ -65,7 +65,7 @@ public class DampingMatrix extends CardImpl { super(card); } - @Override + @java.lang.Override public DampingMatrix copy() { return new DampingMatrix(this); } @@ -89,22 +89,22 @@ class DampingMatrixEffect extends ReplacementEffectImpl { super(effect); } - @Override + @java.lang.Override public DampingMatrixEffect copy() { return new DampingMatrixEffect(this); } - @Override + @java.lang.Override public boolean replaceEvent(GameEvent event, Ability source, Game game) { return true; } - @Override + @java.lang.Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == EventType.ACTIVATE_ABILITY; } - @Override + @java.lang.Override public boolean applies(GameEvent event, Ability source, Game game) { MageObject object = game.getObject(event.getSourceId()); if (object instanceof Permanent && filter.match((Permanent)object, game)) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/Deconstruct.java b/Mage.Sets/src/mage/sets/mirrodin/Deconstruct.java index 1e6eef3d172..9ee62a3fbbd 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Deconstruct.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Deconstruct.java @@ -63,7 +63,7 @@ public class Deconstruct extends CardImpl { super(card); } - @Override + @java.lang.Override public Deconstruct copy() { return new Deconstruct(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/DiscipleOfTheVault.java b/Mage.Sets/src/mage/sets/mirrodin/DiscipleOfTheVault.java index 223f4b99aae..6355d354512 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/DiscipleOfTheVault.java +++ b/Mage.Sets/src/mage/sets/mirrodin/DiscipleOfTheVault.java @@ -69,7 +69,7 @@ public class DiscipleOfTheVault extends CardImpl { super(card); } - @Override + @java.lang.Override public DiscipleOfTheVault copy() { return new DiscipleOfTheVault(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/DragonBlood.java b/Mage.Sets/src/mage/sets/mirrodin/DragonBlood.java index e3c6c1015c2..fb9cfeb570c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/DragonBlood.java +++ b/Mage.Sets/src/mage/sets/mirrodin/DragonBlood.java @@ -60,7 +60,7 @@ public class DragonBlood extends CardImpl { super(card); } - @Override + @java.lang.Override public DragonBlood copy() { return new DragonBlood(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/DreamsGrip.java b/Mage.Sets/src/mage/sets/mirrodin/DreamsGrip.java index 1f539e867ee..228e76e2d75 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/DreamsGrip.java +++ b/Mage.Sets/src/mage/sets/mirrodin/DreamsGrip.java @@ -74,7 +74,7 @@ public class DreamsGrip extends CardImpl { super(card); } - @Override + @java.lang.Override public DreamsGrip copy() { return new DreamsGrip(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/DrossProwler.java b/Mage.Sets/src/mage/sets/mirrodin/DrossProwler.java index 060d0a0484a..36fe5a79a4d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/DrossProwler.java +++ b/Mage.Sets/src/mage/sets/mirrodin/DrossProwler.java @@ -55,7 +55,7 @@ public class DrossProwler extends CardImpl { super(card); } - @Override + @java.lang.Override public DrossProwler copy() { return new DrossProwler(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Duplicant.java b/Mage.Sets/src/mage/sets/mirrodin/Duplicant.java index 097ad9b5bbb..97e6c4811d5 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Duplicant.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Duplicant.java @@ -81,7 +81,7 @@ public class Duplicant extends CardImpl { super(card); } - @Override + @java.lang.Override public Duplicant copy() { return new Duplicant(this); } @@ -97,12 +97,12 @@ class ExileTargetEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public ExileTargetEffect copy() { return new ExileTargetEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source)); Permanent sourcePermananent = game.getPermanent(source.getSourceId()); @@ -117,7 +117,7 @@ class ExileTargetEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public String getText(Mode mode) { return "you may exile target nontoken creature"; } @@ -135,12 +135,12 @@ class DuplicantContinuousEffect extends ContinuousEffectImpl { super(effect); } - @Override + @java.lang.Override public DuplicantContinuousEffect copy() { return new DuplicantContinuousEffect(this); } - @Override + @java.lang.Override public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { @@ -172,12 +172,12 @@ class DuplicantContinuousEffect extends ContinuousEffectImpl { return false; } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { return false; } - @Override + @java.lang.Override public boolean hasLayer(Layer layer) { return layer == Layer.PTChangingEffects_7 || layer == Layer.TypeChangingEffects_4; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Duskworker.java b/Mage.Sets/src/mage/sets/mirrodin/Duskworker.java index 5a0c14ff4d2..a3e8b1dcf53 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Duskworker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Duskworker.java @@ -61,7 +61,7 @@ public class Duskworker extends CardImpl { super(card); } - @Override + @java.lang.Override public Duskworker copy() { return new Duskworker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ElfReplica.java b/Mage.Sets/src/mage/sets/mirrodin/ElfReplica.java index 13842387642..c7a006aa34a 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ElfReplica.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ElfReplica.java @@ -71,7 +71,7 @@ public class ElfReplica extends CardImpl { super(card); } - @Override + @java.lang.Override public ElfReplica copy() { return new ElfReplica(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/EmpyrialPlate.java b/Mage.Sets/src/mage/sets/mirrodin/EmpyrialPlate.java index 8e670b1954b..f4f896cb3d9 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/EmpyrialPlate.java +++ b/Mage.Sets/src/mage/sets/mirrodin/EmpyrialPlate.java @@ -61,7 +61,7 @@ public class EmpyrialPlate extends CardImpl { super(card); } - @Override + @java.lang.Override public EmpyrialPlate copy() { return new EmpyrialPlate(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ExtraplanarLens.java b/Mage.Sets/src/mage/sets/mirrodin/ExtraplanarLens.java index b019f5c0196..343798c557b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ExtraplanarLens.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ExtraplanarLens.java @@ -73,7 +73,7 @@ public class ExtraplanarLens extends CardImpl { super(card); } - @Override + @java.lang.Override public ExtraplanarLens copy() { return new ExtraplanarLens(this); } @@ -96,7 +96,7 @@ class ExtraplanarLensImprintEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); Permanent extraplanarLens = game.getPermanentOrLKIBattlefield(source.getSourceId()); @@ -118,7 +118,7 @@ class ExtraplanarLensImprintEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public ExtraplanarLensImprintEffect copy() { return new ExtraplanarLensImprintEffect(this); } @@ -135,12 +135,12 @@ class ExtraplanarLensTriggeredAbility extends TriggeredManaAbility { super(ability); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.TAPPED_FOR_MANA; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { Permanent landTappedForMana = game.getPermanentOrLKIBattlefield(event.getSourceId()); Permanent extraplanarLens = game.getPermanent(getSourceId()); @@ -164,12 +164,12 @@ class ExtraplanarLensTriggeredAbility extends TriggeredManaAbility { return false; } - @Override + @java.lang.Override public String getRule() { return new StringBuilder("Whenever a land with the same name as the exiled card is tapped for mana, ").append(super.getRule()).toString(); } - @Override + @java.lang.Override public ExtraplanarLensTriggeredAbility copy() { return new ExtraplanarLensTriggeredAbility(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Fabricate.java b/Mage.Sets/src/mage/sets/mirrodin/Fabricate.java index 17ae471d3d6..f188f69da3f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Fabricate.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Fabricate.java @@ -45,7 +45,7 @@ public class Fabricate extends mage.sets.magic2010.Fabricate { super(card); } - @Override + @java.lang.Override public Fabricate copy() { return new Fabricate(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/FangrenHunter.java b/Mage.Sets/src/mage/sets/mirrodin/FangrenHunter.java index fcda78ed975..a50ce1baf3c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/FangrenHunter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/FangrenHunter.java @@ -55,7 +55,7 @@ public class FangrenHunter extends CardImpl { super(card); } - @Override + @java.lang.Override public FangrenHunter copy() { return new FangrenHunter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/FarsightMask.java b/Mage.Sets/src/mage/sets/mirrodin/FarsightMask.java index 7aa5166950c..3638e18895e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/FarsightMask.java +++ b/Mage.Sets/src/mage/sets/mirrodin/FarsightMask.java @@ -56,7 +56,7 @@ public class FarsightMask extends CardImpl { super(card); } - @Override + @java.lang.Override public FarsightMask copy() { return new FarsightMask(this); } @@ -72,23 +72,23 @@ class FarsightMaskTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public FarsightMaskTriggeredAbility copy() { return new FarsightMaskTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType().equals(GameEvent.EventType.DAMAGED_PLAYER); } - @Override + @java.lang.Override public boolean checkInterveningIfClause(Game game) { Permanent permanent = game.getPermanent(getSourceId()); return permanent != null && !permanent.isTapped(); } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { if (event.getTargetId().equals(controllerId)) { UUID sourceControllerId = game.getControllerId(event.getSourceId()); @@ -99,7 +99,7 @@ class FarsightMaskTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever a source an opponent controls deals damage to you, if {this} is untapped, you may draw a card."; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/FieryGambit.java b/Mage.Sets/src/mage/sets/mirrodin/FieryGambit.java index 25be1b7f876..c95dbad0ffe 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/FieryGambit.java +++ b/Mage.Sets/src/mage/sets/mirrodin/FieryGambit.java @@ -63,7 +63,7 @@ public class FieryGambit extends CardImpl { super(card); } - @Override + @java.lang.Override public FieryGambit copy() { return new FieryGambit(this); } @@ -81,12 +81,12 @@ class FieryGambitEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public FieryGambitEffect copy() { return new FieryGambitEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/Fireshrieker.java b/Mage.Sets/src/mage/sets/mirrodin/Fireshrieker.java index 5371b7da9b4..1e3504d4718 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Fireshrieker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Fireshrieker.java @@ -45,7 +45,7 @@ public class Fireshrieker extends mage.sets.magic2014.Fireshrieker { super(card); } - @Override + @java.lang.Override public Fireshrieker copy() { return new Fireshrieker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/FistsOfTheAnvil.java b/Mage.Sets/src/mage/sets/mirrodin/FistsOfTheAnvil.java index 2f42a1b0885..c091e6f2b64 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/FistsOfTheAnvil.java +++ b/Mage.Sets/src/mage/sets/mirrodin/FistsOfTheAnvil.java @@ -45,7 +45,7 @@ public class FistsOfTheAnvil extends mage.sets.tenthedition.FistsOfTheAnvil { super(card); } - @Override + @java.lang.Override public FistsOfTheAnvil copy() { return new FistsOfTheAnvil(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Forest1.java b/Mage.Sets/src/mage/sets/mirrodin/Forest1.java index d3c05ea5c41..417118b11a5 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Forest1.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Forest1.java @@ -44,7 +44,7 @@ public class Forest1 extends mage.cards.basiclands.Forest { super(card); } - @Override + @java.lang.Override public Forest1 copy() { return new Forest1(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Forest2.java b/Mage.Sets/src/mage/sets/mirrodin/Forest2.java index ff6380dca76..fd9f4b3e5f8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Forest2.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Forest2.java @@ -44,7 +44,7 @@ public class Forest2 extends mage.cards.basiclands.Forest { super(card); } - @Override + @java.lang.Override public Forest2 copy() { return new Forest2(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Forest3.java b/Mage.Sets/src/mage/sets/mirrodin/Forest3.java index 3b443dff6ea..5bc9d69b785 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Forest3.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Forest3.java @@ -44,7 +44,7 @@ public class Forest3 extends mage.cards.basiclands.Forest { super(card); } - @Override + @java.lang.Override public Forest3 copy() { return new Forest3(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Forest4.java b/Mage.Sets/src/mage/sets/mirrodin/Forest4.java index 676ccafb7c4..12bfcb4ed7d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Forest4.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Forest4.java @@ -44,7 +44,7 @@ public class Forest4 extends mage.cards.basiclands.Forest { super(card); } - @Override + @java.lang.Override public Forest4 copy() { return new Forest4(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Frogmite.java b/Mage.Sets/src/mage/sets/mirrodin/Frogmite.java index e5bf48cfe45..e4de69dba56 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Frogmite.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Frogmite.java @@ -45,7 +45,7 @@ public class Frogmite extends mage.sets.elspethvstezzeret.Frogmite { super(card); } - @Override + @java.lang.Override public Frogmite copy() { return new Frogmite(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GalvanicKey.java b/Mage.Sets/src/mage/sets/mirrodin/GalvanicKey.java index 57fba23da17..31cf76f1fa3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GalvanicKey.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GalvanicKey.java @@ -69,7 +69,7 @@ public class GalvanicKey extends CardImpl { super(card); } - @Override + @java.lang.Override public GalvanicKey copy() { return new GalvanicKey(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GildedLotus.java b/Mage.Sets/src/mage/sets/mirrodin/GildedLotus.java index b3a9670c521..afd3842ee6c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GildedLotus.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GildedLotus.java @@ -45,7 +45,7 @@ public class GildedLotus extends mage.sets.magic2013.GildedLotus { super(card); } - @Override + @java.lang.Override public GildedLotus copy() { return new GildedLotus(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Glimmervoid.java b/Mage.Sets/src/mage/sets/mirrodin/Glimmervoid.java index f8f27d33be2..75ab8e50f04 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Glimmervoid.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Glimmervoid.java @@ -60,7 +60,7 @@ public class Glimmervoid extends CardImpl { super(card); } - @Override + @java.lang.Override public Glimmervoid copy() { return new Glimmervoid(this); } @@ -76,17 +76,17 @@ class GlimmervoidTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public GlimmervoidTriggeredAbility copy() { return new GlimmervoidTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.END_TURN_STEP_PRE; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { FilterArtifactPermanent filter = new FilterArtifactPermanent(); if (!game.getBattlefield().contains(filter, controllerId, 1, game)) { @@ -95,7 +95,7 @@ class GlimmervoidTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "At the beginning of the end step, if you control no artifacts, sacrifice {this}."; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GlissaSunseeker.java b/Mage.Sets/src/mage/sets/mirrodin/GlissaSunseeker.java new file mode 100644 index 00000000000..4e6bc4c5fe6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/GlissaSunseeker.java @@ -0,0 +1,116 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.ManaPool; +import mage.players.Player; +import mage.target.common.TargetArtifactPermanent; + +/** + * + * @author fireshoes + */ +public class GlissaSunseeker extends CardImpl { + + public GlissaSunseeker(UUID ownerId) { + super(ownerId, 120, "Glissa Sunseeker", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); + this.expansionSetCode = "MRD"; + this.supertype.add("Legendary"); + this.subtype.add("Elf"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // First strike + this.addAbility(FirstStrikeAbility.getInstance()); + + // {tap}: Destroy target artifact if its converted mana cost is equal to the amount of mana in your mana pool. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GlissaSunseekerEffect(), new TapSourceCost()); + ability.addTarget(new TargetArtifactPermanent()); + this.addAbility(ability); + } + + public GlissaSunseeker(final GlissaSunseeker card) { + super(card); + } + + @java.lang.Override + public GlissaSunseeker copy() { + return new GlissaSunseeker(this); + } +} + +class GlissaSunseekerEffect extends OneShotEffect { + + public GlissaSunseekerEffect() { + super(Outcome.DestroyPermanent); + this.staticText = "Destroy target artifact if its converted mana cost is equal to the amount of mana in your mana pool"; + } + + public GlissaSunseekerEffect(final GlissaSunseekerEffect effect) { + super(effect); + } + + @java.lang.Override + public GlissaSunseekerEffect copy() { + return new GlissaSunseekerEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + ManaPool pool = controller.getManaPool(); + int blackMana = pool.getBlack(); + int whiteMana = pool.getWhite(); + int blueMana = pool.getBlue(); + int greenMana = pool.getGreen(); + int redMana = pool.getRed(); + int colorlessMana = pool.getColorless(); + int manaPoolTotal = blackMana + whiteMana + blueMana + greenMana + redMana + colorlessMana; + Permanent permanent = game.getPermanent(getTargetPointer().getFirst(game, source)); + if (controller != null && permanent != null) { + if (permanent.getManaCost().convertedManaCost() == manaPoolTotal) { + return permanent.destroy(source.getSourceId(), game, false); + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/GoblinCharbelcher.java b/Mage.Sets/src/mage/sets/mirrodin/GoblinCharbelcher.java index 4d592923a78..654c4e4dcf4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GoblinCharbelcher.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GoblinCharbelcher.java @@ -68,7 +68,7 @@ public class GoblinCharbelcher extends CardImpl { super(card); } - @Override + @java.lang.Override public GoblinCharbelcher copy() { return new GoblinCharbelcher(this); } @@ -85,12 +85,12 @@ class GoblinCharbelcherEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public GoblinCharbelcherEffect copy() { return new GoblinCharbelcherEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { boolean isMountain = false; MageObject sourceObject = game.getObject(source.getSourceId()); diff --git a/Mage.Sets/src/mage/sets/mirrodin/GoblinReplica.java b/Mage.Sets/src/mage/sets/mirrodin/GoblinReplica.java index d5b315d609b..aeffd5c109f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GoblinReplica.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GoblinReplica.java @@ -71,7 +71,7 @@ public class GoblinReplica extends CardImpl { super(card); } - @Override + @java.lang.Override public GoblinReplica copy() { return new GoblinReplica(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GoblinStriker.java b/Mage.Sets/src/mage/sets/mirrodin/GoblinStriker.java index 51ad002083e..e0944b2ca6e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GoblinStriker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GoblinStriker.java @@ -58,7 +58,7 @@ public class GoblinStriker extends CardImpl { super(card); } - @Override + @java.lang.Override public GoblinStriker copy() { return new GoblinStriker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GoldMyr.java b/Mage.Sets/src/mage/sets/mirrodin/GoldMyr.java index 843a45b4361..6f1fd69cb86 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GoldMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GoldMyr.java @@ -54,7 +54,7 @@ public class GoldMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public GoldMyr copy() { return new GoldMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GolemSkinGauntlets.java b/Mage.Sets/src/mage/sets/mirrodin/GolemSkinGauntlets.java index bfbead38c77..b5beeb571e4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GolemSkinGauntlets.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GolemSkinGauntlets.java @@ -62,7 +62,7 @@ public class GolemSkinGauntlets extends CardImpl { super(card); } - @Override + @java.lang.Override public GolemSkinGauntlets copy() { return new GolemSkinGauntlets(this); } @@ -78,7 +78,7 @@ class GolemSkinGauntletsAttachedCount implements DynamicValue { public GolemSkinGauntletsAttachedCount(final GolemSkinGauntletsAttachedCount dynamicValue) { } - @Override + @java.lang.Override public int calculate(Game game, Ability source, Effect effect) { int count = 0; Permanent equipment = game.getPermanent(source.getSourceId()); @@ -98,17 +98,17 @@ class GolemSkinGauntletsAttachedCount implements DynamicValue { return count; } - @Override + @java.lang.Override public DynamicValue copy() { return new GolemSkinGauntletsAttachedCount(this); } - @Override + @java.lang.Override public String toString() { return "1"; } - @Override + @java.lang.Override public String getMessage() { return "Equipment attached to it"; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GrabTheReins.java b/Mage.Sets/src/mage/sets/mirrodin/GrabTheReins.java index 905ef340f27..1cbdbdbb751 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GrabTheReins.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GrabTheReins.java @@ -89,7 +89,7 @@ public class GrabTheReins extends CardImpl { super(card); } - @Override + @java.lang.Override public GrabTheReins copy() { return new GrabTheReins(this); } @@ -106,7 +106,7 @@ class GrabTheReinsEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { UUID controllerId = source.getControllerId(); Target target = new TargetCreaturePermanent(); @@ -142,7 +142,7 @@ class GrabTheReinsEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public GrabTheReinsEffect copy() { return new GrabTheReinsEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GreatFurnace.java b/Mage.Sets/src/mage/sets/mirrodin/GreatFurnace.java index 5a759d25d87..abe44d7765b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/GreatFurnace.java +++ b/Mage.Sets/src/mage/sets/mirrodin/GreatFurnace.java @@ -50,7 +50,7 @@ public class GreatFurnace extends CardImpl { super(card); } - @Override + @java.lang.Override public GreatFurnace copy() { return new GreatFurnace(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/GridMonitor.java b/Mage.Sets/src/mage/sets/mirrodin/GridMonitor.java new file mode 100644 index 00000000000..7ef1888e8c9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/GridMonitor.java @@ -0,0 +1,103 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author fireshoes + */ +public class GridMonitor extends CardImpl { + + public GridMonitor(UUID ownerId) { + super(ownerId, 183, "Grid Monitor", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{4}"); + this.expansionSetCode = "MRD"; + this.subtype.add("Construct"); + this.power = new MageInt(4); + this.toughness = new MageInt(6); + + // You can't cast creature spells. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GridMonitorEffect())); + } + + public GridMonitor(final GridMonitor card) { + super(card); + } + + @java.lang.Override + public GridMonitor copy() { + return new GridMonitor(this); + } +} + +class GridMonitorEffect extends ContinuousRuleModifyingEffectImpl { + + public GridMonitorEffect() { + super(Duration.WhileOnBattlefield, Outcome.Detriment); + staticText = "You can't cast creature spells"; + } + + public GridMonitorEffect(final GridMonitorEffect effect) { + super(effect); + } + + @java.lang.Override + public GridMonitorEffect copy() { + return new GridMonitorEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + return true; + } + + @java.lang.Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getType() == GameEvent.EventType.CAST_SPELL && event.getPlayerId().equals(source.getControllerId())) { + MageObject object = game.getObject(event.getSourceId()); + if (object.getCardType().contains(CardType.CREATURE)) { + return true; + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/HematiteGolem.java b/Mage.Sets/src/mage/sets/mirrodin/HematiteGolem.java index c35522ba369..0e8e54ad99f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/HematiteGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/HematiteGolem.java @@ -58,7 +58,7 @@ public class HematiteGolem extends CardImpl { super(card); } - @Override + @java.lang.Override public HematiteGolem copy() { return new HematiteGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/IcyManipulator.java b/Mage.Sets/src/mage/sets/mirrodin/IcyManipulator.java index 20129833d89..5a453583f16 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/IcyManipulator.java +++ b/Mage.Sets/src/mage/sets/mirrodin/IcyManipulator.java @@ -45,7 +45,7 @@ public class IcyManipulator extends mage.sets.tenthedition.IcyManipulator { super(card); } - @Override + @java.lang.Override public IcyManipulator copy() { return new IcyManipulator(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/InciteWar.java b/Mage.Sets/src/mage/sets/mirrodin/InciteWar.java new file mode 100644 index 00000000000..b7635f2125e --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/InciteWar.java @@ -0,0 +1,119 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.RequirementEffect; +import mage.abilities.effects.common.combat.AttacksIfAbleAllEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class InciteWar extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures you control"); + + static { + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public InciteWar(UUID ownerId) { + super(ownerId, 96, "Incite War", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); + this.expansionSetCode = "MRD"; + + // Choose one - Creatures target player controls attack this turn if able; + this.getSpellAbility().addEffect(new InciteWarMustAttackEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + + // or creatures you control gain first strike until end of turn. + Mode mode = new Mode(); + mode.getEffects().add(new GainAbilityAllEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn, filter)); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {2} + this.addAbility(new EntwineAbility("{2}")); + } + + public InciteWar(final InciteWar card) { + super(card); + } + + @java.lang.Override + public InciteWar copy() { + return new InciteWar(this); + } +} + +class InciteWarMustAttackEffect extends OneShotEffect { + + public InciteWarMustAttackEffect() { + super(Outcome.Detriment); + staticText = "Creatures target player control attack this turn if able"; + } + + public InciteWarMustAttackEffect(final InciteWarMustAttackEffect effect) { + super(effect); + } + + @java.lang.Override + public InciteWarMustAttackEffect copy() { + return new InciteWarMustAttackEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(this.getTargetPointer().getFirst(game, source)); + if (player != null) { + FilterCreaturePermanent filter = new FilterCreaturePermanent(); + filter.add(new ControllerIdPredicate(player.getId())); + RequirementEffect effect = new AttacksIfAbleAllEffect(filter, Duration.EndOfTurn); + game.addEffect(effect, source); + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/IronMyr.java b/Mage.Sets/src/mage/sets/mirrodin/IronMyr.java index b8b92d7c430..713188380d4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/IronMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/IronMyr.java @@ -54,7 +54,7 @@ public class IronMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public IronMyr copy() { return new IronMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Island1.java b/Mage.Sets/src/mage/sets/mirrodin/Island1.java index 40c253b9aa8..5465691330f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Island1.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Island1.java @@ -45,7 +45,7 @@ public class Island1 extends mage.cards.basiclands.Island { super(card); } - @Override + @java.lang.Override public Island1 copy() { return new Island1(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Island2.java b/Mage.Sets/src/mage/sets/mirrodin/Island2.java index c4493783a81..882a0f8fe8b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Island2.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Island2.java @@ -45,7 +45,7 @@ public class Island2 extends mage.cards.basiclands.Island { super(card); } - @Override + @java.lang.Override public Island2 copy() { return new Island2(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Island3.java b/Mage.Sets/src/mage/sets/mirrodin/Island3.java index 09a395efda9..56ff70d0132 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Island3.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Island3.java @@ -45,7 +45,7 @@ public class Island3 extends mage.cards.basiclands.Island { super(card); } - @Override + @java.lang.Override public Island3 copy() { return new Island3(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Island4.java b/Mage.Sets/src/mage/sets/mirrodin/Island4.java index 2a43af0bf73..a6f457c94d0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Island4.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Island4.java @@ -45,7 +45,7 @@ public class Island4 extends mage.cards.basiclands.Island { super(card); } - @Override + @java.lang.Override public Island4 copy() { return new Island4(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/IsochronScepter.java b/Mage.Sets/src/mage/sets/mirrodin/IsochronScepter.java index c66fe327f6a..182669babf1 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/IsochronScepter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/IsochronScepter.java @@ -75,7 +75,7 @@ public class IsochronScepter extends CardImpl { super(card); } - @Override + @java.lang.Override public IsochronScepter copy() { return new IsochronScepter(this); } @@ -98,7 +98,7 @@ class IsochronScepterImprintEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); @@ -124,7 +124,7 @@ class IsochronScepterImprintEffect extends OneShotEffect { } - @Override + @java.lang.Override public IsochronScepterImprintEffect copy() { return new IsochronScepterImprintEffect(this); } @@ -142,12 +142,12 @@ class IsochronScepterCopyEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public IsochronScepterCopyEffect copy() { return new IsochronScepterCopyEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/JinxedChoker.java b/Mage.Sets/src/mage/sets/mirrodin/JinxedChoker.java new file mode 100644 index 00000000000..9ce1f78d594 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/JinxedChoker.java @@ -0,0 +1,180 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfYourEndStepTriggeredAbility; +import mage.abilities.common.OnEventTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DamageControllerEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.effects.common.counter.RemoveCounterSourceEffect; +import mage.cards.CardImpl; +import mage.constants.*; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +import java.lang.Override; +import java.util.UUID; + +/** + * + * @author andyfries + */ + +public class JinxedChoker extends CardImpl { + + public JinxedChoker(UUID ownerId) { + super(ownerId, 189, "Jinxed Choker", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "MRD"; + + // At the beginning of your end step, target opponent gains control of Jinxed Choker and puts a charge counter on it. + Ability endStepAbility = new BeginningOfYourEndStepTriggeredAbility(new JinxedChokerChangeControllerEffect(), false); + endStepAbility.addTarget(new TargetOpponent()); + + AddCountersSourceEffect addCountersSourceEffect = new AddCountersSourceEffect(CounterType.CHARGE.createInstance()); + addCountersSourceEffect.setText(""); + endStepAbility.addEffect(addCountersSourceEffect); + this.addAbility(endStepAbility); + + // At the beginning of your upkeep, Jinxed Choker deals damage to you equal to the number of charge counters on it. + Ability upkeepAbility = new OnEventTriggeredAbility(GameEvent.EventType.UPKEEP_STEP_PRE, "beginning of your upkeep", new DamageControllerEffect(new JinxedChokerDynamicValue()), false); + this.addAbility(upkeepAbility); + + // {3}: Put a charge counter on Jinxed Choker or remove one from it. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new JinxedChokerCounterEffect(), new ManaCostsImpl("{3}")); + this.addAbility(ability); + } + + public JinxedChoker(final JinxedChoker card) { + super(card); + } + + @Override + public JinxedChoker copy() { + return new JinxedChoker(this); + } +} + +class JinxedChokerChangeControllerEffect extends ContinuousEffectImpl { + + public JinxedChokerChangeControllerEffect() { + super(Duration.Custom, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); + staticText = "target opponent gains control of {this} and puts a charge counter on it"; + } + + public JinxedChokerChangeControllerEffect(final JinxedChokerChangeControllerEffect effect) { + super(effect); + } + + @Override + public JinxedChokerChangeControllerEffect copy() { + return new JinxedChokerChangeControllerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = (Permanent) source.getSourceObjectIfItStillExists(game); + if (permanent != null) { + return permanent.changeControllerId(source.getFirstTarget(), game); + } else { + discard(); + } + return false; + } + +} + +class JinxedChokerDynamicValue implements DynamicValue { + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + Permanent permanent = game.getPermanent(sourceAbility.getSourceId()); + + int count = 0; + if (permanent != null){ + count = permanent.getCounters().getCount(CounterType.CHARGE); + } + return count; + } + + @Override + public JinxedChokerDynamicValue copy() { + return new JinxedChokerDynamicValue(); + } + + @Override + public String getMessage() { + return "charge counter on it"; + } + + @Override + public String toString() { + return "1"; + } +} + +class JinxedChokerCounterEffect extends OneShotEffect { + + public JinxedChokerCounterEffect() { + super(Outcome.Detriment); + this.staticText = "Put a charge counter on {this} or remove one from it"; + } + + public JinxedChokerCounterEffect(final JinxedChokerCounterEffect effect) { + super(effect); + } + + @Override + public JinxedChokerCounterEffect copy() { + return new JinxedChokerCounterEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent sourcePermanent = game.getPermanent(source.getSourceId()); + if (controller != null && sourcePermanent != null) { + if (!sourcePermanent.getCounters().containsKey(CounterType.CHARGE) || controller.chooseUse(outcome, "Put a charge counter on? (No removes one)", source, game)) { + return new AddCountersSourceEffect(CounterType.CHARGE.createInstance(), true).apply(game, source); + } else { + return new RemoveCounterSourceEffect(CounterType.CHARGE.createInstance()).apply(game, source); + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/JourneyOfDiscovery.java b/Mage.Sets/src/mage/sets/mirrodin/JourneyOfDiscovery.java new file mode 100644 index 00000000000..40a8f5ee9b9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/JourneyOfDiscovery.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.continuous.PlayAdditionalLandsControllerEffect; +import mage.abilities.effects.common.search.SearchLibraryPutInHandEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterBasicLandCard; +import mage.target.common.TargetCardInLibrary; + +/** + * + * @author fireshoes + */ +public class JourneyOfDiscovery extends CardImpl { + + public JourneyOfDiscovery(UUID ownerId) { + super(ownerId, 123, "Journey of Discovery", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}"); + this.expansionSetCode = "MRD"; + + // Choose one - Search your library for up to two basic land cards, reveal them, put them into your hand, then shuffle your library; + this.getSpellAbility().addEffect(new SearchLibraryPutInHandEffect(new TargetCardInLibrary(0, 2, new FilterBasicLandCard()))); + + // or you may play up to two additional lands this turn. + Mode mode = new Mode(); + mode.getEffects().add(new PlayAdditionalLandsControllerEffect(2, Duration.EndOfTurn)); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {2}{G} + this.addAbility(new EntwineAbility("{2}{G}")); + } + + public JourneyOfDiscovery(final JourneyOfDiscovery card) { + super(card); + } + + @java.lang.Override + public JourneyOfDiscovery copy() { + return new JourneyOfDiscovery(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/KrarkClanGrunt.java b/Mage.Sets/src/mage/sets/mirrodin/KrarkClanGrunt.java index 94ffdedb221..aae26d6f7c5 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/KrarkClanGrunt.java +++ b/Mage.Sets/src/mage/sets/mirrodin/KrarkClanGrunt.java @@ -74,7 +74,7 @@ public class KrarkClanGrunt extends CardImpl { super(card); } - @Override + @java.lang.Override public KrarkClanGrunt copy() { return new KrarkClanGrunt(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/KrarkClanShaman.java b/Mage.Sets/src/mage/sets/mirrodin/KrarkClanShaman.java index a7c8e9e14a8..a146a28a62e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/KrarkClanShaman.java +++ b/Mage.Sets/src/mage/sets/mirrodin/KrarkClanShaman.java @@ -74,7 +74,7 @@ public class KrarkClanShaman extends CardImpl { super(card); } - @Override + @java.lang.Override public KrarkClanShaman copy() { return new KrarkClanShaman(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/KrarksThumb.java b/Mage.Sets/src/mage/sets/mirrodin/KrarksThumb.java index 36535622b0e..0cdacc0dde0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/KrarksThumb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/KrarksThumb.java @@ -61,7 +61,7 @@ public class KrarksThumb extends CardImpl { super(card); } - @Override + @java.lang.Override public KrarksThumb copy() { return new KrarksThumb(this); } @@ -77,7 +77,7 @@ class KrarksThumbEffect extends ReplacementEffectImpl { super(effect); } - @Override + @java.lang.Override public boolean replaceEvent(GameEvent event, Ability source, Game game) { Player player = game.getPlayer(event.getPlayerId()); if (player != null) { @@ -96,22 +96,22 @@ class KrarksThumbEffect extends ReplacementEffectImpl { return false; } - @Override + @java.lang.Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.FLIP_COIN; } - @Override + @java.lang.Override public boolean applies(GameEvent event, Ability source, Game game) { return source.getControllerId().equals(event.getPlayerId()); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { return false; } - @Override + @java.lang.Override public KrarksThumbEffect copy() { return new KrarksThumbEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeadenMyr.java b/Mage.Sets/src/mage/sets/mirrodin/LeadenMyr.java index ffb5900b8bd..7d144062de6 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeadenMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeadenMyr.java @@ -54,7 +54,7 @@ public class LeadenMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public LeadenMyr copy() { return new LeadenMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninAbunas.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninAbunas.java index e8fa6160cfa..540f7a870c1 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninAbunas.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninAbunas.java @@ -64,7 +64,7 @@ public class LeoninAbunas extends CardImpl { super(card); } - @Override + @java.lang.Override public LeoninAbunas copy() { return new LeoninAbunas(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninBladetrap.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninBladetrap.java index 504e83a6da1..654eb93d909 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninBladetrap.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninBladetrap.java @@ -45,7 +45,7 @@ public class LeoninBladetrap extends mage.sets.commander2013.LeoninBladetrap { super(card); } - @Override + @java.lang.Override public LeoninBladetrap copy() { return new LeoninBladetrap(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninDenGuard.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninDenGuard.java index e49cf3faa03..075c2178133 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninDenGuard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninDenGuard.java @@ -73,7 +73,7 @@ public class LeoninDenGuard extends CardImpl { super(card); } - @Override + @java.lang.Override public LeoninDenGuard copy() { return new LeoninDenGuard(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninElder.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninElder.java index c790c360d7e..45986262ef3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninElder.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninElder.java @@ -60,7 +60,7 @@ public class LeoninElder extends CardImpl { super(card); } - @Override + @java.lang.Override public LeoninElder copy() { return new LeoninElder(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninScimitar.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninScimitar.java index f4acfab0167..f2c5a2be69b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninScimitar.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninScimitar.java @@ -47,7 +47,7 @@ public class LeoninScimitar extends mage.sets.tenthedition.LeoninScimitar { super(card); } - @Override + @java.lang.Override public LeoninScimitar copy() { return new LeoninScimitar(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninSkyhunter.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninSkyhunter.java index 2f58b879d29..edf59d4f9bf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninSkyhunter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninSkyhunter.java @@ -56,7 +56,7 @@ public class LeoninSkyhunter extends CardImpl { super(card); } - @Override + @java.lang.Override public LeoninSkyhunter copy() { return new LeoninSkyhunter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LeoninSunStandard.java b/Mage.Sets/src/mage/sets/mirrodin/LeoninSunStandard.java index dbd41164ff9..d24fd96fc10 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LeoninSunStandard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LeoninSunStandard.java @@ -55,7 +55,7 @@ public class LeoninSunStandard extends CardImpl { super(card); } - @Override + @java.lang.Override public LeoninSunStandard copy() { return new LeoninSunStandard(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LifesparkSpellbomb.java b/Mage.Sets/src/mage/sets/mirrodin/LifesparkSpellbomb.java index d16126b5cc9..21ab646e064 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LifesparkSpellbomb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LifesparkSpellbomb.java @@ -71,7 +71,7 @@ public class LifesparkSpellbomb extends CardImpl { super(card); } - @Override + @java.lang.Override public LifesparkSpellbomb copy() { return new LifesparkSpellbomb(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LightningGreaves.java b/Mage.Sets/src/mage/sets/mirrodin/LightningGreaves.java index 73a92cb9deb..391adfcb056 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LightningGreaves.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LightningGreaves.java @@ -68,7 +68,7 @@ public class LightningGreaves extends CardImpl { super(card); } - @Override + @java.lang.Override public LightningGreaves copy() { return new LightningGreaves(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LivingHive.java b/Mage.Sets/src/mage/sets/mirrodin/LivingHive.java index d2e38bc750b..7ba01ec498b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LivingHive.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LivingHive.java @@ -66,7 +66,7 @@ public class LivingHive extends CardImpl { super(card); } - @Override + @java.lang.Override public LivingHive copy() { return new LivingHive(this); } @@ -83,12 +83,12 @@ class LivingHiveEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public LivingHiveEffect copy() { return new LivingHiveEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(targetPointer.getFirst(game, source)); if (player != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/LodestoneMyr.java b/Mage.Sets/src/mage/sets/mirrodin/LodestoneMyr.java index b1f3e0e1457..05a91327a96 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LodestoneMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LodestoneMyr.java @@ -45,7 +45,7 @@ public class LodestoneMyr extends mage.sets.planechase.LodestoneMyr { super(card); } - @Override + @java.lang.Override public LodestoneMyr copy() { return new LodestoneMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LoomingHoverguard.java b/Mage.Sets/src/mage/sets/mirrodin/LoomingHoverguard.java index 3f09d0e5a51..657e07c8546 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LoomingHoverguard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LoomingHoverguard.java @@ -69,7 +69,7 @@ public class LoomingHoverguard extends CardImpl { super(card); } - @Override + @java.lang.Override public LoomingHoverguard copy() { return new LoomingHoverguard(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LoxodonMender.java b/Mage.Sets/src/mage/sets/mirrodin/LoxodonMender.java index 4bcf2cee1ec..f280f831ae7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LoxodonMender.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LoxodonMender.java @@ -73,7 +73,7 @@ public class LoxodonMender extends CardImpl { super(card); } - @Override + @java.lang.Override public LoxodonMender copy() { return new LoxodonMender(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LoxodonPunisher.java b/Mage.Sets/src/mage/sets/mirrodin/LoxodonPunisher.java index edc5fbb0893..9b849c157c1 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LoxodonPunisher.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LoxodonPunisher.java @@ -63,7 +63,7 @@ public class LoxodonPunisher extends CardImpl { super(card); } - @Override + @java.lang.Override public LoxodonPunisher copy() { return new LoxodonPunisher(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LoxodonWarhammer.java b/Mage.Sets/src/mage/sets/mirrodin/LoxodonWarhammer.java index 9c48fc6395e..510bb2b755c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LoxodonWarhammer.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LoxodonWarhammer.java @@ -47,7 +47,7 @@ public class LoxodonWarhammer extends mage.sets.planechase.LoxodonWarhammer { super(card); } - @Override + @java.lang.Override public LoxodonWarhammer copy() { return new LoxodonWarhammer(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LumengridWarden.java b/Mage.Sets/src/mage/sets/mirrodin/LumengridWarden.java index 210c29f8f5d..5729d6d8463 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LumengridWarden.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LumengridWarden.java @@ -45,7 +45,7 @@ public class LumengridWarden extends mage.sets.tenthedition.LumengridWarden { super(card); } - @Override + @java.lang.Override public LumengridWarden copy() { return new LumengridWarden(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/LuminousAngel.java b/Mage.Sets/src/mage/sets/mirrodin/LuminousAngel.java index 7fab125c19d..2bd4c953dff 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/LuminousAngel.java +++ b/Mage.Sets/src/mage/sets/mirrodin/LuminousAngel.java @@ -60,7 +60,7 @@ public class LuminousAngel extends CardImpl { super(card); } - @Override + @java.lang.Override public LuminousAngel copy() { return new LuminousAngel(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MalachiteGolem.java b/Mage.Sets/src/mage/sets/mirrodin/MalachiteGolem.java index c1b768a0e7f..354cb3b493c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MalachiteGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MalachiteGolem.java @@ -59,7 +59,7 @@ public class MalachiteGolem extends CardImpl { super(card); } - @Override + @java.lang.Override public MalachiteGolem copy() { return new MalachiteGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MarchOfTheMachines.java b/Mage.Sets/src/mage/sets/mirrodin/MarchOfTheMachines.java index 1c14f4eb5ff..a772a1b0441 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MarchOfTheMachines.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MarchOfTheMachines.java @@ -45,7 +45,7 @@ public class MarchOfTheMachines extends mage.sets.tenthedition.MarchOfTheMachine super(card); } - @Override + @java.lang.Override public MarchOfTheMachines copy() { return new MarchOfTheMachines(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MaskOfMemory.java b/Mage.Sets/src/mage/sets/mirrodin/MaskOfMemory.java index cc13eecf925..1fb2fff1292 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MaskOfMemory.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MaskOfMemory.java @@ -45,7 +45,7 @@ public class MaskOfMemory extends mage.sets.planechase.MaskOfMemory { super(card); } - @Override + @java.lang.Override public MaskOfMemory copy() { return new MaskOfMemory(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MassHysteria.java b/Mage.Sets/src/mage/sets/mirrodin/MassHysteria.java index b48267e3fba..2cc90d37270 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MassHysteria.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MassHysteria.java @@ -56,7 +56,7 @@ public class MassHysteria extends CardImpl { super(card); } - @Override + @java.lang.Override public MassHysteria copy() { return new MassHysteria(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Megatog.java b/Mage.Sets/src/mage/sets/mirrodin/Megatog.java index 801acb392b7..c888442f902 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Megatog.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Megatog.java @@ -72,7 +72,7 @@ public class Megatog extends CardImpl { super(card); } - @Override + @java.lang.Override public Megatog copy() { return new Megatog(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MesmericOrb.java b/Mage.Sets/src/mage/sets/mirrodin/MesmericOrb.java index 7b237c99fef..6e5e1f84b73 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MesmericOrb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MesmericOrb.java @@ -61,7 +61,7 @@ public class MesmericOrb extends CardImpl { super(card); } - @Override + @java.lang.Override public MesmericOrb copy() { return new MesmericOrb(this); } @@ -77,17 +77,17 @@ class BecomesUntappedPermanentTriggeredAbility extends TriggeredAbilityImpl{ super(ability); } - @Override + @java.lang.Override public BecomesUntappedPermanentTriggeredAbility copy() { return new BecomesUntappedPermanentTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.UNTAPPED; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { Permanent permanent = game.getPermanent(event.getTargetId()); if (permanent != null) { @@ -97,7 +97,7 @@ class BecomesUntappedPermanentTriggeredAbility extends TriggeredAbilityImpl{ return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever a permanent becomes untapped, " + super.getRule(); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MindsEye.java b/Mage.Sets/src/mage/sets/mirrodin/MindsEye.java index baec2090119..07dcfcda894 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MindsEye.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MindsEye.java @@ -54,7 +54,7 @@ public class MindsEye extends CardImpl { super(card); } - @Override + @java.lang.Override public MindsEye copy() { return new MindsEye(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Mindslaver.java b/Mage.Sets/src/mage/sets/mirrodin/Mindslaver.java index 10de4e8ae62..1e0e616bc1b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Mindslaver.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Mindslaver.java @@ -47,7 +47,7 @@ public class Mindslaver extends mage.sets.scarsofmirrodin.Mindslaver { super(card); } - @Override + @java.lang.Override public Mindslaver copy() { return new Mindslaver(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MolderSlug.java b/Mage.Sets/src/mage/sets/mirrodin/MolderSlug.java index cefc85a0183..f13d7e10a0e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MolderSlug.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MolderSlug.java @@ -67,7 +67,7 @@ public class MolderSlug extends CardImpl { super(card); } - @Override + @java.lang.Override public MolderSlug copy() { return new MolderSlug(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MoltenRain.java b/Mage.Sets/src/mage/sets/mirrodin/MoltenRain.java index bdcac25004e..e0872cb2b58 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MoltenRain.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MoltenRain.java @@ -63,7 +63,7 @@ public class MoltenRain extends CardImpl { super(card); } - @Override + @java.lang.Override public MoltenRain copy() { return new MoltenRain(this); } @@ -80,12 +80,12 @@ class MoltenRainEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public MoltenRainEffect copy() { return new MoltenRainEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent permanent = (Permanent) game.getLastKnownInformation(source.getFirstTarget(), Zone.BATTLEFIELD); if (permanent != null && !permanent.getSupertype().contains("Basic")) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/Mountain1.java b/Mage.Sets/src/mage/sets/mirrodin/Mountain1.java index 0679b2a11a2..83978d3dd3f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Mountain1.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Mountain1.java @@ -45,7 +45,7 @@ public class Mountain1 extends mage.cards.basiclands.Mountain { super(card); } - @Override + @java.lang.Override public Mountain1 copy() { return new Mountain1(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Mountain2.java b/Mage.Sets/src/mage/sets/mirrodin/Mountain2.java index ea38142bd3c..9190ef81d69 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Mountain2.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Mountain2.java @@ -45,7 +45,7 @@ public class Mountain2 extends mage.cards.basiclands.Mountain { super(card); } - @Override + @java.lang.Override public Mountain2 copy() { return new Mountain2(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Mountain3.java b/Mage.Sets/src/mage/sets/mirrodin/Mountain3.java index 3d4a0dd4bbf..9b13f549bf8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Mountain3.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Mountain3.java @@ -45,7 +45,7 @@ public class Mountain3 extends mage.cards.basiclands.Mountain { super(card); } - @Override + @java.lang.Override public Mountain3 copy() { return new Mountain3(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Mountain4.java b/Mage.Sets/src/mage/sets/mirrodin/Mountain4.java index 7c8639020a4..852a488bb38 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Mountain4.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Mountain4.java @@ -45,7 +45,7 @@ public class Mountain4 extends mage.cards.basiclands.Mountain { super(card); } - @Override + @java.lang.Override public Mountain4 copy() { return new Mountain4(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MyrAdapter.java b/Mage.Sets/src/mage/sets/mirrodin/MyrAdapter.java index 16592471fe2..5ed2e2f88ec 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MyrAdapter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MyrAdapter.java @@ -62,7 +62,7 @@ public class MyrAdapter extends CardImpl { super(card); } - @Override + @java.lang.Override public MyrAdapter copy() { return new MyrAdapter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MyrEnforcer.java b/Mage.Sets/src/mage/sets/mirrodin/MyrEnforcer.java index dbc7ba0755a..75d9999fb58 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MyrEnforcer.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MyrEnforcer.java @@ -45,7 +45,7 @@ public class MyrEnforcer extends mage.sets.planechase.MyrEnforcer { super(card); } - @Override + @java.lang.Override public MyrEnforcer copy() { return new MyrEnforcer(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/MyrRetriever.java b/Mage.Sets/src/mage/sets/mirrodin/MyrRetriever.java index 58fc7b74bf8..7791fdacbed 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/MyrRetriever.java +++ b/Mage.Sets/src/mage/sets/mirrodin/MyrRetriever.java @@ -45,7 +45,7 @@ public class MyrRetriever extends mage.sets.modernmasters.MyrRetriever { super(card); } - @Override + @java.lang.Override public MyrRetriever copy() { return new MyrRetriever(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NecrogenMists.java b/Mage.Sets/src/mage/sets/mirrodin/NecrogenMists.java index a6881b17569..6849b48b767 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NecrogenMists.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NecrogenMists.java @@ -55,7 +55,7 @@ public class NecrogenMists extends CardImpl { super(card); } - @Override + @java.lang.Override public NecrogenMists copy() { return new NecrogenMists(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NecrogenSpellbomb.java b/Mage.Sets/src/mage/sets/mirrodin/NecrogenSpellbomb.java index fcb16b0875d..67655a692a9 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NecrogenSpellbomb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NecrogenSpellbomb.java @@ -65,7 +65,7 @@ public class NecrogenSpellbomb extends CardImpl { super(card); } - @Override + @java.lang.Override public NecrogenSpellbomb copy() { return new NecrogenSpellbomb(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Needlebug.java b/Mage.Sets/src/mage/sets/mirrodin/Needlebug.java index 56f10dfdd45..1bd3e785c7a 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Needlebug.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Needlebug.java @@ -59,7 +59,7 @@ public class Needlebug extends CardImpl { super(card); } - @Override + @java.lang.Override public Needlebug copy() { return new Needlebug(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NeurokHoversail.java b/Mage.Sets/src/mage/sets/mirrodin/NeurokHoversail.java index 6eef00d5055..909d74c8f87 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NeurokHoversail.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NeurokHoversail.java @@ -58,7 +58,7 @@ public class NeurokHoversail extends CardImpl { super(card); } - @Override + @java.lang.Override public NeurokHoversail copy() { return new NeurokHoversail(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NeurokSpy.java b/Mage.Sets/src/mage/sets/mirrodin/NeurokSpy.java index 3dccb51f5d5..51188369f43 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NeurokSpy.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NeurokSpy.java @@ -67,7 +67,7 @@ public class NeurokSpy extends CardImpl { super(card); } - @Override + @java.lang.Override public NeurokSpy copy() { return new NeurokSpy(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NightmareLash.java b/Mage.Sets/src/mage/sets/mirrodin/NightmareLash.java index 2b1afca7485..6afd1d2bab3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NightmareLash.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NightmareLash.java @@ -68,7 +68,7 @@ public class NightmareLash extends CardImpl { super(card); } - @Override + @java.lang.Override public NightmareLash copy() { return new NightmareLash(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NimDevourer.java b/Mage.Sets/src/mage/sets/mirrodin/NimDevourer.java new file mode 100644 index 00000000000..cce49286673 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/NimDevourer.java @@ -0,0 +1,130 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.Target; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class NimDevourer extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("artifact you control"); + + static { + filter.add(new CardTypePredicate(CardType.ARTIFACT)); + } + + public NimDevourer(UUID ownerId) { + super(ownerId, 70, "Nim Devourer", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{B}{B}"); + this.expansionSetCode = "MRD"; + this.subtype.add("Zombie"); + this.power = new MageInt(4); + this.toughness = new MageInt(1); + + // Nim Devourer gets +1/+0 for each artifact you control. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(new PermanentsOnBattlefieldCount(filter), new StaticValue(0), Duration.WhileOnBattlefield))); + + // {B}{B}: Return Nim Devourer from your graveyard to the battlefield, then sacrifice a creature. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility(Zone.GRAVEYARD, + new ReturnSourceFromGraveyardToBattlefieldEffect(), + new ManaCostsImpl("{B}{B}"), + new IsStepCondition(PhaseStep.UPKEEP), null); + ability.addEffect(new NimDevourerEffect()); + this.addAbility(ability); + } + + public NimDevourer(final NimDevourer card) { + super(card); + } + + @java.lang.Override + public NimDevourer copy() { + return new NimDevourer(this); + } +} + +class NimDevourerEffect extends OneShotEffect { + + public NimDevourerEffect() { + super(Outcome.Sacrifice); + this.staticText = "then sacrifice a creature"; + } + + public NimDevourerEffect(final NimDevourerEffect effect) { + super(effect); + } + + @java.lang.Override + public NimDevourerEffect copy() { + return new NimDevourerEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + Target target = new TargetControlledPermanent(new FilterControlledCreaturePermanent()); + + if (target.canChoose(player.getId(), game) && player.choose(Outcome.Sacrifice, target, source.getSourceId(), game)) { + Permanent permanent = game.getPermanent(target.getFirstTarget()); + if (permanent != null) { + return permanent.sacrifice(source.getSourceId(), game); + } + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/NimLasher.java b/Mage.Sets/src/mage/sets/mirrodin/NimLasher.java index 1af1ffcdb64..b3cbc9c3d26 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NimLasher.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NimLasher.java @@ -67,7 +67,7 @@ public class NimLasher extends CardImpl { super(card); } - @Override + @java.lang.Override public NimLasher copy() { return new NimLasher(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NimReplica.java b/Mage.Sets/src/mage/sets/mirrodin/NimReplica.java index 1c1f302394b..a6605795079 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NimReplica.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NimReplica.java @@ -64,7 +64,7 @@ public class NimReplica extends CardImpl { super(card); } - @Override + @java.lang.Override public NimReplica copy() { return new NimReplica(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NimShambler.java b/Mage.Sets/src/mage/sets/mirrodin/NimShambler.java index 57a57fb340b..a3ad4388405 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NimShambler.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NimShambler.java @@ -72,7 +72,7 @@ public class NimShambler extends CardImpl { super(card); } - @Override + @java.lang.Override public NimShambler copy() { return new NimShambler(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NimShrieker.java b/Mage.Sets/src/mage/sets/mirrodin/NimShrieker.java index 8ed76b47f69..b81a37f2018 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NimShrieker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NimShrieker.java @@ -69,7 +69,7 @@ public class NimShrieker extends CardImpl { super(card); } - @Override + @java.lang.Override public NimShrieker copy() { return new NimShrieker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/NuisanceEngine.java b/Mage.Sets/src/mage/sets/mirrodin/NuisanceEngine.java index 3b63bda3f46..184bf4f6dd0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/NuisanceEngine.java +++ b/Mage.Sets/src/mage/sets/mirrodin/NuisanceEngine.java @@ -45,7 +45,7 @@ public class NuisanceEngine extends mage.sets.planechase.NuisanceEngine { super(card); } - @Override + @java.lang.Override public NuisanceEngine copy() { return new NuisanceEngine(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/OblivionStone.java b/Mage.Sets/src/mage/sets/mirrodin/OblivionStone.java index 184dcc1ab32..d0ef92ef316 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/OblivionStone.java +++ b/Mage.Sets/src/mage/sets/mirrodin/OblivionStone.java @@ -71,7 +71,7 @@ public class OblivionStone extends CardImpl { super(card); } - @Override + @java.lang.Override public OblivionStone copy() { return new OblivionStone(this); } @@ -87,7 +87,7 @@ class OblivionStoneEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { for (Permanent p : game.getBattlefield().getAllActivePermanents()) { if (!(p.getCardType().contains(CardType.LAND) || p.getCounters().containsKey(CounterType.FATE))) { @@ -102,7 +102,7 @@ class OblivionStoneEffect extends OneShotEffect { return true; } - @Override + @java.lang.Override public OblivionStoneEffect copy() { return new OblivionStoneEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/OmegaMyr.java b/Mage.Sets/src/mage/sets/mirrodin/OmegaMyr.java index 615a1344097..5f9062daa1f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/OmegaMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/OmegaMyr.java @@ -52,7 +52,7 @@ public class OmegaMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public OmegaMyr copy() { return new OmegaMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/OneDozenEyes.java b/Mage.Sets/src/mage/sets/mirrodin/OneDozenEyes.java index 3518126f722..db0a3d698e7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/OneDozenEyes.java +++ b/Mage.Sets/src/mage/sets/mirrodin/OneDozenEyes.java @@ -45,7 +45,7 @@ public class OneDozenEyes extends mage.sets.commander2013.OneDozenEyes { super(card); } - @Override + @java.lang.Override public OneDozenEyes copy() { return new OneDozenEyes(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Ornithopter.java b/Mage.Sets/src/mage/sets/mirrodin/Ornithopter.java index c64f333279b..78ee448d269 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Ornithopter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Ornithopter.java @@ -45,7 +45,7 @@ public class Ornithopter extends mage.sets.tenthedition.Ornithopter { super(card); } - @Override + @java.lang.Override public Ornithopter copy() { return new Ornithopter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Override.java b/Mage.Sets/src/mage/sets/mirrodin/Override.java new file mode 100644 index 00000000000..396e4e59ae6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/Override.java @@ -0,0 +1,113 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterArtifactPermanent; +import mage.game.Game; +import mage.game.stack.StackObject; +import mage.players.Player; +import mage.target.TargetSpell; + +/** + * + * @author LevelX2 + */ +public class Override extends CardImpl { + + public Override(UUID ownerId) { + super(ownerId, 45, "Override", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{U}"); + this.expansionSetCode = "MRD"; + + // Counter target spell unless its controller pays {1} for each artifact you control. + this.getSpellAbility().addEffect(new OverrideEffect()); + this.getSpellAbility().addTarget(new TargetSpell()); + } + + public Override(final Override card) { + super(card); + } + + @java.lang.Override + public Override copy() { + return new Override(this); + } +} + +class OverrideEffect extends OneShotEffect { + + public OverrideEffect() { + super(Outcome.Benefit); + } + + public OverrideEffect(final OverrideEffect effect) { + super(effect); + } + + @java.lang.Override + public OverrideEffect copy() { + return new OverrideEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + StackObject spell = game.getStack().getStackObject(targetPointer.getFirst(game, source)); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (sourceObject != null && spell != null) { + Player player = game.getPlayer(spell.getControllerId()); + Player controller = game.getPlayer(source.getControllerId()); + if (player != null && controller != null) { + int amount = game.getBattlefield().countAll(new FilterArtifactPermanent(), source.getControllerId(), game); + if (amount > 0) { + GenericManaCost cost = new GenericManaCost(amount); + if (!cost.pay(source, game, spell.getControllerId(), spell.getControllerId(), false)) { + game.informPlayers(sourceObject.getLogName() + ": cost wasn't payed - countering target spell."); + return game.getStack().counter(source.getFirstTarget(), source.getSourceId(), game); + } + } + return true; + } + } + return false; + } + + @java.lang.Override + public String getText(Mode mode) { + return "Counter target spell unless its controller pays {1} for each artifact you control"; + } + +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/PearlShard.java b/Mage.Sets/src/mage/sets/mirrodin/PearlShard.java new file mode 100644 index 00000000000..de7459c3113 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/PearlShard.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class PearlShard extends CardImpl { + + public PearlShard(UUID ownerId) { + super(ownerId, 225, "Pearl Shard", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "MRD"; + + // {3}, {tap} or {W}, {tap}: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new ManaCostsImpl("{3}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public PearlShard(final PearlShard card) { + super(card); + } + + @java.lang.Override + public PearlShard copy() { + return new PearlShard(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/Pentavus.java b/Mage.Sets/src/mage/sets/mirrodin/Pentavus.java index 6fe1b9ea2d9..a8a632e26e3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Pentavus.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Pentavus.java @@ -45,7 +45,7 @@ public class Pentavus extends mage.sets.elspethvstezzeret.Pentavus { super(card); } - @Override + @java.lang.Override public Pentavus copy() { return new Pentavus(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PewterGolem.java b/Mage.Sets/src/mage/sets/mirrodin/PewterGolem.java index 4109de8823f..bac712072bc 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PewterGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PewterGolem.java @@ -57,7 +57,7 @@ public class PewterGolem extends CardImpl { super(card); } - @Override + @java.lang.Override public PewterGolem copy() { return new PewterGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Plains1.java b/Mage.Sets/src/mage/sets/mirrodin/Plains1.java index 10604274df3..36245373646 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Plains1.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Plains1.java @@ -45,7 +45,7 @@ public class Plains1 extends mage.cards.basiclands.Plains { super(card); } - @Override + @java.lang.Override public Plains1 copy() { return new Plains1(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Plains2.java b/Mage.Sets/src/mage/sets/mirrodin/Plains2.java index 6a498371eb0..f0ef9c70afa 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Plains2.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Plains2.java @@ -45,7 +45,7 @@ public class Plains2 extends mage.cards.basiclands.Plains { super(card); } - @Override + @java.lang.Override public Plains2 copy() { return new Plains2(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Plains3.java b/Mage.Sets/src/mage/sets/mirrodin/Plains3.java index 99c444dcc52..6ecb5572b1b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Plains3.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Plains3.java @@ -45,7 +45,7 @@ public class Plains3 extends mage.cards.basiclands.Plains { super(card); } - @Override + @java.lang.Override public Plains3 copy() { return new Plains3(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Plains4.java b/Mage.Sets/src/mage/sets/mirrodin/Plains4.java index ed626f5590d..f0badf9c208 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Plains4.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Plains4.java @@ -45,7 +45,7 @@ public class Plains4 extends mage.cards.basiclands.Plains { super(card); } - @Override + @java.lang.Override public Plains4 copy() { return new Plains4(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PlatedSlagwurm.java b/Mage.Sets/src/mage/sets/mirrodin/PlatedSlagwurm.java index 1e7509f184d..39cd1476dd2 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PlatedSlagwurm.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PlatedSlagwurm.java @@ -55,7 +55,7 @@ public class PlatedSlagwurm extends CardImpl { super(card); } - @Override + @java.lang.Override public PlatedSlagwurm copy() { return new PlatedSlagwurm(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PlatinumAngel.java b/Mage.Sets/src/mage/sets/mirrodin/PlatinumAngel.java index 2fb71ad5da6..f4e95c130ae 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PlatinumAngel.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PlatinumAngel.java @@ -45,7 +45,7 @@ public class PlatinumAngel extends mage.sets.tenthedition.PlatinumAngel { super(card); } - @Override + @java.lang.Override public PlatinumAngel copy() { return new PlatinumAngel(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PredatorsStrike.java b/Mage.Sets/src/mage/sets/mirrodin/PredatorsStrike.java index b4191b97b5b..edc6f1aef44 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PredatorsStrike.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PredatorsStrike.java @@ -57,7 +57,7 @@ public class PredatorsStrike extends CardImpl { super(card); } - @Override + @java.lang.Override public PredatorsStrike copy() { return new PredatorsStrike(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PromiseOfPower.java b/Mage.Sets/src/mage/sets/mirrodin/PromiseOfPower.java index 80706a26221..4296e76d279 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PromiseOfPower.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PromiseOfPower.java @@ -45,7 +45,7 @@ public class PromiseOfPower extends mage.sets.commander2014.PromiseOfPower { super(card); } - @Override + @java.lang.Override public PromiseOfPower copy() { return new PromiseOfPower(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ProteusStaff.java b/Mage.Sets/src/mage/sets/mirrodin/ProteusStaff.java index 1d631448acc..7cfbf933b62 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ProteusStaff.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ProteusStaff.java @@ -69,7 +69,7 @@ public class ProteusStaff extends CardImpl { super(card); } - @Override + @java.lang.Override public ProteusStaff copy() { return new ProteusStaff(this); } @@ -86,12 +86,12 @@ class ProteusStaffEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public ProteusStaffEffect copy() { return new ProteusStaffEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(this.getTargetPointer().getFirst(game, source)); if (permanent != null) { @@ -119,7 +119,7 @@ class ProteusStaffEffect extends OneShotEffect { controller.revealCards("Proteus Staff", cards, game); // and the rest on the bottom of his or her library in any order. - while (cards.size() > 0 && controller.isInGame()) { + while (cards.size() > 0 && controller.canRespond()) { if (cards.size() == 1) { Card card = cards.get(cards.iterator().next(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/PsychicMembrane.java b/Mage.Sets/src/mage/sets/mirrodin/PsychicMembrane.java index 7fb6463e9bd..13d12537019 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PsychicMembrane.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PsychicMembrane.java @@ -59,7 +59,7 @@ public class PsychicMembrane extends CardImpl { super(card); } - @Override + @java.lang.Override public PsychicMembrane copy() { return new PsychicMembrane(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PsychogenicProbe.java b/Mage.Sets/src/mage/sets/mirrodin/PsychogenicProbe.java index 9ce7f410cf2..0c4b4c10041 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PsychogenicProbe.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PsychogenicProbe.java @@ -58,7 +58,7 @@ public class PsychogenicProbe extends CardImpl { super(card); } - @Override + @java.lang.Override public PsychogenicProbe copy() { return new PsychogenicProbe(this); } @@ -74,17 +74,17 @@ class PsychogenicProbeTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public PsychogenicProbeTriggeredAbility copy() { return new PsychogenicProbeTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType().equals(EventType.LIBRARY_SHUFFLED); } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { for (Effect effect : this.getEffects()) { effect.setTargetPointer(new FixedTarget(event.getPlayerId())); @@ -92,7 +92,7 @@ class PsychogenicProbeTriggeredAbility extends TriggeredAbilityImpl { return true; } - @Override + @java.lang.Override public String getRule() { return "Whenever a spell or ability causes a player to shuffle his or her library, Psychogenic Probe deals 2 damage to him or her."; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/PyriteSpellbomb.java b/Mage.Sets/src/mage/sets/mirrodin/PyriteSpellbomb.java index 8b8428a8a3f..23a1e2a8256 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/PyriteSpellbomb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/PyriteSpellbomb.java @@ -65,7 +65,7 @@ public class PyriteSpellbomb extends CardImpl { super(card); } - @Override + @java.lang.Override public PyriteSpellbomb copy() { return new PyriteSpellbomb(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/RaiseTheAlarm.java b/Mage.Sets/src/mage/sets/mirrodin/RaiseTheAlarm.java index a168b852539..86ac6a53c0e 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/RaiseTheAlarm.java +++ b/Mage.Sets/src/mage/sets/mirrodin/RaiseTheAlarm.java @@ -52,7 +52,7 @@ public class RaiseTheAlarm extends CardImpl { super(card); } - @Override + @java.lang.Override public RaiseTheAlarm copy() { return new RaiseTheAlarm(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/RazorBarrier.java b/Mage.Sets/src/mage/sets/mirrodin/RazorBarrier.java index 49b87837480..a9568c08304 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/RazorBarrier.java +++ b/Mage.Sets/src/mage/sets/mirrodin/RazorBarrier.java @@ -45,7 +45,7 @@ public class RazorBarrier extends mage.sets.elspethvstezzeret.RazorBarrier { super(card); } - @Override + @java.lang.Override public RazorBarrier copy() { return new RazorBarrier(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Regress.java b/Mage.Sets/src/mage/sets/mirrodin/Regress.java index c54168c9910..911acf72f85 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Regress.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Regress.java @@ -53,7 +53,7 @@ public class Regress extends CardImpl { super(card); } - @Override + @java.lang.Override public Regress copy() { return new Regress(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ReiverDemon.java b/Mage.Sets/src/mage/sets/mirrodin/ReiverDemon.java index 0f3420423d5..5a6c5a41fe4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ReiverDemon.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ReiverDemon.java @@ -45,7 +45,7 @@ public class ReiverDemon extends mage.sets.divinevsdemonic.ReiverDemon { super(card); } - @Override + @java.lang.Override public ReiverDemon copy() { return new ReiverDemon(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/RoarOfTheKha.java b/Mage.Sets/src/mage/sets/mirrodin/RoarOfTheKha.java new file mode 100644 index 00000000000..c85e9e2474d --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/RoarOfTheKha.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.UntapAllControllerEffect; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class RoarOfTheKha extends CardImpl { + + private static final String rule = "untap all creatures you control"; + + public RoarOfTheKha(UUID ownerId) { + super(ownerId, 18, "Roar of the Kha", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "MRD"; + + // Choose one - Creatures you control get +1/+1 until end of turn; + this.getSpellAbility().addEffect(new BoostControlledEffect(1, 1, Duration.EndOfTurn)); + + // or untap all creatures you control. + Mode mode = new Mode(); + mode.getEffects().add(new UntapAllControllerEffect(new FilterControlledCreaturePermanent(), rule)); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {1}{W} + this.addAbility(new EntwineAbility("{1}{W}")); + } + + public RoarOfTheKha(final RoarOfTheKha card) { + super(card); + } + + @java.lang.Override + public RoarOfTheKha copy() { + return new RoarOfTheKha(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/RuleOfLaw.java b/Mage.Sets/src/mage/sets/mirrodin/RuleOfLaw.java index e30fdd02797..b72076ada60 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/RuleOfLaw.java +++ b/Mage.Sets/src/mage/sets/mirrodin/RuleOfLaw.java @@ -47,7 +47,7 @@ public class RuleOfLaw extends mage.sets.tenthedition.RuleOfLaw { super(card); } - @Override + @java.lang.Override public RuleOfLaw copy() { return new RuleOfLaw(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/RustmouthOgre.java b/Mage.Sets/src/mage/sets/mirrodin/RustmouthOgre.java index 669833fd276..175bc1194e6 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/RustmouthOgre.java +++ b/Mage.Sets/src/mage/sets/mirrodin/RustmouthOgre.java @@ -65,7 +65,7 @@ public class RustmouthOgre extends CardImpl { super(card); } - @Override + @java.lang.Override public RustmouthOgre copy() { return new RustmouthOgre(this); } @@ -81,17 +81,17 @@ class RustmouthOgreTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public RustmouthOgreTriggeredAbility copy() { return new RustmouthOgreTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DAMAGED_PLAYER; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { DamagedPlayerEvent damageEvent = (DamagedPlayerEvent) event; if (damageEvent.isCombatDamage() && event.getSourceId().equals(this.getSourceId())) { @@ -106,7 +106,7 @@ class RustmouthOgreTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever {this} deals combat damage to a player, you may destroy target artifact that player controls."; } diff --git a/Mage.Sets/src/mage/sets/mirrodin/RustsporeRam.java b/Mage.Sets/src/mage/sets/mirrodin/RustsporeRam.java index ea823b712e3..643987c81bf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/RustsporeRam.java +++ b/Mage.Sets/src/mage/sets/mirrodin/RustsporeRam.java @@ -66,7 +66,7 @@ public class RustsporeRam extends CardImpl { super(card); } - @Override + @java.lang.Override public RustsporeRam copy() { return new RustsporeRam(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ScaleOfChissGoria.java b/Mage.Sets/src/mage/sets/mirrodin/ScaleOfChissGoria.java index bb969fccc9f..32f80eceb4c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ScaleOfChissGoria.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ScaleOfChissGoria.java @@ -65,7 +65,7 @@ public class ScaleOfChissGoria extends CardImpl { super(card); } - @Override + @java.lang.Override public ScaleOfChissGoria copy() { return new ScaleOfChissGoria(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ScrabblingClaws.java b/Mage.Sets/src/mage/sets/mirrodin/ScrabblingClaws.java index 22f3b27323b..83c645ba001 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ScrabblingClaws.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ScrabblingClaws.java @@ -74,7 +74,7 @@ public class ScrabblingClaws extends CardImpl { super(card); } - @Override + @java.lang.Override public ScrabblingClaws copy() { return new ScrabblingClaws(this); } @@ -91,12 +91,12 @@ class ScrabblingClawsEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public ScrabblingClawsEffect copy() { return new ScrabblingClawsEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player targetPlayer = game.getPlayer(source.getFirstTarget()); if (targetPlayer != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/SculptingSteel.java b/Mage.Sets/src/mage/sets/mirrodin/SculptingSteel.java index 7c3715074fe..3844913c705 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SculptingSteel.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SculptingSteel.java @@ -45,7 +45,7 @@ public class SculptingSteel extends mage.sets.tenthedition.SculptingSteel { super(card); } - @Override + @java.lang.Override public SculptingSteel copy() { return new SculptingSteel(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ScytheOfTheWretched.java b/Mage.Sets/src/mage/sets/mirrodin/ScytheOfTheWretched.java index 341aecb7194..a0b0f53927a 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ScytheOfTheWretched.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ScytheOfTheWretched.java @@ -79,7 +79,7 @@ public class ScytheOfTheWretched extends CardImpl { super(card); } - @Override + @java.lang.Override public ScytheOfTheWretched copy() { return new ScytheOfTheWretched(this); } @@ -95,17 +95,17 @@ class ScytheOfTheWretchedTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public ScytheOfTheWretchedTriggeredAbility copy() { return new ScytheOfTheWretchedTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.ZONE_CHANGE; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { ZoneChangeEvent zoneChange = (ZoneChangeEvent) event; if (zoneChange.isDiesEvent() && zoneChange.getTarget().getCardType().contains(CardType.CREATURE)) { @@ -122,7 +122,7 @@ class ScytheOfTheWretchedTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever a creature dealt damage by equipped creature this turn dies, " + super.getRule(); } @@ -153,7 +153,7 @@ class ScytheOfTheWretchedReanimateEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Card card = game.getCard(getTargetPointer().getFirst(game, source)); Player controller = game.getPlayer(source.getControllerId()); @@ -169,7 +169,7 @@ class ScytheOfTheWretchedReanimateEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public Effect copy() { return new ScytheOfTheWretchedReanimateEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SeatOfTheSynod.java b/Mage.Sets/src/mage/sets/mirrodin/SeatOfTheSynod.java index a8353a2179d..351536ae651 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SeatOfTheSynod.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SeatOfTheSynod.java @@ -50,7 +50,7 @@ public class SeatOfTheSynod extends CardImpl { super(card); } - @Override + @java.lang.Override public SeatOfTheSynod copy() { return new SeatOfTheSynod(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SecondSunrise.java b/Mage.Sets/src/mage/sets/mirrodin/SecondSunrise.java index 141503c8ef7..376b69c06bb 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SecondSunrise.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SecondSunrise.java @@ -60,7 +60,7 @@ public class SecondSunrise extends CardImpl { super(card); } - @Override + @java.lang.Override public SecondSunrise copy() { return new SecondSunrise(this); } @@ -77,7 +77,7 @@ class SecondSunriseEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { SecondSunriseWatcher watcher = (SecondSunriseWatcher) game.getState().getWatchers().get("SecondSunriseWatcher"); if (watcher != null) { @@ -94,7 +94,7 @@ class SecondSunriseEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public SecondSunriseEffect copy() { return new SecondSunriseEffect(this); } @@ -112,19 +112,19 @@ class SecondSunriseWatcher extends Watcher { this.cards.addAll(watcher.cards); } - @Override + @java.lang.Override public void watch(GameEvent event, Game game) { if (event.getType() == GameEvent.EventType.ZONE_CHANGE && ((ZoneChangeEvent)event).isDiesEvent()) { cards.add(event.getTargetId()); } } - @Override + @java.lang.Override public SecondSunriseWatcher copy() { return new SecondSunriseWatcher(this); } - @Override + @java.lang.Override public void reset() { super.reset(); cards.clear(); diff --git a/Mage.Sets/src/mage/sets/mirrodin/SeethingSong.java b/Mage.Sets/src/mage/sets/mirrodin/SeethingSong.java index 118b7979eca..63ddebe54fd 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SeethingSong.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SeethingSong.java @@ -51,7 +51,7 @@ public class SeethingSong extends CardImpl { super(card); } - @Override + @java.lang.Override public SeethingSong copy() { return new SeethingSong(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Shatter.java b/Mage.Sets/src/mage/sets/mirrodin/Shatter.java index 6c8c5d51543..8b153e8955c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Shatter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Shatter.java @@ -53,7 +53,7 @@ public class Shatter extends CardImpl { super(card); } - @Override + @java.lang.Override public Shatter copy() { return new Shatter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ShrapnelBlast.java b/Mage.Sets/src/mage/sets/mirrodin/ShrapnelBlast.java index c9dda788ef9..4b269946fbb 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ShrapnelBlast.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ShrapnelBlast.java @@ -63,7 +63,7 @@ public class ShrapnelBlast extends CardImpl { super(card); } - @Override + @java.lang.Override public ShrapnelBlast copy() { return new ShrapnelBlast(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SilverMyr.java b/Mage.Sets/src/mage/sets/mirrodin/SilverMyr.java index 024642a8d95..218dd3ecf9d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SilverMyr.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SilverMyr.java @@ -54,7 +54,7 @@ public class SilverMyr extends CardImpl { super(card); } - @Override + @java.lang.Override public SilverMyr copy() { return new SilverMyr(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SkeletonShard.java b/Mage.Sets/src/mage/sets/mirrodin/SkeletonShard.java index 4056a013046..2fe693eadd0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SkeletonShard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SkeletonShard.java @@ -45,7 +45,7 @@ public class SkeletonShard extends mage.sets.planechase.SkeletonShard { super(card); } - @Override + @java.lang.Override public SkeletonShard copy() { return new SkeletonShard(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SkyhunterPatrol.java b/Mage.Sets/src/mage/sets/mirrodin/SkyhunterPatrol.java index 6223384d851..6827426e3d4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SkyhunterPatrol.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SkyhunterPatrol.java @@ -45,7 +45,7 @@ public class SkyhunterPatrol extends mage.sets.tenthedition.SkyhunterPatrol { super(card); } - @Override + @java.lang.Override public SkyhunterPatrol copy() { return new SkyhunterPatrol(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlagwurmArmor.java b/Mage.Sets/src/mage/sets/mirrodin/SlagwurmArmor.java index 9e008c2bf27..ebd9df3c588 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlagwurmArmor.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlagwurmArmor.java @@ -56,7 +56,7 @@ public class SlagwurmArmor extends CardImpl { super(card); } - @Override + @java.lang.Override public SlagwurmArmor copy() { return new SlagwurmArmor(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlithAscendant.java b/Mage.Sets/src/mage/sets/mirrodin/SlithAscendant.java index 931a7b32331..ba749e23710 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlithAscendant.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlithAscendant.java @@ -58,7 +58,7 @@ public class SlithAscendant extends CardImpl { super(card); } - @Override + @java.lang.Override public SlithAscendant copy() { return new SlithAscendant(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlithBloodletter.java b/Mage.Sets/src/mage/sets/mirrodin/SlithBloodletter.java index aa1c5d3eae2..d0f0b07aaa9 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlithBloodletter.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlithBloodletter.java @@ -62,7 +62,7 @@ public class SlithBloodletter extends CardImpl { super(card); } - @Override + @java.lang.Override public SlithBloodletter copy() { return new SlithBloodletter(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlithFirewalker.java b/Mage.Sets/src/mage/sets/mirrodin/SlithFirewalker.java index e6eaf50e072..c129b2dc3f7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlithFirewalker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlithFirewalker.java @@ -58,7 +58,7 @@ public class SlithFirewalker extends CardImpl { super(card); } - @Override + @java.lang.Override public SlithFirewalker copy() { return new SlithFirewalker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlithPredator.java b/Mage.Sets/src/mage/sets/mirrodin/SlithPredator.java index 97f80ea6fe8..37c9e7edbc0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlithPredator.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlithPredator.java @@ -58,7 +58,7 @@ public class SlithPredator extends CardImpl { super(card); } - @Override + @java.lang.Override public SlithPredator copy() { return new SlithPredator(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SlithStrider.java b/Mage.Sets/src/mage/sets/mirrodin/SlithStrider.java index 9f129c8643b..7e63807e137 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SlithStrider.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SlithStrider.java @@ -59,7 +59,7 @@ public class SlithStrider extends CardImpl { super(card); } - @Override + @java.lang.Override public SlithStrider copy() { return new SlithStrider(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SolarTide.java b/Mage.Sets/src/mage/sets/mirrodin/SolarTide.java new file mode 100644 index 00000000000..4ca6d7f86ca --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/SolarTide.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.DestroyAllEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.PowerPredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class SolarTide extends CardImpl { + + private static final FilterCreaturePermanent filter1 = new FilterCreaturePermanent("creatures with power 2 or less"); + private static final FilterCreaturePermanent filter2 = new FilterCreaturePermanent("creatures with power 3 or greater"); + + static { + filter1.add(new PowerPredicate(Filter.ComparisonType.LessThan, 3)); + filter2.add(new PowerPredicate(Filter.ComparisonType.GreaterThan, 2)); + } + + public SolarTide(UUID ownerId) { + super(ownerId, 24, "Solar Tide", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{4}{W}{W}"); + this.expansionSetCode = "MRD"; + + // Choose one - Destroy all creatures with power 2 or less; + this.getSpellAbility().addEffect(new DestroyAllEffect(filter1)); + + // or destroy all creatures with power 3 or greater. + Mode mode = new Mode(); + mode.getEffects().add(new DestroyAllEffect(filter2)); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine-Sacrifice two lands. + this.addAbility(new EntwineAbility(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, new FilterControlledLandPermanent("two lands"), true)))); + } + + public SolarTide(final SolarTide card) { + super(card); + } + + @java.lang.Override + public SolarTide copy() { + return new SolarTide(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/SoldierReplica.java b/Mage.Sets/src/mage/sets/mirrodin/SoldierReplica.java index 51fcef5f56d..c1048cd8bcf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SoldierReplica.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SoldierReplica.java @@ -64,7 +64,7 @@ public class SoldierReplica extends CardImpl { super(card); } - @Override + @java.lang.Override public SoldierReplica copy() { return new SoldierReplica(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SolemnSimulacrum.java b/Mage.Sets/src/mage/sets/mirrodin/SolemnSimulacrum.java index fd2af2f9877..e0d44cc8058 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SolemnSimulacrum.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SolemnSimulacrum.java @@ -45,7 +45,7 @@ public class SolemnSimulacrum extends mage.sets.magic2012.SolemnSimulacrum { super(card); } - @Override + @java.lang.Override public SolemnSimulacrum copy() { return new SolemnSimulacrum(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SomberHoverguard.java b/Mage.Sets/src/mage/sets/mirrodin/SomberHoverguard.java index 2cbd88cb148..33fdc7dbc4f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SomberHoverguard.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SomberHoverguard.java @@ -58,7 +58,7 @@ public class SomberHoverguard extends CardImpl { super(card); } - @Override + @java.lang.Override public SomberHoverguard copy() { return new SomberHoverguard(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SoulFoundry.java b/Mage.Sets/src/mage/sets/mirrodin/SoulFoundry.java index 8e4c6a28792..0ae3d362a29 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SoulFoundry.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SoulFoundry.java @@ -76,7 +76,7 @@ public class SoulFoundry extends CardImpl { super(card); } - @Override + @java.lang.Override public void adjustCosts(Ability ability, Game game) { if (ability instanceof SimpleActivatedAbility) { Permanent sourcePermanent = game.getPermanent(ability.getSourceId()); @@ -99,7 +99,7 @@ public class SoulFoundry extends CardImpl { } } - @Override + @java.lang.Override public SoulFoundry copy() { return new SoulFoundry(this); } @@ -122,7 +122,7 @@ class SoulFoundryImprintEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); @@ -147,7 +147,7 @@ class SoulFoundryImprintEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public SoulFoundryImprintEffect copy() { return new SoulFoundryImprintEffect(this); } @@ -164,7 +164,7 @@ class SoulFoundryEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { @@ -184,7 +184,7 @@ class SoulFoundryEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public SoulFoundryEffect copy() { return new SoulFoundryEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SpikeshotGoblin.java b/Mage.Sets/src/mage/sets/mirrodin/SpikeshotGoblin.java index 58929dcb715..b0ab572b366 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SpikeshotGoblin.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SpikeshotGoblin.java @@ -68,7 +68,7 @@ public class SpikeshotGoblin extends CardImpl { super(card); } - @Override + @java.lang.Override public SpikeshotGoblin copy() { return new SpikeshotGoblin(this); } @@ -84,7 +84,7 @@ class SpikeshotGoblinEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Permanent sourcePermanent = game.getPermanent(source.getSourceId()); if (sourcePermanent == null) { @@ -109,7 +109,7 @@ class SpikeshotGoblinEffect extends OneShotEffect { return false; } - @Override + @java.lang.Override public SpikeshotGoblinEffect copy() { return new SpikeshotGoblinEffect(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SpoilsOfTheVault.java b/Mage.Sets/src/mage/sets/mirrodin/SpoilsOfTheVault.java index f2017a43afa..6629c14c6fb 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SpoilsOfTheVault.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SpoilsOfTheVault.java @@ -53,7 +53,6 @@ public class SpoilsOfTheVault extends CardImpl { super(ownerId, 78, "Spoils of the Vault", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{B}"); this.expansionSetCode = "MRD"; - // Name a card. Reveal cards from the top of your library until you reveal the named card, then put that card into your hand. Exile all other cards revealed this way, and you lose 1 life for each of the exiled cards. this.getSpellAbility().addEffect(new NameACardEffect(NameACardEffect.TypeOfName.ALL)); this.getSpellAbility().addEffect(new SpoilsOfTheVaultEffect()); @@ -63,13 +62,12 @@ public class SpoilsOfTheVault extends CardImpl { super(card); } - @Override + @java.lang.Override public SpoilsOfTheVault copy() { return new SpoilsOfTheVault(this); } } - class SpoilsOfTheVaultEffect extends OneShotEffect { public SpoilsOfTheVaultEffect() { @@ -81,12 +79,12 @@ class SpoilsOfTheVaultEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public SpoilsOfTheVaultEffect copy() { return new SpoilsOfTheVaultEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { MageObject sourceObject = game.getObject(source.getSourceId()); Player controller = game.getPlayer(source.getControllerId()); @@ -94,28 +92,25 @@ class SpoilsOfTheVaultEffect extends OneShotEffect { if (sourceObject == null || controller == null || cardName == null || cardName.isEmpty()) { return false; } - - Cards cards = new CardsImpl(); + + Cards cardsToReveal = new CardsImpl(); + Cards cardsToExile = new CardsImpl(); while (controller.getLibrary().size() > 0) { Card card = controller.getLibrary().removeFromTop(game); if (card != null) { - cards.add(card); - if(card.getName().equals(cardName)){ - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + cardsToReveal.add(card); + if (card.getName().equals(cardName)) { + controller.moveCards(card, null, Zone.HAND, source, game); break; + } else { + cardsToExile.add(card); } - else{ - controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true); - } - } - else{ - break; } } - - controller.revealCards(sourceObject.getName(), cards, game); - controller.loseLife(cards.size(), game); - + controller.revealCards(sourceObject.getIdName(), cardsToReveal, game); + controller.moveCards(cardsToExile, null, Zone.EXILED, source, game); + controller.loseLife(cardsToExile.size(), game); + return true; } } diff --git a/Mage.Sets/src/mage/sets/mirrodin/StalkingStones.java b/Mage.Sets/src/mage/sets/mirrodin/StalkingStones.java index 718a641d777..aa3a43ba3e6 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/StalkingStones.java +++ b/Mage.Sets/src/mage/sets/mirrodin/StalkingStones.java @@ -45,7 +45,7 @@ public class StalkingStones extends mage.sets.tempest.StalkingStones { super(card); } - @Override + @java.lang.Override public StalkingStones copy() { return new StalkingStones(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SteelWall.java b/Mage.Sets/src/mage/sets/mirrodin/SteelWall.java index dea66f273cb..4f63898d32c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SteelWall.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SteelWall.java @@ -54,7 +54,7 @@ public class SteelWall extends CardImpl { super(card); } - @Override + @java.lang.Override public SteelWall copy() { return new SteelWall(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SunDroplet.java b/Mage.Sets/src/mage/sets/mirrodin/SunDroplet.java index 43a3d3ead75..f1c72773b64 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SunDroplet.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SunDroplet.java @@ -45,7 +45,7 @@ public class SunDroplet extends mage.sets.commander2013.SunDroplet { super(card); } - @Override + @java.lang.Override public SunDroplet copy() { return new SunDroplet(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SunbeamSpellbomb.java b/Mage.Sets/src/mage/sets/mirrodin/SunbeamSpellbomb.java index 62eec3e8ff6..e3743d62047 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SunbeamSpellbomb.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SunbeamSpellbomb.java @@ -63,7 +63,7 @@ public class SunbeamSpellbomb extends CardImpl { super(card); } - @Override + @java.lang.Override public SunbeamSpellbomb copy() { return new SunbeamSpellbomb(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Swamp1.java b/Mage.Sets/src/mage/sets/mirrodin/Swamp1.java index d854d42af6e..381b620b2ff 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Swamp1.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Swamp1.java @@ -45,7 +45,7 @@ public class Swamp1 extends mage.cards.basiclands.Swamp { super(card); } - @Override + @java.lang.Override public Swamp1 copy() { return new Swamp1(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Swamp2.java b/Mage.Sets/src/mage/sets/mirrodin/Swamp2.java index 7bd942df3f9..9c31334589f 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Swamp2.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Swamp2.java @@ -45,7 +45,7 @@ public class Swamp2 extends mage.cards.basiclands.Swamp { super(card); } - @Override + @java.lang.Override public Swamp2 copy() { return new Swamp2(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Swamp3.java b/Mage.Sets/src/mage/sets/mirrodin/Swamp3.java index 43839ceed36..459640075b0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Swamp3.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Swamp3.java @@ -45,7 +45,7 @@ public class Swamp3 extends mage.cards.basiclands.Swamp { super(card); } - @Override + @java.lang.Override public Swamp3 copy() { return new Swamp3(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Swamp4.java b/Mage.Sets/src/mage/sets/mirrodin/Swamp4.java index cd33dd58555..da560265cd8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Swamp4.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Swamp4.java @@ -45,7 +45,7 @@ public class Swamp4 extends mage.cards.basiclands.Swamp { super(card); } - @Override + @java.lang.Override public Swamp4 copy() { return new Swamp4(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SwordOfKaldra.java b/Mage.Sets/src/mage/sets/mirrodin/SwordOfKaldra.java index cf7921dbde9..27c6fa36ec0 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SwordOfKaldra.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SwordOfKaldra.java @@ -71,7 +71,7 @@ public class SwordOfKaldra extends CardImpl { super(card); } - @Override + @java.lang.Override public SwordOfKaldra copy() { return new SwordOfKaldra(this); } @@ -87,17 +87,17 @@ class SwordOfKaldraTriggeredAbility extends TriggeredAbilityImpl { super(ability); } - @Override + @java.lang.Override public SwordOfKaldraTriggeredAbility copy() { return new SwordOfKaldraTriggeredAbility(this); } - @Override + @java.lang.Override public boolean checkEventType(GameEvent event, Game game) { return event.getType() == EventType.DAMAGED_CREATURE; } - @Override + @java.lang.Override public boolean checkTrigger(GameEvent event, Game game) { Permanent equipment = game.getPermanent(this.getSourceId()); if (equipment != null @@ -111,7 +111,7 @@ class SwordOfKaldraTriggeredAbility extends TriggeredAbilityImpl { return false; } - @Override + @java.lang.Override public String getRule() { return "Whenever equipped creature deals damage to a creature, " + super.getRule(); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/SylvanScrying.java b/Mage.Sets/src/mage/sets/mirrodin/SylvanScrying.java index 5a061a85b19..6acde907ee5 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/SylvanScrying.java +++ b/Mage.Sets/src/mage/sets/mirrodin/SylvanScrying.java @@ -45,7 +45,7 @@ public class SylvanScrying extends mage.sets.tenthedition.SylvanScrying { super(card); } - @Override + @java.lang.Override public SylvanScrying copy() { return new SylvanScrying(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TajNarSwordsmith.java b/Mage.Sets/src/mage/sets/mirrodin/TajNarSwordsmith.java index 33a834624fb..884f933f931 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TajNarSwordsmith.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TajNarSwordsmith.java @@ -69,7 +69,7 @@ public class TajNarSwordsmith extends CardImpl { super(card); } - @Override + @java.lang.Override public TajNarSwordsmith copy() { return new TajNarSwordsmith(this); } @@ -86,12 +86,12 @@ class TajNarSwordsmithEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public TajNarSwordsmithEffect copy() { return new TajNarSwordsmithEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getControllerId()); if (player != null && player.chooseUse(Outcome.BoostCreature, "Do you want to to pay {X}?", source, game)) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfDominance.java b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfDominance.java index 8501d95ab3f..f22aea13fd3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfDominance.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfDominance.java @@ -62,7 +62,7 @@ public class TalismanOfDominance extends CardImpl { super(card); } - @Override + @java.lang.Override public TalismanOfDominance copy() { return new TalismanOfDominance(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfImpulse.java b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfImpulse.java index 1e191f0249c..f0072e4c5b2 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfImpulse.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfImpulse.java @@ -62,7 +62,7 @@ public class TalismanOfImpulse extends CardImpl { super(card); } - @Override + @java.lang.Override public TalismanOfImpulse copy() { return new TalismanOfImpulse(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfIndulgence.java b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfIndulgence.java index 48cbb1c73e7..d2b54e48067 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfIndulgence.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfIndulgence.java @@ -62,7 +62,7 @@ public class TalismanOfIndulgence extends CardImpl { super(card); } - @Override + @java.lang.Override public TalismanOfIndulgence copy() { return new TalismanOfIndulgence(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfProgress.java b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfProgress.java index d955bb7b8e3..906fe8f676d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfProgress.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfProgress.java @@ -62,7 +62,7 @@ public class TalismanOfProgress extends CardImpl { super(card); } - @Override + @java.lang.Override public TalismanOfProgress copy() { return new TalismanOfProgress(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfUnity.java b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfUnity.java index 3b87ca52e9a..2be502e301b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TalismanOfUnity.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TalismanOfUnity.java @@ -62,7 +62,7 @@ public class TalismanOfUnity extends CardImpl { super(card); } - @Override + @java.lang.Override public TalismanOfUnity copy() { return new TalismanOfUnity(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Tanglebloom.java b/Mage.Sets/src/mage/sets/mirrodin/Tanglebloom.java index d146518970a..c79c011f4db 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Tanglebloom.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Tanglebloom.java @@ -58,7 +58,7 @@ public class Tanglebloom extends CardImpl { super(card); } - @Override + @java.lang.Override public Tanglebloom copy() { return new Tanglebloom(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TelJiladArchers.java b/Mage.Sets/src/mage/sets/mirrodin/TelJiladArchers.java index 0aa6211b08d..2f0dde06bcf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TelJiladArchers.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TelJiladArchers.java @@ -60,7 +60,7 @@ public class TelJiladArchers extends CardImpl { super(card); } - @Override + @java.lang.Override public TelJiladArchers copy() { return new TelJiladArchers(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TelJiladChosen.java b/Mage.Sets/src/mage/sets/mirrodin/TelJiladChosen.java index b6f56f03ca2..e86c45d4846 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TelJiladChosen.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TelJiladChosen.java @@ -57,7 +57,7 @@ public class TelJiladChosen extends CardImpl { super(card); } - @Override + @java.lang.Override public TelJiladChosen copy() { return new TelJiladChosen(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TelJiladExile.java b/Mage.Sets/src/mage/sets/mirrodin/TelJiladExile.java index c05e3255689..d7d9230191a 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TelJiladExile.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TelJiladExile.java @@ -59,7 +59,7 @@ public class TelJiladExile extends CardImpl { super(card); } - @Override + @java.lang.Override public TelJiladExile copy() { return new TelJiladExile(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TelJiladStylus.java b/Mage.Sets/src/mage/sets/mirrodin/TelJiladStylus.java index b6a5e99a576..f29623b9c82 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TelJiladStylus.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TelJiladStylus.java @@ -69,7 +69,7 @@ public class TelJiladStylus extends CardImpl { super(card); } - @Override + @java.lang.Override public TelJiladStylus copy() { return new TelJiladStylus(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TempestOfLight.java b/Mage.Sets/src/mage/sets/mirrodin/TempestOfLight.java index 8affb861174..e24ba4fd083 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TempestOfLight.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TempestOfLight.java @@ -45,7 +45,7 @@ public class TempestOfLight extends mage.sets.magic2010.TempestOfLight { super(card); } - @Override + @java.lang.Override public TempestOfLight copy() { return new TempestOfLight(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TemporalCascade.java b/Mage.Sets/src/mage/sets/mirrodin/TemporalCascade.java new file mode 100644 index 00000000000..7767cfbe069 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/TemporalCascade.java @@ -0,0 +1,140 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class TemporalCascade extends CardImpl { + + public TemporalCascade(UUID ownerId) { + super(ownerId, 52, "Temporal Cascade", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{5}{U}{U}"); + this.expansionSetCode = "MRD"; + + // Choose one - Each player shuffles his or her hand and graveyard into his or her library; + this.getSpellAbility().addEffect(new TemporalCascadeShuffleEffect()); + + // or each player draws seven cards. + Mode mode = new Mode(); + mode.getEffects().add(new TemporalCascadeDrawEffect()); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {2} + this.addAbility(new EntwineAbility("{2}")); + } + + public TemporalCascade(final TemporalCascade card) { + super(card); + } + + @java.lang.Override + public TemporalCascade copy() { + return new TemporalCascade(this); + } +} + +class TemporalCascadeShuffleEffect extends OneShotEffect { + + public TemporalCascadeShuffleEffect() { + super(Outcome.Neutral); + staticText = "Each player shuffles his or her hand and graveyard into his or her library"; + } + + public TemporalCascadeShuffleEffect(final TemporalCascadeShuffleEffect effect) { + super(effect); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player sourcePlayer = game.getPlayer(source.getControllerId()); + for (UUID playerId: sourcePlayer.getInRange()) { + Player player = game.getPlayer(playerId); + if (player != null) { + for (Card card: player.getHand().getCards(game)) { + card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); + } + for (Card card: player.getGraveyard().getCards(game)) { + card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); + } + player.shuffleLibrary(game); + + } + } + return true; + } + + @java.lang.Override + public TemporalCascadeShuffleEffect copy() { + return new TemporalCascadeShuffleEffect(this); + } +} + +class TemporalCascadeDrawEffect extends OneShotEffect { + + public TemporalCascadeDrawEffect() { + super(Outcome.Neutral); + staticText = "Each player draws seven cards"; + } + + public TemporalCascadeDrawEffect(final TemporalCascadeDrawEffect effect) { + super(effect); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player sourcePlayer = game.getPlayer(source.getControllerId()); + game.getState().handleSimultaneousEvent(game); // needed here so state based triggered effects + for (UUID playerId: sourcePlayer.getInRange()) { + Player player = game.getPlayer(playerId); + if (player != null) { + player.drawCards(7, game); + } + } + return true; + } + + @java.lang.Override + public TemporalCascadeDrawEffect copy() { + return new TemporalCascadeDrawEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/Terror.java b/Mage.Sets/src/mage/sets/mirrodin/Terror.java index 057a2ca0c8b..ba172bc20f3 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Terror.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Terror.java @@ -45,7 +45,7 @@ public class Terror extends mage.sets.tenthedition.Terror { super(card); } - @Override + @java.lang.Override public Terror copy() { return new Terror(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ThirstForKnowledge.java b/Mage.Sets/src/mage/sets/mirrodin/ThirstForKnowledge.java index 4f3461387e8..eae35bffad9 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ThirstForKnowledge.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ThirstForKnowledge.java @@ -45,7 +45,7 @@ public class ThirstForKnowledge extends mage.sets.planechase.ThirstForKnowledge super(card); } - @Override + @java.lang.Override public ThirstForKnowledge copy() { return new ThirstForKnowledge(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Thoughtcast.java b/Mage.Sets/src/mage/sets/mirrodin/Thoughtcast.java index 4d90ccc4c25..1197995c4c1 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Thoughtcast.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Thoughtcast.java @@ -45,7 +45,7 @@ public class Thoughtcast extends mage.sets.elspethvstezzeret.Thoughtcast { super(card); } - @Override + @java.lang.Override public Thoughtcast copy() { return new Thoughtcast(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TitaniumGolem.java b/Mage.Sets/src/mage/sets/mirrodin/TitaniumGolem.java index 9cb7ff5f6bd..610835b34b4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TitaniumGolem.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TitaniumGolem.java @@ -59,7 +59,7 @@ public class TitaniumGolem extends CardImpl { super(card); } - @Override + @java.lang.Override public TitaniumGolem copy() { return new TitaniumGolem(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ToothAndNail.java b/Mage.Sets/src/mage/sets/mirrodin/ToothAndNail.java index a50188250a1..c9b4b4ab8dc 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ToothAndNail.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ToothAndNail.java @@ -45,7 +45,7 @@ public class ToothAndNail extends mage.sets.modernmasters.ToothAndNail { super(card); } - @Override + @java.lang.Override public ToothAndNail copy() { return new ToothAndNail(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ToothOfChissGoria.java b/Mage.Sets/src/mage/sets/mirrodin/ToothOfChissGoria.java index ba598aff8b0..8417487ab18 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ToothOfChissGoria.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ToothOfChissGoria.java @@ -65,7 +65,7 @@ public class ToothOfChissGoria extends CardImpl { super(card); } - @Override + @java.lang.Override public ToothOfChissGoria copy() { return new ToothOfChissGoria(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TowerOfChampions.java b/Mage.Sets/src/mage/sets/mirrodin/TowerOfChampions.java index 8da22439119..988534c802d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TowerOfChampions.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TowerOfChampions.java @@ -61,7 +61,7 @@ public class TowerOfChampions extends CardImpl { super(card); } - @Override + @java.lang.Override public TowerOfChampions copy() { return new TowerOfChampions(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TowerOfEons.java b/Mage.Sets/src/mage/sets/mirrodin/TowerOfEons.java index 4ae77a5e20b..fca55d57ed8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TowerOfEons.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TowerOfEons.java @@ -58,7 +58,7 @@ public class TowerOfEons extends CardImpl { super(card); } - @Override + @java.lang.Override public TowerOfEons copy() { return new TowerOfEons(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TowerOfFortunes.java b/Mage.Sets/src/mage/sets/mirrodin/TowerOfFortunes.java index eed8fa34fb5..d3d80c565e1 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TowerOfFortunes.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TowerOfFortunes.java @@ -58,7 +58,7 @@ public class TowerOfFortunes extends CardImpl { super(card); } - @Override + @java.lang.Override public TowerOfFortunes copy() { return new TowerOfFortunes(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TowerOfMurmurs.java b/Mage.Sets/src/mage/sets/mirrodin/TowerOfMurmurs.java index 74cbf64bce8..3c4e4452eff 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TowerOfMurmurs.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TowerOfMurmurs.java @@ -60,7 +60,7 @@ public class TowerOfMurmurs extends CardImpl { super(card); } - @Override + @java.lang.Override public TowerOfMurmurs copy() { return new TowerOfMurmurs(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TrashForTreasure.java b/Mage.Sets/src/mage/sets/mirrodin/TrashForTreasure.java index 86536946578..4c1c77b310c 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TrashForTreasure.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TrashForTreasure.java @@ -66,7 +66,7 @@ public class TrashForTreasure extends CardImpl { super(card); } - @Override + @java.lang.Override public TrashForTreasure copy() { return new TrashForTreasure(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TreeOfTales.java b/Mage.Sets/src/mage/sets/mirrodin/TreeOfTales.java index 61fca0de6ac..c604eb3a7ad 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TreeOfTales.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TreeOfTales.java @@ -50,7 +50,7 @@ public class TreeOfTales extends CardImpl { super(card); } - @Override + @java.lang.Override public TreeOfTales copy() { return new TreeOfTales(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Triskelion.java b/Mage.Sets/src/mage/sets/mirrodin/Triskelion.java index 127256fd0c2..b47e3605ac4 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Triskelion.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Triskelion.java @@ -45,7 +45,7 @@ public class Triskelion extends mage.sets.magic2011.Triskelion { super(card); } - @Override + @java.lang.Override public Triskelion copy() { return new Triskelion(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TrollAscetic.java b/Mage.Sets/src/mage/sets/mirrodin/TrollAscetic.java index 19760f938cb..acdeea42cd8 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TrollAscetic.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TrollAscetic.java @@ -61,7 +61,7 @@ public class TrollAscetic extends CardImpl { super(card); } - @Override + @java.lang.Override public TrollAscetic copy() { return new TrollAscetic(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TrollsOfTelJilad.java b/Mage.Sets/src/mage/sets/mirrodin/TrollsOfTelJilad.java index b49354cd7cc..348bcbce2ab 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TrollsOfTelJilad.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TrollsOfTelJilad.java @@ -72,7 +72,7 @@ public class TrollsOfTelJilad extends CardImpl { super(card); } - @Override + @java.lang.Override public TrollsOfTelJilad copy() { return new TrollsOfTelJilad(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/TurnToDust.java b/Mage.Sets/src/mage/sets/mirrodin/TurnToDust.java index 06b9939603c..e7d98325521 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/TurnToDust.java +++ b/Mage.Sets/src/mage/sets/mirrodin/TurnToDust.java @@ -63,7 +63,7 @@ public class TurnToDust extends CardImpl { super(card); } - @Override + @java.lang.Override public TurnToDust copy() { return new TurnToDust(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/VaultOfWhispers.java b/Mage.Sets/src/mage/sets/mirrodin/VaultOfWhispers.java index 57203693fd5..539d41680f6 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/VaultOfWhispers.java +++ b/Mage.Sets/src/mage/sets/mirrodin/VaultOfWhispers.java @@ -50,7 +50,7 @@ public class VaultOfWhispers extends CardImpl { super(card); } - @Override + @java.lang.Override public VaultOfWhispers copy() { return new VaultOfWhispers(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/VedalkenArchmage.java b/Mage.Sets/src/mage/sets/mirrodin/VedalkenArchmage.java index 5589557fd24..6ae9ac52b87 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/VedalkenArchmage.java +++ b/Mage.Sets/src/mage/sets/mirrodin/VedalkenArchmage.java @@ -59,7 +59,7 @@ public class VedalkenArchmage extends CardImpl { super(card); } - @Override + @java.lang.Override public VedalkenArchmage copy() { return new VedalkenArchmage(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ViridianJoiner.java b/Mage.Sets/src/mage/sets/mirrodin/ViridianJoiner.java index c9e71165d4a..4c289b7e4e7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ViridianJoiner.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ViridianJoiner.java @@ -59,7 +59,7 @@ public class ViridianJoiner extends CardImpl { super(card); } - @Override + @java.lang.Override public ViridianJoiner copy() { return new ViridianJoiner(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/ViridianShaman.java b/Mage.Sets/src/mage/sets/mirrodin/ViridianShaman.java index 152fb420104..93d6f8f77e9 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/ViridianShaman.java +++ b/Mage.Sets/src/mage/sets/mirrodin/ViridianShaman.java @@ -45,7 +45,7 @@ public class ViridianShaman extends mage.sets.tenthedition.ViridianShaman { super(card); } - @Override + @java.lang.Override public ViridianShaman copy() { return new ViridianShaman(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/VorracBattlehorns.java b/Mage.Sets/src/mage/sets/mirrodin/VorracBattlehorns.java new file mode 100644 index 00000000000..a4d47e9d1d1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/VorracBattlehorns.java @@ -0,0 +1,137 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EquipAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.util.CardUtil; + +/** + * + * @author fireshoes + */ +public class VorracBattlehorns extends CardImpl { + + public VorracBattlehorns(UUID ownerId) { + super(ownerId, 271, "Vorrac Battlehorns", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "MRD"; + this.subtype.add("Equipment"); + + // Equipped creature has trample and can't be blocked by more than one creature. + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(TrampleAbility.getInstance(), AttachmentType.EQUIPMENT)); + Effect effect = new CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType.EQUIPMENT, 1); + effect.setText("and can't be blocked by more than one creature"); + ability.addEffect(effect); + this.addAbility(ability); + + // Equip {1} + this.addAbility(new EquipAbility(Outcome.BoostCreature, new GenericManaCost(1))); + } + + public VorracBattlehorns(final VorracBattlehorns card) { + super(card); + } + + @java.lang.Override + public VorracBattlehorns copy() { + return new VorracBattlehorns(this); + } +} + +class CantBeBlockedByMoreThanOneAttachedEffect extends ContinuousEffectImpl { + + protected int amount; + protected AttachmentType attachmentType; + + public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount) { + this(attachmentType, amount, Duration.WhileOnBattlefield); + } + + public CantBeBlockedByMoreThanOneAttachedEffect(AttachmentType attachmentType, int amount, Duration duration) { + super(duration, Outcome.Benefit); + this.amount = amount; + this.attachmentType = attachmentType; + staticText = (attachmentType.equals(AttachmentType.AURA) ? "Enchanted" : "Equipped") + " creature can't be blocked by more than " + CardUtil.numberToText(amount) + " creature" + (amount==1 ?"":"s"); + } + + public CantBeBlockedByMoreThanOneAttachedEffect(final CantBeBlockedByMoreThanOneAttachedEffect effect) { + super(effect); + this.amount = effect.amount; + this.attachmentType = effect.attachmentType; + } + + @java.lang.Override + public CantBeBlockedByMoreThanOneAttachedEffect copy() { + return new CantBeBlockedByMoreThanOneAttachedEffect(this); + } + + @java.lang.Override + public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { + switch (layer) { + case RulesEffects: + Permanent attachment = game.getPermanent(source.getSourceId()); + if (attachment != null && attachment.getAttachedTo() != null) { + Permanent perm = game.getPermanent(attachment.getAttachedTo()); + if (perm != null) { + perm.setMaxBlockedBy(amount); + return true; + } + } + break; + } + return false; + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + return false; + } + + @java.lang.Override + public boolean hasLayer(Layer layer) { + return layer == Layer.RulesEffects; + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/VulshokBattlegear.java b/Mage.Sets/src/mage/sets/mirrodin/VulshokBattlegear.java index 7a2be4fbc20..99142d8b864 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/VulshokBattlegear.java +++ b/Mage.Sets/src/mage/sets/mirrodin/VulshokBattlegear.java @@ -58,7 +58,7 @@ public class VulshokBattlegear extends CardImpl { super(card); } - @Override + @java.lang.Override public VulshokBattlegear copy() { return new VulshokBattlegear(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/VulshokBerserker.java b/Mage.Sets/src/mage/sets/mirrodin/VulshokBerserker.java index 9ee0bff29aa..e108be7a73d 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/VulshokBerserker.java +++ b/Mage.Sets/src/mage/sets/mirrodin/VulshokBerserker.java @@ -45,7 +45,7 @@ public class VulshokBerserker extends mage.sets.magic2011.VulshokBerserker { super(card); } - @Override + @java.lang.Override public VulshokBerserker copy() { return new VulshokBerserker(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/VulshokGauntlets.java b/Mage.Sets/src/mage/sets/mirrodin/VulshokGauntlets.java new file mode 100644 index 00000000000..1022f368109 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/VulshokGauntlets.java @@ -0,0 +1,122 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.continuous.BoostEquippedEffect; +import mage.abilities.keyword.EquipAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; + +/** + * + * @author fireshoes + */ +public class VulshokGauntlets extends CardImpl { + + public VulshokGauntlets(UUID ownerId) { + super(ownerId, 273, "Vulshok Gauntlets", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "MRD"; + this.subtype.add("Equipment"); + + // Equipped creature gets +4/+2 and doesn't untap during its controller's untap step. + Effect effect = new BoostEquippedEffect(4, 2); + effect.setText("Equipped creature gets +4/+2"); + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); + effect = new VulshokGauntletsEffect(); + effect.setText("and has doesn't untap during its controller's untap step"); + ability.addEffect(effect); + this.addAbility(ability); + + // Equip {3} + this.addAbility(new EquipAbility(Outcome.AddAbility, new GenericManaCost(3))); + } + + public VulshokGauntlets(final VulshokGauntlets card) { + super(card); + } + + @java.lang.Override + public VulshokGauntlets copy() { + return new VulshokGauntlets(this); + } +} + +class VulshokGauntletsEffect extends ReplacementEffectImpl { + + public VulshokGauntletsEffect() { + super(Duration.WhileOnBattlefield, Outcome.Detriment); + staticText = "Equipped creature doesn't untap during its controller's untap step"; + } + + public VulshokGauntletsEffect(final VulshokGauntletsEffect effect) { + super(effect); + } + + @java.lang.Override + public VulshokGauntletsEffect copy() { + return new VulshokGauntletsEffect(this); + } + + @java.lang.Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + return true; + } + + @java.lang.Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.UNTAP; + } + + @java.lang.Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (game.getTurn().getStepType() == PhaseStep.UNTAP) { + Permanent equipment = game.getPermanent(source.getSourceId()); + if (equipment != null && equipment.getAttachedTo() != null) { + Permanent equipped = game.getPermanent(equipment.getAttachedTo()); + if (equipped.getId().equals(event.getTargetId())) { + return true; + } + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/mirrodin/WailOfTheNim.java b/Mage.Sets/src/mage/sets/mirrodin/WailOfTheNim.java new file mode 100644 index 00000000000..429360ddf67 --- /dev/null +++ b/Mage.Sets/src/mage/sets/mirrodin/WailOfTheNim.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.mirrodin; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.abilities.effects.common.RegenerateAllEffect; +import mage.abilities.keyword.EntwineAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class WailOfTheNim extends CardImpl { + + public WailOfTheNim(UUID ownerId) { + super(ownerId, 81, "Wail of the Nim", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{B}"); + this.expansionSetCode = "MRD"; + + // Choose one - Regenerate each creature you control; + this.getSpellAbility().addEffect(new RegenerateAllEffect(new FilterControlledCreaturePermanent())); + + // or Wail of the Nim deals 1 damage to each creature and each player. + Mode mode = new Mode(); + mode.getEffects().add(new DamageEverythingEffect(1)); + this.getSpellAbility().getModes().addMode(mode); + + // Entwine {B} + this.addAbility(new EntwineAbility("{B}")); + } + + public WailOfTheNim(final WailOfTheNim card) { + super(card); + } + + @java.lang.Override + public WailOfTheNim copy() { + return new WailOfTheNim(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodin/WallOfBlood.java b/Mage.Sets/src/mage/sets/mirrodin/WallOfBlood.java index 5535457b7f8..3e406902154 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/WallOfBlood.java +++ b/Mage.Sets/src/mage/sets/mirrodin/WallOfBlood.java @@ -62,7 +62,7 @@ public class WallOfBlood extends CardImpl { super(card); } - @Override + @java.lang.Override public WallOfBlood copy() { return new WallOfBlood(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/WanderguardSentry.java b/Mage.Sets/src/mage/sets/mirrodin/WanderguardSentry.java index 8fb623dad0f..40daf3e301b 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/WanderguardSentry.java +++ b/Mage.Sets/src/mage/sets/mirrodin/WanderguardSentry.java @@ -45,7 +45,7 @@ public class WanderguardSentry extends mage.sets.ninthedition.WanderguardSentry super(card); } - @Override + @java.lang.Override public WanderguardSentry copy() { return new WanderguardSentry(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/WeldingJar.java b/Mage.Sets/src/mage/sets/mirrodin/WeldingJar.java index ada85339d7e..dc1be1047bf 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/WeldingJar.java +++ b/Mage.Sets/src/mage/sets/mirrodin/WeldingJar.java @@ -58,7 +58,7 @@ public class WeldingJar extends CardImpl { super(card); } - @Override + @java.lang.Override public WeldingJar copy() { return new WeldingJar(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/WizardReplica.java b/Mage.Sets/src/mage/sets/mirrodin/WizardReplica.java index d750a39ba80..b2bdade4842 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/WizardReplica.java +++ b/Mage.Sets/src/mage/sets/mirrodin/WizardReplica.java @@ -45,7 +45,7 @@ public class WizardReplica extends mage.sets.planechase.WizardReplica { super(card); } - @Override + @java.lang.Override public WizardReplica copy() { return new WizardReplica(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/Worldslayer.java b/Mage.Sets/src/mage/sets/mirrodin/Worldslayer.java index 3cb17a7e367..6d3883763f7 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/Worldslayer.java +++ b/Mage.Sets/src/mage/sets/mirrodin/Worldslayer.java @@ -45,7 +45,7 @@ public class Worldslayer extends mage.sets.magic2012.Worldslayer { super(card); } - @Override + @java.lang.Override public Worldslayer copy() { return new Worldslayer(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodin/WrenchMind.java b/Mage.Sets/src/mage/sets/mirrodin/WrenchMind.java index e03f202fee8..48f36ef3981 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/WrenchMind.java +++ b/Mage.Sets/src/mage/sets/mirrodin/WrenchMind.java @@ -61,7 +61,7 @@ public class WrenchMind extends CardImpl { super(card); } - @Override + @java.lang.Override public WrenchMind copy() { return new WrenchMind(this); } @@ -78,12 +78,12 @@ class WrenchMindEffect extends OneShotEffect { super(effect); } - @Override + @java.lang.Override public WrenchMindEffect copy() { return new WrenchMindEffect(this); } - @Override + @java.lang.Override public boolean apply(Game game, Ability source) { Player targetPlayer = game.getPlayer(this.getTargetPointer().getFirst(game, source)); if (targetPlayer != null && !targetPlayer.getHand().isEmpty()) { diff --git a/Mage.Sets/src/mage/sets/mirrodin/YotianSoldier.java b/Mage.Sets/src/mage/sets/mirrodin/YotianSoldier.java index 27981636572..c3f142ccc91 100644 --- a/Mage.Sets/src/mage/sets/mirrodin/YotianSoldier.java +++ b/Mage.Sets/src/mage/sets/mirrodin/YotianSoldier.java @@ -55,7 +55,7 @@ public class YotianSoldier extends CardImpl { super(card); } - @Override + @java.lang.Override public YotianSoldier copy() { return new YotianSoldier(this); } diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/DivineOffering.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/DivineOffering.java index 1fcbb3dd8d2..8dd821a21b1 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/DivineOffering.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/DivineOffering.java @@ -28,14 +28,13 @@ package mage.sets.mirrodinbesieged; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.filter.FilterPermanent; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.game.Game; @@ -88,9 +87,9 @@ public class DivineOffering extends CardImpl { @Override public boolean apply(Game game, Ability source) { - Permanent artefact = game.getPermanentOrLKIBattlefield(getTargetPointer().getFirst(game, source)); - if (artefact != null) { - int cost = artefact.getManaCost().convertedManaCost(); + Permanent artifact = game.getPermanentOrLKIBattlefield(getTargetPointer().getFirst(game, source)); + if (artifact != null) { + int cost = artifact.getManaCost().convertedManaCost(); Player player = game.getPlayer(source.getControllerId()); if (player != null) { player.gainLife(cost, game); diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/MitoticManipulation.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/MitoticManipulation.java index def18f8114c..c911a7f3537 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/MitoticManipulation.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/MitoticManipulation.java @@ -130,7 +130,7 @@ class MitoticManipulationEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/NestedGhoul.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/NestedGhoul.java index 6751f451c29..c28f1a46104 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/NestedGhoul.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/NestedGhoul.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.mirrodinbesieged; import java.util.UUID; @@ -47,7 +46,7 @@ import mage.game.permanent.token.ZombieToken; */ public class NestedGhoul extends CardImpl { - public NestedGhoul (UUID ownerId) { + public NestedGhoul(UUID ownerId) { super(ownerId, 48, "Nested Ghoul", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{B}{B}"); this.expansionSetCode = "MBS"; this.subtype.add("Zombie"); @@ -58,7 +57,7 @@ public class NestedGhoul extends CardImpl { this.addAbility(new NestedGhoulTriggeredAbility()); } - public NestedGhoul (final NestedGhoul card) { + public NestedGhoul(final NestedGhoul card) { super(card); } @@ -70,8 +69,9 @@ public class NestedGhoul extends CardImpl { } class NestedGhoulTriggeredAbility extends TriggeredAbilityImpl { + NestedGhoulTriggeredAbility() { - super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken("MBS"))); + super(Zone.BATTLEFIELD, new CreateTokenEffect(new ZombieToken())); } NestedGhoulTriggeredAbility(final NestedGhoulTriggeredAbility ability) { @@ -97,4 +97,4 @@ class NestedGhoulTriggeredAbility extends TriggeredAbilityImpl { public String getRule() { return "Whenever a source deals damage to {this}, put a 2/2 black Zombie creature token onto the battlefield."; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/PhyrexianRevoker.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/PhyrexianRevoker.java index fd0a2c97d80..279bd693526 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/PhyrexianRevoker.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/PhyrexianRevoker.java @@ -103,7 +103,7 @@ class PhyrexianRevokerEffect1 extends OneShotEffect { cardChoice.setChoices(CardRepository.instance.getNonLandNames()); cardChoice.clearChoice(); while (!controller.choose(Outcome.Detriment, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/SignalPest.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/SignalPest.java index 604e7f4d863..2ffc07acf9f 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/SignalPest.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/SignalPest.java @@ -27,13 +27,10 @@ */ package mage.sets.mirrodinbesieged; -import java.io.ObjectStreamException; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.MageSingleton; -import mage.abilities.effects.RestrictionEffect; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.BattleCryAbility; import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.ReachAbility; @@ -41,8 +38,9 @@ import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.AbilityPredicate; /** * @@ -50,6 +48,17 @@ import mage.game.permanent.Permanent; */ public class SignalPest extends CardImpl { + private final static FilterCreaturePermanent notFlyingorReachCreatures = new FilterCreaturePermanent("except by creatures with flying or reach"); + + static { + notFlyingorReachCreatures.add(Predicates.not( + Predicates.or( + new AbilityPredicate(FlyingAbility.class), + new AbilityPredicate(ReachAbility.class) + ) + )); + } + public SignalPest(UUID ownerId) { super(ownerId, 131, "Signal Pest", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{1}"); this.expansionSetCode = "MBS"; @@ -58,8 +67,11 @@ public class SignalPest extends CardImpl { this.power = new MageInt(0); this.toughness = new MageInt(1); + // Battle cry (Whenever this creature attacks, each other attacking creature gets +1/+0 until end of turn.) this.addAbility(new BattleCryAbility()); - this.addAbility(SignalPestAbility.getInstance()); + + // Signal Pest can't be blocked except by creatures with flying or reach. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(notFlyingorReachCreatures, Duration.WhileOnBattlefield))); } public SignalPest(final SignalPest card) { @@ -71,65 +83,3 @@ public class SignalPest extends CardImpl { return new SignalPest(this); } } - -class SignalPestAbility extends EvasionAbility implements MageSingleton { - - private static SignalPestAbility instance; - - private Object readResolve() throws ObjectStreamException { - return instance; - } - - public static SignalPestAbility getInstance() { - if (instance == null) { - instance = new SignalPestAbility(); - } - return instance; - } - - private SignalPestAbility() { - this.addEffect(new SignalPestEffect()); - } - - @Override - public String getRule() { - return "{this} can't be blocked except by creatures with flying or reach"; - } - - @Override - public SignalPestAbility copy() { - return getInstance(); - } -} - -class SignalPestEffect extends RestrictionEffect { - - public SignalPestEffect() { - super(Duration.WhileOnBattlefield); - } - - public SignalPestEffect(final SignalPestEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - if (permanent.getAbilities().containsKey(SignalPestAbility.getInstance().getId())) { - return true; - } - return false; - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - if (blocker.getAbilities().contains(FlyingAbility.getInstance()) || blocker.getAbilities().contains(ReachAbility.getInstance())) { - return true; - } - return false; - } - - @Override - public SignalPestEffect copy() { - return new SignalPestEffect(this); - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/modernmasters/PetalsOfInsight.java b/Mage.Sets/src/mage/sets/modernmasters/PetalsOfInsight.java index 8a75832ee6b..6c15cb1f329 100644 --- a/Mage.Sets/src/mage/sets/modernmasters/PetalsOfInsight.java +++ b/Mage.Sets/src/mage/sets/modernmasters/PetalsOfInsight.java @@ -28,6 +28,7 @@ package mage.sets.modernmasters; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; @@ -52,7 +53,6 @@ public class PetalsOfInsight extends CardImpl { this.expansionSetCode = "MMA"; this.subtype.add("Arcane"); - // Look at the top three cards of your library. You may put those cards on the bottom of your library in any order. If you do, return Petals of Insight to its owner's hand. Otherwise, draw three cards. this.getSpellAbility().addEffect(new PetalsOfInsightEffect()); } @@ -85,33 +85,23 @@ class PetalsOfInsightEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { return false; } Cards cards = new CardsImpl(); - int count = Math.min(player.getLibrary().size(), 3); - for (int i = 0; i < count; i++) { - Card card = player.getLibrary().removeFromTop(game); - if (card != null) { - cards.add(card); - } - } - player.lookAtCards("Petals of Insight", cards, game); - if (player.chooseUse(outcome, "Put the cards on the bottom of your library in any order?", source, game)) { - player.putCardsOnBottomOfLibrary(cards, game, source, true); + cards.addAll(controller.getLibrary().getTopCards(game, 3)); + + controller.lookAtCards(sourceObject.getIdName(), cards, game); + if (controller.chooseUse(outcome, "Put the cards on the bottom of your library in any order?", source, game)) { + controller.putCardsOnBottomOfLibrary(cards, game, source, true); Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard(); if (spellCard != null) { - player.moveCardToHandWithInfo(spellCard, source.getSourceId(), game, Zone.STACK); + controller.moveCards(spellCard, null, Zone.HAND, source, game); } } else { - for (UUID cardId: cards) { - Card card = game.getCard(cardId); - if (card != null) { - card.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); - } - } - player.drawCards(3, game); + controller.drawCards(3, game); } return true; } diff --git a/Mage.Sets/src/mage/sets/modernmasters/TestOfFaith.java b/Mage.Sets/src/mage/sets/modernmasters/TestOfFaith.java index 4baaf12bab9..40a9ea2a357 100644 --- a/Mage.Sets/src/mage/sets/modernmasters/TestOfFaith.java +++ b/Mage.Sets/src/mage/sets/modernmasters/TestOfFaith.java @@ -50,11 +50,9 @@ public class TestOfFaith extends CardImpl { super(ownerId, 33, "Test of Faith", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); this.expansionSetCode = "MMA"; - - // Prevent the next 3 damage that would be dealt to target creature this turn, and put a +1/+1 counter on that creature for each 1 damage prevented this way. + // Prevent the next 3 damage that would be dealt to target creature this turn. For each 1 damage prevented this way, put a +1/+1 counter on that creature. this.getSpellAbility().addEffect(new TestOfFaithPreventDamageTargetEffect(Duration.EndOfTurn)); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); - } public TestOfFaith(final TestOfFaith card) { @@ -73,7 +71,7 @@ class TestOfFaithPreventDamageTargetEffect extends PreventionEffectImpl { public TestOfFaithPreventDamageTargetEffect(Duration duration) { super(duration); - staticText = "Prevent the next 3 damage that would be dealt to target creature this turn, and put a +1/+1 counter on that creature for each 1 damage prevented this way"; + staticText = "Prevent the next 3 damage that would be dealt to target creature this turn. For each 1 damage prevented this way, put a +1/+1 counter on that creature"; } public TestOfFaithPreventDamageTargetEffect(final TestOfFaithPreventDamageTargetEffect effect) { diff --git a/Mage.Sets/src/mage/sets/modernmasters2015/AllSunsDawn.java b/Mage.Sets/src/mage/sets/modernmasters2015/AllSunsDawn.java index 7c68912d601..0b01857a2ed 100644 --- a/Mage.Sets/src/mage/sets/modernmasters2015/AllSunsDawn.java +++ b/Mage.Sets/src/mage/sets/modernmasters2015/AllSunsDawn.java @@ -34,6 +34,8 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ExileSpellEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -56,7 +58,7 @@ public class AllSunsDawn extends CardImpl { private final static FilterCard filterBlue = new FilterCard("blue card from your graveyard"); private final static FilterCard filterBlack = new FilterCard("black card from your graveyard"); private final static FilterCard filterWhite = new FilterCard("white card from your graveyard"); - + static { filterGreen.add(new ColorPredicate(ObjectColor.GREEN)); filterRed.add(new ColorPredicate(ObjectColor.RED)); @@ -64,18 +66,18 @@ public class AllSunsDawn extends CardImpl { filterBlack.add(new ColorPredicate(ObjectColor.BLACK)); filterWhite.add(new ColorPredicate(ObjectColor.WHITE)); } - + public AllSunsDawn(UUID ownerId) { super(ownerId, 138, "All Suns' Dawn", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{4}{G}"); this.expansionSetCode = "MM2"; - // For each color, return up to one target card of that color from your graveyard to your hand. + // For each color, return up to one target card of that color from your graveyard to your hand. this.getSpellAbility().addEffect(new AllSunsDawnEffect()); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,1,filterGreen)); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,1,filterRed)); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,1,filterBlue)); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,1,filterBlack)); - this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0,1,filterWhite)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 1, filterGreen)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 1, filterRed)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 1, filterBlue)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 1, filterBlack)); + this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(0, 1, filterWhite)); // Exile All Suns' Dawn. this.getSpellAbility().addEffect(ExileSpellEffect.getInstance()); } @@ -91,32 +93,34 @@ public class AllSunsDawn extends CardImpl { } class AllSunsDawnEffect extends OneShotEffect { - + public AllSunsDawnEffect() { super(Outcome.ReturnToHand); this.staticText = "For each color, return up to one target card of that color from your graveyard to your hand. Exile {this}"; } - + public AllSunsDawnEffect(final AllSunsDawnEffect effect) { super(effect); } - + @Override public AllSunsDawnEffect copy() { return new AllSunsDawnEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - for(Target target: source.getTargets()) { + Cards cardsToHand = new CardsImpl(); + for (Target target : source.getTargets()) { UUID targetId = target.getFirstTarget(); Card card = game.getCard(targetId); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, true); + cardsToHand.add(card); } } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/morningtide/DistantMelody.java b/Mage.Sets/src/mage/sets/morningtide/DistantMelody.java index 2c4c17f745b..7a5dd503b10 100644 --- a/Mage.Sets/src/mage/sets/morningtide/DistantMelody.java +++ b/Mage.Sets/src/mage/sets/morningtide/DistantMelody.java @@ -93,7 +93,7 @@ class DistantMelodyEffect extends OneShotEffect { typeChoice.setMessage("Choose a creature type:"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/morningtide/FinalStingFaerie.java b/Mage.Sets/src/mage/sets/morningtide/FinalStingFaerie.java new file mode 100644 index 00000000000..33f52b3a1d1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/morningtide/FinalStingFaerie.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.morningtide; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.WasDealtDamageThisTurnPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FinalStingFaerie extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature that was dealt damage this turn"); + + static { + filter.add(new WasDealtDamageThisTurnPredicate()); + } + + public FinalStingFaerie(UUID ownerId) { + super(ownerId, 63, "Final-Sting Faerie", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "MOR"; + this.subtype.add("Faerie"); + this.subtype.add("Assassin"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When Final-Sting Faerie enters the battlefield, destroy target creature that was dealt damage this turn. + Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect()); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public FinalStingFaerie(final FinalStingFaerie card) { + super(card); + } + + @Override + public FinalStingFaerie copy() { + return new FinalStingFaerie(this); + } +} diff --git a/Mage.Sets/src/mage/sets/morningtide/Floodchaser.java b/Mage.Sets/src/mage/sets/morningtide/Floodchaser.java new file mode 100644 index 00000000000..a2988fa30a7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/morningtide/Floodchaser.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.morningtide; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterLandPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class Floodchaser extends CardImpl { + + public Floodchaser(UUID ownerId) { + super(ownerId, 34, "Floodchaser", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{5}{U}"); + this.expansionSetCode = "MOR"; + this.subtype.add("Elemental"); + this.power = new MageInt(0); + this.toughness = new MageInt(0); + + // Floodchaser enters the battlefield with six +1/+1 counters on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(6)), "{this} enters the battlefield with six +1/+1 counters on it")); + + // Floodchaser can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + + // {U}, Remove a +1/+1 counter from Floodchaser: Target land becomes an Island until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Island"), new ManaCostsImpl("{U}")); + ability.addCost(new RemoveCountersSourceCost(CounterType.P1P1.createInstance(1))); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public Floodchaser(final Floodchaser card) { + super(card); + } + + @Override + public Floodchaser copy() { + return new Floodchaser(this); + } +} diff --git a/Mage.Sets/src/mage/sets/morningtide/LuminescentRain.java b/Mage.Sets/src/mage/sets/morningtide/LuminescentRain.java index d677141a652..567db004db5 100644 --- a/Mage.Sets/src/mage/sets/morningtide/LuminescentRain.java +++ b/Mage.Sets/src/mage/sets/morningtide/LuminescentRain.java @@ -91,7 +91,7 @@ class LuminescentRainEffect extends OneShotEffect { typeChoice.setMessage("Choose a creature type:"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/morningtide/OrderOfTheGoldenCricket.java b/Mage.Sets/src/mage/sets/morningtide/OrderOfTheGoldenCricket.java new file mode 100644 index 00000000000..2460b30f144 --- /dev/null +++ b/Mage.Sets/src/mage/sets/morningtide/OrderOfTheGoldenCricket.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.morningtide; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class OrderOfTheGoldenCricket extends CardImpl { + + public OrderOfTheGoldenCricket(UUID ownerId) { + super(ownerId, 19, "Order of the Golden Cricket", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "MOR"; + this.subtype.add("Kithkin"); + this.subtype.add("Knight"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Order of the Golden Cricket attacks, you may pay {W}. If you do, it gains flying until end of turn. + Ability ability = new AttacksTriggeredAbility(new DoIfCostPaid( + new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{W}")), + false, + "Whenever {this} attacks, you may pay {W}. If you do, it gains flying until end of turn."); + this.addAbility(ability); + } + + public OrderOfTheGoldenCricket(final OrderOfTheGoldenCricket card) { + super(card); + } + + @Override + public OrderOfTheGoldenCricket copy() { + return new OrderOfTheGoldenCricket(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/morningtide/RoarOfTheCrowd.java b/Mage.Sets/src/mage/sets/morningtide/RoarOfTheCrowd.java index fa9e9d70501..bd30aad56e4 100644 --- a/Mage.Sets/src/mage/sets/morningtide/RoarOfTheCrowd.java +++ b/Mage.Sets/src/mage/sets/morningtide/RoarOfTheCrowd.java @@ -94,7 +94,7 @@ class RoarOfTheCrowdEffect extends OneShotEffect { typeChoice.setMessage("Choose a creature type:"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.LoseLife, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/morningtide/SagesDousing.java b/Mage.Sets/src/mage/sets/morningtide/SagesDousing.java new file mode 100644 index 00000000000..d6c235a11ff --- /dev/null +++ b/Mage.Sets/src/mage/sets/morningtide/SagesDousing.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.morningtide; + +import java.util.UUID; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.CounterUnlessPaysEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetSpell; + +/** + * + * @author fireshoes + */ +public class SagesDousing extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Wizard"); + + static { + filter.add(new SubtypePredicate("Wizard")); + } + + public SagesDousing(UUID ownerId) { + super(ownerId, 48, "Sage's Dousing", Rarity.UNCOMMON, new CardType[]{CardType.TRIBAL, CardType.INSTANT}, "{2}{U}"); + this.expansionSetCode = "MOR"; + this.subtype.add("Wizard"); + + // Counter target spell unless its controller pays {3}. + this.getSpellAbility().addTarget(new TargetSpell()); + this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(new GenericManaCost(3))); + + // If you control a Wizard, draw a card. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), + new PermanentsOnTheBattlefieldCondition(filter),"If you control a Wizard, draw a card")); + } + + public SagesDousing(final SagesDousing card) { + super(card); + } + + @Override + public SagesDousing copy() { + return new SagesDousing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/morningtide/SigilTracer.java b/Mage.Sets/src/mage/sets/morningtide/SigilTracer.java index b5e5499dfa0..f97d3fdc29c 100644 --- a/Mage.Sets/src/mage/sets/morningtide/SigilTracer.java +++ b/Mage.Sets/src/mage/sets/morningtide/SigilTracer.java @@ -28,9 +28,6 @@ package mage.sets.morningtide; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; @@ -38,6 +35,8 @@ import mage.abilities.costs.common.TapTargetCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.CopyTargetSpellEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterSpell; import mage.filter.common.FilterControlledCreaturePermanent; @@ -72,6 +71,8 @@ public class SigilTracer extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(2); + + // {1}{U}, Tap two untapped Wizards you control: Copy target instant or sorcery spell. You may choose new targets for the copy. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CopyTargetSpellEffect(), new ManaCostsImpl("{1}{U}")); ability.addTarget(new TargetSpell(filterInstorSorc)); ability.addCost(new TapTargetCost(new TargetControlledCreaturePermanent(2, 2, filter, false))); diff --git a/Mage.Sets/src/mage/sets/morningtide/StreamOfUnconsciousness.java b/Mage.Sets/src/mage/sets/morningtide/StreamOfUnconsciousness.java new file mode 100644 index 00000000000..dceb753b77e --- /dev/null +++ b/Mage.Sets/src/mage/sets/morningtide/StreamOfUnconsciousness.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.morningtide; + +import java.util.UUID; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class StreamOfUnconsciousness extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Wizard"); + + static { + filter.add(new SubtypePredicate("Wizard")); + } + + public StreamOfUnconsciousness(UUID ownerId) { + super(ownerId, 52, "Stream of Unconsciousness", Rarity.COMMON, new CardType[]{CardType.TRIBAL, CardType.INSTANT}, "{U}"); + this.expansionSetCode = "MOR"; + this.subtype.add("Wizard"); + + // Target creature gets -4/-0 until end of turn. + this.getSpellAbility().addEffect(new BoostTargetEffect(-4, 0, Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + + // If you control a Wizard, draw a card. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect(new DrawCardSourceControllerEffect(1), + new PermanentsOnTheBattlefieldCondition(filter),"If you control a Wizard, draw a card")); + } + + public StreamOfUnconsciousness(final StreamOfUnconsciousness card) { + super(card); + } + + @Override + public StreamOfUnconsciousness copy() { + return new StreamOfUnconsciousness(this); + } +} diff --git a/Mage.Sets/src/mage/sets/morningtide/VioletPall.java b/Mage.Sets/src/mage/sets/morningtide/VioletPall.java index 228a57579be..7b760e28e44 100644 --- a/Mage.Sets/src/mage/sets/morningtide/VioletPall.java +++ b/Mage.Sets/src/mage/sets/morningtide/VioletPall.java @@ -28,15 +28,18 @@ package mage.sets.morningtide; import java.util.UUID; +import mage.MageInt; import mage.constants.CardType; import mage.constants.Rarity; import mage.ObjectColor; import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.permanent.token.Token; import mage.target.common.TargetCreaturePermanent; /** @@ -58,7 +61,7 @@ public class VioletPall extends CardImpl { this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); - this.getSpellAbility().addEffect(new CreateTokenEffect(new FaerieToken(), 1)); + this.getSpellAbility().addEffect(new CreateTokenEffect(new VioletPallFaerieToken(), 1)); } public VioletPall(final VioletPall card) { @@ -70,3 +73,17 @@ public class VioletPall extends CardImpl { return new VioletPall(this); } } + +class VioletPallFaerieToken extends Token { + + VioletPallFaerieToken() { + super("Faerie Rogue", "1/1 black Faerie Rogue creature token with flying"); + cardType.add(CardType.CREATURE); + color.setBlack(true); + subtype.add("Faerie"); + subtype.add("Rogue"); + power = new MageInt(1); + toughness = new MageInt(1); + this.addAbility(FlyingAbility.getInstance()); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/AncientHydra.java b/Mage.Sets/src/mage/sets/nemesis/AncientHydra.java new file mode 100644 index 00000000000..a9ea30a9979 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/AncientHydra.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.FadingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class AncientHydra extends CardImpl { + + public AncientHydra(UUID ownerId) { + super(ownerId, 76, "Ancient Hydra", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{R}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Hydra"); + this.power = new MageInt(5); + this.toughness = new MageInt(1); + + // Fading 5 + this.addAbility(new FadingAbility(5, this)); + // {1}, Remove a fade counter from Ancient Hydra: Ancient Hydra deals 1 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new ManaCostsImpl("{1}")); + ability.addCost(new RemoveCountersSourceCost(CounterType.FADE.createInstance(1))); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public AncientHydra(final AncientHydra card) { + super(card); + } + + @Override + public AncientHydra copy() { + return new AncientHydra(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/AvengerEnDal.java b/Mage.Sets/src/mage/sets/nemesis/AvengerEnDal.java new file mode 100644 index 00000000000..9875b337a52 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/AvengerEnDal.java @@ -0,0 +1,110 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetAttackingCreature; + +/** + * + * @author fireshoes + */ +public class AvengerEnDal extends CardImpl { + + public AvengerEnDal(UUID ownerId) { + super(ownerId, 2, "Avenger en-Dal", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {2}{W}, {tap}, Discard a card: Exile target attacking creature. Its controller gains life equal to its toughness. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new ManaCostsImpl("{2}{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addTarget(new TargetAttackingCreature()); + ability.addEffect(new AvengerEnDalEffect()); + this.addAbility(ability); + } + + public AvengerEnDal(final AvengerEnDal card) { + super(card); + } + + @Override + public AvengerEnDal copy() { + return new AvengerEnDal(this); + } +} + +class AvengerEnDalEffect extends OneShotEffect { + + public AvengerEnDalEffect() { + super(Outcome.GainLife); + staticText = "Its controller gains life equal to its toughness"; + } + + public AvengerEnDalEffect(final AvengerEnDalEffect effect) { + super(effect); + } + + @Override + public AvengerEnDalEffect copy() { + return new AvengerEnDalEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanentOrLKIBattlefield(getTargetPointer().getFirst(game, source)); + if (permanent != null) { + Player player = game.getPlayer(permanent.getControllerId()); + if (player != null) { + player.gainLife(permanent.getToughness().getValue(), game); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/nemesis/BelbesPortal.java b/Mage.Sets/src/mage/sets/nemesis/BelbesPortal.java index 5b3e8c7cb73..8a6bd9a80f4 100644 --- a/Mage.Sets/src/mage/sets/nemesis/BelbesPortal.java +++ b/Mage.Sets/src/mage/sets/nemesis/BelbesPortal.java @@ -34,24 +34,15 @@ import mage.abilities.common.AsEntersBattlefieldAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.abilities.effects.Effect; -import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ChooseCreatureTypeEffect; -import mage.abilities.effects.common.PutCreatureOnBattlefieldEffect; -import mage.cards.Card; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; -import mage.cards.repository.CardRepository; -import mage.choices.Choice; -import mage.choices.ChoiceImpl; -import mage.constants.*; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; -import mage.filter.common.FilterCreaturePermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; -import mage.target.common.TargetCardInHand; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; /** * @@ -66,8 +57,10 @@ public class BelbesPortal extends CardImpl { // As Belbe's Portal enters the battlefield, choose a creature type. this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.PutCreatureInPlay))); // {3}, {tap}: You may put a creature card of the chosen type from your hand onto the battlefield. - SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, - new BelbesPortalPutCreatureOnBattlefieldEffect(), + FilterCreatureCard filter = new FilterCreatureCard("a creature card of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PutPermanentOnBattlefieldEffect(filter), new ManaCostsImpl("{3}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); @@ -82,48 +75,3 @@ public class BelbesPortal extends CardImpl { return new BelbesPortal(this); } } - -class BelbesPortalPutCreatureOnBattlefieldEffect extends OneShotEffect { - BelbesPortalPutCreatureOnBattlefieldEffect() { - super(Outcome.PutCreatureInPlay); - staticText = "You may put a creature card of the chosen type from your hand onto the battlefield"; - } - - BelbesPortalPutCreatureOnBattlefieldEffect(final BelbesPortalPutCreatureOnBattlefieldEffect effect) { - super(effect); - } - - @Override - public BelbesPortalPutCreatureOnBattlefieldEffect copy() { - return new BelbesPortalPutCreatureOnBattlefieldEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null) { - String subtype = (String) game.getState().getValue(permanent.getId() + "_type"); - if (subtype != null) { - Player player = game.getPlayer(source.getControllerId()); - String choiceText = "Put a " + subtype.toLowerCase() + " creature card from your hand onto the battlefield?"; - - if (player != null) { - if (player.chooseUse(Outcome.PutCreatureInPlay, choiceText, source, game)) { - FilterCreatureCard creatureTypeFilter = new FilterCreatureCard(); - creatureTypeFilter.add(new SubtypePredicate(subtype)); - - TargetCardInHand target = new TargetCardInHand(creatureTypeFilter); - if (player.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } - } - } - return true; - } - } - } - return false; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/nemesis/Cloudskate.java b/Mage.Sets/src/mage/sets/nemesis/Cloudskate.java new file mode 100644 index 00000000000..b21cc3311e0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/Cloudskate.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.FadingAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author markedagain + */ +public class Cloudskate extends CardImpl { + + public Cloudskate(UUID ownerId) { + super(ownerId, 29, "Cloudskate", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Illusion"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Fading 3 + this.addAbility(new FadingAbility(3, this)); + } + + public Cloudskate(final Cloudskate card) { + super(card); + } + + @Override + public Cloudskate copy() { + return new Cloudskate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/DefenderEnVec.java b/Mage.Sets/src/mage/sets/nemesis/DefenderEnVec.java new file mode 100644 index 00000000000..e6a7c7557f9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/DefenderEnVec.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.abilities.keyword.FadingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class DefenderEnVec extends CardImpl { + + public DefenderEnVec(UUID ownerId) { + super(ownerId, 5, "Defender en-Vec", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // Fading 4 + this.addAbility(new FadingAbility(4, this)); + + // Remove a fade counter from Defender en-Vec: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new RemoveCountersSourceCost(CounterType.FADE.createInstance())); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public DefenderEnVec(final DefenderEnVec card) { + super(card); + } + + @Override + public DefenderEnVec copy() { + return new DefenderEnVec(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/DefiantFalcon.java b/Mage.Sets/src/mage/sets/nemesis/DefiantFalcon.java new file mode 100644 index 00000000000..ea6c267313c --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/DefiantFalcon.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterPermanentCard; +import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetCardInLibrary; + +/** + * + * @author fireshoes + */ +public class DefiantFalcon extends CardImpl { + + private static final FilterPermanentCard filter = new FilterPermanentCard("Rebel permanent card with converted mana cost 3 or less"); + + static { + filter.add(new SubtypePredicate("Rebel")); + filter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, 4)); + } + + public DefiantFalcon(UUID ownerId) { + super(ownerId, 6, "Defiant Falcon", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Rebel"); + this.subtype.add("Bird"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {4}, {tap}: Search your library for a Rebel permanent card with converted mana cost 3 or less and put it onto the battlefield. Then shuffle your library. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(filter), false), + new ManaCostsImpl("{4}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + } + + public DefiantFalcon(final DefiantFalcon card) { + super(card); + } + + @Override + public DefiantFalcon copy() { + return new DefiantFalcon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/FlowstoneCrusher.java b/Mage.Sets/src/mage/sets/nemesis/FlowstoneCrusher.java new file mode 100644 index 00000000000..6c85d1c1a37 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/FlowstoneCrusher.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class FlowstoneCrusher extends mage.sets.ninthedition.FlowstoneCrusher { + + public FlowstoneCrusher(UUID ownerId) { + super(ownerId); + this.cardNumber = 81; + this.expansionSetCode = "NMS"; + this.rarity = Rarity.COMMON; + } + + public FlowstoneCrusher(final FlowstoneCrusher card) { + super(card); + } + + @Override + public FlowstoneCrusher copy() { + return new FlowstoneCrusher(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/Lawbringer.java b/Mage.Sets/src/mage/sets/nemesis/Lawbringer.java new file mode 100644 index 00000000000..ab0b587a21e --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/Lawbringer.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Lawbringer extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("red creature"); + + static { + filter.add(new ColorPredicate(ObjectColor.RED)); + } + + public Lawbringer(UUID ownerId) { + super(ownerId, 10, "Lawbringer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Kor"); + this.subtype.add("Rebel"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {tap}, Sacrifice Lawbringer: Exile target red creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public Lawbringer(final Lawbringer card) { + super(card); + } + + @Override + public Lawbringer copy() { + return new Lawbringer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/Lightbringer.java b/Mage.Sets/src/mage/sets/nemesis/Lightbringer.java new file mode 100644 index 00000000000..aefe3b373cd --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/Lightbringer.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Lightbringer extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("black creature"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public Lightbringer(UUID ownerId) { + super(ownerId, 11, "Lightbringer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Kor"); + this.subtype.add("Rebel"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {tap}, Sacrifice Lightbringer: Exile target black creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public Lightbringer(final Lightbringer card) { + super(card); + } + + @Override + public Lightbringer copy() { + return new Lightbringer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/LinSivviDefiantHero.java b/Mage.Sets/src/mage/sets/nemesis/LinSivviDefiantHero.java new file mode 100644 index 00000000000..efc9dcd7c22 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/LinSivviDefiantHero.java @@ -0,0 +1,145 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.Filter.ComparisonType; +import mage.filter.FilterCard; +import mage.filter.common.FilterPermanentCard; +import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.other.OwnerPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInLibrary; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class LinSivviDefiantHero extends CardImpl { + + private static final FilterCard filter = new FilterCard("Rebel card from your graveyard"); + + static { + filter.add(new OwnerPredicate(TargetController.YOU)); + filter.add(new SubtypePredicate("Rebel")); + } + + static final String rule = "Put target Rebel card from your graveyard on the bottom of your library"; + + public LinSivviDefiantHero(UUID ownerId) { + super(ownerId, 12, "Lin Sivvi, Defiant Hero", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{W}{W}"); + this.expansionSetCode = "NMS"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Rebel"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // {X}, {tap}: Search your library for a Rebel permanent card with converted mana cost X or less and put it onto the battlefield. Then shuffle your library. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new LinSivviDefiantHeroEffect(), + new ManaCostsImpl("{X}")); + ability.addCost(new TapSourceCost()); + this.addAbility(ability); + + // {3}: Put target Rebel card from your graveyard on the bottom of your library. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutOnLibraryTargetEffect(false, rule), new GenericManaCost(3)); + ability.addTarget(new TargetCardInYourGraveyard(1, filter)); + this.addAbility(ability); + } + + public LinSivviDefiantHero(final LinSivviDefiantHero card) { + super(card); + } + + @Override + public LinSivviDefiantHero copy() { + return new LinSivviDefiantHero(this); + } +} + +class LinSivviDefiantHeroEffect extends OneShotEffect { + + public LinSivviDefiantHeroEffect() { + super(Outcome.DrawCard); + this.staticText = "Search your library for a Rebel permanent card with converted mana cost X or less and put it onto the battlefield. Then shuffle your library"; + } + + public LinSivviDefiantHeroEffect(final LinSivviDefiantHeroEffect effect) { + super(effect); + } + + @Override + public LinSivviDefiantHeroEffect copy() { + return new LinSivviDefiantHeroEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player == null) { + return false; + } + + int xCost = source.getManaCostsToPay().getX(); + + FilterPermanentCard filter = new FilterPermanentCard(new StringBuilder("Rebel permanent card with converted mana cost ").append(xCost).append(" or less").toString()); + filter.add(new ConvertedManaCostPredicate(ComparisonType.LessThan, xCost + 1)); + filter.add(new SubtypePredicate("Rebel")); + TargetCardInLibrary target = new TargetCardInLibrary(filter); + + if (player.searchLibrary(target, game)) { + Card card = player.getLibrary().getCard(target.getFirstTarget(), game); + if (card != null) { + player.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); + } + player.shuffleLibrary(game); + return true; + } + player.shuffleLibrary(game); + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/nemesis/Massacre.java b/Mage.Sets/src/mage/sets/nemesis/Massacre.java index ded7f68f0d6..45412174b20 100644 --- a/Mage.Sets/src/mage/sets/nemesis/Massacre.java +++ b/Mage.Sets/src/mage/sets/nemesis/Massacre.java @@ -1,80 +1,80 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.nemesis; - -import java.util.UUID; -import mage.abilities.condition.CompoundCondition; -import mage.abilities.condition.Condition; -import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; -import mage.abilities.condition.common.OpponentControlsPermanentCondition; -import mage.abilities.costs.AlternativeCostSourceAbility; -import mage.abilities.effects.common.continuous.BoostAllEffect; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.filter.FilterPermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; - -/** - * - * @author Plopman - */ -public class Massacre extends CardImpl { - - private static final FilterPermanent filterPlains = new FilterPermanent(); - private static final FilterPermanent filterSwamp = new FilterPermanent(); - - static { - filterPlains.add(new SubtypePredicate(("Plains"))); - filterSwamp.add(new SubtypePredicate(("Swamp"))); - } - - public Massacre(UUID ownerId) { - super(ownerId, 58, "Massacre", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{B}{B}"); - this.expansionSetCode = "NMS"; - - - // If an opponent controls a Plains and you control a Swamp, you may cast Massacre without paying its mana cost. - Condition condition = new CompoundCondition("If an opponent controls a Plains and you control a Swamp", - new OpponentControlsPermanentCondition(filterPlains), - new PermanentsOnTheBattlefieldCondition(filterSwamp)); - this.addAbility(new AlternativeCostSourceAbility(null, condition)); - // All creatures get -2/-2 until end of turn. - this.getSpellAbility().addEffect(new BoostAllEffect(-2, -2, Duration.EndOfTurn)); - } - - public Massacre(final Massacre card) { - super(card); - } - - @Override - public Massacre copy() { - return new Massacre(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author Plopman + */ +public class Massacre extends CardImpl { + + private static final FilterPermanent filterPlains = new FilterPermanent(); + private static final FilterPermanent filterSwamp = new FilterPermanent(); + + static { + filterPlains.add(new SubtypePredicate(("Plains"))); + filterSwamp.add(new SubtypePredicate(("Swamp"))); + } + + public Massacre(UUID ownerId) { + super(ownerId, 58, "Massacre", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{B}{B}"); + this.expansionSetCode = "NMS"; + + + // If an opponent controls a Plains and you control a Swamp, you may cast Massacre without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Plains and you control a Swamp", + new OpponentControlsPermanentCondition(filterPlains), + new PermanentsOnTheBattlefieldCondition(filterSwamp)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + // All creatures get -2/-2 until end of turn. + this.getSpellAbility().addEffect(new BoostAllEffect(-2, -2, Duration.EndOfTurn)); + } + + public Massacre(final Massacre card) { + super(card); + } + + @Override + public Massacre copy() { + return new Massacre(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/MoggAlarm.java b/Mage.Sets/src/mage/sets/nemesis/MoggAlarm.java new file mode 100644 index 00000000000..3a7e4d58fb1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/MoggAlarm.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.game.permanent.token.GoblinToken; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author markedagain + */ +public class MoggAlarm extends CardImpl { + + private static final FilterControlledPermanent filter = new FilterControlledPermanent("two Mountains"); + static { + filter.add(new SubtypePredicate("Mountain")); + } + + public MoggAlarm(UUID ownerId) { + super(ownerId, 93, "Mogg Alarm", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{R}{R}"); + this.expansionSetCode = "NMS"; + + // You may sacrifice two Mountains rather than pay Mogg Alarm's mana cost. + this.addAbility(new AlternativeCostSourceAbility(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, filter, true)))); + // Put two 1/1 red Goblin creature tokens onto the battlefield. + this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(),2)); + + } + + public MoggAlarm(final MoggAlarm card) { + super(card); + } + + @Override + public MoggAlarm copy() { + return new MoggAlarm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/MoggSalvage.java b/Mage.Sets/src/mage/sets/nemesis/MoggSalvage.java new file mode 100644 index 00000000000..2ea3f3643b6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/MoggSalvage.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterArtifactPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class MoggSalvage extends CardImpl { + + private static final FilterPermanent filterMountain = new FilterPermanent(); + private static final FilterPermanent filterIsland = new FilterPermanent(); + + static { + filterMountain.add(new SubtypePredicate(("Mountain"))); + filterIsland.add(new SubtypePredicate(("Island"))); + } + + public MoggSalvage(UUID ownerId) { + super(ownerId, 94, "Mogg Salvage", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); + this.expansionSetCode = "NMS"; + + // If an opponent controls an Island and you control a Mountain, you may cast Mogg Salvage without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls an Island and you control a Mountain", + new OpponentControlsPermanentCondition(filterIsland), + new PermanentsOnTheBattlefieldCondition(filterMountain)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + + // Destroy target artifact. + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(new FilterArtifactPermanent())); + } + + public MoggSalvage(final MoggSalvage card) { + super(card); + } + + @Override + public MoggSalvage copy() { + return new MoggSalvage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/OverlaidTerrain.java b/Mage.Sets/src/mage/sets/nemesis/OverlaidTerrain.java new file mode 100644 index 00000000000..ef23eb8a4fa --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/OverlaidTerrain.java @@ -0,0 +1,106 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.AddManaOfAnyColorEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class OverlaidTerrain extends CardImpl { + + public OverlaidTerrain(UUID ownerId) { + super(ownerId, 108, "Overlaid Terrain", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}{G}"); + this.expansionSetCode = "NMS"; + + // As Overlaid Terrain enters the battlefield, sacrifice all lands you control. + this.addAbility(new AsEntersBattlefieldAbility(new SacrificeAllLandEffect())); + + // Lands you control have "{tap}: Add two mana of any one color to your mana pool." + SimpleManaAbility manaAbility = new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(2), new TapSourceCost()); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(manaAbility, Duration.WhileOnBattlefield, new FilterLandPermanent(), false))); + } + + public OverlaidTerrain(final OverlaidTerrain card) { + super(card); + } + + @Override + public OverlaidTerrain copy() { + return new OverlaidTerrain(this); + } +} + +class SacrificeAllLandEffect extends OneShotEffect { + + SacrificeAllLandEffect() { + super(Outcome.Detriment); + staticText = "sacrifice all lands you control"; + } + + SacrificeAllLandEffect(final SacrificeAllLandEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + for(Permanent permanent : game.getBattlefield().getActivePermanents(new FilterControlledLandPermanent(), source.getControllerId(), game)){ + permanent.sacrifice(source.getControllerId(), game); + } + return true; + } + return false; + } + + @Override + public SacrificeAllLandEffect copy() { + return new SacrificeAllLandEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/nemesis/RefreshingRain.java b/Mage.Sets/src/mage/sets/nemesis/RefreshingRain.java new file mode 100644 index 00000000000..1e48e618691 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/RefreshingRain.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.effects.common.GainLifeTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class RefreshingRain extends CardImpl { + + private static final FilterPermanent filterForest = new FilterPermanent(); + private static final FilterPermanent filterSwamp = new FilterPermanent(); + + static { + filterForest.add(new SubtypePredicate(("Forest"))); + filterSwamp.add(new SubtypePredicate(("Swamp"))); + } + + public RefreshingRain(UUID ownerId) { + super(ownerId, 110, "Refreshing Rain", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{3}{G}"); + this.expansionSetCode = "NMS"; + + // If an opponent controls a Swamp and you control a Forest, you may cast Refreshing Rain without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Swamp and you control a Forest", + new OpponentControlsPermanentCondition(filterSwamp), + new PermanentsOnTheBattlefieldCondition(filterForest)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + + // Target player gains 6 life. + this.getSpellAbility().addEffect(new GainLifeTargetEffect(6)); + this.getSpellAbility().addTarget(new TargetPlayer()); + } + + public RefreshingRain(final RefreshingRain card) { + super(card); + } + + @Override + public RefreshingRain copy() { + return new RefreshingRain(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/RisingWaters.java b/Mage.Sets/src/mage/sets/nemesis/RisingWaters.java new file mode 100644 index 00000000000..7afea122781 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/RisingWaters.java @@ -0,0 +1,112 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.Target; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class RisingWaters extends CardImpl { + + public RisingWaters(UUID ownerId) { + super(ownerId, 38, "Rising Waters", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{U}"); + this.expansionSetCode = "NMS"; + + // Lands don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, new FilterLandPermanent("Lands")))); + + // At the beginning of each player's upkeep, that player untaps a land he or she controls. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new RisingWatersUntapEffect(), TargetController.ANY, false)); + } + + public RisingWaters(final RisingWaters card) { + super(card); + } + + @Override + public RisingWaters copy() { + return new RisingWaters(this); + } +} + +class RisingWatersUntapEffect extends OneShotEffect { + + public RisingWatersUntapEffect() { + super(Outcome.Untap); + this.staticText = "that player untaps a land he or she controls"; + } + + public RisingWatersUntapEffect(final RisingWatersUntapEffect effect) { + super(effect); + } + + @Override + public RisingWatersUntapEffect copy() { + return new RisingWatersUntapEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(game.getActivePlayerId()); + FilterLandPermanent filter = new FilterLandPermanent("land you control"); + filter.add(new ControllerIdPredicate(game.getActivePlayerId())); + Target target = new TargetLandPermanent(filter); + if (player != null && player.chooseTarget(Outcome.Untap, target, source, game)) { + for (UUID landId : target.getTargets()) { + Permanent land = game.getPermanent(landId); + if (land != null) { + land.untap(game); + } + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/SaprolingCluster.java b/Mage.Sets/src/mage/sets/nemesis/SaprolingCluster.java new file mode 100644 index 00000000000..2d0ff917a9a --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/SaprolingCluster.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.InfoEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.permanent.token.SaprolingToken; + +/** + * + * @author fireshoes + */ +public class SaprolingCluster extends CardImpl { + + public SaprolingCluster(UUID ownerId) { + super(ownerId, 114, "Saproling Cluster", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "NMS"; + + // {1}, Discard a card: Put a 1/1 green Saproling creature token onto the battlefield. Any player may activate this ability. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new SaprolingToken()) , new GenericManaCost(1)); + ability.addCost(new DiscardCardCost()); + ability.setMayActivate(TargetController.ANY); + ability.addEffect(new InfoEffect("Any player may activate this ability")); + this.addAbility(ability); + } + + public SaprolingCluster(final SaprolingCluster card) { + super(card); + } + + @Override + public SaprolingCluster copy() { + return new SaprolingCluster(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/SivvisRuse.java b/Mage.Sets/src/mage/sets/nemesis/SivvisRuse.java new file mode 100644 index 00000000000..05598de0e6d --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/SivvisRuse.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.abilities.condition.CompoundCondition; +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.OpponentControlsPermanentCondition; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.effects.common.PreventAllDamageToAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterControlledCreatureInPlay; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class SivvisRuse extends CardImpl { + + private static final FilterPermanent filterMountain = new FilterPermanent(); + private static final FilterPermanent filterPlains = new FilterPermanent(); + + static { + filterMountain.add(new SubtypePredicate(("Mountain"))); + filterPlains.add(new SubtypePredicate(("Plains"))); + } + + public SivvisRuse(UUID ownerId) { + super(ownerId, 21, "Sivvi's Ruse", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}{W}"); + this.expansionSetCode = "NMS"; + + // If an opponent controls a Mountain and you control a Plains, you may cast Sivvi's Ruse without paying its mana cost. + Condition condition = new CompoundCondition("If an opponent controls a Mountain and you control a Plains", + new OpponentControlsPermanentCondition(filterMountain), + new PermanentsOnTheBattlefieldCondition(filterPlains)); + this.addAbility(new AlternativeCostSourceAbility(null, condition)); + + // Prevent all damage that would be dealt this turn to creatures you control. + this.getSpellAbility().addEffect(new PreventAllDamageToAllEffect(Duration.EndOfTurn, new FilterControlledCreatureInPlay())); + } + + public SivvisRuse(final SivvisRuse card) { + super(card); + } + + @Override + public SivvisRuse copy() { + return new SivvisRuse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/SneakyHomunculus.java b/Mage.Sets/src/mage/sets/nemesis/SneakyHomunculus.java index 35ab78e728f..f388d9cee91 100644 --- a/Mage.Sets/src/mage/sets/nemesis/SneakyHomunculus.java +++ b/Mage.Sets/src/mage/sets/nemesis/SneakyHomunculus.java @@ -30,14 +30,14 @@ package mage.sets.nemesis; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.effects.common.combat.CantBlockCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.Filter; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.PowerPredicate; @@ -49,6 +49,7 @@ import mage.filter.predicate.mageobject.PowerPredicate; public class SneakyHomunculus extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creatures with power 2 or greater"); + static { filter.add(new PowerPredicate(Filter.ComparisonType.GreaterThan, 1)); } @@ -63,8 +64,12 @@ public class SneakyHomunculus extends CardImpl { this.toughness = new MageInt(1); // Sneaky Homunculus can't block or be blocked by creatures with power 2 or greater. - Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield)); - ability.addEffect(new CantBlockCreaturesSourceEffect(filter)); + Effect effect = new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield); + effect.setText("{this} can't block"); + Ability ability = new SimpleEvasionAbility(effect); + effect = new CantBlockCreaturesSourceEffect(filter); + effect.setText("or be blocked by creatures with power 2 or greater"); + ability.addEffect(effect); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/nemesis/StrongholdDiscipline.java b/Mage.Sets/src/mage/sets/nemesis/StrongholdDiscipline.java new file mode 100644 index 00000000000..d58af0a0106 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/StrongholdDiscipline.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class StrongholdDiscipline extends mage.sets.conspiracy.StrongholdDiscipline { + + public StrongholdDiscipline(UUID ownerId) { + super(ownerId); + this.cardNumber = 73; + this.expansionSetCode = "NMS"; + } + + public StrongholdDiscipline(final StrongholdDiscipline card) { + super(card); + } + + @Override + public StrongholdDiscipline copy() { + return new StrongholdDiscipline(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/TricksterMage.java b/Mage.Sets/src/mage/sets/nemesis/TricksterMage.java new file mode 100644 index 00000000000..771161cf3c7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/TricksterMage.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.MayTapOrUntapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class TricksterMage extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public TricksterMage(UUID ownerId) { + super(ownerId, 49, "Trickster Mage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {U}, {tap}, Discard a card: You may tap or untap target artifact, creature, or land. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MayTapOrUntapTargetEffect(), new ManaCostsImpl("{U}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + public TricksterMage(final TricksterMage card) { + super(card); + } + + @Override + public TricksterMage copy() { + return new TricksterMage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/nemesis/WanderingEye.java b/Mage.Sets/src/mage/sets/nemesis/WanderingEye.java new file mode 100644 index 00000000000..04c4fa1c665 --- /dev/null +++ b/Mage.Sets/src/mage/sets/nemesis/WanderingEye.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.nemesis; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.PlayWithHandRevealedEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class WanderingEye extends CardImpl { + + public WanderingEye(UUID ownerId) { + super(ownerId, 50, "Wandering Eye", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "NMS"; + this.subtype.add("Illusion"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Players play with their hands revealed. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithHandRevealedEffect(TargetController.ANY))); + } + + public WanderingEye(final WanderingEye card) { + super(card); + } + + @Override + public WanderingEye copy() { + return new WanderingEye(this); + } +} diff --git a/Mage.Sets/src/mage/sets/newphyrexia/ApostlesBlessing.java b/Mage.Sets/src/mage/sets/newphyrexia/ApostlesBlessing.java index 1106bb635aa..38f851c776d 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/ApostlesBlessing.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/ApostlesBlessing.java @@ -105,7 +105,7 @@ class ApostlesBlessingEffect extends OneShotEffect { if (controller != null) { ChoiceColorOrArtifact choice = new ChoiceColorOrArtifact(); while (!choice.isChosen()) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } controller.choose(outcome, choice, game); diff --git a/Mage.Sets/src/mage/sets/newphyrexia/GitaxianProbe.java b/Mage.Sets/src/mage/sets/newphyrexia/GitaxianProbe.java index 1dd4bfe1c4f..bf3054706e8 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/GitaxianProbe.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/GitaxianProbe.java @@ -25,17 +25,17 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.newphyrexia; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.game.Game; import mage.players.Player; import mage.target.TargetPlayer; @@ -46,20 +46,19 @@ import mage.target.TargetPlayer; */ public class GitaxianProbe extends CardImpl { - public GitaxianProbe (UUID ownerId) { + public GitaxianProbe(UUID ownerId) { super(ownerId, 35, "Gitaxian Probe", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{UP}"); this.expansionSetCode = "NPH"; - // Look at target player's hand. this.getSpellAbility().addEffect(new GitaxianProbeEffect()); this.getSpellAbility().addTarget(new TargetPlayer()); // Draw a card. this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); - + } - public GitaxianProbe (final GitaxianProbe card) { + public GitaxianProbe(final GitaxianProbe card) { super(card); } @@ -71,6 +70,7 @@ public class GitaxianProbe extends CardImpl { } class GitaxianProbeEffect extends OneShotEffect { + GitaxianProbeEffect() { super(Outcome.DrawCard); staticText = "Look at target player's hand"; @@ -84,8 +84,9 @@ class GitaxianProbeEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); Player player = game.getPlayer(targetPointer.getFirst(game, source)); - if (player != null && controller != null) { - controller.lookAtCards("Gitaxian Probe", player.getHand(), game); + MageObject sourceObject = source.getSourceObject(game); + if (player != null && controller != null && sourceObject != null) { + controller.lookAtCards(sourceObject.getIdName() + " (" + player.getName() + ")", player.getHand(), game); } return true; } diff --git a/Mage.Sets/src/mage/sets/newphyrexia/KarnLiberated.java b/Mage.Sets/src/mage/sets/newphyrexia/KarnLiberated.java index 38deecc35fe..5b5a30d8035 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/KarnLiberated.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/KarnLiberated.java @@ -75,12 +75,12 @@ public class KarnLiberated extends CardImpl { this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(6)), false)); // +4: Target player exiles a card from his or her hand. - LoyaltyAbility ability1 = new LoyaltyAbility(new ExileFromZoneTargetEffect(Zone.HAND, exileId, "Karn Liberated", new FilterCard()), 4); + LoyaltyAbility ability1 = new LoyaltyAbility(new ExileFromZoneTargetEffect(Zone.HAND, exileId, this.getIdName(), new FilterCard()), 4); ability1.addTarget(new TargetPlayer()); this.addAbility(ability1); // -3: Exile target permanent. - LoyaltyAbility ability2 = new LoyaltyAbility(new ExileTargetEffect(exileId, "Karn Liberated"), -3); + LoyaltyAbility ability2 = new LoyaltyAbility(new ExileTargetEffect(exileId, this.getIdName()), -3); ability2.addTarget(new TargetPermanent()); this.addAbility(ability2); @@ -120,9 +120,9 @@ class KarnLiberatedEffect extends OneShotEffect { return false; } List cards = new ArrayList<>(); - for (ExileZone zone: game.getExile().getExileZones()) { + for (ExileZone zone : game.getExile().getExileZones()) { if (zone.getId().equals(exileId)) { - for (Card card: zone.getCards(game)) { + for (Card card : zone.getCards(game)) { if (!card.getSubtype().contains("Aura") && CardUtil.isPermanentCard(card)) { cards.add(card); } @@ -130,15 +130,15 @@ class KarnLiberatedEffect extends OneShotEffect { } } game.getState().clear(); - for (Card card: game.getCards()) { + for (Card card : game.getCards()) { game.getState().addCard(card); } - for (Player player: game.getPlayers().values()) { + for (Player player : game.getPlayers().values()) { player.getGraveyard().clear(); player.getHand().clear(); player.getLibrary().clear(); - for (Card card: game.getCards()) { - if (card.getOwnerId().equals(player.getId()) && !card.isCopy() // no copies + for (Card card : game.getCards()) { + if (card.getOwnerId().equals(player.getId()) && !card.isCopy() // no copies && !player.getSideboard().contains(card.getId()) && !cards.contains(card)) { // not the exiled cards player.getLibrary().putOnTop(card, game); @@ -146,8 +146,8 @@ class KarnLiberatedEffect extends OneShotEffect { } player.init(game); } - for (Card card: cards) { - if ( CardUtil.isPermanentCard(card) && !card.getSubtype().contains("Aura") ) { + for (Card card : cards) { + if (CardUtil.isPermanentCard(card) && !card.getSubtype().contains("Aura")) { game.getExile().add(exileId, sourceObject.getIdName(), card); } } @@ -215,10 +215,10 @@ class KarnLiberatedDelayedEffect extends OneShotEffect { if (exile != null) { Cards cards = new CardsImpl(); // needed because putOntoTheBattlefield removes from exile cards.addAll(exile); - for (Card card: cards.getCards(game)) { + for (Card card : cards.getCards(game)) { card.putOntoBattlefield(game, Zone.EXILED, source.getSourceId(), source.getControllerId()); Permanent permanent = game.getPermanent(card.getId()); - ((PermanentImpl)permanent).removeSummoningSickness(); + ((PermanentImpl) permanent).removeSummoningSickness(); } return true; } diff --git a/Mage.Sets/src/mage/sets/newphyrexia/PsychicSurgery.java b/Mage.Sets/src/mage/sets/newphyrexia/PsychicSurgery.java index 35a26e0db75..8178bb45663 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/PsychicSurgery.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/PsychicSurgery.java @@ -150,7 +150,7 @@ class PsychicSurgeryEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on top of his library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/newphyrexia/ShrineOfPiercingVision.java b/Mage.Sets/src/mage/sets/newphyrexia/ShrineOfPiercingVision.java index 9483fe13c92..e6670e7d7f5 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/ShrineOfPiercingVision.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/ShrineOfPiercingVision.java @@ -140,7 +140,7 @@ class ShrineOfPiercingVisionEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/newphyrexia/Spellskite.java b/Mage.Sets/src/mage/sets/newphyrexia/Spellskite.java index 6c6db8f49c8..ba7b8ebc634 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/Spellskite.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/Spellskite.java @@ -93,20 +93,23 @@ class SpellskiteEffect extends OneShotEffect { StackObject stackObject = game.getStack().getStackObject(source.getFirstTarget()); MageObject sourceObject = game.getObject(source.getSourceId()); if (stackObject != null && sourceObject != null) { - Targets targets; + Targets targets = new Targets(); Ability sourceAbility; MageObject oldTarget = null; if (stackObject instanceof Spell) { - Spell spell = (Spell)stackObject; + Spell spell = (Spell) stackObject; sourceAbility = spell.getSpellAbility(); - targets = spell.getSpellAbility().getTargets(); } else if (stackObject instanceof StackAbility) { - StackAbility stackAbility = (StackAbility)stackObject; + StackAbility stackAbility = (StackAbility) stackObject; sourceAbility = stackAbility; - targets = stackAbility.getTargets(); } else { return false; } + for (UUID modeId : sourceAbility.getModes().getSelectedModes()) { + sourceAbility.getModes().setActiveMode(modeId); + targets.addAll(sourceAbility.getTargets()); + } + boolean twoTimesTarget = false; if (targets.size() == 1 && targets.get(0).getTargets().size() == 1) { Target target = targets.get(0); @@ -115,25 +118,25 @@ class SpellskiteEffect extends OneShotEffect { target.clearChosen(); // The source is still the spell on the stack target.addTarget(source.getSourceId(), stackObject.getStackAbility(), game); - } + } } else { Player player = game.getPlayer(source.getControllerId()); - for (Target target: targets) { - for (UUID targetId: target.getTargets()) { + for (Target target : targets) { + for (UUID targetId : target.getTargets()) { MageObject object = game.getObject(targetId); String name; if (object == null) { Player targetPlayer = game.getPlayer(targetId); name = targetPlayer.getLogName(); } else { - name = object.getName(); + name = object.getLogName(); } if (!targetId.equals(source.getSourceId()) && target.getTargets().contains(source.getSourceId())) { // you can't change this target to Spellskite because Spellskite is already another targetId of that target. twoTimesTarget = true; continue; } - if (name != null && player.chooseUse(Outcome.Neutral, new StringBuilder("Change target from ").append(name).append(" to ").append(sourceObject.getName()).append("?").toString(), source, game)) { + if (name != null && player.chooseUse(Outcome.Neutral, "Change target from " + name + " to " + sourceObject.getLogName() + "?", source, game)) { if (target.canTarget(stackObject.getControllerId(), source.getSourceId(), sourceAbility, game)) { oldTarget = game.getObject(targets.getFirstTarget()); target.remove(targetId); @@ -146,12 +149,12 @@ class SpellskiteEffect extends OneShotEffect { } } if (oldTarget != null) { - game.informPlayers(sourceObject.getLogName() + ": Changed target of " +stackObject.getLogName() + " from " + oldTarget.getLogName() + " to " + sourceObject.getLogName()); + game.informPlayers(sourceObject.getLogName() + ": Changed target of " + stackObject.getLogName() + " from " + oldTarget.getLogName() + " to " + sourceObject.getLogName()); } else { if (twoTimesTarget) { - game.informPlayers(sourceObject.getLogName() + ": Target not changed to " + sourceObject.getLogName() + " because its not valid to target it twice for " + stackObject.getName()); + game.informPlayers(sourceObject.getLogName() + ": Target not changed to " + sourceObject.getLogName() + " because its not valid to target it twice for " + stackObject.getLogName()); } else { - game.informPlayers(sourceObject.getLogName() + ": Target not changed to " + sourceObject.getLogName() + " because its no valid target for " + stackObject.getName()); + game.informPlayers(sourceObject.getLogName() + ": Target not changed to " + sourceObject.getLogName() + " because its no valid target for " + stackObject.getLogName()); } } return true; diff --git a/Mage.Sets/src/mage/sets/newphyrexia/Xenograft.java b/Mage.Sets/src/mage/sets/newphyrexia/Xenograft.java index 88692fb2d1d..df7da676226 100644 --- a/Mage.Sets/src/mage/sets/newphyrexia/Xenograft.java +++ b/Mage.Sets/src/mage/sets/newphyrexia/Xenograft.java @@ -97,7 +97,7 @@ class XenograftEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/ninthedition/FlowstoneCrusher.java b/Mage.Sets/src/mage/sets/ninthedition/FlowstoneCrusher.java new file mode 100644 index 00000000000..d05061444b4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/FlowstoneCrusher.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class FlowstoneCrusher extends CardImpl { + + public FlowstoneCrusher(UUID ownerId) { + super(ownerId, 184, "Flowstone Crusher", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}{R}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Beast"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // {R}: Flowstone Crusher gets +1/-1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostSourceEffect(1, -1, Duration.EndOfTurn), new ManaCostsImpl("{R}"))); + } + + public FlowstoneCrusher(final FlowstoneCrusher card) { + super(card); + } + + @Override + public FlowstoneCrusher copy() { + return new FlowstoneCrusher(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/FlowstoneShambler.java b/Mage.Sets/src/mage/sets/ninthedition/FlowstoneShambler.java new file mode 100644 index 00000000000..4ec8d5747a6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/FlowstoneShambler.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class FlowstoneShambler extends CardImpl { + + public FlowstoneShambler(UUID ownerId) { + super(ownerId, 185, "Flowstone Shambler", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Beast"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {R}: Flowstone Shambler gets +1/-1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostSourceEffect(1, -1, Duration.EndOfTurn), new ManaCostsImpl("{R}"))); + } + + public FlowstoneShambler(final FlowstoneShambler card) { + super(card); + } + + @Override + public FlowstoneShambler copy() { + return new FlowstoneShambler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/Groundskeeper.java b/Mage.Sets/src/mage/sets/ninthedition/Groundskeeper.java new file mode 100644 index 00000000000..a447da81b88 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/Groundskeeper.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterBasicLandCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class Groundskeeper extends CardImpl { + + public Groundskeeper(UUID ownerId) { + super(ownerId, 247, "Groundskeeper", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{G}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Human"); + this.subtype.add("Druid"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}{G}: Return target basic land card from your graveyard to your hand. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl("{1}{G}")); + ability.addTarget(new TargetCardInYourGraveyard(new FilterBasicLandCard("basic land card from your graveyard"))); + this.addAbility(ability); + } + + public Groundskeeper(final Groundskeeper card) { + super(card); + } + + @Override + public Groundskeeper copy() { + return new Groundskeeper(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/HellsCaretaker.java b/Mage.Sets/src/mage/sets/ninthedition/HellsCaretaker.java new file mode 100644 index 00000000000..8e545b8c4b0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/HellsCaretaker.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class HellsCaretaker extends CardImpl { + + public HellsCaretaker(UUID ownerId) { + super(ownerId, 137, "Hell's Caretaker", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Horror"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {tap}, Sacrifice a creature: Return target creature card from your graveyard to the battlefield. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new ReturnFromGraveyardToBattlefieldTargetEffect(), + new TapSourceCost(), + new IsStepCondition(PhaseStep.UPKEEP), null); + ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + ability.addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard"))); + this.addAbility(ability); + } + + public HellsCaretaker(final HellsCaretaker card) { + super(card); + } + + @Override + public HellsCaretaker copy() { + return new HellsCaretaker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/HorrorOfHorrors.java b/Mage.Sets/src/mage/sets/ninthedition/HorrorOfHorrors.java new file mode 100644 index 00000000000..5f229c7da13 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/HorrorOfHorrors.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class HorrorOfHorrors extends mage.sets.legends.HorrorOfHorrors { + + public HorrorOfHorrors(UUID ownerId) { + super(ownerId); + this.cardNumber = 140; + this.expansionSetCode = "9ED"; + } + + public HorrorOfHorrors(final HorrorOfHorrors card) { + super(card); + } + + @Override + public HorrorOfHorrors copy() { + return new HorrorOfHorrors(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/ImaginaryPet.java b/Mage.Sets/src/mage/sets/ninthedition/ImaginaryPet.java new file mode 100644 index 00000000000..cbc264edc80 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/ImaginaryPet.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ImaginaryPet extends mage.sets.urzassaga.ImaginaryPet { + + public ImaginaryPet(UUID ownerId) { + super(ownerId); + this.cardNumber = 82; + this.expansionSetCode = "9ED"; + } + + public ImaginaryPet(final ImaginaryPet card) { + super(card); + } + + @Override + public ImaginaryPet copy() { + return new ImaginaryPet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/Inspirit.java b/Mage.Sets/src/mage/sets/ninthedition/Inspirit.java new file mode 100644 index 00000000000..12112f59e1d --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/Inspirit.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Inspirit extends mage.sets.onslaught.Inspirit { + + public Inspirit(UUID ownerId) { + super(ownerId); + this.cardNumber = 22; + this.expansionSetCode = "9ED"; + } + + public Inspirit(final Inspirit card) { + super(card); + } + + @Override + public Inspirit copy() { + return new Inspirit(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/KarplusanYeti.java b/Mage.Sets/src/mage/sets/ninthedition/KarplusanYeti.java new file mode 100644 index 00000000000..d0eaf0d4594 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/KarplusanYeti.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class KarplusanYeti extends mage.sets.iceage.KarplusanYeti { + + public KarplusanYeti(UUID ownerId) { + super(ownerId); + this.cardNumber = 198; + this.expansionSetCode = "9ED"; + } + + public KarplusanYeti(final KarplusanYeti card) { + super(card); + } + + @Override + public KarplusanYeti copy() { + return new KarplusanYeti(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/MarbleTitan.java b/Mage.Sets/src/mage/sets/ninthedition/MarbleTitan.java new file mode 100644 index 00000000000..61d49319d2f --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/MarbleTitan.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class MarbleTitan extends mage.sets.tempest.MarbleTitan { + + public MarbleTitan(UUID ownerId) { + super(ownerId); + this.cardNumber = 26; + this.expansionSetCode = "9ED"; + } + + public MarbleTitan(final MarbleTitan card) { + super(card); + } + + @Override + public MarbleTitan copy() { + return new MarbleTitan(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/NaturalAffinity.java b/Mage.Sets/src/mage/sets/ninthedition/NaturalAffinity.java index c5a7804b97c..208cd0eba78 100644 --- a/Mage.Sets/src/mage/sets/ninthedition/NaturalAffinity.java +++ b/Mage.Sets/src/mage/sets/ninthedition/NaturalAffinity.java @@ -55,7 +55,6 @@ public class NaturalAffinity extends CardImpl { super(ownerId, 256, "Natural Affinity", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{2}{G}"); this.expansionSetCode = "9ED"; - // All lands become 2/2 creatures until end of turn. They're still lands. this.getSpellAbility().addEffect(new BecomesCreatureAllEffect()); } @@ -72,9 +71,8 @@ public class NaturalAffinity extends CardImpl { class BecomesCreatureAllEffect extends ContinuousEffectImpl { - public BecomesCreatureAllEffect() { - super(Duration.WhileOnBattlefield, Outcome.BecomeCreature); + super(Duration.EndOfTurn, Outcome.BecomeCreature); staticText = "All lands become 2/2 creatures until end of turn. They're still lands"; } @@ -86,12 +84,12 @@ class BecomesCreatureAllEffect extends ContinuousEffectImpl { public BecomesCreatureAllEffect copy() { return new BecomesCreatureAllEffect(this); } - + @Override public void init(Ability source, Game game) { super.init(source, game); this.affectedObjectsSet = true; - for (Permanent perm: game.getBattlefield().getActivePermanents(new FilterLandPermanent(), source.getControllerId(), source.getSourceId(), game)) { + for (Permanent perm : game.getBattlefield().getActivePermanents(new FilterLandPermanent(), source.getControllerId(), source.getSourceId(), game)) { affectedObjectList.add(new MageObjectReference(perm, game)); } } @@ -101,9 +99,9 @@ class BecomesCreatureAllEffect extends ContinuousEffectImpl { switch (layer) { case TypeChangingEffects_4: if (sublayer == SubLayer.NA) { - for (Iterator it = affectedObjectList.iterator(); it.hasNext();) { + for (Iterator it = affectedObjectList.iterator(); it.hasNext();) { Permanent permanent = it.next().getPermanent(game); - if(permanent != null){ + if (permanent != null) { permanent.getCardType().add(CardType.CREATURE); } else { it.remove(); @@ -116,7 +114,7 @@ class BecomesCreatureAllEffect extends ContinuousEffectImpl { if (sublayer == SubLayer.SetPT_7b) { for (Iterator it = affectedObjectList.iterator(); it.hasNext();) { Permanent permanent = it.next().getPermanent(game); - if(permanent != null){ + if (permanent != null) { permanent.getPower().setValue(2); permanent.getToughness().setValue(2); } else { @@ -133,7 +131,6 @@ class BecomesCreatureAllEffect extends ContinuousEffectImpl { return false; } - @Override public boolean hasLayer(Layer layer) { return layer == Layer.PTChangingEffects_7 || layer == Layer.AbilityAddingRemovingEffects_6 || layer == Layer.ColorChangingEffects_5 || layer == Layer.TypeChangingEffects_4; diff --git a/Mage.Sets/src/mage/sets/ninthedition/SageAven.java b/Mage.Sets/src/mage/sets/ninthedition/SageAven.java new file mode 100644 index 00000000000..c7a91f38e44 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/SageAven.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.LookLibraryControllerEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class SageAven extends CardImpl { + + public SageAven(UUID ownerId) { + super(ownerId, 95, "Sage Aven", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Bird"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // When Sage Aven enters the battlefield, look at the top four cards of your library, then put them back in any order. + this.addAbility(new EntersBattlefieldTriggeredAbility(new LookLibraryControllerEffect(4))); + } + + public SageAven(final SageAven card) { + super(card); + } + + @Override + public SageAven copy() { + return new SageAven(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/SanctumGuardian.java b/Mage.Sets/src/mage/sets/ninthedition/SanctumGuardian.java new file mode 100644 index 00000000000..938fc482053 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/SanctumGuardian.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.PreventNextDamageFromChosenSourceToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class SanctumGuardian extends CardImpl { + + public SanctumGuardian(UUID ownerId) { + super(ownerId, 40, "Sanctum Guardian", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W}{W}"); + this.expansionSetCode = "9ED"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(4); + + // Sacrifice Sanctum Guardian: The next time a source of your choice would deal damage to target creature or player this turn, prevent that damage. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventNextDamageFromChosenSourceToTargetEffect(Duration.EndOfTurn), + new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public SanctumGuardian(final SanctumGuardian card) { + super(card); + } + + @Override + public SanctumGuardian copy() { + return new SanctumGuardian(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/StorageMatrix.java b/Mage.Sets/src/mage/sets/ninthedition/StorageMatrix.java index 62c863c93ef..2256c8e78f8 100644 --- a/Mage.Sets/src/mage/sets/ninthedition/StorageMatrix.java +++ b/Mage.Sets/src/mage/sets/ninthedition/StorageMatrix.java @@ -107,7 +107,7 @@ class StorageMatrixRestrictionEffect extends RestrictionEffect { Player player = game.getPlayer(game.getActivePlayerId()); if (player != null) { while (!player.choose(outcome, choiceImpl, game)) { - if (player.isInGame()) { + if (player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/ninthedition/TeferisPuzzleBox.java b/Mage.Sets/src/mage/sets/ninthedition/TeferisPuzzleBox.java index d4cebbe74e7..636a1fe1ad8 100644 --- a/Mage.Sets/src/mage/sets/ninthedition/TeferisPuzzleBox.java +++ b/Mage.Sets/src/mage/sets/ninthedition/TeferisPuzzleBox.java @@ -95,7 +95,7 @@ class TeferisPuzzleBoxEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/ninthedition/ThievingMagpie.java b/Mage.Sets/src/mage/sets/ninthedition/ThievingMagpie.java index e77fb511118..7f6ac26f06c 100644 --- a/Mage.Sets/src/mage/sets/ninthedition/ThievingMagpie.java +++ b/Mage.Sets/src/mage/sets/ninthedition/ThievingMagpie.java @@ -28,13 +28,13 @@ package mage.sets.ninthedition; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * diff --git a/Mage.Sets/src/mage/sets/ninthedition/Thundermare.java b/Mage.Sets/src/mage/sets/ninthedition/Thundermare.java new file mode 100644 index 00000000000..a9e7495472e --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/Thundermare.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Thundermare extends mage.sets.portal.Thundermare { + + public Thundermare(UUID ownerId) { + super(ownerId); + this.cardNumber = 224; + this.expansionSetCode = "9ED"; + } + + public Thundermare(final Thundermare card) { + super(card); + } + + @Override + public Thundermare copy() { + return new Thundermare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ninthedition/WhipSergeant.java b/Mage.Sets/src/mage/sets/ninthedition/WhipSergeant.java new file mode 100644 index 00000000000..9342c790986 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ninthedition/WhipSergeant.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ninthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class WhipSergeant extends mage.sets.prophecy.WhipSergeant { + + public WhipSergeant(UUID ownerId) { + super(ownerId); + this.cardNumber = 227; + this.expansionSetCode = "9ED"; + } + + public WhipSergeant(final WhipSergeant card) { + super(card); + } + + @Override + public WhipSergeant copy() { + return new WhipSergeant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/DarkwaterEgg.java b/Mage.Sets/src/mage/sets/odyssey/DarkwaterEgg.java new file mode 100644 index 00000000000..52bd2d1bd08 --- /dev/null +++ b/Mage.Sets/src/mage/sets/odyssey/DarkwaterEgg.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.odyssey; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class DarkwaterEgg extends CardImpl { + + public DarkwaterEgg(UUID ownerId) { + super(ownerId, 299, "Darkwater Egg", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ODY"; + + // {2}, {tap}, Sacrifice Darkwater Egg: Add {U}{B} to your mana pool. Draw a card. + ManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 1, 0, 1, 0, 0), new ManaCostsImpl("{2}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public DarkwaterEgg(final DarkwaterEgg card) { + super(card); + } + + @Override + public DarkwaterEgg copy() { + return new DarkwaterEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/DruidsCall.java b/Mage.Sets/src/mage/sets/odyssey/DruidsCall.java index 7746b54f027..3f7f6c922d0 100644 --- a/Mage.Sets/src/mage/sets/odyssey/DruidsCall.java +++ b/Mage.Sets/src/mage/sets/odyssey/DruidsCall.java @@ -29,25 +29,22 @@ package mage.sets.odyssey; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.DamageDealtToAttachedTriggeredAbility; +import mage.abilities.dynamicvalue.common.NumericSetToEffectValues; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.CreateTokenTargetEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; +import mage.constants.SetTargetPointer; import mage.constants.Zone; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.game.permanent.Permanent; import mage.game.permanent.token.SquirrelToken; -import mage.game.permanent.token.Token; import mage.players.Player; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; -import mage.target.targetpointer.FixedTarget; /** * @@ -69,7 +66,9 @@ public class DruidsCall extends CardImpl { this.addAbility(ability); // Whenever enchanted creature is dealt damage, its controller puts that many 1/1 green Squirrel creature tokens onto the battlefield. - this.addAbility(new DruidsCallTriggeredAbility()); + Effect effect = new CreateTokenTargetEffect(new SquirrelToken(), new NumericSetToEffectValues("that much", "damage")); + effect.setText("its controller puts that many 1/1 green Squirrel creature tokens onto the battlefield"); + this.addAbility(new DamageDealtToAttachedTriggeredAbility(Zone.BATTLEFIELD, effect, false, SetTargetPointer.PLAYER)); } public DruidsCall(final DruidsCall card) { @@ -81,79 +80,3 @@ public class DruidsCall extends CardImpl { return new DruidsCall(this); } } - -class DruidsCallTriggeredAbility extends TriggeredAbilityImpl { - - public DruidsCallTriggeredAbility() { - super(Zone.BATTLEFIELD, new DruidsCallEffect()); - } - - public DruidsCallTriggeredAbility(final DruidsCallTriggeredAbility ability) { - super(ability); - } - - @Override - public DruidsCallTriggeredAbility copy() { - return new DruidsCallTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.DAMAGED_CREATURE; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - Permanent enchantment = game.getPermanent(sourceId); - UUID targetId = event.getTargetId(); - if (enchantment != null && enchantment.getAttachedTo() != null && targetId.equals(enchantment.getAttachedTo())) { - this.getEffects().get(0).setValue("damageAmount", event.getAmount()); - this.getEffects().get(0).setTargetPointer(new FixedTarget(targetId)); - return true; - } - return false; - } - - @Override - public String getRule() { - return "Whenever enchanted creature is dealt damage, its controller puts that many 1/1 green Squirrel creature tokens onto the battlefield."; - } -} - -class DruidsCallEffect extends OneShotEffect { - - public DruidsCallEffect() { - super(Outcome.Damage); - this.staticText = "its controller puts that many 1/1 green Squirrel creature tokens onto the battlefield"; - } - - public DruidsCallEffect(final DruidsCallEffect effect) { - super(effect); - } - - @Override - public DruidsCallEffect copy() { - return new DruidsCallEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Integer damageAmount = (Integer) this.getValue("damageAmount"); - UUID targetId = this.targetPointer.getFirst(game, source); - if (damageAmount != null && targetId != null) { - Permanent permanent = game.getPermanent(targetId); - if (permanent == null) { - permanent = (Permanent) game.getLastKnownInformation(targetId, Zone.BATTLEFIELD); - } - if (permanent != null) { - Player player = game.getPlayer(permanent.getControllerId()); - if (player != null) { - Token token = new SquirrelToken(); - token.putOntoBattlefield(damageAmount, game, source.getSourceId(), player.getId()); - return true; - } - } - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/odyssey/MossfireEgg.java b/Mage.Sets/src/mage/sets/odyssey/MossfireEgg.java new file mode 100644 index 00000000000..693f6be1ed4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/odyssey/MossfireEgg.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.odyssey; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class MossfireEgg extends CardImpl { + + public MossfireEgg(UUID ownerId) { + super(ownerId, 304, "Mossfire Egg", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ODY"; + + // {2}, {tap}, Sacrifice Mossfire Egg: Add {R}{G} to your mana pool. Draw a card. + ManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 1, 0, 0, 0, 0, 0), new ManaCostsImpl("{2}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public MossfireEgg(final MossfireEgg card) { + super(card); + } + + @Override + public MossfireEgg copy() { + return new MossfireEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/RepentantVampire.java b/Mage.Sets/src/mage/sets/odyssey/RepentantVampire.java index 33480b005c4..c2062edc5ef 100644 --- a/Mage.Sets/src/mage/sets/odyssey/RepentantVampire.java +++ b/Mage.Sets/src/mage/sets/odyssey/RepentantVampire.java @@ -38,8 +38,8 @@ import mage.abilities.condition.common.CardsInControllerGraveCondition; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.decorator.ConditionalContinuousEffect; import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.continuous.BecomesColorSourceEffect; import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; -import mage.abilities.effects.common.continuous.SetCardColorSourceEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; @@ -77,7 +77,7 @@ public class RepentantVampire extends CardImpl { this.addAbility(new DiesAndDealtDamageThisTurnTriggeredAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance()), false)); // Threshold - As long as seven or more cards are in your graveyard, Repentant Vampire is white and has "{tap}: Destroy target black creature." Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( - new SetCardColorSourceEffect(ObjectColor.WHITE, Duration.WhileOnBattlefield), + new BecomesColorSourceEffect(ObjectColor.WHITE, Duration.WhileOnBattlefield), new CardsInControllerGraveCondition(7), "Threshold - As long as seven or more cards are in your graveyard, {this} is white")); Ability gainedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new TapSourceCost()); diff --git a/Mage.Sets/src/mage/sets/odyssey/ShadowbloodEgg.java b/Mage.Sets/src/mage/sets/odyssey/ShadowbloodEgg.java new file mode 100644 index 00000000000..c2de9c96901 --- /dev/null +++ b/Mage.Sets/src/mage/sets/odyssey/ShadowbloodEgg.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.odyssey; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class ShadowbloodEgg extends CardImpl { + + public ShadowbloodEgg(UUID ownerId) { + super(ownerId, 308, "Shadowblood Egg", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ODY"; + + // {2}, {tap}, Sacrifice Shadowblood Egg: Add {B}{R} to your mana pool. Draw a card. + ManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(1, 0, 0, 0, 1, 0, 0), new ManaCostsImpl("{2}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public ShadowbloodEgg(final ShadowbloodEgg card) { + super(card); + } + + @Override + public ShadowbloodEgg copy() { + return new ShadowbloodEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/SkycloudEgg.java b/Mage.Sets/src/mage/sets/odyssey/SkycloudEgg.java new file mode 100644 index 00000000000..622f19765c1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/odyssey/SkycloudEgg.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.odyssey; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class SkycloudEgg extends CardImpl { + + public SkycloudEgg(UUID ownerId) { + super(ownerId, 309, "Skycloud Egg", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ODY"; + + // {2}, {tap}, Sacrifice Skycloud Egg: Add {W}{U} to your mana pool. Draw a card. + ManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 0, 1, 1, 0, 0, 0), new ManaCostsImpl("{2}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public SkycloudEgg(final SkycloudEgg card) { + super(card); + } + + @Override + public SkycloudEgg copy() { + return new SkycloudEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/SungrassEgg.java b/Mage.Sets/src/mage/sets/odyssey/SungrassEgg.java new file mode 100644 index 00000000000..06a04ccfed1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/odyssey/SungrassEgg.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.odyssey; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class SungrassEgg extends CardImpl { + + public SungrassEgg(UUID ownerId) { + super(ownerId, 311, "Sungrass Egg", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "ODY"; + + // {2}, {tap}, Sacrifice Sungrass Egg: Add {G}{W} to your mana pool. Draw a card. + ManaAbility ability = new SimpleManaAbility(Zone.BATTLEFIELD, new Mana(0, 1, 0, 1, 0, 0, 0), new ManaCostsImpl("{2}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + ability.setUndoPossible(false); + this.addAbility(ability); + } + + public SungrassEgg(final SungrassEgg card) { + super(card); + } + + @Override + public SungrassEgg copy() { + return new SungrassEgg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/odyssey/TaintedPact.java b/Mage.Sets/src/mage/sets/odyssey/TaintedPact.java index 09b9c6d6f25..1674834f938 100644 --- a/Mage.Sets/src/mage/sets/odyssey/TaintedPact.java +++ b/Mage.Sets/src/mage/sets/odyssey/TaintedPact.java @@ -90,7 +90,7 @@ class TaintedPactEffect extends OneShotEffect{ return false; } Set names = new HashSet<>(); - while (player.isInGame() && player.getLibrary().size() > 0) { + while (player.canRespond() && player.getLibrary().size() > 0) { Card card = player.getLibrary().getFromTop(game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/odyssey/WaywardAngel.java b/Mage.Sets/src/mage/sets/odyssey/WaywardAngel.java index f73fe6f3e36..0c65b84ddad 100644 --- a/Mage.Sets/src/mage/sets/odyssey/WaywardAngel.java +++ b/Mage.Sets/src/mage/sets/odyssey/WaywardAngel.java @@ -36,9 +36,9 @@ import mage.abilities.common.SimpleStaticAbility; import mage.abilities.condition.common.CardsInControllerGraveCondition; import mage.abilities.decorator.ConditionalContinuousEffect; import mage.abilities.effects.common.SacrificeControllerEffect; +import mage.abilities.effects.common.continuous.BecomesColorSourceEffect; import mage.abilities.effects.common.continuous.BoostSourceEffect; import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; -import mage.abilities.effects.common.continuous.SetCardColorSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.TrampleAbility; import mage.abilities.keyword.VigilanceAbility; @@ -75,21 +75,21 @@ public class WaywardAngel extends CardImpl { new CardsInControllerGraveCondition(7), "Threshold - As long as seven or more cards are in your graveyard, {this} gets +3/+3,")); ability.addEffect(new ConditionalContinuousEffect( - new SetCardColorSourceEffect(ObjectColor.BLACK, Duration.WhileOnBattlefield), + new BecomesColorSourceEffect(ObjectColor.BLACK, Duration.WhileOnBattlefield), new CardsInControllerGraveCondition(7), " is black,")); ability.addEffect(new ConditionalContinuousEffect( new GainAbilitySourceEffect(TrampleAbility.getInstance()), new CardsInControllerGraveCondition(7), " has trample,")); - + Ability gainedAbility = new BeginningOfUpkeepTriggeredAbility(new SacrificeControllerEffect(new FilterControlledCreaturePermanent(), 1, ""), TargetController.YOU, false); - + ability.addEffect(new ConditionalContinuousEffect( new GainAbilitySourceEffect(gainedAbility), new CardsInControllerGraveCondition(7), " and has \"At the beginning of your upkeep, sacrifice a creature.\" ")); - + this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/onslaught/AkromasBlessing.java b/Mage.Sets/src/mage/sets/onslaught/AkromasBlessing.java index bf42de81296..4b301c061ec 100644 --- a/Mage.Sets/src/mage/sets/onslaught/AkromasBlessing.java +++ b/Mage.Sets/src/mage/sets/onslaught/AkromasBlessing.java @@ -99,7 +99,7 @@ class AkromasBlessingChooseColorEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/onslaught/Aurification.java b/Mage.Sets/src/mage/sets/onslaught/Aurification.java new file mode 100644 index 00000000000..92479ceca51 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/Aurification.java @@ -0,0 +1,164 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.BecomesSubtypeAllEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.*; +import mage.counters.CounterType; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.CounterPredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.target.targetpointer.FixedTarget; + +import java.util.ArrayList; +import java.util.UUID; + +/** + * + * @author andyfries + */ + +public class Aurification extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Each creature with a gold counter on it"); + + static { + filter.add(new CounterPredicate(CounterType.GOLD)); + } + + final String rule = "Each creature with a gold counter on it is a Wall in addition to its other creature types and has defender."; + + public Aurification(UUID ownerId) { + super(ownerId, 6, "Aurification", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}{W}"); + this.expansionSetCode = "ONS"; + + // Whenever a creature deals damage to you, put a gold counter on it. + this.addAbility(new AddGoldCountersAbility()); + + // Each creature with a gold counter on it is a Wall in addition to its other creature types and has defender. + ArrayList subtypes = new ArrayList<>(1); + subtypes.add("Wall"); + + BecomesSubtypeAllEffect becomesSubtypeAllEffect = new BecomesSubtypeAllEffect(Duration.WhileOnBattlefield, subtypes, filter, false); + becomesSubtypeAllEffect.setText(""); + + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, becomesSubtypeAllEffect)); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(DefenderAbility.getInstance(), Duration.WhileOnBattlefield, filter, rule))); + + // When Aurification leaves the battlefield, remove all gold counters from all creatures. + this.addAbility(new LeavesBattlefieldTriggeredAbility(new RemoveAllGoldCountersEffect(), false)); + } + + public Aurification(final Aurification card) { + super(card); + } + + @Override + public Aurification copy() { + return new Aurification(this); + } + + public class AddGoldCountersAbility extends TriggeredAbilityImpl { + + public AddGoldCountersAbility() { + super(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.GOLD.createInstance())); + } + + public AddGoldCountersAbility(final AddGoldCountersAbility ability) { + super(ability); + } + + @Override + public AddGoldCountersAbility copy() { + return new AddGoldCountersAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.DAMAGED_PLAYER; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (event.getPlayerId().equals(this.getControllerId())) { + Permanent permanent = game.getPermanent(event.getSourceId()); + if (permanent != null && permanent.getCardType().contains(CardType.CREATURE)) { + for (Effect effect : this.getEffects()) { + effect.setTargetPointer(new FixedTarget(event.getSourceId())); + } + return true; + } + } + return false; + } + + @Override + public String getRule() { + return "Whenever a creature deals damage to you, put a gold counter on it."; + } + + } + + public class RemoveAllGoldCountersEffect extends OneShotEffect { + public RemoveAllGoldCountersEffect() { + super(Outcome.Neutral); + this.staticText = "remove all gold counters from all creatures"; + } + + public RemoveAllGoldCountersEffect(final RemoveAllGoldCountersEffect effect) { + super(effect); + } + + @Override + public RemoveAllGoldCountersEffect copy() { + return new RemoveAllGoldCountersEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents(CardType.CREATURE)) { + if (permanent != null){ + permanent.getCounters().removeAllCounters(CounterType.GOLD); + } + } + return true; + } + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/onslaught/CabalArchon.java b/Mage.Sets/src/mage/sets/onslaught/CabalArchon.java new file mode 100644 index 00000000000..e67cd3fa843 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/CabalArchon.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.LoseLifeTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPlayer; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CabalArchon extends CardImpl { + + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("Cleric"); + + static { + filter.add(new SubtypePredicate("Cleric")); + } + + public CabalArchon(UUID ownerId) { + super(ownerId, 129, "Cabal Archon", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {B}, Sacrifice a Cleric: Target player loses 2 life and you gain 2 life. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new LoseLifeTargetEffect(2), new ManaCostsImpl("{B}")); + ability.addEffect(new GainLifeEffect(2)); + ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, filter, false))); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + } + + public CabalArchon(final CabalArchon card) { + super(card); + } + + @Override + public CabalArchon copy() { + return new CabalArchon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/CabalExecutioner.java b/Mage.Sets/src/mage/sets/onslaught/CabalExecutioner.java new file mode 100644 index 00000000000..f29be5c3967 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/CabalExecutioner.java @@ -0,0 +1,116 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.SacrificeEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.events.DamagedPlayerEvent; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author fireshoes + */ +public class CabalExecutioner extends CardImpl { + + public CabalExecutioner(UUID ownerId) { + super(ownerId, 130, "Cabal Executioner", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{B}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Cabal Executioner deals combat damage to a player, that player sacrifices a creature. + this.addAbility(new CabalExecutionerAbility()); + + // Morph {3}{B}{B} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{3}{B}{B}"))); + } + + public CabalExecutioner(final CabalExecutioner card) { + super(card); + } + + @Override + public CabalExecutioner copy() { + return new CabalExecutioner(this); + } +} + +class CabalExecutionerAbility extends TriggeredAbilityImpl { + + public CabalExecutionerAbility() { + super(Zone.BATTLEFIELD, new SacrificeEffect(new FilterCreaturePermanent(), 1, "")); + } + + public CabalExecutionerAbility(final CabalExecutionerAbility ability) { + super(ability); + } + + @Override + public CabalExecutionerAbility copy() { + return new CabalExecutionerAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return EventType.DAMAGED_PLAYER.equals(event.getType()); + } + + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + DamagedPlayerEvent damageEvent = (DamagedPlayerEvent) event; + if (damageEvent.isCombatDamage() && event.getSourceId().equals(this.getSourceId())) { + for (Effect effect : this.getEffects()) { + effect.setTargetPointer(new FixedTarget(event.getPlayerId())); + } + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever {this} deals combat damage to a player, that player sacrifices a creature."; + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/ChainOfVapor.java b/Mage.Sets/src/mage/sets/onslaught/ChainOfVapor.java index b03ec15c5ae..dd376b43af1 100644 --- a/Mage.Sets/src/mage/sets/onslaught/ChainOfVapor.java +++ b/Mage.Sets/src/mage/sets/onslaught/ChainOfVapor.java @@ -28,14 +28,13 @@ package mage.sets.onslaught; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; -import mage.constants.Outcome; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterControlledLandPermanent; import mage.game.Game; @@ -55,7 +54,6 @@ public class ChainOfVapor extends CardImpl { super(ownerId, 73, "Chain of Vapor", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{U}"); this.expansionSetCode = "ONS"; - // Return target nonland permanent to its owner's hand. Then that permanent's controller may sacrifice a land. If the player does, he or she may copy this spell and may choose a new target for that copy. this.getSpellAbility().addEffect(new ChainOfVaporEffect()); this.getSpellAbility().addTarget(new TargetNonlandPermanent()); @@ -94,16 +92,14 @@ class ChainOfVaporEffect extends OneShotEffect { } Permanent permanent = game.getPermanent(source.getFirstTarget()); if (permanent != null) { - if (!controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD)){ - return false; - } + controller.moveCards(permanent, null, Zone.HAND, source, game); Player player = game.getPlayer(permanent.getControllerId()); - if (player.chooseUse(Outcome.ReturnToHand, "Sacrifice a land to copy this spell?", source, game)){ + if (player.chooseUse(Outcome.ReturnToHand, "Sacrifice a land to copy this spell?", source, game)) { TargetControlledPermanent target = new TargetControlledPermanent(new FilterControlledLandPermanent()); - if (player.chooseTarget(Outcome.Sacrifice, target, source, game)){ + if (player.chooseTarget(Outcome.Sacrifice, target, source, game)) { Permanent land = game.getPermanent(target.getFirstTarget()); - if(land != null){ - if(land.sacrifice(source.getSourceId(), game)){ + if (land != null) { + if (land.sacrifice(source.getSourceId(), game)) { Spell spell = game.getStack().getSpell(source.getSourceId()); if (spell != null) { Spell copy = spell.copySpell(); @@ -123,9 +119,10 @@ class ChainOfVaporEffect extends OneShotEffect { } } } + return true; } - - return true; + + return false; } @Override diff --git a/Mage.Sets/src/mage/sets/onslaught/Complicate.java b/Mage.Sets/src/mage/sets/onslaught/Complicate.java index 29e679a624c..3d5023a5869 100644 --- a/Mage.Sets/src/mage/sets/onslaught/Complicate.java +++ b/Mage.Sets/src/mage/sets/onslaught/Complicate.java @@ -52,12 +52,12 @@ public class Complicate extends CardImpl { // Counter target spell unless its controller pays {3}. this.getSpellAbility().addEffect(new CounterUnlessPaysEffect(new GenericManaCost(3))); this.getSpellAbility().addTarget(new TargetSpell()); - + // Cycling {2}{U} this.addAbility(new CyclingAbility(new ManaCostsImpl<>("{2}{U}"))); - + // When you cycle Complicate, you may counter target spell unless its controller pays {1}. - Ability ability = new CycleTriggeredAbility(new CounterUnlessPaysEffect(new GenericManaCost(1))); + Ability ability = new CycleTriggeredAbility(new CounterUnlessPaysEffect(new GenericManaCost(1)), true); ability.addTarget(new TargetSpell()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/onslaught/DeathPulse.java b/Mage.Sets/src/mage/sets/onslaught/DeathPulse.java index be0c44a8f87..0cf9e25b03d 100644 --- a/Mage.Sets/src/mage/sets/onslaught/DeathPulse.java +++ b/Mage.Sets/src/mage/sets/onslaught/DeathPulse.java @@ -52,11 +52,11 @@ public class DeathPulse extends CardImpl { // Target creature gets -4/-4 until end of turn. this.getSpellAbility().addEffect(new BoostTargetEffect(-4, -4, Duration.EndOfTurn)); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); - + // Cycling {1}{B}{B} this.addAbility(new CyclingAbility(new ManaCostsImpl("{1}{B}{B}"))); // When you cycle Death Pulse, you may have target creature get -1/-1 until end of turn. - Ability ability = new CycleTriggeredAbility(new BoostTargetEffect(-1, -1, Duration.EndOfTurn)); + Ability ability = new CycleTriggeredAbility(new BoostTargetEffect(-1, -1, Duration.EndOfTurn), true); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/onslaught/DoubtlessOne.java b/Mage.Sets/src/mage/sets/onslaught/DoubtlessOne.java new file mode 100644 index 00000000000..006b01ae26d --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/DoubtlessOne.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class DoubtlessOne extends CardImpl { + + final static FilterPermanent filter = new FilterPermanent("Clerics on the battlefield"); + + static { + filter.add(new SubtypePredicate("Cleric")); + } + + public DoubtlessOne(UUID ownerId) { + super(ownerId, 27, "Doubtless One", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Cleric"); + this.subtype.add("Avatar"); + this.power = new MageInt(0); + this.toughness = new MageInt(0); + + // Doubtless One's power and toughness are each equal to the number of Clerics on the battlefield. + this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetPowerToughnessSourceEffect(new PermanentsOnBattlefieldCount(filter), Duration.EndOfGame))); + + // Whenever Doubtless One deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public DoubtlessOne(final DoubtlessOne card) { + super(card); + } + + @Override + public DoubtlessOne copy() { + return new DoubtlessOne(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/onslaught/DwarvenBlastminer.java b/Mage.Sets/src/mage/sets/onslaught/DwarvenBlastminer.java new file mode 100644 index 00000000000..98fe0119bc0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/DwarvenBlastminer.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class DwarvenBlastminer extends CardImpl { + + private static final FilterLandPermanent filter = new FilterLandPermanent("nonbasic land"); + + public DwarvenBlastminer(UUID ownerId) { + super(ownerId, 199, "Dwarven Blastminer", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Dwarf"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {2}{R}, {tap}: Destroy target nonbasic land. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{2}{R}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetLandPermanent(filter)); + this.addAbility(ability); + + // Morph {R} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{R}"))); + } + + public DwarvenBlastminer(final DwarvenBlastminer card) { + super(card); + } + + @Override + public DwarvenBlastminer copy() { + return new DwarvenBlastminer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/ElvenRiders.java b/Mage.Sets/src/mage/sets/onslaught/ElvenRiders.java index adf8229110d..b9413277a4b 100644 --- a/Mage.Sets/src/mage/sets/onslaught/ElvenRiders.java +++ b/Mage.Sets/src/mage/sets/onslaught/ElvenRiders.java @@ -29,14 +29,13 @@ package mage.sets.onslaught; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; @@ -53,7 +52,7 @@ public class ElvenRiders extends CardImpl { static { filter.add(Predicates.not(Predicates.or(new SubtypePredicate("Wall"), new AbilityPredicate(FlyingAbility.class)))); } - + public ElvenRiders(UUID ownerId) { super(ownerId, 254, "Elven Riders", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); this.expansionSetCode = "ONS"; @@ -63,7 +62,7 @@ public class ElvenRiders extends CardImpl { this.toughness = new MageInt(3); // Elven Riders can't be blocked except by Walls and/or creatures with flying. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public ElvenRiders(final ElvenRiders card) { diff --git a/Mage.Sets/src/mage/sets/onslaught/EssenceFracture.java b/Mage.Sets/src/mage/sets/onslaught/EssenceFracture.java new file mode 100644 index 00000000000..4484fadd996 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/EssenceFracture.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class EssenceFracture extends CardImpl { + + public EssenceFracture(UUID ownerId) { + super(ownerId, 82, "Essence Fracture", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{U}{U}"); + this.expansionSetCode = "ONS"; + + // Return two target creatures to their owners' hands. + Effect effect = new ReturnToHandTargetEffect(); + effect.setText("Return two target creatures to their owners' hands"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(2)); + + // Cycling {2}{U} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}{U}"))); + } + + public EssenceFracture(final EssenceFracture card) { + super(card); + } + + @Override + public EssenceFracture copy() { + return new EssenceFracture(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/GangrenousGoliath.java b/Mage.Sets/src/mage/sets/onslaught/GangrenousGoliath.java new file mode 100644 index 00000000000..9d4064426a8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/GangrenousGoliath.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapTargetCost; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GangrenousGoliath extends CardImpl { + + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("untapped Clerics"); + + static { + filter.add(new SubtypePredicate("Cleric")); + } + + public GangrenousGoliath(UUID ownerId) { + super(ownerId, 150, "Gangrenous Goliath", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{B}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Zombie"); + this.subtype.add("Giant"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Tap three untapped Clerics you control: Return Gangrenous Goliath from your graveyard to your hand. + this.addAbility(new SimpleActivatedAbility( + Zone.GRAVEYARD, + new ReturnToHandSourceEffect(), + new TapTargetCost(new TargetControlledCreaturePermanent(3, 3, filter, true)))); + } + + public GangrenousGoliath(final GangrenousGoliath card) { + super(card); + } + + @Override + public GangrenousGoliath copy() { + return new GangrenousGoliath(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/GoblinBurrows.java b/Mage.Sets/src/mage/sets/onslaught/GoblinBurrows.java index c54781b82e8..66bcc8033fe 100644 --- a/Mage.Sets/src/mage/sets/onslaught/GoblinBurrows.java +++ b/Mage.Sets/src/mage/sets/onslaught/GoblinBurrows.java @@ -49,7 +49,7 @@ import mage.target.common.TargetCreaturePermanent; */ public class GoblinBurrows extends CardImpl { - private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Goblin"); + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Goblin creature"); static { filter.add(new SubtypePredicate(("Goblin"))); diff --git a/Mage.Sets/src/mage/sets/onslaught/GoblinTaskmaster.java b/Mage.Sets/src/mage/sets/onslaught/GoblinTaskmaster.java new file mode 100644 index 00000000000..9d27c1aa72f --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/GoblinTaskmaster.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GoblinTaskmaster extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Goblin"); + + static { + filter.add(new SubtypePredicate("Goblin")); + } + + public GoblinTaskmaster(UUID ownerId) { + super(ownerId, 210, "Goblin Taskmaster", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Goblin"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}{R}: Target Goblin creature gets +1/+0 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{1}{R}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + + // Morph {R} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{R}"))); + } + + public GoblinTaskmaster(final GoblinTaskmaster card) { + super(card); + } + + @Override + public GoblinTaskmaster copy() { + return new GoblinTaskmaster(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/GustcloakSavior.java b/Mage.Sets/src/mage/sets/onslaught/GustcloakSavior.java new file mode 100644 index 00000000000..c6b4892ca19 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/GustcloakSavior.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BecomesBlockedAllTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.RemoveFromCombatTargetEffect; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LevelX2 + */ +public class GustcloakSavior extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("a creature you control"); + + static { + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public GustcloakSavior(UUID ownerId) { + super(ownerId, 36, "Gustcloak Savior", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{W}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Bird"); + this.subtype.add("Soldier"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Whenever a creature you control becomes blocked, you may untap that creature and remove it from combat. + Effect effect = new UntapTargetEffect(); + effect.setText("you may untap that creature"); + Ability ability = new BecomesBlockedAllTriggeredAbility(effect, true, filter, true); + effect = new RemoveFromCombatTargetEffect(); + effect.setText("and remove it from combat"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public GustcloakSavior(final GustcloakSavior card) { + super(card); + } + + @Override + public GustcloakSavior copy() { + return new GustcloakSavior(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/Inspirit.java b/Mage.Sets/src/mage/sets/onslaught/Inspirit.java new file mode 100644 index 00000000000..fd26c17183a --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/Inspirit.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Inspirit extends CardImpl { + + public Inspirit(UUID ownerId) { + super(ownerId, 41, "Inspirit", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}"); + this.expansionSetCode = "ONS"; + + // Untap target creature. It gets +2/+4 until end of turn. + this.getSpellAbility().addEffect(new UntapTargetEffect()); + Effect effect = new BoostTargetEffect(2, 4, Duration.EndOfTurn); + effect.setText("It gets +2/+4 until end of turn"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public Inspirit(final Inspirit card) { + super(card); + } + + @Override + public Inspirit copy() { + return new Inspirit(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/IronfistCrusher.java b/Mage.Sets/src/mage/sets/onslaught/IronfistCrusher.java new file mode 100644 index 00000000000..c8928d998c2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/IronfistCrusher.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CanBlockAdditionalCreatureEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class IronfistCrusher extends CardImpl { + + public IronfistCrusher(UUID ownerId) { + super(ownerId, 42, "Ironfist Crusher", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{W}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // Ironfist Crusher can block any number of creatures. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CanBlockAdditionalCreatureEffect(0))); + + // Morph {3}{W} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{3}{W}"))); + } + + public IronfistCrusher(final IronfistCrusher card) { + super(card); + } + + @Override + public IronfistCrusher copy() { + return new IronfistCrusher(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/KrosanColossus.java b/Mage.Sets/src/mage/sets/onslaught/KrosanColossus.java new file mode 100644 index 00000000000..bc7d6f1918e --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/KrosanColossus.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class KrosanColossus extends CardImpl { + + public KrosanColossus(UUID ownerId) { + super(ownerId, 270, "Krosan Colossus", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{6}{G}{G}{G}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Beast"); + this.power = new MageInt(9); + this.toughness = new MageInt(9); + + // Morph {6}{G}{G} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{6}{G}{G}"))); + } + + public KrosanColossus(final KrosanColossus card) { + super(card); + } + + @Override + public KrosanColossus copy() { + return new KrosanColossus(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/OversoldCemetery.java b/Mage.Sets/src/mage/sets/onslaught/OversoldCemetery.java new file mode 100644 index 00000000000..1f5ff6efbeb --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/OversoldCemetery.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInControllerGraveCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInGraveyard; + +/** + * + * @author fireshoes + */ +public class OversoldCemetery extends CardImpl { + + public OversoldCemetery(UUID ownerId) { + super(ownerId, 160, "Oversold Cemetery", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); + this.expansionSetCode = "ONS"; + + // At the beginning of your upkeep, if you have four or more creature cards in your graveyard, you may return target creature card from your graveyard to your hand. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToHandTargetEffect(), TargetController.YOU, true); + ability.addTarget(new TargetCardInGraveyard(new FilterCreatureCard())); + CardsInControllerGraveCondition condition = new CardsInControllerGraveCondition(4, new FilterCreatureCard("creature card from your graveyard")); + this.addAbility(new ConditionalTriggeredAbility(ability, condition, "At the beginning of your upkeep, if you have four or more creature cards in your graveyard, you may return target creature card from your graveyard to your hand.")); + } + + public OversoldCemetery(final OversoldCemetery card) { + super(card); + } + + @Override + public OversoldCemetery copy() { + return new OversoldCemetery(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/PatriarchsBidding.java b/Mage.Sets/src/mage/sets/onslaught/PatriarchsBidding.java index e5a030662c2..42b4dfd2de0 100644 --- a/Mage.Sets/src/mage/sets/onslaught/PatriarchsBidding.java +++ b/Mage.Sets/src/mage/sets/onslaught/PatriarchsBidding.java @@ -102,7 +102,7 @@ class PatriarchsBiddingEffect extends OneShotEffect { typeChoice.setMessage("Choose a creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.PutCreatureInPlay, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { break; } } diff --git a/Mage.Sets/src/mage/sets/onslaught/PeerPressure.java b/Mage.Sets/src/mage/sets/onslaught/PeerPressure.java new file mode 100644 index 00000000000..0dd856326d4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/PeerPressure.java @@ -0,0 +1,132 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.ContinuousEffect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.GainControlTargetEffect; +import mage.cards.CardImpl; +import mage.cards.repository.CardRepository; +import mage.choices.Choice; +import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author emerald000 + */ +public class PeerPressure extends CardImpl { + + public PeerPressure(UUID ownerId) { + super(ownerId, 101, "Peer Pressure", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{3}{U}"); + this.expansionSetCode = "ONS"; + + // Choose a creature type. If you control more creatures of that type than each other player, you gain control of all creatures of that type. + this.getSpellAbility().addEffect(new PeerPressureEffect()); + } + + public PeerPressure(final PeerPressure card) { + super(card); + } + + @Override + public PeerPressure copy() { + return new PeerPressure(this); + } +} + +class PeerPressureEffect extends OneShotEffect { + + PeerPressureEffect() { + super(Outcome.GainControl); + this.staticText = "Choose a creature type. If you control more creatures of that type than each other player, you gain control of all creatures of that type"; + } + + PeerPressureEffect(final PeerPressureEffect effect) { + super(effect); + } + + @Override + public PeerPressureEffect copy() { + return new PeerPressureEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + Choice choice = new ChoiceImpl(true); + choice.setMessage("Choose creature type"); + choice.setChoices(CardRepository.instance.getCreatureTypes()); + while (!controller.choose(Outcome.GainControl, choice, game)) { + if (!controller.canRespond()) { + return false; + } + } + String chosenType = choice.getChoice(); + if (!game.isSimulation()) { + game.informPlayers(controller.getLogName() + " has chosen " + chosenType); + } + UUID playerWithMost = null; + int maxControlled = 0; + for (UUID playerId : game.getState().getPlayersInRange(controller.getId(), game)) { + FilterPermanent filter = new FilterCreaturePermanent(chosenType, chosenType); + filter.add(new ControllerIdPredicate(playerId)); + int controlled = new PermanentsOnBattlefieldCount(filter).calculate(game, source, this); + if (controlled > maxControlled) { + maxControlled = controlled; + playerWithMost = playerId; + } else if (controlled == maxControlled) { + playerWithMost = null; // Do nothing in case of tie + } + } + if (playerWithMost != null && playerWithMost.equals(controller.getId())) { + for (Permanent permanent : game.getBattlefield().getActivePermanents(new FilterCreaturePermanent(chosenType, chosenType), controller.getId(), source.getSourceId(), game)) { + ContinuousEffect effect = new GainControlTargetEffect(Duration.EndOfGame); + effect.setTargetPointer(new FixedTarget(permanent.getId())); + game.addEffect(effect, source); + } + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/PrimalBoost.java b/Mage.Sets/src/mage/sets/onslaught/PrimalBoost.java new file mode 100644 index 00000000000..9d050f1fc28 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/PrimalBoost.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.CycleTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class PrimalBoost extends CardImpl { + + public PrimalBoost(UUID ownerId) { + super(ownerId, 277, "Primal Boost", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{G}"); + this.expansionSetCode = "ONS"; + + // Target creature gets +4/+4 until end of turn. + this.getSpellAbility().addEffect(new BoostTargetEffect(4, 4, Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + // Cycling {2}{G} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}{G}"))); + // When you cycle Primal Boost, you may have target creature get +1/+1 until end of turn. + Ability ability = new CycleTriggeredAbility(new BoostTargetEffect(1, 1, Duration.EndOfTurn), true); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public PrimalBoost(final PrimalBoost card) { + super(card); + } + + @Override + public PrimalBoost copy() { + return new PrimalBoost(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/RiptideShapeshifter.java b/Mage.Sets/src/mage/sets/onslaught/RiptideShapeshifter.java index d7f7e5d00b1..0f4b766a2cd 100644 --- a/Mage.Sets/src/mage/sets/onslaught/RiptideShapeshifter.java +++ b/Mage.Sets/src/mage/sets/onslaught/RiptideShapeshifter.java @@ -102,7 +102,7 @@ class RiptideShapeshifterEffect extends OneShotEffect { choice.setMessage("Choose a creature type:"); choice.setChoices(CardRepository.instance.getCreatureTypes()); while (!player.choose(Outcome.BoostCreature, choice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/onslaught/RotlungReanimator.java b/Mage.Sets/src/mage/sets/onslaught/RotlungReanimator.java new file mode 100644 index 00000000000..15ec38fc4df --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/RotlungReanimator.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DiesCreatureTriggeredAbility; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.game.permanent.token.ZombieToken; + +/** + * + * @author fireshoes + */ +public class RotlungReanimator extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("{this} or another Cleric"); + + static { + filter.add(new SubtypePredicate("Cleric")); + } + + public RotlungReanimator(UUID ownerId) { + super(ownerId, 164, "Rotlung Reanimator", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Zombie"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever Rotlung Reanimator or another Cleric dies, put a 2/2 black Zombie creature token onto the battlefield. + this.addAbility(new DiesCreatureTriggeredAbility(new CreateTokenEffect(new ZombieToken()), false, filter)); + } + + public RotlungReanimator(final RotlungReanimator card) { + super(card); + } + + @Override + public RotlungReanimator copy() { + return new RotlungReanimator(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/SageAven.java b/Mage.Sets/src/mage/sets/onslaught/SageAven.java new file mode 100644 index 00000000000..d1d40e34d7f --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/SageAven.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class SageAven extends mage.sets.ninthedition.SageAven { + + public SageAven(UUID ownerId) { + super(ownerId); + this.cardNumber = 111; + this.expansionSetCode = "ONS"; + } + + public SageAven(final SageAven card) { + super(card); + } + + @Override + public SageAven copy() { + return new SageAven(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/SeasideHaven.java b/Mage.Sets/src/mage/sets/onslaught/SeasideHaven.java index 193ab18919c..eaccc8185cf 100644 --- a/Mage.Sets/src/mage/sets/onslaught/SeasideHaven.java +++ b/Mage.Sets/src/mage/sets/onslaught/SeasideHaven.java @@ -33,6 +33,7 @@ import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.SacrificeTargetCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.mana.ColorlessManaAbility; import mage.cards.CardImpl; import mage.constants.CardType; @@ -47,9 +48,9 @@ import mage.target.common.TargetControlledPermanent; * @author anonymous */ public class SeasideHaven extends CardImpl { - + private static final FilterControlledPermanent filter = new FilterControlledPermanent("Bird"); - + static{ filter.add(new SubtypePredicate("Bird")); } @@ -61,7 +62,7 @@ public class SeasideHaven extends CardImpl { // {tap}: Add {1} to your mana pool. this.addAbility(new ColorlessManaAbility()); // {W}{U}, {tap}, Sacrifice a Bird: Draw a card. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, null, new ManaCostsImpl<>("{W}{U}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl<>("{W}{U}")); ability.addCost(new TapSourceCost()); ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter))); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/onslaught/SharedTriumph.java b/Mage.Sets/src/mage/sets/onslaught/SharedTriumph.java index bbaf9de2c45..1846892cc4e 100644 --- a/Mage.Sets/src/mage/sets/onslaught/SharedTriumph.java +++ b/Mage.Sets/src/mage/sets/onslaught/SharedTriumph.java @@ -39,8 +39,7 @@ import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; /** * @@ -55,9 +54,10 @@ public class SharedTriumph extends CardImpl { // As Shared Triumph enters the battlefield, choose a creature type. this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.BoostCreature))); - // Creatures of the chosen type get +1/+1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, new FilterSharedTriumph(), false))); + FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filter, false))); } public SharedTriumph(final SharedTriumph card) { @@ -69,31 +69,3 @@ public class SharedTriumph extends CardImpl { return new SharedTriumph(this); } } - -class FilterSharedTriumph extends FilterCreaturePermanent { - - public FilterSharedTriumph() { - super("Creatures of the chosen type"); - } - - public FilterSharedTriumph(final FilterSharedTriumph filter) { - super(filter); - } - - @Override - public FilterSharedTriumph copy() { - return new FilterSharedTriumph(this); - } - - @Override - public boolean match(Permanent permanent, UUID sourceId, UUID playerId, Game game) { - if(super.match(permanent, sourceId, playerId, game)){ - String subtype = (String) game.getState().getValue(sourceId + "_type"); - if(subtype != null && !subtype.equals("") && permanent.hasSubtype(subtype)){ - return true; - } - } - return false; - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/onslaught/SlipstreamEel.java b/Mage.Sets/src/mage/sets/onslaught/SlipstreamEel.java new file mode 100644 index 00000000000..a75ba50b483 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/SlipstreamEel.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class SlipstreamEel extends CardImpl { + + public SlipstreamEel(UUID ownerId) { + super(ownerId, 114, "Slipstream Eel", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{5}{U}{U}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Fish"); + this.subtype.add("Beast"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // Slipstream Eel can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + + // Cycling {1}{U} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{1}{U}"))); + } + + public SlipstreamEel(final SlipstreamEel card) { + super(card); + } + + @Override + public SlipstreamEel copy() { + return new SlipstreamEel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/Standardize.java b/Mage.Sets/src/mage/sets/onslaught/Standardize.java index c0f732a3706..760ae76aead 100644 --- a/Mage.Sets/src/mage/sets/onslaught/Standardize.java +++ b/Mage.Sets/src/mage/sets/onslaught/Standardize.java @@ -99,7 +99,7 @@ class StandardizeEffect extends OneShotEffect { types.remove("Wall"); typeChoice.setChoices(types); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/onslaught/SteelyResolve.java b/Mage.Sets/src/mage/sets/onslaught/SteelyResolve.java new file mode 100644 index 00000000000..169d77ca363 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/SteelyResolve.java @@ -0,0 +1,97 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.ChooseCreatureTypeEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author markedagain + */ +public class SteelyResolve extends CardImpl { + + public SteelyResolve(UUID ownerId) { + super(ownerId, 286, "Steely Resolve", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "ONS"; + + // As Steely Resolve enters the battlefield, choose a creature type. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.AddAbility))); + // Creatures of the chosen type have shroud. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(ShroudAbility.getInstance(), Duration.WhileOnBattlefield, new FilterSteelyResolve()))); + } + + public SteelyResolve(final SteelyResolve card) { + super(card); + } + + @Override + public SteelyResolve copy() { + return new SteelyResolve(this); + } +} +class FilterSteelyResolve extends FilterCreaturePermanent { + + public FilterSteelyResolve() { + super("All creatures of the chosen type"); + } + + public FilterSteelyResolve(final FilterSteelyResolve filter) { + super(filter); + } + + @Override + public FilterSteelyResolve copy() { + return new FilterSteelyResolve(this); + } + + @Override + public boolean match(Permanent permanent, UUID sourceId, UUID playerId, Game game) { + if (super.match(permanent, sourceId, playerId, game)) { + String subtype = (String) game.getState().getValue(sourceId + "_type"); + if (subtype != null && !subtype.equals("") && permanent.hasSubtype(subtype)) { + return true; + } + } + return false; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/onslaught/SunfireBalm.java b/Mage.Sets/src/mage/sets/onslaught/SunfireBalm.java new file mode 100644 index 00000000000..896fcdc29a9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/SunfireBalm.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.CycleTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class SunfireBalm extends CardImpl { + + public SunfireBalm(UUID ownerId) { + super(ownerId, 56, "Sunfire Balm", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{W}"); + this.expansionSetCode = "ONS"; + + // Prevent the next 4 damage that would be dealt to target creature or player this turn. + this.getSpellAbility().addEffect(new PreventDamageToTargetEffect(Duration.EndOfTurn, 4)); + this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); + // Cycling {1}{W} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{1}{W}"))); + // When you cycle Sunfire Balm, you may prevent the next 1 damage that would be dealt to target creature or player this turn. + Ability ability = new CycleTriggeredAbility(new PreventDamageToTargetEffect(Duration.EndOfTurn, 1), true); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + + } + + public SunfireBalm(final SunfireBalm card) { + super(card); + } + + @Override + public SunfireBalm copy() { + return new SunfireBalm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/UndeadGladiator.java b/Mage.Sets/src/mage/sets/onslaught/UndeadGladiator.java new file mode 100644 index 00000000000..19428fda45c --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/UndeadGladiator.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.condition.common.IsStepCondition; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.ReturnSourceFromGraveyardToHandEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class UndeadGladiator extends CardImpl { + + public UndeadGladiator(UUID ownerId) { + super(ownerId, 178, "Undead Gladiator", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Zombie"); + this.subtype.add("Barbarian"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // {1}{B}, Discard a card: Return Undead Gladiator from your graveyard to your hand. Activate this ability only during your upkeep. + Ability ability = new ConditionalActivatedAbility(Zone.GRAVEYARD, + new ReturnSourceFromGraveyardToHandEffect(), + new ManaCostsImpl("{1}{B}"), + new IsStepCondition(PhaseStep.UPKEEP), null); + ability.addCost(new DiscardCardCost()); + this.addAbility(ability); + + // Cycling {1}{B} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{1}{B}"))); + } + + public UndeadGladiator(final UndeadGladiator card) { + super(card); + } + + @Override + public UndeadGladiator copy() { + return new UndeadGladiator(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/WaveOfIndifference.java b/Mage.Sets/src/mage/sets/onslaught/WaveOfIndifference.java new file mode 100644 index 00000000000..6376ddddbe4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/WaveOfIndifference.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.combat.CantBlockTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author emerald000 + */ +public class WaveOfIndifference extends CardImpl { + + public WaveOfIndifference(UUID ownerId) { + super(ownerId, 243, "Wave of Indifference", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{X}{R}"); + this.expansionSetCode = "ONS"; + + // X target creatures can't block this turn. + Effect effect = new CantBlockTargetEffect(Duration.EndOfTurn); + effect.setText("X target creatures can't block this turn"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(0, 1, new FilterCreaturePermanent(), false)); + } + + public WaveOfIndifference(final WaveOfIndifference card) { + super(card); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability instanceof SpellAbility) { + ability.getTargets().clear(); + ability.addTarget(new TargetCreaturePermanent(ability.getManaCostsToPay().getX())); + } + } + + @Override + public WaveOfIndifference copy() { + return new WaveOfIndifference(this); + } +} diff --git a/Mage.Sets/src/mage/sets/onslaught/WeirdHarvest.java b/Mage.Sets/src/mage/sets/onslaught/WeirdHarvest.java index 1be7a060ebc..788ec1f3ab5 100644 --- a/Mage.Sets/src/mage/sets/onslaught/WeirdHarvest.java +++ b/Mage.Sets/src/mage/sets/onslaught/WeirdHarvest.java @@ -30,9 +30,9 @@ package mage.sets.onslaught; import java.util.ArrayList; import java.util.List; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; @@ -55,7 +55,6 @@ public class WeirdHarvest extends CardImpl { super(ownerId, 299, "Weird Harvest", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{X}{G}{G}"); this.expansionSetCode = "ONS"; - // Each player may search his or her library for up to X creature cards, reveal those cards, and put them into his or her hand. Then each player who searched his or her library this way shuffles it. getSpellAbility().addEffect(new WeirdHarvestEffect()); } @@ -89,20 +88,21 @@ class WeirdHarvestEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { int xValue = source.getManaCostsToPay().getX(); if (xValue > 0) { List usingPlayers = new ArrayList<>(); - this.chooseAndSearchLibrary(usingPlayers, controller, xValue, source, game); - for (UUID playerId: controller.getInRange()) { + this.chooseAndSearchLibrary(usingPlayers, controller, xValue, source, sourceObject, game); + for (UUID playerId : controller.getInRange()) { if (!playerId.equals(controller.getId())) { Player player = game.getPlayer(playerId); if (player != null) { - this.chooseAndSearchLibrary(usingPlayers, player, xValue, source, game); + this.chooseAndSearchLibrary(usingPlayers, player, xValue, source, sourceObject, game); } } } - for (Player player: usingPlayers) { + for (Player player : usingPlayers) { player.shuffleLibrary(game); } return true; @@ -111,21 +111,15 @@ class WeirdHarvestEffect extends OneShotEffect { return false; } - private void chooseAndSearchLibrary(List usingPlayers, Player player, int xValue, Ability source, Game game) { + private void chooseAndSearchLibrary(List usingPlayers, Player player, int xValue, Ability source, MageObject sourceObject, Game game) { if (player.chooseUse(Outcome.PutCardInPlay, "Search your library for up " + xValue + " creature cards and put them into your hand?", source, game)) { usingPlayers.add(player); TargetCardInLibrary target = new TargetCardInLibrary(0, xValue, new FilterCreatureCard()); if (player.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { - Cards cards = new CardsImpl(); - for (UUID cardId: (List)target.getTargets()) { - Card card = player.getLibrary().getCard(cardId, game); - if (card != null) { - cards.add(card); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - } - } - player.revealCards("Weird Harvest", cards, game); + Cards cards = new CardsImpl(target.getTargets()); + player.moveCards(cards, null, Zone.HAND, source, game); + player.revealCards(sourceObject.getIdName() + " (" + player.getName() + ")", cards, game); } } } diff --git a/Mage.Sets/src/mage/sets/onslaught/WordsOfWind.java b/Mage.Sets/src/mage/sets/onslaught/WordsOfWind.java index 54cac4d5891..756f729d359 100644 --- a/Mage.Sets/src/mage/sets/onslaught/WordsOfWind.java +++ b/Mage.Sets/src/mage/sets/onslaught/WordsOfWind.java @@ -99,7 +99,7 @@ class WordsOfWindEffect extends ReplacementEffectImpl { List liste = game.getBattlefield().getActivePermanents(new FilterControlledPermanent(), playerId, game); if(!liste.isEmpty()){ while (!player.choose(Outcome.ReturnToHand, target, source.getSourceId(), game)){ - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/onslaught/WretchedAnurid.java b/Mage.Sets/src/mage/sets/onslaught/WretchedAnurid.java new file mode 100644 index 00000000000..9c58825fe2b --- /dev/null +++ b/Mage.Sets/src/mage/sets/onslaught/WretchedAnurid.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.onslaught; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldAllTriggeredAbility; +import mage.abilities.effects.common.LoseLifeSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author fireshoes + */ +public class WretchedAnurid extends CardImpl { + + private static final FilterPermanent filter = new FilterCreaturePermanent("another creature"); + + static { + filter.add(new AnotherPredicate()); + } + + public WretchedAnurid(UUID ownerId) { + super(ownerId, 183, "Wretched Anurid", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "ONS"; + this.subtype.add("Zombie"); + this.subtype.add("Frog"); + this.subtype.add("Beast"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Whenever another creature enters the battlefield, you lose 1 life. + this.addAbility(new EntersBattlefieldAllTriggeredAbility(new LoseLifeSourceControllerEffect(1), filter)); + } + + public WretchedAnurid(final WretchedAnurid card) { + super(card); + } + + @Override + public WretchedAnurid copy() { + return new WretchedAnurid(this); + } +} diff --git a/Mage.Sets/src/mage/sets/pdsgraveborn/CrosisThePurger.java b/Mage.Sets/src/mage/sets/pdsgraveborn/CrosisThePurger.java new file mode 100644 index 00000000000..ad66b29cc28 --- /dev/null +++ b/Mage.Sets/src/mage/sets/pdsgraveborn/CrosisThePurger.java @@ -0,0 +1,53 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.pdsgraveborn; + +import java.util.UUID; + +/** + * + * @author LoneFox + + */ +public class CrosisThePurger extends mage.sets.invasion.CrosisThePurger { + + public CrosisThePurger(UUID ownerId) { + super(ownerId); + this.cardNumber = 5; + this.expansionSetCode = "PD3"; + } + + public CrosisThePurger(final CrosisThePurger card) { + super(card); + } + + @Override + public CrosisThePurger copy() { + return new CrosisThePurger(this); + } +} diff --git a/Mage.Sets/src/mage/sets/pdsgraveborn/SickeningDreams.java b/Mage.Sets/src/mage/sets/pdsgraveborn/SickeningDreams.java new file mode 100644 index 00000000000..0cfcfa9aff6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/pdsgraveborn/SickeningDreams.java @@ -0,0 +1,103 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.pdsgraveborn; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.Cost; +import mage.abilities.costs.VariableCostImpl; +import mage.abilities.costs.common.DiscardTargetCost; +import mage.abilities.dynamicvalue.common.GetXValue; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInHand; + +/** + * + * @author fireshoes + */ +public class SickeningDreams extends CardImpl { + + public SickeningDreams(UUID ownerId) { + super(ownerId, 18, "Sickening Dreams", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{B}"); + this.expansionSetCode = "PD3"; + + // As an additional cost to cast Sickening Dreams, discard X cards. + this.getSpellAbility().addCost(new SickeningDreamsAdditionalCost()); + + // Sickening Dreams deals X damage to each creature and each player. + this.getSpellAbility().addEffect(new DamageEverythingEffect(new GetXValue(), new FilterCreaturePermanent())); + } + + public SickeningDreams(final SickeningDreams card) { + super(card); + } + + @Override + public SickeningDreams copy() { + return new SickeningDreams(this); + } +} + +class SickeningDreamsAdditionalCost extends VariableCostImpl { + + SickeningDreamsAdditionalCost() { + super("cards to discard"); + this.text = "As an additional cost to cast {this}, discard X cards"; + } + + SickeningDreamsAdditionalCost(final SickeningDreamsAdditionalCost cost) { + super(cost); + } + + @Override + public SickeningDreamsAdditionalCost copy() { + return new SickeningDreamsAdditionalCost(this); + } + + @Override + public int getMaxValue(Ability source, Game game) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + return controller.getHand().size(); + } + return 0; + } + + @Override + public Cost getFixedCostsFromAnnouncedValue(int xValue) { + TargetCardInHand target = new TargetCardInHand(xValue, new FilterCard()); + return new DiscardTargetCost(target); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/phyrexiavsthecoalition/DarigaazTheIgniter.java b/Mage.Sets/src/mage/sets/phyrexiavsthecoalition/DarigaazTheIgniter.java index b8176452454..032facd8255 100644 --- a/Mage.Sets/src/mage/sets/phyrexiavsthecoalition/DarigaazTheIgniter.java +++ b/Mage.Sets/src/mage/sets/phyrexiavsthecoalition/DarigaazTheIgniter.java @@ -101,7 +101,7 @@ class DarigaazTheIgniterEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(true); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/planarchaos/AEtherMembrane.java b/Mage.Sets/src/mage/sets/planarchaos/AEtherMembrane.java new file mode 100644 index 00000000000..971b3c29428 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/AEtherMembrane.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; + +/** + * + * @author klayhamn + */ +public class AEtherMembrane extends mage.sets.venservskoth.AEtherMembrane { + + public AEtherMembrane(UUID ownerId) { + super(ownerId); + this.cardNumber = 93; + this.expansionSetCode = "PLC"; + } + + public AEtherMembrane(final AEtherMembrane card) { + super(card); + } + + @Override + public AEtherMembrane copy() { + return new AEtherMembrane(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/AvenRiftwatcher.java b/Mage.Sets/src/mage/sets/planarchaos/AvenRiftwatcher.java index 8cf27f15ec2..4da27ce5740 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/AvenRiftwatcher.java +++ b/Mage.Sets/src/mage/sets/planarchaos/AvenRiftwatcher.java @@ -29,6 +29,7 @@ package mage.sets.planarchaos; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.common.EntersOrLeavesTheBattlefieldSourceTriggeredAbility; import mage.abilities.effects.common.GainLifeEffect; @@ -60,7 +61,9 @@ public class AvenRiftwatcher extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); // Vanishing 3 - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(3)))); + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(3))); + ability.setRuleVisible(false); + this.addAbility(ability); this.addAbility(new VanishingUpkeepAbility(3)); this.addAbility(new VanishingSacrificeAbility()); diff --git a/Mage.Sets/src/mage/sets/planarchaos/BogSerpent.java b/Mage.Sets/src/mage/sets/planarchaos/BogSerpent.java new file mode 100644 index 00000000000..ca1f6bdcf33 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/BogSerpent.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class BogSerpent extends CardImpl { + + public BogSerpent(UUID ownerId) { + super(ownerId, 84, "Bog Serpent", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{5}{B}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Serpent"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Bog Serpent can't attack unless defending player controls a Swamp. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Swamp", "a Swamp")))); + + // When you control no Swamps, sacrifice Bog Serpent. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Swamp", "no Swamps"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public BogSerpent(final BogSerpent card) { + super(card); + } + + @Override + public BogSerpent copy() { + return new BogSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/BraidsConjurerAdept.java b/Mage.Sets/src/mage/sets/planarchaos/BraidsConjurerAdept.java new file mode 100644 index 00000000000..6938504723b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/BraidsConjurerAdept.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; + +/** + * + * @author LoneFox + */ +public class BraidsConjurerAdept extends CardImpl { + + private static final FilterCard filter = new FilterCard("artifact, creature, or land card") +; + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public BraidsConjurerAdept(UUID ownerId) { + super(ownerId, 36, "Braids, Conjurer Adept", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{U}{U}"); + this.expansionSetCode = "PLC"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // At the beginning of each player's upkeep, that player may put an artifact, creature, or land card from his or her hand onto the battlefield. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new PutPermanentOnBattlefieldEffect(filter, true), TargetController.ANY, false)); + } + + public BraidsConjurerAdept(final BraidsConjurerAdept card) { + super(card); + } + + @Override + public BraidsConjurerAdept copy() { + return new BraidsConjurerAdept(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/Calciderm.java b/Mage.Sets/src/mage/sets/planarchaos/Calciderm.java index 39865b67a5d..3bc5e170170 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/Calciderm.java +++ b/Mage.Sets/src/mage/sets/planarchaos/Calciderm.java @@ -28,15 +28,16 @@ package mage.sets.planarchaos; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.ShroudAbility; import mage.abilities.keyword.VanishingSacrificeAbility; import mage.abilities.keyword.VanishingUpkeepAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.counters.CounterType; /** @@ -56,7 +57,9 @@ public class Calciderm extends CardImpl { // Shroud this.addAbility(ShroudAbility.getInstance()); // Vanishing 4 - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(4)))); + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(4))); + ability.setRuleVisible(false); + this.addAbility(ability); this.addAbility(new VanishingUpkeepAbility(4)); this.addAbility(new VanishingSacrificeAbility()); } diff --git a/Mage.Sets/src/mage/sets/planarchaos/Chronozoa.java b/Mage.Sets/src/mage/sets/planarchaos/Chronozoa.java new file mode 100644 index 00000000000..ce30729322c --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/Chronozoa.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DiesCreatureTriggeredAbility; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.condition.common.LastTimeCounterRemovedCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.CopyCardEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.VanishingSacrificeAbility; +import mage.abilities.keyword.VanishingUpkeepAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.counters.CounterType; + +/** + * + * @author Gal Lerman + + */ +public class Chronozoa extends CardImpl { + + private static final int timeCounters = 3; + private static final int numCopies = 2; + + public Chronozoa(UUID ownerId) { + super(ownerId, 37, "Chronozoa", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Illusion"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Vanishing 3 + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(timeCounters))); + ability.setRuleVisible(false); + this.addAbility(ability); + this.addAbility(new VanishingUpkeepAbility(timeCounters)); + this.addAbility(new VanishingSacrificeAbility()); + // When Chronozoa is put into a graveyard from play, if it had no time counters on it, put two tokens into play that are copies of it. + this.addAbility(new ConditionalTriggeredAbility(new DiesCreatureTriggeredAbility(new CopyCardEffect(this, numCopies), false), + new LastTimeCounterRemovedCondition(), + "When {this} is put into a graveyard from play, if it had no time counters on it, put two tokens into play that are copies of it.")); + } + + public Chronozoa(final Chronozoa card) { + super(card); + } + + @Override + public Chronozoa copy() { + return new Chronozoa(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/DreamscapeArtist.java b/Mage.Sets/src/mage/sets/planarchaos/DreamscapeArtist.java new file mode 100644 index 00000000000..14335e8ba6b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/DreamscapeArtist.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterBasicLandCard; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetCardInLibrary; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class DreamscapeArtist extends CardImpl { + + public DreamscapeArtist(UUID ownerId) { + super(ownerId, 40, "Dreamscape Artist", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {2}{U}, {tap}, Discard a card, Sacrifice a land: Search your library for up to two basic land cards and put them onto the battlefield. Then shuffle your library. + TargetCardInLibrary target = new TargetCardInLibrary(0, 2, new FilterBasicLandCard()); + Ability ability = new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new SearchLibraryPutInPlayEffect(target, false, Outcome.PutLandInPlay), + new ManaCostsImpl("{2}{U}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("land")))); + this.addAbility(ability); + } + + public DreamscapeArtist(final DreamscapeArtist card) { + super(card); + } + + @Override + public DreamscapeArtist copy() { + return new DreamscapeArtist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/FatalFrenzy.java b/Mage.Sets/src/mage/sets/planarchaos/FatalFrenzy.java index 43ba60a9041..0bbef4cfb3c 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/FatalFrenzy.java +++ b/Mage.Sets/src/mage/sets/planarchaos/FatalFrenzy.java @@ -28,10 +28,6 @@ package mage.sets.planarchaos; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.DelayedTriggeredAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; @@ -43,7 +39,12 @@ import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.keyword.TrampleAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.target.common.TargetControlledCreaturePermanent; import mage.target.targetpointer.FixedTarget; @@ -57,7 +58,6 @@ public class FatalFrenzy extends CardImpl { super(ownerId, 98, "Fatal Frenzy", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{2}{R}"); this.expansionSetCode = "PLC"; - // Until end of turn, target creature you control gains trample and gets +X/+0, where X is its power. Sacrifice it at the beginning of the next end step. this.getSpellAbility().addEffect(new GainAbilityTargetEffect(TrampleAbility.getInstance(), Duration.EndOfTurn)); this.getSpellAbility().addEffect(new BoostTargetEffect(new TargetPermanentPowerCount(), new StaticValue(0), Duration.EndOfTurn, true)); @@ -94,13 +94,16 @@ class FatalFrenzyEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this"); - sacrificeEffect.setTargetPointer(new FixedTarget(source.getFirstTarget())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + Permanent targetCreature = game.getPermanent(source.getFirstTarget()); + if (targetCreature != null) { + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(targetCreature, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } return true; } } diff --git a/Mage.Sets/src/mage/sets/planarchaos/FreneticSliver.java b/Mage.Sets/src/mage/sets/planarchaos/FreneticSliver.java index 8a0c4422a4b..bcc9c5e9fc7 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/FreneticSliver.java +++ b/Mage.Sets/src/mage/sets/planarchaos/FreneticSliver.java @@ -97,7 +97,7 @@ class FreneticSliverEffect extends OneShotEffect { Player player = game.getPlayer(source.getControllerId()); if (player != null) { if (player.flipCoin(game)) { - return new ExileReturnToBattlefieldOwnerNextEndStepEffect().apply(game, source); + return new ExileReturnToBattlefieldOwnerNextEndStepEffect(true).apply(game, source); } else { Permanent perm = game.getPermanent(source.getSourceId()); if (perm != null) { diff --git a/Mage.Sets/src/mage/sets/planarchaos/GhostTactician.java b/Mage.Sets/src/mage/sets/planarchaos/GhostTactician.java new file mode 100644 index 00000000000..0dd988d3638 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/GhostTactician.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class GhostTactician extends CardImpl { + + public GhostTactician(UUID ownerId) { + super(ownerId, 6, "Ghost Tactician", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{W}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Spirit"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(2); + this.toughness = new MageInt(5); + + // {W}, {T}, Discard a card: Creatures you control get +1/+0 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new BoostControlledEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + this.addAbility(ability); + } + + public GhostTactician(final GhostTactician card) { + super(card); + } + + @Override + public GhostTactician copy() { + return new GhostTactician(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/GossamerPhantasm.java b/Mage.Sets/src/mage/sets/planarchaos/GossamerPhantasm.java new file mode 100644 index 00000000000..651ed2bd337 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/GossamerPhantasm.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BecomesTargetTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class GossamerPhantasm extends CardImpl { + + public GossamerPhantasm(UUID ownerId) { + super(ownerId, 55, "Gossamer Phantasm", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Illusion"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // When Gossamer Phantasm becomes the target of a spell or ability, sacrifice it. + this.addAbility(new BecomesTargetTriggeredAbility(new SacrificeSourceEffect())); + } + + public GossamerPhantasm(final GossamerPhantasm card) { + super(card); + } + + @Override + public GossamerPhantasm copy() { + return new GossamerPhantasm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/HealingLeaves.java b/Mage.Sets/src/mage/sets/planarchaos/HealingLeaves.java new file mode 100644 index 00000000000..f412e8438ce --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/HealingLeaves.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.GainLifeTargetEffect; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.TargetPlayer; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class HealingLeaves extends CardImpl { + + public HealingLeaves(UUID ownerId) { + super(ownerId, 150, "Healing Leaves", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{G}"); + this.expansionSetCode = "PLC"; + + // Choose one - Target player gains 3 life; or prevent the next 3 damage that would be dealt to target creature or player this turn. + this.getSpellAbility().addEffect(new GainLifeTargetEffect(3)); + this.getSpellAbility().addTarget(new TargetPlayer()); + Mode mode = new Mode(); + mode.getEffects().add(new PreventDamageToTargetEffect(Duration.EndOfTurn, 3)); + mode.getTargets().add(new TargetCreatureOrPlayer()); + this.getSpellAbility().addMode(mode); + } + + public HealingLeaves(final HealingLeaves card) { + super(card); + } + + @Override + public HealingLeaves copy() { + return new HealingLeaves(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/HedgeTroll.java b/Mage.Sets/src/mage/sets/planarchaos/HedgeTroll.java new file mode 100644 index 00000000000..95a342342b6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/HedgeTroll.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.abilities.effects.common.continuous.BoostSourceWhileControlsEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class HedgeTroll extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Plains"); + + static { + filter.add(new SubtypePredicate("Plains")); + } + + public HedgeTroll(UUID ownerId) { + super(ownerId, 151, "Hedge Troll", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Troll"); + this.subtype.add("Cleric"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Hedge Troll gets +1/+1 as long as you control a Plains. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceWhileControlsEffect(filter, 1, 1))); + + // {W}: Regenerate Hedge Troll. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{W}"))); + } + + public HedgeTroll(final HedgeTroll card) { + super(card); + } + + @Override + public HedgeTroll copy() { + return new HedgeTroll(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/JeditOjanenOfEfrava.java b/Mage.Sets/src/mage/sets/planarchaos/JeditOjanenOfEfrava.java new file mode 100644 index 00000000000..d8335051280 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/JeditOjanenOfEfrava.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.AttacksOrBlocksTriggeredAbility; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.keyword.ForestwalkAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.permanent.token.Token; + +/** + * + * @author fireshoes + */ +public class JeditOjanenOfEfrava extends CardImpl { + + public JeditOjanenOfEfrava(UUID ownerId) { + super(ownerId, 131, "Jedit Ojanen of Efrava", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}{G}{G}"); + this.expansionSetCode = "PLC"; + this.supertype.add("Legendary"); + this.subtype.add("Cat"); + this.subtype.add("Warrior"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Forestwalk + this.addAbility(new ForestwalkAbility()); + + // Whenever Jedit Ojanen of Efrava attacks or blocks, put a 2/2 green Cat Warrior creature token with forestwalk onto the battlefield. + this.addAbility(new AttacksOrBlocksTriggeredAbility(new CreateTokenEffect(new CatWarriorToken()), false)); + } + + public JeditOjanenOfEfrava(final JeditOjanenOfEfrava card) { + super(card); + } + + @Override + public JeditOjanenOfEfrava copy() { + return new JeditOjanenOfEfrava(this); + } +} + +class CatWarriorToken extends Token { + + CatWarriorToken() { + super("Cat Warrior", "2/2 green Cat Warrior creature token with forestwalk"); + this.setOriginalExpansionSetCode("PLC"); + this.getPower().initValue(2); + this.getToughness().initValue(2); + this.color.setGreen(true); + this.getSubtype().add("Cat"); + this.getSubtype().add("Warrior"); + this.getCardType().add(CardType.CREATURE); + this.addAbility(new ForestwalkAbility()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/planarchaos/KeldonMarauders.java b/Mage.Sets/src/mage/sets/planarchaos/KeldonMarauders.java index d342e0f28d2..952005b8c69 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/KeldonMarauders.java +++ b/Mage.Sets/src/mage/sets/planarchaos/KeldonMarauders.java @@ -28,8 +28,6 @@ package mage.sets.planarchaos; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldAbility; @@ -39,6 +37,8 @@ import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.VanishingSacrificeAbility; import mage.abilities.keyword.VanishingUpkeepAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.counters.CounterType; import mage.target.TargetPlayer; @@ -58,12 +58,14 @@ public class KeldonMarauders extends CardImpl { this.toughness = new MageInt(3); // Vanishing 2 - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(2)))); + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(2))); + ability.setRuleVisible(false); + this.addAbility(ability); this.addAbility(new VanishingUpkeepAbility(2)); this.addAbility(new VanishingSacrificeAbility()); - + // When Keldon Marauders enters the battlefield or leaves the battlefield, it deals 1 damage to target player. - Ability ability = new EntersOrLeavesTheBattlefieldSourceTriggeredAbility(new DamageTargetEffect(1), false); + ability = new EntersOrLeavesTheBattlefieldSourceTriggeredAbility(new DamageTargetEffect(1), false); ability.addTarget(new TargetPlayer()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/planarchaos/LavacoreElemental.java b/Mage.Sets/src/mage/sets/planarchaos/LavacoreElemental.java index c7ffdca38be..972e529d883 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/LavacoreElemental.java +++ b/Mage.Sets/src/mage/sets/planarchaos/LavacoreElemental.java @@ -29,6 +29,7 @@ package mage.sets.planarchaos; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.DealsDamageToAPlayerAllTriggeredAbility; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.effects.Effect; @@ -56,10 +57,12 @@ public class LavacoreElemental extends CardImpl { this.toughness = new MageInt(3); // Vanishing 1 - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(1)))); + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(1))); + ability.setRuleVisible(false); + this.addAbility(ability); this.addAbility(new VanishingUpkeepAbility(1)); this.addAbility(new VanishingSacrificeAbility()); - + // Whenever a creature you control deals combat damage to a player, put a time counter on Lavacore Elemental. Effect effect = new AddCountersSourceEffect(CounterType.TIME.createInstance(1)); effect.setText("put a time counter on {this}"); diff --git a/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheBazaar.java b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheBazaar.java new file mode 100644 index 00000000000..fa9b7eaf222 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheBazaar.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.DrawDiscardControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class MagusOfTheBazaar extends CardImpl { + + public MagusOfTheBazaar(UUID ownerId) { + super(ownerId, 43, "Magus of the Bazaar", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(0); + this.toughness = new MageInt(1); + + // {tap}: Draw two cards, then discard three cards. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawDiscardControllerEffect(2, 3), new TapSourceCost())); } + + public MagusOfTheBazaar(final MagusOfTheBazaar card) { + super(card); + } + + @Override + public MagusOfTheBazaar copy() { + return new MagusOfTheBazaar(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheLibrary.java b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheLibrary.java new file mode 100644 index 00000000000..81163b98e6b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheLibrary.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ColorlessManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class MagusOfTheLibrary extends CardImpl { + + public MagusOfTheLibrary(UUID ownerId) { + super(ownerId, 134, "Magus of the Library", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{G}{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {tap}: Add {1} to your mana pool. + this.addAbility(new ColorlessManaAbility()); + + // {tap}: Draw a card. Activate this ability only if you have exactly seven cards in hand. + this.addAbility(new ConditionalActivatedAbility( + Zone.BATTLEFIELD, + new DrawCardSourceControllerEffect(1), + new TapSourceCost(), + new CardsInHandCondition(CardsInHandCondition.CountType.EQUAL_TO, 7), + "")); + } + + public MagusOfTheLibrary(final MagusOfTheLibrary card) { + super(card); + } + + @Override + public MagusOfTheLibrary copy() { + return new MagusOfTheLibrary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheTabernacle.java b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheTabernacle.java index 96580e1a7d3..b71a27efed8 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheTabernacle.java +++ b/Mage.Sets/src/mage/sets/planarchaos/MagusOfTheTabernacle.java @@ -1,77 +1,77 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.planarchaos; - -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.constants.Zone; -import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.costs.mana.GenericManaCost; -import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; -import mage.abilities.effects.common.continuous.GainAbilityAllEffect; -import mage.cards.CardImpl; -import mage.filter.common.FilterCreaturePermanent; - -/** - * - * @author LevelX2 - */ -public class MagusOfTheTabernacle extends CardImpl { - - static private final String rule = "All creatures have \"At the beginning of your upkeep, sacrifice this creature unless you pay {1}\""; - - public MagusOfTheTabernacle(UUID ownerId) { - super(ownerId, 8, "Magus of the Tabernacle", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{W}"); - this.expansionSetCode = "PLC"; - this.subtype.add("Human"); - this.subtype.add("Wizard"); - - this.color.setWhite(true); - this.power = new MageInt(2); - this.toughness = new MageInt(6); - - // All creatures have "At the beginning of your upkeep, sacrifice this creature unless you pay {1}." - Ability abilityToGain = new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new GenericManaCost(1)), TargetController.YOU, false); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(abilityToGain, Duration.WhileInGraveyard, new FilterCreaturePermanent(), rule))); - } - - public MagusOfTheTabernacle(final MagusOfTheTabernacle card) { - super(card); - } - - @Override - public MagusOfTheTabernacle copy() { - return new MagusOfTheTabernacle(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author LevelX2 + */ +public class MagusOfTheTabernacle extends CardImpl { + + static private final String rule = "All creatures have \"At the beginning of your upkeep, sacrifice this creature unless you pay {1}\""; + + public MagusOfTheTabernacle(UUID ownerId) { + super(ownerId, 8, "Magus of the Tabernacle", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + + this.color.setWhite(true); + this.power = new MageInt(2); + this.toughness = new MageInt(6); + + // All creatures have "At the beginning of your upkeep, sacrifice this creature unless you pay {1}." + Ability abilityToGain = new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new GenericManaCost(1)), TargetController.YOU, false); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(abilityToGain, Duration.WhileOnBattlefield, new FilterCreaturePermanent(), rule))); + } + + public MagusOfTheTabernacle(final MagusOfTheTabernacle card) { + super(card); + } + + @Override + public MagusOfTheTabernacle copy() { + return new MagusOfTheTabernacle(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MalachOfTheDawn.java b/Mage.Sets/src/mage/sets/planarchaos/MalachOfTheDawn.java new file mode 100644 index 00000000000..6bbae42c676 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MalachOfTheDawn.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class MalachOfTheDawn extends CardImpl { + + public MalachOfTheDawn(UUID ownerId) { + super(ownerId, 24, "Malach of the Dawn", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{W}{W}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Angel"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // {W}{W}{W}: Regenerate Malach of the Dawn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{W}{W}{W}"))); + } + + public MalachOfTheDawn(final MalachOfTheDawn card) { + super(card); + } + + @Override + public MalachOfTheDawn copy() { + return new MalachOfTheDawn(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/Melancholy.java b/Mage.Sets/src/mage/sets/planarchaos/Melancholy.java new file mode 100644 index 00000000000..9a5c7cc3e63 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/Melancholy.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.TapEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; +/** + * + * @author LoneFox + */ +public class Melancholy extends CardImpl { + + public Melancholy(UUID ownerId) { + super(ownerId, 88, "Melancholy", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + // When Melancholy enters the battlefield, tap enchanted creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapEnchantedEffect())); + // Enchanted creature doesn't untap during its controller's untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepEnchantedEffect())); + // At the beginning of your upkeep, sacrifice Melancholy unless you pay {B}. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new ManaCostsImpl("{B}")), + TargetController.YOU, false)); + } + + public Melancholy(final Melancholy card) { + super(card); + } + + @Override + public Melancholy copy() { + return new Melancholy(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MerfolkThaumaturgist.java b/Mage.Sets/src/mage/sets/planarchaos/MerfolkThaumaturgist.java new file mode 100644 index 00000000000..849ade5be0e --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MerfolkThaumaturgist.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.SwitchPowerToughnessTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class MerfolkThaumaturgist extends CardImpl { + + public MerfolkThaumaturgist(UUID ownerId) { + super(ownerId, 56, "Merfolk Thaumaturgist", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {tap}: Switch target creature's power and toughness until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SwitchPowerToughnessTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public MerfolkThaumaturgist(final MerfolkThaumaturgist card) { + super(card); + } + + @Override + public MerfolkThaumaturgist copy() { + return new MerfolkThaumaturgist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MidnightCharm.java b/Mage.Sets/src/mage/sets/planarchaos/MidnightCharm.java new file mode 100644 index 00000000000..3e280291816 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MidnightCharm.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class MidnightCharm extends CardImpl { + + public MidnightCharm(UUID ownerId) { + super(ownerId, 74, "Midnight Charm", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{B}"); + this.expansionSetCode = "PLC"; + + // Choose one - Midnight Charm deals 1 damage to target creature and you gain 1 life; or target creature gains first strike until end of turn; or tap target creature. + this.getSpellAbility().addEffect(new DamageTargetEffect(1)); + this.getSpellAbility().addEffect(new GainLifeEffect(1)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + Mode mode = new Mode(); + mode.getEffects().add(new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn)); + mode.getTargets().add(new TargetCreaturePermanent()); + this.getSpellAbility().addMode(mode); + mode = new Mode(); + mode.getEffects().add(new TapTargetEffect()); + mode.getTargets().add(new TargetCreaturePermanent()); + this.getSpellAbility().addMode(mode); + } + + public MidnightCharm(final MidnightCharm card) { + super(card); + } + + @Override + public MidnightCharm copy() { + return new MidnightCharm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/MireBoa.java b/Mage.Sets/src/mage/sets/planarchaos/MireBoa.java new file mode 100644 index 00000000000..9f3f6d05c77 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/MireBoa.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.abilities.keyword.SwampwalkAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class MireBoa extends CardImpl { + + public MireBoa(UUID ownerId) { + super(ownerId, 135, "Mire Boa", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Snake"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Swampwalk + this.addAbility(new SwampwalkAbility()); + + // {G}: Regenerate Mire Boa. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{G}"))); + } + + public MireBoa(final MireBoa card) { + super(card); + } + + @Override + public MireBoa copy() { + return new MireBoa(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/Pyrohemia.java b/Mage.Sets/src/mage/sets/planarchaos/Pyrohemia.java new file mode 100644 index 00000000000..1c79bd7b92d --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/Pyrohemia.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.OnEventTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.condition.common.NoCreatureCondition; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.events.GameEvent; + +/** + * + * @author fireshoes + */ +public class Pyrohemia extends CardImpl { + + private static final String ruleText = "At the beginning of the end step, if no creatures are on the battlefield, sacrifice Pyrohemia."; + + public Pyrohemia(UUID ownerId) { + super(ownerId, 119, "Pyrohemia", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}{R}"); + this.expansionSetCode = "PLC"; + + // At the beginning of the end step, if no creatures are on the battlefield, sacrifice Pyrohemia. + TriggeredAbility triggered = new OnEventTriggeredAbility(GameEvent.EventType.END_TURN_STEP_PRE, "beginning of the end step", true, new SacrificeSourceEffect()); + this.addAbility(new ConditionalTriggeredAbility(triggered, new NoCreatureCondition(), ruleText)); + + // {R}: Pyrohemia deals 1 damage to each creature and each player. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEverythingEffect(1), new ManaCostsImpl("{R}"))); + } + + public Pyrohemia(final Pyrohemia card) { + super(card); + } + + @Override + public Pyrohemia copy() { + return new Pyrohemia(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/RealityAcid.java b/Mage.Sets/src/mage/sets/planarchaos/RealityAcid.java new file mode 100644 index 00000000000..ac39868c19b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/RealityAcid.java @@ -0,0 +1,125 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.ZoneChangeTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.VanishingSacrificeAbility; +import mage.abilities.keyword.VanishingUpkeepAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.target.TargetPermanent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author fireshoes + */ +public class RealityAcid extends CardImpl { + + public RealityAcid(UUID ownerId) { + super(ownerId, 45, "Reality Acid", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Aura"); + + // Enchant permanent + TargetPermanent auraTarget = new TargetPermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.GainControl)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Vanishing 3 + ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(3))); + ability.setRuleVisible(false); + this.addAbility(ability); + this.addAbility(new VanishingUpkeepAbility(3)); + this.addAbility(new VanishingSacrificeAbility()); + + // When Reality Acid leaves the battlefield, enchanted permanent's controller sacrifices it. + Effect effect = new SacrificeTargetEffect("enchanted permanent's controller sacrifices it"); + this.addAbility(new RealityAcidTriggeredAbility(effect, false)); + } + + public RealityAcid(final RealityAcid card) { + super(card); + } + + @Override + public RealityAcid copy() { + return new RealityAcid(this); + } +} + +class RealityAcidTriggeredAbility extends ZoneChangeTriggeredAbility { + + public RealityAcidTriggeredAbility(Effect effect, boolean optional) { + super(Zone.BATTLEFIELD, null, effect, "When {this} leaves the battlefield, ", optional); + } + + public RealityAcidTriggeredAbility(RealityAcidTriggeredAbility ability) { + super(ability); + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (super.checkTrigger(event, game)) { + Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(getSourceId()); + if (sourcePermanent != null && sourcePermanent.getAttachedTo() != null) { + Permanent attachedTo = game.getPermanent(sourcePermanent.getAttachedTo()); + if (attachedTo != null) { + for (Effect effect : getEffects()) { + effect.setTargetPointer(new FixedTarget(attachedTo.getId(), attachedTo.getZoneChangeCounter(game))); + } + } + } + return true; + } + return false; + } + + @Override + public RealityAcidTriggeredAbility copy() { + return new RealityAcidTriggeredAbility(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/ReveredDead.java b/Mage.Sets/src/mage/sets/planarchaos/ReveredDead.java new file mode 100644 index 00000000000..18abc745114 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/ReveredDead.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class ReveredDead extends CardImpl { + + public ReveredDead(UUID ownerId) { + super(ownerId, 29, "Revered Dead", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Spirit"); + this.subtype.add("Soldier"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {W}: Regenerate Revered Dead. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ManaCostsImpl("{W}"))); + } + + public ReveredDead(final ReveredDead card) { + super(card); + } + + @Override + public ReveredDead copy() { + return new ReveredDead(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/RidgedKusite.java b/Mage.Sets/src/mage/sets/planarchaos/RidgedKusite.java new file mode 100644 index 00000000000..87ab8078e8e --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/RidgedKusite.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class RidgedKusite extends CardImpl { + + public RidgedKusite(UUID ownerId) { + super(ownerId, 78, "Ridged Kusite", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Horror"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}{B}, {tap}, Discard a card: Target creature gets +1/+0 and gains first strike until end of turn. + Effect effect = new BoostTargetEffect(1, 0, Duration.EndOfTurn); + effect.setText("Target creature gets +1/+0"); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{1}{B}")); + effect = new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and gains first strike until end of turn"); + ability.addEffect(effect); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public RidgedKusite(final RidgedKusite card) { + super(card); + } + + @Override + public RidgedKusite copy() { + return new RidgedKusite(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/RiptidePilferer.java b/Mage.Sets/src/mage/sets/planarchaos/RiptidePilferer.java new file mode 100644 index 00000000000..dbb0b57f71c --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/RiptidePilferer.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class RiptidePilferer extends CardImpl { + + public RiptidePilferer(UUID ownerId) { + super(ownerId, 60, "Riptide Pilferer", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Merfolk"); + this.subtype.add("Rogue"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Whenever Riptide Pilferer deals combat damage to a player, that player discards a card. + this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new DiscardTargetEffect(1), false, true)); // Morph {U} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{U}"))); + } + + public RiptidePilferer(final RiptidePilferer card) { + super(card); + } + + @Override + public RiptidePilferer copy() { + return new RiptidePilferer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/ShadeOfTrokair.java b/Mage.Sets/src/mage/sets/planarchaos/ShadeOfTrokair.java new file mode 100644 index 00000000000..eca024d270c --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/ShadeOfTrokair.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.keyword.SuspendAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class ShadeOfTrokair extends CardImpl { + + public ShadeOfTrokair(UUID ownerId) { + super(ownerId, 18, "Shade of Trokair", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Shade"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {W}: Shade of Trokair gets +1/+1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(1, 1, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.W))); + + // Suspend 3-{W} + this.addAbility(new SuspendAbility(3, new ManaCostsImpl("{W}"), this)); + } + + public ShadeOfTrokair(final ShadeOfTrokair card) { + super(card); + } + + @Override + public ShadeOfTrokair copy() { + return new ShadeOfTrokair(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/ShroudedLore.java b/Mage.Sets/src/mage/sets/planarchaos/ShroudedLore.java new file mode 100644 index 00000000000..a9ffdeab0bc --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/ShroudedLore.java @@ -0,0 +1,141 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.Cost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardIdPredicate; +import mage.filter.predicate.other.OwnerIdPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInGraveyard; +import mage.target.common.TargetOpponent; + +/** + * + * @author LoneFox + */ +public class ShroudedLore extends CardImpl { + + public ShroudedLore(UUID ownerId) { + super(ownerId, 91, "Shrouded Lore", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{B}"); + this.expansionSetCode = "PLC"; + + // Target opponent chooses a card in your graveyard. You may pay {B}. If you do, repeat this process except that opponent can't choose a card already chosen for Shrouded Lore. Then put the last chosen card into your hand. + this.getSpellAbility().addEffect(new ShroudedLoreEffect()); + this.getSpellAbility().addTarget(new TargetOpponent()); + } + + public ShroudedLore(final ShroudedLore card) { + super(card); + } + + @Override + public ShroudedLore copy() { + return new ShroudedLore(this); + } +} + +class ShroudedLoreEffect extends OneShotEffect { + + public ShroudedLoreEffect() { + super(Outcome.Benefit); + staticText = "Target opponent chooses a card in your graveyard. You may pay {B}. If you do, repeat this process except that opponent can't choose a card already chosen for {this}. Then put the last chosen card into your hand."; + } + + public ShroudedLoreEffect(final ShroudedLoreEffect effect) { + super(effect); + } + + @Override + public ShroudedLoreEffect copy() { + return new ShroudedLoreEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player you = game.getPlayer(source.getControllerId()); + Player opponent = game.getPlayer(targetPointer.getFirst(game, source)); + if(you != null && opponent != null) + { + FilterCard filter = new FilterCard(); + filter.add(new OwnerIdPredicate(you.getId())); + Cost cost = new ManaCostsImpl("{B}"); + TargetCardInGraveyard chosenCard; + Card card = null; + boolean done = false; + do { + chosenCard = new TargetCardInGraveyard(filter); + chosenCard.setNotTarget(true); + if(chosenCard.canChoose(opponent.getId(), game)) { + opponent.chooseTarget(Outcome.ReturnToHand, chosenCard, source, game); + card = game.getCard(chosenCard.getFirstTarget()); + filter.add(Predicates.not(new CardIdPredicate(card.getId()))); + game.informPlayers("Shrouded Lore: " + opponent.getLogName() + " has chosen " + card.getLogName()); + } + else { + done = true; + } + + if(!done) { + if(cost.canPay(source, source.getSourceId(), you.getId(), game) && you.chooseUse(Outcome.Benefit, "Pay {B} to choose a different card ?", source, game)) { + cost.clearPaid(); + if(!cost.pay(source, game, source.getSourceId(), you.getId(), false)) { + done = true; + } + } + else { + done = true; + } + } + + } while(!done); + + if(card != null) { + Cards cardsToHand = new CardsImpl(); + cardsToHand.add(card); + you.moveCards(cardsToHand, Zone.GRAVEYARD, Zone.HAND, source, game); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/Timbermare.java b/Mage.Sets/src/mage/sets/planarchaos/Timbermare.java new file mode 100644 index 00000000000..3a3c321c9b1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/Timbermare.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.TapAllEffect; +import mage.abilities.keyword.EchoAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author LoneFox + */ +public class Timbermare extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("other creatures"); + + static { + filter.add(new AnotherPredicate()); + } + + public Timbermare(UUID ownerId) { + super(ownerId, 140, "Timbermare", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Elemental"); + this.subtype.add("Horse"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Haste + this.addAbility(HasteAbility.getInstance()); + // Echo {5}{G} + this.addAbility(new EchoAbility("{5}{G}")); + // When Timbermare enters the battlefield, tap all other creatures. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapAllEffect(filter))); + } + + public Timbermare(final Timbermare card) { + super(card); + } + + @Override + public Timbermare copy() { + return new Timbermare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/UktabiDrake.java b/Mage.Sets/src/mage/sets/planarchaos/UktabiDrake.java new file mode 100644 index 00000000000..cd638634faf --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/UktabiDrake.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.keyword.EchoAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class UktabiDrake extends CardImpl { + + public UktabiDrake(UUID ownerId) { + super(ownerId, 141, "Uktabi Drake", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Drake"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Haste + this.addAbility(HasteAbility.getInstance()); + // Echo {1}{G}{G} + this.addAbility(new EchoAbility("{1}{G}{G}")); + } + + public UktabiDrake(final UktabiDrake card) { + super(card); + } + + @Override + public UktabiDrake copy() { + return new UktabiDrake(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/UtopiaVow.java b/Mage.Sets/src/mage/sets/planarchaos/UtopiaVow.java new file mode 100644 index 00000000000..6455fdf557b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/UtopiaVow.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.combat.CantAttackBlockAttachedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.mana.AnyColorManaAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class UtopiaVow extends CardImpl { + + public UtopiaVow(UUID ownerId) { + super(ownerId, 142, "Utopia Vow", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature can't attack or block. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackBlockAttachedEffect(AttachmentType.AURA))); + + // Enchanted creature has "{tap}: Add one mana of any color to your mana pool." + Effect effect = new GainAbilityAttachedEffect(new AnyColorManaAbility(), AttachmentType.AURA, Duration.WhileOnBattlefield); + effect.setText("Enchanted creature has \"{T}: Add one mana of any color to your mana pool.\""); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + } + + public UtopiaVow(final UtopiaVow card) { + super(card); + } + + @Override + public UtopiaVow copy() { + return new UtopiaVow(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planarchaos/VoidstoneGargoyle.java b/Mage.Sets/src/mage/sets/planarchaos/VoidstoneGargoyle.java index d222aeb8c4c..76bc947d8e7 100644 --- a/Mage.Sets/src/mage/sets/planarchaos/VoidstoneGargoyle.java +++ b/Mage.Sets/src/mage/sets/planarchaos/VoidstoneGargoyle.java @@ -103,7 +103,7 @@ class VoidstoneGargoyleChooseCardEffect extends OneShotEffect { cardChoice.setChoices(CardRepository.instance.getNonLandNames()); cardChoice.clearChoice(); while (!controller.choose(Outcome.Detriment, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/planarchaos/WaningWurm.java b/Mage.Sets/src/mage/sets/planarchaos/WaningWurm.java new file mode 100644 index 00000000000..7a37457f8dd --- /dev/null +++ b/Mage.Sets/src/mage/sets/planarchaos/WaningWurm.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planarchaos; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.VanishingSacrificeAbility; +import mage.abilities.keyword.VanishingUpkeepAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.counters.CounterType; + +/** + * + * @author LoneFox + */ +public class WaningWurm extends CardImpl { + + public WaningWurm(UUID ownerId) { + super(ownerId, 83, "Waning Wurm", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "PLC"; + this.subtype.add("Zombie"); + this.subtype.add("Wurm"); + this.power = new MageInt(7); + this.toughness = new MageInt(6); + + // Vanishing 2 + Ability ability = new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIME.createInstance(2))); + ability.setRuleVisible(false); + this.addAbility(ability); + this.addAbility(new VanishingUpkeepAbility(2)); + this.addAbility(new VanishingSacrificeAbility()); + } + + public WaningWurm(final WaningWurm card) { + super(card); + } + + @Override + public WaningWurm copy() { + return new WaningWurm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planechase/RumblingSlum.java b/Mage.Sets/src/mage/sets/planechase/RumblingSlum.java new file mode 100644 index 00000000000..1ce5901500a --- /dev/null +++ b/Mage.Sets/src/mage/sets/planechase/RumblingSlum.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planechase; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class RumblingSlum extends mage.sets.guildpact.RumblingSlum { + + public RumblingSlum(UUID ownerId) { + super(ownerId); + this.cardNumber = 93; + this.expansionSetCode = "HOP"; + } + + public RumblingSlum(final RumblingSlum card) { + super(card); + } + + @Override + public RumblingSlum copy() { + return new RumblingSlum(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planechase/VedalkenEngineer.java b/Mage.Sets/src/mage/sets/planechase/VedalkenEngineer.java index e3e2447e1ec..2e3e3d640d6 100644 --- a/Mage.Sets/src/mage/sets/planechase/VedalkenEngineer.java +++ b/Mage.Sets/src/mage/sets/planechase/VedalkenEngineer.java @@ -160,7 +160,7 @@ class VedalkenEngineerEffect extends ManaEffect { Mana mana = new Mana(); ChoiceColor choiceColor = new ChoiceColor(true); while (!controller.choose(Outcome.Benefit, choiceColor, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/planechase2012/BeetlebackChief.java b/Mage.Sets/src/mage/sets/planechase2012/BeetlebackChief.java index f1b2cb90f9d..a4c631a6224 100644 --- a/Mage.Sets/src/mage/sets/planechase2012/BeetlebackChief.java +++ b/Mage.Sets/src/mage/sets/planechase2012/BeetlebackChief.java @@ -28,12 +28,12 @@ package mage.sets.planechase2012; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.permanent.token.GoblinToken; /** @@ -52,7 +52,7 @@ public class BeetlebackChief extends CardImpl { this.toughness = new MageInt(2); // When Beetleback Chief enters the battlefield, put two 1/1 red Goblin creature tokens onto the battlefield. - this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new GoblinToken(expansionSetCode), 2))); + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new GoblinToken(), 2))); } diff --git a/Mage.Sets/src/mage/sets/planechase2012/PrimalPlasma.java b/Mage.Sets/src/mage/sets/planechase2012/PrimalPlasma.java index df5864a7031..4d91881eea1 100644 --- a/Mage.Sets/src/mage/sets/planechase2012/PrimalPlasma.java +++ b/Mage.Sets/src/mage/sets/planechase2012/PrimalPlasma.java @@ -29,13 +29,13 @@ package mage.sets.planechase2012; import java.util.UUID; import mage.MageInt; -import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; import mage.abilities.keyword.DefenderAbility; import mage.abilities.keyword.FlyingAbility; -import mage.cards.Card; import mage.cards.CardImpl; import mage.choices.Choice; import mage.choices.ChoiceImpl; @@ -48,9 +48,6 @@ import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; -import mage.game.permanent.PermanentCard; -import mage.game.permanent.PermanentToken; -import mage.game.permanent.token.Token; import mage.players.Player; /** @@ -123,35 +120,39 @@ class PrimalPlasmaReplacementEffect extends ReplacementEffectImpl { Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { Choice choice = new ChoiceImpl(true); - choice.setMessage("Choose what the creature becomes to"); + choice.setMessage("Choose what " + permanent.getIdName() + " becomes to"); choice.getChoices().add(choice33); choice.getChoices().add(choice22); choice.getChoices().add(choice16); Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - while(!choice.isChosen()) { + while (!choice.isChosen()) { controller.choose(Outcome.Neutral, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } } + int power = 0; + int toughness = 0; switch (choice.getChoice()) { case choice33: - permanent.getPower().setValue(3); - permanent.getToughness().setValue(3); + power = 3; + toughness = 3; break; case choice22: - permanent.getPower().setValue(2); - permanent.getToughness().setValue(2); - permanent.addAbility(FlyingAbility.getInstance(), source.getId(), game); + power = 2; + toughness = 2; + game.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.Custom), source); break; case choice16: - permanent.getPower().setValue(1); - permanent.getToughness().setValue(6); - permanent.addAbility(DefenderAbility.getInstance(), source.getId(), game); + power = 1; + toughness = 6; + game.addEffect(new GainAbilitySourceEffect(DefenderAbility.getInstance(), Duration.Custom), source); break; } + game.addEffect(new SetPowerToughnessSourceEffect(power, toughness, Duration.Custom), source); + } return false; diff --git a/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java b/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java new file mode 100644 index 00000000000..251546109d7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; + +/** + * + * @author LoneFox + */ +public class AuroraGriffin extends CardImpl { + + public AuroraGriffin(UUID ownerId) { + super(ownerId, 2, "Aurora Griffin", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Griffin"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // {W}: Target permanent becomes white until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(ObjectColor.WHITE, + Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addTarget(new TargetPermanent()); + this.addAbility(ability); + } + + public AuroraGriffin(final AuroraGriffin card) { + super(card); + } + + @Override + public AuroraGriffin copy() { + return new AuroraGriffin(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/CloudCover.java b/Mage.Sets/src/mage/sets/planeshift/CloudCover.java new file mode 100644 index 00000000000..c8b82d6a5f2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/CloudCover.java @@ -0,0 +1,106 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author fireshoes + */ +public class CloudCover extends CardImpl { + + public CloudCover(UUID ownerId) { + super(ownerId, 98, "Cloud Cover", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}{U}"); + this.expansionSetCode = "PLS"; + + // Whenever another permanent you control becomes the target of a spell or ability an opponent controls, you may return that permanent to its owner's hand. + this.addAbility(new CloudCoverAbility()); + } + + public CloudCover(final CloudCover card) { + super(card); + } + + @Override + public CloudCover copy() { + return new CloudCover(this); + } +} + +class CloudCoverAbility extends TriggeredAbilityImpl { + + public CloudCoverAbility() { + super(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), true); + } + + public CloudCoverAbility(final CloudCoverAbility ability) { + super(ability); + } + + @Override + public CloudCoverAbility copy() { + return new CloudCoverAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.TARGETED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Permanent permanent = game.getPermanent(event.getTargetId()); + Player controller = game.getPlayer(this.getControllerId()); + Player targetter = game.getPlayer(event.getPlayerId()); + if (permanent != null && !permanent.getId().equals(this.getSourceId()) + && controller != null && targetter != null + && !controller.getId().equals(targetter.getId())) { + getEffects().get(0).setTargetPointer(new FixedTarget(event.getTargetId())); + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever another permanent you control becomes the target of a spell or ability an opponent controls, you may return that permanent to its owner's hand."; + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java b/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java new file mode 100644 index 00000000000..8266d993c30 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.LoseLifeTargetControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class DeathBomb extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("nonblack creature"); + static { + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + + public DeathBomb(UUID ownerId) { + super(ownerId, 41, "Death Bomb", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{B}"); + this.expansionSetCode = "PLS"; + + // As an additional cost to cast Death Bomb, sacrifice a creature. + this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1,1, new FilterControlledCreaturePermanent("a creature"), true))); + // Destroy target nonblack creature. It can't be regenerated. Its controller loses 2 life. + this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); + this.getSpellAbility().addEffect(new LoseLifeTargetControllerEffect(2)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); + } + + public DeathBomb(final DeathBomb card) { + super(card); + } + + @Override + public DeathBomb copy() { + return new DeathBomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/DestructiveFlow.java b/Mage.Sets/src/mage/sets/planeshift/DestructiveFlow.java new file mode 100644 index 00000000000..79dff24deeb --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/DestructiveFlow.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.common.SacrificeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.SupertypePredicate; + +/** + * + * @author LoneFox + */ +public class DestructiveFlow extends CardImpl { + + private static final FilterLandPermanent filter = new FilterLandPermanent("nonbasic land"); + + static { + filter.add(Predicates.not(new SupertypePredicate("Basic"))); + } + + public DestructiveFlow(UUID ownerId) { + super(ownerId, 102, "Destructive Flow", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{B}{R}{G}"); + this.expansionSetCode = "PLS"; + + // At the beginning of each player's upkeep, that player sacrifices a nonbasic land. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeEffect(filter, 1, "that player"), + TargetController.ANY, false)); + + } + + public DestructiveFlow(final DestructiveFlow card) { + super(card); + } + + @Override + public DestructiveFlow copy() { + return new DestructiveFlow(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/Draco.java b/Mage.Sets/src/mage/sets/planeshift/Draco.java new file mode 100644 index 00000000000..4de19ca60f4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/Draco.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; + +/** + * + * @author Simown + */ +public class Draco extends mage.sets.ftvdragons.Draco { + + public Draco(UUID ownerId) { + super(ownerId); + this.cardNumber = 131; + this.expansionSetCode = "PLS"; + } + + public Draco(final Draco card) { + super(card); + } + + @Override + public Draco copy() { + return new Draco(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/DralnusPet.java b/Mage.Sets/src/mage/sets/planeshift/DralnusPet.java new file mode 100644 index 00000000000..11e62798662 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/DralnusPet.java @@ -0,0 +1,132 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.costs.Cost; +import mage.abilities.costs.Costs; +import mage.abilities.costs.CostsImpl; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.EntersBattlefieldEffect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.counters.CounterType; +import mage.filter.common.FilterCreatureCard; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author LoneFox + * @author LevelX + */ +public class DralnusPet extends CardImpl { + + public DralnusPet(UUID ownerId) { + super(ownerId, 23, "Dralnu's Pet", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Shapeshifter"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Kicker-{2}{B}, Discard a creature card. + Costs kickerCosts = new CostsImpl<>(); + kickerCosts.add(new ManaCostsImpl<>("{2}{B}")); + kickerCosts.add(new DiscardCardCost(new FilterCreatureCard())); + this.addAbility(new KickerAbility(kickerCosts)); + // If Dralnu's Pet was kicked, it enters the battlefield with flying and with X +1/+1 counters on it, where X is the discarded card's converted mana cost. + Ability ability = new EntersBattlefieldAbility(new DralnusPetEffect(), KickedCondition.getInstance(), true, + "If {this} was kicked, it enters the battlefield with flying and with X +1/+1 counters on it, where X is the discarded card's converted mana cost", ""); + ability.addEffect(new GainAbilitySourceEffect(FlyingAbility.getInstance(), Duration.WhileOnBattlefield)); + this.addAbility(ability); + } + + public DralnusPet(final DralnusPet card) { + super(card); + } + + @Override + public DralnusPet copy() { + return new DralnusPet(this); + } +} + +class DralnusPetEffect extends OneShotEffect { + + public DralnusPetEffect() { + super(Outcome.BoostCreature); + this.staticText = "and with X +1/+1 counters on it, where X is the discarded card's converted mana cost"; + } + + public DralnusPetEffect(final DralnusPetEffect effect) { + super(effect); + } + + @Override + public DralnusPetEffect copy() { + return new DralnusPetEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (controller != null && permanent != null) { + Object obj = getValue(EntersBattlefieldEffect.SOURCE_CAST_SPELL_ABILITY); + if (obj != null && obj instanceof SpellAbility) { + int cmc = 0; + for (Cost cost : ((SpellAbility) obj).getCosts()) { + if (cost instanceof DiscardCardCost && ((DiscardCardCost) cost).getCards().size() > 0) { + cmc = ((DiscardCardCost) cost).getCards().get(0).getManaCost().convertedManaCost(); + } + if (cmc > 0) { + return new AddCountersSourceEffect(CounterType.P1P1.createInstance(cmc), true).apply(game, source); + } + } + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java b/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java new file mode 100644 index 00000000000..7018891526b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java @@ -0,0 +1,91 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.stack.Spell; +import mage.target.TargetSpell; + +/** + * + * @author LoneFox + */ +public class ErtaisTrickery extends CardImpl { + + public ErtaisTrickery(UUID ownerId) { + super(ownerId, 24, "Ertai's Trickery", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{U}"); + this.expansionSetCode = "PLS"; + + // Counter target spell if it was kicked. + this.getSpellAbility().addEffect(new ErtaisTrickeryEffect()); + this.getSpellAbility().addTarget(new TargetSpell()); + } + + public ErtaisTrickery(final ErtaisTrickery card) { + super(card); + } + + @Override + public ErtaisTrickery copy() { + return new ErtaisTrickery(this); + } +} + +class ErtaisTrickeryEffect extends CounterTargetEffect { + + public ErtaisTrickeryEffect() { + super(); + staticText = "Counter target spell if it was kicked."; + } + + public ErtaisTrickeryEffect(final CounterTargetEffect effect) { + super(effect); + } + + @Override + public ErtaisTrickeryEffect copy() { + return new ErtaisTrickeryEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Spell targetSpell = game.getStack().getSpell(source.getFirstTarget()); + if(targetSpell != null && KickedCondition.getInstance().apply(game, targetSpell.getSpellAbility())) { + return super.apply(game, source); + } + return false; + } + +} diff --git a/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java b/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java new file mode 100644 index 00000000000..e39db8fd8e7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class EscapeRoutes extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white or black creature you control"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.WHITE), new ColorPredicate(ObjectColor.BLACK))); + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public EscapeRoutes(UUID ownerId) { + super(ownerId, 25, "Escape Routes", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "PLS"; + + // {2}{U}: Return target white or black creature you control to its owner's hand. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl("{2}{U}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public EscapeRoutes(final EscapeRoutes card) { + super(card); + } + + @Override + public EscapeRoutes copy() { + return new EscapeRoutes(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java b/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java new file mode 100644 index 00000000000..3b453b32b4d --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.LoseLifeTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; + +/** + * + * @author LoneFox + */ +public class ExoticDisease extends CardImpl { + + public ExoticDisease(UUID ownerId) { + super(ownerId, 43, "Exotic Disease", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{4}{B}"); + this.expansionSetCode = "PLS"; + + // Domain - Target player loses X life and you gain X life, where X is the number of basic land types among lands you control. + DomainValue dv = new DomainValue(); + Effect effect = new LoseLifeTargetEffect(dv); + effect.setText("Domain - Target player loses X life"); + this.getSpellAbility().addEffect(effect); + effect = new GainLifeEffect(dv); + effect.setText("and you gain X life, where X is the number of basic land types among lands you control"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetPlayer()); + } + + public ExoticDisease(final ExoticDisease card) { + super(card); + } + + @Override + public ExoticDisease copy() { + return new ExoticDisease(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/Hobble.java b/Mage.Sets/src/mage/sets/planeshift/Hobble.java new file mode 100644 index 00000000000..ed0b5277512 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/Hobble.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.EnchantedCreatureColorCondition; +import mage.abilities.decorator.ConditionalRestrictionEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.combat.CantAttackAttachedEffect; +import mage.abilities.effects.common.combat.CantBlockAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Hobble extends CardImpl { + + public Hobble(UUID ownerId) { + super(ownerId, 7, "Hobble", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // When Hobble enters the battlefield, draw a card. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1))); + // Enchanted creature can't attack. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackAttachedEffect(AttachmentType.AURA))); + // Enchanted creature can't block if it's black. + Effect effect = new ConditionalRestrictionEffect(new CantBlockAttachedEffect(AttachmentType.AURA), + new EnchantedCreatureColorCondition(ObjectColor.BLACK)); + effect.setText("Enchanted creature can't block if it's black."); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + } + + public Hobble(final Hobble card) { + super(card); + } + + @Override + public Hobble copy() { + return new Hobble(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java b/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java new file mode 100644 index 00000000000..97d924c4c29 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsTargetOpponentControlsCount; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetOpponent; + +/** + * + * @author LoneFox + */ +public class HonorableScout extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("black and/or red creature"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.BLACK), new ColorPredicate(ObjectColor.RED))); + } + + public HonorableScout(UUID ownerId) { + super(ownerId, 8, "Honorable Scout", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.subtype.add("Scout"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // When Honorable Scout enters the battlefield, you gain 2 life for each black and/or red creature target opponent controls. + Ability ability = new EntersBattlefieldTriggeredAbility(new GainLifeEffect(new PermanentsTargetOpponentControlsCount(filter, 2))); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + } + + public HonorableScout(final HonorableScout card) { + super(card); + } + + @Override + public HonorableScout copy() { + return new HonorableScout(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/Insolence.java b/Mage.Sets/src/mage/sets/planeshift/Insolence.java new file mode 100644 index 00000000000..4fdcbf1b6c5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/Insolence.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.target.TargetPermanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; +import mage.abilities.common.BecomesTappedAttachedTriggeredAbility; +import mage.abilities.effects.common.DamageAttachedControllerEffect; + + +/** + * + * @author LoneFox + */ +public class Insolence extends CardImpl { + + public Insolence(UUID ownerId) { + super(ownerId, 63, "Insolence", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Whenever enchanted creature becomes tapped, Insolence deals 2 damage to that creature's controller. + this.addAbility(new BecomesTappedAttachedTriggeredAbility(new DamageAttachedControllerEffect(2), false)); + } + + public Insolence(final Insolence card) { + super(card); + } + + @Override + public Insolence copy() { + return new Insolence(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java b/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java new file mode 100644 index 00000000000..b90364edac5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class KavuRecluse extends CardImpl { + + public KavuRecluse(UUID ownerId) { + super(ownerId, 64, "Kavu Recluse", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {T}: Target land becomes a Forest until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Forest"), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public KavuRecluse(final KavuRecluse card) { + super(card); + } + + @Override + public KavuRecluse copy() { + return new KavuRecluse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/KeldonMantle.java b/Mage.Sets/src/mage/sets/planeshift/KeldonMantle.java new file mode 100644 index 00000000000..5493ff2f2b1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/KeldonMantle.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.RegenerateAttachedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class KeldonMantle extends CardImpl { + + public KeldonMantle(UUID ownerId) { + super(ownerId, 65, "Keldon Mantle", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // {B}: Regenerate enchanted creature. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateAttachedEffect(AttachmentType.AURA), new ManaCostsImpl("{B}"))); + // {R}: Enchanted creature gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), + new ManaCostsImpl("{R}"))); + // {G}: Enchanted creature gains trample until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(TrampleAbility.getInstance(), + AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl("{G}"))); + } + + public KeldonMantle(final KeldonMantle card) { + super(card); + } + + @Override + public KeldonMantle copy() { + return new KeldonMantle(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/MaliciousAdvice.java b/Mage.Sets/src/mage/sets/planeshift/MaliciousAdvice.java new file mode 100644 index 00000000000..a08dc49ceb0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/MaliciousAdvice.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.LoseLifeSourceControllerEffect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.target.TargetPermanent; + +/** + * + * @author LoneFox + */ +public class MaliciousAdvice extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifacts, creatures, and/or lands"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public MaliciousAdvice(UUID ownerId) { + super(ownerId, 114, "Malicious Advice", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{X}{U}{B}"); + this.expansionSetCode = "PLS"; + + // Tap X target artifacts, creatures, and/or lands. You lose X life. + Effect effect = new TapTargetEffect(); + effect.setText("Tap X target artifacts, creatures, and/or lands"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addEffect(new LoseLifeSourceControllerEffect(new ManacostVariableValue())); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if(ability instanceof SpellAbility) { + ability.getTargets().clear(); + ability.addTarget(new TargetPermanent(ability.getManaCostsToPay().getX(), filter)); + } + } + + public MaliciousAdvice(final MaliciousAdvice card) { + super(card); + } + + @Override + public MaliciousAdvice copy() { + return new MaliciousAdvice(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/MarchOfSouls.java b/Mage.Sets/src/mage/sets/planeshift/MarchOfSouls.java index d1d0d83b4ea..dc7495bed21 100644 --- a/Mage.Sets/src/mage/sets/planeshift/MarchOfSouls.java +++ b/Mage.Sets/src/mage/sets/planeshift/MarchOfSouls.java @@ -27,6 +27,7 @@ */ package mage.sets.planeshift; +import java.util.HashMap; import java.util.List; import java.util.UUID; import mage.abilities.Ability; @@ -83,16 +84,24 @@ class MarchOfSoulsEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - List creatures = game.getBattlefield().getActivePermanents(new FilterCreaturePermanent(), - source.getControllerId(), source.getSourceId(), game); - for(Permanent p : creatures) { - UUID controllerId = p.getControllerId(); - if(p.destroy(source.getSourceId(), game, true)) { - SpiritWhiteToken token = new SpiritWhiteToken(); - token.putOntoBattlefield(1, game, source.getSourceId(), controllerId); - } - } - return true; + List creatures = game.getBattlefield().getActivePermanents(new FilterCreaturePermanent(), + source.getControllerId(), source.getSourceId(), game); + HashMap playersWithCreatures = new HashMap(); + for(Permanent p : creatures) { + UUID controllerId = p.getControllerId(); + if(p.destroy(source.getSourceId(), game, true)) { + if(playersWithCreatures.containsKey(controllerId)) { + playersWithCreatures.put(controllerId, playersWithCreatures.get(controllerId) + 1); + } + else { + playersWithCreatures.put(controllerId, 1); + } + } + } + SpiritWhiteToken token = new SpiritWhiteToken(); + for(UUID playerId : playersWithCreatures.keySet()) { + token.putOntoBattlefield(playersWithCreatures.get(playerId), game, source.getSourceId(), playerId); + } + return true; } - } diff --git a/Mage.Sets/src/mage/sets/planeshift/MireKavu.java b/Mage.Sets/src/mage/sets/planeshift/MireKavu.java new file mode 100644 index 00000000000..4833b72e1f8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/MireKavu.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BoostSourceWhileControlsEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class MireKavu extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Swamp"); + + static { + filter.add(new SubtypePredicate("Swamp")); + } + + public MireKavu(UUID ownerId) { + super(ownerId, 67, "Mire Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // Mire Kavu gets +1/+1 as long as you control a Swamp. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceWhileControlsEffect(filter, 1, 1))); + } + + public MireKavu(final MireKavu card) { + super(card); + } + + @Override + public MireKavu copy() { + return new MireKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java b/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java new file mode 100644 index 00000000000..71027519ae0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class PhyrexianBloodstock extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white creature"); + + static { + filter.add(new ColorPredicate(ObjectColor.WHITE)); + } + + public PhyrexianBloodstock(UUID ownerId) { + super(ownerId, 50, "Phyrexian Bloodstock", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{B}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Zombie"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Phyrexian Bloodstock leaves the battlefield, destroy target white creature. It can't be regenerated. + Ability ability = new LeavesBattlefieldTriggeredAbility(new DestroyTargetEffect(true), false); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public PhyrexianBloodstock(final PhyrexianBloodstock card) { + super(card); + } + + @Override + public PhyrexianBloodstock copy() { + return new PhyrexianBloodstock(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/PollenRemedy.java b/Mage.Sets/src/mage/sets/planeshift/PollenRemedy.java index 7e3d7d8b1b7..dd294e5e17c 100644 --- a/Mage.Sets/src/mage/sets/planeshift/PollenRemedy.java +++ b/Mage.Sets/src/mage/sets/planeshift/PollenRemedy.java @@ -41,8 +41,8 @@ import mage.constants.Duration; import mage.constants.Rarity; import mage.filter.common.FilterControlledLandPermanent; import mage.game.Game; -import mage.target.common.TargetCreatureOrPlayerAmount; import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreatureOrPlayerAmount; /** * diff --git a/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java b/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java new file mode 100644 index 00000000000..4cba0900000 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class PygmyKavu extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("black creature your opponents control"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public PygmyKavu(UUID ownerId) { + super(ownerId, 88, "Pygmy Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // When Pygmy Kavu enters the battlefield, draw a card for each black creature your opponents control. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(new PermanentsOnBattlefieldCount(filter)))); + } + + public PygmyKavu(final PygmyKavu card) { + super(card); + } + + @Override + public PygmyKavu copy() { + return new PygmyKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java b/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java new file mode 100644 index 00000000000..bccab7725ad --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.mana.AnyColorOpponentLandsProduceManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class QuirionExplorer extends CardImpl { + + public QuirionExplorer(UUID ownerId) { + super(ownerId, 90, "Quirion Explorer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Elf"); + this.subtype.add("Druid"); + this.subtype.add("Scout"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Add to your mana pool one mana of any color that a land an opponent controls could produce. + this.addAbility(new AnyColorOpponentLandsProduceManaAbility()); + } + + public QuirionExplorer(final QuirionExplorer card) { + super(card); + } + + @Override + public QuirionExplorer copy() { + return new QuirionExplorer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/RadiantKavu.java b/Mage.Sets/src/mage/sets/planeshift/RadiantKavu.java new file mode 100644 index 00000000000..e29f6f24da0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/RadiantKavu.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventAllDamageByAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author LoneFox + */ +public class RadiantKavu extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blue creatures and black creatures"); + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.BLUE), new ColorPredicate(ObjectColor.BLACK))); + } + + public RadiantKavu(UUID ownerId) { + super(ownerId, 120, "Radiant Kavu", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{R}{G}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {R}{G}{W}: Prevent all combat damage blue creatures and black creatures would deal this turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, (new PreventAllDamageByAllEffect(filter, + Duration.EndOfTurn, true)), new ManaCostsImpl("{R}{G}{W}"))); + } + + public RadiantKavu(final RadiantKavu card) { + super(card); + } + + @Override + public RadiantKavu copy() { + return new RadiantKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/RushingRiver.java b/Mage.Sets/src/mage/sets/planeshift/RushingRiver.java index ce6d9e7473d..34b0cee256e 100644 --- a/Mage.Sets/src/mage/sets/planeshift/RushingRiver.java +++ b/Mage.Sets/src/mage/sets/planeshift/RushingRiver.java @@ -1,116 +1,115 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.planeshift; - -import java.util.UUID; -import mage.abilities.Ability; -import mage.abilities.SpellAbility; -import mage.abilities.condition.common.KickedCondition; -import mage.abilities.costs.common.SacrificeTargetCost; -import mage.abilities.decorator.ConditionalOneShotEffect; -import mage.abilities.effects.Effect; -import mage.abilities.effects.common.ReturnToHandTargetEffect; -import mage.abilities.keyword.KickerAbility; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.filter.Filter; -import mage.filter.common.FilterControlledLandPermanent; -import mage.filter.common.FilterNonlandPermanent; -import mage.game.Game; -import mage.target.common.TargetControlledPermanent; -import mage.target.common.TargetNonlandPermanent; -import mage.target.targetpointer.SecondTargetPointer; - -/** - * - * @author LevelX2 - */ -public class RushingRiver extends CardImpl { - - public RushingRiver(UUID ownerId) { - super(ownerId, 30, "Rushing River", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{U}"); - this.expansionSetCode = "PLS"; - - - // Kicker-Sacrifice a land. - this.addAbility(new KickerAbility(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land"))))); - - // Return target nonland permanent to its owner's hand. If Rushing River was kicked, return another target nonland permanent to its owner's hand. - this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); - Effect effect = new ConditionalOneShotEffect( - new ReturnToHandTargetEffect(), - KickedCondition.getInstance(), - "If {this} was kicked, return another target nonland permanent to its owner's hand"); - effect.setTargetPointer(new SecondTargetPointer()); - this.getSpellAbility().addEffect(effect); - this.getSpellAbility().addTarget(new TargetNonlandPermanent()); - - } - - @Override - public void adjustTargets(Ability ability, Game game) { - if (ability instanceof SpellAbility && KickedCondition.getInstance().apply(game, ability)) { - ability.addTarget(new TargetOtherNonlandPermanent(new FilterNonlandPermanent("another target nonland permanent"))); - } - - } - - public RushingRiver(final RushingRiver card) { - super(card); - } - - @Override - public RushingRiver copy() { - return new RushingRiver(this); - } -} - -class TargetOtherNonlandPermanent extends TargetNonlandPermanent { - - public TargetOtherNonlandPermanent(FilterNonlandPermanent filter) { - super(filter); - } - - public TargetOtherNonlandPermanent(final TargetOtherNonlandPermanent target) { - super(target); - } - - @Override - public boolean canTarget(UUID controllerId, UUID id, Ability source, Game game) { - if (source.getTargets().get(0).getTargets().contains(id)) { - return false; - } - return super.canTarget(controllerId, id, source, game); - } - - @Override - public TargetOtherNonlandPermanent copy() { - return new TargetOtherNonlandPermanent(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.SpellAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterNonlandPermanent; +import mage.game.Game; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetNonlandPermanent; +import mage.target.targetpointer.SecondTargetPointer; + +/** + * + * @author LevelX2 + */ +public class RushingRiver extends CardImpl { + + public RushingRiver(UUID ownerId) { + super(ownerId, 30, "Rushing River", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{U}"); + this.expansionSetCode = "PLS"; + + + // Kicker-Sacrifice a land. + this.addAbility(new KickerAbility(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land"))))); + + // Return target nonland permanent to its owner's hand. If Rushing River was kicked, return another target nonland permanent to its owner's hand. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + Effect effect = new ConditionalOneShotEffect( + new ReturnToHandTargetEffect(), + KickedCondition.getInstance(), + "If {this} was kicked, return another target nonland permanent to its owner's hand"); + effect.setTargetPointer(new SecondTargetPointer()); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetNonlandPermanent()); + + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability instanceof SpellAbility && KickedCondition.getInstance().apply(game, ability)) { + ability.addTarget(new TargetOtherNonlandPermanent(new FilterNonlandPermanent("another target nonland permanent"))); + } + + } + + public RushingRiver(final RushingRiver card) { + super(card); + } + + @Override + public RushingRiver copy() { + return new RushingRiver(this); + } +} + +class TargetOtherNonlandPermanent extends TargetNonlandPermanent { + + public TargetOtherNonlandPermanent(FilterNonlandPermanent filter) { + super(filter); + } + + public TargetOtherNonlandPermanent(final TargetOtherNonlandPermanent target) { + super(target); + } + + @Override + public boolean canTarget(UUID controllerId, UUID id, Ability source, Game game) { + if (source.getTargets().get(0).getTargets().contains(id)) { + return false; + } + return super.canTarget(controllerId, id, source, game); + } + + @Override + public TargetOtherNonlandPermanent copy() { + return new TargetOtherNonlandPermanent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SamiteElder.java b/Mage.Sets/src/mage/sets/planeshift/SamiteElder.java new file mode 100644 index 00000000000..50cd28ade0e --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SamiteElder.java @@ -0,0 +1,110 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author LoneFox + */ +public class SamiteElder extends CardImpl { + + public SamiteElder(UUID ownerId) { + super(ownerId, 14, "Samite Elder", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {T}: Creatures you control gain protection from the colors of target permanent you control until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SamiteElderEffect(), new TapSourceCost()); + ability.addTarget(new TargetControlledPermanent()); + this.addAbility(ability); + } + + public SamiteElder(final SamiteElder card) { + super(card); + } + + @Override + public SamiteElder copy() { + return new SamiteElder(this); + } +} + +class SamiteElderEffect extends OneShotEffect { + + public SamiteElderEffect() { + super(Outcome.Protect); + staticText = "Creatures you control gain protection from the colors of target permanent you control until end of turn"; + } + + public SamiteElderEffect(final SamiteElderEffect effect) { + super(effect); + } + + public SamiteElderEffect copy() { + return new SamiteElderEffect(this); + } + + public boolean apply(Game game, Ability source) { + Permanent target = game.getPermanent(source.getFirstTarget()); + if(target != null) { + for(ObjectColor color : target.getColor(game).getColors()) { + FilterCard filter = new FilterCard(color.getDescription()); + filter.add(new ColorPredicate(color)); + game.addEffect(new GainAbilityControlledEffect(new ProtectionAbility(filter), + Duration.EndOfTurn, new FilterControlledCreaturePermanent()), source); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SamitePilgrim.java b/Mage.Sets/src/mage/sets/planeshift/SamitePilgrim.java new file mode 100644 index 00000000000..81ea8fbc8ee --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SamitePilgrim.java @@ -0,0 +1,107 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.PreventionEffectImpl; +import mage.cards.CardImpl; +import mage.constants.*; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author Simown + */ +public class SamitePilgrim extends CardImpl { + + public SamitePilgrim(UUID ownerId) { + super(ownerId, 15, "Samite Pilgrim", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Domain - {T}: Prevent the next X damage that would be dealt to target creature this turn, where X is the number of basic land types among lands you control. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SamitePilgrimPreventDamageToTargetEffect(), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public SamitePilgrim(final SamitePilgrim card) { + super(card); + } + + @Override + public SamitePilgrim copy() { + return new SamitePilgrim(this); + } +} + +class SamitePilgrimPreventDamageToTargetEffect extends PreventionEffectImpl { + + + public SamitePilgrimPreventDamageToTargetEffect() { + super(Duration.EndOfTurn, Integer.MAX_VALUE, false, true); + staticText = "Prevent the next X damage that would be dealt to target creature this turn, where X is the number of basic land types among lands you control."; + } + + public SamitePilgrimPreventDamageToTargetEffect(final SamitePilgrimPreventDamageToTargetEffect effect) { + super(effect); + } + + @Override + public SamitePilgrimPreventDamageToTargetEffect copy() { + return new SamitePilgrimPreventDamageToTargetEffect(this); + } + + @Override + public void init(Ability source, Game game) { + super.init(source, game); + amountToPrevent = new DomainValue().calculate(game, source, this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + return !this.used && super.applies(event, source, game) && event.getTargetId().equals(source.getFirstTarget()); + } + +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java b/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java new file mode 100644 index 00000000000..f6eb16aabcc --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class SeaSnidd extends CardImpl { + + public SeaSnidd(UUID ownerId) { + super(ownerId, 31, "Sea Snidd", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Beast"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {T}: Target land becomes the basic land type of your choice until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public SeaSnidd(final SeaSnidd card) { + super(card); + } + + @Override + public SeaSnidd copy() { + return new SeaSnidd(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java b/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java new file mode 100644 index 00000000000..769e10d3d32 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java @@ -0,0 +1,62 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FearAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ShriekOfDread extends CardImpl { + + public ShriekOfDread(UUID ownerId) { + super(ownerId, 53, "Shriek of Dread", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "PLS"; + + // Target creature gains fear until end of turn. + this.getSpellAbility().addEffect(new GainAbilityTargetEffect(FearAbility.getInstance(), Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public ShriekOfDread(final ShriekOfDread card) { + super(card); + } + + @Override + public ShriekOfDread copy() { + return new ShriekOfDread(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SisaysIngenuity.java b/Mage.Sets/src/mage/sets/planeshift/SisaysIngenuity.java new file mode 100644 index 00000000000..5d3eb5fb336 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SisaysIngenuity.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class SisaysIngenuity extends CardImpl { + + public SisaysIngenuity(UUID ownerId) { + super(ownerId, 33, "Sisay's Ingenuity", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // When Sisay's Ingenuity enters the battlefield, draw a card. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1))); + // Enchanted creature has "{2}{U}: Target creature becomes the color of your choice until end of turn." + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(Duration.EndOfTurn), + new ManaCostsImpl("{2}{U}")); + ability.addTarget(new TargetCreaturePermanent()); + Effect effect = new GainAbilityAttachedEffect(ability, AttachmentType.AURA); + effect.setText("Enchanted creature has \"{2}{U}: Target creature becomes the color of your choice until end of turn.\""); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + } + + public SisaysIngenuity(final SisaysIngenuity card) { + super(card); + } + + @Override + public SisaysIngenuity copy() { + return new SisaysIngenuity(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SkyshipWeatherlight.java b/Mage.Sets/src/mage/sets/planeshift/SkyshipWeatherlight.java index 4342192abcb..22a1c755e1b 100644 --- a/Mage.Sets/src/mage/sets/planeshift/SkyshipWeatherlight.java +++ b/Mage.Sets/src/mage/sets/planeshift/SkyshipWeatherlight.java @@ -34,61 +34,60 @@ import mage.util.CardUtil; * @author nick.myers */ public class SkyshipWeatherlight extends CardImpl { - + public SkyshipWeatherlight(UUID ownerId) { super(ownerId, 133, "Skyship Weatherlight", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{4}"); this.expansionSetCode = "PLS"; this.supertype.add("Legendary"); - + // 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. this.addAbility(new EntersBattlefieldTriggeredAbility(new SkyshipWeatherlightEffect(), false)); - + // {4}, {tap}, Choose a card at random that was removed from the game with Skyship Weatherlight. Put that card into your hand. SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SkyshipWeatherlightEffect2(), new GenericManaCost(4)); ability.addCost(new TapSourceCost()); this.addAbility(ability); } - + public SkyshipWeatherlight(final SkyshipWeatherlight card) { super(card); } - + @Override public SkyshipWeatherlight copy() { return new SkyshipWeatherlight(this); } - + } class SkyshipWeatherlightEffect extends SearchEffect { - + private static final FilterCard filter = new FilterCard("artifact and/or creature card"); - - + static { filter.add(Predicates.or( - new CardTypePredicate(CardType.ARTIFACT), - new CardTypePredicate(CardType.CREATURE))); + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE))); } - + public SkyshipWeatherlightEffect() { - + super(new TargetCardInLibrary(0, Integer.MAX_VALUE, filter), Outcome.Neutral); this.staticText = "search your library for any number of artifact and/or creature cards and remove them from the game. Then shuffle your library"; - + } - + public SkyshipWeatherlightEffect(final SkyshipWeatherlightEffect effect) { super(effect); } - + @Override public SkyshipWeatherlightEffect copy() { return new SkyshipWeatherlightEffect(this); } - + @Override - public boolean apply (Game game, Ability source) { + public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = source.getSourceObject(game); if (sourceObject != null && controller != null) { @@ -108,25 +107,25 @@ class SkyshipWeatherlightEffect extends SearchEffect { } return false; } - + } class SkyshipWeatherlightEffect2 extends OneShotEffect { - + public SkyshipWeatherlightEffect2() { super(Outcome.ReturnToHand); this.staticText = "Choose a card at random that was removed from the game with {this}. Put that card into your hand"; } - + public SkyshipWeatherlightEffect2(final SkyshipWeatherlightEffect2 effect) { super(effect); } - + @Override public SkyshipWeatherlightEffect2 copy() { return new SkyshipWeatherlightEffect2(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); @@ -134,12 +133,11 @@ class SkyshipWeatherlightEffect2 extends OneShotEffect { if (sourceObject != null && controller != null) { ExileZone exZone = game.getExile().getExileZone(CardUtil.getExileZoneId(game, source.getSourceId(), source.getSourceObjectZoneChangeCounter())); if (exZone != null) { - Card card = exZone.getRandom(game); - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.EXILED); + controller.moveCards(exZone.getRandom(game), null, Zone.HAND, source, game); } return true; } return false; } - + } diff --git a/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java b/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java new file mode 100644 index 00000000000..decb8652a7b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author LoneFox + */ +public class SkyshroudBlessing extends CardImpl { + + public SkyshroudBlessing(UUID ownerId) { + super(ownerId, 92, "Skyshroud Blessing", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "PLS"; + + // Lands gain shroud until end of turn. + this.getSpellAbility().addEffect(new GainAbilityAllEffect(ShroudAbility.getInstance(), + Duration.EndOfTurn, new FilterLandPermanent("all lands"))); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public SkyshroudBlessing(final SkyshroudBlessing card) { + super(card); + } + + @Override + public SkyshroudBlessing copy() { + return new SkyshroudBlessing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SleepingPotion.java b/Mage.Sets/src/mage/sets/planeshift/SleepingPotion.java new file mode 100644 index 00000000000..ad0cacc5e64 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SleepingPotion.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BecomesTargetAttachedTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.TapEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class SleepingPotion extends CardImpl { + + public SleepingPotion(UUID ownerId) { + super(ownerId, 34, "Sleeping Potion", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // When Sleeping Potion enters the battlefield, tap enchanted creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapEnchantedEffect())); + // Enchanted creature doesn't untap during its controller's untap step. + Effect effect = new DontUntapInControllersUntapStepEnchantedEffect(); + effect.setText("Enchanted creature doesn't untap during its controller's untap step"); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + // When enchanted creature becomes the target of a spell or ability, sacrifice Sleeping Potion. + this.addAbility(new BecomesTargetAttachedTriggeredAbility(new SacrificeSourceEffect())); + } + + public SleepingPotion(final SleepingPotion card) { + super(card); + } + + @Override + public SleepingPotion copy() { + return new SleepingPotion(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SunkenHope.java b/Mage.Sets/src/mage/sets/planeshift/SunkenHope.java index 4f161888409..9779bb3fb30 100644 --- a/Mage.Sets/src/mage/sets/planeshift/SunkenHope.java +++ b/Mage.Sets/src/mage/sets/planeshift/SunkenHope.java @@ -97,7 +97,7 @@ class ReturnToHandEffect extends OneShotEffect { Target target = new TargetControlledPermanent(1, 1, new FilterControlledCreaturePermanent(), true); if (target.canChoose(player.getId(), game)) { - while (player.isInGame() && !target.isChosen() && target.canChoose(player.getId(), game)) { + while (player.canRespond() && !target.isChosen() && target.canChoose(player.getId(), game)) { player.chooseTarget(Outcome.ReturnToHand, target, source, game); } diff --git a/Mage.Sets/src/mage/sets/planeshift/TahngarthTalruumHero.java b/Mage.Sets/src/mage/sets/planeshift/TahngarthTalruumHero.java new file mode 100644 index 00000000000..876e3724c04 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/TahngarthTalruumHero.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageEachOtherEffect; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class TahngarthTalruumHero extends CardImpl { + + public TahngarthTalruumHero(UUID ownerId) { + super(ownerId, 74, "Tahngarth, Talruum Hero", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{R}{R}"); + this.expansionSetCode = "PLS"; + this.supertype.add("Legendary"); + this.subtype.add("Minotaur"); + this.subtype.add("Warrior"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Vigilance + this.addAbility(VigilanceAbility.getInstance()); + // {1}{R}, {tap}: Tahngarth, Talruum Hero deals damage equal to its power to target creature. That creature deals damage equal to its power to Tahngarth. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEachOtherEffect(), new ManaCostsImpl("{1}{R}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public TahngarthTalruumHero(final TahngarthTalruumHero card) { + super(card); + } + + @Override + public TahngarthTalruumHero copy() { + return new TahngarthTalruumHero(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/VoiceOfAll.java b/Mage.Sets/src/mage/sets/planeshift/VoiceOfAll.java index a82a64c7acd..76fe140548b 100644 --- a/Mage.Sets/src/mage/sets/planeshift/VoiceOfAll.java +++ b/Mage.Sets/src/mage/sets/planeshift/VoiceOfAll.java @@ -29,23 +29,16 @@ package mage.sets.planeshift; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.common.EntersBattlefieldAbility; -import mage.abilities.effects.ContinuousEffect; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.ChooseColorEffect; +import mage.abilities.effects.keyword.ProtectionChosenColorSourceEffect; import mage.abilities.keyword.FlyingAbility; -import mage.abilities.keyword.ProtectionAbility; import mage.cards.CardImpl; -import mage.choices.ChoiceColor; import mage.constants.CardType; -import mage.constants.Duration; import mage.constants.Outcome; import mage.constants.Rarity; -import mage.filter.FilterCard; -import mage.filter.predicate.mageobject.ColorPredicate; -import mage.game.Game; -import mage.players.Player; +import mage.constants.Zone; /** * @@ -62,9 +55,11 @@ public class VoiceOfAll extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); + // As Voice of All enters the battlefield, choose a color. - // Voice of All has protection from the chosen color. - this.addAbility(new EntersBattlefieldAbility(new VoiceOfAllEffect())); + this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Benefit))); + + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ProtectionChosenColorSourceEffect())); } public VoiceOfAll(final VoiceOfAll card) { @@ -75,37 +70,4 @@ public class VoiceOfAll extends CardImpl { public VoiceOfAll copy() { return new VoiceOfAll(this); } -} - -class VoiceOfAllEffect extends OneShotEffect { - - public VoiceOfAllEffect() { - super(Outcome.Protect); - this.staticText = "{this} gains protection from the color of your choice"; - } - - public VoiceOfAllEffect(final VoiceOfAllEffect effect) { - super(effect); - } - - @Override - public VoiceOfAllEffect copy() { - return new VoiceOfAllEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - ChoiceColor choice = new ChoiceColor(); - choice.setMessage("Choose color to get protection from"); - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null && controller.choose(outcome, choice, game)) { - FilterCard protectionFilter = new FilterCard(); - protectionFilter.add(new ColorPredicate(choice.getColor())); - protectionFilter.setMessage(choice.getChoice().toLowerCase()); - ContinuousEffect effect = new GainAbilitySourceEffect(new ProtectionAbility(protectionFilter), Duration.WhileOnBattlefield); - game.addEffect(effect, source); - return true; - } - return false; - } -} +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/planeshift/WarpedDevotion.java b/Mage.Sets/src/mage/sets/planeshift/WarpedDevotion.java new file mode 100644 index 00000000000..776a40c4dce --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/WarpedDevotion.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class WarpedDevotion extends mage.sets.eighthedition.WarpedDevotion { + + public WarpedDevotion(UUID ownerId) { + super(ownerId); + this.cardNumber = 57; + this.expansionSetCode = "PLS"; + this.rarity = Rarity.UNCOMMON; + } + + public WarpedDevotion(final WarpedDevotion card) { + super(card); + } + + @Override + public WarpedDevotion copy() { + return new WarpedDevotion(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/WaterspoutElemental.java b/Mage.Sets/src/mage/sets/planeshift/WaterspoutElemental.java new file mode 100644 index 00000000000..787126a6ccd --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/WaterspoutElemental.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.ReturnToHandFromBattlefieldAllEffect; +import mage.abilities.effects.common.turn.SkipNextTurnSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.KickerAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author LoneFox + */ +public class WaterspoutElemental extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("other creatures"); + + static { + filter.add(new AnotherPredicate()); + } + + public WaterspoutElemental(UUID ownerId) { + super(ownerId, 38, "Waterspout Elemental", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Elemental"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Kicker {U} + this.addAbility(new KickerAbility("{U}")); + // Flying + this.addAbility(FlyingAbility.getInstance()); + // When Waterspout Elemental enters the battlefield, if it was kicked, return all other creatures to their owners' hands and you skip your next turn. + EntersBattlefieldTriggeredAbility ability = new EntersBattlefieldTriggeredAbility(new ReturnToHandFromBattlefieldAllEffect(filter)); + ability.addEffect(new SkipNextTurnSourceEffect()); + this.addAbility(new ConditionalTriggeredAbility(ability, KickedCondition.getInstance(), + "When {this} enters the battlefield, if it was kicked, return all other creatures to their owners' hands and you skip your next turn")); + } + + public WaterspoutElemental(final WaterspoutElemental card) { + super(card); + } + + @Override + public WaterspoutElemental copy() { + return new WaterspoutElemental(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portal/DeepSeaSerpent.java b/Mage.Sets/src/mage/sets/portal/DeepSeaSerpent.java new file mode 100644 index 00000000000..c33ac24a92c --- /dev/null +++ b/Mage.Sets/src/mage/sets/portal/DeepSeaSerpent.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portal; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class DeepSeaSerpent extends CardImpl { + + public DeepSeaSerpent(UUID ownerId) { + super(ownerId, 52, "Deep-Sea Serpent", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{U}{U}"); + this.expansionSetCode = "POR"; + this.subtype.add("Serpent"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Deep-Sea Serpent can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public DeepSeaSerpent(final DeepSeaSerpent card) { + super(card); + } + + @Override + public DeepSeaSerpent copy() { + return new DeepSeaSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portal/PlantElemental.java b/Mage.Sets/src/mage/sets/portal/PlantElemental.java new file mode 100644 index 00000000000..012a1d5cf9a --- /dev/null +++ b/Mage.Sets/src/mage/sets/portal/PlantElemental.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portal; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class PlantElemental extends CardImpl { + + private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("a Forest"); + + static{ + filter.add(new SubtypePredicate("Forest")); + } + + public PlantElemental(UUID ownerId) { + super(ownerId, 107, "Plant Elemental", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "POR"; + this.subtype.add("Plant"); + this.subtype.add("Elemental"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // When Plant Elemental enters the battlefield, sacrifice it unless you sacrifice a Forest. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(filter))))); + } + + public PlantElemental(final PlantElemental card) { + super(card); + } + + @Override + public PlantElemental copy() { + return new PlantElemental(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portal/TheftOfDreams.java b/Mage.Sets/src/mage/sets/portal/TheftOfDreams.java new file mode 100644 index 00000000000..6342c53c2e6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portal/TheftOfDreams.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portal; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class TheftOfDreams extends mage.sets.exodus.TheftOfDreams { + + public TheftOfDreams(UUID ownerId) { + super(ownerId); + this.cardNumber = 73; + this.expansionSetCode = "POR"; + this.rarity = Rarity.UNCOMMON; + } + + public TheftOfDreams(final TheftOfDreams card) { + super(card); + } + + @Override + public TheftOfDreams copy() { + return new TheftOfDreams(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portal/Thundermare.java b/Mage.Sets/src/mage/sets/portal/Thundermare.java new file mode 100644 index 00000000000..51a6fb7b48a --- /dev/null +++ b/Mage.Sets/src/mage/sets/portal/Thundermare.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portal; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.TapAllEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author LoneFox + */ +public class Thundermare extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("other creatures"); + + static { + filter.add(new AnotherPredicate()); + } + + public Thundermare(UUID ownerId) { + super(ownerId, 158, "Thundermare", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{R}"); + this.expansionSetCode = "POR"; + this.subtype.add("Elemental"); + this.subtype.add("Horse"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Haste + this.addAbility(HasteAbility.getInstance()); + // When Thundermare enters the battlefield, tap all other creatures. + this.addAbility(new EntersBattlefieldTriggeredAbility(new TapAllEffect(filter))); + } + + public Thundermare(final Thundermare card) { + super(card); + } + + @Override + public Thundermare copy() { + return new Thundermare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/ArmoredGalleon.java b/Mage.Sets/src/mage/sets/portalsecondage/ArmoredGalleon.java new file mode 100644 index 00000000000..24580763ab4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/ArmoredGalleon.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class ArmoredGalleon extends CardImpl { + + public ArmoredGalleon(UUID ownerId) { + super(ownerId, 33, "Armored Galleon", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "PO2"; + this.subtype.add("Human"); + this.subtype.add("Pirate"); + this.power = new MageInt(5); + this.toughness = new MageInt(4); + + // Armored Galleon can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public ArmoredGalleon(final ArmoredGalleon card) { + super(card); + } + + @Override + public ArmoredGalleon copy() { + return new ArmoredGalleon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/BloodcurdlingScream.java b/Mage.Sets/src/mage/sets/portalsecondage/BloodcurdlingScream.java new file mode 100644 index 00000000000..6bd616fc6a8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/BloodcurdlingScream.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.abilities.dynamicvalue.common.ExileFromHandCostCardConvertedMana; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class BloodcurdlingScream extends CardImpl { + + public BloodcurdlingScream(UUID ownerId) { + super(ownerId, 3, "Bloodcurdling Scream", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{X}{B}"); + this.expansionSetCode = "PO2"; + + // Target creature gets +X/+0 until end of turn. + this.getSpellAbility().addEffect(new BoostTargetEffect(new ExileFromHandCostCardConvertedMana(), new StaticValue(0), Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public BloodcurdlingScream(final BloodcurdlingScream card) { + super(card); + } + + @Override + public BloodcurdlingScream copy() { + return new BloodcurdlingScream(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/FoulSpirit.java b/Mage.Sets/src/mage/sets/portalsecondage/FoulSpirit.java new file mode 100644 index 00000000000..4162ab26c12 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/FoulSpirit.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class FoulSpirit extends mage.sets.masterseditioniv.FoulSpirit { + + public FoulSpirit(UUID ownerId) { + super(ownerId); + this.cardNumber = 13; + this.expansionSetCode = "PO2"; + this.rarity = Rarity.UNCOMMON; + } + + public FoulSpirit(final FoulSpirit card) { + super(card); + } + + @Override + public FoulSpirit copy() { + return new FoulSpirit(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/NorwoodRiders.java b/Mage.Sets/src/mage/sets/portalsecondage/NorwoodRiders.java new file mode 100644 index 00000000000..0fdf6682c23 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/NorwoodRiders.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByMoreThanOneSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class NorwoodRiders extends CardImpl { + + public NorwoodRiders(UUID ownerId) { + super(ownerId, 79, "Norwood Riders", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "PO2"; + this.subtype.add("Elf"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Norwood Riders can't be blocked by more than one creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByMoreThanOneSourceEffect())); + } + + public NorwoodRiders(final NorwoodRiders card) { + super(card); + } + + @Override + public NorwoodRiders copy() { + return new NorwoodRiders(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/ProwlingNightstalker.java b/Mage.Sets/src/mage/sets/portalsecondage/ProwlingNightstalker.java new file mode 100644 index 00000000000..5a641ffa069 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/ProwlingNightstalker.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ProwlingNightstalker extends mage.sets.masterseditioniv.ProwlingNightstalker { + + public ProwlingNightstalker(UUID ownerId) { + super(ownerId); + this.cardNumber = 23; + this.expansionSetCode = "PO2"; + } + + public ProwlingNightstalker(final ProwlingNightstalker card) { + super(card); + } + + @Override + public ProwlingNightstalker copy() { + return new ProwlingNightstalker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/SteamFrigate.java b/Mage.Sets/src/mage/sets/portalsecondage/SteamFrigate.java new file mode 100644 index 00000000000..2d3a736da45 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/SteamFrigate.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class SteamFrigate extends CardImpl { + + public SteamFrigate(UUID ownerId) { + super(ownerId, 47, "Steam Frigate", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "PO2"; + this.subtype.add("Human"); + this.subtype.add("Pirate"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Steam Frigate can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public SteamFrigate(final SteamFrigate card) { + super(card); + } + + @Override + public SteamFrigate copy() { + return new SteamFrigate(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/TheftOfDreams.java b/Mage.Sets/src/mage/sets/portalsecondage/TheftOfDreams.java new file mode 100644 index 00000000000..4035e36a471 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/TheftOfDreams.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class TheftOfDreams extends mage.sets.exodus.TheftOfDreams { + + public TheftOfDreams(UUID ownerId) { + super(ownerId); + this.cardNumber = 55; + this.expansionSetCode = "PO2"; + this.rarity = Rarity.UNCOMMON; + } + + public TheftOfDreams(final TheftOfDreams card) { + super(card); + } + + @Override + public TheftOfDreams copy() { + return new TheftOfDreams(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalsecondage/Undo.java b/Mage.Sets/src/mage/sets/portalsecondage/Undo.java new file mode 100644 index 00000000000..a12965707ff --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalsecondage/Undo.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalsecondage; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Undo extends mage.sets.starter1999.Undo { + + public Undo(UUID ownerId) { + super(ownerId); + this.cardNumber = 59; + this.expansionSetCode = "PO2"; + } + + public Undo(final Undo card) { + super(card); + } + + @Override + public Undo copy() { + return new Undo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/BurningOfXinye.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/BurningOfXinye.java index 4b31451bf46..7ec929aec5b 100644 --- a/Mage.Sets/src/mage/sets/portalthreekingdoms/BurningOfXinye.java +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/BurningOfXinye.java @@ -111,7 +111,7 @@ class BurningOfXinyeEffect extends OneShotEffect{ Target target = new TargetControlledPermanent(amount, amount, filter, true); if (amount > 0 && target.canChoose(source.getSourceId(), player.getId(), game)) { - while (!target.isChosen() && target.canChoose(player.getId(), game) && player.isInGame()) { + while (!target.isChosen() && target.canChoose(player.getId(), game) && player.canRespond()) { player.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/Counterintelligence.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/Counterintelligence.java new file mode 100644 index 00000000000..923bfb50c67 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/Counterintelligence.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Counterintelligence extends CardImpl { + + public Counterintelligence(UUID ownerId) { + super(ownerId, 41, "Counterintelligence", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{U}{U}"); + this.expansionSetCode = "PTK"; + + // Return one or two target creatures to their owners' hands. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(1, 2)); + } + + public Counterintelligence(final Counterintelligence card) { + super(card); + } + + @Override + public Counterintelligence copy() { + return new Counterintelligence(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/Deception.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/Deception.java new file mode 100644 index 00000000000..59fdf2a4bb4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/Deception.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class Deception extends CardImpl { + + public Deception(UUID ownerId) { + super(ownerId, 73, "Deception", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{B}"); + this.expansionSetCode = "PTK"; + + // Target opponent discards two cards. + this.getSpellAbility().addTarget(new TargetOpponent()); + this.getSpellAbility().addEffect(new DiscardTargetEffect(2)); + } + + public Deception(final Deception card) { + super(card); + } + + @Override + public Deception copy() { + return new Deception(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/DongZhouTheTyrant.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/DongZhouTheTyrant.java new file mode 100644 index 00000000000..6fc74eb1296 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/DongZhouTheTyrant.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class DongZhouTheTyrant extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature an opponent controls"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public DongZhouTheTyrant(UUID ownerId) { + super(ownerId, 109, "Dong Zhou, the Tyrant", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{R}"); + this.expansionSetCode = "PTK"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Dong Zhou, the Tyrant enters the battlefield, target creature an opponent controls deals damage equal to its power to that player. + Ability ability = new EntersBattlefieldTriggeredAbility(new DongZhouTheTyrantEffect(), false); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public DongZhouTheTyrant(final DongZhouTheTyrant card) { + super(card); + } + + @Override + public DongZhouTheTyrant copy() { + return new DongZhouTheTyrant(this); + } +} + +class DongZhouTheTyrantEffect extends OneShotEffect { + + public DongZhouTheTyrantEffect() { + super(Outcome.Damage); + staticText = "target creature an opponent controls deals damage equal to its power to that player"; + } + + public DongZhouTheTyrantEffect(final DongZhouTheTyrantEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent creature = game.getPermanent(source.getFirstTarget()); + if (creature != null) { + int amount = creature.getPower().getValue(); + Player controller = game.getPlayer(creature.getControllerId()); + if (controller != null) { + controller.damage(amount, creature.getId(), game, false, true); + return true; + } + } + return false; + } + + @Override + public DongZhouTheTyrantEffect copy() { + return new DongZhouTheTyrantEffect(this); + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/HuangZhongShuGeneral.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/HuangZhongShuGeneral.java new file mode 100644 index 00000000000..5eb6e23db0e --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/HuangZhongShuGeneral.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByMoreThanOneSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class HuangZhongShuGeneral extends CardImpl { + + public HuangZhongShuGeneral(UUID ownerId) { + super(ownerId, 8, "Huang Zhong, Shu General", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}{W}"); + this.expansionSetCode = "PTK"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // Huang Zhong, Shu General can't be blocked by more than one creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByMoreThanOneSourceEffect())); + } + + public HuangZhongShuGeneral(final HuangZhongShuGeneral card) { + super(card); + } + + @Override + public HuangZhongShuGeneral copy() { + return new HuangZhongShuGeneral(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/MengHuoBarbarianKing.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/MengHuoBarbarianKing.java new file mode 100644 index 00000000000..6cc88ddd808 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/MengHuoBarbarianKing.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author fireshoes + */ +public class MengHuoBarbarianKing extends CardImpl { + + private static final FilterCreaturePermanent filterGreen = new FilterCreaturePermanent("green creatures you control"); + + static { + filterGreen.add(new ColorPredicate(ObjectColor.GREEN)); + filterGreen.add(new ControllerPredicate(TargetController.YOU)); + } + + public MengHuoBarbarianKing(UUID ownerId) { + super(ownerId, 142, "Meng Huo, Barbarian King", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); + this.expansionSetCode = "PTK"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Barbarian"); + this.subtype.add("Soldier"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Other green creatures you control get +1/+1. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filterGreen, true))); + } + + public MengHuoBarbarianKing(final MengHuoBarbarianKing card) { + super(card); + } + + @Override + public MengHuoBarbarianKing copy() { + return new MengHuoBarbarianKing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/RedCliffsArmada.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/RedCliffsArmada.java new file mode 100644 index 00000000000..0e96a287aa6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/RedCliffsArmada.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class RedCliffsArmada extends mage.sets.masterseditionii.RedCliffsArmada { + + public RedCliffsArmada(UUID ownerId) { + super(ownerId); + this.cardNumber = 51; + this.expansionSetCode = "PTK"; + this.rarity = Rarity.UNCOMMON; + } + + public RedCliffsArmada(final RedCliffsArmada card) { + super(card); + } + + @Override + public RedCliffsArmada copy() { + return new RedCliffsArmada(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/WuWarship.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/WuWarship.java new file mode 100644 index 00000000000..d73e452ecac --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/WuWarship.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class WuWarship extends mage.sets.masterseditioniii.WuWarship { + + public WuWarship(UUID ownerId) { + super(ownerId); + this.cardNumber = 64; + this.expansionSetCode = "PTK"; + } + + public WuWarship(final WuWarship card) { + super(card); + } + + @Override + public WuWarship copy() { + return new WuWarship(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/YuanShaoTheIndecisive.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/YuanShaoTheIndecisive.java new file mode 100644 index 00000000000..b1870e08954 --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/YuanShaoTheIndecisive.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByMoreThanOneAllEffect; +import mage.abilities.keyword.HorsemanshipAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class YuanShaoTheIndecisive extends CardImpl { + + public YuanShaoTheIndecisive(UUID ownerId) { + super(ownerId, 128, "Yuan Shao, the Indecisive", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{R}"); + this.expansionSetCode = "PTK"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // Horsemanship + this.addAbility(HorsemanshipAbility.getInstance()); + + // Each creature you control can't be blocked by more than one creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByMoreThanOneAllEffect(new FilterControlledCreaturePermanent()))); + } + + public YuanShaoTheIndecisive(final YuanShaoTheIndecisive card) { + super(card); + } + + @Override + public YuanShaoTheIndecisive copy() { + return new YuanShaoTheIndecisive(this); + } +} diff --git a/Mage.Sets/src/mage/sets/portalthreekingdoms/ZhouYuChiefCommander.java b/Mage.Sets/src/mage/sets/portalthreekingdoms/ZhouYuChiefCommander.java new file mode 100644 index 00000000000..5fc93faaccd --- /dev/null +++ b/Mage.Sets/src/mage/sets/portalthreekingdoms/ZhouYuChiefCommander.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.portalthreekingdoms; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class ZhouYuChiefCommander extends CardImpl { + + public ZhouYuChiefCommander(UUID ownerId) { + super(ownerId, 65, "Zhou Yu, Chief Commander", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{U}{U}"); + this.expansionSetCode = "PTK"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(8); + this.toughness = new MageInt(8); + + // Zhou Yu, Chief Commander can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island","an Island")))); + } + + public ZhouYuChiefCommander(final ZhouYuChiefCommander card) { + super(card); + } + + @Override + public ZhouYuChiefCommander copy() { + return new ZhouYuChiefCommander(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prereleaseevents/FungalShambler.java b/Mage.Sets/src/mage/sets/prereleaseevents/FungalShambler.java new file mode 100644 index 00000000000..5bd1f2ef1bd --- /dev/null +++ b/Mage.Sets/src/mage/sets/prereleaseevents/FungalShambler.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prereleaseevents; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class FungalShambler extends mage.sets.apocalypse.FungalShambler { + + public FungalShambler(UUID ownerId) { + super(ownerId); + this.cardNumber = 14; + this.expansionSetCode = "PTC"; + this.rarity = Rarity.SPECIAL; + } + + public FungalShambler(final FungalShambler card) { + super(card); + } + + @Override + public FungalShambler copy() { + return new FungalShambler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prereleaseevents/Gleancrawler.java b/Mage.Sets/src/mage/sets/prereleaseevents/Gleancrawler.java new file mode 100644 index 00000000000..d3deaada3ad --- /dev/null +++ b/Mage.Sets/src/mage/sets/prereleaseevents/Gleancrawler.java @@ -0,0 +1,125 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prereleaseevents; + +import java.util.Set; +import java.util.UUID; +import mage.MageInt; +import mage.MageObjectReference; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.InfoEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; +import mage.watchers.common.CardsPutIntoGraveyardWatcher; + +/** + * + * @author LevelX2 + */ +public class Gleancrawler extends CardImpl { + + public Gleancrawler(UUID ownerId) { + super(ownerId, 27, "Gleancrawler", Rarity.SPECIAL, new CardType[]{CardType.CREATURE}, "{3}{B/G}{B/G}{B/G}"); + this.expansionSetCode = "PTC"; + this.subtype.add("Insect"); + this.subtype.add("Horror"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // ({B/G} can be paid with either {B} or {G}.) + this.addAbility(new SimpleStaticAbility(Zone.ALL, new InfoEffect("({B/G} can be paid with either {B} or {G}.)"))); + // Trample + this.addAbility(TrampleAbility.getInstance()); + // At the beginning of your end step, return to your hand all creature cards in your graveyard that were put there from the battlefield this turn. + this.addAbility(new BeginningOfEndStepTriggeredAbility(new GleancrawlerEffect(), TargetController.YOU, false), new CardsPutIntoGraveyardWatcher()); + + } + + public Gleancrawler(final Gleancrawler card) { + super(card); + } + + @Override + public Gleancrawler copy() { + return new Gleancrawler(this); + } +} + +class GleancrawlerEffect extends OneShotEffect { + + boolean applied = false; + + public GleancrawlerEffect() { + super(Outcome.ReturnToHand); + this.staticText = "return to your hand all creature cards in your graveyard that were put there from the battlefield this turn"; + } + + public GleancrawlerEffect(final GleancrawlerEffect effect) { + super(effect); + } + + @Override + public GleancrawlerEffect copy() { + return new GleancrawlerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + CardsPutIntoGraveyardWatcher watcher = (CardsPutIntoGraveyardWatcher) game.getState().getWatchers().get("CardsPutIntoGraveyardWatcher"); + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null && watcher != null) { + Set cardsToGraveyardThisTurn = watcher.getCardsPutToGraveyardFromBattlefield(); + Cards cardsToHand = new CardsImpl(); + for (MageObjectReference mor : cardsToGraveyardThisTurn) { + if (game.getState().getZoneChangeCounter(mor.getSourceId()) == mor.getZoneChangeCounter()) { + Card card = game.getCard(mor.getSourceId()); + if (card != null && card.getCardType().contains(CardType.CREATURE) + && card.getOwnerId().equals(source.getControllerId())) { + cardsToHand.add(card); + } + } + } + controller.moveCards(cardsToHand, Zone.GRAVEYARD, Zone.HAND, source, game); + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/prereleaseevents/Overtaker.java b/Mage.Sets/src/mage/sets/prereleaseevents/Overtaker.java new file mode 100644 index 00000000000..01ece0181ee --- /dev/null +++ b/Mage.Sets/src/mage/sets/prereleaseevents/Overtaker.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prereleaseevents; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Overtaker extends mage.sets.mercadianmasques.Overtaker { + + public Overtaker(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "PTC"; + this.rarity = Rarity.SPECIAL; + } + + public Overtaker(final Overtaker card) { + super(card); + } + + @Override + public Overtaker copy() { + return new Overtaker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prereleaseevents/SoulCollector.java b/Mage.Sets/src/mage/sets/prereleaseevents/SoulCollector.java new file mode 100644 index 00000000000..62074e34573 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prereleaseevents/SoulCollector.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prereleaseevents; + +import java.util.UUID; + +/** + * + * @author markedagain + */ +public class SoulCollector extends mage.sets.timeshifted.SoulCollector { + + public SoulCollector(UUID ownerId) { + super(ownerId); + this.cardNumber = 20; + this.expansionSetCode = "PTC"; + } + + public SoulCollector(final SoulCollector card) { + super(card); + } + + @Override + public SoulCollector copy() { + return new SoulCollector(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/AuraFracture.java b/Mage.Sets/src/mage/sets/prophecy/AuraFracture.java new file mode 100644 index 00000000000..af058cd709f --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/AuraFracture.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class AuraFracture extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("enchantment"); + + static { + filter.add(new CardTypePredicate(CardType.ENCHANTMENT)); + } + + public AuraFracture(UUID ownerId) { + super(ownerId, 2, "Aura Fracture", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "PCY"; + + // Sacrifice a land: Destroy target enchantment. + Ability ability = new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new DestroyTargetEffect(), + new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("land")))); + ability.addTarget(new TargetPermanent(filter)); + this.addAbility(ability); + } + + public AuraFracture(final AuraFracture card) { + super(card); + } + + @Override + public AuraFracture copy() { + return new AuraFracture(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/BogElemental.java b/Mage.Sets/src/mage/sets/prophecy/BogElemental.java new file mode 100644 index 00000000000..2e7de4e009b --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/BogElemental.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class BogElemental extends CardImpl { + + private static final FilterCard filter = new FilterCard("white"); + + static { + filter.add(new ColorPredicate(ObjectColor.WHITE)); + } + + public BogElemental(UUID ownerId) { + super(ownerId, 57, "Bog Elemental", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{B}{B}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Elemental"); + this.power = new MageInt(5); + this.toughness = new MageInt(4); + + // Protection from white + this.addAbility(new ProtectionAbility(filter)); + + // At the beginning of your upkeep, sacrifice Bog Elemental unless you sacrifice a land. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, + new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent()))), + TargetController.YOU, + false)); + } + + public BogElemental(final BogElemental card) { + super(card); + } + + @Override + public BogElemental copy() { + return new BogElemental(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/Excavation.java b/Mage.Sets/src/mage/sets/prophecy/Excavation.java new file mode 100644 index 00000000000..d3e03bab5b6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/Excavation.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.InfoEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class Excavation extends CardImpl { + + public Excavation(UUID ownerId) { + super(ownerId, 33, "Excavation", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}"); + this.expansionSetCode = "PCY"; + + // {1}, Sacrifice a land: Draw a card. Any player may activate this ability. + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(1), new ManaCostsImpl("{1}")); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land")))); + ability.setMayActivate(TargetController.ANY); + ability.addEffect(new InfoEffect("Any player may activate this ability")); + this.addAbility(ability); + } + + public Excavation(final Excavation card) { + super(card); + } + + @Override + public Excavation copy() { + return new Excavation(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/FaultRiders.java b/Mage.Sets/src/mage/sets/prophecy/FaultRiders.java new file mode 100644 index 00000000000..d493f08ed5f --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/FaultRiders.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.LimitedTimesPerTurnActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class FaultRiders extends CardImpl { + + public FaultRiders(UUID ownerId) { + super(ownerId, 88, "Fault Riders", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Sacrifice a land: Fault Riders gets +2/+0 and gains first strike until end of turn. Activate this ability only once each turn. + Effect effect = new BoostSourceEffect(2,0, Duration.EndOfTurn); + effect.setText("{this} gets +2/+0"); + Ability ability = new LimitedTimesPerTurnActivatedAbility(Zone.BATTLEFIELD, + effect, + new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land")))); + effect = new GainAbilitySourceEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and gains first strike"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public FaultRiders(final FaultRiders card) { + super(card); + } + + @Override + public FaultRiders copy() { + return new FaultRiders(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/Flameshot.java b/Mage.Sets/src/mage/sets/prophecy/Flameshot.java new file mode 100644 index 00000000000..b4ff94e68b9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/Flameshot.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.abilities.costs.AlternativeCostSourceAbility; +import mage.abilities.costs.common.DiscardTargetCost; +import mage.abilities.effects.common.DamageMultiEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetCardInHand; +import mage.target.common.TargetCreaturePermanentAmount; + +/** + * + * @author fireshoes + */ +public class Flameshot extends CardImpl { + + private static final FilterCard filter = new FilterCard("a Mountain card"); + + static { + filter.add(new SubtypePredicate("Mountain")); + } + + public Flameshot(UUID ownerId) { + super(ownerId, 90, "Flameshot", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{3}{R}"); + this.expansionSetCode = "PCY"; + + // You may discard a Mountain card rather than pay Flameshot's mana cost. + this.addAbility(new AlternativeCostSourceAbility(new DiscardTargetCost(new TargetCardInHand(filter)))); + + // Flameshot deals 3 damage divided as you choose among one, two, or three target creatures. + this.getSpellAbility().addEffect(new DamageMultiEffect(3)); + this.getSpellAbility().addTarget(new TargetCreaturePermanentAmount(3)); + } + + public Flameshot(final Flameshot card) { + super(card); + } + + @Override + public Flameshot copy() { + return new Flameshot(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/GulfSquid.java b/Mage.Sets/src/mage/sets/prophecy/GulfSquid.java new file mode 100644 index 00000000000..5ea725b257a --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/GulfSquid.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.TapAllTargetPlayerControlsEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterLandPermanent; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class GulfSquid extends CardImpl { + + public GulfSquid(UUID ownerId) { + super(ownerId, 35, "Gulf Squid", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Squid"); + this.subtype.add("Beast"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // When Gulf Squid enters the battlefield, tap all lands target player controls. + Ability ability = new EntersBattlefieldTriggeredAbility(new TapAllTargetPlayerControlsEffect(new FilterLandPermanent("lands"))); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + } + + public GulfSquid(final GulfSquid card) { + super(card); + } + + @Override + public GulfSquid copy() { + return new GulfSquid(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/JolraelEmpressOfBeasts.java b/Mage.Sets/src/mage/sets/prophecy/JolraelEmpressOfBeasts.java new file mode 100644 index 00000000000..b2c681bde0f --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/JolraelEmpressOfBeasts.java @@ -0,0 +1,125 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.BecomesCreatureAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.other.PlayerIdPredicate; +import mage.game.Game; +import mage.game.permanent.token.Token; +import mage.players.Player; +import mage.target.TargetPlayer; +import mage.target.common.TargetCardInHand; + +/** + * + * @author LevelX2 + */ +public class JolraelEmpressOfBeasts extends CardImpl { + + public JolraelEmpressOfBeasts(UUID ownerId) { + super(ownerId, 115, "Jolrael, Empress of Beasts", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); + this.expansionSetCode = "PCY"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {2}{G}, {tap}, Discard two cards: All lands target player controls become 3/3 creatures until end of turn. They're still lands. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new JolraelEmpressOfBeastsEffect(), new ManaCostsImpl<>("{2}{G}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardTargetCost(new TargetCardInHand(2, new FilterCard("two cards")))); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + } + + public JolraelEmpressOfBeasts(final JolraelEmpressOfBeasts card) { + super(card); + } + + @Override + public JolraelEmpressOfBeasts copy() { + return new JolraelEmpressOfBeasts(this); + } +} + +class JolraelEmpressOfBeastsEffect extends OneShotEffect { + + public JolraelEmpressOfBeastsEffect() { + super(Outcome.Benefit); + this.staticText = "All lands target player controls become 3/3 creatures until end of turn. They're still lands."; + } + + public JolraelEmpressOfBeastsEffect(final JolraelEmpressOfBeastsEffect effect) { + super(effect); + } + + @Override + public JolraelEmpressOfBeastsEffect copy() { + return new JolraelEmpressOfBeastsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player targetPlayer = game.getPlayer(getTargetPointer().getFirst(game, source)); + if (targetPlayer != null) { + FilterPermanent filter = new FilterLandPermanent(); + filter.add(new PlayerIdPredicate(targetPlayer.getId())); + game.addEffect(new BecomesCreatureAllEffect(new JolraelLandsToken(), "lands", filter, Duration.EndOfTurn), source); + return true; + } + return false; + } +} + +class JolraelLandsToken extends Token { + + public JolraelLandsToken() { + super("", "3/3 creature"); + cardType.add(CardType.CREATURE); + power = new MageInt(3); + toughness = new MageInt(3); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/MagetaTheLion.java b/Mage.Sets/src/mage/sets/prophecy/MagetaTheLion.java new file mode 100644 index 00000000000..d8bdc6221f7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/MagetaTheLion.java @@ -0,0 +1,85 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DestroyAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.permanent.AnotherPredicate; +import mage.target.common.TargetCardInHand; + +/** + * + * @author fireshoes + */ +public class MagetaTheLion extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("creatures except for {this}"); + + static { + filter.add(new CardTypePredicate(CardType.CREATURE)); + filter.add(new AnotherPredicate()); + } + + public MagetaTheLion(UUID ownerId) { + super(ownerId, 13, "Mageta the Lion", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{W}{W}"); + this.expansionSetCode = "PCY"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {2}{W}{W}, {tap}, Discard two cards: Destroy all creatures except for Mageta the Lion. Those creatures can't be regenerated. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyAllEffect(filter, true), new ManaCostsImpl("{2}{W}{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardTargetCost(new TargetCardInHand(2,2, new FilterCard("two cards")))); + this.addAbility(ability); + } + + public MagetaTheLion(final MagetaTheLion card) { + super(card); + } + + @Override + public MagetaTheLion copy() { + return new MagetaTheLion(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/MercenaryInformer.java b/Mage.Sets/src/mage/sets/prophecy/MercenaryInformer.java new file mode 100644 index 00000000000..2837baf4cf4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/MercenaryInformer.java @@ -0,0 +1,93 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CantBeTargetedSourceEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.FilterStackObject; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.TokenPredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class MercenaryInformer extends CardImpl { + + private static final FilterStackObject filterBlack = new FilterStackObject("black spells or abilities from black sources"); + private static final FilterPermanent filterMercenary = new FilterPermanent("nontoken Mercenary"); + + static { + filterBlack.add(new ColorPredicate(ObjectColor.BLACK)); + filterMercenary.add(Predicates.not(new TokenPredicate())); + filterMercenary.add(new SubtypePredicate("Mercenary")); + } + + public MercenaryInformer(UUID ownerId) { + super(ownerId, 15, "Mercenary Informer", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Human"); + this.subtype.add("Rebel"); + this.subtype.add("Mercenary"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Mercenary Informer can't be the target of black spells or abilities from black sources. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeTargetedSourceEffect(filterBlack, Duration.WhileOnBattlefield))); + + // {2}{W}: Put target nontoken Mercenary on the bottom of its owner's library. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutOnLibraryTargetEffect(false), new ManaCostsImpl("{2}{W}")); + ability.addTarget(new TargetPermanent(filterMercenary)); + this.addAbility(ability); + } + + public MercenaryInformer(final MercenaryInformer card) { + super(card); + } + + @Override + public MercenaryInformer copy() { + return new MercenaryInformer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/RebelInformer.java b/Mage.Sets/src/mage/sets/prophecy/RebelInformer.java new file mode 100644 index 00000000000..f593ed193a6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/RebelInformer.java @@ -0,0 +1,93 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.CantBeTargetedSourceEffect; +import mage.abilities.effects.common.PutOnLibraryTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.FilterStackObject; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.filter.predicate.permanent.TokenPredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class RebelInformer extends CardImpl { + + private static final FilterStackObject filterWhite = new FilterStackObject("white spells or abilities from white sources"); + private static final FilterPermanent filterRebel = new FilterPermanent("nontoken Rebel"); + + static { + filterWhite.add(new ColorPredicate(ObjectColor.WHITE)); + filterRebel.add(Predicates.not(new TokenPredicate())); + filterRebel.add(new SubtypePredicate("Rebel")); + } + + public RebelInformer(UUID ownerId) { + super(ownerId, 75, "Rebel Informer", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Human"); + this.subtype.add("Mercenary"); + this.subtype.add("Rebel"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // Rebel Informer can't be the target of white spells or abilities from white sources. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeTargetedSourceEffect(filterWhite, Duration.WhileOnBattlefield))); + + // {3}: Put target nontoken Rebel on the bottom of its owner's library. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutOnLibraryTargetEffect(false), new GenericManaCost(3)); + ability.addTarget(new TargetPermanent(filterRebel)); + this.addAbility(ability); + } + + public RebelInformer(final RebelInformer card) { + super(card); + } + + @Override + public RebelInformer copy() { + return new RebelInformer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/StealStrength.java b/Mage.Sets/src/mage/sets/prophecy/StealStrength.java new file mode 100644 index 00000000000..c0dc42b53d9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/StealStrength.java @@ -0,0 +1,99 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class StealStrength extends CardImpl { + + public StealStrength(UUID ownerId) { + super(ownerId, 79, "Steal Strength", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "PCY"; + + // Target creature gets +1/+1 until end of turn. Another target creature gets -1/-1 until end of turn. + this.getSpellAbility().addEffect(new StealStrengthEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(2)); + } + + public StealStrength(final StealStrength card) { + super(card); + } + + @Override + public StealStrength copy() { + return new StealStrength(this); + } +} + +class StealStrengthEffect extends ContinuousEffectImpl { + + public StealStrengthEffect() { + super(Duration.EndOfTurn, Layer.PTChangingEffects_7, SubLayer.ModifyPT_7c, Outcome.BoostCreature); + this.staticText = "Target creature gets +1/+1 until end of turn. Another target creature gets -1/-1 until end of turn"; + } + + public StealStrengthEffect(final StealStrengthEffect effect) { + super(effect); + } + + @Override + public StealStrengthEffect copy() { + return new StealStrengthEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getFirstTarget()); + if (permanent != null) { + permanent.addPower(1); + permanent.addToughness(1); + } + permanent = game.getPermanent(source.getTargets().get(0).getTargets().get(1)); + if (permanent != null) { + permanent.addPower(-1); + permanent.addToughness(-1); + } + return true; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/prophecy/StormwatchEagle.java b/Mage.Sets/src/mage/sets/prophecy/StormwatchEagle.java new file mode 100644 index 00000000000..9134cc353a9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/StormwatchEagle.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class StormwatchEagle extends CardImpl { + + public StormwatchEagle(UUID ownerId) { + super(ownerId, 50, "Stormwatch Eagle", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Bird"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Sacrifice a land: Return Stormwatch Eagle to its owner's hand. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new ReturnToHandSourceEffect(), + new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("a land"))))); + } + + public StormwatchEagle(final StormwatchEagle card) { + super(card); + } + + @Override + public StormwatchEagle copy() { + return new StormwatchEagle(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/TrenchingSteed.java b/Mage.Sets/src/mage/sets/prophecy/TrenchingSteed.java new file mode 100644 index 00000000000..a138473021a --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/TrenchingSteed.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class TrenchingSteed extends CardImpl { + + public TrenchingSteed(UUID ownerId) { + super(ownerId, 26, "Trenching Steed", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Horse"); + this.subtype.add("Rebel"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // Sacrifice a land: Trenching Steed gets +0/+3 until end of turn. + this.addAbility(new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new BoostSourceEffect(0, 3, Duration.EndOfTurn), + new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("land"))))); + } + + public TrenchingSteed(final TrenchingSteed card) { + super(card); + } + + @Override + public TrenchingSteed copy() { + return new TrenchingSteed(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/TroubledHealer.java b/Mage.Sets/src/mage/sets/prophecy/TroubledHealer.java new file mode 100644 index 00000000000..af64eae7561 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/TroubledHealer.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class TroubledHealer extends CardImpl { + + public TroubledHealer(UUID ownerId) { + super(ownerId, 27, "Troubled Healer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // Sacrifice a land: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), + new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent("land")))); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public TroubledHealer(final TroubledHealer card) { + super(card); + } + + @Override + public TroubledHealer copy() { + return new TroubledHealer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/WhipSergeant.java b/Mage.Sets/src/mage/sets/prophecy/WhipSergeant.java new file mode 100644 index 00000000000..60678399313 --- /dev/null +++ b/Mage.Sets/src/mage/sets/prophecy/WhipSergeant.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.prophecy; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class WhipSergeant extends CardImpl { + + public WhipSergeant(UUID ownerId) { + super(ownerId, 107, "Whip Sergeant", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "PCY"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // {R}: Target creature gains haste until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{R}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public WhipSergeant(final WhipSergeant card) { + super(card); + } + + @Override + public WhipSergeant copy() { + return new WhipSergeant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/prophecy/WintermoonMesa.java b/Mage.Sets/src/mage/sets/prophecy/WintermoonMesa.java index 959aa4e37c9..41e285b6b91 100644 --- a/Mage.Sets/src/mage/sets/prophecy/WintermoonMesa.java +++ b/Mage.Sets/src/mage/sets/prophecy/WintermoonMesa.java @@ -31,6 +31,7 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.TapTargetEffect; @@ -58,6 +59,7 @@ public class WintermoonMesa extends CardImpl { // {2}, {tap}, Sacrifice Wintermoon Mesa: Tap two target lands. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new ManaCostsImpl<>("{2}")); ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); ability.addTarget(new TargetLandPermanent(2)); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/ravnica/Blockbuster.java b/Mage.Sets/src/mage/sets/ravnica/Blockbuster.java new file mode 100644 index 00000000000..0a3520ac9b0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/Blockbuster.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.TappedPredicate; + +/** + * + * @author fireshoes + */ +public class Blockbuster extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("tapped creature"); + + static { + filter.add(new TappedPredicate()); + } + + public Blockbuster(UUID ownerId) { + super(ownerId, 115, "Blockbuster", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{R}{R}"); + this.expansionSetCode = "RAV"; + + // {1}{R}, Sacrifice Blockbuster: Blockbuster deals 3 damage to each tapped creature and each player. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEverythingEffect(3, filter), new ManaCostsImpl("{1}{R}"))); + } + + public Blockbuster(final Blockbuster card) { + super(card); + } + + @Override + public Blockbuster copy() { + return new Blockbuster(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/BloodFunnel.java b/Mage.Sets/src/mage/sets/ravnica/BloodFunnel.java new file mode 100644 index 00000000000..54aacd10457 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/BloodFunnel.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SpellCastControllerTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CounterUnlessPaysEffect; +import mage.abilities.effects.common.cost.SpellsCostReductionControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.FilterSpell; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class BloodFunnel extends CardImpl { + + private static final FilterCard filter = new FilterCard("Noncreature spells"); + private static final FilterSpell filterNoncreature = new FilterSpell("a noncreature spell"); + + static { + filter.add(Predicates.not(new CardTypePredicate(CardType.CREATURE))); + filterNoncreature.add(Predicates.not(new CardTypePredicate(CardType.CREATURE))); + } + + public BloodFunnel(UUID ownerId) { + super(ownerId, 77, "Blood Funnel", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}"); + this.expansionSetCode = "RAV"; + + // Noncreature spells you cast cost {2} less to cast. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new SpellsCostReductionControllerEffect(filter, 2))); + + // Whenever you cast a noncreature spell, counter that spell unless you sacrifice a creature. + Effect effect = new CounterUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + effect.setText("counter that spell unless you sacrifice a creature"); + this.addAbility(new SpellCastControllerTriggeredAbility(Zone.BATTLEFIELD, + effect, + filterNoncreature, + false, + true)); + } + + public BloodFunnel(final BloodFunnel card) { + super(card); + } + + @Override + public BloodFunnel copy() { + return new BloodFunnel(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/ravnica/CloudstoneCurio.java b/Mage.Sets/src/mage/sets/ravnica/CloudstoneCurio.java index db7a7afef5e..661f4f5883b 100644 --- a/Mage.Sets/src/mage/sets/ravnica/CloudstoneCurio.java +++ b/Mage.Sets/src/mage/sets/ravnica/CloudstoneCurio.java @@ -57,6 +57,7 @@ import mage.target.TargetPermanent; public class CloudstoneCurio extends CardImpl { private static final FilterPermanent filter = new FilterPermanent("a nonartifact permanent"); + static { filter.add(Predicates.not(new CardTypePredicate(CardType.ARTIFACT))); filter.add(new ControllerPredicate(TargetController.YOU)); @@ -69,7 +70,6 @@ public class CloudstoneCurio extends CardImpl { // Whenever a nonartifact permanent enters the battlefield under your control, you may return another permanent you control that shares a card type with it to its owner's hand. this.addAbility(new EntersBattlefieldAllTriggeredAbility(Zone.BATTLEFIELD, new CloudstoneCurioEffect(), filter, true, SetTargetPointer.PERMANENT, "", true)); - } public CloudstoneCurio(final CloudstoneCurio card) { @@ -120,7 +120,7 @@ class CloudstoneCurioEffect extends OneShotEffect { if (target.canChoose(controller.getId(), game) && controller.chooseTarget(outcome, target, source, game)) { Permanent returningCreature = game.getPermanent(target.getFirstTarget()); if (returningCreature != null) { - controller.moveCardToHandWithInfo(returningCreature, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(returningCreature, null, Zone.HAND, source, game); } } } diff --git a/Mage.Sets/src/mage/sets/ravnica/CongregationAtDawn.java b/Mage.Sets/src/mage/sets/ravnica/CongregationAtDawn.java index c8dca0990b5..6ca8d911a6d 100644 --- a/Mage.Sets/src/mage/sets/ravnica/CongregationAtDawn.java +++ b/Mage.Sets/src/mage/sets/ravnica/CongregationAtDawn.java @@ -107,7 +107,7 @@ class CongregationAtDawnEffect extends OneShotEffect { TargetCard targetToLib = new TargetCard(Zone.PICK, new FilterCard(textTop)); - while (revealed.size() > 1 && controller.isInGame()) { + while (revealed.size() > 1 && controller.canRespond()) { controller.choose(Outcome.Neutral, revealed, targetToLib, game); Card card = revealed.get(targetToLib.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/ravnica/DarkConfidant.java b/Mage.Sets/src/mage/sets/ravnica/DarkConfidant.java index 830ed264fa4..d5c22e87007 100644 --- a/Mage.Sets/src/mage/sets/ravnica/DarkConfidant.java +++ b/Mage.Sets/src/mage/sets/ravnica/DarkConfidant.java @@ -28,10 +28,6 @@ package mage.sets.ravnica; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; @@ -40,8 +36,11 @@ import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.TargetController; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; @@ -76,6 +75,7 @@ public class DarkConfidant extends CardImpl { } class DarkConfidantEffect extends OneShotEffect { + DarkConfidantEffect() { super(Outcome.DrawCard); this.staticText = "reveal the top card of your library and put that card into your hand. You lose life equal to its converted mana cost"; @@ -87,17 +87,16 @@ class DarkConfidantEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); + Player controller = game.getPlayer(source.getControllerId()); Permanent sourcePermanent = game.getPermanentOrLKIBattlefield(source.getSourceId()); - if (player != null && sourcePermanent != null) { - if (player.getLibrary().size() > 0) { - Card card = player.getLibrary().removeFromTop(game); + if (controller != null && sourcePermanent != null) { + if (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().removeFromTop(game); if (card != null) { - Cards cards = new CardsImpl(); - cards.add(card); - player.revealCards(sourcePermanent.getName(), cards, game); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - player.loseLife(card.getManaCost().convertedManaCost(), game); + Cards cards = new CardsImpl(card); + controller.revealCards(sourcePermanent.getIdName(), cards, game); + controller.moveCards(card, null, Zone.HAND, source, game); + controller.loseLife(card.getManaCost().convertedManaCost(), game); } return true; diff --git a/Mage.Sets/src/mage/sets/ravnica/FieryConclusion.java b/Mage.Sets/src/mage/sets/ravnica/FieryConclusion.java index 1414e2b710c..add1b7318bf 100644 --- a/Mage.Sets/src/mage/sets/ravnica/FieryConclusion.java +++ b/Mage.Sets/src/mage/sets/ravnica/FieryConclusion.java @@ -28,11 +28,11 @@ package mage.sets.ravnica; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.costs.common.SacrificeTargetCost; import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetControlledCreaturePermanent; import mage.target.common.TargetCreaturePermanent; @@ -46,7 +46,6 @@ public class FieryConclusion extends CardImpl { super(ownerId, 122, "Fiery Conclusion", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{R}"); this.expansionSetCode = "RAV"; - // As an additional cost to cast Fiery Conclusion, sacrifice a creature. this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); // Fiery Conclusion deals 5 damage to target creature. diff --git a/Mage.Sets/src/mage/sets/ravnica/FiremaneAngel.java b/Mage.Sets/src/mage/sets/ravnica/FiremaneAngel.java index d23339da7fe..91b1bbe4eaf 100644 --- a/Mage.Sets/src/mage/sets/ravnica/FiremaneAngel.java +++ b/Mage.Sets/src/mage/sets/ravnica/FiremaneAngel.java @@ -28,9 +28,6 @@ package mage.sets.ravnica; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; @@ -41,10 +38,12 @@ import mage.abilities.decorator.ConditionalActivatedAbility; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect; -import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.PhaseStep; +import mage.constants.Rarity; import mage.constants.TargetController; import mage.constants.Zone; import mage.game.Game; @@ -70,12 +69,12 @@ public class FiremaneAngel extends CardImpl { // At the beginning of your upkeep, if Firemane Angel is in your graveyard or on the battlefield, you may gain 1 life. Ability ability = new ConditionalTriggeredAbility( new BeginningOfUpkeepTriggeredAbility(Zone.ALL, new GainLifeEffect(1), TargetController.YOU, true), - SourceOnBattelfieldOrGraveyardCondition.getInstance(), - "At the beginning of your upkeep, if {this} is in your graveyard or on the battlefield, you may gain 1 life", true); + SourceOnBattelfieldOrGraveyardCondition.getInstance(), + "At the beginning of your upkeep, if {this} is in your graveyard or on the battlefield, you may gain 1 life"); this.addAbility(ability); // {6}{R}{R}{W}{W}: Return Firemane Angel from your graveyard to the battlefield. Activate this ability only during your upkeep. - this.addAbility(new ConditionalActivatedAbility(Zone.GRAVEYARD, - new ReturnSourceFromGraveyardToBattlefieldEffect(), new ManaCostsImpl("{6}{R}{R}{W}{W}"), new IsStepCondition(PhaseStep.UPKEEP), null)); + this.addAbility(new ConditionalActivatedAbility(Zone.GRAVEYARD, + new ReturnSourceFromGraveyardToBattlefieldEffect(), new ManaCostsImpl("{6}{R}{R}{W}{W}"), new IsStepCondition(PhaseStep.UPKEEP), null)); } public FiremaneAngel(final FiremaneAngel card) { @@ -98,8 +97,8 @@ class SourceOnBattelfieldOrGraveyardCondition implements Condition { @Override public boolean apply(Game game, Ability source) { - return (game.getState().getZone(source.getSourceId()).equals(Zone.GRAVEYARD) || - game.getState().getZone(source.getSourceId()).equals(Zone.BATTLEFIELD)); + return (game.getState().getZone(source.getSourceId()).equals(Zone.GRAVEYARD) + || game.getState().getZone(source.getSourceId()).equals(Zone.BATTLEFIELD)); } @Override @@ -107,5 +106,4 @@ class SourceOnBattelfieldOrGraveyardCondition implements Condition { return "if {this} is in your graveyard or on the battlefield"; } - -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/ravnica/Gleancrawler.java b/Mage.Sets/src/mage/sets/ravnica/Gleancrawler.java new file mode 100644 index 00000000000..fb84aee512e --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/Gleancrawler.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LevelX2 + */ +public class Gleancrawler extends mage.sets.prereleaseevents.Gleancrawler { + + public Gleancrawler(UUID ownerId) { + super(ownerId); + this.cardNumber = 247; + this.expansionSetCode = "RAV"; + this.rarity = Rarity.RARE; + } + + public Gleancrawler(final Gleancrawler card) { + super(card); + } + + @Override + public Gleancrawler copy() { + return new Gleancrawler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/Mindmoil.java b/Mage.Sets/src/mage/sets/ravnica/Mindmoil.java index b45b2478e6b..f0669f79591 100644 --- a/Mage.Sets/src/mage/sets/ravnica/Mindmoil.java +++ b/Mage.Sets/src/mage/sets/ravnica/Mindmoil.java @@ -91,7 +91,7 @@ class MindmoilEffect extends OneShotEffect { cards.add(card.getId()); } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (you.isInGame() && cards.size() > 1) { + while (you.canRespond() && cards.size() > 1) { you.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/ravnica/NecromanticThirst.java b/Mage.Sets/src/mage/sets/ravnica/NecromanticThirst.java new file mode 100644 index 00000000000..b2995b69c61 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/NecromanticThirst.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToAPlayerAttachedTriggeredAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreatureCard; +import mage.target.TargetPermanent; +import mage.target.common.TargetCardInYourGraveyard; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class NecromanticThirst extends CardImpl { + + public NecromanticThirst(UUID ownerId) { + super(ownerId, 97, "Necromantic Thirst", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}{B}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Benefit)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // Whenever enchanted creature deals combat damage to a player, you may return target creature card from your graveyard to your hand. + Ability ability = new DealsDamageToAPlayerAttachedTriggeredAbility( + new ReturnFromGraveyardToHandTargetEffect(), + "enchanted creature", true, false, true, TargetController.ANY); + ability.addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard"))); + this.addAbility(ability); + } + + public NecromanticThirst(final NecromanticThirst card) { + super(card); + } + + @Override + public NecromanticThirst copy() { + return new NecromanticThirst(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/NetherbornPhalanx.java b/Mage.Sets/src/mage/sets/ravnica/NetherbornPhalanx.java new file mode 100644 index 00000000000..8cd4a85155f --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/NetherbornPhalanx.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.TransmuteAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class NetherbornPhalanx extends CardImpl { + + public NetherbornPhalanx(UUID ownerId) { + super(ownerId, 99, "Netherborn Phalanx", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{5}{B}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Horror"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // When Netherborn Phalanx enters the battlefield, each opponent loses 1 life for each creature he or she controls. + Ability ability = new EntersBattlefieldTriggeredAbility(new NetherbornPhalanxEffect()); + this.addAbility(ability); + + // Transmute {1}{B}{B} + this.addAbility(new TransmuteAbility("{1}{B}{B}")); + } + + public NetherbornPhalanx(final NetherbornPhalanx card) { + super(card); + } + + @Override + public NetherbornPhalanx copy() { + return new NetherbornPhalanx(this); + } +} + +class NetherbornPhalanxEffect extends OneShotEffect { + + NetherbornPhalanxEffect() { + super(Outcome.Sacrifice); + this.staticText = "Each opponent loses 1 life for each creature he or she controls"; + } + + NetherbornPhalanxEffect(final NetherbornPhalanxEffect effect) { + super(effect); + } + + @Override + public NetherbornPhalanxEffect copy() { + return new NetherbornPhalanxEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + for (UUID playerId : game.getOpponents(source.getControllerId())) { + final int count = game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), playerId, game).size(); + if (count > 0) { + Player opponent = game.getPlayer(playerId); + if (opponent != null) { + opponent.loseLife(count, game); + return true; + } + } + } + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/ravnica/PerilousForays.java b/Mage.Sets/src/mage/sets/ravnica/PerilousForays.java new file mode 100644 index 00000000000..452c6e1f7af --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/PerilousForays.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetCardInLibrary; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class PerilousForays extends CardImpl { + + private static final FilterLandCard filter = new FilterLandCard("land card with a basic land type"); + + static { + filter.add(Predicates.or( + new SubtypePredicate("Plains"), + new SubtypePredicate("Island"), + new SubtypePredicate("Swamp"), + new SubtypePredicate("Forest"), + new SubtypePredicate("Mountain"))); + } + + public PerilousForays(UUID ownerId) { + super(ownerId, 176, "Perilous Forays", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{3}{G}{G}"); + this.expansionSetCode = "RAV"; + + // {1}, Sacrifice a creature: Search your library for a land card with a basic land type and put it onto the battlefield tapped. Then shuffle your library. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(filter), true, Outcome.PutLandInPlay), + new ManaCostsImpl("{1}")); + ability.addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + this.addAbility(ability); + } + + public PerilousForays(final PerilousForays card) { + super(card); + } + + @Override + public PerilousForays copy() { + return new PerilousForays(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/SistersOfStoneDeath.java b/Mage.Sets/src/mage/sets/ravnica/SistersOfStoneDeath.java index 1c74a4d7b71..200188ec098 100644 --- a/Mage.Sets/src/mage/sets/ravnica/SistersOfStoneDeath.java +++ b/Mage.Sets/src/mage/sets/ravnica/SistersOfStoneDeath.java @@ -59,16 +59,14 @@ import mage.target.common.TargetCreaturePermanent; * @author jeffwadsworth */ public class SistersOfStoneDeath extends CardImpl { - + private UUID exileId = UUID.randomUUID(); - + public SistersOfStoneDeath(UUID ownerId) { super(ownerId, 231, "Sisters of Stone Death", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{B}{B}{G}{G}"); this.expansionSetCode = "RAV"; this.supertype.add("Legendary"); this.subtype.add("Gorgon"); - - this.power = new MageInt(7); this.toughness = new MageInt(5); @@ -79,7 +77,7 @@ public class SistersOfStoneDeath extends CardImpl { this.addAbility(ability); // {B}{G}: Exile target creature blocking or blocked by Sisters of Stone Death. - Ability ability2 = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(exileId, "Sisters Of Stone Death"), new ManaCostsImpl("{B}{G}")); + Ability ability2 = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(exileId, this.getIdName()), new ManaCostsImpl("{B}{G}")); FilterCreaturePermanent filter = new FilterCreaturePermanent("creature blocking or blocked by Sisters of Stone Death"); filter.add(Predicates.or(new BlockedByIdPredicate(this.getId()), new BlockingAttackerIdPredicate(this.getId()))); @@ -88,13 +86,13 @@ public class SistersOfStoneDeath extends CardImpl { // {2}{B}: Put a creature card exiled with Sisters of Stone Death onto the battlefield under your control. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new SistersOfStoneDeathEffect(exileId), new ManaCostsImpl("{2}{B}"))); - + } - + public SistersOfStoneDeath(final SistersOfStoneDeath card) { super(card); } - + @Override public SistersOfStoneDeath copy() { return new SistersOfStoneDeath(this); @@ -102,20 +100,20 @@ public class SistersOfStoneDeath extends CardImpl { } class SistersOfStoneDeathEffect extends OneShotEffect { - + private UUID exileId; - + public SistersOfStoneDeathEffect(UUID exileId) { super(Outcome.PutCreatureInPlay); this.exileId = exileId; staticText = "Put a creature card exiled with {this} onto the battlefield under your control"; } - + public SistersOfStoneDeathEffect(final SistersOfStoneDeathEffect effect) { super(effect); this.exileId = effect.exileId; } - + @Override public boolean apply(Game game, Ability source) { CardsImpl cardsInExile = new CardsImpl(); @@ -137,7 +135,7 @@ class SistersOfStoneDeathEffect extends OneShotEffect { } return false; } - + @Override public SistersOfStoneDeathEffect copy() { return new SistersOfStoneDeathEffect(this); diff --git a/Mage.Sets/src/mage/sets/ravnica/StasisCell.java b/Mage.Sets/src/mage/sets/ravnica/StasisCell.java new file mode 100644 index 00000000000..42ca36d6bbb --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/StasisCell.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DontUntapInControllersUntapStepEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ + +public class StasisCell extends CardImpl { + + public StasisCell(UUID ownerId) { + super(ownerId, 66, "Stasis Cell", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{4}{U}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // Enchanted creature doesn't untap during its controller's untap step. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepEnchantedEffect())); + + // {3}{U}: Attach Stasis Cell to target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AttachEffect(Outcome.Detriment, "Attach {this} to target creature"), new ManaCostsImpl("{3}{U}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public StasisCell(final StasisCell card) { + super(card); + } + + @Override + public StasisCell copy() { + return new StasisCell(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/StoneSeederHierophant.java b/Mage.Sets/src/mage/sets/ravnica/StoneSeederHierophant.java index b6aeee6f40c..8f33f38ad1b 100644 --- a/Mage.Sets/src/mage/sets/ravnica/StoneSeederHierophant.java +++ b/Mage.Sets/src/mage/sets/ravnica/StoneSeederHierophant.java @@ -58,8 +58,8 @@ public class StoneSeederHierophant extends CardImpl { this.toughness = new MageInt(1); // Whenever a land enters the battlefield under your control, untap Stone-Seeder Hierophant. - this.addAbility(new EntersBattlefieldAllTriggeredAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new FilterLandPermanent("a land"), false)); - + this.addAbility(new EntersBattlefieldAllTriggeredAbility(Zone.BATTLEFIELD, new UntapSourceEffect(), new FilterLandPermanent("a land"), false, null, true)); + // {tap}: Untap target land. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new TapSourceCost()); Target target = new TargetLandPermanent(); diff --git a/Mage.Sets/src/mage/sets/ravnica/StoneshakerShaman.java b/Mage.Sets/src/mage/sets/ravnica/StoneshakerShaman.java new file mode 100644 index 00000000000..77579329ae6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/StoneshakerShaman.java @@ -0,0 +1,74 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.effects.common.SacrificeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.permanent.TappedPredicate; + +/** + * + * @author fireshoes + */ +public class StoneshakerShaman extends CardImpl { + + private static final FilterLandPermanent filter = new FilterLandPermanent("untapped land"); + + static { + filter.add(Predicates.not(new TappedPredicate())); + } + + public StoneshakerShaman(UUID ownerId) { + super(ownerId, 145, "Stoneshaker Shaman", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Human"); + this.subtype.add("Shaman"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // At the beginning of each player's end step, that player sacrifices an untapped land. + this.addAbility(new BeginningOfEndStepTriggeredAbility(new SacrificeEffect(filter, 1, "that player "), TargetController.ANY, false)); + } + + public StoneshakerShaman(final StoneshakerShaman card) { + super(card); + } + + @Override + public StoneshakerShaman copy() { + return new StoneshakerShaman(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/SuppressionField.java b/Mage.Sets/src/mage/sets/ravnica/SuppressionField.java index 7c4142711e2..ae8f16d7458 100644 --- a/Mage.Sets/src/mage/sets/ravnica/SuppressionField.java +++ b/Mage.Sets/src/mage/sets/ravnica/SuppressionField.java @@ -29,11 +29,8 @@ package mage.sets.ravnica; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.ActivatedAbility; -import mage.abilities.SpellAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.cost.CostModificationEffectImpl; -import mage.abilities.mana.ManaAbility; import mage.cards.CardImpl; import mage.constants.AbilityType; import mage.constants.CardType; @@ -55,9 +52,8 @@ public class SuppressionField extends CardImpl { super(ownerId, 31, "Suppression Field", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); this.expansionSetCode = "RAV"; - // Activated abilities cost {2} more to activate unless they're mana abilities. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new SuppressionFieldCostReductionEffect() )); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new SuppressionFieldCostReductionEffect())); } public SuppressionField(final SuppressionField card) { @@ -72,7 +68,7 @@ public class SuppressionField extends CardImpl { class SuppressionFieldCostReductionEffect extends CostModificationEffectImpl { - SuppressionFieldCostReductionEffect ( ) { + SuppressionFieldCostReductionEffect() { super(Duration.WhileOnBattlefield, Outcome.Benefit, CostModificationType.INCREASE_COST); staticText = "Activated abilities cost {2} more to activate unless they're mana abilities"; } @@ -89,10 +85,7 @@ class SuppressionFieldCostReductionEffect extends CostModificationEffectImpl { @Override public boolean applies(Ability abilityToModify, Ability source, Game game) { - if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED)) { - return true; - } - return false; + return abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED); } @Override diff --git a/Mage.Sets/src/mage/sets/ravnica/Terraformer.java b/Mage.Sets/src/mage/sets/ravnica/Terraformer.java new file mode 100644 index 00000000000..13e12446010 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/Terraformer.java @@ -0,0 +1,190 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.Set; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.mana.BlackManaAbility; +import mage.abilities.mana.BlueManaAbility; +import mage.abilities.mana.GreenManaAbility; +import mage.abilities.mana.RedManaAbility; +import mage.abilities.mana.WhiteManaAbility; +import mage.cards.CardImpl; +import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterControlledPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author emerald000 + */ +public class Terraformer extends CardImpl { + + public Terraformer(UUID ownerId) { + super(ownerId, 70, "Terraformer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {1}: Choose a basic land type. Each land you control becomes that type until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new TerraformerEffect(), new GenericManaCost(1))); + } + + public Terraformer(final Terraformer card) { + super(card); + } + + @Override + public Terraformer copy() { + return new Terraformer(this); + } +} + +class TerraformerEffect extends OneShotEffect { + + TerraformerEffect() { + super(Outcome.Neutral); + this.staticText = "Choose a basic land type. Each land you control becomes that type until end of turn"; + } + + TerraformerEffect(final TerraformerEffect effect) { + super(effect); + } + + @Override + public TerraformerEffect copy() { + return new TerraformerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + ChoiceImpl choices = new ChoiceImpl(true); + Set choicesSet = choices.getChoices(); + choicesSet.add("Forest"); + choicesSet.add("Plains"); + choicesSet.add("Mountain"); + choicesSet.add("Island"); + choicesSet.add("Swamp"); + if (player.choose(Outcome.Neutral, choices, game)) { + game.getState().setValue(source.getSourceId().toString() + "_Terraformer", choices.getChoice()); + } + game.addEffect(new TerraformerContinuousEffect(), source); + return true; + } + return false; + } +} + +class TerraformerContinuousEffect extends ContinuousEffectImpl { + + private static final FilterControlledPermanent filter = new FilterControlledLandPermanent(); + + TerraformerContinuousEffect() { + super(Duration.EndOfTurn, Outcome.Neutral); + } + + TerraformerContinuousEffect(final TerraformerContinuousEffect effect) { + super(effect); + } + + @Override + public TerraformerContinuousEffect copy() { + return new TerraformerContinuousEffect(this); + } + + @Override + public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { + String choice = (String) game.getState().getValue(source.getSourceId().toString() + "_Terraformer"); + if (choice != null) { + for (Permanent land : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), game)) { + if (land != null) { + switch (layer) { + case TypeChangingEffects_4: + if (sublayer == SubLayer.NA) { + land.getSubtype().clear(); + land.getSubtype().add(choice); + } + break; + case AbilityAddingRemovingEffects_6: + if (sublayer == SubLayer.NA) { + land.getAbilities().clear(); + if (choice.equals("Forest")) { + land.addAbility(new GreenManaAbility(), id, game); + } + if (choice.equals("Plains")) { + land.addAbility(new WhiteManaAbility(), id, game); + } + if (choice.equals("Mountain")) { + land.addAbility(new RedManaAbility(), id, game); + } + if (choice.equals("Island")) { + land.addAbility(new BlueManaAbility(), id, game); + } + if (choice.equals("Swamp")) { + land.addAbility(new BlackManaAbility(), id, game); + } + } + break; + } + } + } + return true; + } + return false; + } + + @Override + public boolean apply(Game game, Ability source) { + return false; + } + + @Override + public boolean hasLayer(Layer layer) { + return layer == Layer.AbilityAddingRemovingEffects_6 || layer == Layer.TypeChangingEffects_4; + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/ThundersongTrumpeter.java b/Mage.Sets/src/mage/sets/ravnica/ThundersongTrumpeter.java index c487030aac2..d252bc818de 100644 --- a/Mage.Sets/src/mage/sets/ravnica/ThundersongTrumpeter.java +++ b/Mage.Sets/src/mage/sets/ravnica/ThundersongTrumpeter.java @@ -32,7 +32,7 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; -import mage.abilities.effects.common.combat.CantBlockTargetEffect; +import mage.abilities.effects.common.combat.CantAttackBlockTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; @@ -54,8 +54,8 @@ public class ThundersongTrumpeter extends CardImpl { this.power = new MageInt(2); this.toughness = new MageInt(1); - // {tap}: Target creature can't attack or block this turn. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantBlockTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + // {T}: Target creature can't attack or block this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CantAttackBlockTargetEffect(Duration.EndOfTurn), new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/ravnica/TidewaterMinion.java b/Mage.Sets/src/mage/sets/ravnica/TidewaterMinion.java new file mode 100644 index 00000000000..7f4c692ce14 --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/TidewaterMinion.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.abilities.effects.common.continuous.LoseAbilitySourceEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class TidewaterMinion extends CardImpl { + + public TidewaterMinion(UUID ownerId) { + super(ownerId, 71, "Tidewater Minion", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{U}{U}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Elemental"); + this.subtype.add("Minion"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // {4}: Tidewater Minion loses defender until end of turn. + this.addAbility(new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new LoseAbilitySourceEffect(DefenderAbility.getInstance(), Duration.EndOfTurn), + new ManaCostsImpl("{4}"))); + + // {tap}: Untap target permanent. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new TapSourceCost()); + ability.addTarget(new TargetPermanent()); + this.addAbility(ability); + } + + public TidewaterMinion(final TidewaterMinion card) { + super(card); + } + + @Override + public TidewaterMinion copy() { + return new TidewaterMinion(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/TorpidMoloch.java b/Mage.Sets/src/mage/sets/ravnica/TorpidMoloch.java new file mode 100644 index 00000000000..fe25ccf895b --- /dev/null +++ b/Mage.Sets/src/mage/sets/ravnica/TorpidMoloch.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.ravnica; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.continuous.LoseAbilitySourceEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class TorpidMoloch extends CardImpl { + + public TorpidMoloch(UUID ownerId) { + super(ownerId, 147, "Torpid Moloch", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "RAV"; + this.subtype.add("Lizard"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // Sacrifice three lands: Torpid Moloch loses defender until end of turn. + this.addAbility(new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new LoseAbilitySourceEffect(DefenderAbility.getInstance(), Duration.EndOfTurn), + new SacrificeTargetCost(new TargetControlledPermanent(3, 3, new FilterControlledLandPermanent("three lands"), true)))); + } + + public TorpidMoloch(final TorpidMoloch card) { + super(card); + } + + @Override + public TorpidMoloch copy() { + return new TorpidMoloch(this); + } +} diff --git a/Mage.Sets/src/mage/sets/ravnica/VindictiveMob.java b/Mage.Sets/src/mage/sets/ravnica/VindictiveMob.java index f2b57af28e7..06d5b1f531a 100644 --- a/Mage.Sets/src/mage/sets/ravnica/VindictiveMob.java +++ b/Mage.Sets/src/mage/sets/ravnica/VindictiveMob.java @@ -30,14 +30,13 @@ package mage.sets.ravnica; import java.util.UUID; import mage.MageInt; import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.SacrificeControllerEffect; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.SubtypePredicate; @@ -52,7 +51,7 @@ public class VindictiveMob extends CardImpl { static { filter.add(new SubtypePredicate("Saproling")); } - + public VindictiveMob(UUID ownerId) { super(ownerId, 112, "Vindictive Mob", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{4}{B}{B}"); this.expansionSetCode = "RAV"; @@ -63,9 +62,9 @@ public class VindictiveMob extends CardImpl { // When Vindictive Mob enters the battlefield, sacrifice a creature. this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterCreaturePermanent(), 1, null))); - + // Vindictive Mob can't be blocked by Saprolings. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public VindictiveMob(final VindictiveMob card) { diff --git a/Mage.Sets/src/mage/sets/returntoravnica/DestroyTheEvidence.java b/Mage.Sets/src/mage/sets/returntoravnica/DestroyTheEvidence.java index 590469bd589..c1a56bc3577 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/DestroyTheEvidence.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/DestroyTheEvidence.java @@ -102,7 +102,7 @@ class DestroyTheEvidenceEffect extends OneShotEffect { boolean landFound = false; Cards cards = new CardsImpl(); while (player.getLibrary().size() > 0 && !landFound) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } Card card = player.getLibrary().removeFromTop(game); diff --git a/Mage.Sets/src/mage/sets/returntoravnica/FaerieImpostor.java b/Mage.Sets/src/mage/sets/returntoravnica/FaerieImpostor.java index 4d786071745..a4f918823d2 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/FaerieImpostor.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/FaerieImpostor.java @@ -28,9 +28,6 @@ package mage.sets.returntoravnica; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; @@ -38,7 +35,9 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterControlledCreaturePermanent; import mage.filter.predicate.permanent.AnotherPredicate; @@ -88,12 +87,12 @@ class FaerieImpostorEffect extends OneShotEffect { filter.add(new AnotherPredicate()); } - FaerieImpostorEffect ( ) { + FaerieImpostorEffect() { super(Outcome.ReturnToHand); staticText = effectText; } - FaerieImpostorEffect ( FaerieImpostorEffect effect ) { + FaerieImpostorEffect(FaerieImpostorEffect effect) { super(effect); } @@ -108,13 +107,13 @@ class FaerieImpostorEffect extends OneShotEffect { controller.choose(Outcome.ReturnToHand, target, source.getSourceId(), game); Permanent permanent = game.getPermanent(target.getFirstTarget()); - if ( permanent != null ) { + if (permanent != null) { targetChosen = true; - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(permanent, null, Zone.HAND, source, game); } } - if ( !targetChosen ) { + if (!targetChosen) { new SacrificeSourceEffect().apply(game, source); } return true; diff --git a/Mage.Sets/src/mage/sets/returntoravnica/GraveBetrayal.java b/Mage.Sets/src/mage/sets/returntoravnica/GraveBetrayal.java index d28418b9095..dab0ee466f1 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/GraveBetrayal.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/GraveBetrayal.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.returntoravnica; import java.util.UUID; @@ -58,21 +57,19 @@ import mage.target.targetpointer.FixedTarget; * * @author LevelX2 */ - public class GraveBetrayal extends CardImpl { - public GraveBetrayal (UUID ownerId) { + public GraveBetrayal(UUID ownerId) { super(ownerId, 67, "Grave Betrayal", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{5}{B}{B}"); this.expansionSetCode = "RTR"; - // Whenever a creature you don't control dies, return it to the battlefield under // your control with an additional +1/+1 counter on it at the beginning of the // next end step. That creature is a black Zombie in addition to its other colors and types. this.addAbility(new GraveBetrayalTriggeredAbility()); } - public GraveBetrayal (final GraveBetrayal card) { + public GraveBetrayal(final GraveBetrayal card) { super(card); } @@ -108,13 +105,10 @@ class GraveBetrayalTriggeredAbility extends TriggeredAbilityImpl { && ((ZoneChangeEvent) event).getFromZone() == Zone.BATTLEFIELD) { Permanent permanent = (Permanent) game.getLastKnownInformation(event.getTargetId(), Zone.BATTLEFIELD); if (permanent != null && !permanent.getControllerId().equals(this.getControllerId()) && permanent.getCardType().contains(CardType.CREATURE)) { - Card card = (Card)game.getObject(permanent.getId()); + Card card = (Card) game.getObject(permanent.getId()); if (card != null) { Effect effect = new GraveBetrayalEffect(); - effect.setTargetPointer(new FixedTarget(card.getId())); - Integer zoneChanges = card.getZoneChangeCounter(game); - effect.setValue("zoneChanges", zoneChanges); - + effect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(effect); delayedAbility.setSourceId(this.getSourceId()); delayedAbility.setControllerId(this.getControllerId()); @@ -153,17 +147,14 @@ class GraveBetrayalEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Card card = game.getCard(targetPointer.getFirst(game, source)); if (card != null) { - Integer zoneChanges = (Integer) getValue("zoneChanges"); - if (card.getZoneChangeCounter(game) == zoneChanges) { - Zone currentZone = game.getState().getZone(card.getId()); - if (card.putOntoBattlefield(game, currentZone, source.getSourceId(), source.getControllerId())) { - Permanent creature = game.getPermanent(card.getId()); - creature.addCounters(CounterType.P1P1.createInstance(), game); - ContinuousEffect effect = new GraveBetrayalContiniousEffect(); - effect.setTargetPointer(new FixedTarget(creature.getId())); - game.addEffect(effect, source); - return true; - } + Zone currentZone = game.getState().getZone(card.getId()); + if (card.putOntoBattlefield(game, currentZone, source.getSourceId(), source.getControllerId())) { + Permanent creature = game.getPermanent(card.getId()); + creature.addCounters(CounterType.P1P1.createInstance(), game); + ContinuousEffect effect = new GraveBetrayalContiniousEffect(); + effect.setTargetPointer(new FixedTarget(creature.getId())); + game.addEffect(effect, source); + return true; } } return false; @@ -220,4 +211,4 @@ class GraveBetrayalContiniousEffect extends ContinuousEffectImpl { return layer == Layer.ColorChangingEffects_5 || layer == Layer.TypeChangingEffects_4; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/returntoravnica/JaceArchitectOfThought.java b/Mage.Sets/src/mage/sets/returntoravnica/JaceArchitectOfThought.java index fa1d8f6e552..93753306a08 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/JaceArchitectOfThought.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/JaceArchitectOfThought.java @@ -258,12 +258,12 @@ class JaceArchitectOfThoughtEffect2 extends OneShotEffect { for (UUID cardUuid : cardsToHand) { Card card = cardsToHand.get(cardUuid, game); if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + player.moveCards(card, null, Zone.HAND, source, game); } } TargetCard targetCard = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cardsToLibrary.size() > 1) { + while (player.canRespond() && cardsToLibrary.size() > 1) { player.choose(Outcome.Neutral, cardsToLibrary, targetCard, game); Card card = cardsToLibrary.get(targetCard.getFirstTarget(), game); if (card != null) { @@ -342,14 +342,12 @@ class JaceArchitectOfThoughtEffect3 extends OneShotEffect { while (jaceExileZone.count(filter, game) > 0 && controller.choose(Outcome.PlayForFree, jaceExileZone, target, game)) { Card card = game.getCard(target.getFirstTarget()); if (card != null) { - if (controller.cast(card.getSpellAbility(), game, true)) { game.getExile().removeCard(card, game); } } target.clearChosen(); } - return true; } } diff --git a/Mage.Sets/src/mage/sets/returntoravnica/LoxodonSmiter.java b/Mage.Sets/src/mage/sets/returntoravnica/LoxodonSmiter.java index 3ec4636e9c7..e127fad6560 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/LoxodonSmiter.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/LoxodonSmiter.java @@ -32,19 +32,12 @@ import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.CantBeCounteredAbility; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.ReplacementEffectImpl; -import mage.cards.Card; +import mage.abilities.effects.common.DiscardOntoBattlefieldEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.ZoneChangeEvent; -import mage.game.stack.StackObject; -import mage.players.Player; /** * @@ -67,7 +60,7 @@ public class LoxodonSmiter extends CardImpl { this.addAbility(new CantBeCounteredAbility()); // If a spell or ability an opponent controls causes you to discard Loxodon Smiter, put it onto the battlefield instead of putting it into your graveyard. - this.addAbility(new SimpleStaticAbility(Zone.HAND, new LoxodonSmiterEffect())); + this.addAbility(new SimpleStaticAbility(Zone.HAND, new DiscardOntoBattlefieldEffect())); } public LoxodonSmiter(final LoxodonSmiter card) { @@ -79,59 +72,3 @@ public class LoxodonSmiter extends CardImpl { return new LoxodonSmiter(this); } } - -class LoxodonSmiterEffect extends ReplacementEffectImpl { - - public LoxodonSmiterEffect() { - super(Duration.EndOfGame, Outcome.PutCardInPlay); - staticText = "If a spell or ability an opponent controls causes you to discard {this}, put it onto the battlefield instead of putting it into your graveyard"; - } - - public LoxodonSmiterEffect(final LoxodonSmiterEffect effect) { - super(effect); - } - - @Override - public LoxodonSmiterEffect copy() { - return new LoxodonSmiterEffect(this); - } - - @Override - public boolean checksEventType(GameEvent event, Game game) { - return event.getType() == GameEvent.EventType.ZONE_CHANGE; - } - - @Override - public boolean applies(GameEvent event, Ability source, Game game) { - if (event.getTargetId().equals(source.getSourceId())) { - ZoneChangeEvent zcEvent = (ZoneChangeEvent) event; - if (zcEvent.getFromZone() == Zone.HAND && zcEvent.getToZone() == Zone.GRAVEYARD) { - StackObject spell = game.getStack().getStackObject(event.getSourceId()); - if (spell != null && game.getOpponents(source.getControllerId()).contains(spell.getControllerId())) { - return true; - } - } - } - return false; - } - - @Override - public boolean apply(Game game, Ability source) { - Card card = game.getCard(source.getSourceId()); - if (card != null) { - Player player = game.getPlayer(card.getOwnerId()); - if (player != null) { - if (card.putOntoBattlefield(game, Zone.HAND, source.getSourceId(), player.getId())) { - return true; - } - } - } - return false; - } - - @Override - public boolean replaceEvent(GameEvent event, Ability source, Game game) { - return apply(game, source); - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/returntoravnica/PackRat.java b/Mage.Sets/src/mage/sets/returntoravnica/PackRat.java index 451cc8df37c..266521195b0 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/PackRat.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/PackRat.java @@ -29,6 +29,7 @@ package mage.sets.returntoravnica; import java.util.UUID; +import mage.abilities.effects.CopyCardEffect; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; @@ -39,18 +40,11 @@ import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.DiscardCardCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; -import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.Duration; -import mage.constants.Outcome; import mage.filter.common.FilterControlledPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.game.permanent.token.EmptyToken; -import mage.util.CardUtil; /** * @@ -89,7 +83,7 @@ public class PackRat extends CardImpl { // Pack Rat's power and toughness are each equal to the number of Rats you control. this.addAbility(new SimpleStaticAbility(Zone.ALL, new SetPowerToughnessSourceEffect(new PermanentsOnBattlefieldCount(filter), Duration.EndOfGame))); // {2}{B}, Discard a card: Put a token onto the battlefield that's a copy of Pack Rat. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PackRatEffect(this), new ManaCostsImpl("{2}{B}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CopyCardEffect(this, 1), new ManaCostsImpl("{2}{B}")); ability.addCost(new DiscardCardCost()); this.addAbility(ability); } @@ -104,37 +98,3 @@ public class PackRat extends CardImpl { } } -class PackRatEffect extends OneShotEffect { - - private Card card; - - public PackRatEffect(Card card) { - super(Outcome.PutCreatureInPlay); - this.card = card; - staticText = "Put a token onto the battlefield that's a copy of {this}"; - } - - public PackRatEffect(final PackRatEffect effect) { - super(effect); - this.card = effect.card; - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent == null) { - permanent = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD); - } - if (permanent != null) { - EmptyToken newToken = new EmptyToken(); - CardUtil.copyTo(newToken).from(permanent); - return newToken.putOntoBattlefield(1, game, source.getSourceId(), source.getControllerId()); - } - return false; - } - - @Override - public PackRatEffect copy() { - return new PackRatEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/returntoravnica/SlaughterGames.java b/Mage.Sets/src/mage/sets/returntoravnica/SlaughterGames.java index f8fc51cc664..4a9b31a1afe 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/SlaughterGames.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/SlaughterGames.java @@ -101,7 +101,7 @@ class SlaughterGamesEffect extends SearchTargetGraveyardHandLibraryForCardNameAn cardChoice.setMessage("Name a nonland card"); while (!controller.choose(Outcome.Exile, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/returntoravnica/TabletOfTheGuilds.java b/Mage.Sets/src/mage/sets/returntoravnica/TabletOfTheGuilds.java index b844e1a25c7..ffe0df331bd 100644 --- a/Mage.Sets/src/mage/sets/returntoravnica/TabletOfTheGuilds.java +++ b/Mage.Sets/src/mage/sets/returntoravnica/TabletOfTheGuilds.java @@ -92,7 +92,7 @@ class TabletOfTheGuildsEntersBattlefieldEffect extends OneShotEffect { ChoiceColor colorChoice = new ChoiceColor(); colorChoice.setMessage("Choose the first color"); while (!player.choose(Outcome.GainLife, colorChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } @@ -101,7 +101,7 @@ class TabletOfTheGuildsEntersBattlefieldEffect extends OneShotEffect { colorChoice.getChoices().remove(colorChoice.getChoice()); colorChoice.setMessage("Choose the second color"); - while (!player.choose(Outcome.GainLife, colorChoice, game) && player.isInGame()) { + while (!player.choose(Outcome.GainLife, colorChoice, game) && player.canRespond()) { game.debugMessage("player canceled choosing type. retrying."); } game.getState().setValue(permanent.getId() + "_color2", colorChoice.getColor().toString()); diff --git a/Mage.Sets/src/mage/sets/revisededition/Channel.java b/Mage.Sets/src/mage/sets/revisededition/Channel.java new file mode 100644 index 00000000000..0eb11c09a12 --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/Channel.java @@ -0,0 +1,145 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; +import mage.Mana; +import mage.abilities.Ability; +import mage.abilities.DelayedTriggeredAbility; +import mage.abilities.SpecialAction; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.BasicManaEffect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.CreateSpecialActionEffect; +import mage.abilities.effects.common.RemoveSpecialActionEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; + +/** + * + * @author emerald000 + */ +public class Channel extends CardImpl { + + public Channel(UUID ownerId) { + super(ownerId, 95, "Channel", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{G}{G}"); + this.expansionSetCode = "3ED"; + + // Until end of turn, any time you could activate a mana ability, you may pay 1 life. If you do, add {1} to your mana pool. + this.getSpellAbility().addEffect(new ChannelEffect()); + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} + +class ChannelEffect extends OneShotEffect { + + ChannelEffect() { + super(Outcome.PutManaInPool); + this.staticText = "Until end of turn, any time you could activate a mana ability, you may pay 1 life. If you do, add {1} to your mana pool"; + } + + ChannelEffect(final ChannelEffect effect) { + super(effect); + } + + @Override + public ChannelEffect copy() { + return new ChannelEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + SpecialAction specialAction = new ChannelSpecialAction(); + new CreateSpecialActionEffect(specialAction).apply(game, source); + + // Create a hidden delayed triggered ability to remove the special action at end of turn. + new CreateDelayedTriggeredAbilityEffect(new ChannelDelayedTriggeredAbility(specialAction.getId()), false).apply(game, source); + return true; + } +} + +class ChannelSpecialAction extends SpecialAction { + + ChannelSpecialAction() { + super(); + this.addCost(new PayLifeCost(1)); + this.addEffect(new BasicManaEffect(Mana.ColorlessMana)); + } + + ChannelSpecialAction(final ChannelSpecialAction ability) { + super(ability); + } + + @Override + public ChannelSpecialAction copy() { + return new ChannelSpecialAction(this); + } +} + +class ChannelDelayedTriggeredAbility extends DelayedTriggeredAbility { + + ChannelDelayedTriggeredAbility(UUID specialActionId) { + super(new RemoveSpecialActionEffect(specialActionId), Duration.OneUse); + this.usesStack = false; + this.setRuleVisible(false); + } + + ChannelDelayedTriggeredAbility(ChannelDelayedTriggeredAbility ability) { + super(ability); + } + + @Override + public ChannelDelayedTriggeredAbility copy() { + return new ChannelDelayedTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.CLEANUP_STEP_PRE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/Crumble.java b/Mage.Sets/src/mage/sets/revisededition/Crumble.java new file mode 100644 index 00000000000..9e5ba1fb290 --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/Crumble.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Crumble extends mage.sets.masterseditioniv.Crumble { + + public Crumble(UUID ownerId) { + super(ownerId); + this.cardNumber = 98; + this.expansionSetCode = "3ED"; + this.rarity = Rarity.UNCOMMON; + } + + public Crumble(final Crumble card) { + super(card); + } + + @Override + public Crumble copy() { + return new Crumble(this); + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/Deathgrip.java b/Mage.Sets/src/mage/sets/revisededition/Deathgrip.java new file mode 100644 index 00000000000..220647d3079 --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/Deathgrip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "3ED"; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/ElHajjaj.java b/Mage.Sets/src/mage/sets/revisededition/ElHajjaj.java new file mode 100644 index 00000000000..ea0b5826aa5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/ElHajjaj.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ElHajjaj extends mage.sets.arabiannights.ElHajjaj { + + public ElHajjaj(UUID ownerId) { + super(ownerId); + this.cardNumber = 16; + this.expansionSetCode = "3ED"; + } + + public ElHajjaj(final ElHajjaj card) { + super(card); + } + + @Override + public ElHajjaj copy() { + return new ElHajjaj(this); + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/IslandFishJasconius.java b/Mage.Sets/src/mage/sets/revisededition/IslandFishJasconius.java new file mode 100644 index 00000000000..a3174bbcb7a --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/IslandFishJasconius.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class IslandFishJasconius extends mage.sets.fourthedition.IslandFishJasconius { + + public IslandFishJasconius(UUID ownerId) { + super(ownerId); + this.cardNumber = 61; + this.expansionSetCode = "3ED"; + } + + public IslandFishJasconius(final IslandFishJasconius card) { + super(card); + } + + @Override + public IslandFishJasconius copy() { + return new IslandFishJasconius(this); + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/IslandSanctuary.java b/Mage.Sets/src/mage/sets/revisededition/IslandSanctuary.java new file mode 100644 index 00000000000..a7e0b44651a --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 209; + this.expansionSetCode = "3ED"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/revisededition/Reconstruction.java b/Mage.Sets/src/mage/sets/revisededition/Reconstruction.java new file mode 100644 index 00000000000..4f26241469e --- /dev/null +++ b/Mage.Sets/src/mage/sets/revisededition/Reconstruction.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.revisededition; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class Reconstruction extends mage.sets.antiquities.Reconstruction { + + public Reconstruction(UUID ownerId) { + super(ownerId); + this.cardNumber = 77; + this.expansionSetCode = "3ED"; + } + + public Reconstruction(final Reconstruction card) { + super(card); + } + + @Override + public Reconstruction copy() { + return new Reconstruction(this); + } +} diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/DemonicAppetite.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/DemonicAppetite.java index d467a009fb5..efaaf2c58a8 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/DemonicAppetite.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/DemonicAppetite.java @@ -25,20 +25,25 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.riseoftheeldrazi; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.abilities.effects.common.SacrificeTargetEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; import mage.target.TargetPermanent; import mage.target.common.TargetControlledCreaturePermanent; @@ -48,29 +53,27 @@ import mage.target.common.TargetControlledCreaturePermanent; */ public class DemonicAppetite extends CardImpl { - public DemonicAppetite (UUID ownerId) { + public DemonicAppetite(UUID ownerId) { super(ownerId, 106, "Demonic Appetite", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{B}"); this.expansionSetCode = "ROE"; this.subtype.add("Aura"); - + // Enchant creature you control TargetPermanent auraTarget = new TargetControlledCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); - Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); + + // Enchanted creature gets +3/+3. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 3, Duration.WhileOnBattlefield))); - ability = new BeginningOfUpkeepTriggeredAbility( - new DemonicAppetiteEffect(), - TargetController.YOU, - false); - ability.addTarget(new TargetControlledCreaturePermanent()); - this.addAbility(ability); + // At the beginning of your upkeep, sacrifice a creature. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeControllerEffect(new FilterCreaturePermanent("a creature"), 1, ""), + TargetController.YOU, false)); } - public DemonicAppetite (final DemonicAppetite card) { + public DemonicAppetite(final DemonicAppetite card) { super(card); } @@ -80,16 +83,16 @@ public class DemonicAppetite extends CardImpl { } } - class DemonicAppetiteEffect extends SacrificeTargetEffect { +class DemonicAppetiteEffect extends SacrificeTargetEffect { - DemonicAppetiteEffect() { - super(); - staticText = "sacrifice a creature"; - } + DemonicAppetiteEffect() { + super(); + staticText = "sacrifice a creature"; + } - @Override - public DemonicAppetiteEffect copy() { - return new DemonicAppetiteEffect(); - } + @Override + public DemonicAppetiteEffect copy() { + return new DemonicAppetiteEffect(); + } -} +} diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/HellcarverDemon.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/HellcarverDemon.java index 0f479e09c9f..21e317a4214 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/HellcarverDemon.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/HellcarverDemon.java @@ -113,7 +113,7 @@ class HellcarverDemonEffect extends OneShotEffect { } } - while (player != null && player.isInGame() && player.chooseUse(Outcome.PlayForFree, "Cast another nonland card exiled with Hellcarver Demon without paying that card's mana cost?", source, game)) { + while (player != null && player.canRespond() && player.chooseUse(Outcome.PlayForFree, "Cast another nonland card exiled with Hellcarver Demon without paying that card's mana cost?", source, game)) { TargetCardInExile target = new TargetCardInExile(filter, source.getSourceId()); while (player.choose(Outcome.PlayForFree, game.getExile().getExileZone(source.getSourceId()), target, game)) { Card card = game.getCard(target.getFirstTarget()); diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/InduceDespair.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/InduceDespair.java index 24b5f55f6af..5719b94007d 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/InduceDespair.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/InduceDespair.java @@ -28,33 +28,35 @@ package mage.sets.riseoftheeldrazi; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; -import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.RevealTargetFromHandCost; +import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.filter.common.FilterCreatureCard; import mage.game.Game; import mage.game.permanent.Permanent; import mage.target.common.TargetCardInHand; import mage.target.common.TargetCreaturePermanent; +import mage.target.targetpointer.FixedTarget; /** * * @author jeffwadsworth */ public class InduceDespair extends CardImpl { - + private static final FilterCreatureCard filter = new FilterCreatureCard("creature card from your hand"); public InduceDespair(UUID ownerId) { super(ownerId, 114, "Induce Despair", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{B}"); this.expansionSetCode = "ROE"; - // As an additional cost to cast Induce Despair, reveal a creature card from your hand. // Target creature gets -X/-X until end of turn, where X is the revealed card's converted mana cost. this.getSpellAbility().addEffect(new InduceDespairEffect()); @@ -87,13 +89,14 @@ class InduceDespairEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { RevealTargetFromHandCost cost = (RevealTargetFromHandCost) source.getCosts().get(0); Permanent creature = game.getPermanent(targetPointer.getFirst(game, source)); - if (cost != null) { - int CMC = -1 * cost.convertedManaCosts; - if (creature != null) { - creature.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceEffect(CMC, CMC, Duration.EndOfTurn)), source.getSourceId(), game, false); - } + if (cost != null && creature != null) { + int cmcBoost = -1 * cost.convertedManaCosts; + ContinuousEffect effect = new BoostTargetEffect(cmcBoost, cmcBoost, Duration.EndOfTurn); + effect.setTargetPointer(new FixedTarget(creature.getId(), creature.getZoneChangeCounter(game))); + game.addEffect(effect, source); + return true; } - return true; + return false; } @Override diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/LustForWar.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/LustForWar.java index 403a433405f..0f72528f309 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/LustForWar.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/LustForWar.java @@ -28,17 +28,20 @@ package mage.sets.riseoftheeldrazi; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; -import mage.abilities.common.BecomesTappedTriggeredAbility; +import mage.abilities.common.BecomesTappedAttachedTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.DamageControllerEffect; +import mage.abilities.effects.common.DamageAttachedControllerEffect; import mage.abilities.effects.common.combat.AttacksIfAbleAttachedEffect; -import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -56,17 +59,16 @@ public class LustForWar extends CardImpl { // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); - this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); // Whenever enchanted creature becomes tapped, Lust for War deals 3 damage to that creature's controller. - Ability attachedAbility = new BecomesTappedTriggeredAbility(new DamageControllerEffect(3)); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(attachedAbility, AttachmentType.AURA))); + this.addAbility(new BecomesTappedAttachedTriggeredAbility(new DamageAttachedControllerEffect(3), false)); // Enchanted creature attacks each turn if able. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, - new AttacksIfAbleAttachedEffect(Duration.WhileOnBattlefield, AttachmentType.AURA))); + new AttacksIfAbleAttachedEffect(Duration.WhileOnBattlefield, AttachmentType.AURA))); } public LustForWar(final LustForWar card) { diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/NotOfThisWorld.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/NotOfThisWorld.java index a3f6f6e6c1d..558d240f739 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/NotOfThisWorld.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/NotOfThisWorld.java @@ -67,7 +67,7 @@ public class NotOfThisWorld extends CardImpl { // Counter target spell or ability that targets a permanent you control. this.getSpellAbility().addTarget( - new TargetSpellTargetingControlledPermanent()); + new TargetStackObjectTargetingControlledPermanent()); this.getSpellAbility().addEffect(new CounterTargetEffect()); // Not of This World costs {7} less to cast if it targets a spell or ability that targets a creature you control with power 7 or greater. this.addAbility(new SimpleStaticAbility(Zone.STACK, new SpellCostReductionSourceEffect(7, NotOfThisWorldCondition.getInstance()))); @@ -83,17 +83,17 @@ public class NotOfThisWorld extends CardImpl { } } -class TargetSpellTargetingControlledPermanent extends TargetObject { +class TargetStackObjectTargetingControlledPermanent extends TargetObject { - public TargetSpellTargetingControlledPermanent() { + public TargetStackObjectTargetingControlledPermanent() { this.minNumberOfTargets = 1; this.maxNumberOfTargets = 1; this.zone = Zone.STACK; this.targetName = "spell or ability that targets a permanent you control"; } - public TargetSpellTargetingControlledPermanent(final TargetSpellTargetingControlledPermanent target) { + public TargetStackObjectTargetingControlledPermanent(final TargetStackObjectTargetingControlledPermanent target) { super(target); } @@ -164,8 +164,8 @@ class TargetSpellTargetingControlledPermanent extends TargetObject { } @Override - public TargetSpellTargetingControlledPermanent copy() { - return new TargetSpellTargetingControlledPermanent(this); + public TargetStackObjectTargetingControlledPermanent copy() { + return new TargetStackObjectTargetingControlledPermanent(this); } } diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/SnakeUmbra.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/SnakeUmbra.java index 5daad05f235..2c50e5be6e6 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/SnakeUmbra.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/SnakeUmbra.java @@ -29,18 +29,18 @@ package mage.sets.riseoftheeldrazi; import java.util.UUID; -import mage.constants.*; import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.Effect; import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; import mage.abilities.keyword.EnchantAbility; import mage.abilities.keyword.TotemArmorAbility; import mage.cards.CardImpl; +import mage.constants.*; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -61,17 +61,17 @@ public class SnakeUmbra extends CardImpl { this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); - + // Enchanted creature gets +1/+1 ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield)); - + // and has "Whenever this creature deals damage to an opponent, you may draw a card." Ability gainedAbility = new DealsDamageToOpponentTriggeredAbility(new DrawCardSourceControllerEffect(1), true); Effect effect = new GainAbilityAttachedEffect(gainedAbility, AttachmentType.AURA); effect.setText("and has \"Whenever this creature deals damage to an opponent, you may draw a card.\""); ability.addEffect(effect); this.addAbility(ability); - + // Totem armor this.addAbility(new TotemArmorAbility()); } diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/TrainingGrounds.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/TrainingGrounds.java index d1aeb9882d5..9919547c67c 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/TrainingGrounds.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/TrainingGrounds.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.riseoftheeldrazi; import java.util.LinkedHashSet; @@ -33,6 +32,7 @@ import java.util.Set; import java.util.UUID; import mage.Mana; import mage.abilities.Ability; +import mage.abilities.ActivatedAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.cost.CostModificationEffectImpl; import mage.cards.CardImpl; @@ -56,14 +56,14 @@ import mage.util.CardUtil; */ public class TrainingGrounds extends CardImpl { - public TrainingGrounds (UUID ownerId) { + public TrainingGrounds(UUID ownerId) { super(ownerId, 91, "Training Grounds", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{U}"); this.expansionSetCode = "ROE"; this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new TrainingGroundsEffect())); } - public TrainingGrounds (final TrainingGrounds card) { + public TrainingGrounds(final TrainingGrounds card) { super(card); } @@ -74,7 +74,7 @@ public class TrainingGrounds extends CardImpl { } class TrainingGroundsEffect extends CostModificationEffectImpl { - + private static final String effectText = "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"; private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent(); @@ -90,41 +90,42 @@ class TrainingGroundsEffect extends CostModificationEffectImpl { @Override public boolean apply(Game game, Ability source, Ability abilityToModify) { Player controller = game.getPlayer(abilityToModify.getControllerId()); - if (controller != null){ + if (controller != null) { Mana mana = abilityToModify.getManaCostsToPay().getMana(); int reduceMax = mana.getColorless(); - if (reduceMax > 0 && mana.count() == mana.getColorless()){ + if (reduceMax > 0 && mana.count() == mana.getColorless()) { reduceMax--; } - if (reduceMax > 2){ + if (reduceMax > 2) { reduceMax = 2; } if (reduceMax > 0) { ChoiceImpl choice = new ChoiceImpl(true); Set set = new LinkedHashSet<>(); - for(int i = 0; i <= reduceMax; i++){ + for (int i = 0; i <= reduceMax; i++) { set.add(String.valueOf(i)); } choice.setChoices(set); choice.setMessage("Reduce ability cost"); - if(controller.choose(Outcome.Benefit, choice, game)){ + if (controller.choose(Outcome.Benefit, choice, game)) { int reduce = Integer.parseInt(choice.getChoice()); CardUtil.reduceCost(abilityToModify, reduce); } } return true; } - return false; + return false; } @Override public boolean applies(Ability abilityToModify, Ability source, Game game) { - if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED)) { + if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED) + || (abilityToModify.getAbilityType().equals(AbilityType.MANA) && (abilityToModify instanceof ActivatedAbility))) { //Activated abilities of creatures you control Permanent permanent = game.getPermanent(abilityToModify.getSourceId()); if (permanent != null && filter.match(permanent, source.getSourceId(), source.getControllerId(), game)) { - return true; + return true; } } return false; diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/UlamogTheInfiniteGyre.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/UlamogTheInfiniteGyre.java index cbf82ffea26..7f3cf02de88 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/UlamogTheInfiniteGyre.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/UlamogTheInfiniteGyre.java @@ -64,7 +64,7 @@ public class UlamogTheInfiniteGyre extends CardImpl { this.power = new MageInt(10); this.toughness = new MageInt(10); - + // When you cast Ulamog, the Infinite Gyre, destroy target permanent. this.addAbility(new UlamogTheInfiniteGyreDestroyOnCastAbility()); // Annihilator 4 (Whenever this creature attacks, defending player sacrifices four permanents.) @@ -87,7 +87,7 @@ public class UlamogTheInfiniteGyre extends CardImpl { class UlamogTheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl { - UlamogTheInfiniteGyreDestroyOnCastAbility ( ) { + UlamogTheInfiniteGyreDestroyOnCastAbility() { super(Zone.STACK, new DestroyTargetEffect()); this.addTarget(new TargetPermanent()); } @@ -114,13 +114,13 @@ class UlamogTheInfiniteGyreDestroyOnCastAbility extends TriggeredAbilityImpl { @Override public String getRule() { - return new StringBuilder("When you cast {this}, ").append(super.getRule()).toString(); + return "When you cast {this}, " + super.getRule(); } } class UlamogTheInfiniteGyreEnterGraveyardEffect extends OneShotEffect { - UlamogTheInfiniteGyreEnterGraveyardEffect ( ) { + UlamogTheInfiniteGyreEnterGraveyardEffect() { super(Outcome.Benefit); staticText = "its owner shuffles his or her graveyard into his or her library"; } @@ -144,9 +144,9 @@ class UlamogTheInfiniteGyreEnterGraveyardEffect extends OneShotEffect { } Player player = game.getPlayer(ownerId); if (player != null) { - for (Card cardToMove: player.getGraveyard().getCards(game)) { + for (Card cardToMove : player.getGraveyard().getCards(game)) { cardToMove.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); - } + } player.shuffleLibrary(game); return true; } diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/ZulaportEnforcer.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/ZulaportEnforcer.java index a1b8a492f4b..9e4036e8187 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/ZulaportEnforcer.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/ZulaportEnforcer.java @@ -27,23 +27,24 @@ */ package mage.sets.riseoftheeldrazi; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; +import java.util.UUID; import mage.MageInt; +import mage.ObjectColor; import mage.abilities.Abilities; import mage.abilities.AbilitiesImpl; import mage.abilities.Ability; -import mage.abilities.EvasionAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.RestrictionEffect; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.LevelUpAbility; import mage.abilities.keyword.LevelerCardBuilder; import mage.cards.LevelerCard; -import mage.game.Game; -import mage.game.permanent.Permanent; - -import java.util.UUID; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; /** * @@ -51,6 +52,12 @@ import java.util.UUID; */ public class ZulaportEnforcer extends LevelerCard { + private final static FilterCreaturePermanent notBlackCreatures = new FilterCreaturePermanent("except by black creatures"); + + static { + notBlackCreatures.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + public ZulaportEnforcer(UUID ownerId) { super(ownerId, 133, "Zulaport Enforcer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); this.expansionSetCode = "ROE"; @@ -64,14 +71,13 @@ public class ZulaportEnforcer extends LevelerCard { this.addAbility(new LevelUpAbility(new ManaCostsImpl("{4}"))); // LEVEL 1-2: 3/3 - // LEVEL 3+: 5/5 // Zulaport Enforcer can't be blocked except by black creatures. - Abilities levelAbilities = new AbilitiesImpl(); - levelAbilities.add(ZulaportEnforcerAbility.getInstance()); + Abilities levelAbilities = new AbilitiesImpl<>(); + levelAbilities.add(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(notBlackCreatures, Duration.WhileOnBattlefield))); this.addAbilities(LevelerCardBuilder.construct( - new LevelerCardBuilder.LevelAbility(1, 2, new AbilitiesImpl(), 3, 3), + new LevelerCardBuilder.LevelAbility(1, 2, new AbilitiesImpl<>(), 3, 3), new LevelerCardBuilder.LevelAbility(3, -1, levelAbilities, 5, 5) )); setMaxLevelCounters(3); @@ -86,61 +92,3 @@ public class ZulaportEnforcer extends LevelerCard { return new ZulaportEnforcer(this); } } - -class ZulaportEnforcerAbility extends EvasionAbility { - - private static ZulaportEnforcerAbility instance; - - public static ZulaportEnforcerAbility getInstance() { - if (instance == null) { - instance = new ZulaportEnforcerAbility(); - } - return instance; - } - - private ZulaportEnforcerAbility() { - this.addEffect(new ZulaportEnforcerEffect()); - } - - @Override - public String getRule() { - return "{this} can't be blocked except by black creatures."; - } - - @Override - public ZulaportEnforcerAbility copy() { - return getInstance(); - } -} - -class ZulaportEnforcerEffect extends RestrictionEffect { - - public ZulaportEnforcerEffect() { - super(Duration.WhileOnBattlefield); - } - - public ZulaportEnforcerEffect(final ZulaportEnforcerEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - if (permanent.getAbilities().containsKey(ZulaportEnforcerAbility.getInstance().getId())) { - return true; - } - return false; - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - if (blocker.getColor(game).isBlack()) { - return true; - } - return false; - } - - @Override - public ZulaportEnforcerEffect copy() { - return new ZulaportEnforcerEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/DeathOfAThousandStings.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/DeathOfAThousandStings.java index 52c9424e24f..07ac0051eef 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/DeathOfAThousandStings.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/DeathOfAThousandStings.java @@ -53,7 +53,6 @@ public class DeathOfAThousandStings extends CardImpl { this.expansionSetCode = "SOK"; this.subtype.add("Arcane"); - // Target player loses 1 life and you gain 1 life. this.getSpellAbility().addEffect(new LoseLifeTargetEffect(1)); this.getSpellAbility().addTarget(new TargetPlayer()); @@ -64,10 +63,10 @@ public class DeathOfAThousandStings extends CardImpl { // At the beginning of your upkeep, if you have more cards in hand than each opponent, you may return Death of a Thousand Stings from your graveyard to your hand. Ability ability = new ConditionalTriggeredAbility( new BeginningOfUpkeepTriggeredAbility(Zone.GRAVEYARD, - new ReturnSourceFromGraveyardToHandEffect(), - TargetController.YOU, true), + new ReturnSourceFromGraveyardToHandEffect(), + TargetController.YOU, true), new MoreCardsInHandThanOpponentsCondition(), - "At the beginning of your upkeep, if you have more cards in hand than each opponent, you may return {this} from your graveyard to your hand.", true); + "At the beginning of your upkeep, if you have more cards in hand than each opponent, you may return {this} from your graveyard to your hand."); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/ElderPineOfJukai.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/ElderPineOfJukai.java index ac6b74af586..860c187ec2f 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/ElderPineOfJukai.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/ElderPineOfJukai.java @@ -99,13 +99,13 @@ class ElderPineOfJukaiEffect extends OneShotEffect { MageObject sourceObject = game.getObject(source.getSourceId()); if (controller == null || sourceObject == null) { return false; - } + } Cards cards = new CardsImpl(); cards.addAll(controller.getLibrary().getTopCards(game, 3)); controller.revealCards(sourceObject.getName(), cards, game); - for (Card card: cards.getCards(game)) { + for (Card card : cards.getCards(game)) { if (card.getCardType().contains(CardType.LAND)) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); cards.remove(card); } } diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/FootstepsOfTheGoryo.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/FootstepsOfTheGoryo.java index d558731be79..1e3be38179f 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/FootstepsOfTheGoryo.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/FootstepsOfTheGoryo.java @@ -32,15 +32,9 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.DelayedTriggeredAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; -import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; -import mage.abilities.effects.common.ExileTargetEffect; -import mage.abilities.effects.common.ReturnFromGraveyardToBattlefieldTargetEffect; import mage.abilities.effects.common.SacrificeTargetEffect; -import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; -import mage.abilities.keyword.HasteAbility; import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.*; @@ -62,7 +56,6 @@ public class FootstepsOfTheGoryo extends CardImpl { this.expansionSetCode = "SOK"; this.subtype.add("Arcane"); - // Return target creature card from your graveyard to the battlefield. Sacrifice that creature at the beginning of the next end step. this.getSpellAbility().addEffect(new FootstepsOfTheGoryoEffect()); this.getSpellAbility().addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard())); @@ -104,8 +97,8 @@ class FootstepsOfTheGoryoEffect extends OneShotEffect { Permanent permanent = game.getPermanent(card.getId()); if (permanent != null) { // Sacrifice it at end of turn - Effect sacrificeEffect = new SacrificeTargetEffect("Sacrifice that creature at the beginning of next end step"); - sacrificeEffect.setTargetPointer(new FixedTarget(card.getId())); + Effect sacrificeEffect = new SacrificeTargetEffect("Sacrifice that creature at the beginning of next end step", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/GodosIrregulars.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/GodosIrregulars.java index ed5fe602c33..f346e94a319 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/GodosIrregulars.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/GodosIrregulars.java @@ -34,11 +34,9 @@ import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; -import mage.constants.AbilityType; import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; -import mage.filter.Filter; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.permanent.BlockingAttackerIdPredicate; import mage.filter.predicate.permanent.BlockingPredicate; @@ -53,10 +51,13 @@ import mage.target.common.TargetCreaturePermanent; public class GodosIrregulars extends CardImpl { private static final FilterCreaturePermanent basicFilter = new FilterCreaturePermanent("creature blocking it"); + static { basicFilter.add(new BlockingPredicate()); } + public UUID originalAbilityIdToAdjust; + public GodosIrregulars(UUID ownerId) { super(ownerId, 101, "Godo's Irregulars", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{R}"); this.expansionSetCode = "SOK"; @@ -69,12 +70,13 @@ public class GodosIrregulars extends CardImpl { // {R}: Godo's Irregulars deals 1 damage to target creature blocking it. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new ManaCostsImpl("{R")); ability.addTarget(new TargetCreaturePermanent()); + originalAbilityIdToAdjust = ability.getOriginalId(); this.addAbility(ability); } @Override public void adjustTargets(Ability ability, Game game) { - if (ability.getAbilityType().equals(AbilityType.ACTIVATED)) { + if (originalAbilityIdToAdjust.equals(ability.getOriginalId())) { ability.getTargets().clear(); FilterCreaturePermanent filter = basicFilter.copy(); filter.add(new BlockingAttackerIdPredicate(this.getId())); @@ -85,6 +87,7 @@ public class GodosIrregulars extends CardImpl { public GodosIrregulars(final GodosIrregulars card) { super(card); + this.originalAbilityIdToAdjust = card.originalAbilityIdToAdjust; } @Override diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/IvoryCraneNetsuke.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/IvoryCraneNetsuke.java index 0ab2b4e3fdb..313615c5fae 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/IvoryCraneNetsuke.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/IvoryCraneNetsuke.java @@ -1,67 +1,67 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.saviorsofkamigawa; - -import java.util.UUID; -import mage.abilities.TriggeredAbility; -import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; -import mage.abilities.condition.common.CardsInHandCondition; -import mage.abilities.decorator.ConditionalTriggeredAbility; -import mage.abilities.effects.common.GainLifeEffect; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.constants.Zone; - -/** - * - * @author LevelX2 - */ -public class IvoryCraneNetsuke extends CardImpl { - - public IvoryCraneNetsuke(UUID ownerId) { - super(ownerId, 155, "Ivory Crane Netsuke", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); - this.expansionSetCode = "SOK"; - - // At the beginning of your upkeep, if you have seven or more cards in hand, you gain 4 life. - TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new GainLifeEffect(4), TargetController.YOU, false); - CardsInHandCondition contition = new CardsInHandCondition(CardsInHandCondition.CountType.MORE_THAN, 6); - this.addAbility(new ConditionalTriggeredAbility(ability, contition, "At the beginning of your upkeep, if you have seven or more cards in hand, you gain 4 life.")); - - } - - public IvoryCraneNetsuke(final IvoryCraneNetsuke card) { - super(card); - } - - @Override - public IvoryCraneNetsuke copy() { - return new IvoryCraneNetsuke(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.saviorsofkamigawa; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author LevelX2 + */ +public class IvoryCraneNetsuke extends CardImpl { + + public IvoryCraneNetsuke(UUID ownerId) { + super(ownerId, 155, "Ivory Crane Netsuke", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "SOK"; + + // At the beginning of your upkeep, if you have seven or more cards in hand, you gain 4 life. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new GainLifeEffect(4), TargetController.YOU, false); + CardsInHandCondition condition = new CardsInHandCondition(CardsInHandCondition.CountType.MORE_THAN, 6); + this.addAbility(new ConditionalTriggeredAbility(ability, condition, "At the beginning of your upkeep, if you have seven or more cards in hand, you gain 4 life.")); + + } + + public IvoryCraneNetsuke(final IvoryCraneNetsuke card) { + super(card); + } + + @Override + public IvoryCraneNetsuke copy() { + return new IvoryCraneNetsuke(this); + } +} diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/SasayaOrochiAscendant.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/SasayaOrochiAscendant.java index 1692019dc10..3bc2a38c378 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/SasayaOrochiAscendant.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/SasayaOrochiAscendant.java @@ -192,7 +192,7 @@ class SasayasEssenceManaEffectEffect extends ManaEffect { } else { while(!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/SekkiSeasonsGuide.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/SekkiSeasonsGuide.java index 83cfa25aafb..0d45c155313 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/SekkiSeasonsGuide.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/SekkiSeasonsGuide.java @@ -36,7 +36,7 @@ import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.SacrificeTargetCost; import mage.abilities.effects.PreventionEffectImpl; import mage.abilities.effects.common.CreateTokenEffect; -import mage.abilities.effects.common.ReturnSourceFromGraveyardToHandEffect; +import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; @@ -81,9 +81,9 @@ public class SekkiSeasonsGuide extends CardImpl { // Sacrifice eight Spirits: Return Sekki from your graveyard to the battlefield. this.addAbility(new SimpleActivatedAbility( - Zone.BATTLEFIELD, - new ReturnSourceFromGraveyardToHandEffect(), - new SacrificeTargetCost(new TargetControlledPermanent(8,8,filter, true)))); + Zone.GRAVEYARD, + new ReturnSourceFromGraveyardToBattlefieldEffect(), + new SacrificeTargetCost(new TargetControlledPermanent(8, 8, filter, true)))); } public SekkiSeasonsGuide(final SekkiSeasonsGuide card) { @@ -98,45 +98,45 @@ public class SekkiSeasonsGuide extends CardImpl { class SekkiSeasonsGuideEffect extends PreventionEffectImpl { - public SekkiSeasonsGuideEffect() { - super(Duration.WhileOnBattlefield, Integer.MAX_VALUE, false, false); - staticText = "If damage would be dealt to {this}, prevent that damage, remove that many +1/+1 counters from {this}, and put that many 1/1 colorless Spirit creature tokens onto the battlefield"; - } + public SekkiSeasonsGuideEffect() { + super(Duration.WhileOnBattlefield, Integer.MAX_VALUE, false, false); + staticText = "If damage would be dealt to {this}, prevent that damage, remove that many +1/+1 counters from {this}, and put that many 1/1 colorless Spirit creature tokens onto the battlefield"; + } - public SekkiSeasonsGuideEffect(final SekkiSeasonsGuideEffect effect) { - super(effect); - } + public SekkiSeasonsGuideEffect(final SekkiSeasonsGuideEffect effect) { + super(effect); + } - @Override - public SekkiSeasonsGuideEffect copy() { - return new SekkiSeasonsGuideEffect(this); - } + @Override + public SekkiSeasonsGuideEffect copy() { + return new SekkiSeasonsGuideEffect(this); + } - @Override - public boolean apply(Game game, Ability source) { - return true; - } + @Override + public boolean apply(Game game, Ability source) { + return true; + } - @Override - public boolean replaceEvent(GameEvent event, Ability source, Game game) { - int damage = event.getAmount(); - preventDamageAction(event, source, game); - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null) { - permanent.removeCounters(CounterType.P1P1.createInstance(damage), game); + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + int damage = event.getAmount(); + preventDamageAction(event, source, game); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + permanent.removeCounters(CounterType.P1P1.createInstance(damage), game); + } + new CreateTokenEffect(new SpiritToken(), damage).apply(game, source); + return true; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (super.applies(event, source, game)) { + if (event.getTargetId().equals(source.getSourceId())) { + return true; } - new CreateTokenEffect(new SpiritToken(), damage).apply(game, source); - return true; } + return false; + } - @Override - public boolean applies(GameEvent event, Ability source, Game game) { - if (super.applies(event, source, game)) { - if (event.getTargetId().equals(source.getSourceId())) { - return true; - } - } - return false; - } - - } \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/ShapeStealer.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/ShapeStealer.java index f0384b087dd..51cddc6978c 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/ShapeStealer.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/ShapeStealer.java @@ -56,13 +56,13 @@ public class ShapeStealer extends CardImpl { this.subtype.add("Spirit"); this.power = new MageInt(1); this.toughness = new MageInt(1); - // This ability triggers once for each creature blocked by or blocking Shape Stealer. // If multiple creatures block it, Shape Stealer's power and toughness will change for // each one in succession. The first trigger put on the stack will be the last to resolve, // so that will set Shape Stealer's final power and toughness. - // Whenever Shape Stealer blocks or becomes blocked by a creature, change Shape Stealer's power and toughness to that creature's power and toughness until end of turn. + + // Whenever Shape Stealer blocks or becomes blocked by a creature, change Shape Stealer's base power and toughness to that creature's power and toughness until end of turn. this.addAbility(new BlocksOrBecomesBlockedByCreatureTriggeredAbility(new ShapeStealerEffect(), false)); } @@ -80,7 +80,7 @@ class ShapeStealerEffect extends OneShotEffect { public ShapeStealerEffect() { super(Outcome.Detriment); - this.staticText = "change {this}'s power and toughness to that creature's power and toughness until end of turn"; + this.staticText = "change {this}'s base power and toughness to that creature's power and toughness until end of turn"; } public ShapeStealerEffect(final ShapeStealerEffect effect) { diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/UndyingFlames.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/UndyingFlames.java index c9a1c61c0ed..a2e743fb821 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/UndyingFlames.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/UndyingFlames.java @@ -91,7 +91,7 @@ class UndyingFlamesEffect extends OneShotEffect { Player you = game.getPlayer(source.getControllerId()); Card sourceCard = game.getCard(source.getSourceId()); while (you != null && sourceCard != null - && you.getLibrary().size() > 0 && you.isInGame()) { + && you.getLibrary().size() > 0 && you.canRespond()) { Card card = you.getLibrary().removeFromTop(game); if (card != null) { you.moveCardToExileWithInfo(card, null, null, source.getSourceId(), game, Zone.LIBRARY, true); diff --git a/Mage.Sets/src/mage/sets/saviorsofkamigawa/WineOfBloodAndIron.java b/Mage.Sets/src/mage/sets/saviorsofkamigawa/WineOfBloodAndIron.java index 2a831a03a06..bfe6007c45b 100644 --- a/Mage.Sets/src/mage/sets/saviorsofkamigawa/WineOfBloodAndIron.java +++ b/Mage.Sets/src/mage/sets/saviorsofkamigawa/WineOfBloodAndIron.java @@ -30,23 +30,19 @@ package mage.sets.saviorsofkamigawa; import java.util.UUID; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.DelayedTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.dynamicvalue.common.TargetPermanentPowerCount; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CreateDelayedTriggeredAbilityEffect; +import mage.abilities.effects.common.SacrificeSourceEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.cards.CardImpl; -import mage.game.Game; import mage.target.common.TargetCreaturePermanent; -import mage.target.targetpointer.FixedTarget; /** * @@ -62,7 +58,10 @@ public class WineOfBloodAndIron extends CardImpl { SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(new TargetPermanentPowerCount(), new StaticValue(0), Duration.EndOfTurn, true), new GenericManaCost(4)); - ability.addEffect(new WineOfBloodAndIronEffect()); + Effect effect = new CreateDelayedTriggeredAbilityEffect( + new AtTheBeginOfNextEndStepDelayedTriggeredAbility(new SacrificeSourceEffect()), false); + effect.setText("Sacrifice {this} at the beginning of the next end step"); + ability.addEffect(effect); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); } @@ -76,32 +75,3 @@ public class WineOfBloodAndIron extends CardImpl { return new WineOfBloodAndIron(this); } } - -class WineOfBloodAndIronEffect extends OneShotEffect { - - public WineOfBloodAndIronEffect() { - super(Outcome.Sacrifice); - this.staticText = "Sacrifice {this} at the beginning of the next end step"; - } - - public WineOfBloodAndIronEffect(final WineOfBloodAndIronEffect effect) { - super(effect); - } - - @Override - public WineOfBloodAndIronEffect copy() { - return new WineOfBloodAndIronEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice this"); - sacrificeEffect.setTargetPointer(new FixedTarget(source.getSourceId())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); - return true; - } -} diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ArgentSphinx.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ArgentSphinx.java index 3613ce6d0d4..3863832e516 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ArgentSphinx.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ArgentSphinx.java @@ -25,15 +25,11 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.scarsofmirrodin; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.common.delayed.AtTheBeginOfNextEndStepDelayedTriggeredAbility; @@ -43,7 +39,10 @@ import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ReturnFromExileEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; @@ -53,7 +52,7 @@ import mage.game.permanent.Permanent; */ public class ArgentSphinx extends CardImpl { - public ArgentSphinx (UUID ownerId) { + public ArgentSphinx(UUID ownerId) { super(ownerId, 28, "Argent Sphinx", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{U}{U}"); this.expansionSetCode = "SOM"; this.subtype.add("Sphinx"); @@ -66,7 +65,7 @@ public class ArgentSphinx extends CardImpl { this.addAbility(ability); } - public ArgentSphinx (final ArgentSphinx card) { + public ArgentSphinx(final ArgentSphinx card) { super(card); } @@ -81,7 +80,7 @@ class ArgentSphinxEffect extends OneShotEffect { private static final String effectText = "Exile {this}. Return it to the battlefield under your control at the beginning of the next end step"; - ArgentSphinxEffect ( ) { + ArgentSphinxEffect() { super(Outcome.Benefit); staticText = effectText; } @@ -93,10 +92,13 @@ class ArgentSphinxEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null) { - if (permanent.moveToExile(source.getSourceId(), "Argent Sphinx Exile", source.getSourceId(), game)) { + MageObject sourceObject = game.getObject(source.getSourceId()); + if (permanent != null && sourceObject != null) { + if (permanent.moveToExile(source.getSourceId(), sourceObject.getIdName(), source.getSourceId(), game)) { //create delayed triggered ability - AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(new ReturnFromExileEffect(source.getSourceId(), Zone.BATTLEFIELD)); + AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility + = new AtTheBeginOfNextEndStepDelayedTriggeredAbility( + new ReturnFromExileEffect(source.getSourceId(), Zone.BATTLEFIELD)); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setSourceObject(source.getSourceObject(game), game); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/CerebralEruption.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/CerebralEruption.java index 318cd6d1486..404279a7b39 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/CerebralEruption.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/CerebralEruption.java @@ -1,16 +1,16 @@ /* * Copyright 2011 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -28,6 +28,7 @@ package mage.sets.scarsofmirrodin; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; @@ -55,7 +56,6 @@ public class CerebralEruption extends CardImpl { super(ownerId, 86, "Cerebral Eruption", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{2}{R}{R}"); this.expansionSetCode = "SOM"; - // Target opponent reveals the top card of his or her library. Cerebral Eruption deals damage equal to the revealed card's converted mana cost to that player and each creature he or she controls. If a land card is revealed this way, return Cerebral Eruption to its owner's hand. this.getSpellAbility().addTarget(new TargetOpponent()); this.getSpellAbility().addEffect(new CerebralEruptionEffect()); @@ -87,21 +87,21 @@ class CerebralEruptionEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getFirstTarget()); - if (player != null && player.getLibrary().size() > 0) { + MageObject sourceObject = game.getObject(source.getSourceId()); + if (player != null && sourceObject != null && player.getLibrary().size() > 0) { Card card = player.getLibrary().getFromTop(game); - Cards cards = new CardsImpl(); - cards.add(card); - player.revealCards("Cerebral Eruption", cards, game); + Cards cards = new CardsImpl(card); + player.revealCards(sourceObject.getIdName(), cards, game); game.getState().setValue(source.getSourceId().toString(), card); int damage = card.getManaCost().convertedManaCost(); player.damage(damage, source.getSourceId(), game, false, true); - for (Permanent perm: game.getBattlefield().getAllActivePermanents(filter, player.getId(), game)) { + for (Permanent perm : game.getBattlefield().getAllActivePermanents(filter, player.getId(), game)) { perm.damage(damage, source.getSourceId(), game, false, true); } if (card.getCardType().contains(CardType.LAND)) { Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard(); if (spellCard != null) { - player.moveCardToHandWithInfo(spellCard, source.getSourceId(), game, Zone.STACK); + player.moveCards(spellCard, null, Zone.HAND, source, game); } } return true; diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/CloneShell.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/CloneShell.java index b200bd833ea..4f984aaf754 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/CloneShell.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/CloneShell.java @@ -125,7 +125,7 @@ class CloneShellEffect extends OneShotEffect { if (cards.size() > 0) { TargetCard target2 = new TargetCard(Zone.PICK, filter2); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Benefit, cards, target2, game); Card card = cards.get(target2.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/KuldothaRebirth.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/KuldothaRebirth.java index 0def5d46f32..f5e1c2d7146 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/KuldothaRebirth.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/KuldothaRebirth.java @@ -25,33 +25,32 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.scarsofmirrodin; -import mage.constants.CardType; -import mage.constants.Rarity; +import java.util.UUID; import mage.abilities.costs.common.SacrificeTargetCost; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.filter.common.FilterControlledPermanent; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.game.permanent.token.GoblinToken; import mage.target.common.TargetControlledPermanent; -import java.util.UUID; - /** * * @author Loki */ public class KuldothaRebirth extends CardImpl { + private static final FilterControlledPermanent filter = new FilterControlledPermanent("an artifact"); static { filter.add(new CardTypePredicate(CardType.ARTIFACT)); } - public KuldothaRebirth (UUID ownerId) { + public KuldothaRebirth(UUID ownerId) { super(ownerId, 96, "Kuldotha Rebirth", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{R}"); this.expansionSetCode = "SOM"; @@ -59,7 +58,7 @@ public class KuldothaRebirth extends CardImpl { this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledPermanent(filter))); } - public KuldothaRebirth (final KuldothaRebirth card) { + public KuldothaRebirth(final KuldothaRebirth card) { super(card); } @@ -68,4 +67,4 @@ public class KuldothaRebirth extends CardImpl { return new KuldothaRebirth(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/Memoricide.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/Memoricide.java index 3b5df3a250f..1d4bea6649b 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/Memoricide.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/Memoricide.java @@ -93,7 +93,7 @@ class MemoricideEffect extends OneShotEffect { cardChoice.clearChoice(); while (!controller.choose(Outcome.Exile, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/MimicVat.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/MimicVat.java index b194cda67d5..2a24c0196ea 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/MimicVat.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/MimicVat.java @@ -117,11 +117,11 @@ class MimicVatTriggeredAbility extends TriggeredAbilityImpl { ZoneChangeEvent zEvent = (ZoneChangeEvent) event; Permanent permanent = zEvent.getTarget(); - if (permanent != null && - zEvent.getToZone() == Zone.GRAVEYARD && - zEvent.getFromZone() == Zone.BATTLEFIELD && - !(permanent instanceof PermanentToken) && - permanent.getCardType().contains(CardType.CREATURE)) { + if (permanent != null + && zEvent.getToZone() == Zone.GRAVEYARD + && zEvent.getFromZone() == Zone.BATTLEFIELD + && !(permanent instanceof PermanentToken) + && permanent.getCardType().contains(CardType.CREATURE)) { getEffects().get(0).setTargetPointer(new FixedTarget(permanent.getId())); return true; @@ -131,7 +131,7 @@ class MimicVatTriggeredAbility extends TriggeredAbilityImpl { @Override public String getRule() { - return "Whenever a nontoken creature dies, you may exile that card. If you do, return each other card exiled with {this} to its owner's graveyard"; + return "Whenever a nontoken creature dies, you may exile that card. If you do, return each other card exiled with {this} to its owner's graveyard."; } } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/MoriokReplica.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/MoriokReplica.java index d8919a383a6..2c94a0706da 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/MoriokReplica.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/MoriokReplica.java @@ -29,17 +29,18 @@ package mage.sets.scarsofmirrodin; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.LoseLifeSourceControllerEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; /** * @@ -53,9 +54,15 @@ public class MoriokReplica extends CardImpl { this.subtype.add("Warrior"); this.power = new MageInt(2); this.toughness = new MageInt(2); - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DrawCardSourceControllerEffect(2), new ManaCostsImpl("{1}{B}")); + + // {1}{B}, Sacrifice Moriok Replica: You draw two cards and you lose 2 life. + Effect effect = new DrawCardSourceControllerEffect(2); + effect.setText("You draw two cards"); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{1}{B}")); + effect = new LoseLifeSourceControllerEffect(2); + effect.setText("and you lose 2 life"); ability.addCost(new SacrificeSourceCost()); - ability.addEffect(new LoseLifeSourceControllerEffect(2)); + ability.addEffect(effect); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/MyrBattlesphere.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/MyrBattlesphere.java index 6b53dcbc271..c0c51087095 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/MyrBattlesphere.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/MyrBattlesphere.java @@ -109,7 +109,7 @@ class MyrBattlesphereEffect extends OneShotEffect { if (controller != null) { int tappedAmount = 0; TargetPermanent target = new TargetPermanent(0,1,filter, false); - while (true && controller.isInGame()) { + while (true && controller.canRespond()) { target.clearChosen(); if (target.canChoose(source.getControllerId(), game)) { Map options = new HashMap<>(); diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/PsychicMiasma.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/PsychicMiasma.java index 389297a1198..99de7634a75 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/PsychicMiasma.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/PsychicMiasma.java @@ -1,16 +1,16 @@ /* * Copyright 2011 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -50,7 +50,6 @@ public class PsychicMiasma extends CardImpl { super(ownerId, 76, "Psychic Miasma", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{B}"); this.expansionSetCode = "SOM"; - // Target player discards a card. If a land card is discarded this way, return Psychic Miasma to its owner's hand. this.getSpellAbility().addTarget(new TargetPlayer()); this.getSpellAbility().addEffect(new PsychicMiasmaEffect()); @@ -86,9 +85,10 @@ class PsychicMiasmaEffect extends OneShotEffect { if (discardedCard != null && discardedCard.getCardType().contains(CardType.LAND)) { Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard(); if (spellCard != null) { - player.moveCardToHandWithInfo(spellCard, source.getSourceId(), game, Zone.STACK); + player.moveCards(spellCard, null, Zone.HAND, source, game); } } + return true; } return false; } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/ShapeAnew.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/ShapeAnew.java index cef5f23b882..b02ce34d87e 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/ShapeAnew.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/ShapeAnew.java @@ -25,13 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.scarsofmirrodin; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.SacrificeTargetEffect; @@ -39,7 +35,9 @@ import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterPermanent; import mage.filter.predicate.mageobject.CardTypePredicate; @@ -60,16 +58,19 @@ public class ShapeAnew extends CardImpl { filter.add(new CardTypePredicate(CardType.ARTIFACT)); } - public ShapeAnew (UUID ownerId) { + public ShapeAnew(UUID ownerId) { super(ownerId, 43, "Shape Anew", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{3}{U}"); this.expansionSetCode = "SOM"; - this.getSpellAbility().addEffect(new SacrificeTargetEffect()); + // 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. + this.getSpellAbility().addEffect(new SacrificeTargetEffect("The controller of target artifact sacrifices it")); this.getSpellAbility().addTarget(new TargetPermanent(filter)); this.getSpellAbility().addEffect(new ShapeAnewEffect()); } - public ShapeAnew (final ShapeAnew card) { + public ShapeAnew(final ShapeAnew card) { super(card); } @@ -82,7 +83,7 @@ public class ShapeAnew extends CardImpl { public ShapeAnewEffect() { super(Outcome.PutCardInPlay); - staticText = "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"; + staticText = ", 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"; } public ShapeAnewEffect(ShapeAnewEffect effect) { @@ -102,9 +103,9 @@ public class ShapeAnew extends CardImpl { Cards revealed = new CardsImpl(); Card artifactCard = null; Cards nonArtifactCards = new CardsImpl(); - Player player = game.getPlayer(sourcePermanent.getControllerId()); - while (artifactCard == null && player.getLibrary().size() > 0) { - Card card = player.getLibrary().removeFromTop(game); + Player targetController = game.getPlayer(sourcePermanent.getControllerId()); + while (artifactCard == null && targetController.getLibrary().size() > 0) { + Card card = targetController.getLibrary().removeFromTop(game); revealed.add(card); if (card.getCardType().contains(CardType.ARTIFACT)) { artifactCard = card; @@ -112,14 +113,12 @@ public class ShapeAnew extends CardImpl { nonArtifactCards.add(card); } } - player.revealCards("Shape Anew", revealed, game); + targetController.revealCards(sourcePermanent.getIdName(), revealed, game); if (artifactCard != null) { - artifactCard.putOntoBattlefield(game, Zone.LIBRARY, source.getSourceId(), player.getId()); + artifactCard.putOntoBattlefield(game, Zone.LIBRARY, source.getSourceId(), targetController.getId()); } - for (Card cardToMove: nonArtifactCards.getCards(game)) { - cardToMove.moveToZone(Zone.LIBRARY, source.getSourceId(), game, true); - } - player.shuffleLibrary(game); + targetController.moveCards(nonArtifactCards, null, Zone.LIBRARY, source, game); + targetController.shuffleLibrary(game); return true; } diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/VenserTheSojourner.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/VenserTheSojourner.java index 2182a3dd8a6..2f4def3ecfd 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/VenserTheSojourner.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/VenserTheSojourner.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.scarsofmirrodin; import java.util.UUID; @@ -81,8 +80,6 @@ public class VenserTheSojourner extends CardImpl { this.expansionSetCode = "SOM"; this.subtype.add("Venser"); - - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.LOYALTY.createInstance(3)), false)); // +2: Exile target permanent you own. Return it to the battlefield under your control at the beginning of the next end step. @@ -131,7 +128,7 @@ class VenserTheSojournerEffect extends OneShotEffect { if (getTargetPointer().getFirst(game, source) != null) { Permanent permanent = game.getPermanent(getTargetPointer().getFirst(game, source)); if (permanent != null) { - if (controller.moveCardToExileWithInfo(permanent, source.getSourceId(), sourceObject.getName(), source.getSourceId(), game, Zone.BATTLEFIELD, true)) { + if (controller.moveCardToExileWithInfo(permanent, source.getSourceId(), sourceObject.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true)) { //create delayed triggered ability AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(new ReturnFromExileEffect(source.getSourceId(), Zone.BATTLEFIELD)); delayedAbility.setSourceId(source.getSourceId()); @@ -174,7 +171,8 @@ class VenserTheSojournerSpellCastTriggeredAbility extends TriggeredAbilityImpl { protected FilterSpell filter; /** - * If true, the source that triggered the ability will be set as target to effect. + * If true, the source that triggered the ability will be set as target to + * effect. */ protected boolean rememberSource = false; diff --git a/Mage.Sets/src/mage/sets/scourge/KaronaFalseGod.java b/Mage.Sets/src/mage/sets/scourge/KaronaFalseGod.java index bc93b1ed61a..9313ed5c764 100644 --- a/Mage.Sets/src/mage/sets/scourge/KaronaFalseGod.java +++ b/Mage.Sets/src/mage/sets/scourge/KaronaFalseGod.java @@ -148,7 +148,7 @@ class KaronaFalseGodEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!controller.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/scourge/PemminsAura.java b/Mage.Sets/src/mage/sets/scourge/PemminsAura.java new file mode 100644 index 00000000000..82fb31f25e7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/scourge/PemminsAura.java @@ -0,0 +1,144 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.scourge; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.UntapEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.choices.Choice; +import mage.choices.ChoiceImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class PemminsAura extends CardImpl { + + public PemminsAura(UUID ownerId) { + super(ownerId, 45, "Pemmin's Aura", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}{U}"); + this.expansionSetCode = "SCG"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // {U}: Untap enchanted creature. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapEnchantedEffect(), new ManaCostsImpl("{U}"))); + + // {U}: Enchanted creature gains flying until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(FlyingAbility.getInstance(), + AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl("{U}"))); + + // {U}: Enchanted creature gains shroud until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(ShroudAbility.getInstance(), + AttachmentType.AURA, Duration.EndOfTurn), new ManaCostsImpl("{U}"))); + + // {1}: Enchanted creature gets +1/-1 or -1/+1 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PemminsAuraBoostEnchantedEffect(), new ManaCostsImpl("U"))); + } + + public PemminsAura(final PemminsAura card) { + super(card); + } + + @Override + public PemminsAura copy() { + return new PemminsAura(this); + } +} + +class PemminsAuraBoostEnchantedEffect extends OneShotEffect { + + private static String CHOICE_1 = "+1/-1"; + private static String CHOICE_2 = "-1/+1"; + + public PemminsAuraBoostEnchantedEffect() { + super(Outcome.BoostCreature); + this.staticText = "Enchanted creature gets +1/-1 or -1/+1 until end of turn"; + } + + public PemminsAuraBoostEnchantedEffect(final PemminsAuraBoostEnchantedEffect effect) { + super(effect); + } + + @Override + public PemminsAuraBoostEnchantedEffect copy() { + return new PemminsAuraBoostEnchantedEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent enchantment = game.getPermanent(source.getSourceId()); + Permanent creature = game.getPermanent(enchantment.getAttachedTo()); + if (controller != null && creature != null) { + Choice choice = new ChoiceImpl(true); + choice.setMessage("Select how to boost"); + choice.getChoices().add(CHOICE_1); + choice.getChoices().add(CHOICE_2); + while (!choice.isChosen()) { + if (!controller.canRespond()) { + return false; + } + controller.choose(outcome, choice, game); + } + if (choice.getChoice().equals(CHOICE_1)) { + game.addEffect(new BoostEnchantedEffect(+1, -1, Duration.EndOfTurn), source); + } else { + game.addEffect(new BoostEnchantedEffect(-1, +1, Duration.EndOfTurn), source); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/scourge/RavenGuildMaster.java b/Mage.Sets/src/mage/sets/scourge/RavenGuildMaster.java new file mode 100644 index 00000000000..938a4bc5dcb --- /dev/null +++ b/Mage.Sets/src/mage/sets/scourge/RavenGuildMaster.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.scourge; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.DealsDamageToAPlayerTriggeredAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class RavenGuildMaster extends CardImpl { + + public RavenGuildMaster(UUID ownerId) { + super(ownerId, 47, "Raven Guild Master", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "SCG"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.subtype.add("Mutant"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Whenever Raven Guild Master deals combat damage to a player, that player exiles the top ten cards of his or her library. + this.addAbility(new DealsDamageToAPlayerTriggeredAbility(new RavenGuildMasterEffect(), false, true)); + + // Morph {2}{U}{U} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{2}{U}{U}"))); + } + + public RavenGuildMaster(final RavenGuildMaster card) { + super(card); + } + + @Override + public RavenGuildMaster copy() { + return new RavenGuildMaster(this); + } +} + +class RavenGuildMasterEffect extends OneShotEffect { + + public RavenGuildMasterEffect() { + super(Outcome.Exile); + this.staticText = "that player exiles the top ten cards of his or her library"; + } + + public RavenGuildMasterEffect(final RavenGuildMasterEffect effect) { + super(effect); + } + + @Override + public RavenGuildMasterEffect copy() { + return new RavenGuildMasterEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(targetPointer.getFirst(game, source)); + if (player != null) { + int count = Math.min(player.getLibrary().size(), 10); + for (int i = 0; i < count; i++) { + Card card = player.getLibrary().removeFromTop(game); + if (card != null) { + card.moveToExile(id, "", source.getSourceId(), game); + } + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/scourge/SkirkVolcanist.java b/Mage.Sets/src/mage/sets/scourge/SkirkVolcanist.java new file mode 100644 index 00000000000..383c25f0006 --- /dev/null +++ b/Mage.Sets/src/mage/sets/scourge/SkirkVolcanist.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.scourge; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.TurnedFaceUpSourceTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageMultiEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetCreaturePermanentAmount; + +/** + * + * @author fireshoes + */ +public class SkirkVolcanist extends CardImpl { + + private static final FilterControlledLandPermanent filterSacrifice = new FilterControlledLandPermanent("two Mountains"); + + static { + filterSacrifice.add(new SubtypePredicate("Mountain")); + } + + public SkirkVolcanist(UUID ownerId) { + super(ownerId, 104, "Skirk Volcanist", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "SCG"; + this.subtype.add("Goblin"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // Morph-Sacrifice two Mountains. + this.addAbility(new MorphAbility(this, new SacrificeTargetCost(new TargetControlledPermanent(2,2, filterSacrifice, false)))); + + // When Skirk Volcanist is turned face up, it deals 3 damage divided as you choose among one, two, or three target creatures. + Effect effect = new DamageMultiEffect(3); + effect.setText("it deals 3 damage divided as you choose among one, two, or three target creatures"); + Ability ability = new TurnedFaceUpSourceTriggeredAbility(effect); + ability.addTarget(new TargetCreaturePermanentAmount(3)); + this.addAbility(ability); + } + + public SkirkVolcanist(final SkirkVolcanist card) { + super(card); + } + + @Override + public SkirkVolcanist copy() { + return new SkirkVolcanist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/scourge/SoulCollector.java b/Mage.Sets/src/mage/sets/scourge/SoulCollector.java new file mode 100644 index 00000000000..b1432d441d4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/scourge/SoulCollector.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.scourge; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author markedagain + */ +public class SoulCollector extends mage.sets.timeshifted.SoulCollector { + + public SoulCollector(UUID ownerId) { + super(ownerId); + this.cardNumber = 74; + this.expansionSetCode = "SCG"; + this.rarity = Rarity.RARE; + } + + public SoulCollector(final SoulCollector card) { + super(card); + } + + @Override + public SoulCollector copy() { + return new SoulCollector(this); + } +} diff --git a/Mage.Sets/src/mage/sets/scourge/TreetopScout.java b/Mage.Sets/src/mage/sets/scourge/TreetopScout.java index 200e3b941fe..94326c9140e 100644 --- a/Mage.Sets/src/mage/sets/scourge/TreetopScout.java +++ b/Mage.Sets/src/mage/sets/scourge/TreetopScout.java @@ -29,15 +29,13 @@ package mage.sets.scourge; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesAllEffect; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; @@ -64,9 +62,7 @@ public class TreetopScout extends CardImpl { this.toughness = new MageInt(1); // Treetop Scout can't be blocked except by creatures with flying. - this.addAbility(new SimpleStaticAbility( - Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(onlyFlyingCreatures, Duration.WhileOnBattlefield) - )); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(onlyFlyingCreatures, Duration.WhileOnBattlefield))); } public TreetopScout(final TreetopScout card) { diff --git a/Mage.Sets/src/mage/sets/shadowmoor/AdviceFromTheFae.java b/Mage.Sets/src/mage/sets/shadowmoor/AdviceFromTheFae.java index 402a2e440ab..bf1ed806de7 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/AdviceFromTheFae.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/AdviceFromTheFae.java @@ -27,12 +27,10 @@ */ package mage.sets.shadowmoor; -import java.util.List; import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.cards.Cards; import mage.cards.CardsImpl; @@ -95,12 +93,8 @@ class AdviceFromTheFaeEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); MageObject mageObject = game.getObject(source.getSourceId()); if (controller != null) { - List cardsFromTopLibrary = controller.getLibrary().getTopCards(game, 5); - Cards cards = new CardsImpl(Zone.LIBRARY); - for (Card card : cardsFromTopLibrary) { - cards.add(card); - } - controller.lookAtCards(mageObject.getName(), cards, game); + Cards cardsFromLibrary = new CardsImpl(Zone.LIBRARY, controller.getLibrary().getTopCards(game, 5)); + controller.lookAtCards(mageObject.getIdName(), cardsFromLibrary, game); int max = 0; for (UUID playerId : controller.getInRange()) { FilterCreaturePermanent filter = new FilterCreaturePermanent(); @@ -111,22 +105,13 @@ class AdviceFromTheFaeEffect extends OneShotEffect { } } } - if (game.getBattlefield().countAll(new FilterControlledCreaturePermanent(), controller.getId(), game) > max) { - TargetCard target = new TargetCard(2, Zone.LIBRARY, new FilterCard()); - if (controller.choose(Outcome.DrawCard, cards, target, game)) { - controller.moveCardToHandWithInfo(game.getCard(target.getFirstTarget()), source.getSourceId(), game, Zone.LIBRARY); - cards.remove(game.getCard(target.getFirstTarget())); - controller.moveCardToHandWithInfo(game.getCard(target.getTargets().get(1)), source.getSourceId(), game, Zone.LIBRARY); - cards.remove(game.getCard(target.getTargets().get(1))); - } - } else { - TargetCard target = new TargetCard(1, Zone.LIBRARY, new FilterCard()); - if (controller.choose(Outcome.DrawCard, cards, target, game)) { - controller.moveCardToHandWithInfo(game.getCard(target.getFirstTarget()), source.getSourceId(), game, Zone.LIBRARY); - cards.remove(game.getCard(target.getFirstTarget())); - } + boolean moreCreatures = game.getBattlefield().countAll(new FilterControlledCreaturePermanent(), controller.getId(), game) > max; + TargetCard target = new TargetCard(moreCreatures ? 2 : 1, Zone.LIBRARY, new FilterCard()); + if (controller.choose(Outcome.DrawCard, cardsFromLibrary, target, game)) { + cardsFromLibrary.removeAll(target.getTargets()); + controller.moveCards(new CardsImpl(target.getTargets()), null, Zone.HAND, source, game); } - controller.putCardsOnBottomOfLibrary(cards, game, source, true); + controller.putCardsOnBottomOfLibrary(cardsFromLibrary, game, source, true); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/shadowmoor/BarrentonCragtreads.java b/Mage.Sets/src/mage/sets/shadowmoor/BarrentonCragtreads.java index ee6dbb6cab3..ec7034d8362 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/BarrentonCragtreads.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/BarrentonCragtreads.java @@ -30,13 +30,12 @@ package mage.sets.shadowmoor; import java.util.UUID; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.ColorPredicate; @@ -62,7 +61,7 @@ public class BarrentonCragtreads extends CardImpl { this.toughness = new MageInt(3); // Barrenton Cragtreads can't be blocked by red creatures. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } diff --git a/Mage.Sets/src/mage/sets/shadowmoor/DramaticEntrance.java b/Mage.Sets/src/mage/sets/shadowmoor/DramaticEntrance.java index c3c0846ab5d..cf1822e48df 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/DramaticEntrance.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/DramaticEntrance.java @@ -29,20 +29,12 @@ package mage.sets.shadowmoor; import java.util.UUID; import mage.ObjectColor; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.filter.predicate.mageobject.ColorPredicate; -import mage.game.Game; -import mage.players.Player; -import mage.target.Target; -import mage.target.common.TargetCardInHand; /** * @@ -50,13 +42,18 @@ import mage.target.common.TargetCardInHand; */ public class DramaticEntrance extends CardImpl { + private static final FilterCreatureCard filter = new FilterCreatureCard("a green creature card"); + + static { + filter.add(new ColorPredicate(ObjectColor.GREEN)); + } + public DramaticEntrance(UUID ownerId) { super(ownerId, 111, "Dramatic Entrance", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{3}{G}{G}"); this.expansionSetCode = "SHM"; - // You may put a green creature card from your hand onto the battlefield. - this.getSpellAbility().addEffect(new DramaticEntranceEffect()); + this.getSpellAbility().addEffect(new PutPermanentOnBattlefieldEffect(filter)); } @@ -69,47 +66,3 @@ public class DramaticEntrance extends CardImpl { return new DramaticEntrance(this); } } - -class DramaticEntranceEffect extends OneShotEffect { - - private static final FilterCreatureCard filter = new FilterCreatureCard("a green creature card from your hand"); - - static { - filter.add(new ColorPredicate(ObjectColor.GREEN)); - } - - public DramaticEntranceEffect() { - super(Outcome.PutCreatureInPlay); - this.staticText = "You may put a green creature card from your hand onto the battlefield"; - } - - public DramaticEntranceEffect(final DramaticEntranceEffect effect) { - super(effect); - } - - @Override - public DramaticEntranceEffect copy() { - return new DramaticEntranceEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - if (controller.getHand().count(filter, game) > 0) { - if (controller.chooseUse(Outcome.PutCreatureInPlay, - "Put a green creature card onto the battlefield?", source, game)) { - Target target = new TargetCardInHand(filter); - if (controller.chooseTarget(outcome, target, source, game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } - } - } - } - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/shadowmoor/ElsewhereFlask.java b/Mage.Sets/src/mage/sets/shadowmoor/ElsewhereFlask.java index 4210b34092a..ae8d945447e 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/ElsewhereFlask.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/ElsewhereFlask.java @@ -29,8 +29,6 @@ package mage.sets.shadowmoor; import java.util.Set; import java.util.UUID; - -import mage.constants.*; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; @@ -38,9 +36,20 @@ import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.effects.ContinuousEffectImpl; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; -import mage.abilities.mana.*; +import mage.abilities.mana.BlackManaAbility; +import mage.abilities.mana.BlueManaAbility; +import mage.abilities.mana.GreenManaAbility; +import mage.abilities.mana.RedManaAbility; +import mage.abilities.mana.WhiteManaAbility; import mage.cards.CardImpl; import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; import mage.filter.common.FilterControlledLandPermanent; import mage.filter.common.FilterControlledPermanent; import mage.game.Game; @@ -95,7 +104,7 @@ class ElsewhereFlaskEffect extends OneShotEffect { Player player = game.getPlayer(source.getControllerId()); if (player != null) { ChoiceImpl choices = new ChoiceImpl(true); - Set choicesSet = choices.getChoices(); + Set choicesSet = choices.getChoices(); choicesSet.add("Forest"); choicesSet.add("Plains"); choicesSet.add("Mountain"); diff --git a/Mage.Sets/src/mage/sets/shadowmoor/ImpromptuRaid.java b/Mage.Sets/src/mage/sets/shadowmoor/ImpromptuRaid.java index 95e71547286..690b42690dd 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/ImpromptuRaid.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/ImpromptuRaid.java @@ -52,6 +52,7 @@ import mage.filter.FilterCard; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.targetpointer.FixedTarget; @@ -117,16 +118,19 @@ class ImpromptuRaidEffect extends OneShotEffect { return true; } if (controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId())) { - ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn); - effect.setTargetPointer(new FixedTarget(card.getId())); - game.addEffect(effect, source); - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect(); - sacrificeEffect.setTargetPointer(new FixedTarget(card.getId())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + Permanent permanent = game.getPermanent(card.getId()); + if (permanent != null) { + ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn); + effect.setTargetPointer(new FixedTarget(permanent, game)); + game.addEffect(effect, source); + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("", source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } return true; } } diff --git a/Mage.Sets/src/mage/sets/shadowmoor/LureboundScarecrow.java b/Mage.Sets/src/mage/sets/shadowmoor/LureboundScarecrow.java index 0ee0aabd1b4..fc6cd8c6cef 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/LureboundScarecrow.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/LureboundScarecrow.java @@ -64,7 +64,7 @@ public class LureboundScarecrow extends CardImpl { // As Lurebound Scarecrow enters the battlefield, choose a color. this.addAbility(new AsEntersBattlefieldAbility(new LureboundScarecrowChooseColorEffect())); - + // When you control no permanents of the chosen color, sacrifice Lurebound Scarecrow. this.addAbility(new LureboundScarecrowTriggeredAbility()); } @@ -80,7 +80,7 @@ public class LureboundScarecrow extends CardImpl { } class LureboundScarecrowChooseColorEffect extends OneShotEffect { - + public LureboundScarecrowChooseColorEffect() { super(Outcome.BoostCreature); staticText = "choose a color"; @@ -110,11 +110,11 @@ class LureboundScarecrowChooseColorEffect extends OneShotEffect { public LureboundScarecrowChooseColorEffect copy() { return new LureboundScarecrowChooseColorEffect(this); } - + } class LureboundScarecrowTriggeredAbility extends StateTriggeredAbility { - + private static final String staticText = "When you control no permanents of the chosen color, sacrifice {this}."; public LureboundScarecrowTriggeredAbility() { @@ -127,16 +127,17 @@ class LureboundScarecrowTriggeredAbility extends StateTriggeredAbility { @Override public boolean checkTrigger(GameEvent event, Game game) { - if (event.getType() == GameEvent.EventType.ZONE_CHANGE || event.getType() == GameEvent.EventType.LOST_CONTROL + if (event.getType() == GameEvent.EventType.ZONE_CHANGE || event.getType() == GameEvent.EventType.LOST_CONTROL || event.getType() == GameEvent.EventType.COLOR_CHANGED || event.getType() == GameEvent.EventType.SPELL_CAST) { Card card = game.getCard(this.getSourceId()); if (card != null) { ObjectColor color = (ObjectColor) game.getState().getValue(card.getId() + "_color"); if (color != null) { - for (Permanent perm: game.getBattlefield().getAllActivePermanents(controllerId)) { - if (perm.getColor(game).contains(color)) + for (Permanent perm : game.getBattlefield().getAllActivePermanents(controllerId)) { + if (perm.getColor(game).contains(color)) { return false; + } } return true; } diff --git a/Mage.Sets/src/mage/sets/shadowmoor/ManaforgeCinder.java b/Mage.Sets/src/mage/sets/shadowmoor/ManaforgeCinder.java index 46d33e9ab6c..c650a49008d 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/ManaforgeCinder.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/ManaforgeCinder.java @@ -105,7 +105,7 @@ class ManaforgeCinderManaEffect extends OneShotEffect { manaChoice.setMessage("Select black or red mana to add to your mana pool"); Mana mana = new Mana(); while (!controller.choose(Outcome.Benefit, manaChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/shadowmoor/PlagueOfVermin.java b/Mage.Sets/src/mage/sets/shadowmoor/PlagueOfVermin.java index 4bf3c7225d6..a494bd2cb7e 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/PlagueOfVermin.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/PlagueOfVermin.java @@ -93,17 +93,17 @@ class PlagueOfVerminEffect extends OneShotEffect { int totalPaidLife; if (controller != null) { PlayerList playerList = game.getState().getPlayerList().copy(); - while (!playerList.get().equals(source.getControllerId()) && controller.isInGame()) { + while (!playerList.get().equals(source.getControllerId()) && controller.canRespond()) { playerList.getNext(); } Player currentPlayer = game.getPlayer(playerList.get()); UUID firstInactivePlayer = null; - while (controller.isInGame()) { + while (controller.canRespond()) { if (firstInactivePlayer == null) { firstInactivePlayer = currentPlayer.getId(); } - if (currentPlayer != null && currentPlayer.isInGame() && controller.getInRange().contains(currentPlayer.getId())) { + if (currentPlayer != null && currentPlayer.canRespond() && controller.getInRange().contains(currentPlayer.getId())) { currentLifePaid = 0; totalPaidLife = 0; if (currentPlayer.chooseUse(Outcome.AIDontUseIt, "Pay life?", source, game)) { diff --git a/Mage.Sets/src/mage/sets/shadowmoor/TwilightShepherd.java b/Mage.Sets/src/mage/sets/shadowmoor/TwilightShepherd.java index 09f251c2d9c..94fc3a43426 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/TwilightShepherd.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/TwilightShepherd.java @@ -30,19 +30,23 @@ package mage.sets.shadowmoor; import java.util.Set; import java.util.UUID; import mage.MageInt; +import mage.MageObjectReference; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.keyword.FlyingAbility; -import mage.abilities.keyword.VigilanceAbility; import mage.abilities.keyword.PersistAbility; +import mage.abilities.keyword.VigilanceAbility; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.game.Game; +import mage.players.Player; import mage.watchers.common.CardsPutIntoGraveyardWatcher; /** @@ -104,17 +108,22 @@ class TwilightShepherdEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { CardsPutIntoGraveyardWatcher watcher = (CardsPutIntoGraveyardWatcher) game.getState().getWatchers().get("CardsPutIntoGraveyardWatcher"); - if (watcher != null) { - Set cardsInGraveyardId = watcher.getCardsPutToGraveyardFromBattlefield(); - for (UUID cardId : cardsInGraveyardId) { - Card card = game.getCard(cardId); - if (card != null - && card.getOwnerId().equals(source.getControllerId()) - && game.getState().getZone(card.getId()).match(Zone.GRAVEYARD)) { - applied = card.moveToZone(Zone.HAND, source.getSourceId(), game, false); + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null && watcher != null) { + Set cardsInGraveyard = watcher.getCardsPutToGraveyardFromBattlefield(); + Cards cardsToHand = new CardsImpl(); + for (MageObjectReference mor : cardsInGraveyard) { + if (game.getState().getZoneChangeCounter(mor.getSourceId()) == mor.getZoneChangeCounter()) { + Card card = game.getCard(mor.getSourceId()); + if (card != null + && card.getOwnerId().equals(source.getControllerId())) { + cardsToHand.add(card); + } } } + controller.moveCards(cardsToHand, Zone.GRAVEYARD, Zone.HAND, source, game); + return true; } - return applied; + return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/shadowmoor/WanderbrineRootcutters.java b/Mage.Sets/src/mage/sets/shadowmoor/WanderbrineRootcutters.java index 7752b605606..03135e41add 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/WanderbrineRootcutters.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/WanderbrineRootcutters.java @@ -30,13 +30,12 @@ package mage.sets.shadowmoor; import java.util.UUID; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.ColorPredicate; @@ -45,9 +44,9 @@ import mage.filter.predicate.mageobject.ColorPredicate; * @author jeffwadsworth */ public class WanderbrineRootcutters extends CardImpl { - + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("green creatures"); - + static { filter.add(new ColorPredicate(ObjectColor.GREEN)); } @@ -61,8 +60,8 @@ public class WanderbrineRootcutters extends CardImpl { this.toughness = new MageInt(3); // Wanderbrine Rootcutters can't be blocked by green creatures. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); - + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + } public WanderbrineRootcutters(final WanderbrineRootcutters card) { diff --git a/Mage.Sets/src/mage/sets/shadowmoor/WheelOfSunAndMoon.java b/Mage.Sets/src/mage/sets/shadowmoor/WheelOfSunAndMoon.java index d028787067d..e41ad1b2148 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/WheelOfSunAndMoon.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/WheelOfSunAndMoon.java @@ -102,7 +102,7 @@ class WheelOfSunAndMoonEffect extends ReplacementEffectImpl { public boolean checksEventType(GameEvent event, Game game) { return event.getType() == EventType.ZONE_CHANGE; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { ZoneChangeEvent zEvent = (ZoneChangeEvent) event; @@ -110,8 +110,8 @@ class WheelOfSunAndMoonEffect extends ReplacementEffectImpl { Card card = game.getCard(event.getTargetId()); if (card != null) { Permanent enchantment = game.getPermanent(source.getSourceId()); - if (enchantment != null && enchantment.getAttachedTo() != null && - card.getOwnerId().equals(enchantment.getAttachedTo())) { + if (enchantment != null && enchantment.getAttachedTo() != null + && card.getOwnerId().equals(enchantment.getAttachedTo())) { return true; } } @@ -128,7 +128,7 @@ class WheelOfSunAndMoonEffect extends ReplacementEffectImpl { if (card != null) { ZoneChangeEvent zEvent = (ZoneChangeEvent) event; Cards cards = new CardsImpl(card); - controller.revealCards(sourceObject.getName(), cards, game); + controller.revealCards(sourceObject.getIdName(), cards, game); controller.moveCardToLibraryWithInfo(card, source.getSourceId(), game, zEvent.getFromZone(), false, true); return true; } diff --git a/Mage.Sets/src/mage/sets/shadowmoor/WiltLeafLiege.java b/Mage.Sets/src/mage/sets/shadowmoor/WiltLeafLiege.java index 373f7aaa411..a8c72991aab 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/WiltLeafLiege.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/WiltLeafLiege.java @@ -30,27 +30,18 @@ package mage.sets.shadowmoor; import java.util.UUID; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.dynamicvalue.common.StaticValue; -import mage.abilities.effects.ReplacementEffectImpl; +import mage.abilities.effects.common.DiscardOntoBattlefieldEffect; import mage.abilities.effects.common.continuous.BoostAllEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.TargetController; import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.ColorPredicate; import mage.filter.predicate.permanent.ControllerPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.ZoneChangeEvent; -import mage.game.stack.StackObject; -import mage.players.Player; /** * @@ -66,7 +57,7 @@ public class WiltLeafLiege extends CardImpl { filterWhite.add(new ColorPredicate(ObjectColor.WHITE)); filterWhite.add(new ControllerPredicate(TargetController.YOU)); } - + public WiltLeafLiege(UUID ownerId) { super(ownerId, 245, "Wilt-Leaf Liege", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{G/W}{G/W}{G/W}"); this.expansionSetCode = "SHM"; @@ -77,11 +68,11 @@ public class WiltLeafLiege extends CardImpl { this.toughness = new MageInt(4); // Other green creatures you control get +1/+1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(new StaticValue(1), new StaticValue(1), Duration.WhileOnBattlefield, filterGreen, true))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filterGreen, true))); // Other white creatures you control get +1/+1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(new StaticValue(1), new StaticValue(1), Duration.WhileOnBattlefield, filterWhite, true))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(1, 1, Duration.WhileOnBattlefield, filterWhite, true))); // If a spell or ability an opponent controls causes you to discard Wilt-Leaf Liege, put it onto the battlefield instead of putting it into your graveyard. - this.addAbility(new SimpleStaticAbility(Zone.HAND, new WiltLeafLiegeEffect())); + this.addAbility(new SimpleStaticAbility(Zone.HAND, new DiscardOntoBattlefieldEffect())); } public WiltLeafLiege(final WiltLeafLiege card) { @@ -93,58 +84,3 @@ public class WiltLeafLiege extends CardImpl { return new WiltLeafLiege(this); } } - -class WiltLeafLiegeEffect extends ReplacementEffectImpl { - - public WiltLeafLiegeEffect() { - super(Duration.EndOfGame, Outcome.PutCardInPlay); - staticText = "If a spell or ability an opponent controls causes you to discard {this}, put it onto the battlefield instead of putting it into your graveyard"; - } - - public WiltLeafLiegeEffect(final WiltLeafLiegeEffect effect) { - super(effect); - } - - @Override - public WiltLeafLiegeEffect copy() { - return new WiltLeafLiegeEffect(this); - } - - @Override - public boolean checksEventType(GameEvent event, Game game) { - return event.getType().equals(GameEvent.EventType.ZONE_CHANGE); - } - - @Override - public boolean applies(GameEvent event, Ability source, Game game) { - if (event.getTargetId().equals(source.getSourceId())) { - ZoneChangeEvent zcEvent = (ZoneChangeEvent) event; - if (zcEvent.getFromZone() == Zone.HAND && zcEvent.getToZone() == Zone.GRAVEYARD) { - StackObject spell = game.getStack().getStackObject(event.getSourceId()); - if (spell != null && game.getOpponents(source.getControllerId()).contains(spell.getControllerId())) { - return true; - } - } - } - return false; - } - - @Override - public boolean apply(Game game, Ability source) { - Card card = game.getCard(source.getSourceId()); - if (card != null) { - Player player = game.getPlayer(card.getOwnerId()); - if (player != null) { - card.putOntoBattlefield(game, Zone.HAND, source.getSourceId(), player.getId()); - return true; - } - } - return false; - } - - @Override - public boolean replaceEvent(GameEvent event, Ability source, Game game) { - return apply(game, source); - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java b/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java index 505fab69390..bc3e1f3d06c 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java @@ -31,9 +31,9 @@ import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.BlocksOrBecomesBlockedByCreatureTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.keyword.WitherAbility; import mage.cards.CardImpl; diff --git a/Mage.Sets/src/mage/sets/shardsofalara/AdNauseam.java b/Mage.Sets/src/mage/sets/shardsofalara/AdNauseam.java index 80ee8b645bf..23fd96ae723 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/AdNauseam.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/AdNauseam.java @@ -50,7 +50,6 @@ public class AdNauseam extends CardImpl { super(ownerId, 63, "Ad Nauseam", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{3}{B}{B}"); this.expansionSetCode = "ALA"; - // Reveal the top card of your library and put that card into your hand. You lose life equal to its converted mana cost. You may repeat this process any number of times. this.getSpellAbility().addEffect(new AdNauseamEffect()); } @@ -92,12 +91,12 @@ class AdNauseamEffect extends OneShotEffect { while (controller.chooseUse(outcome, message, source, game) && controller.getLibrary().size() > 0) { Card card = controller.getLibrary().removeFromTop(game); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); int cmc = card.getManaCost().convertedManaCost(); if (cmc > 0) { controller.loseLife(cmc, game); } - controller.revealCards(new StringBuilder(sourceCard.getName()).append(" put into hand").toString(), new CardsImpl(card), game); + controller.revealCards(sourceCard.getIdName() + " put into hand", new CardsImpl(card), game); } } return true; diff --git a/Mage.Sets/src/mage/sets/shardsofalara/ArchdemonOfUnx.java b/Mage.Sets/src/mage/sets/shardsofalara/ArchdemonOfUnx.java index 9d490cb6f31..4ab86cd5878 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/ArchdemonOfUnx.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/ArchdemonOfUnx.java @@ -51,10 +51,11 @@ import mage.game.permanent.token.ZombieToken; public class ArchdemonOfUnx extends CardImpl { private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("non-Zombie creature"); + static { filter.add(Predicates.not(new SubtypePredicate("Zombie"))); } - + public ArchdemonOfUnx(UUID ownerId) { super(ownerId, 64, "Archdemon of Unx", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{B}{B}"); this.expansionSetCode = "ALA"; @@ -69,7 +70,7 @@ public class ArchdemonOfUnx extends CardImpl { this.addAbility(TrampleAbility.getInstance()); // At the beginning of your upkeep, sacrifice a non-Zombie creature, then put a 2/2 black Zombie creature token onto the battlefield. Ability ability = new BeginningOfUpkeepTriggeredAbility(new SacrificeControllerEffect(filter, 1, ""), TargetController.YOU, false); - ability.addEffect(new CreateTokenEffect(new ZombieToken("ALA"))); + ability.addEffect(new CreateTokenEffect(new ZombieToken())); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/shardsofalara/CruelUltimatum.java b/Mage.Sets/src/mage/sets/shardsofalara/CruelUltimatum.java index 0e4a703fca4..6e853e8797b 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/CruelUltimatum.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/CruelUltimatum.java @@ -58,7 +58,6 @@ public class CruelUltimatum extends CardImpl { super(ownerId, 164, "Cruel Ultimatum", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{U}{U}{B}{B}{B}{R}{R}"); this.expansionSetCode = "ALA"; - // Target opponent sacrifices a creature, discards three cards, then loses 5 life. // You return a creature card from your graveyard to your hand, draw three cards, then gain 5 life. this.getSpellAbility().addTarget(new TargetOpponent()); @@ -99,17 +98,17 @@ class CruelUltimatumEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller == null) { return false; } TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard")); - if (target.canChoose(source.getSourceId(), source.getControllerId(), game) && player.choose(Outcome.ReturnToHand, target, source.getSourceId(), game)) { + if (target.canChoose(source.getSourceId(), source.getControllerId(), game) && controller.choose(Outcome.ReturnToHand, target, source.getSourceId(), game)) { Card card = game.getCard(target.getFirstTarget()); if (card == null) { return false; } - return player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + controller.moveCards(card, null, Zone.HAND, source, game); } return true; } diff --git a/Mage.Sets/src/mage/sets/shardsofalara/DragonFodder.java b/Mage.Sets/src/mage/sets/shardsofalara/DragonFodder.java index c1b33de6731..3e6a4f5989e 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/DragonFodder.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/DragonFodder.java @@ -28,10 +28,10 @@ package mage.sets.shardsofalara; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.permanent.token.GoblinToken; /** diff --git a/Mage.Sets/src/mage/sets/shardsofalara/GiftOfTheGargantuan.java b/Mage.Sets/src/mage/sets/shardsofalara/GiftOfTheGargantuan.java index 68c2b74275f..d9ad98c8b73 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/GiftOfTheGargantuan.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/GiftOfTheGargantuan.java @@ -141,7 +141,7 @@ class GiftOfTheGargantuanEffect extends OneShotEffect { } TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/shardsofalara/TidehollowSculler.java b/Mage.Sets/src/mage/sets/shardsofalara/TidehollowSculler.java index f0a2e2f5bd3..e667e1d7cd6 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/TidehollowSculler.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/TidehollowSculler.java @@ -69,9 +69,8 @@ public class TidehollowSculler extends CardImpl { ability.addTarget(new TargetOpponent()); this.addAbility(ability); - // When Tidehollow Sculler leaves the battlefield, return the exiled card to its owner's hand. - this.addAbility(new LeavesBattlefieldTriggeredAbility(new TidehollowScullerLeaveEffect(), false )); + this.addAbility(new LeavesBattlefieldTriggeredAbility(new TidehollowScullerLeaveEffect(), false)); } public TidehollowSculler(final TidehollowSculler card) { @@ -124,7 +123,6 @@ class TidehollowScullerExileEffect extends OneShotEffect { return false; } - } class TidehollowScullerLeaveEffect extends OneShotEffect { @@ -148,17 +146,13 @@ class TidehollowScullerLeaveEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = source.getSourceObject(game); if (controller != null && sourceObject != null) { - int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() -1; + int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() - 1; ExileZone exZone = game.getExile().getExileZone(CardUtil.getExileZoneId(game, source.getSourceId(), zoneChangeCounter)); if (exZone != null) { - for (Card card : exZone.getCards(game)) { - if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.EXILED); - } - } - } + controller.moveCards(exZone, null, Zone.HAND, source, game); + } return true; } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/shardsofalara/TortoiseFormation.java b/Mage.Sets/src/mage/sets/shardsofalara/TortoiseFormation.java index 3e39a14a239..b82bcb45747 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/TortoiseFormation.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/TortoiseFormation.java @@ -1,63 +1,62 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.shardsofalara; - -import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; -import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; -import mage.abilities.keyword.ShroudAbility; -import mage.cards.CardImpl; -import mage.filter.common.FilterControlledCreaturePermanent; -import mage.filter.common.FilterCreaturePermanent; - -/** - * - * @author North - */ -public class TortoiseFormation extends CardImpl { - - public TortoiseFormation(UUID ownerId) { - super(ownerId, 61, "Tortoise Formation", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{U}"); - this.expansionSetCode = "ALA"; - - - // Creatures you control gain shroud until end of turn. - this.getSpellAbility().addEffect(new GainAbilityControlledEffect(ShroudAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent())); - } - - public TortoiseFormation(final TortoiseFormation card) { - super(card); - } - - @Override - public TortoiseFormation copy() { - return new TortoiseFormation(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.shardsofalara; + +import java.util.UUID; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author North + */ +public class TortoiseFormation extends CardImpl { + + public TortoiseFormation(UUID ownerId) { + super(ownerId, 61, "Tortoise Formation", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{U}"); + this.expansionSetCode = "ALA"; + + + // Creatures you control gain shroud until end of turn. + this.getSpellAbility().addEffect(new GainAbilityControlledEffect(ShroudAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent())); + } + + public TortoiseFormation(final TortoiseFormation card) { + super(card); + } + + @Override + public TortoiseFormation copy() { + return new TortoiseFormation(this); + } +} diff --git a/Mage.Sets/src/mage/sets/shardsofalara/VeinDrinker.java b/Mage.Sets/src/mage/sets/shardsofalara/VeinDrinker.java index 3248596ce07..abe026812b6 100644 --- a/Mage.Sets/src/mage/sets/shardsofalara/VeinDrinker.java +++ b/Mage.Sets/src/mage/sets/shardsofalara/VeinDrinker.java @@ -29,24 +29,20 @@ package mage.sets.shardsofalara; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.Mode; import mage.abilities.common.DiesAndDealtDamageThisTurnTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; -import mage.abilities.effects.OneShotEffect; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageEachOtherEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; -import mage.constants.Outcome; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; import mage.counters.CounterType; -import mage.game.Game; -import mage.game.permanent.Permanent; import mage.target.common.TargetCreaturePermanent; /** @@ -66,7 +62,7 @@ public class VeinDrinker extends CardImpl { // Flying this.addAbility(FlyingAbility.getInstance()); // {R}, {tap}: Vein Drinker deals damage equal to its power to target creature. That creature deals damage equal to its power to Vein Drinker. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new VeinDrinkerEffect(), new ManaCostsImpl("{R}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEachOtherEffect(), new ManaCostsImpl("{R}")); ability.addCost(new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); @@ -83,39 +79,3 @@ public class VeinDrinker extends CardImpl { return new VeinDrinker(this); } } - -class VeinDrinkerEffect extends OneShotEffect { - - public VeinDrinkerEffect() { - super(Outcome.Damage); - } - - public VeinDrinkerEffect(final VeinDrinkerEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent sourceCreature = game.getPermanent(source.getSourceId()); - Permanent targetCreature = game.getPermanent(source.getTargets().get(0).getFirstTarget()); - if (sourceCreature != null && targetCreature != null) { - if (sourceCreature.getCardType().contains(CardType.CREATURE) && targetCreature.getCardType().contains(CardType.CREATURE)) { - sourceCreature.damage(targetCreature.getPower().getValue(), targetCreature.getId(), game, false, true); - targetCreature.damage(sourceCreature.getPower().getValue(), sourceCreature.getId(), game, false, true); - return true; - } - } - return false; - } - - @Override - public VeinDrinkerEffect copy() { - return new VeinDrinkerEffect(this); - } - - @Override - public String getText(Mode mode) { - return "{this} deals damage equal to its power to target creature. That creature deals damage equal to its power to {this}"; - } - -} diff --git a/Mage.Sets/src/mage/sets/sorinvstibalt/LavabornMuse.java b/Mage.Sets/src/mage/sets/sorinvstibalt/LavabornMuse.java index 03353d0dbf7..ca767c08246 100644 --- a/Mage.Sets/src/mage/sets/sorinvstibalt/LavabornMuse.java +++ b/Mage.Sets/src/mage/sets/sorinvstibalt/LavabornMuse.java @@ -58,9 +58,8 @@ public class LavabornMuse extends CardImpl { // At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, Lavaborn Muse deals 3 damage to him or her. this.addAbility(new ConditionalTriggeredAbility( new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageTargetEffect(3), TargetController.OPPONENT, false, true), - new CardsInActivePlayersHandCondition(), - "At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, {this} deals 3 damage to him or her.", - false)); + new CardsInActivePlayersHandCondition(), + "At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, {this} deals 3 damage to him or her.")); } public LavabornMuse(final LavabornMuse card) { @@ -83,4 +82,3 @@ class CardsInActivePlayersHandCondition implements Condition { return player != null && player.getHand().size() <= 2; } } - diff --git a/Mage.Sets/src/mage/sets/speedvscunning/AquamorphEntity.java b/Mage.Sets/src/mage/sets/speedvscunning/AquamorphEntity.java index be0377d3d78..803b119ff50 100644 --- a/Mage.Sets/src/mage/sets/speedvscunning/AquamorphEntity.java +++ b/Mage.Sets/src/mage/sets/speedvscunning/AquamorphEntity.java @@ -145,7 +145,7 @@ class AquamorphEntityReplacementEffect extends ReplacementEffectImpl { if (controller != null) { while(!choice.isChosen()) { controller.choose(Outcome.Neutral, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/starter1999/Undo.java b/Mage.Sets/src/mage/sets/starter1999/Undo.java new file mode 100644 index 00000000000..61d44673f30 --- /dev/null +++ b/Mage.Sets/src/mage/sets/starter1999/Undo.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.starter1999; + +import java.util.UUID; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Undo extends CardImpl { + + public Undo(UUID ownerId) { + super(ownerId, 58, "Undo", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{1}{U}{U}"); + this.expansionSetCode = "S99"; + + // Return two target creatures to their owners' hands. + this.getSpellAbility().addEffect(new ReturnToHandTargetEffect()); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(2)); + } + + public Undo(final Undo card) { + super(card); + } + + @Override + public Undo copy() { + return new Undo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/Awakening.java b/Mage.Sets/src/mage/sets/stronghold/Awakening.java new file mode 100644 index 00000000000..51e8196e645 --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/Awakening.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.common.UntapAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; + +/** + * + * @author LevelX2 + */ +public class Awakening extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("creatures and lands"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND) + )); + } + + public Awakening(UUID ownerId) { + super(ownerId, 51, "Awakening", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}{G}"); + this.expansionSetCode = "STH"; + + // At the beginning of each upkeep, untap all creatures and lands. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new UntapAllEffect(filter), TargetController.ANY, false)); + } + + public Awakening(final Awakening card) { + super(card); + } + + @Override + public Awakening copy() { + return new Awakening(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/FlowstoneShambler.java b/Mage.Sets/src/mage/sets/stronghold/FlowstoneShambler.java new file mode 100644 index 00000000000..b64a081c058 --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/FlowstoneShambler.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class FlowstoneShambler extends mage.sets.ninthedition.FlowstoneShambler { + + public FlowstoneShambler(UUID ownerId) { + super(ownerId); + this.cardNumber = 86; + this.expansionSetCode = "STH"; + } + + public FlowstoneShambler(final FlowstoneShambler card) { + super(card); + } + + @Override + public FlowstoneShambler copy() { + return new FlowstoneShambler(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/Heartstone.java b/Mage.Sets/src/mage/sets/stronghold/Heartstone.java index e30efda2bc9..0d530dfacd3 100644 --- a/Mage.Sets/src/mage/sets/stronghold/Heartstone.java +++ b/Mage.Sets/src/mage/sets/stronghold/Heartstone.java @@ -25,28 +25,27 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.stronghold; +package mage.sets.stronghold; - import java.util.LinkedHashSet; - import java.util.Set; - import java.util.UUID; - import mage.Mana; - import mage.abilities.Ability; - import mage.abilities.common.SimpleStaticAbility; - import mage.abilities.effects.common.cost.CostModificationEffectImpl; - import mage.cards.CardImpl; - import mage.constants.AbilityType; - import mage.constants.CardType; - import mage.constants.CostModificationType; - import mage.constants.Duration; - import mage.constants.Outcome; - import mage.constants.Rarity; - import mage.constants.Zone; - import mage.filter.common.FilterCreaturePermanent; - import mage.game.Game; - import mage.game.permanent.Permanent; - import mage.players.Player; - import mage.util.CardUtil; +import java.util.UUID; +import mage.Mana; +import mage.abilities.Ability; +import mage.abilities.ActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.cost.CostModificationEffectImpl; +import mage.cards.CardImpl; +import mage.constants.AbilityType; +import mage.constants.CardType; +import mage.constants.CostModificationType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.util.CardUtil; /** * @@ -89,19 +88,20 @@ class HeartstoneEffect extends CostModificationEffectImpl { @Override public boolean apply(Game game, Ability source, Ability abilityToModify) { Player controller = game.getPlayer(abilityToModify.getControllerId()); - if (controller != null){ + if (controller != null) { Mana mana = abilityToModify.getManaCostsToPay().getMana(); - if (mana.getColorless() > 1){ - CardUtil.reduceCost(abilityToModify, 1); + if (mana.count() > 1 && mana.getColorless() > 0) { + CardUtil.reduceCost(abilityToModify, 1); } return true; } - return false; + return false; } @Override public boolean applies(Ability abilityToModify, Ability source, Game game) { - if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED)) { + if (abilityToModify.getAbilityType().equals(AbilityType.ACTIVATED) + || (abilityToModify.getAbilityType().equals(AbilityType.MANA) && (abilityToModify instanceof ActivatedAbility))) { // Activated abilities of creatures Permanent permanent = game.getPermanent(abilityToModify.getSourceId()); if (permanent != null && filter.match(permanent, source.getSourceId(), source.getControllerId(), game)) { diff --git a/Mage.Sets/src/mage/sets/stronghold/MindGames.java b/Mage.Sets/src/mage/sets/stronghold/MindGames.java new file mode 100644 index 00000000000..4c8062a91ee --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/MindGames.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.abilities.effects.common.TapTargetEffect; +import mage.abilities.keyword.BuybackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class MindGames extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("artifact, creature, or land"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new CardTypePredicate(CardType.CREATURE), + new CardTypePredicate(CardType.LAND))); + } + + public MindGames(UUID ownerId) { + super(ownerId, 38, "Mind Games", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{U}"); + this.expansionSetCode = "STH"; + + // Buyback {2}{U} + this.addAbility(new BuybackAbility("{3}")); + + // Tap target artifact, creature, or land. + this.getSpellAbility().addEffect(new TapTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent(filter)); + } + + public MindGames(final MindGames card) { + super(card); + } + + @Override + public MindGames copy() { + return new MindGames(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/MoggInfestation.java b/Mage.Sets/src/mage/sets/stronghold/MoggInfestation.java index b408d3a3d5a..3082cf32101 100644 --- a/Mage.Sets/src/mage/sets/stronghold/MoggInfestation.java +++ b/Mage.Sets/src/mage/sets/stronghold/MoggInfestation.java @@ -31,7 +31,6 @@ import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.Effect; import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.effects.common.CreateTokenTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; @@ -83,14 +82,14 @@ class MoggInfestationEffect extends OneShotEffect { @Override public MoggInfestationEffect copy() { - return new MoggInfestationEffect(this); + return new MoggInfestationEffect(this); } @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null && getTargetPointer().getFirst(game, source) != null) { - for (Permanent permanent: game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), getTargetPointer().getFirst(game, source), game)) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), getTargetPointer().getFirst(game, source), game)) { if (permanent.destroy(source.getSourceId(), game, false)) { Effect effect = new CreateTokenTargetEffect(new GoblinToken(), 2); effect.setTargetPointer(getTargetPointer()); diff --git a/Mage.Sets/src/mage/sets/stronghold/MorgueThrull.java b/Mage.Sets/src/mage/sets/stronghold/MorgueThrull.java new file mode 100644 index 00000000000..2a6eff55e7d --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/MorgueThrull.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class MorgueThrull extends CardImpl { + + public MorgueThrull(UUID ownerId) { + super(ownerId, 15, "Morgue Thrull", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "STH"; + this.subtype.add("Thrull"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Sacrifice Morgue Thrull: Put the top three cards of your library into your graveyard. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutTopCardOfLibraryIntoGraveControllerEffect(3), new SacrificeSourceCost())); + } + + public MorgueThrull(final MorgueThrull card) { + super(card); + } + + @Override + public MorgueThrull copy() { + return new MorgueThrull(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/SwordOfTheChosen.java b/Mage.Sets/src/mage/sets/stronghold/SwordOfTheChosen.java new file mode 100644 index 00000000000..960be1ac057 --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/SwordOfTheChosen.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.SupertypePredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class SwordOfTheChosen extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("legendary creature"); + + static { + filter.add(new SupertypePredicate("Legendary")); + } + + public SwordOfTheChosen(UUID ownerId) { + super(ownerId, 135, "Sword of the Chosen", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "STH"; + this.supertype.add("Legendary"); + + // {tap}: Target legendary creature gets +2/+2 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(2, 2, Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public SwordOfTheChosen(final SwordOfTheChosen card) { + super(card); + } + + @Override + public SwordOfTheChosen copy() { + return new SwordOfTheChosen(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/TorturedExistence.java b/Mage.Sets/src/mage/sets/stronghold/TorturedExistence.java new file mode 100644 index 00000000000..8c9bb1aea4f --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/TorturedExistence.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnFromGraveyardToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreatureCard; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author fireshoes + */ +public class TorturedExistence extends CardImpl { + + public TorturedExistence(UUID ownerId) { + super(ownerId, 24, "Tortured Existence", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{B}"); + this.expansionSetCode = "STH"; + + // {B}, Discard a creature card: Return target creature card from your graveyard to your hand. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnFromGraveyardToHandTargetEffect(), new ManaCostsImpl("{B}")); + ability.addCost(new DiscardCardCost(new FilterCreatureCard())); + ability.addTarget(new TargetCardInYourGraveyard(new FilterCreatureCard("creature card from your graveyard"))); + this.addAbility(ability); + } + + public TorturedExistence(final TorturedExistence card) { + super(card); + } + + @Override + public TorturedExistence copy() { + return new TorturedExistence(this); + } +} diff --git a/Mage.Sets/src/mage/sets/stronghold/WarriorAngel.java b/Mage.Sets/src/mage/sets/stronghold/WarriorAngel.java new file mode 100644 index 00000000000..d082d91d324 --- /dev/null +++ b/Mage.Sets/src/mage/sets/stronghold/WarriorAngel.java @@ -0,0 +1,67 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.stronghold; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DealsDamageGainLifeSourceTriggeredAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class WarriorAngel extends CardImpl { + + public WarriorAngel(UUID ownerId) { + super(ownerId, 123, "Warrior Angel", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{W}{W}"); + this.expansionSetCode = "STH"; + this.subtype.add("Angel"); + this.subtype.add("Warrior"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Whenever Warrior Angel deals damage, you gain that much life. + this.addAbility(new DealsDamageGainLifeSourceTriggeredAbility()); + } + + public WarriorAngel(final WarriorAngel card) { + super(card); + } + + @Override + public WarriorAngel copy() { + return new WarriorAngel(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/tempest/Apocalypse.java b/Mage.Sets/src/mage/sets/tempest/Apocalypse.java new file mode 100644 index 00000000000..ec63ce33d58 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/Apocalypse.java @@ -0,0 +1,117 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author markedagain + */ +public class Apocalypse extends CardImpl { + + public Apocalypse(UUID ownerId) { + super(ownerId, 162, "Apocalypse", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{2}{R}{R}{R}"); + this.expansionSetCode = "TMP"; + + // Exile all permanents. You discard your hand. + this.getSpellAbility().addEffect(new ApocalypseExileAllPermanentsEffect()); + this.getSpellAbility().addEffect(new ApocalypseDiscardEffect()); + } + + public Apocalypse(final Apocalypse card) { + super(card); + } + + @Override + public Apocalypse copy() { + return new Apocalypse(this); + } +} +class ApocalypseDiscardEffect extends OneShotEffect { + + public ApocalypseDiscardEffect() { + super(Outcome.Discard); + this.staticText = "Discard your hand"; + } + + public ApocalypseDiscardEffect(final ApocalypseDiscardEffect effect) { + super(effect); + } + + @Override + public ApocalypseDiscardEffect copy() { + return new ApocalypseDiscardEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + if (player != null) { + for (Card card : player.getHand().getCards(game)) { + player.discard(card, source, game); + } + return true; + } + return false; + } +} +class ApocalypseExileAllPermanentsEffect extends OneShotEffect { + + public ApocalypseExileAllPermanentsEffect() { + super(Outcome.Exile); + staticText = "Exile all permanents"; + } + + public ApocalypseExileAllPermanentsEffect(final ApocalypseExileAllPermanentsEffect effect) { + super(effect); + } + + @Override + public ApocalypseExileAllPermanentsEffect copy() { + return new ApocalypseExileAllPermanentsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents()) { + permanent.moveToExile(null, null, source.getSourceId(), game); + } + return true; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/tempest/CommanderGrevenIlVec.java b/Mage.Sets/src/mage/sets/tempest/CommanderGrevenIlVec.java index 1ca56981e19..b7e5293c30a 100644 --- a/Mage.Sets/src/mage/sets/tempest/CommanderGrevenIlVec.java +++ b/Mage.Sets/src/mage/sets/tempest/CommanderGrevenIlVec.java @@ -31,12 +31,11 @@ import java.util.UUID; import mage.constants.CardType; import mage.constants.Rarity; import mage.MageInt; -import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.abilities.keyword.FearAbility; import mage.cards.CardImpl; -import mage.target.common.TargetControlledCreaturePermanent; +import mage.filter.common.FilterCreaturePermanent; /** * @@ -53,10 +52,12 @@ public class CommanderGrevenIlVec extends CardImpl { this.power = new MageInt(7); this.toughness = new MageInt(5); - Ability ability = new EntersBattlefieldTriggeredAbility(new SacrificeTargetEffect(), false); - ability.addTarget(new TargetControlledCreaturePermanent()); - this.addAbility(ability); + + // Fear (This creature can't be blocked except by artifact creatures and/or black creatures.) this.addAbility(FearAbility.getInstance()); + + // When Commander Greven il-Vec enters the battlefield, sacrifice a creature. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterCreaturePermanent(), 1, ""), false)); } public CommanderGrevenIlVec(final CommanderGrevenIlVec card) { diff --git a/Mage.Sets/src/mage/sets/tempest/EnragingLicid.java b/Mage.Sets/src/mage/sets/tempest/EnragingLicid.java new file mode 100644 index 00000000000..9ef2e6899fe --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/EnragingLicid.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.LicidAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author emerald000 + */ +public class EnragingLicid extends CardImpl { + + public EnragingLicid(UUID ownerId) { + super(ownerId, 171, "Enraging Licid", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "TMP"; + this.subtype.add("Licid"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {R}, {tap}: Enraging Licid loses this ability and becomes an Aura enchantment with enchant creature. Attach it to target creature. You may pay {R} to end this effect. + this.addAbility(new LicidAbility(new ColoredManaCost(ColoredManaSymbol.R), new ColoredManaCost(ColoredManaSymbol.R))); + + // Enchanted creature has haste. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(HasteAbility.getInstance(), AttachmentType.AURA))); + } + + public EnragingLicid(final EnragingLicid card) { + super(card); + } + + @Override + public EnragingLicid copy() { + return new EnragingLicid(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/EvincarsJustice.java b/Mage.Sets/src/mage/sets/tempest/EvincarsJustice.java index 8cf233d45c4..15f9c4f91f7 100644 --- a/Mage.Sets/src/mage/sets/tempest/EvincarsJustice.java +++ b/Mage.Sets/src/mage/sets/tempest/EvincarsJustice.java @@ -46,8 +46,9 @@ public class EvincarsJustice extends CardImpl { // Buyback {3} this.addAbility(new BuybackAbility("{3}")); + // Evincar's Justice deals 2 damage to each creature and each player. - this.getSpellAbility().addEffect(new DamageEverythingEffect(2)); + this.getSpellAbility().addEffect(new DamageEverythingEffect(2)); } public EvincarsJustice(final EvincarsJustice card) { diff --git a/Mage.Sets/src/mage/sets/tempest/FlickeringWard.java b/Mage.Sets/src/mage/sets/tempest/FlickeringWard.java new file mode 100644 index 00000000000..d1f89844a74 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/FlickeringWard.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ChooseColorEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.keyword.ProtectionChosenColorAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FlickeringWard extends CardImpl { + + public FlickeringWard(UUID ownerId) { + super(ownerId, 231, "Flickering Ward", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}"); + this.expansionSetCode = "TMP"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Protect)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // As Flickering Ward enters the battlefield, choose a color. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Benefit))); + + // Enchanted creature has protection from the chosen color. This effect doesn't remove Flickering Ward. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ProtectionChosenColorAttachedEffect(true))); + + // {W}: Return Flickering Ward to its owner's hand. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandSourceEffect(), new ManaCostsImpl("{W}"))); + } + + public FlickeringWard(final FlickeringWard card) { + super(card); + } + + @Override + public FlickeringWard copy() { + return new FlickeringWard(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/tempest/Grindstone.java b/Mage.Sets/src/mage/sets/tempest/Grindstone.java index 785046a82be..64654c52cf3 100644 --- a/Mage.Sets/src/mage/sets/tempest/Grindstone.java +++ b/Mage.Sets/src/mage/sets/tempest/Grindstone.java @@ -116,7 +116,7 @@ class GrindstoneEffect extends OneShotEffect { } } targetPlayer.moveCards(cards, Zone.LIBRARY, Zone.GRAVEYARD, source, game); - } while (colorShared && targetPlayer.isInGame()); + } while (colorShared && targetPlayer.canRespond()); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/tempest/HandToHand.java b/Mage.Sets/src/mage/sets/tempest/HandToHand.java new file mode 100644 index 00000000000..0e6ce50ad75 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/HandToHand.java @@ -0,0 +1,118 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.abilities.mana.ManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TurnPhase; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author fireshoes + */ +public class HandToHand extends CardImpl { + + public HandToHand(UUID ownerId) { + super(ownerId, 180, "Hand to Hand", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{R}"); + this.expansionSetCode = "TMP"; + + // During combat, players can't cast instant spells or activate abilities that aren't mana abilities. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new HandToHandEffect())); + } + + public HandToHand(final HandToHand card) { + super(card); + } + + @Override + public HandToHand copy() { + return new HandToHand(this); + } +} + +class HandToHandEffect extends ContinuousRuleModifyingEffectImpl { + + public HandToHandEffect() { + super(Duration.WhileOnBattlefield, Outcome.Detriment); + staticText = "During combat, players can't cast instant spells or activate abilities that aren't mana abilities"; + } + + public HandToHandEffect(final HandToHandEffect effect) { + super(effect); + } + + @Override + public HandToHandEffect copy() { + return new HandToHandEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public String getInfoMessage(Ability source, GameEvent event, Game game) { + MageObject mageObject = game.getObject(source.getSourceId()); + if (mageObject != null) { + return "During combat, players can't cast instant spells or activate abilities that aren't mana abilities (" + mageObject.getLogName() + ")."; + } + return null; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (game.getPhase().getType() == TurnPhase.COMBAT) { + MageObject object = game.getObject(event.getSourceId()); + if (event.getType() == GameEvent.EventType.CAST_SPELL) { + if (object.getCardType().contains(CardType.INSTANT)) { + return true; + } + } + if (event.getType() == GameEvent.EventType.ACTIVATE_ABILITY) { + Ability ability = game.getAbility(event.getTargetId(), event.getSourceId()); + if (ability != null && !(ability instanceof ManaAbility)) { + return true; + } + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/Intuition.java b/Mage.Sets/src/mage/sets/tempest/Intuition.java index c3434f60978..b53b71eddcb 100644 --- a/Mage.Sets/src/mage/sets/tempest/Intuition.java +++ b/Mage.Sets/src/mage/sets/tempest/Intuition.java @@ -114,7 +114,7 @@ class IntuitionEffect extends SearchEffect { TargetCard targetCard = new TargetCard(Zone.PICK, new FilterCard()); while(!opponent.choose(Outcome.Neutral, cards, targetCard, game)) { - if (!opponent.isInGame()) { + if (!opponent.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/tempest/Invulnerability.java b/Mage.Sets/src/mage/sets/tempest/Invulnerability.java new file mode 100644 index 00000000000..7c278d62dea --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/Invulnerability.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.effects.common.PreventNextDamageFromChosenSourceToYouEffect; +import mage.abilities.keyword.BuybackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author anonymous + */ +public class Invulnerability extends CardImpl { + + public Invulnerability(UUID ownerId) { + super(ownerId, 237, "Invulnerability", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "TMP"; + + // Buyback {3} + this.addAbility(new BuybackAbility("{3}")); + + // The next time a source of your choice would deal damage to you this turn, prevent that damage. + this.getSpellAbility().addEffect(new PreventNextDamageFromChosenSourceToYouEffect(Duration.EndOfTurn)); + } + + public Invulnerability(final Invulnerability card) { + super(card); + } + + @Override + public Invulnerability copy() { + return new Invulnerability(this); + } +} + diff --git a/Mage.Sets/src/mage/sets/tempest/Lobotomy.java b/Mage.Sets/src/mage/sets/tempest/Lobotomy.java index 38c80b50163..e666c50d0ec 100644 --- a/Mage.Sets/src/mage/sets/tempest/Lobotomy.java +++ b/Mage.Sets/src/mage/sets/tempest/Lobotomy.java @@ -33,6 +33,8 @@ import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -44,8 +46,8 @@ import mage.filter.predicate.mageobject.NamePredicate; import mage.filter.predicate.mageobject.SupertypePredicate; import mage.game.Game; import mage.players.Player; +import mage.target.TargetCard; import mage.target.TargetPlayer; -import mage.target.common.TargetCardInHand; import mage.target.common.TargetCardInLibrary; /** @@ -96,62 +98,65 @@ class LobotomyEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = game.getObject(source.getSourceId()); if (targetPlayer != null && sourceObject != null && controller != null) { - - // reveal hand of target player - targetPlayer.revealCards(sourceObject.getName(), targetPlayer.getHand(), game); - + + // reveal hand of target player + targetPlayer.revealCards(sourceObject.getIdName(), targetPlayer.getHand(), game); + // You choose card other than a basic land card - TargetCardInHand target = new TargetCardInHand(filter); + TargetCard target = new TargetCard(Zone.HAND, filter); target.setNotTarget(true); Card chosenCard = null; - if (controller.choose(Outcome.Benefit, targetPlayer.getHand(), target, game)) { + if (controller.chooseTarget(Outcome.Benefit, targetPlayer.getHand(), target, source, game)) { chosenCard = game.getCard(target.getFirstTarget()); } - - + // Exile all cards with the same name // Building a card filter with the name FilterCard filterNamedCards = new FilterCard(); if (chosenCard != null) { - filterNamedCards.add(new NamePredicate(chosenCard.getName())); + filterNamedCards.add(new NamePredicate(chosenCard.getName())); + filterNamedCards.setMessage("cards named " + chosenCard.getName()); } else { filterNamedCards.add(new NamePredicate("----")); // so no card matches } - + Cards cardsToExile = new CardsImpl(); // The cards you're searching for must be found and exiled if they're in the graveyard because it's a public zone. // Finding those cards in the hand and library is optional, because those zones are hidden (even if the hand is temporarily revealed). // search cards in graveyard if (chosenCard != null) { for (Card checkCard : targetPlayer.getGraveyard().getCards(game)) { if (checkCard.getName().equals(chosenCard.getName())) { - controller.moveCardToExileWithInfo(checkCard, null, "", source.getSourceId(), game, Zone.GRAVEYARD, true); + cardsToExile.add(checkCard); } } - // search cards in hand - TargetCardInHand targetCardsHand = new TargetCardInHand(0, Integer.MAX_VALUE, filterNamedCards); - controller.chooseTarget(outcome, targetPlayer.getGraveyard(), targetCardsHand, source, game); - for(UUID cardId: targetCardsHand.getTargets()) { + TargetCard targetCardsHand = new TargetCard(0, Integer.MAX_VALUE, Zone.HAND, filterNamedCards); + controller.chooseTarget(outcome, targetPlayer.getHand(), targetCardsHand, source, game); + for (UUID cardId : targetCardsHand.getTargets()) { Card card = game.getCard(cardId); if (card != null) { - controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.HAND, true); + cardsToExile.add(card); } } - } + } // search cards in Library // If the player has no nonland cards in his or her hand, you can still search that player's library and have him or her shuffle it. if (chosenCard != null || controller.chooseUse(outcome, "Search library anyway?", source, game)) { TargetCardInLibrary targetCardsLibrary = new TargetCardInLibrary(0, Integer.MAX_VALUE, filterNamedCards); controller.searchLibrary(targetCardsLibrary, game, targetPlayer.getId()); - for(UUID cardId: targetCardsLibrary.getTargets()) { + for (UUID cardId : targetCardsLibrary.getTargets()) { Card card = game.getCard(cardId); if (card != null) { - controller.moveCardToExileWithInfo(card, null, "", source.getSourceId(), game, Zone.LIBRARY, true); + cardsToExile.add(card); } } - targetPlayer.shuffleLibrary(game); + } + if (!cardsToExile.isEmpty()) { + controller.moveCards(cardsToExile, null, Zone.EXILED, source, game); + } + targetPlayer.shuffleLibrary(game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/tempest/MarbleTitan.java b/Mage.Sets/src/mage/sets/tempest/MarbleTitan.java new file mode 100644 index 00000000000..77aca3a45da --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/MarbleTitan.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.DontUntapInControllersUntapStepAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.PowerPredicate; + +/** + * + * @author LoneFox + */ +public class MarbleTitan extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("Creatures with power 3 or greater"); + + static { + filter.add(new PowerPredicate(Filter.ComparisonType.GreaterThan, 2)); + } + + public MarbleTitan(UUID ownerId) { + super(ownerId, 240, "Marble Titan", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "TMP"; + this.subtype.add("Giant"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Creatures with power 3 or greater don't untap during their controllers' untap steps. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new DontUntapInControllersUntapStepAllEffect(Duration.WhileOnBattlefield, TargetController.ANY, filter))); + } + + public MarbleTitan(final MarbleTitan card) { + super(card); + } + + @Override + public MarbleTitan copy() { + return new MarbleTitan(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/Respite.java b/Mage.Sets/src/mage/sets/tempest/Respite.java new file mode 100644 index 00000000000..dd97200d06e --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/Respite.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.dynamicvalue.common.AttackingCreatureCount; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.PreventAllDamageByAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Respite extends CardImpl { + + public Respite(UUID ownerId) { + super(ownerId, 143, "Respite", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "TMP"; + + // Prevent all combat damage that would be dealt this turn. + this.getSpellAbility().addEffect(new PreventAllDamageByAllEffect(Duration.EndOfTurn, true)); + + // You gain 1 life for each attacking creature. + this.getSpellAbility().addEffect(new GainLifeEffect(new AttackingCreatureCount())); + } + + public Respite(final Respite card) { + super(card); + } + + @Override + public Respite copy() { + return new Respite(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/Sarcomancy.java b/Mage.Sets/src/mage/sets/tempest/Sarcomancy.java index 19a9c322c3f..77b8d9ec149 100644 --- a/Mage.Sets/src/mage/sets/tempest/Sarcomancy.java +++ b/Mage.Sets/src/mage/sets/tempest/Sarcomancy.java @@ -1,75 +1,73 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.tempest; - -import java.util.UUID; -import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; -import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; -import mage.abilities.decorator.ConditionalTriggeredAbility; -import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; -import mage.abilities.effects.common.CreateTokenEffect; -import mage.abilities.effects.common.DamageControllerEffect; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.constants.Zone; -import mage.filter.FilterPermanent; -import mage.filter.predicate.mageobject.NamePredicate; -import mage.game.permanent.token.ZombieToken; - -/** - * - * @author LevelX2 - */ -public class Sarcomancy extends CardImpl { - - public Sarcomancy(UUID ownerId) { - super(ownerId, 48, "Sarcomancy", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{B}"); - this.expansionSetCode = "TMP"; - - - // When Sarcomancy enters the battlefield, put a 2/2 black Zombie creature token onto the battlefield. - this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken(), 1), false)); - // At the beginning of your upkeep, if there are no Zombies on the battlefield, Sarcomancy deals 1 damage to you. - this.addAbility(new ConditionalTriggeredAbility( - new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageControllerEffect(1), TargetController.YOU, false), - new PermanentsOnTheBattlefieldCondition(new FilterPermanent("Zombie", "Zombies"), PermanentsOnTheBattlefieldCondition.CountType.EQUAL_TO, 0, false), - "At the beginning of your upkeep, if there are no Zombies on the battlefield, {this} deals 1 damage to you.")); - } - - public Sarcomancy(final Sarcomancy card) { - super(card); - } - - @Override - public Sarcomancy copy() { - return new Sarcomancy(this); - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DamageControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.game.permanent.token.ZombieToken; + +/** + * + * @author LevelX2 + */ +public class Sarcomancy extends CardImpl { + + public Sarcomancy(UUID ownerId) { + super(ownerId, 48, "Sarcomancy", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{B}"); + this.expansionSetCode = "TMP"; + + + // When Sarcomancy enters the battlefield, put a 2/2 black Zombie creature token onto the battlefield. + this.addAbility(new EntersBattlefieldTriggeredAbility(new CreateTokenEffect(new ZombieToken(), 1), false)); + // At the beginning of your upkeep, if there are no Zombies on the battlefield, Sarcomancy deals 1 damage to you. + this.addAbility(new ConditionalTriggeredAbility( + new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageControllerEffect(1), TargetController.YOU, false), + new PermanentsOnTheBattlefieldCondition(new FilterPermanent("Zombie", "Zombies"), PermanentsOnTheBattlefieldCondition.CountType.EQUAL_TO, 0, false), + "At the beginning of your upkeep, if there are no Zombies on the battlefield, {this} deals 1 damage to you.")); + } + + public Sarcomancy(final Sarcomancy card) { + super(card); + } + + @Override + public Sarcomancy copy() { + return new Sarcomancy(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/ScaldingTongs.java b/Mage.Sets/src/mage/sets/tempest/ScaldingTongs.java new file mode 100644 index 00000000000..fd52fed1e12 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/ScaldingTongs.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class ScaldingTongs extends CardImpl { + + public ScaldingTongs(UUID ownerId) { + super(ownerId, 297, "Scalding Tongs", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "TMP"; + + // At the beginning of your upkeep, if you have three or fewer cards in hand, Scalding Tongs deals 1 damage to target opponent. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), TargetController.YOU, false); + ability.addTarget(new TargetOpponent()); + CardsInHandCondition condition = new CardsInHandCondition(CardsInHandCondition.CountType.FEWER_THAN, 4); + this.addAbility(new ConditionalTriggeredAbility(ability, condition, "At the beginning of your upkeep, if you have three or fewer cards in hand, {this} deals 1 damage to target opponent.")); + } + + public ScaldingTongs(final ScaldingTongs card) { + super(card); + } + + @Override + public ScaldingTongs copy() { + return new ScaldingTongs(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/ScrollRack.java b/Mage.Sets/src/mage/sets/tempest/ScrollRack.java index 50cf767d80e..db4100fe0e7 100644 --- a/Mage.Sets/src/mage/sets/tempest/ScrollRack.java +++ b/Mage.Sets/src/mage/sets/tempest/ScrollRack.java @@ -27,7 +27,7 @@ */ package mage.sets.tempest; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.MageObject; import mage.abilities.Ability; @@ -37,15 +37,14 @@ import mage.abilities.costs.mana.GenericManaCost; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterCard; -import mage.game.ExileZone; import mage.game.Game; import mage.players.Player; -import mage.target.common.TargetCardInExile; import mage.target.common.TargetCardInHand; /** @@ -91,54 +90,35 @@ class ScrollRackEffect extends OneShotEffect { MageObject sourceObject = game.getObject(source.getSourceId()); if (controller != null && sourceObject != null) { FilterCard filter = new FilterCard("card in your hand to exile"); - FilterCard filter2 = new FilterCard("(move the window) card exiled by " + sourceObject.getLogName() + " to put on top of library"); +// FilterCard filter2 = new FilterCard("(move the window) card exiled by " + sourceObject.getIdName() + " to put on top of library"); TargetCardInHand target = new TargetCardInHand(0, controller.getHand().size(), filter); target.setRequired(false); int amountExiled = 0; if (target.canChoose(source.getControllerId(), game) && target.choose(Outcome.Neutral, source.getControllerId(), source.getSourceId(), game)) { if (!target.getTargets().isEmpty()) { - List targets = target.getTargets(); - for (UUID targetId : targets) { + for (UUID targetId : target.getTargets()) { Card card = game.getCard(targetId); if (card != null) { - if (card.moveToExile(source.getSourceId(), sourceObject.getName(), source.getSourceId(), game)) { - card.setFaceDown(true, game); - amountExiled++; - } + card.setFaceDown(true, game); + amountExiled++; } } + controller.moveCardsToExile(new CardsImpl(target.getTargets()).getCards(game), source, game, false, source.getSourceId(), sourceObject.getIdName()); + for (Card card : game.getExile().getExileZone(source.getSourceId()).getCards(game)) { + card.setFaceDown(true, game); + } } } - game.informPlayers(controller.getLogName() + " exiles " + amountExiled + " card" + (amountExiled == 1 ? " ":"s ") + "face down from his or her hand"); + // Put that many cards from the top of your library into your hand. if (amountExiled > 0) { - int count = Math.min(controller.getLibrary().size(), amountExiled); - for (int i = 0; i < count; i++) { - Card card = controller.getLibrary().removeFromTop(game); - if (card != null) { - card.moveToZone(Zone.HAND, source.getSourceId(), game, false); - } - } - } - game.informPlayers(controller.getLogName() + " moves " + amountExiled + " card" + (amountExiled == 1 ? " ":"s ") + "from library to hand"); - - TargetCardInExile target2 = new TargetCardInExile(filter2, source.getSourceId()); - ExileZone scrollRackExileZone = game.getExile().getExileZone(source.getSourceId()); - if (scrollRackExileZone != null) { - while (controller.isInGame() && scrollRackExileZone.count(filter, game) > 1) { - controller.lookAtCards("exiled cards with " + sourceObject.getName(), scrollRackExileZone, game); - controller.choose(Outcome.Neutral, scrollRackExileZone, target2, game); - Card card = game.getCard(target2.getFirstTarget()); - if (card != null) { - game.getExile().removeCard(card, game); - controller.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.EXILED, true, false); - } - target2.clearChosen(); - } - if (scrollRackExileZone.count(filter, game) == 1) { - Card card = scrollRackExileZone.get(scrollRackExileZone.iterator().next(), game); - controller.moveCardToLibraryWithInfo(card, source.getSourceId(), game, Zone.EXILED, true, false); + Set cards = controller.getLibrary().getTopCards(game, amountExiled); + for (Card card : cards) { + card.setFaceDown(true, game); } + controller.moveCards(cards, null, Zone.HAND, source, game); } + // Then look at the exiled cards and put them on top of your library in any order + controller.putCardsOnTopOfLibrary(game.getExile().getExileZone(source.getSourceId()), game, source, true); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/tempest/ServantOfVolrath.java b/Mage.Sets/src/mage/sets/tempest/ServantOfVolrath.java new file mode 100644 index 00000000000..7010697b90d --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/ServantOfVolrath.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.common.SacrificeControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class ServantOfVolrath extends CardImpl { + + public ServantOfVolrath(UUID ownerId) { + super(ownerId, 50, "Servant of Volrath", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "TMP"; + this.subtype.add("Minion"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Servant of Volrath leaves the battlefield, sacrifice a creature. + this.addAbility(new LeavesBattlefieldTriggeredAbility(new SacrificeControllerEffect(new FilterCreaturePermanent(), 1, ""), false)); + } + + public ServantOfVolrath(final ServantOfVolrath card) { + super(card); + } + + @Override + public ServantOfVolrath copy() { + return new ServantOfVolrath(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/Stun.java b/Mage.Sets/src/mage/sets/tempest/Stun.java index 82cc6f5cb77..ecaa81eac69 100644 --- a/Mage.Sets/src/mage/sets/tempest/Stun.java +++ b/Mage.Sets/src/mage/sets/tempest/Stun.java @@ -28,9 +28,6 @@ package mage.sets.tempest; import java.util.UUID; -import mage.abilities.common.EntersBattlefieldTriggeredAbility; - -import mage.abilities.effects.Effect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.combat.CantBlockTargetEffect; import mage.cards.CardImpl; @@ -50,10 +47,8 @@ public class Stun extends CardImpl { this.expansionSetCode = "TMP"; // Target creature can't block this turn. - Effect effect = new CantBlockTargetEffect(Duration.EndOfTurn); - effect.setText("Target creature can't block this turn."); - this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addEffect(new CantBlockTargetEffect(Duration.EndOfTurn)); // Draw a card. this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); diff --git a/Mage.Sets/src/mage/sets/tempest/Thumbscrews.java b/Mage.Sets/src/mage/sets/tempest/Thumbscrews.java new file mode 100644 index 00000000000..0d43d04e3ce --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/Thumbscrews.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class Thumbscrews extends CardImpl { + + public Thumbscrews(UUID ownerId) { + super(ownerId, 302, "Thumbscrews", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "TMP"; + + // At the beginning of your upkeep, if you have five or more cards in hand, Thumbscrews deals 1 damage to target opponent. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, + new DamageTargetEffect(1), TargetController.YOU, false); + ability.addTarget(new TargetOpponent()); + CardsInHandCondition condition = new CardsInHandCondition(CardsInHandCondition.CountType.MORE_THAN, 4); + this.addAbility(new ConditionalTriggeredAbility(ability, condition, "At the beginning of your upkeep, if you have five or more cards in hand, {this} deals 1 damage to target opponent.")); + } + + public Thumbscrews(final Thumbscrews card) { + super(card); + } + + @Override + public Thumbscrews copy() { + return new Thumbscrews(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempest/WoodSage.java b/Mage.Sets/src/mage/sets/tempest/WoodSage.java index 867039608a8..3744b716831 100644 --- a/Mage.Sets/src/mage/sets/tempest/WoodSage.java +++ b/Mage.Sets/src/mage/sets/tempest/WoodSage.java @@ -103,7 +103,7 @@ class WoodSageEffect extends OneShotEffect { cardChoice.setChoices(CardRepository.instance.getCreatureNames()); cardChoice.setMessage("Name a creature card"); while (!controller.choose(Outcome.Detriment, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/tempest/WorthyCause.java b/Mage.Sets/src/mage/sets/tempest/WorthyCause.java new file mode 100644 index 00000000000..64bcac4466d --- /dev/null +++ b/Mage.Sets/src/mage/sets/tempest/WorthyCause.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tempest; + +import java.util.UUID; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.dynamicvalue.common.SacrificeCostCreaturesToughness; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.keyword.BuybackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetControlledCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class WorthyCause extends CardImpl { + + public WorthyCause(UUID ownerId) { + super(ownerId, 265, "Worthy Cause", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "TMP"; + + // Buyback {2} + this.addAbility(new BuybackAbility("{2}")); + + // As an additional cost to cast Worthy Cause, sacrifice a creature. + this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + + // You gain life equal to the sacrificed creature's toughness. + Effect effect = new GainLifeEffect(new SacrificeCostCreaturesToughness()); + effect.setText("You gain life equal to the sacrificed creature's toughness"); + this.getSpellAbility().addEffect(effect); + } + + public WorthyCause(final WorthyCause card) { + super(card); + } + + @Override + public WorthyCause copy() { + return new WorthyCause(this); + } +} diff --git a/Mage.Sets/src/mage/sets/tempestremastered/EndangeredArmodon.java b/Mage.Sets/src/mage/sets/tempestremastered/EndangeredArmodon.java index 3aac6873f3d..e246e942bba 100644 --- a/Mage.Sets/src/mage/sets/tempestremastered/EndangeredArmodon.java +++ b/Mage.Sets/src/mage/sets/tempestremastered/EndangeredArmodon.java @@ -29,17 +29,14 @@ package mage.sets.tempestremastered; import java.util.UUID; import mage.MageInt; -import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; import mage.abilities.effects.common.SacrificeSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; -import mage.constants.Zone; -import mage.filter.Filter.ComparisonType; -import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.Filter; +import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.ToughnessPredicate; -import mage.game.Game; -import mage.game.events.GameEvent; /** * @@ -47,6 +44,12 @@ import mage.game.events.GameEvent; */ public class EndangeredArmodon extends CardImpl { + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with toughness 2 or less"); + + static { + filter.add(new ToughnessPredicate(Filter.ComparisonType.LessThan, 3)); + } + public EndangeredArmodon(UUID ownerId) { super(ownerId, 171, "Endangered Armodon", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}{G}"); this.expansionSetCode = "TPR"; @@ -55,7 +58,9 @@ public class EndangeredArmodon extends CardImpl { this.toughness = new MageInt(5); // When you control a creature with toughness 2 or less, sacrifice Endangered Armodon. - this.addAbility(new EndangeredArmodonStateTriggeredAbility()); + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + filter, Filter.ComparisonType.GreaterThan, 0, + new SacrificeSourceEffect())); } public EndangeredArmodon(final EndangeredArmodon card) { @@ -67,34 +72,3 @@ public class EndangeredArmodon extends CardImpl { return new EndangeredArmodon(this); } } - -class EndangeredArmodonStateTriggeredAbility extends StateTriggeredAbility { - - private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("creature with toughness 2 or less"); - static { - filter.add(new ToughnessPredicate(ComparisonType.LessThan, 3)); - } - - EndangeredArmodonStateTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeSourceEffect()); - } - - EndangeredArmodonStateTriggeredAbility(final EndangeredArmodonStateTriggeredAbility ability) { - super(ability); - } - - @Override - public EndangeredArmodonStateTriggeredAbility copy() { - return new EndangeredArmodonStateTriggeredAbility(this); - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return game.getBattlefield().contains(filter, this.getControllerId(), game, 1); - } - - @Override - public String getRule() { - return "When you control a creature with toughness 2 or less, sacrifice {this}."; - } -} diff --git a/Mage.Sets/src/mage/sets/tenthedition/Abundance.java b/Mage.Sets/src/mage/sets/tenthedition/Abundance.java index 767dceb20f1..09bc7c058bf 100644 --- a/Mage.Sets/src/mage/sets/tenthedition/Abundance.java +++ b/Mage.Sets/src/mage/sets/tenthedition/Abundance.java @@ -28,6 +28,7 @@ package mage.sets.tenthedition; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.ReplacementEffectImpl; @@ -94,35 +95,35 @@ class AbundanceReplacementEffect extends ReplacementEffectImpl { @Override public boolean replaceEvent(GameEvent event, Ability source, Game game) { - Player player = game.getPlayer(event.getPlayerId()); - if (player != null) { + Player controller = game.getPlayer(event.getPlayerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { FilterCard filter = new FilterCard(); - if (player.chooseUse(Outcome.Benefit, "Choose land? (No = nonland)", source, game)) { + if (controller.chooseUse(Outcome.Benefit, "Choose land? (No = nonland)", source, game)) { filter.add(new CardTypePredicate(CardType.LAND)); - } - else { + } else { filter.add(Predicates.not(new CardTypePredicate(CardType.LAND))); } Cards cards = new CardsImpl(); - while (player.getLibrary().size() > 0) { - Card card = player.getLibrary().removeFromTop(game); + while (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().removeFromTop(game); if (filter.match(card, source.getSourceId(), source.getControllerId(), game)) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + controller.moveCards(card, null, Zone.HAND, source, game); break; } cards.add(card); } - player.revealCards("Abundance", cards, game); - player.putCardsOnBottomOfLibrary(cards, game, source, true); + controller.revealCards(sourceObject.getIdName(), cards, game); + controller.putCardsOnBottomOfLibrary(cards, game, source, true); } return true; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.DRAW_CARD; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { if (event.getPlayerId().equals(source.getControllerId())) { @@ -133,4 +134,4 @@ class AbundanceReplacementEffect extends ReplacementEffectImpl { } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/tenthedition/BeaconOfImmortality.java b/Mage.Sets/src/mage/sets/tenthedition/BeaconOfImmortality.java index b9a3ecc2241..b382e323c53 100644 --- a/Mage.Sets/src/mage/sets/tenthedition/BeaconOfImmortality.java +++ b/Mage.Sets/src/mage/sets/tenthedition/BeaconOfImmortality.java @@ -87,9 +87,9 @@ class BeaconOfImmortalityEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getFirstTarget()); if (player != null) { - int amount = game.getLife(); + int amount = player.getLife(); if (amount < 0) { - player.loseLife(amount, game); + player.loseLife(-amount, game); return true; } if (amount > 0) { diff --git a/Mage.Sets/src/mage/sets/tenthedition/StrongholdDiscipline.java b/Mage.Sets/src/mage/sets/tenthedition/StrongholdDiscipline.java new file mode 100644 index 00000000000..fc1ad76ba57 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tenthedition/StrongholdDiscipline.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.tenthedition; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class StrongholdDiscipline extends mage.sets.conspiracy.StrongholdDiscipline { + + public StrongholdDiscipline(UUID ownerId) { + super(ownerId); + this.cardNumber = 181; + this.expansionSetCode = "10E"; + this.rarity = Rarity.UNCOMMON; + } + + public StrongholdDiscipline(final StrongholdDiscipline card) { + super(card); + } + + @Override + public StrongholdDiscipline copy() { + return new StrongholdDiscipline(this); + } +} diff --git a/Mage.Sets/src/mage/sets/thedark/BogRats.java b/Mage.Sets/src/mage/sets/thedark/BogRats.java index 7522c2f1473..987cc41538b 100644 --- a/Mage.Sets/src/mage/sets/thedark/BogRats.java +++ b/Mage.Sets/src/mage/sets/thedark/BogRats.java @@ -29,13 +29,12 @@ package mage.sets.thedark; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.SubtypePredicate; @@ -50,7 +49,7 @@ public class BogRats extends CardImpl { static { filter.add(new SubtypePredicate("Wall")); } - + public BogRats(UUID ownerId) { super(ownerId, 4, "Bog Rats", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); this.expansionSetCode = "DRK"; @@ -60,7 +59,7 @@ public class BogRats extends CardImpl { this.toughness = new MageInt(1); // Bog Rats can't be blocked by Walls. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); } public BogRats(final BogRats card) { diff --git a/Mage.Sets/src/mage/sets/thedark/CityOfShadows.java b/Mage.Sets/src/mage/sets/thedark/CityOfShadows.java index 6e4381050e3..8651daa4ad0 100644 --- a/Mage.Sets/src/mage/sets/thedark/CityOfShadows.java +++ b/Mage.Sets/src/mage/sets/thedark/CityOfShadows.java @@ -45,7 +45,7 @@ import mage.target.common.TargetControlledCreaturePermanent; /** * - * @author anonymous + * @author Luna Skyrise */ public class CityOfShadows extends CardImpl { @@ -53,12 +53,14 @@ public class CityOfShadows extends CardImpl { super(ownerId, 113, "City of Shadows", Rarity.RARE, new CardType[]{CardType.LAND}, ""); this.expansionSetCode = "DRK"; - // {tap}, Exile a creature you control: Put a storage counter on City of Shadows. + // {T}, Exile a creature you control: Put a storage counter on City of Shadows. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.STORAGE.createInstance()), new TapSourceCost()); ability.addCost(new ExileTargetCost(new TargetControlledCreaturePermanent())); - // {tap}: Add {X} to your mana pool, where X is the number of storage counters on City of Shadows. + this.addAbility(ability); + + // {T}: Add {X} to your mana pool, where X is the number of storage counters on City of Shadows. ability = new DynamicManaAbility(Mana.ColorlessMana, new CountersCount(CounterType.STORAGE), - "{tap}: Add {X} to your mana pool, where X is the number of storage counters on City of Shadows"); + "{tap}: Add {X} to your mana pool, where X is the number of storage counters on {this}"); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/thedark/GoblinsOfTheFlarg.java b/Mage.Sets/src/mage/sets/thedark/GoblinsOfTheFlarg.java new file mode 100644 index 00000000000..c3d1e28e435 --- /dev/null +++ b/Mage.Sets/src/mage/sets/thedark/GoblinsOfTheFlarg.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.thedark; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.keyword.MountainwalkAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class GoblinsOfTheFlarg extends CardImpl { + + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("a Dwarf"); + + static { + filter.add(new SubtypePredicate("Dwarf")); + } + + public GoblinsOfTheFlarg(UUID ownerId) { + super(ownerId, 69, "Goblins of the Flarg", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "DRK"; + this.subtype.add("Goblin"); + this.subtype.add("Warrior"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Mountainwalk + this.addAbility(new MountainwalkAbility()); + + // When you control a Dwarf, sacrifice Goblins of the Flarg. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + filter, Filter.ComparisonType.GreaterThan, 0, + new SacrificeSourceEffect())); + } + + public GoblinsOfTheFlarg(final GoblinsOfTheFlarg card) { + super(card); + } + + @Override + public GoblinsOfTheFlarg copy() { + return new GoblinsOfTheFlarg(this); + } +} diff --git a/Mage.Sets/src/mage/sets/thedark/ManaVortex.java b/Mage.Sets/src/mage/sets/thedark/ManaVortex.java new file mode 100644 index 00000000000..c14a4934509 --- /dev/null +++ b/Mage.Sets/src/mage/sets/thedark/ManaVortex.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.thedark; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class ManaVortex extends mage.sets.masterseditioniii.ManaVortex { + + public ManaVortex(UUID ownerId) { + super(ownerId); + this.cardNumber = 30; + this.expansionSetCode = "DRK"; + } + + public ManaVortex(final ManaVortex card) { + super(card); + } + + @Override + public ManaVortex copy() { + return new ManaVortex(this); + } +} diff --git a/Mage.Sets/src/mage/sets/thedark/Tracker.java b/Mage.Sets/src/mage/sets/thedark/Tracker.java new file mode 100644 index 00000000000..18d3bf592a5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/thedark/Tracker.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.thedark; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class Tracker extends mage.sets.masterseditioniii.Tracker { + + public Tracker(UUID ownerId) { + super(ownerId); + this.cardNumber = 52; + this.expansionSetCode = "DRK"; + this.rarity = Rarity.RARE; + } + + public Tracker(final Tracker card) { + super(card); + } + + @Override + public Tracker copy() { + return new Tracker(this); + } +} diff --git a/Mage.Sets/src/mage/sets/thedark/WordOfBinding.java b/Mage.Sets/src/mage/sets/thedark/WordOfBinding.java new file mode 100644 index 00000000000..ecd0f63a4b6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/thedark/WordOfBinding.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.thedark; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class WordOfBinding extends mage.sets.fourthedition.WordOfBinding { + + public WordOfBinding(UUID ownerId) { + super(ownerId); + this.cardNumber = 17; + this.expansionSetCode = "DRK"; + } + + public WordOfBinding(final WordOfBinding card) { + super(card); + } + + @Override + public WordOfBinding copy() { + return new WordOfBinding(this); + } +} diff --git a/Mage.Sets/src/mage/sets/theros/ChainedToTheRocks.java b/Mage.Sets/src/mage/sets/theros/ChainedToTheRocks.java index a5d3a0e0246..2a8dd53f012 100644 --- a/Mage.Sets/src/mage/sets/theros/ChainedToTheRocks.java +++ b/Mage.Sets/src/mage/sets/theros/ChainedToTheRocks.java @@ -52,33 +52,37 @@ import mage.target.common.TargetCreaturePermanent; import mage.util.CardUtil; /** - * If the land Chained to the Rocks is enchanting stops being a Mountain or another player - * gains control of it, Chained to the Rocks will be put into its owner's graveyard when - * state-based actions are performed. + * If the land Chained to the Rocks is enchanting stops being a Mountain or + * another player gains control of it, Chained to the Rocks will be put into its + * owner's graveyard when state-based actions are performed. * - * Chained to the Rocks's ability causes a zone change with a duration, a style of ability - * introduced in Magic 2014 that's somewhat reminiscent of older cards like Oblivion Ring. - * However, unlike Oblivion Ring, cards like Chained to the Rocks have a single ability - * that creates two one-shot effects: one that exiles the creature when the ability resolves, - * and another that returns the exiled card to the battlefield immediately after Chained to - * the Rocks leaves the battlefield. + * Chained to the Rocks's ability causes a zone change with a duration, a style + * of ability introduced in Magic 2014 that's somewhat reminiscent of older + * cards like Oblivion Ring. However, unlike Oblivion Ring, cards like Chained + * to the Rocks have a single ability that creates two one-shot effects: one + * that exiles the creature when the ability resolves, and another that returns + * the exiled card to the battlefield immediately after Chained to the Rocks + * leaves the battlefield. * - * If Chained to the Rocks leaves the battlefield before its triggered ability resolves, - * the target creature won't be exiled. + * If Chained to the Rocks leaves the battlefield before its triggered ability + * resolves, the target creature won't be exiled. * - * Auras attached to the exiled creature will be put into their owners' graveyards (unless - * they have bestow). Equipment attached to the exiled creature will become unattached and - * remain on the battlefield. Any counters on the exiled creature will cease to exist. + * Auras attached to the exiled creature will be put into their owners' + * graveyards (unless they have bestow). Equipment attached to the exiled + * creature will become unattached and remain on the battlefield. Any counters + * on the exiled creature will cease to exist. * - * If a creature token is exiled, it ceases to exist. It won't be returned to the battlefield. + * If a creature token is exiled, it ceases to exist. It won't be returned to + * the battlefield. * - * The exiled card returns to the battlefield immediately after Chained to the Rocks leaves - * the battlefield. Nothing happens between the two events, including state-based actions. + * The exiled card returns to the battlefield immediately after Chained to the + * Rocks leaves the battlefield. Nothing happens between the two events, + * including state-based actions. * - * In a multiplayer game, if Chained to the Rocks's owner leaves the game, the exiled card - * will return to the battlefield. Because the one-shot effect that returns the card isn't - * an ability that goes on the stack, it won't cease to exist along with the leaving player's - * spells and abilities on the stack. + * In a multiplayer game, if Chained to the Rocks's owner leaves the game, the + * exiled card will return to the battlefield. Because the one-shot effect that + * returns the card isn't an ability that goes on the stack, it won't cease to + * exist along with the leaving player's spells and abilities on the stack. * * @author LevelX2 */ @@ -86,6 +90,7 @@ public class ChainedToTheRocks extends CardImpl { private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("Mountain you control"); private static final FilterCreaturePermanent filterTarget = new FilterCreaturePermanent("creature an opponent controls"); + static { filter.add(new SubtypePredicate("Mountain")); filterTarget.add(new ControllerPredicate(TargetController.OPPONENT)); @@ -96,7 +101,6 @@ public class ChainedToTheRocks extends CardImpl { this.expansionSetCode = "THS"; this.subtype.add("Aura"); - // Enchant Mountain you control TargetPermanent auraTarget = new TargetPermanent(filter); this.getSpellAbility().addTarget(auraTarget); @@ -144,7 +148,7 @@ class ChainedToTheRocksEffect extends OneShotEffect { // If Chained to the Rocks leaves the battlefield before its triggered ability resolves, // the target creature won't be exiled. if (permanent != null) { - return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getName()).apply(game, source); + return new ExileTargetEffect(CardUtil.getCardExileZoneId(game, source), permanent.getIdName()).apply(game, source); } return false; } diff --git a/Mage.Sets/src/mage/sets/theros/DaxosOfMeletis.java b/Mage.Sets/src/mage/sets/theros/DaxosOfMeletis.java index 2fa81356036..555da66687d 100644 --- a/Mage.Sets/src/mage/sets/theros/DaxosOfMeletis.java +++ b/Mage.Sets/src/mage/sets/theros/DaxosOfMeletis.java @@ -32,7 +32,7 @@ import mage.MageInt; import mage.MageObject; import mage.abilities.Ability; import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.AsThoughEffectImpl; import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.OneShotEffect; @@ -77,7 +77,7 @@ public class DaxosOfMeletis extends CardImpl { this.toughness = new MageInt(2); // Daxos of Meletis can't be blocked by creatures with power 3 or greater. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); // Whenever Daxos of Meletis deals combat damage to a player, exile the top card of that player's library. You gain life equal to that card's converted mana cost. Until end of turn, you may cast that card and you may spend mana as though it were mana of any color to cast it. this.addAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new DaxosOfMeletisEffect(), false, true)); diff --git a/Mage.Sets/src/mage/sets/theros/WhipOfErebos.java b/Mage.Sets/src/mage/sets/theros/WhipOfErebos.java index 8e4dfbcb939..6b345fdd021 100644 --- a/Mage.Sets/src/mage/sets/theros/WhipOfErebos.java +++ b/Mage.Sets/src/mage/sets/theros/WhipOfErebos.java @@ -73,7 +73,7 @@ public class WhipOfErebos extends CardImpl { // Creatures you control have lifelink. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityControlledEffect(LifelinkAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent("Creatures")))); - // {2}{B}{B}, {T}: Return target creature card from your graveyard to the battlefield. + // {2}{B}{B}, {T}: Return target creature card from your graveyard to the battlefield. // It gains haste. Exile it at the beginning of the next end step. // If it would leave the battlefield, exile it instead of putting it anywhere else. // Activate this ability only any time you could cast a sorcery. @@ -122,12 +122,12 @@ class WhipOfErebosEffect extends OneShotEffect { game.addEffect(effect, source); // Exile at begin of next end step ExileTargetEffect exileEffect = new ExileTargetEffect(null, null, Zone.BATTLEFIELD); - exileEffect.setTargetPointer(new FixedTarget(card.getId())); + exileEffect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(exileEffect); delayedAbility.setSourceId(source.getSourceId()); delayedAbility.setControllerId(source.getControllerId()); delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); + game.addDelayedTriggeredAbility(delayedAbility); } return true; } @@ -160,12 +160,12 @@ class WhipOfErebosReplacementEffect extends ReplacementEffectImpl { } return true; } - - @Override + + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.ZONE_CHANGE; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { if (event.getTargetId().equals(source.getFirstTarget()) diff --git a/Mage.Sets/src/mage/sets/theros/XenagosTheReveler.java b/Mage.Sets/src/mage/sets/theros/XenagosTheReveler.java index 276a35b4b4a..0166753702c 100644 --- a/Mage.Sets/src/mage/sets/theros/XenagosTheReveler.java +++ b/Mage.Sets/src/mage/sets/theros/XenagosTheReveler.java @@ -127,7 +127,7 @@ class XenagosManaEffect extends OneShotEffect { for (int i = 0; i < x; i++){ Mana mana = new Mana(); while (!player.choose(Outcome.Benefit, manaChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/timeshifted/DesolationGiant.java b/Mage.Sets/src/mage/sets/timeshifted/DesolationGiant.java new file mode 100644 index 00000000000..22daab2d556 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/DesolationGiant.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class DesolationGiant extends mage.sets.apocalypse.DesolationGiant { + + public DesolationGiant(UUID ownerId) { + super(ownerId); + this.cardNumber = 57; + this.expansionSetCode = "TSB"; + this.rarity = Rarity.SPECIAL; + } + + public DesolationGiant(final DesolationGiant card) { + super(card); + } + + @Override + public DesolationGiant copy() { + return new DesolationGiant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timeshifted/Dodecapod.java b/Mage.Sets/src/mage/sets/timeshifted/Dodecapod.java new file mode 100644 index 00000000000..73f7ddd1063 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/Dodecapod.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class Dodecapod extends mage.sets.apocalypse.Dodecapod { + + public Dodecapod(UUID ownerId) { + super(ownerId); + this.cardNumber = 108; + this.expansionSetCode = "TSB"; + this.rarity = Rarity.SPECIAL; + } + + public Dodecapod(final Dodecapod card) { + super(card); + } + + @Override + public Dodecapod copy() { + return new Dodecapod(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timeshifted/JolraelEmpressOfBeasts.java b/Mage.Sets/src/mage/sets/timeshifted/JolraelEmpressOfBeasts.java new file mode 100644 index 00000000000..7df8b372995 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/JolraelEmpressOfBeasts.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LevelX2 + */ +public class JolraelEmpressOfBeasts extends mage.sets.prophecy.JolraelEmpressOfBeasts { + + public JolraelEmpressOfBeasts(UUID ownerId) { + super(ownerId); + this.cardNumber = 81; + this.expansionSetCode = "TSB"; + this.rarity = Rarity.SPECIAL; + } + + public JolraelEmpressOfBeasts(final JolraelEmpressOfBeasts card) { + super(card); + } + + @Override + public JolraelEmpressOfBeasts copy() { + return new JolraelEmpressOfBeasts(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timeshifted/ShadowGuildmage.java b/Mage.Sets/src/mage/sets/timeshifted/ShadowGuildmage.java new file mode 100644 index 00000000000..8d76411452a --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/ShadowGuildmage.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class ShadowGuildmage extends mage.sets.mirage.ShadowGuildmage { + + public ShadowGuildmage(UUID ownerId) { + super(ownerId); + this.cardNumber = 46; + this.expansionSetCode = "TSB"; + this.rarity = Rarity.SPECIAL; + } + + public ShadowGuildmage(final ShadowGuildmage card) { + super(card); + } + + @Override + public ShadowGuildmage copy() { + return new ShadowGuildmage(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timeshifted/SoulCollector.java b/Mage.Sets/src/mage/sets/timeshifted/SoulCollector.java new file mode 100644 index 00000000000..fc35e9e8fa7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/SoulCollector.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.DiesAndDealtDamageThisTurnTriggeredAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnToBattlefieldUnderYourControlTargetEffect; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author markedagain + */ +public class SoulCollector extends CardImpl { + + public SoulCollector(UUID ownerId) { + super(ownerId, 47, "Soul Collector", Rarity.SPECIAL, new CardType[]{CardType.CREATURE}, "{3}{B}{B}"); + this.expansionSetCode = "TSB"; + this.subtype.add("Vampire"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Whenever a creature dealt damage by Soul Collector this turn dies, return that card to the battlefield under your control. + this.addAbility(new DiesAndDealtDamageThisTurnTriggeredAbility(new ReturnToBattlefieldUnderYourControlTargetEffect(false))); + // Morph {B}{B}{B} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{B}{B}{B}"))); + } + + public SoulCollector(final SoulCollector card) { + super(card); + } + + @Override + public SoulCollector copy() { + return new SoulCollector(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timeshifted/WildfireEmissary.java b/Mage.Sets/src/mage/sets/timeshifted/WildfireEmissary.java new file mode 100644 index 00000000000..2befb05562a --- /dev/null +++ b/Mage.Sets/src/mage/sets/timeshifted/WildfireEmissary.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timeshifted; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class WildfireEmissary extends mage.sets.mirage.WildfireEmissary { + + public WildfireEmissary(UUID ownerId) { + super(ownerId); + this.cardNumber = 72; + this.expansionSetCode = "TSB"; + this.rarity = Rarity.SPECIAL; + } + + public WildfireEmissary(final WildfireEmissary card) { + super(card); + } + + @Override + public WildfireEmissary copy() { + return new WildfireEmissary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/AmrouSeekers.java b/Mage.Sets/src/mage/sets/timespiral/AmrouSeekers.java index 2b8cd9f5fae..f7e95746eea 100644 --- a/Mage.Sets/src/mage/sets/timespiral/AmrouSeekers.java +++ b/Mage.Sets/src/mage/sets/timespiral/AmrouSeekers.java @@ -28,24 +28,18 @@ package mage.sets.timespiral; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.ObjectColor; -import mage.abilities.Ability; -import mage.abilities.EvasionAbility; -import mage.abilities.MageSingleton; -import mage.abilities.effects.RestrictionEffect; -import mage.abilities.keyword.IntimidateAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Rarity; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; import mage.filter.predicate.mageobject.ColorPredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; /** * @@ -53,6 +47,17 @@ import mage.game.permanent.Permanent; */ public class AmrouSeekers extends CardImpl { + private final static FilterCreaturePermanent notArtificatOrWhite = new FilterCreaturePermanent("except by artifact creatures and/or white creatures"); + + static { + notArtificatOrWhite.add(Predicates.not( + Predicates.or( + new CardTypePredicate(CardType.ARTIFACT), + new ColorPredicate(ObjectColor.WHITE) + ) + )); + } + public AmrouSeekers(UUID ownerId) { super(ownerId, 2, "Amrou Seekers", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); this.expansionSetCode = "TSP"; @@ -63,7 +68,7 @@ public class AmrouSeekers extends CardImpl { this.toughness = new MageInt(2); // Amrou Seekers can't be blocked except by artifact creatures and/or white creatures. - this.addAbility(new AmrouSeekersEvasionAbility()); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(notArtificatOrWhite, Duration.WhileOnBattlefield))); } @@ -76,57 +81,3 @@ public class AmrouSeekers extends CardImpl { return new AmrouSeekers(this); } } - -class AmrouSeekersEvasionAbility extends EvasionAbility implements MageSingleton { - - public AmrouSeekersEvasionAbility() { - super(); - this.addEffect(new AmrouSeekersRestrictionEffect()); - } - - public AmrouSeekersEvasionAbility(final AmrouSeekersEvasionAbility ability) { - super(ability); - } - - @Override - public String getRule() { - return "Amrou Seekers can't be blocked except by artifact creatures and/or white creatures."; - } - - @Override - public AmrouSeekersEvasionAbility copy() { - return new AmrouSeekersEvasionAbility(this); - } -} - - -class AmrouSeekersRestrictionEffect extends RestrictionEffect { - - private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("artifact creatures and/or white creatures"); - static { - filter.add(Predicates.or(new CardTypePredicate(CardType.ARTIFACT), new ColorPredicate(ObjectColor.WHITE))); - } - - public AmrouSeekersRestrictionEffect() { - super(Duration.WhileOnBattlefield); - } - - public AmrouSeekersRestrictionEffect(final AmrouSeekersRestrictionEffect effect) { - super(effect); - } - - @Override - public boolean applies(Permanent permanent, Ability source, Game game) { - return true; - } - - @Override - public boolean canBeBlocked(Permanent attacker, Permanent blocker, Ability source, Game game) { - return filter.match(blocker, source.getSourceId(), source.getControllerId(), game); - } - - @Override - public AmrouSeekersRestrictionEffect copy() { - return new AmrouSeekersRestrictionEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/timespiral/BlazingBladeAskari.java b/Mage.Sets/src/mage/sets/timespiral/BlazingBladeAskari.java index de158ab2596..d20676a6e54 100644 --- a/Mage.Sets/src/mage/sets/timespiral/BlazingBladeAskari.java +++ b/Mage.Sets/src/mage/sets/timespiral/BlazingBladeAskari.java @@ -29,16 +29,16 @@ package mage.sets.timespiral; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.ObjectColor; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.common.continuous.SetCardColorSourceEffect; +import mage.abilities.effects.common.continuous.BecomesColorSourceEffect; import mage.abilities.keyword.FlankingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; +import mage.constants.Rarity; import mage.constants.Zone; /** @@ -59,7 +59,7 @@ public class BlazingBladeAskari extends CardImpl { // Flanking this.addAbility(new FlankingAbility()); // {2}: Blazing Blade Askari becomes colorless until end of turn. - this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new SetCardColorSourceEffect(new ObjectColor(""), Duration.EndOfTurn), new ManaCostsImpl("{2}"))); + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorSourceEffect(new ObjectColor(), Duration.EndOfTurn), new ManaCostsImpl("{2}"))); } public BlazingBladeAskari(final BlazingBladeAskari card) { diff --git a/Mage.Sets/src/mage/sets/timespiral/Chronosavant.java b/Mage.Sets/src/mage/sets/timespiral/Chronosavant.java new file mode 100644 index 00000000000..9b503cc133d --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/Chronosavant.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnSourceFromGraveyardToBattlefieldEffect; +import mage.abilities.effects.common.turn.SkipNextTurnSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class Chronosavant extends CardImpl { + + public Chronosavant(UUID ownerId) { + super(ownerId, 9, "Chronosavant", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{W}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Giant"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // {1}{W}: Return Chronosavant from your graveyard to the battlefield tapped. You skip your next turn. + Ability ability = new SimpleActivatedAbility(Zone.GRAVEYARD, new ReturnSourceFromGraveyardToBattlefieldEffect(true), new ManaCostsImpl("{1}{W}")); + ability.addEffect(new SkipNextTurnSourceEffect()); + this.addAbility(ability); + } + + public Chronosavant(final Chronosavant card) { + super(card); + } + + @Override + public Chronosavant copy() { + return new Chronosavant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/DeepSeaKraken.java b/Mage.Sets/src/mage/sets/timespiral/DeepSeaKraken.java index ac50ef010e6..1a319bc947f 100644 --- a/Mage.Sets/src/mage/sets/timespiral/DeepSeaKraken.java +++ b/Mage.Sets/src/mage/sets/timespiral/DeepSeaKraken.java @@ -73,7 +73,7 @@ public class DeepSeaKraken extends CardImpl { // Whenever an opponent casts a spell, if Deep-Sea Kraken is suspended, remove a time counter from it. this.addAbility(new ConditionalTriggeredAbility( new SpellCastAllTriggeredAbility(Zone.EXILED, new RemoveCounterSourceEffect(CounterType.TIME.createInstance()), filter, false, SetTargetPointer.NONE), SuspendedCondition.getInstance(), - "Whenever an opponent casts a spell, if Deep-Sea Kraken is suspended, remove a time counter from it.", false)); + "Whenever an opponent casts a spell, if Deep-Sea Kraken is suspended, remove a time counter from it.")); } public DeepSeaKraken(final DeepSeaKraken card) { diff --git a/Mage.Sets/src/mage/sets/timespiral/EmptyTheWarrens.java b/Mage.Sets/src/mage/sets/timespiral/EmptyTheWarrens.java index 5397da90d23..54433fa9763 100644 --- a/Mage.Sets/src/mage/sets/timespiral/EmptyTheWarrens.java +++ b/Mage.Sets/src/mage/sets/timespiral/EmptyTheWarrens.java @@ -28,11 +28,11 @@ package mage.sets.timespiral; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.effects.common.CreateTokenEffect; import mage.abilities.keyword.StormAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.permanent.token.GoblinToken; /** @@ -45,7 +45,6 @@ public class EmptyTheWarrens extends CardImpl { super(ownerId, 152, "Empty the Warrens", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{3}{R}"); this.expansionSetCode = "TSP"; - // Put two 1/1 red Goblin creature tokens onto the battlefield. this.getSpellAbility().addEffect(new CreateTokenEffect(new GoblinToken(), 2)); // Storm diff --git a/Mage.Sets/src/mage/sets/timespiral/FallenIdeal.java b/Mage.Sets/src/mage/sets/timespiral/FallenIdeal.java new file mode 100644 index 00000000000..7f0f46ab9b4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/FallenIdeal.java @@ -0,0 +1,95 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.PutIntoGraveFromBattlefieldSourceTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FallenIdeal extends CardImpl { + + public FallenIdeal(UUID ownerId) { + super(ownerId, 109, "Fallen Ideal", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{B}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature has flying and "Sacrifice a creature: This creature gets +2/+1 until end of turn." + Effect effect = new GainAbilityAttachedEffect(FlyingAbility.getInstance(), AttachmentType.AURA, Duration.WhileOnBattlefield); + Ability gainedAbility = new SimpleStaticAbility(Zone.BATTLEFIELD, effect); + this.addAbility(gainedAbility); + gainedAbility = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 1, Duration.EndOfTurn), + new SacrificeTargetCost(new TargetControlledCreaturePermanent(1, 1, new FilterControlledCreaturePermanent("a creature"), true))); + effect = new GainAbilityAttachedEffect(gainedAbility, AttachmentType.AURA, Duration.WhileOnBattlefield); + effect.setText("Enchanted creature has \"Sacrifice a creature: This creature gets +2/+1 until end of turn.\""); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); + + // When Fallen Ideal is put into a graveyard from the battlefield, return Fallen Ideal to its owner's hand. + this.addAbility(new PutIntoGraveFromBattlefieldSourceTriggeredAbility(new ReturnToHandSourceEffect())); + } + + public FallenIdeal(final FallenIdeal card) { + super(card); + } + + @Override + public FallenIdeal copy() { + return new FallenIdeal(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/FiremawKavu.java b/Mage.Sets/src/mage/sets/timespiral/FiremawKavu.java new file mode 100644 index 00000000000..791e8b600a3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/FiremawKavu.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.keyword.EchoAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FiremawKavu extends CardImpl { + + public FiremawKavu(UUID ownerId) { + super(ownerId, 153, "Firemaw Kavu", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{5}{R}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Kavu"); + this.power = new MageInt(4); + this.toughness = new MageInt(2); + + // Echo {5}{R} + this.addAbility(new EchoAbility("{5}{R}")); + + // When Firemaw Kavu enters the battlefield, it deals 2 damage to target creature. + Ability ability = new EntersBattlefieldTriggeredAbility(new DamageTargetEffect(2)); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // When Firemaw Kavu leaves the battlefield, it deals 4 damage to target creature. + ability = new LeavesBattlefieldTriggeredAbility(new DamageTargetEffect(4), false); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public FiremawKavu(final FiremawKavu card) { + super(card); + } + + @Override + public FiremawKavu copy() { + return new FiremawKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/ForiysianTotem.java b/Mage.Sets/src/mage/sets/timespiral/ForiysianTotem.java new file mode 100644 index 00000000000..f5c35e200ed --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/ForiysianTotem.java @@ -0,0 +1,95 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.SourceMatchesFilterCondition; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.effects.common.combat.CanBlockAdditionalCreatureEffect; +import mage.abilities.effects.common.continuous.BecomesCreatureSourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.abilities.mana.RedManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.permanent.token.Token; + +import java.util.UUID; + +/** + * + * @author klayhamn + */ +public class ForiysianTotem extends CardImpl { + + private final static String ruleText = "As long as {this} is a creature, it can block an additional creature."; + + public ForiysianTotem(UUID ownerId) { + super(ownerId, 254, "Foriysian Totem", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "TSP"; + + // {tap}: Add {R} to your mana pool. + this.addAbility(new RedManaAbility()); + + // {4}{R}: Foriysian Totem becomes a 4/4 red Giant artifact creature with trample until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesCreatureSourceEffect(new ForiysianTotemToken(), "", Duration.EndOfTurn), new ManaCostsImpl<>("{4}{R}"))); + + // As long as Foriysian Totem is a creature, it can block an additional creature. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect(new CanBlockAdditionalCreatureEffect(1), new SourceMatchesFilterCondition(new FilterCreaturePermanent()), ruleText))); + } + + public ForiysianTotem(final ForiysianTotem card) { + super(card); + } + + @Override + public ForiysianTotem copy() { + return new ForiysianTotem(this); + } + +} + +class ForiysianTotemToken extends Token { + + public ForiysianTotemToken() { + super("", "4/4 red Giant artifact creature"); + cardType.add(CardType.CREATURE); + cardType.add(CardType.ARTIFACT); + subtype.add("Giant"); + color.setRed(true); + power = new MageInt(4); + toughness = new MageInt(4); + this.addAbility(TrampleAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/GhituFirebreathing.java b/Mage.Sets/src/mage/sets/timespiral/GhituFirebreathing.java new file mode 100644 index 00000000000..e8203ac9728 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/GhituFirebreathing.java @@ -0,0 +1,86 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlashAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class GhituFirebreathing extends CardImpl { + + public GhituFirebreathing(UUID ownerId) { + super(ownerId, 158, "Ghitu Firebreathing", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Aura"); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // {R}: Enchanted creature gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.R))); + + // {R}: Return Ghitu Firebreathing to its owner's hand. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandSourceEffect(), new ManaCostsImpl("{R}"))); + } + + public GhituFirebreathing(final GhituFirebreathing card) { + super(card); + } + + @Override + public GhituFirebreathing copy() { + return new GhituFirebreathing(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/HerdGnarr.java b/Mage.Sets/src/mage/sets/timespiral/HerdGnarr.java new file mode 100644 index 00000000000..8d2fb429192 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/HerdGnarr.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldControlledTriggeredAbility; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author fireshoes + */ +public class HerdGnarr extends CardImpl { + + private static final FilterPermanent filter = new FilterCreaturePermanent("another creature"); + + static { + filter.add(new AnotherPredicate()); + } + + public HerdGnarr(UUID ownerId) { + super(ownerId, 200, "Herd Gnarr", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Beast"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Whenever another creature enters the battlefield under your control, Herd Gnarr gets +2/+2 until end of turn. + this.addAbility(new EntersBattlefieldControlledTriggeredAbility(new BoostSourceEffect(2, 2, Duration.EndOfTurn), filter)); + } + + public HerdGnarr(final HerdGnarr card) { + super(card); + } + + @Override + public HerdGnarr copy() { + return new HerdGnarr(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/Hypergenesis.java b/Mage.Sets/src/mage/sets/timespiral/Hypergenesis.java index eb88827dd9e..de7538b305a 100644 --- a/Mage.Sets/src/mage/sets/timespiral/Hypergenesis.java +++ b/Mage.Sets/src/mage/sets/timespiral/Hypergenesis.java @@ -102,15 +102,15 @@ class HypergenesisEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { PlayerList playerList = game.getState().getPlayerList().copy(); - while (!playerList.get().equals(source.getControllerId()) && controller.isInGame()) { + while (!playerList.get().equals(source.getControllerId()) && controller.canRespond()) { playerList.getNext(); } Player currentPlayer = game.getPlayer(playerList.get()); UUID firstInactivePlayer = null; Target target = new TargetCardInHand(filter); - while (controller.isInGame()) { - if (currentPlayer != null && currentPlayer.isInGame() && controller.getInRange().contains(currentPlayer.getId())) { + while (controller.canRespond()) { + if (currentPlayer != null && currentPlayer.canRespond() && controller.getInRange().contains(currentPlayer.getId())) { if (firstInactivePlayer == null) { firstInactivePlayer = currentPlayer.getId(); } diff --git a/Mage.Sets/src/mage/sets/timespiral/IcatianCrier.java b/Mage.Sets/src/mage/sets/timespiral/IcatianCrier.java new file mode 100644 index 00000000000..5fe2991a137 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/IcatianCrier.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.permanent.token.CitizenToken; + +/** + * + * @author fireshoes + */ +public class IcatianCrier extends CardImpl { + + public IcatianCrier(UUID ownerId) { + super(ownerId, 23, "Icatian Crier", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Human"); + this.subtype.add("Spellshaper"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {1}{W}, {tap}, Discard a card: Put two 1/1 white Citizen creature tokens onto the battlefield. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new CitizenToken(), 2), new ManaCostsImpl("{1}{W}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + this.addAbility(ability); + } + + public IcatianCrier(final IcatianCrier card) { + super(card); + } + + @Override + public IcatianCrier copy() { + return new IcatianCrier(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/LooterIlKor.java b/Mage.Sets/src/mage/sets/timespiral/LooterIlKor.java index 50d92657baf..967e8f78d3f 100644 --- a/Mage.Sets/src/mage/sets/timespiral/LooterIlKor.java +++ b/Mage.Sets/src/mage/sets/timespiral/LooterIlKor.java @@ -28,13 +28,13 @@ package mage.sets.timespiral; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; -import mage.abilities.effects.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.common.DrawDiscardControllerEffect; import mage.abilities.keyword.ShadowAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; /** * diff --git a/Mage.Sets/src/mage/sets/timespiral/MagusOfTheMirror.java b/Mage.Sets/src/mage/sets/timespiral/MagusOfTheMirror.java new file mode 100644 index 00000000000..135184f14fb --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/MagusOfTheMirror.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class MagusOfTheMirror extends mage.sets.conspiracy.MagusOfTheMirror { + + public MagusOfTheMirror(UUID ownerId) { + super(ownerId); + this.cardNumber = 116; + this.expansionSetCode = "TSP"; + } + + public MagusOfTheMirror(final MagusOfTheMirror card) { + super(card); + } + + @Override + public MagusOfTheMirror copy() { + return new MagusOfTheMirror(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/MagusOfTheScroll.java b/Mage.Sets/src/mage/sets/timespiral/MagusOfTheScroll.java new file mode 100644 index 00000000000..cc4be45df3c --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/MagusOfTheScroll.java @@ -0,0 +1,129 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.NameACardEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class MagusOfTheScroll extends CardImpl { + + public MagusOfTheScroll(UUID ownerId) { + super(ownerId, 169, "Magus of the Scroll", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Human"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {3}, {tap}: Name a card. Reveal a card at random from your hand. If it's the named card, Magus of the Scroll deals 2 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new NameACardEffect(NameACardEffect.TypeOfName.ALL), new ManaCostsImpl("{3}")); + ability.addEffect(new MagusOfTheScrollEffect()); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public MagusOfTheScroll(final MagusOfTheScroll card) { + super(card); + } + + @Override + public MagusOfTheScroll copy() { + return new MagusOfTheScroll(this); + } +} + +class MagusOfTheScrollEffect extends OneShotEffect { + + public MagusOfTheScrollEffect() { + super(Outcome.Neutral); + staticText = "Reveal a card at random from your hand. If it's the named card, {this} deals 2 damage to target creature or player"; + } + + public MagusOfTheScrollEffect(final MagusOfTheScrollEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player you = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + String cardName = (String) game.getState().getValue(source.getSourceId().toString() + NameACardEffect.INFO_KEY); + if (sourceObject != null && you != null && cardName != null && !cardName.isEmpty()) { + if (you.getHand().size() > 0) { + Cards revealed = new CardsImpl(); + Card card = you.getHand().getRandom(game); + revealed.add(card); + you.revealCards(sourceObject.getName(), revealed, game); + if (card.getName().equals(cardName)) { + Permanent creature = game.getPermanent(targetPointer.getFirst(game, source)); + if (creature != null) { + creature.damage(2, source.getSourceId(), game, false, true); + return true; + } + Player player = game.getPlayer(targetPointer.getFirst(game, source)); + if (player != null) { + player.damage(2, source.getSourceId(), game, false, true); + return true; + } + return false; + } + } + return true; + } + return false; + } + + @Override + public MagusOfTheScrollEffect copy() { + return new MagusOfTheScrollEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/MishraArtificerProdigy.java b/Mage.Sets/src/mage/sets/timespiral/MishraArtificerProdigy.java new file mode 100644 index 00000000000..28488d56754 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/MishraArtificerProdigy.java @@ -0,0 +1,189 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.stack.Spell; +import mage.players.Player; +import mage.target.common.TargetCardInHand; +import mage.target.common.TargetCardInLibrary; +import mage.target.common.TargetCardInYourGraveyard; + +/** + * + * @author emerald000 + */ +public class MishraArtificerProdigy extends CardImpl { + + public MishraArtificerProdigy(UUID ownerId) { + super(ownerId, 243, "Mishra, Artificer Prodigy", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}{B}{R}"); + this.expansionSetCode = "TSP"; + this.supertype.add("Legendary"); + this.subtype.add("Human"); + this.subtype.add("Artificer"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // Whenever you cast an artifact spell, you may search your graveyard, hand, and/or library for a card with the same name as that spell and put it onto the battlefield. If you search your library this way, shuffle it. + this.addAbility(new MishraArtificerProdigyTriggeredAbility()); + } + + public MishraArtificerProdigy(final MishraArtificerProdigy card) { + super(card); + } + + @Override + public MishraArtificerProdigy copy() { + return new MishraArtificerProdigy(this); + } +} + +class MishraArtificerProdigyTriggeredAbility extends TriggeredAbilityImpl { + + MishraArtificerProdigyTriggeredAbility() { + super(Zone.BATTLEFIELD, new MishraArtificerProdigyEffect(), true); + } + + MishraArtificerProdigyTriggeredAbility(final MishraArtificerProdigyTriggeredAbility ability) { + super(ability); + } + + @Override + public MishraArtificerProdigyTriggeredAbility copy() { + return new MishraArtificerProdigyTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.SPELL_CAST; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + if (event.getPlayerId().equals(this.getControllerId())) { + Spell spell = game.getStack().getSpell(event.getTargetId()); + if (spell != null && spell.getCardType().contains(CardType.ARTIFACT)) { + ((MishraArtificerProdigyEffect) this.getEffects().get(0)).setName(spell.getName()); + return true; + } + } + return false; + } + + @Override + public String getRule() { + return "Whenever you cast an artifact spell, you may search your graveyard, hand, and/or library for a card with the same name as that spell and put it onto the battlefield. If you search your library this way, shuffle it."; + } +} + +class MishraArtificerProdigyEffect extends OneShotEffect { + + private String cardName; + + MishraArtificerProdigyEffect() { + super(Outcome.PutCardInPlay); + this.staticText = "Search your graveyard, hand, and/or library for a card named " + cardName + " and put it onto the battlefield. If you search your library this way, shuffle it."; + } + + MishraArtificerProdigyEffect(final MishraArtificerProdigyEffect effect) { + super(effect); + this.cardName = effect.cardName; + } + + @Override + public MishraArtificerProdigyEffect copy() { + return new MishraArtificerProdigyEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + FilterCard filter = new FilterCard("card named " + this.cardName); + filter.add(new NamePredicate(cardName)); + Card card = null; + Zone zone = null; + // Graveyard + if (controller.chooseUse(Outcome.Neutral, "Search your graveyard?", source, game)) { + TargetCardInYourGraveyard target = new TargetCardInYourGraveyard(0, 1, filter); + if (controller.choose(Outcome.PutCardInPlay, controller.getGraveyard(), target, game)) { + card = game.getCard(target.getFirstTarget()); + if (card != null) { + zone = Zone.GRAVEYARD; + } + } + } + // Hand + if (card == null && controller.chooseUse(Outcome.Neutral, "Search your hand?", source, game)) { + TargetCardInHand target = new TargetCardInHand(0, 1, filter); + if (controller.choose(Outcome.PutCardInPlay, controller.getHand(), target, game)) { + card = game.getCard(target.getFirstTarget()); + if (card != null) { + zone = Zone.HAND; + } + } + } + // Library + if (card == null && controller.chooseUse(Outcome.Neutral, "Search your library?", source, game)) { + TargetCardInLibrary target = new TargetCardInLibrary(0, 1, filter); + if (controller.searchLibrary(target, game)) { + card = game.getCard(target.getFirstTarget()); + if (card != null) { + zone = Zone.LIBRARY; + } + } + controller.shuffleLibrary(game); + } + // Put on battlefield + if (card != null) { + controller.moveCards(card, zone, Zone.BATTLEFIELD, source, game); + } + return true; + } + return false; + } + + public void setName(String cardName) { + this.cardName = cardName; + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/MwonvuliAcidMoss.java b/Mage.Sets/src/mage/sets/timespiral/MwonvuliAcidMoss.java index 7bb54c0dd5b..ede5bc10ed5 100644 --- a/Mage.Sets/src/mage/sets/timespiral/MwonvuliAcidMoss.java +++ b/Mage.Sets/src/mage/sets/timespiral/MwonvuliAcidMoss.java @@ -1,71 +1,70 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.sets.timespiral; - -import java.util.UUID; -import mage.abilities.effects.common.DestroyTargetEffect; -import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; -import mage.cards.CardImpl; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.filter.common.FilterBasicLandCard; -import mage.filter.common.FilterLandCard; -import mage.filter.common.FilterLandPermanent; -import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.target.TargetPermanent; -import mage.target.common.TargetCardInLibrary; - -/** - * - * @author markedagain - */ -public class MwonvuliAcidMoss extends CardImpl { - - public MwonvuliAcidMoss(UUID ownerId) { - super(ownerId, 207, "Mwonvuli Acid-Moss", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}{G}"); - this.expansionSetCode = "TSP"; - - FilterLandCard filterForest = new FilterLandCard(); - filterForest.add(new SubtypePredicate("Forest")); - - // Destroy target land. Search your library for a Forest card and put that card onto the battlefield tapped. Then shuffle your library. - this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); - this.getSpellAbility().addTarget(new TargetPermanent(new FilterLandPermanent())); - this.getSpellAbility().addEffect(new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(filterForest), false, true)); - } - - public MwonvuliAcidMoss(final MwonvuliAcidMoss card) { - super(card); - } - - @Override - public MwonvuliAcidMoss copy() { - return new MwonvuliAcidMoss(this); - } -} - +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterLandCard; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCardInLibrary; + +/** + * + * @author markedagain + */ +public class MwonvuliAcidMoss extends CardImpl { + + public MwonvuliAcidMoss(UUID ownerId) { + super(ownerId, 207, "Mwonvuli Acid-Moss", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}{G}"); + this.expansionSetCode = "TSP"; + + FilterLandCard filterForest = new FilterLandCard(); + filterForest.add(new SubtypePredicate("Forest")); + + // Destroy target land. Search your library for a Forest card and put that card onto the battlefield tapped. Then shuffle your library. + this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); + this.getSpellAbility().addTarget(new TargetPermanent(new FilterLandPermanent())); + this.getSpellAbility().addEffect(new SearchLibraryPutInPlayEffect(new TargetCardInLibrary(filterForest), true, true)); + } + + public MwonvuliAcidMoss(final MwonvuliAcidMoss card) { + super(card); + } + + @Override + public MwonvuliAcidMoss copy() { + return new MwonvuliAcidMoss(this); + } +} + diff --git a/Mage.Sets/src/mage/sets/timespiral/NorinTheWary.java b/Mage.Sets/src/mage/sets/timespiral/NorinTheWary.java index b87f928ade1..1b0a67fb131 100644 --- a/Mage.Sets/src/mage/sets/timespiral/NorinTheWary.java +++ b/Mage.Sets/src/mage/sets/timespiral/NorinTheWary.java @@ -73,7 +73,7 @@ public class NorinTheWary extends CardImpl { class NorinTheWaryTriggeredAbility extends TriggeredAbilityImpl { public NorinTheWaryTriggeredAbility() { - super(Zone.BATTLEFIELD, new ExileReturnToBattlefieldOwnerNextEndStepEffect(), false); + super(Zone.BATTLEFIELD, new ExileReturnToBattlefieldOwnerNextEndStepEffect(true), false); } public NorinTheWaryTriggeredAbility(final NorinTheWaryTriggeredAbility ability) { diff --git a/Mage.Sets/src/mage/sets/timespiral/OpalineSliver.java b/Mage.Sets/src/mage/sets/timespiral/OpalineSliver.java index b891c5f5c31..f653af6f14a 100644 --- a/Mage.Sets/src/mage/sets/timespiral/OpalineSliver.java +++ b/Mage.Sets/src/mage/sets/timespiral/OpalineSliver.java @@ -112,7 +112,7 @@ class OpalineSliverTriggeredAbility extends TriggeredAbilityImpl { } else { return event.getTargetId().equals(this.getSourceId()) && game.getOpponents(this.controllerId).contains(event.getPlayerId()) - && spellCard.match(spell, event.getPlayerId(), game); + && spellCard.match(spell, getSourceId(), getControllerId(), game); } } diff --git a/Mage.Sets/src/mage/sets/timespiral/PentarchWard.java b/Mage.Sets/src/mage/sets/timespiral/PentarchWard.java new file mode 100644 index 00000000000..38169026a3c --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/PentarchWard.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.common.AsEntersBattlefieldAbility; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ChooseColorEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.keyword.ProtectionChosenColorAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class PentarchWard extends CardImpl { + + public PentarchWard(UUID ownerId) { + super(ownerId, 33, "Pentarch Ward", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{W}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Protect)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // When Pentarch Ward enters the battlefield, draw a card. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1))); + + // As Pentarch Ward enters the battlefield, choose a color. + this.addAbility(new AsEntersBattlefieldAbility(new ChooseColorEffect(Outcome.Benefit))); + + // Enchanted creature has protection from the chosen color. This effect doesn't remove Pentarch Ward. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ProtectionChosenColorAttachedEffect(true))); + } + + public PentarchWard(final PentarchWard card) { + super(card); + } + + @Override + public PentarchWard copy() { + return new PentarchWard(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/SlipstreamSerpent.java b/Mage.Sets/src/mage/sets/timespiral/SlipstreamSerpent.java new file mode 100644 index 00000000000..298b8f3c143 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/SlipstreamSerpent.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.keyword.MorphAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author fireshoes + */ +public class SlipstreamSerpent extends CardImpl { + + public SlipstreamSerpent(UUID ownerId) { + super(ownerId, 77, "Slipstream Serpent", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{7}{U}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Serpent"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // Slipstream Serpent can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // When you control no Islands, sacrifice Slipstream Serpent. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + + // Morph {5}{U} + this.addAbility(new MorphAbility(this, new ManaCostsImpl("{5}{U}"))); + } + + public SlipstreamSerpent(final SlipstreamSerpent card) { + super(card); + } + + @Override + public SlipstreamSerpent copy() { + return new SlipstreamSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/SpectralForce.java b/Mage.Sets/src/mage/sets/timespiral/SpectralForce.java new file mode 100644 index 00000000000..42a566327d2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/SpectralForce.java @@ -0,0 +1,118 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.common.DontUntapInControllersNextUntapStepSourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; + +/** + * + * @author fireshoes + */ +public class SpectralForce extends CardImpl { + + public SpectralForce(UUID ownerId) { + super(ownerId, 217, "Spectral Force", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}{G}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Elemental"); + this.subtype.add("Spirit"); + this.power = new MageInt(8); + this.toughness = new MageInt(8); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // Whenever Spectral Force attacks, if defending player controls no black permanents, it doesn't untap during your next untap step. + this.addAbility(new SpectralForceTriggeredAbility()); + } + + public SpectralForce(final SpectralForce card) { + super(card); + } + + @Override + public SpectralForce copy() { + return new SpectralForce(this); + } +} + +class SpectralForceTriggeredAbility extends TriggeredAbilityImpl { + + private static final FilterPermanent filter = new FilterPermanent("black permanents"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + } + + public SpectralForceTriggeredAbility() { + super(Zone.BATTLEFIELD, new DontUntapInControllersNextUntapStepSourceEffect()); + } + + public SpectralForceTriggeredAbility(final SpectralForceTriggeredAbility ability) { + super(ability); + } + + @Override + public SpectralForceTriggeredAbility copy() { + return new SpectralForceTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.ATTACKER_DECLARED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return event.getSourceId().equals(this.getSourceId()); + } + + @Override + public boolean checkInterveningIfClause(Game game) { + UUID defendingPlayerId = game.getCombat().getDefendingPlayerId(getSourceId(), game); + return defendingPlayerId != null && game.getBattlefield().countAll(filter, defendingPlayerId, game) < 1; + } + + @Override + public String getRule() { + return "Whenever {this} attacks, if defending player controls no black permanents, it doesn't untap during your next untap step."; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/StonewoodInvocation.java b/Mage.Sets/src/mage/sets/timespiral/StonewoodInvocation.java new file mode 100644 index 00000000000..48f2b638f5a --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/StonewoodInvocation.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.abilities.keyword.SplitSecondAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class StonewoodInvocation extends CardImpl { + + public StonewoodInvocation(UUID ownerId) { + super(ownerId, 223, "Stonewood Invocation", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{3}{G}"); + this.expansionSetCode = "TSP"; + + // Split second + this.addAbility(new SplitSecondAbility()); + + // Target creature gets +5/+5 and gains shroud until end of turn. + Effect effect = new BoostTargetEffect(5, 5, Duration.EndOfTurn); + effect.setText("Target creature gets +5/+5"); + this.getSpellAbility().addEffect(effect); + effect = new GainAbilityTargetEffect(ShroudAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and gains shroud until end of turn"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public StonewoodInvocation(final StonewoodInvocation card) { + super(card); + } + + @Override + public StonewoodInvocation copy() { + return new StonewoodInvocation(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/StuffyDoll.java b/Mage.Sets/src/mage/sets/timespiral/StuffyDoll.java index e1495a01e1c..7927019a7b4 100644 --- a/Mage.Sets/src/mage/sets/timespiral/StuffyDoll.java +++ b/Mage.Sets/src/mage/sets/timespiral/StuffyDoll.java @@ -173,7 +173,7 @@ class StuffyDollGainLifeEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { UUID playerId = (UUID) game.getState().getValue(source.getSourceId() + "_player"); Player player = game.getPlayer(playerId); - if (player != null && player.isInGame()) { + if (player != null && player.canRespond()) { player.damage((Integer) this.getValue("damageAmount"), source.getSourceId(), game, false, true); } return true; diff --git a/Mage.Sets/src/mage/sets/timespiral/SulfurousBlast.java b/Mage.Sets/src/mage/sets/timespiral/SulfurousBlast.java new file mode 100644 index 00000000000..e6e173673b4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/SulfurousBlast.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.abilities.condition.common.MyMainPhaseCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class SulfurousBlast extends CardImpl { + + public SulfurousBlast(UUID ownerId) { + super(ownerId, 180, "Sulfurous Blast", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{2}{R}{R}"); + this.expansionSetCode = "TSP"; + + // Sulfurous Blast deals 2 damage to each creature and each player. If you cast this spell during your main phase, Sulfurous Blast deals 3 damage to each creature and each player instead. + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new DamageEverythingEffect(3), + new DamageEverythingEffect(2), + MyMainPhaseCondition.getInstance(), + "Sulfurous Blast deals 2 damage to each creature and each player. If you cast this spell during your main phase, Sulfurous Blast deals 3 damage to each creature and each player instead")); + } + + public SulfurousBlast(final SulfurousBlast card) { + super(card); + } + + @Override + public SulfurousBlast copy() { + return new SulfurousBlast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/ThunderTotem.java b/Mage.Sets/src/mage/sets/timespiral/ThunderTotem.java new file mode 100644 index 00000000000..eb0a4cdeddf --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/ThunderTotem.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesCreatureSourceEffect; +import mage.abilities.keyword.FirstStrikeAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.mana.WhiteManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.permanent.token.Token; + +/** + * + * @author fireshoes + */ +public class ThunderTotem extends CardImpl { + + public ThunderTotem(UUID ownerId) { + super(ownerId, 265, "Thunder Totem", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "TSP"; + + // {tap}: Add {W} to your mana pool. + this.addAbility(new WhiteManaAbility()); + + // {1}{W}{W}: Thunder Totem becomes a 2/2 white Spirit artifact creature with flying and first strike until end of turn. + this.addAbility(new SimpleActivatedAbility( + Zone.BATTLEFIELD, + new BecomesCreatureSourceEffect(new ThunderTotemToken(), "", Duration.EndOfTurn), + new ManaCostsImpl("{1}{W}{W}"))); + } + + public ThunderTotem(final ThunderTotem card) { + super(card); + } + + @Override + public ThunderTotem copy() { + return new ThunderTotem(this); + } + +private class ThunderTotemToken extends Token { + ThunderTotemToken() { + super("", "a 2/2 white Spirit artifact creature with flying and first strike"); + cardType.add(CardType.ARTIFACT); + cardType.add(CardType.CREATURE); + color.setWhite(true); + this.subtype.add("Spirit"); + power = new MageInt(2); + toughness = new MageInt(2); + this.addAbility(FlyingAbility.getInstance()); + this.addAbility(FirstStrikeAbility.getInstance()); + } + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/TrespasserIlVec.java b/Mage.Sets/src/mage/sets/timespiral/TrespasserIlVec.java new file mode 100644 index 00000000000..aa4bd8a938f --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/TrespasserIlVec.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.ShadowAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class TrespasserIlVec extends CardImpl { + + public TrespasserIlVec(UUID ownerId) { + super(ownerId, 138, "Trespasser il-Vec", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Human"); + this.subtype.add("Rogue"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // Discard a card: Trespasser il-Vec gains shadow until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new GainAbilitySourceEffect(ShadowAbility.getInstance(), Duration.EndOfTurn), + new DiscardCardCost())); + } + + public TrespasserIlVec(final TrespasserIlVec card) { + super(card); + } + + @Override + public TrespasserIlVec copy() { + return new TrespasserIlVec(this); + } +} diff --git a/Mage.Sets/src/mage/sets/timespiral/Triskelavus.java b/Mage.Sets/src/mage/sets/timespiral/Triskelavus.java new file mode 100644 index 00000000000..704c4c478d8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/Triskelavus.java @@ -0,0 +1,99 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.RemoveCountersSourceCost; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.permanent.token.Token; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class Triskelavus extends CardImpl { + + public Triskelavus(UUID ownerId) { + super(ownerId, 266, "Triskelavus", Rarity.RARE, new CardType[]{CardType.ARTIFACT, CardType.CREATURE}, "{7}"); + this.expansionSetCode = "TSP"; + this.subtype.add("Construct"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Triskelavus enters the battlefield with three +1/+1 counters on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.P1P1.createInstance(3)), "with three +1/+1 counters on it")); + + // {1}, Remove a +1/+1 counter from Triskelavus: Put a 1/1 colorless Triskelavite artifact creature token with flying onto the battlefield. It has "Sacrifice this creature: This creature deals 1 damage to target creature or player." + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new TriskelaviteToken()), new RemoveCountersSourceCost(CounterType.P1P1.createInstance()))); + } + + public Triskelavus(final Triskelavus card) { + super(card); + } + + @Override + public Triskelavus copy() { + return new Triskelavus(this); + } +} + +class TriskelaviteToken extends Token { + + public TriskelaviteToken() { + super("Triskelavite", "1/1 colorless Triskelavite artifact creature token with flying onto the battlefield. It has \"Sacrifice this creature: This creature deals 1 damage to target creature or player.\""); + this.setOriginalExpansionSetCode("TSP"); + cardType.add(CardType.ARTIFACT); + cardType.add(CardType.CREATURE); + subtype.add("Triskelavite"); + power = new MageInt(1); + toughness = new MageInt(1); + + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + + addAbility(FlyingAbility.getInstance()); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/timespiral/VoidmageHusher.java b/Mage.Sets/src/mage/sets/timespiral/VoidmageHusher.java new file mode 100644 index 00000000000..f74b44b3dcb --- /dev/null +++ b/Mage.Sets/src/mage/sets/timespiral/VoidmageHusher.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.timespiral; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author andyfries + */ +public class VoidmageHusher extends mage.sets.mediainserts.VoidmageHusher { + + public VoidmageHusher(UUID ownerId) { + super(ownerId); + this.cardNumber = 92; + this.expansionSetCode = "TSP"; + this.rarity = Rarity.UNCOMMON; + } + + public VoidmageHusher(final VoidmageHusher card) { + super(card); + } + + @Override + public VoidmageHusher copy() { + return new VoidmageHusher(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/BarbarianOutcast.java b/Mage.Sets/src/mage/sets/torment/BarbarianOutcast.java new file mode 100644 index 00000000000..0becdaa5ed7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/BarbarianOutcast.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author fireshoes + */ +public class BarbarianOutcast extends CardImpl { + + private static final FilterControlledLandPermanent filterControlledLand = new FilterControlledLandPermanent("a Swamp"); + + static { + filterControlledLand.add(new SubtypePredicate("Swamp")); + } + + public BarbarianOutcast(UUID ownerId) { + super(ownerId, 92, "Barbarian Outcast", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{R}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Human"); + this.subtype.add("Barbarian"); + this.subtype.add("Beast"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // When you control no Swamps, sacrifice Barbarian Outcast. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Swamp", "no Swamps"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public BarbarianOutcast(final BarbarianOutcast card) { + super(card); + } + + @Override + public BarbarianOutcast copy() { + return new BarbarianOutcast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/CephalidAristocrat.java b/Mage.Sets/src/mage/sets/torment/CephalidAristocrat.java new file mode 100644 index 00000000000..f0c831e3a10 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/CephalidAristocrat.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BecomesTargetTriggeredAbility; +import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class CephalidAristocrat extends CardImpl { + + public CephalidAristocrat(UUID ownerId) { + super(ownerId, 27, "Cephalid Aristocrat", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Cephalid"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Whenever Cephalid Aristocrat becomes the target of a spell or ability, put the top two cards of your library into your graveyard. + this.addAbility(new BecomesTargetTriggeredAbility(new PutTopCardOfLibraryIntoGraveControllerEffect(2))); + } + + public CephalidAristocrat(final CephalidAristocrat card) { + super(card); + } + + @Override + public CephalidAristocrat copy() { + return new CephalidAristocrat(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/CephalidVandal.java b/Mage.Sets/src/mage/sets/torment/CephalidVandal.java new file mode 100644 index 00000000000..6aa724c6288 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/CephalidVandal.java @@ -0,0 +1,105 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class CephalidVandal extends CardImpl { + + public CephalidVandal(UUID ownerId) { + super(ownerId, 31, "Cephalid Vandal", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Cephalid"); + this.subtype.add("Rogue"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // At the beginning of your upkeep, put a shred counter on Cephalid Vandal. Then put the top card of your library into your graveyard for each shred counter on Cephalid Vandal. + Effect effect = new CephalidVandalEffect(); + Ability ability = new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.SHRED.createInstance(), false), TargetController.YOU, false); + ability.addEffect(effect); + this.addAbility(ability); + } + + public CephalidVandal(final CephalidVandal card) { + super(card); + } + + @Override + public CephalidVandal copy() { + return new CephalidVandal(this); + } +} + +class CephalidVandalEffect extends OneShotEffect { + + public CephalidVandalEffect() { + super(Outcome.Neutral); + staticText = "Then put the top card of your library into your graveyard for each shred counter on {this}"; + } + + public CephalidVandalEffect(final CephalidVandalEffect effect) { + super(effect); + } + + @Override + public CephalidVandalEffect copy() { + return new CephalidVandalEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null && controller != null) { + int amount = permanent.getCounters().getCount(CounterType.SHRED); + controller.moveCards(controller.getLibrary().getTopCards(game, amount), Zone.LIBRARY, Zone.GRAVEYARD, source, game); + } + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/torment/CoralNet.java b/Mage.Sets/src/mage/sets/torment/CoralNet.java new file mode 100644 index 00000000000..154f49307c2 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/CoralNet.java @@ -0,0 +1,96 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CoralNet extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("green or white creature"); + + static { + filter.add(Predicates.or( + new ColorPredicate(ObjectColor.WHITE), + new ColorPredicate(ObjectColor.GREEN))); + } + + static private final String rule = "Enchanted creature has \"At the beginning of your upkeep, sacrifice this creature unless you discard a card.\""; + + public CoralNet(UUID ownerId) { + super(ownerId, 35, "Coral Net", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{U}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Aura"); + + // Enchant green or white creature + TargetPermanent auraTarget = new TargetCreaturePermanent(filter); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // Enchanted creature has "At the beginning of your upkeep, sacrifice this creature unless you discard a card." + Ability abilityToGain = new BeginningOfUpkeepTriggeredAbility( + new SacrificeSourceUnlessPaysEffect(new DiscardCardCost()), TargetController.YOU, false); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, + new GainAbilityAttachedEffect(abilityToGain, AttachmentType.AURA, Duration.WhileOnBattlefield, rule))); + } + + public CoralNet(final CoralNet card) { + super(card); + } + + @Override + public CoralNet copy() { + return new CoralNet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/CripplingFatigue.java b/Mage.Sets/src/mage/sets/torment/CripplingFatigue.java new file mode 100644 index 00000000000..d0ae4762c02 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/CripplingFatigue.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.abilities.keyword.FlashbackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TimingRule; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class CripplingFatigue extends CardImpl { + + public CripplingFatigue(UUID ownerId) { + super(ownerId, 58, "Crippling Fatigue", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{B}{B}"); + this.expansionSetCode = "TOR"; + + // Target creature gets -2/-2 until end of turn. + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + this.getSpellAbility().addEffect(new BoostTargetEffect(-2, -2, Duration.EndOfTurn)); + + // Flashback-{1}{B}, Pay 3 life + Ability ability = new FlashbackAbility(new ManaCostsImpl("{1}{B}"), TimingRule.SORCERY); + ability.addCost(new PayLifeCost(3)); + this.addAbility(ability); + } + + public CripplingFatigue(final CripplingFatigue card) { + super(card); + } + + @Override + public CripplingFatigue copy() { + return new CripplingFatigue(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/FlashOfDefiance.java b/Mage.Sets/src/mage/sets/torment/FlashOfDefiance.java new file mode 100644 index 00000000000..b537c088f8c --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/FlashOfDefiance.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CantBlockAllEffect; +import mage.abilities.keyword.FlashbackAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TimingRule; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class FlashOfDefiance extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("green creatures and white creatures"); + + static { + filter.add(Predicates.or( + new ColorPredicate(ObjectColor.WHITE), + new ColorPredicate(ObjectColor.GREEN))); + } + + public FlashOfDefiance(UUID ownerId) { + super(ownerId, 99, "Flash of Defiance", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{R}"); + this.expansionSetCode = "TOR"; + + // Green creatures and white creatures can't block this turn. + this.getSpellAbility().addEffect(new CantBlockAllEffect(filter, Duration.EndOfTurn)); + + // Flashback-{1}{R}, Pay 3 life. + Ability ability = new FlashbackAbility(new ManaCostsImpl("{1}{R}"), TimingRule.SORCERY); + ability.addCost(new PayLifeCost(3)); + this.addAbility(ability); + } + + public FlashOfDefiance(final FlashOfDefiance card) { + super(card); + } + + @Override + public FlashOfDefiance copy() { + return new FlashOfDefiance(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/HydromorphGuardian.java b/Mage.Sets/src/mage/sets/torment/HydromorphGuardian.java new file mode 100644 index 00000000000..261fc1c2e34 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/HydromorphGuardian.java @@ -0,0 +1,115 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterSpell; +import mage.filter.predicate.ObjectSourcePlayer; +import mage.filter.predicate.ObjectSourcePlayerPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.game.stack.Spell; +import mage.target.Target; +import mage.target.TargetSpell; + +/** + * + * @author TaVSt + */ +public class HydromorphGuardian extends CardImpl { + + private final static FilterSpell filter = new FilterSpell("spell that targets one or more creatures you control"); + + static { + filter.add(new HydromorphGuardianPredicate()); + } + + public HydromorphGuardian(UUID ownerId) { + super(ownerId, 39, "Hydromorph Guardian", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Elemental"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {U}, Sacrifice Hydromorph Guardian: Counter target spell that targets one or more creatures you control. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CounterTargetEffect(), new ColoredManaCost(ColoredManaSymbol.U)); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetSpell(filter)); + this.addAbility(ability); + } + + public HydromorphGuardian(final HydromorphGuardian card) { + super(card); + } + + @Override + public HydromorphGuardian copy() { + return new HydromorphGuardian(this); + } +} + +class HydromorphGuardianPredicate implements ObjectSourcePlayerPredicate> { + + @Override + public boolean apply(ObjectSourcePlayer input, Game game) { + Spell spell = game.getStack().getSpell(input.getObject().getId()); + if (spell != null) { + for (UUID modeId : spell.getSpellAbility().getModes().getSelectedModes()) { + Mode mode = spell.getSpellAbility().getModes().get(modeId); + for (Target target : mode.getTargets()) { + for (UUID targetId : target.getTargets()) { + Permanent permanent = game.getPermanent(targetId); + if (permanent.getCardType().contains(CardType.CREATURE) + && permanent.getControllerId().equals(input.getPlayerId())) { + return true; + } + } + } + } + } + return false; + } + + @Override + public String toString() { + return "that targets one or more creatures you control"; + } +} diff --git a/Mage.Sets/src/mage/sets/torment/KrosanRestorer.java b/Mage.Sets/src/mage/sets/torment/KrosanRestorer.java new file mode 100644 index 00000000000..83b0dcc2f8a --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/KrosanRestorer.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.condition.common.CardsInControllerGraveCondition; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.decorator.ConditionalActivatedAbility; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class KrosanRestorer extends CardImpl { + + public KrosanRestorer(UUID ownerId) { + super(ownerId, 130, "Krosan Restorer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{G}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Human"); + this.subtype.add("Druid"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {tap}: Untap target land. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new UntapTargetEffect(), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + + // Threshold - {tap}: Untap up to three target lands. Activate this ability only if seven or more cards are in your graveyard. + ability = new ConditionalActivatedAbility(Zone.BATTLEFIELD, + new UntapTargetEffect(), + new TapSourceCost(), + new CardsInControllerGraveCondition(7), + "Threshold - {T}: Untap up to three target lands. Activate this ability only if seven or more cards are in your graveyard."); + ability.addTarget(new TargetLandPermanent(0, 3, new FilterLandPermanent(), false)); + this.addAbility(ability); + } + + public KrosanRestorer(final KrosanRestorer card) { + super(card); + } + + @Override + public KrosanRestorer copy() { + return new KrosanRestorer(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/MesmericFiend.java b/Mage.Sets/src/mage/sets/torment/MesmericFiend.java index e04a248377b..b1d4d738348 100644 --- a/Mage.Sets/src/mage/sets/torment/MesmericFiend.java +++ b/Mage.Sets/src/mage/sets/torment/MesmericFiend.java @@ -71,7 +71,7 @@ public class MesmericFiend extends CardImpl { this.addAbility(ability); // When Mesmeric Fiend leaves the battlefield, return the exiled card to its owner's hand. - this.addAbility(new LeavesBattlefieldTriggeredAbility(new MesmericFiendLeaveEffect(), false )); + this.addAbility(new LeavesBattlefieldTriggeredAbility(new MesmericFiendLeaveEffect(), false)); } public MesmericFiend(final MesmericFiend card) { @@ -83,6 +83,7 @@ public class MesmericFiend extends CardImpl { return new MesmericFiend(this); } } + class MesmericFiendExileEffect extends OneShotEffect { public MesmericFiendExileEffect() { @@ -120,7 +121,6 @@ class MesmericFiendExileEffect extends OneShotEffect { return false; } - } class MesmericFiendLeaveEffect extends OneShotEffect { @@ -143,18 +143,13 @@ class MesmericFiendLeaveEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = source.getSourceObject(game); - if (controller != null && sourceObject !=null) { - int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() -1; + if (controller != null && sourceObject != null) { + int zoneChangeCounter = (sourceObject instanceof PermanentToken) ? source.getSourceObjectZoneChangeCounter() : source.getSourceObjectZoneChangeCounter() - 1; ExileZone exZone = game.getExile().getExileZone(CardUtil.getExileZoneId(game, source.getSourceId(), zoneChangeCounter)); if (exZone != null) { - for (Card card : exZone.getCards(game)) { - if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.EXILED); - } - } - return true; + return controller.moveCards(exZone, null, Zone.HAND, source, game); } } return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/torment/SickeningDreams.java b/Mage.Sets/src/mage/sets/torment/SickeningDreams.java new file mode 100644 index 00000000000..84c68615434 --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/SickeningDreams.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class SickeningDreams extends mage.sets.pdsgraveborn.SickeningDreams { + + public SickeningDreams(UUID ownerId) { + super(ownerId); + this.cardNumber = 83; + this.expansionSetCode = "TOR"; + } + + public SickeningDreams(final SickeningDreams card) { + super(card); + } + + @Override + public SickeningDreams copy() { + return new SickeningDreams(this); + } +} diff --git a/Mage.Sets/src/mage/sets/torment/StupefyingTouch.java b/Mage.Sets/src/mage/sets/torment/StupefyingTouch.java new file mode 100644 index 00000000000..e52c34e006b --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/StupefyingTouch.java @@ -0,0 +1,116 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.RestrictionEffect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class StupefyingTouch extends CardImpl { + + public StupefyingTouch(UUID ownerId) { + super(ownerId, 48, "Stupefying Touch", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}"); + this.expansionSetCode = "TOR"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // When Stupefying Touch enters the battlefield, draw a card. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(1), false)); + + // Enchanted creature's activated abilities can't be activated. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantActivateAbilitiesAttachedEffect())); + } + + public StupefyingTouch(final StupefyingTouch card) { + super(card); + } + + @Override + public StupefyingTouch copy() { + return new StupefyingTouch(this); + } +} + +class CantActivateAbilitiesAttachedEffect extends RestrictionEffect { + + public CantActivateAbilitiesAttachedEffect() { + super(Duration.WhileOnBattlefield); + staticText = "Enchanted creature's activated abilities can't be activated"; + } + + public CantActivateAbilitiesAttachedEffect(final CantActivateAbilitiesAttachedEffect effect) { + super(effect); + } + + @Override + public boolean applies(Permanent permanent, Ability source, Game game) { + Permanent enchantment = game.getPermanent(source.getSourceId()); + if (enchantment != null && enchantment.getAttachedTo() != null) { + if (permanent.getId().equals(enchantment.getAttachedTo())) { + return true; + } + } + return false; + } + + @Override + public boolean canUseActivatedAbilities(Permanent permanent, Ability source, Game game) { + return false; + } + + @Override + public CantActivateAbilitiesAttachedEffect copy() { + return new CantActivateAbilitiesAttachedEffect(this); + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/torment/VengefulDreams.java b/Mage.Sets/src/mage/sets/torment/VengefulDreams.java new file mode 100644 index 00000000000..42b78e2114c --- /dev/null +++ b/Mage.Sets/src/mage/sets/torment/VengefulDreams.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.torment; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.common.DiscardXTargetCost; +import mage.abilities.dynamicvalue.common.GetXValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.common.FilterAttackingCreature; +import mage.game.Game; +import mage.target.Target; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class VengefulDreams extends CardImpl { + + public VengefulDreams(UUID ownerId) { + super(ownerId, 21, "Vengeful Dreams", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{W}{W}"); + this.expansionSetCode = "TOR"; + + // As an additional cost to cast Vengeful Dreams, discard X cards. + this.getSpellAbility().addCost(new DiscardXTargetCost(new FilterCard("cards"), true)); + + // Exile X target attacking creatures. + Effect effect = new ExileTargetEffect(); + effect.setText("Exile X target attacking creatures"); + this.getSpellAbility().addEffect(effect); + } + + public VengefulDreams(final VengefulDreams card) { + super(card); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + int xValue = new GetXValue().calculate(game, ability, null); + Target target = new TargetCreaturePermanent(0, xValue, new FilterAttackingCreature(), false); + ability.addTarget(target); + } + + @Override + public VengefulDreams copy() { + return new VengefulDreams(this); + } +} diff --git a/Mage.Sets/src/mage/sets/unlimitededition/Channel.java b/Mage.Sets/src/mage/sets/unlimitededition/Channel.java new file mode 100644 index 00000000000..6258241b39c --- /dev/null +++ b/Mage.Sets/src/mage/sets/unlimitededition/Channel.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.unlimitededition; + +import java.util.UUID; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 97; + this.expansionSetCode = "2ED"; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/unlimitededition/Deathgrip.java b/Mage.Sets/src/mage/sets/unlimitededition/Deathgrip.java new file mode 100644 index 00000000000..5467ba0936c --- /dev/null +++ b/Mage.Sets/src/mage/sets/unlimitededition/Deathgrip.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.unlimitededition; + +import java.util.UUID; + +/** + * + * @author anonymous + */ +public class Deathgrip extends mage.sets.limitedbeta.Deathgrip { + + public Deathgrip(UUID ownerId) { + super(ownerId); + this.cardNumber = 9; + this.expansionSetCode = "2ED"; + } + + public Deathgrip(final Deathgrip card) { + super(card); + } + + @Override + public Deathgrip copy() { + return new Deathgrip(this); + } +} diff --git a/Mage.Sets/src/mage/sets/unlimitededition/IslandSanctuary.java b/Mage.Sets/src/mage/sets/unlimitededition/IslandSanctuary.java new file mode 100644 index 00000000000..f7c31dedb27 --- /dev/null +++ b/Mage.Sets/src/mage/sets/unlimitededition/IslandSanctuary.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.unlimitededition; + +import java.util.UUID; + +/** + * + * @author LevelX2 + */ +public class IslandSanctuary extends mage.sets.limitedalpha.IslandSanctuary { + + public IslandSanctuary(UUID ownerId) { + super(ownerId); + this.cardNumber = 210; + this.expansionSetCode = "2ED"; + } + + public IslandSanctuary(final IslandSanctuary card) { + super(card); + } + + @Override + public IslandSanctuary copy() { + return new IslandSanctuary(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/CovetousDragon.java b/Mage.Sets/src/mage/sets/urzasdestiny/CovetousDragon.java new file mode 100644 index 00000000000..03d130e3e28 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/CovetousDragon.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterArtifactPermanent; + +/** + * + * @author fireshoes + */ +public class CovetousDragon extends CardImpl { + + public CovetousDragon(UUID ownerId) { + super(ownerId, 80, "Covetous Dragon", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{4}{R}"); + this.expansionSetCode = "UDS"; + this.subtype.add("Dragon"); + this.power = new MageInt(6); + this.toughness = new MageInt(5); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When you control no artifacts, sacrifice Covetous Dragon. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterArtifactPermanent(), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public CovetousDragon(final CovetousDragon card) { + super(card); + } + + @Override + public CovetousDragon copy() { + return new CovetousDragon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/Gamekeeper.java b/Mage.Sets/src/mage/sets/urzasdestiny/Gamekeeper.java new file mode 100644 index 00000000000..71b6e21e76b --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/Gamekeeper.java @@ -0,0 +1,119 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.MageInt; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.DiesTriggeredAbility; +import mage.abilities.costs.common.ExileSourceFromGraveCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.ExileSourceEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class Gamekeeper extends CardImpl { + + public Gamekeeper(UUID ownerId) { + super(ownerId, 106, "Gamekeeper", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "UDS"; + this.subtype.add("Elf"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // When Gamekeeper dies, you may exile it. If you do, reveal cards from the top of your library until you reveal a creature card. Put that card onto the battlefield and put all other cards revealed this way into your graveyard. + Ability ability = new DiesTriggeredAbility(new DoIfCostPaid(new GamekeeperEffect(), new ExileSourceFromGraveCost(), "Exile to reveal cards from the top of your library until you reveal a creature card?"), false); + this.addAbility(ability); + } + + public Gamekeeper(final Gamekeeper card) { + super(card); + } + + @Override + public Gamekeeper copy() { + return new Gamekeeper(this); + } +} + +class GamekeeperEffect extends OneShotEffect { + + + + public GamekeeperEffect() { + super(Outcome.Benefit); + staticText = "reveal cards from the top of your library until you reveal a creature card. Put that card onto the battlefield and put all other cards revealed this way into your graveyard"; + } + + public GamekeeperEffect(final GamekeeperEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + new ExileSourceEffect().apply(game, source); + Cards revealedCards = new CardsImpl(); + while (controller.getLibrary().size() > 0) { + Card card = controller.getLibrary().removeFromTop(game); + if (card.getCardType().contains(CardType.CREATURE)) { + controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, source.getSourceId()); + break; + } + revealedCards.add(card); + } + controller.revealCards("Gamekeeper", revealedCards, game); + for (Card card: revealedCards.getCards(game)) { + card.moveToZone(Zone.GRAVEYARD, source.getSourceId(), game, true); + } + return true; + } + return false; + } + + @Override + public GamekeeperEffect copy() { + return new GamekeeperEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/MaskOfLawAndGrace.java b/Mage.Sets/src/mage/sets/urzasdestiny/MaskOfLawAndGrace.java new file mode 100644 index 00000000000..03e7bdc436f --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/MaskOfLawAndGrace.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.ObjectColor; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.ProtectionAbility; +import mage.cards.CardImpl; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class MaskOfLawAndGrace extends CardImpl { + + private static final FilterCard filter = new FilterCard("black and from red"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.BLACK), new ColorPredicate(ObjectColor.RED))); + } + + public MaskOfLawAndGrace(UUID ownerId) { + super(ownerId, 11, "Mask of Law and Grace", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}"); + this.expansionSetCode = "UDS"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Enchanted creature has protection from black and from red. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(new ProtectionAbility(filter), + AttachmentType.AURA, Duration.WhileOnBattlefield))); + } + + public MaskOfLawAndGrace(final MaskOfLawAndGrace card) { + super(card); + } + + @Override + public MaskOfLawAndGrace copy() { + return new MaskOfLawAndGrace(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/RapidDecay.java b/Mage.Sets/src/mage/sets/urzasdestiny/RapidDecay.java new file mode 100644 index 00000000000..09775f15d30 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/RapidDecay.java @@ -0,0 +1,98 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.game.Game; +import mage.target.common.TargetCardInASingleGraveyard; + +/** + * + * @author fireshoes + */ +public class RapidDecay extends CardImpl { + + public RapidDecay(UUID ownerId) { + super(ownerId, 67, "Rapid Decay", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "UDS"; + + // Exile up to three target cards from a single graveyard. + this.getSpellAbility().addEffect(new RapidDecayExileEffect()); + this.getSpellAbility().addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("up to three target cards from a single graveyard"))); + + // Cycling {2} + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); + } + + public RapidDecay(final RapidDecay card) { + super(card); + } + + @Override + public RapidDecay copy() { + return new RapidDecay(this); + } +} + +class RapidDecayExileEffect extends OneShotEffect { + + public RapidDecayExileEffect() { + super(Outcome.Exile); + this.staticText = "Exile up to three target cards from a single graveyard"; + } + + public RapidDecayExileEffect(final RapidDecayExileEffect effect) { + super(effect); + } + + @Override + public RapidDecayExileEffect copy() { + return new RapidDecayExileEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (UUID targetID : source.getTargets().get(0).getTargets()) { + Card card = game.getCard(targetID); + if (card != null) { + card.moveToExile(null, "", source.getSourceId(), game); + } + } + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/SigilOfSleep.java b/Mage.Sets/src/mage/sets/urzasdestiny/SigilOfSleep.java index fac417a452e..8594f497f6e 100644 --- a/Mage.Sets/src/mage/sets/urzasdestiny/SigilOfSleep.java +++ b/Mage.Sets/src/mage/sets/urzasdestiny/SigilOfSleep.java @@ -57,7 +57,6 @@ public class SigilOfSleep extends CardImpl { this.expansionSetCode = "UDS"; this.subtype.add("Aura"); - // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); @@ -67,7 +66,7 @@ public class SigilOfSleep extends CardImpl { // Whenever enchanted creature deals damage to a player, return target creature that player controls to its owner's hand. Effect effect = new ReturnToHandTargetEffect(); effect.setText("return target creature that player controls to its owner's hand"); - ability = new DealsDamageToAPlayerAttachedTriggeredAbility(effect, "enchanted", false, true); + ability = new DealsDamageToAPlayerAttachedTriggeredAbility(effect, "enchanted", false, true, false); this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/TetheredGriffin.java b/Mage.Sets/src/mage/sets/urzasdestiny/TetheredGriffin.java new file mode 100644 index 00000000000..85da8fd853b --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/TetheredGriffin.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.Filter; +import mage.filter.common.FilterEnchantmentPermanent; + +/** + * + * @author fireshoes + */ +public class TetheredGriffin extends CardImpl { + + public TetheredGriffin(UUID ownerId) { + super(ownerId, 21, "Tethered Griffin", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "UDS"; + this.subtype.add("Griffin"); + this.power = new MageInt(2); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // When you control no enchantments, sacrifice Tethered Griffin. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterEnchantmentPermanent(), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + } + + public TetheredGriffin(final TetheredGriffin card) { + super(card); + } + + @Override + public TetheredGriffin copy() { + return new TetheredGriffin(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzasdestiny/WallOfGlare.java b/Mage.Sets/src/mage/sets/urzasdestiny/WallOfGlare.java new file mode 100644 index 00000000000..19a096e9985 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzasdestiny/WallOfGlare.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzasdestiny; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.combat.CanBlockAdditionalCreatureEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class WallOfGlare extends CardImpl { + + public WallOfGlare(UUID ownerId) { + super(ownerId, 25, "Wall of Glare", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "UDS"; + this.subtype.add("Wall"); + this.power = new MageInt(0); + this.toughness = new MageInt(5); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // Wall of Glare can block any number of creatures. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CanBlockAdditionalCreatureEffect(0))); + } + + public WallOfGlare(final WallOfGlare card) { + super(card); + } + + @Override + public WallOfGlare copy() { + return new WallOfGlare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzaslegacy/AngelsTrumpet.java b/Mage.Sets/src/mage/sets/urzaslegacy/AngelsTrumpet.java new file mode 100644 index 00000000000..0ae0bd87bcd --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzaslegacy/AngelsTrumpet.java @@ -0,0 +1,119 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzaslegacy; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.VigilanceAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.watchers.common.AttackedThisTurnWatcher; + +/** + * + * @author fireshoes + */ +public class AngelsTrumpet extends CardImpl { + + public AngelsTrumpet(UUID ownerId) { + super(ownerId, 121, "Angel's Trumpet", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{3}"); + this.expansionSetCode = "ULG"; + + // All creatures have vigilance. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAllEffect(VigilanceAbility.getInstance(), Duration.WhileOnBattlefield, new FilterCreaturePermanent()))); + + // At the beginning of each player's end step, tap all untapped creatures that player controls that didn't attack this turn. Angel's Trumpet deals damage to the player equal to the number of creatures tapped this way. + this.addAbility(new BeginningOfEndStepTriggeredAbility(new AngelsTrumpetTapEffect(), TargetController.ANY, false), new AttackedThisTurnWatcher()); + } + + public AngelsTrumpet(final AngelsTrumpet card) { + super(card); + } + + @Override + public AngelsTrumpet copy() { + return new AngelsTrumpet(this); + } +} + +class AngelsTrumpetTapEffect extends OneShotEffect { + + AngelsTrumpetTapEffect() { + super(Outcome.Tap); + this.staticText = "tap all untapped creatures that player controls that didn't attack this turn. Angel's Trumpet deals damage to the player equal to the number of creatures tapped this way"; + } + + AngelsTrumpetTapEffect(final AngelsTrumpetTapEffect effect) { + super(effect); + } + + @Override + public AngelsTrumpetTapEffect copy() { + return new AngelsTrumpetTapEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(game.getActivePlayerId()); + int count = 0; + if (player != null) { + for (Permanent creature : game.getBattlefield().getAllActivePermanents(new FilterCreaturePermanent(), player.getId(), game)) { + // Untapped creatures are safe. + if (creature.isTapped()) { + continue; + } + // Creatures that attacked are safe. + AttackedThisTurnWatcher watcher = (AttackedThisTurnWatcher) game.getState().getWatchers().get("AttackedThisTurn"); + if (watcher != null && watcher.getAttackedThisTurnCreatures().contains(creature.getId())) { + continue; + } + // Tap the rest. + creature.tap(game); + count++; + } + if (count > 0) { + player.damage(count, source.getSourceId(), game, false, true); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/urzaslegacy/EngineeredPlague.java b/Mage.Sets/src/mage/sets/urzaslegacy/EngineeredPlague.java index cb30ebba8db..185a236c3c3 100644 --- a/Mage.Sets/src/mage/sets/urzaslegacy/EngineeredPlague.java +++ b/Mage.Sets/src/mage/sets/urzaslegacy/EngineeredPlague.java @@ -28,16 +28,18 @@ package mage.sets.urzaslegacy; import java.util.UUID; - -import mage.constants.*; import mage.abilities.common.AsEntersBattlefieldAbility; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.common.ChooseCreatureTypeEffect; import mage.abilities.effects.common.continuous.BoostAllEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; -import mage.game.Game; -import mage.game.permanent.Permanent; +import mage.filter.predicate.mageobject.ChosenSubtypePredicate; /** * @@ -53,7 +55,9 @@ public class EngineeredPlague extends CardImpl { // As Engineered Plague enters the battlefield, choose a creature type. this.addAbility(new AsEntersBattlefieldAbility(new ChooseCreatureTypeEffect(Outcome.UnboostCreature))); // All creatures of the chosen type get -1/-1. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(-1, -1, Duration.WhileOnBattlefield, new FilterEngineeredPlague(), false))); + FilterCreaturePermanent filter = new FilterCreaturePermanent("All creatures of the chosen type"); + filter.add(new ChosenSubtypePredicate(this.getId())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(-1, -1, Duration.WhileOnBattlefield, filter, false))); } public EngineeredPlague(final EngineeredPlague card) { @@ -64,33 +68,4 @@ public class EngineeredPlague extends CardImpl { public EngineeredPlague copy() { return new EngineeredPlague(this); } - - class FilterEngineeredPlague extends FilterCreaturePermanent { - - public FilterEngineeredPlague() { - super("All creatures of the chosen type"); - } - - public FilterEngineeredPlague(final FilterEngineeredPlague filter) { - super(filter); - } - - @Override - public FilterEngineeredPlague copy() { - return new FilterEngineeredPlague(this); - } - - @Override - public boolean match(Permanent permanent, UUID sourceId, UUID playerId, Game game) { - if(super.match(permanent, sourceId, playerId, game)){ - String subtype = (String) game.getState().getValue(sourceId + "_type"); - if(subtype != null && !subtype.equals("") && permanent.hasSubtype(subtype)){ - return true; - } - } - return false; - } - - } - } diff --git a/Mage.Sets/src/mage/sets/urzaslegacy/HarmonicConvergence.java b/Mage.Sets/src/mage/sets/urzaslegacy/HarmonicConvergence.java index adc6e71cd4d..cf0f508360b 100644 --- a/Mage.Sets/src/mage/sets/urzaslegacy/HarmonicConvergence.java +++ b/Mage.Sets/src/mage/sets/urzaslegacy/HarmonicConvergence.java @@ -116,7 +116,7 @@ class HarmonicConvergenceEffect extends OneShotEffect { for (Permanent permanent : list) { cards.add(permanent); } - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Permanent permanent = game.getPermanent(target.getFirstTarget()); if (permanent != null) { diff --git a/Mage.Sets/src/mage/sets/urzaslegacy/RavenFamiliar.java b/Mage.Sets/src/mage/sets/urzaslegacy/RavenFamiliar.java index 4ad677fd27d..6f708fa0d38 100644 --- a/Mage.Sets/src/mage/sets/urzaslegacy/RavenFamiliar.java +++ b/Mage.Sets/src/mage/sets/urzaslegacy/RavenFamiliar.java @@ -124,7 +124,7 @@ public class RavenFamiliar extends CardImpl { } target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/urzaslegacy/TickingGnomes.java b/Mage.Sets/src/mage/sets/urzaslegacy/TickingGnomes.java index e9956161084..c4458d3f390 100644 --- a/Mage.Sets/src/mage/sets/urzaslegacy/TickingGnomes.java +++ b/Mage.Sets/src/mage/sets/urzaslegacy/TickingGnomes.java @@ -28,9 +28,6 @@ package mage.sets.urzaslegacy; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; @@ -38,6 +35,8 @@ import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.effects.common.DamageTargetEffect; import mage.abilities.keyword.EchoAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; import mage.target.common.TargetCreatureOrPlayer; @@ -60,6 +59,7 @@ public class TickingGnomes extends CardImpl { // Sacrifice Ticking Gnomes: Ticking Gnomes deals 1 damage to target creature or player. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(1), new SacrificeSourceCost()); ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); } public TickingGnomes(final TickingGnomes card) { diff --git a/Mage.Sets/src/mage/sets/urzassaga/ArgothianWurm.java b/Mage.Sets/src/mage/sets/urzassaga/ArgothianWurm.java new file mode 100644 index 00000000000..159db3e05a6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/ArgothianWurm.java @@ -0,0 +1,115 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.Cost; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.PutOnLibrarySourceEffect; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class ArgothianWurm extends CardImpl { + + public ArgothianWurm(UUID ownerId) { + super(ownerId, 236, "Argothian Wurm", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "USG"; + this.subtype.add("Wurm"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // When Argothian Wurm enters the battlefield, any player may sacrifice a land. If a player does, put Argothian Wurm on top of its owner's library. + this.addAbility(new EntersBattlefieldTriggeredAbility(new ArgothianWurmEffect(), false)); + } + + public ArgothianWurm(final ArgothianWurm card) { + super(card); + } + + @Override + public ArgothianWurm copy() { + return new ArgothianWurm(this); + } +} + +class ArgothianWurmEffect extends PutOnLibrarySourceEffect { + + ArgothianWurmEffect() { + super(true); + this.staticText = "any player may sacrifice a land. If a player does, put {this} on top of its owner's library"; + } + + ArgothianWurmEffect(final ArgothianWurmEffect effect) { + super(effect); + } + + @Override + public ArgothianWurmEffect copy() { + return new ArgothianWurmEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + boolean costPaid = false; + for (UUID playerId : controller.getInRange()) { + Cost cost = new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent())); + Player player = game.getPlayer(playerId); + if (player != null + && cost.canPay(source, source.getSourceId(), playerId, game) + && player.chooseUse(Outcome.Sacrifice, "Sacrifice a land?", source, game) + && cost.pay(source, game, source.getSourceId(), playerId, true)) { + costPaid = true; + } + } + if (costPaid) { + super.apply(game, source); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/urzassaga/CarpetOfFlowers.java b/Mage.Sets/src/mage/sets/urzassaga/CarpetOfFlowers.java index 7b6794af6d4..8f6e677c103 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/CarpetOfFlowers.java +++ b/Mage.Sets/src/mage/sets/urzassaga/CarpetOfFlowers.java @@ -168,7 +168,7 @@ class CarpetOfFlowersEffect extends ManaEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(Outcome.Protect, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/urzassaga/CarrionBeetles.java b/Mage.Sets/src/mage/sets/urzassaga/CarrionBeetles.java new file mode 100644 index 00000000000..20ed6bab867 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/CarrionBeetles.java @@ -0,0 +1,103 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.game.Game; +import mage.target.common.TargetCardInASingleGraveyard; + +/** + * + * @author fireshoes + */ +public class CarrionBeetles extends CardImpl { + + public CarrionBeetles(UUID ownerId) { + super(ownerId, 122, "Carrion Beetles", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); + this.expansionSetCode = "USG"; + this.subtype.add("Insect"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {2}{B}, {tap}: Exile up to three target cards from a single graveyard. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CarrionBeetlesExileEffect(), new ManaCostsImpl("{2}{B}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCardInASingleGraveyard(0, 3, new FilterCard("up to three target cards from a single graveyard"))); + this.addAbility(ability); + } + + public CarrionBeetles(final CarrionBeetles card) { + super(card); + } + + @Override + public CarrionBeetles copy() { + return new CarrionBeetles(this); + } +} + +class CarrionBeetlesExileEffect extends OneShotEffect { + + public CarrionBeetlesExileEffect() { + super(Outcome.Exile); + this.staticText = "Exile up to three target cards from a single graveyard"; + } + + public CarrionBeetlesExileEffect(final CarrionBeetlesExileEffect effect) { + super(effect); + } + + @Override + public CarrionBeetlesExileEffect copy() { + return new CarrionBeetlesExileEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (UUID targetID : source.getTargets().get(0).getTargets()) { + Card card = game.getCard(targetID); + if (card != null) { + card.moveToExile(null, "", source.getSourceId(), game); + } + } + return true; + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/Expunge.java b/Mage.Sets/src/mage/sets/urzassaga/Expunge.java index 52b7b53a83d..c0083185cbf 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Expunge.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Expunge.java @@ -28,13 +28,13 @@ package mage.sets.urzassaga; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.ObjectColor; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.DestroyTargetEffect; import mage.abilities.keyword.CyclingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.CardTypePredicate; @@ -62,8 +62,9 @@ public class Expunge extends CardImpl { // Destroy target nonartifact, nonblack creature. It can't be regenerated. this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); - // Cycling {2} ({2}, Discard this card: Draw a card.) - this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); + + // Cycling {2} ({2}, Discard this card: Draw a card.) + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); } diff --git a/Mage.Sets/src/mage/sets/urzassaga/FieryMantle.java b/Mage.Sets/src/mage/sets/urzassaga/FieryMantle.java new file mode 100644 index 00000000000..483bbd2fa38 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/FieryMantle.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.PutIntoGraveFromBattlefieldSourceTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ColoredManaCost; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.ColoredManaSymbol; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class FieryMantle extends CardImpl { + + public FieryMantle(UUID ownerId) { + super(ownerId, 186, "Fiery Mantle", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}"); + this.expansionSetCode = "USG"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.AddAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // {R}: Enchanted creature gets +1/+0 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 0, Duration.EndOfTurn), new ColoredManaCost(ColoredManaSymbol.R))); + + // When Fiery Mantle is put into a graveyard from the battlefield, return Fiery Mantle to its owner's hand. + this.addAbility(new PutIntoGraveFromBattlefieldSourceTriggeredAbility(new ReturnToHandSourceEffect())); + } + + public FieryMantle(final FieryMantle card) { + super(card); + } + + @Override + public FieryMantle copy() { + return new FieryMantle(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/GoblinLackey.java b/Mage.Sets/src/mage/sets/urzassaga/GoblinLackey.java index f4f44011f6f..282a8788916 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/GoblinLackey.java +++ b/Mage.Sets/src/mage/sets/urzassaga/GoblinLackey.java @@ -29,22 +29,13 @@ package mage.sets.urzassaga; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; +import mage.abilities.common.DealsDamageToAPlayerTriggeredAbility; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterPermanentCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.players.Player; -import mage.target.common.TargetCardInHand; /** * @@ -52,6 +43,12 @@ import mage.target.common.TargetCardInHand; */ public class GoblinLackey extends CardImpl { + private static final FilterPermanentCard filter = new FilterPermanentCard("a Goblin permanent card"); + + static { + filter.add(new SubtypePredicate("Goblin")); + } + public GoblinLackey(UUID ownerId) { super(ownerId, 190, "Goblin Lackey", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{R}"); this.expansionSetCode = "USG"; @@ -61,7 +58,7 @@ public class GoblinLackey extends CardImpl { this.toughness = new MageInt(1); // Whenever Goblin Lackey deals damage to a player, you may put a Goblin permanent card from your hand onto the battlefield. - this.addAbility(new GoblinLackeyTriggeredAbility()); + this.addAbility(new DealsDamageToAPlayerTriggeredAbility(new PutPermanentOnBattlefieldEffect(filter), false)); } public GoblinLackey(final GoblinLackey card) { @@ -73,72 +70,3 @@ public class GoblinLackey extends CardImpl { return new GoblinLackey(this); } } - -class GoblinLackeyTriggeredAbility extends TriggeredAbilityImpl { - - public GoblinLackeyTriggeredAbility() { - super(Zone.BATTLEFIELD, new GoblinLackeyEffect(), true); - } - - public GoblinLackeyTriggeredAbility(final GoblinLackeyTriggeredAbility ability) { - super(ability); - } - - @Override - public GoblinLackeyTriggeredAbility copy() { - return new GoblinLackeyTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.DAMAGED_PLAYER; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return event.getSourceId().equals(this.sourceId) - && game.getOpponents(this.getControllerId()).contains(event.getTargetId()); - } - - @Override - public String getRule() { - return "Whenever {this} deals damage to an opponent, you may put a Goblin permanent card from your hand onto the battlefield."; - } -} - -class GoblinLackeyEffect extends OneShotEffect { - - public GoblinLackeyEffect() { - super(Outcome.PutCreatureInPlay); - this.staticText = "you may put a Goblin permanent card from your hand onto the battlefield"; - } - - public GoblinLackeyEffect(final GoblinLackeyEffect effect) { - super(effect); - } - - @Override - public GoblinLackeyEffect copy() { - return new GoblinLackeyEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller == null) { - return false; - } - FilterPermanentCard filter = new FilterPermanentCard("Goblin permanent card from your hand"); - filter.add(new SubtypePredicate("Goblin")); - TargetCardInHand target = new TargetCardInHand(filter); - if (controller.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } else { - return false; - } - } - return true; - } -} diff --git a/Mage.Sets/src/mage/sets/urzassaga/IllGottenGains.java b/Mage.Sets/src/mage/sets/urzassaga/IllGottenGains.java index e4899307daa..f731566dde4 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/IllGottenGains.java +++ b/Mage.Sets/src/mage/sets/urzassaga/IllGottenGains.java @@ -32,8 +32,8 @@ import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ExileSpellEffect; import mage.abilities.effects.common.discard.DiscardHandAllEffect; -import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -54,13 +54,12 @@ public class IllGottenGains extends CardImpl { super(ownerId, 138, "Ill-Gotten Gains", Rarity.RARE, new CardType[]{CardType.SORCERY}, "{2}{B}{B}"); this.expansionSetCode = "USG"; - // Exile Ill-Gotten Gains. this.getSpellAbility().addEffect(ExileSpellEffect.getInstance()); - + // Each player discards his or her hand, this.getSpellAbility().addEffect(new DiscardHandAllEffect()); - + //then returns up to three cards from his or her graveyard to his or her hand. this.getSpellAbility().addEffect(new IllGottenGainsEffect()); } @@ -76,34 +75,31 @@ public class IllGottenGains extends CardImpl { } class IllGottenGainsEffect extends OneShotEffect { - + IllGottenGainsEffect() { super(Outcome.ReturnToHand); this.staticText = ", then returns up to three cards from his or her graveyard to his or her hand."; } - + IllGottenGainsEffect(final IllGottenGainsEffect effect) { super(effect); } - + @Override public IllGottenGainsEffect copy() { return new IllGottenGainsEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - for (UUID playerId : controller.getInRange()){ + for (UUID playerId : controller.getInRange()) { Player player = game.getPlayer(playerId); if (player != null) { Target target = new TargetCardInYourGraveyard(0, 3, new FilterCard()); if (target.choose(Outcome.ReturnToHand, player.getId(), source.getSourceId(), game)) { - for (UUID targetId : target.getTargets()) { - Card card = game.getCard(targetId); - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } + controller.moveCards(new CardsImpl(target.getTargets()), null, Zone.HAND, source, game); } } } diff --git a/Mage.Sets/src/mage/sets/urzassaga/ImaginaryPet.java b/Mage.Sets/src/mage/sets/urzassaga/ImaginaryPet.java new file mode 100644 index 00000000000..69a4a490c45 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/ImaginaryPet.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.TriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.condition.common.CardsInHandCondition; +import mage.abilities.decorator.ConditionalTriggeredAbility; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; + +/** + * + * @author LoneFox + */ +public class ImaginaryPet extends CardImpl { + + public ImaginaryPet(UUID ownerId) { + super(ownerId, 81, "Imaginary Pet", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "USG"; + this.subtype.add("Illusion"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // At the beginning of your upkeep, if you have a card in hand, return Imaginary Pet to its owner's hand. + TriggeredAbility ability = new BeginningOfUpkeepTriggeredAbility(new ReturnToHandSourceEffect(true), TargetController.YOU, false); + this.addAbility(new ConditionalTriggeredAbility(ability, new CardsInHandCondition(CardsInHandCondition.CountType.MORE_THAN, 0), + "At the beginning of your upkeep, if you have a card in hand, return {this} to its owner's hand.")); + } + + public ImaginaryPet(final ImaginaryPet card) { + super(card); + } + + @Override + public ImaginaryPet copy() { + return new ImaginaryPet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/LiltingRefrain.java b/Mage.Sets/src/mage/sets/urzassaga/LiltingRefrain.java new file mode 100644 index 00000000000..e4cfe2d3823 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/LiltingRefrain.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.effects.common.CounterUnlessPaysEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.target.TargetSpell; + +/** + * + * @author fireshoes + */ +public class LiltingRefrain extends CardImpl { + + public LiltingRefrain(UUID ownerId) { + super(ownerId, 83, "Lilting Refrain", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{U}"); + this.expansionSetCode = "USG"; + + // At the beginning of your upkeep, you may put a verse counter on Lilting Refrain. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.VERSE.createInstance()), TargetController.YOU, true)); + + // Sacrifice Lilting Refrain: Counter target spell unless its controller pays {X}, where X is the number of verse counters on Lilting Refrain. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CounterUnlessPaysEffect(new CountersCount(CounterType.VERSE)), new SacrificeSourceCost()); + ability.addTarget(new TargetSpell()); + this.addAbility(ability); + } + + public LiltingRefrain(final LiltingRefrain card) { + super(card); + } + + @Override + public LiltingRefrain copy() { + return new LiltingRefrain(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/MishrasHelix.java b/Mage.Sets/src/mage/sets/urzassaga/MishrasHelix.java new file mode 100644 index 00000000000..da0880100fb --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/MishrasHelix.java @@ -0,0 +1,84 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class MishrasHelix extends CardImpl { + + private final UUID originalId; + + public MishrasHelix(UUID ownerId) { + super(ownerId, 302, "Mishra's Helix", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{5}"); + this.expansionSetCode = "USG"; + + // {X}, {tap}: Tap X target lands. + Effect effect = new TapTargetEffect(); + effect.setText("tap X target lands"); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, effect, new ManaCostsImpl("{X}")); + ability.addCost(new TapSourceCost()); + originalId = ability.getOriginalId(); + this.addAbility(ability); + } + + @Override + public void adjustTargets(Ability ability, Game game) { + if (ability.getOriginalId().equals(originalId)){ + int xValue = ability.getManaCostsToPay().getX(); + ability.getTargets().clear(); + ability.addTarget(new TargetLandPermanent(xValue, xValue, new FilterLandPermanent(), false)); + } + } + + public MishrasHelix(final MishrasHelix card) { + super(card); + this.originalId = card.originalId; + } + + @Override + public MishrasHelix copy() { + return new MishrasHelix(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/MonkRealist.java b/Mage.Sets/src/mage/sets/urzassaga/MonkRealist.java new file mode 100644 index 00000000000..2014b074bc1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/MonkRealist.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.target.Target; +import mage.target.TargetPermanent; + +/** + * + * @author fireshoes + */ +public class MonkRealist extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("enchantment"); + + static { + filter.add(new CardTypePredicate(CardType.ENCHANTMENT)); + } + + public MonkRealist(UUID ownerId) { + super(ownerId, 21, "Monk Realist", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{W}"); + this.expansionSetCode = "USG"; + this.subtype.add("Human"); + this.subtype.add("Monk"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // When Monk Realist enters the battlefield, destroy target enchantment. + Ability ability = new EntersBattlefieldTriggeredAbility(new DestroyTargetEffect(), false); + Target target = new TargetPermanent(filter); + ability.addTarget(target); + this.addAbility(ability); + } + + public MonkRealist(final MonkRealist card) { + super(card); + } + + @Override + public MonkRealist copy() { + return new MonkRealist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/NoRestForTheWicked.java b/Mage.Sets/src/mage/sets/urzassaga/NoRestForTheWicked.java index 4fc753a2123..8d3b3c4a02d 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/NoRestForTheWicked.java +++ b/Mage.Sets/src/mage/sets/urzassaga/NoRestForTheWicked.java @@ -35,6 +35,8 @@ import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; @@ -86,22 +88,20 @@ class NoRestForTheWickedEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { NoRestForTheWickedWatcher watcher = (NoRestForTheWickedWatcher) game.getState().getWatchers().get("NoRestForTheWickedWatcher"); - if (watcher != null) { + Player controller = game.getPlayer(source.getControllerId()); + if (watcher != null && controller != null) { + Cards cardsToHand = new CardsImpl(); for (UUID cardId : watcher.cards) { Card c = game.getCard(cardId); if (c != null) { if (game.getState().getZone(cardId) == Zone.GRAVEYARD && c.getCardType().contains(CardType.CREATURE) && c.getOwnerId().equals(source.getControllerId())) { - //400.3 - Player p = game.getPlayer(source.getControllerId()); - if (p != null) { - p.moveCardToHandWithInfo(c, source.getSourceId(), game, Zone.GRAVEYARD); - } - return false; + cardsToHand.add(c); } } } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/urzassaga/Oppression.java b/Mage.Sets/src/mage/sets/urzassaga/Oppression.java index 5c626c2089e..dee4dea7f2b 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Oppression.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Oppression.java @@ -28,16 +28,11 @@ package mage.sets.urzassaga; import java.util.UUID; - -import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; import mage.abilities.common.SpellCastAllTriggeredAbility; import mage.abilities.effects.common.discard.DiscardTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; -import mage.constants.Zone; -import mage.filter.FilterSpell; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.stack.Spell; @@ -53,7 +48,6 @@ public class Oppression extends CardImpl { super(ownerId, 143, "Oppression", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{B}{B}"); this.expansionSetCode = "USG"; - // Whenever a player casts a spell, that player discards a card. this.addAbility(new OppressionTriggeredAbility()); } @@ -82,7 +76,7 @@ class OppressionTriggeredAbility extends SpellCastAllTriggeredAbility { public boolean checkTrigger(GameEvent event, Game game) { if (event.getType() == GameEvent.EventType.SPELL_CAST) { Spell spell = game.getStack().getSpell(event.getTargetId()); - if (spell != null && filter.match(spell, getControllerId(), game)) { + if (spell != null && filter.match(spell, getSourceId(), getControllerId(), game)) { this.getEffects().get(0).setTargetPointer(new FixedTarget(event.getPlayerId())); return true; } @@ -94,4 +88,4 @@ class OppressionTriggeredAbility extends SpellCastAllTriggeredAbility { public OppressionTriggeredAbility copy() { return new OppressionTriggeredAbility(this); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/Persecute.java b/Mage.Sets/src/mage/sets/urzassaga/Persecute.java index 82d8dfe6f55..78326067aa1 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Persecute.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Persecute.java @@ -87,25 +87,26 @@ class PersecuteEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getFirstTarget()); + Player controller = game.getPlayer(source.getControllerId()); MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller != null && sourceObject != null) { + Player targetPlayer = game.getPlayer(getTargetPointer().getFirst(game, source)); + if (controller != null && sourceObject != null && targetPlayer != null) { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } if (choice.getColor() == null) { return false; } - Cards hand = controller.getHand(); - controller.revealCards(sourceObject.getIdName(), hand, game); + Cards hand = targetPlayer.getHand(); + targetPlayer.revealCards(sourceObject.getIdName(), hand, game); Set cards = hand.getCards(game); for (Card card : cards) { if (card != null && card.getColor(game).shares(choice.getColor())) { - controller.discard(card, source, game); + targetPlayer.discard(card, source, game); } } return true; diff --git a/Mage.Sets/src/mage/sets/urzassaga/PresenceOfTheMaster.java b/Mage.Sets/src/mage/sets/urzassaga/PresenceOfTheMaster.java new file mode 100644 index 00000000000..dd2cfa33e06 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/PresenceOfTheMaster.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class PresenceOfTheMaster extends mage.sets.legends.PresenceOfTheMaster { + + public PresenceOfTheMaster(UUID ownerId) { + super(ownerId); + this.cardNumber = 32; + this.expansionSetCode = "USG"; + } + + public PresenceOfTheMaster(final PresenceOfTheMaster card) { + super(card); + } + + @Override + public PresenceOfTheMaster copy() { + return new PresenceOfTheMaster(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionArtifacts.java b/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionArtifacts.java new file mode 100644 index 00000000000..52286b85afe --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionArtifacts.java @@ -0,0 +1,141 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.PreventionEffectImpl; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterObject; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.target.TargetSource; + +/** + * + * @author fireshoes + */ +public class RuneOfProtectionArtifacts extends CardImpl { + + public RuneOfProtectionArtifacts(UUID ownerId) { + super(ownerId, 35, "Rune of Protection: Artifacts", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + this.expansionSetCode = "USG"; + + + // {W}: The next time a black source of your choice would deal damage to you this turn, prevent that damage. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RuneOfProtectionArtifactsEffect() , new ManaCostsImpl("W"))); + // Cycling {2} ({2}, Discard this card: Draw a card.) + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); + } + + public RuneOfProtectionArtifacts(final RuneOfProtectionArtifacts card) { + super(card); + } + + @Override + public RuneOfProtectionArtifacts copy() { + return new RuneOfProtectionArtifacts(this); + } +} + +class RuneOfProtectionArtifactsEffect extends PreventionEffectImpl { + + private static final FilterObject filter = new FilterObject("artifact source"); + + static { + filter.add(new CardTypePredicate(CardType.ARTIFACT)); + } + + private TargetSource target; + + public RuneOfProtectionArtifactsEffect() { + super(Duration.EndOfTurn); + target = new TargetSource(filter); + + staticText = "The next time an artifact source of your choice would deal damage to you this turn, prevent that damage"; + } + + public RuneOfProtectionArtifactsEffect(final RuneOfProtectionArtifactsEffect effect) { + super(effect); + this.target = effect.target.copy(); + } + + @Override + public RuneOfProtectionArtifactsEffect copy() { + return new RuneOfProtectionArtifactsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public void init(Ability source, Game game) { + this.target.choose(Outcome.PreventDamage, source.getControllerId(), source.getSourceId(), game); + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + if (event.getTargetId().equals(source.getControllerId()) && event.getSourceId().equals(target.getFirstTarget())) { + preventDamage(event, source, target.getFirstTarget(), game); + return true; + } + return false; + } + + private void preventDamage(GameEvent event, Ability source, UUID target, Game game) { + GameEvent preventEvent = new GameEvent(GameEvent.EventType.PREVENT_DAMAGE, target, source.getSourceId(), source.getControllerId(), event.getAmount(), false); + if (!game.replaceEvent(preventEvent)) { + int damage = event.getAmount(); + event.setAmount(0); + this.used = true; + game.fireEvent(GameEvent.getEvent(GameEvent.EventType.PREVENTED_DAMAGE, target, source.getSourceId(), source.getControllerId(), damage)); + } + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (!this.used && super.applies(event, source, game)) { + if (event.getTargetId().equals(source.getControllerId()) && event.getSourceId().equals(target.getFirstTarget())) { + return true; + } + } + return false; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionLands.java b/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionLands.java new file mode 100644 index 00000000000..5d088a895fb --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/RuneOfProtectionLands.java @@ -0,0 +1,141 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.PreventionEffectImpl; +import mage.abilities.keyword.CyclingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterObject; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.target.TargetSource; + +/** + * + * @author fireshoes + */ +public class RuneOfProtectionLands extends CardImpl { + + public RuneOfProtectionLands(UUID ownerId) { + super(ownerId, 39, "Rune of Protection: Lands", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + this.expansionSetCode = "USG"; + + + // {W}: The next time a black source of your choice would deal damage to you this turn, prevent that damage. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RuneOfProtectionLandsEffect() , new ManaCostsImpl("W"))); + // Cycling {2} ({2}, Discard this card: Draw a card.) + this.addAbility(new CyclingAbility(new ManaCostsImpl("{2}"))); + } + + public RuneOfProtectionLands(final RuneOfProtectionLands card) { + super(card); + } + + @Override + public RuneOfProtectionLands copy() { + return new RuneOfProtectionLands(this); + } +} + +class RuneOfProtectionLandsEffect extends PreventionEffectImpl { + + private static final FilterObject filter = new FilterObject("land source"); + + static { + filter.add(new CardTypePredicate(CardType.LAND)); + } + + private TargetSource target; + + public RuneOfProtectionLandsEffect() { + super(Duration.EndOfTurn); + target = new TargetSource(filter); + + staticText = "The next time a land source of your choice would deal damage to you this turn, prevent that damage"; + } + + public RuneOfProtectionLandsEffect(final RuneOfProtectionLandsEffect effect) { + super(effect); + this.target = effect.target.copy(); + } + + @Override + public RuneOfProtectionLandsEffect copy() { + return new RuneOfProtectionLandsEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public void init(Ability source, Game game) { + this.target.choose(Outcome.PreventDamage, source.getControllerId(), source.getSourceId(), game); + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + if (event.getTargetId().equals(source.getControllerId()) && event.getSourceId().equals(target.getFirstTarget())) { + preventDamage(event, source, target.getFirstTarget(), game); + return true; + } + return false; + } + + private void preventDamage(GameEvent event, Ability source, UUID target, Game game) { + GameEvent preventEvent = new GameEvent(GameEvent.EventType.PREVENT_DAMAGE, target, source.getSourceId(), source.getControllerId(), event.getAmount(), false); + if (!game.replaceEvent(preventEvent)) { + int damage = event.getAmount(); + event.setAmount(0); + this.used = true; + game.fireEvent(GameEvent.getEvent(GameEvent.EventType.PREVENTED_DAMAGE, target, source.getSourceId(), source.getControllerId(), damage)); + } + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (!this.used && super.applies(event, source, game)) { + if (event.getTargetId().equals(source.getControllerId()) && event.getSourceId().equals(target.getFirstTarget())) { + return true; + } + } + return false; + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/urzassaga/SanctumCustodian.java b/Mage.Sets/src/mage/sets/urzassaga/SanctumCustodian.java new file mode 100644 index 00000000000..bdad5a972f7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/SanctumCustodian.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class SanctumCustodian extends CardImpl { + + public SanctumCustodian(UUID ownerId) { + super(ownerId, 42, "Sanctum Custodian", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "USG"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {tap}: Prevent the next 2 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 2), new TapSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public SanctumCustodian(final SanctumCustodian card) { + super(card); + } + + @Override + public SanctumCustodian copy() { + return new SanctumCustodian(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/SanctumGuardian.java b/Mage.Sets/src/mage/sets/urzassaga/SanctumGuardian.java new file mode 100644 index 00000000000..2b40cfa1a64 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/SanctumGuardian.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class SanctumGuardian extends mage.sets.ninthedition.SanctumGuardian { + + public SanctumGuardian(UUID ownerId) { + super(ownerId); + this.cardNumber = 43; + this.expansionSetCode = "USG"; + } + + public SanctumGuardian(final SanctumGuardian card) { + super(card); + } + + @Override + public SanctumGuardian copy() { + return new SanctumGuardian(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/Smokestack.java b/Mage.Sets/src/mage/sets/urzassaga/Smokestack.java index 87b8ade46eb..541c4a31bb5 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Smokestack.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Smokestack.java @@ -100,7 +100,7 @@ class SmokestackEffect extends OneShotEffect { //A spell or ability could have removed the only legal target this player //had, if thats the case this ability should fizzle. if (target.canChoose(activePlayer.getId(), game)) { - while (!target.isChosen() && target.canChoose(activePlayer.getId(), game) && activePlayer.isInGame()) { + while (!target.isChosen() && target.canChoose(activePlayer.getId(), game) && activePlayer.canRespond()) { activePlayer.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } diff --git a/Mage.Sets/src/mage/sets/urzassaga/SneakAttack.java b/Mage.Sets/src/mage/sets/urzassaga/SneakAttack.java index 1b447cb9f41..3720511de42 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/SneakAttack.java +++ b/Mage.Sets/src/mage/sets/urzassaga/SneakAttack.java @@ -62,7 +62,6 @@ public class SneakAttack extends CardImpl { super(ownerId, 218, "Sneak Attack", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{R}"); this.expansionSetCode = "USG"; - // {R}: You may put a creature card from your hand onto the battlefield. That creature gains haste. Sacrifice the creature at the beginning of the next end step. this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new SneakAttackEffect(), new ManaCostsImpl("{R}"))); } @@ -78,23 +77,23 @@ public class SneakAttack extends CardImpl { } class SneakAttackEffect extends OneShotEffect { - + private static final String choiceText = "Put a creature card from your hand onto the battlefield?"; - + public SneakAttackEffect() { super(Outcome.Benefit); this.staticText = "You may put a creature card from your hand onto the battlefield. That creature gains haste. Sacrifice the creature at the beginning of the next end step"; } - + public SneakAttackEffect(final SneakAttackEffect effect) { super(effect); } - + @Override public SneakAttackEffect copy() { return new SneakAttackEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(source.getControllerId()); @@ -106,20 +105,21 @@ class SneakAttackEffect extends OneShotEffect { if (card != null) { if (player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId())) { Permanent permanent = game.getPermanent(card.getId()); - ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); - effect.setTargetPointer(new FixedTarget(permanent.getId())); - game.addEffect(effect, source); - - SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName()); - sacrificeEffect.setTargetPointer(new FixedTarget(card.getId())); - DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); - delayedAbility.setSourceId(source.getSourceId()); - delayedAbility.setControllerId(source.getControllerId()); - delayedAbility.setSourceObject(source.getSourceObject(game), game); - game.addDelayedTriggeredAbility(delayedAbility); - + if (permanent != null) { + ContinuousEffect effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.Custom); + effect.setTargetPointer(new FixedTarget(permanent, game)); + game.addEffect(effect, source); + + SacrificeTargetEffect sacrificeEffect = new SacrificeTargetEffect("sacrifice " + card.getName(), source.getControllerId()); + sacrificeEffect.setTargetPointer(new FixedTarget(permanent, game)); + DelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility(sacrificeEffect); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + game.addDelayedTriggeredAbility(delayedAbility); + } return true; - } + } } return false; } diff --git a/Mage.Sets/src/mage/sets/urzassaga/SteamBlast.java b/Mage.Sets/src/mage/sets/urzassaga/SteamBlast.java new file mode 100644 index 00000000000..8c57dec06da --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/SteamBlast.java @@ -0,0 +1,58 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.effects.common.DamageEverythingEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class SteamBlast extends CardImpl { + + public SteamBlast(UUID ownerId) { + super(ownerId, 219, "Steam Blast", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{R}"); + this.expansionSetCode = "USG"; + + // Steam Blast deals 2 damage to each creature and each player. + this.getSpellAbility().addEffect(new DamageEverythingEffect(2)); + } + + public SteamBlast(final SteamBlast card) { + super(card); + } + + @Override + public SteamBlast copy() { + return new SteamBlast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/Sunder.java b/Mage.Sets/src/mage/sets/urzassaga/Sunder.java new file mode 100644 index 00000000000..ee8ff761003 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/Sunder.java @@ -0,0 +1,89 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author fireshoes + */ +public class Sunder extends CardImpl { + + public Sunder(UUID ownerId) { + super(ownerId, 101, "Sunder", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{3}{U}"); + this.expansionSetCode = "USG"; + + // Return all lands to their owners' hands. + this.getSpellAbility().addEffect(new SunderEffect()); + } + + public Sunder(final Sunder card) { + super(card); + } + + @Override + public Sunder copy() { + return new Sunder(this); + } +} + +class SunderEffect extends OneShotEffect { + + public SunderEffect() { + super(Outcome.ReturnToHand); + staticText = "Return all lands to their owners' hands"; + } + + public SunderEffect(final SunderEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + for (Permanent land : game.getBattlefield().getActivePermanents(new FilterLandPermanent(), source.getControllerId(), source.getSourceId(), game)) { + land.moveToZone(Zone.HAND, source.getSourceId(), game, true); + } + return true; + } + + @Override + public SunderEffect copy() { + return new SunderEffect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/urzassaga/Telepathy.java b/Mage.Sets/src/mage/sets/urzassaga/Telepathy.java index 037fe814b77..e71a4cbb551 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Telepathy.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Telepathy.java @@ -27,16 +27,18 @@ */ package mage.sets.urzassaga; -import mage.constants.*; -import mage.abilities.Ability; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.cards.CardImpl; -import mage.game.Game; -import mage.players.Player; - import java.util.UUID; import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.PlayWithHandRevealedEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; /** * @@ -49,7 +51,7 @@ public class Telepathy extends CardImpl { this.expansionSetCode = "USG"; // Your opponents play with their hands revealed. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OpponentsPlayWithTheTopCardRevealedEffect())); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new PlayWithHandRevealedEffect(TargetController.OPPONENT))); } public Telepathy(final Telepathy card) { @@ -61,37 +63,3 @@ public class Telepathy extends CardImpl { return new Telepathy(this); } } - -class OpponentsPlayWithTheTopCardRevealedEffect extends ContinuousEffectImpl { - - public OpponentsPlayWithTheTopCardRevealedEffect() { - super(Duration.WhileOnBattlefield, Layer.PlayerEffects, SubLayer.NA, Outcome.Detriment); - staticText = "Your opponents play with their hands revealed"; - } - - public OpponentsPlayWithTheTopCardRevealedEffect(final OpponentsPlayWithTheTopCardRevealedEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - MageObject sourceObject = game.getObject(source.getSourceId()); - if (controller != null) { - for (UUID opponentId : game.getOpponents(controller.getId())) { - Player opponent = game.getPlayer(opponentId); - if (opponent != null) { - controller.revealCards(sourceObject.getIdName() + " " + opponent.getName(), opponent.getHand(), game, false); - } - } - return true; - } - return false; - } - - @Override - public OpponentsPlayWithTheTopCardRevealedEffect copy() { - return new OpponentsPlayWithTheTopCardRevealedEffect(this); - } - -} diff --git a/Mage.Sets/src/mage/sets/urzassaga/TreetopRangers.java b/Mage.Sets/src/mage/sets/urzassaga/TreetopRangers.java index f9d06be1e4e..9f14c6abba6 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/TreetopRangers.java +++ b/Mage.Sets/src/mage/sets/urzassaga/TreetopRangers.java @@ -29,14 +29,13 @@ package mage.sets.urzassaga; import java.util.UUID; import mage.MageInt; -import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.common.SimpleEvasionAbility; import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; @@ -62,9 +61,7 @@ public class TreetopRangers extends CardImpl { this.toughness = new MageInt(2); // Treetop Rangers can't be blocked except by creatures with flying. - this.addAbility(new SimpleStaticAbility( - Zone.BATTLEFIELD, new CantBeBlockedByCreaturesSourceEffect(onlyFlyingCreatures, Duration.WhileOnBattlefield) - )); + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(onlyFlyingCreatures, Duration.WhileOnBattlefield))); } public TreetopRangers(final TreetopRangers card) { diff --git a/Mage.Sets/src/mage/sets/urzassaga/Turnabout.java b/Mage.Sets/src/mage/sets/urzassaga/Turnabout.java index f3c1c5a1809..40ea435d881 100644 --- a/Mage.Sets/src/mage/sets/urzassaga/Turnabout.java +++ b/Mage.Sets/src/mage/sets/urzassaga/Turnabout.java @@ -112,7 +112,7 @@ class TurnaboutEffect extends OneShotEffect { choiceImpl.setMessage("Choose card type to tap or untap"); choiceImpl.setChoices(choice); while (!controller.choose(Outcome.Neutral, choiceImpl, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } @@ -131,7 +131,7 @@ class TurnaboutEffect extends OneShotEffect { choiceImpl.setMessage("Choose to tap or untap"); choiceImpl.setChoices(choice2); while (!controller.choose(Outcome.Neutral, choiceImpl, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/urzassaga/Unnerve.java b/Mage.Sets/src/mage/sets/urzassaga/Unnerve.java new file mode 100644 index 00000000000..a6251fa60b6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/urzassaga/Unnerve.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.urzassaga; + +import java.util.UUID; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.discard.DiscardEachPlayerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; + +/** + * + * @author fireshoes + */ +public class Unnerve extends CardImpl { + + public Unnerve(UUID ownerId) { + super(ownerId, 162, "Unnerve", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{3}{B}"); + this.expansionSetCode = "USG"; + + // Each opponent discards two cards. + this.getSpellAbility().addEffect(new DiscardEachPlayerEffect(new StaticValue(2), false, TargetController.OPPONENT)); + } + + public Unnerve(final Unnerve card) { + super(card); + } + + @Override + public Unnerve copy() { + return new Unnerve(this); + } +} diff --git a/Mage.Sets/src/mage/sets/venservskoth/AEtherMembrane.java b/Mage.Sets/src/mage/sets/venservskoth/AEtherMembrane.java new file mode 100644 index 00000000000..f799049694a --- /dev/null +++ b/Mage.Sets/src/mage/sets/venservskoth/AEtherMembrane.java @@ -0,0 +1,111 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.venservskoth; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BlocksCreatureTriggeredAbility; +import mage.abilities.common.delayed.AtTheEndOfCombatDelayedTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.abilities.keyword.ReachAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.targetpointer.FixedTarget; + +import java.util.UUID; + +/** + * + * @author klayhamn + */ +public class AEtherMembrane extends CardImpl { + + public AEtherMembrane(UUID ownerId) { + super(ownerId, 48, "AEther Membrane", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{R}{R}"); + this.expansionSetCode = "DDI"; + this.subtype.add("Wall"); + this.power = new MageInt(0); + this.toughness = new MageInt(5); + + // Defender; reach + this.addAbility(ReachAbility.getInstance()); + this.addAbility(DefenderAbility.getInstance()); + + // Whenever AEther Membrane blocks a creature, return that creature to its owner's hand at end of combat. + this.addAbility(new BlocksCreatureTriggeredAbility(new AEtherMembraneEffect(), false, true)); + } + + public AEtherMembrane(final AEtherMembrane card) { + super(card); + } + + @Override + public AEtherMembrane copy() { + return new AEtherMembrane(this); + } +} + +// @klayhamn: This is identical to the effect of KaijinOfTheVanishingTouch but there's only 2 cards with this effect +// and it's not generic enough to be extracted, imho +class AEtherMembraneEffect extends OneShotEffect { + + AEtherMembraneEffect() { + super(Outcome.ReturnToHand); + staticText = "return that creature to its owner's hand at end of combat"; + } + + AEtherMembraneEffect(final AEtherMembraneEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent targetCreature = game.getPermanent(this.getTargetPointer().getFirst(game, source)); + if (targetCreature != null) { + AtTheEndOfCombatDelayedTriggeredAbility delayedAbility = new AtTheEndOfCombatDelayedTriggeredAbility(new ReturnToHandTargetEffect()); + delayedAbility.setSourceId(source.getSourceId()); + delayedAbility.setControllerId(source.getControllerId()); + delayedAbility.setSourceObject(source.getSourceObject(game), game); + delayedAbility.getEffects().get(0).setTargetPointer(new FixedTarget(targetCreature.getId())); + game.addDelayedTriggeredAbility(delayedAbility); + return true; + } + return false; + } + + @Override + public AEtherMembraneEffect copy() { + return new AEtherMembraneEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/vintagemasters/Addle.java b/Mage.Sets/src/mage/sets/vintagemasters/Addle.java new file mode 100644 index 00000000000..3ce4e067d53 --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/Addle.java @@ -0,0 +1,107 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.discard.DiscardCardYouChooseTargetEffect; +import mage.cards.CardImpl; +import mage.choices.ChoiceColor; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetPlayer; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + */ +public class Addle extends CardImpl { + + public Addle(UUID ownerId) { + super(ownerId, 103, "Addle", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{B}"); + this.expansionSetCode = "VMA"; + + // Choose a color. Target player reveals his or her hand and you choose a card of that color from it. That player discards that card. + this.getSpellAbility().addEffect(new AddleEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + } + + public Addle(final Addle card) { + super(card); + } + + @Override + public Addle copy() { + return new Addle(this); + } +} + +class AddleEffect extends OneShotEffect { + + AddleEffect() { + super(Outcome.Discard); + staticText = "Choose a color. Target player reveals his or her hand and you choose a card of that color from it. That player discards that card."; + } + + AddleEffect(final AddleEffect effect) { + super(effect); + } + + @Override + public AddleEffect copy() { + return new AddleEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if(controller != null) { + ChoiceColor choice = new ChoiceColor(); + controller.choose(outcome, choice, game); + ObjectColor color = choice.getColor(); + if(color != null) { + game.informPlayers(controller.getLogName() + " chooses " + color + "."); + FilterCard filter = new FilterCard(); + filter.add(new ColorPredicate(color)); + Effect effect = new DiscardCardYouChooseTargetEffect(filter); + return effect.apply(game, source); + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/vintagemasters/Channel.java b/Mage.Sets/src/mage/sets/vintagemasters/Channel.java new file mode 100644 index 00000000000..e0b0cc26a92 --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/Channel.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author emerald000 + */ +public class Channel extends mage.sets.revisededition.Channel { + + public Channel(UUID ownerId) { + super(ownerId); + this.cardNumber = 200; + this.expansionSetCode = "VMA"; + this.rarity = Rarity.MYTHIC; + } + + public Channel(final Channel card) { + super(card); + } + + @Override + public Channel copy() { + return new Channel(this); + } +} diff --git a/Mage.Sets/src/mage/sets/vintagemasters/CityInABottle.java b/Mage.Sets/src/mage/sets/vintagemasters/CityInABottle.java index e1439fae1f8..abb456a4e2a 100644 --- a/Mage.Sets/src/mage/sets/vintagemasters/CityInABottle.java +++ b/Mage.Sets/src/mage/sets/vintagemasters/CityInABottle.java @@ -27,6 +27,8 @@ */ package mage.sets.vintagemasters; +import java.util.ArrayList; +import java.util.List; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.StateTriggeredAbility; @@ -49,14 +51,13 @@ import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; +import static mage.sets.vintagemasters.CityInABottle.getArabianNightsNamePredicates; /** * * @author emerald000 */ public class CityInABottle extends CardImpl { - - private static final FilterCard filterCard = new FilterCard("cards originally printed in the Arabian Nights expansion"); public CityInABottle(UUID ownerId) { super(ownerId, 265, "City in a Bottle", Rarity.MYTHIC, new CardType[]{CardType.ARTIFACT}, "{2}"); @@ -64,7 +65,7 @@ public class CityInABottle extends CardImpl { // Whenever a nontoken permanent originally printed in the Arabian Nights expansion other than City in a Bottle is on the battlefield, its controller sacrifices it. this.addAbility(new CityInABottleStateTriggeredAbility()); - + // Players can't play cards originally printed in the Arabian Nights expansion. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CityInABottleCantPlayEffect())); } @@ -77,92 +78,99 @@ public class CityInABottle extends CardImpl { public CityInABottle copy() { return new CityInABottle(this); } + + static public List getArabianNightsNamePredicates() { + List namePredicatesArabianNights = new ArrayList<>(); + namePredicatesArabianNights.add(new NamePredicate("Abu Ja'far")); + namePredicatesArabianNights.add(new NamePredicate("Aladdin")); + namePredicatesArabianNights.add(new NamePredicate("Aladdin's Lamp")); + namePredicatesArabianNights.add(new NamePredicate("Aladdin's Ring")); + namePredicatesArabianNights.add(new NamePredicate("Ali Baba")); + namePredicatesArabianNights.add(new NamePredicate("Ali from Cairo")); + namePredicatesArabianNights.add(new NamePredicate("Army of Allah")); + namePredicatesArabianNights.add(new NamePredicate("Bazaar of Baghdad")); + namePredicatesArabianNights.add(new NamePredicate("Bird Maiden")); + namePredicatesArabianNights.add(new NamePredicate("Bottle of Suleiman")); + namePredicatesArabianNights.add(new NamePredicate("Brass Man")); + namePredicatesArabianNights.add(new NamePredicate("Camel")); + namePredicatesArabianNights.add(new NamePredicate("City of Brass")); + namePredicatesArabianNights.add(new NamePredicate("Cuombajj Witches")); + namePredicatesArabianNights.add(new NamePredicate("Cyclone")); + namePredicatesArabianNights.add(new NamePredicate("Dancing Scimitar")); + namePredicatesArabianNights.add(new NamePredicate("Dandân")); + namePredicatesArabianNights.add(new NamePredicate("Desert")); + namePredicatesArabianNights.add(new NamePredicate("Desert Nomads")); + namePredicatesArabianNights.add(new NamePredicate("Desert Twister")); + namePredicatesArabianNights.add(new NamePredicate("Diamond Valley")); + namePredicatesArabianNights.add(new NamePredicate("Drop of Honey")); + namePredicatesArabianNights.add(new NamePredicate("Ebony Horse")); + namePredicatesArabianNights.add(new NamePredicate("El-Hajjâj")); + namePredicatesArabianNights.add(new NamePredicate("Elephant Graveyard")); + namePredicatesArabianNights.add(new NamePredicate("Erg Raiders")); + namePredicatesArabianNights.add(new NamePredicate("Erhnam Djinn")); + namePredicatesArabianNights.add(new NamePredicate("Eye for an Eye")); + namePredicatesArabianNights.add(new NamePredicate("Fishliver Oil")); + namePredicatesArabianNights.add(new NamePredicate("Flying Carpet")); + namePredicatesArabianNights.add(new NamePredicate("Flying Men")); + namePredicatesArabianNights.add(new NamePredicate("Ghazbán Ogre")); + namePredicatesArabianNights.add(new NamePredicate("Giant Tortoise")); + namePredicatesArabianNights.add(new NamePredicate("Guardian Beast")); + namePredicatesArabianNights.add(new NamePredicate("Hasran Ogress")); + namePredicatesArabianNights.add(new NamePredicate("Hurr Jackal")); + namePredicatesArabianNights.add(new NamePredicate("Ifh-Bíff Efreet")); + namePredicatesArabianNights.add(new NamePredicate("Island Fish Jasconius")); + namePredicatesArabianNights.add(new NamePredicate("Island of Wak-Wak")); + namePredicatesArabianNights.add(new NamePredicate("Jandor's Ring")); + namePredicatesArabianNights.add(new NamePredicate("Jandor's Saddlebags")); + namePredicatesArabianNights.add(new NamePredicate("Jeweled Bird")); + namePredicatesArabianNights.add(new NamePredicate("Jihad")); + namePredicatesArabianNights.add(new NamePredicate("Junún Efreet")); + namePredicatesArabianNights.add(new NamePredicate("Juzám Djinn")); + namePredicatesArabianNights.add(new NamePredicate("Khabál Ghoul")); + namePredicatesArabianNights.add(new NamePredicate("King Suleiman")); + namePredicatesArabianNights.add(new NamePredicate("Kird Ape")); + namePredicatesArabianNights.add(new NamePredicate("Library of Alexandria")); + namePredicatesArabianNights.add(new NamePredicate("Magnetic Mountain")); + namePredicatesArabianNights.add(new NamePredicate("Merchant Ship")); + namePredicatesArabianNights.add(new NamePredicate("Metamorphosis")); + namePredicatesArabianNights.add(new NamePredicate("Mijae Djinn")); + namePredicatesArabianNights.add(new NamePredicate("Moorish Cavalry")); + namePredicatesArabianNights.add(new NamePredicate("Nafs Asp")); + namePredicatesArabianNights.add(new NamePredicate("Oasis")); + namePredicatesArabianNights.add(new NamePredicate("Old Man of the Sea")); + namePredicatesArabianNights.add(new NamePredicate("Oubliette")); + namePredicatesArabianNights.add(new NamePredicate("Piety")); + namePredicatesArabianNights.add(new NamePredicate("Pyramids")); + namePredicatesArabianNights.add(new NamePredicate("Repentant Blacksmith")); + namePredicatesArabianNights.add(new NamePredicate("Ring of Ma'rûf")); + namePredicatesArabianNights.add(new NamePredicate("Rukh Egg")); + namePredicatesArabianNights.add(new NamePredicate("Sandals of Abdallah")); + namePredicatesArabianNights.add(new NamePredicate("Sandstorm")); + namePredicatesArabianNights.add(new NamePredicate("Serendib Djinn")); + namePredicatesArabianNights.add(new NamePredicate("Serendib Efreet")); + namePredicatesArabianNights.add(new NamePredicate("Shahrazad")); + namePredicatesArabianNights.add(new NamePredicate("Sindbad")); + namePredicatesArabianNights.add(new NamePredicate("Singing Tree")); + namePredicatesArabianNights.add(new NamePredicate("Sorceress Queen")); + namePredicatesArabianNights.add(new NamePredicate("Stone-Throwing Devils")); + namePredicatesArabianNights.add(new NamePredicate("Unstable Mutation")); + namePredicatesArabianNights.add(new NamePredicate("War Elephant")); + namePredicatesArabianNights.add(new NamePredicate("Wyluli Wolf")); + namePredicatesArabianNights.add(new NamePredicate("Ydwen Efreet")); + return namePredicatesArabianNights; + } } class CityInABottleStateTriggeredAbility extends StateTriggeredAbility { - + private static final FilterPermanent filter = new FilterPermanent("a nontoken permanent originally printed in the Arabian Nights expansion other than City in a Bottle"); + static { filter.add(Predicates.not(new TokenPredicate())); - filter.add(Predicates.or( - new NamePredicate("Abu Ja'far"), - new NamePredicate("Aladdin"), - new NamePredicate("Aladdin's Lamp"), - new NamePredicate("Aladdin's Ring"), - new NamePredicate("Ali Baba"), - new NamePredicate("Ali from Cairo"), - new NamePredicate("Army of Allah"), - new NamePredicate("Bazaar of Baghdad"), - new NamePredicate("Bird Maiden"), - new NamePredicate("Bottle of Suleiman"), - new NamePredicate("Brass Man"), - new NamePredicate("Camel"), - new NamePredicate("City of Brass"), - new NamePredicate("Cuombajj Witches"), - new NamePredicate("Cyclone"), - new NamePredicate("Dancing Scimitar"), - new NamePredicate("Dandân"), - new NamePredicate("Desert"), - new NamePredicate("Desert Nomads"), - new NamePredicate("Desert Twister"), - new NamePredicate("Diamond Valley"), - new NamePredicate("Drop of Honey"), - new NamePredicate("Ebony Horse"), - new NamePredicate("El-Hajjâj"), - new NamePredicate("Elephant Graveyard"), - new NamePredicate("Erg Raiders"), - new NamePredicate("Erhnam Djinn"), - new NamePredicate("Eye for an Eye"), - new NamePredicate("Fishliver Oil"), - new NamePredicate("Flying Carpet"), - new NamePredicate("Flying Men"), - new NamePredicate("Ghazbán Ogre"), - new NamePredicate("Giant Tortoise"), - new NamePredicate("Guardian Beast"), - new NamePredicate("Hasran Ogress"), - new NamePredicate("Hurr Jackal"), - new NamePredicate("Ifh-Bíff Efreet"), - new NamePredicate("Island Fish Jasconius"), - new NamePredicate("Island of Wak-Wak"), - new NamePredicate("Jandor's Ring"), - new NamePredicate("Jandor's Saddlebags"), - new NamePredicate("Jeweled Bird"), - new NamePredicate("Jihad"), - new NamePredicate("Junún Efreet"), - new NamePredicate("Juzám Djinn"), - new NamePredicate("Khabál Ghoul"), - new NamePredicate("King Suleiman"), - new NamePredicate("Kird Ape"), - new NamePredicate("Library of Alexandria"), - new NamePredicate("Magnetic Mountain"), - new NamePredicate("Merchant Ship"), - new NamePredicate("Metamorphosis"), - new NamePredicate("Mijae Djinn"), - new NamePredicate("Moorish Cavalry"), - new NamePredicate("Nafs Asp"), - new NamePredicate("Oasis"), - new NamePredicate("Old Man of the Sea"), - new NamePredicate("Oubliette"), - new NamePredicate("Piety"), - new NamePredicate("Pyramids"), - new NamePredicate("Repentant Blacksmith"), - new NamePredicate("Ring of Ma'rûf"), - new NamePredicate("Rukh Egg"), - new NamePredicate("Sandals of Abdallah"), - new NamePredicate("Sandstorm"), - new NamePredicate("Serendib Djinn"), - new NamePredicate("Serendib Efreet"), - new NamePredicate("Shahrazad"), - new NamePredicate("Sindbad"), - new NamePredicate("Singing Tree"), - new NamePredicate("Sorceress Queen"), - new NamePredicate("Stone-Throwing Devils"), - new NamePredicate("Unstable Mutation"), - new NamePredicate("War Elephant"), - new NamePredicate("Wyluli Wolf"), - new NamePredicate("Ydwen Efreet"))); + filter.add(Predicates.or(getArabianNightsNamePredicates())); + } - + CityInABottleStateTriggeredAbility() { super(Zone.BATTLEFIELD, new CityInABottleSacrificeEffect()); } @@ -188,103 +196,28 @@ class CityInABottleStateTriggeredAbility extends StateTriggeredAbility { } class CityInABottleSacrificeEffect extends OneShotEffect { - + private static final FilterPermanent filter = new FilterPermanent("a nontoken permanent originally printed in the Arabian Nights expansion other than City in a Bottle"); + static { filter.add(Predicates.not(new TokenPredicate())); - filter.add(Predicates.or( - new NamePredicate("Abu Ja'far"), - new NamePredicate("Aladdin"), - new NamePredicate("Aladdin's Lamp"), - new NamePredicate("Aladdin's Ring"), - new NamePredicate("Ali Baba"), - new NamePredicate("Ali from Cairo"), - new NamePredicate("Army of Allah"), - new NamePredicate("Bazaar of Baghdad"), - new NamePredicate("Bird Maiden"), - new NamePredicate("Bottle of Suleiman"), - new NamePredicate("Brass Man"), - new NamePredicate("Camel"), - new NamePredicate("City of Brass"), - new NamePredicate("Cuombajj Witches"), - new NamePredicate("Cyclone"), - new NamePredicate("Dancing Scimitar"), - new NamePredicate("Dandân"), - new NamePredicate("Desert"), - new NamePredicate("Desert Nomads"), - new NamePredicate("Desert Twister"), - new NamePredicate("Diamond Valley"), - new NamePredicate("Drop of Honey"), - new NamePredicate("Ebony Horse"), - new NamePredicate("El-Hajjâj"), - new NamePredicate("Elephant Graveyard"), - new NamePredicate("Erg Raiders"), - new NamePredicate("Erhnam Djinn"), - new NamePredicate("Eye for an Eye"), - new NamePredicate("Fishliver Oil"), - new NamePredicate("Flying Carpet"), - new NamePredicate("Flying Men"), - new NamePredicate("Ghazbán Ogre"), - new NamePredicate("Giant Tortoise"), - new NamePredicate("Guardian Beast"), - new NamePredicate("Hasran Ogress"), - new NamePredicate("Hurr Jackal"), - new NamePredicate("Ifh-Bíff Efreet"), - new NamePredicate("Island Fish Jasconius"), - new NamePredicate("Island of Wak-Wak"), - new NamePredicate("Jandor's Ring"), - new NamePredicate("Jandor's Saddlebags"), - new NamePredicate("Jeweled Bird"), - new NamePredicate("Jihad"), - new NamePredicate("Junún Efreet"), - new NamePredicate("Juzám Djinn"), - new NamePredicate("Khabál Ghoul"), - new NamePredicate("King Suleiman"), - new NamePredicate("Kird Ape"), - new NamePredicate("Library of Alexandria"), - new NamePredicate("Magnetic Mountain"), - new NamePredicate("Merchant Ship"), - new NamePredicate("Metamorphosis"), - new NamePredicate("Mijae Djinn"), - new NamePredicate("Moorish Cavalry"), - new NamePredicate("Nafs Asp"), - new NamePredicate("Oasis"), - new NamePredicate("Old Man of the Sea"), - new NamePredicate("Oubliette"), - new NamePredicate("Piety"), - new NamePredicate("Pyramids"), - new NamePredicate("Repentant Blacksmith"), - new NamePredicate("Ring of Ma'rûf"), - new NamePredicate("Rukh Egg"), - new NamePredicate("Sandals of Abdallah"), - new NamePredicate("Sandstorm"), - new NamePredicate("Serendib Djinn"), - new NamePredicate("Serendib Efreet"), - new NamePredicate("Shahrazad"), - new NamePredicate("Sindbad"), - new NamePredicate("Singing Tree"), - new NamePredicate("Sorceress Queen"), - new NamePredicate("Stone-Throwing Devils"), - new NamePredicate("Unstable Mutation"), - new NamePredicate("War Elephant"), - new NamePredicate("Wyluli Wolf"), - new NamePredicate("Ydwen Efreet"))); + filter.add(Predicates.or(getArabianNightsNamePredicates())); } - + CityInABottleSacrificeEffect() { super(Outcome.Sacrifice); this.staticText = "its controller sacrifices it"; } - + CityInABottleSacrificeEffect(final CityInABottleSacrificeEffect effect) { super(effect); } - + @Override public CityInABottleSacrificeEffect copy() { return new CityInABottleSacrificeEffect(this); } - + @Override public boolean apply(Game game, Ability source) { for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { @@ -295,87 +228,11 @@ class CityInABottleSacrificeEffect extends OneShotEffect { } class CityInABottleCantPlayEffect extends ContinuousRuleModifyingEffectImpl { - + private static final FilterCard filter = new FilterCard("cards originally printed in the Arabian Nights expansion"); + static { - filter.add(Predicates.or( - new NamePredicate("Abu Ja'far"), - new NamePredicate("Aladdin"), - new NamePredicate("Aladdin's Lamp"), - new NamePredicate("Aladdin's Ring"), - new NamePredicate("Ali Baba"), - new NamePredicate("Ali from Cairo"), - new NamePredicate("Army of Allah"), - new NamePredicate("Bazaar of Baghdad"), - new NamePredicate("Bird Maiden"), - new NamePredicate("Bottle of Suleiman"), - new NamePredicate("Brass Man"), - new NamePredicate("Camel"), - new NamePredicate("City in a Bottle"), - new NamePredicate("City of Brass"), - new NamePredicate("Cuombajj Witches"), - new NamePredicate("Cyclone"), - new NamePredicate("Dancing Scimitar"), - new NamePredicate("Dandân"), - new NamePredicate("Desert"), - new NamePredicate("Desert Nomads"), - new NamePredicate("Desert Twister"), - new NamePredicate("Diamond Valley"), - new NamePredicate("Drop of Honey"), - new NamePredicate("Ebony Horse"), - new NamePredicate("El-Hajjâj"), - new NamePredicate("Elephant Graveyard"), - new NamePredicate("Erg Raiders"), - new NamePredicate("Erhnam Djinn"), - new NamePredicate("Eye for an Eye"), - new NamePredicate("Fishliver Oil"), - new NamePredicate("Flying Carpet"), - new NamePredicate("Flying Men"), - new NamePredicate("Ghazbán Ogre"), - new NamePredicate("Giant Tortoise"), - new NamePredicate("Guardian Beast"), - new NamePredicate("Hasran Ogress"), - new NamePredicate("Hurr Jackal"), - new NamePredicate("Ifh-Bíff Efreet"), - new NamePredicate("Island Fish Jasconius"), - new NamePredicate("Island of Wak-Wak"), - new NamePredicate("Jandor's Ring"), - new NamePredicate("Jandor's Saddlebags"), - new NamePredicate("Jeweled Bird"), - new NamePredicate("Jihad"), - new NamePredicate("Junún Efreet"), - new NamePredicate("Juzám Djinn"), - new NamePredicate("Khabál Ghoul"), - new NamePredicate("King Suleiman"), - new NamePredicate("Kird Ape"), - new NamePredicate("Library of Alexandria"), - new NamePredicate("Magnetic Mountain"), - new NamePredicate("Merchant Ship"), - new NamePredicate("Metamorphosis"), - new NamePredicate("Mijae Djinn"), - new NamePredicate("Moorish Cavalry"), - new NamePredicate("Nafs Asp"), - new NamePredicate("Oasis"), - new NamePredicate("Old Man of the Sea"), - new NamePredicate("Oubliette"), - new NamePredicate("Piety"), - new NamePredicate("Pyramids"), - new NamePredicate("Repentant Blacksmith"), - new NamePredicate("Ring of Ma'rûf"), - new NamePredicate("Rukh Egg"), - new NamePredicate("Sandals of Abdallah"), - new NamePredicate("Sandstorm"), - new NamePredicate("Serendib Djinn"), - new NamePredicate("Serendib Efreet"), - new NamePredicate("Shahrazad"), - new NamePredicate("Sindbad"), - new NamePredicate("Singing Tree"), - new NamePredicate("Sorceress Queen"), - new NamePredicate("Stone-Throwing Devils"), - new NamePredicate("Unstable Mutation"), - new NamePredicate("War Elephant"), - new NamePredicate("Wyluli Wolf"), - new NamePredicate("Ydwen Efreet"))); + filter.add(Predicates.or(getArabianNightsNamePredicates())); } CityInABottleCantPlayEffect() { @@ -401,12 +258,12 @@ class CityInABottleCantPlayEffect extends ContinuousRuleModifyingEffectImpl { public String getInfoMessage(Ability source, GameEvent event, Game game) { return "You can't play cards originally printed in the Arabian Nights expansion"; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.PLAY_LAND || event.getType() == EventType.CAST_SPELL; } - + @Override public boolean applies(GameEvent event, Ability source, Game game) { Card card = game.getCard(event.getSourceId()); diff --git a/Mage.Sets/src/mage/sets/vintagemasters/CrescendoOfWar.java b/Mage.Sets/src/mage/sets/vintagemasters/CrescendoOfWar.java new file mode 100644 index 00000000000..45773d8f0af --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/CrescendoOfWar.java @@ -0,0 +1,77 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.common.FilterAttackingCreature; +import mage.filter.common.FilterBlockingCreature; + +/** + * + * @author fireshoes + */ +public class CrescendoOfWar extends CardImpl { + + public CrescendoOfWar(UUID ownerId) { + super(ownerId, 21, "Crescendo of War", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}"); + this.expansionSetCode = "VMA"; + + // At the beginning of each upkeep, put a strife counter on Crescendo of War. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.STRIFE.createInstance(1), true), TargetController.ANY, false)); + + // Attacking creatures get +1/+0 for each strife counter on Crescendo of War. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(new CountersCount(CounterType.STRIFE), new StaticValue(0), + Duration.WhileOnBattlefield, new FilterAttackingCreature(), false))); + + // Blocking creatures you control get +1/+0 for each strife counter on Crescendo of War. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostAllEffect(new CountersCount(CounterType.STRIFE), new StaticValue(0), + Duration.WhileOnBattlefield, new FilterBlockingCreature(), false))); + } + + public CrescendoOfWar(final CrescendoOfWar card) { + super(card); + } + + @Override + public CrescendoOfWar copy() { + return new CrescendoOfWar(this); + } +} diff --git a/Mage.Sets/src/mage/sets/vintagemasters/Eureka.java b/Mage.Sets/src/mage/sets/vintagemasters/Eureka.java index 1900a95d1fe..c47f7887e12 100644 --- a/Mage.Sets/src/mage/sets/vintagemasters/Eureka.java +++ b/Mage.Sets/src/mage/sets/vintagemasters/Eureka.java @@ -89,18 +89,18 @@ class EurekaEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { PlayerList playerList = game.getState().getPlayerList().copy(); - while (!playerList.get().equals(source.getControllerId()) && controller.isInGame()) { + while (!playerList.get().equals(source.getControllerId()) && controller.canRespond()) { playerList.getNext(); } Player currentPlayer = game.getPlayer(playerList.get()); UUID firstInactivePlayer = null; Target target = new TargetCardInHand(new FilterPermanentCard()); - while (controller.isInGame()) { + while (controller.canRespond()) { if (firstInactivePlayer == null) { firstInactivePlayer = currentPlayer.getId(); } - if (currentPlayer != null && currentPlayer.isInGame() && controller.getInRange().contains(currentPlayer.getId())) { + if (currentPlayer != null && currentPlayer.canRespond() && controller.getInRange().contains(currentPlayer.getId())) { target.clearChosen(); if (target.canChoose(source.getSourceId(), currentPlayer.getId(), game) diff --git a/Mage.Sets/src/mage/sets/vintagemasters/MagisterOfWorth.java b/Mage.Sets/src/mage/sets/vintagemasters/MagisterOfWorth.java new file mode 100644 index 00000000000..5242c1ab252 --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/MagisterOfWorth.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class MagisterOfWorth extends mage.sets.mediainserts.MagisterOfWorth { + + public MagisterOfWorth(UUID ownerId) { + super(ownerId); + this.cardNumber = 255; + this.expansionSetCode = "VMA"; + this.rarity = Rarity.RARE; + } + + public MagisterOfWorth(final MagisterOfWorth card) { + super(card); + } + + @Override + public MagisterOfWorth copy() { + return new MagisterOfWorth(this); + } +} diff --git a/Mage.Sets/src/mage/sets/vintagemasters/MuzzioVisionaryArchitect.java b/Mage.Sets/src/mage/sets/vintagemasters/MuzzioVisionaryArchitect.java new file mode 100644 index 00000000000..6af2163443b --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/MuzzioVisionaryArchitect.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class MuzzioVisionaryArchitect extends mage.sets.conspiracy.MuzzioVisionaryArchitect { + + public MuzzioVisionaryArchitect(UUID ownerId) { + super(ownerId); + this.cardNumber = 82; + this.expansionSetCode = "VMA"; + } + + public MuzzioVisionaryArchitect(final MuzzioVisionaryArchitect card) { + super(card); + } + + @Override + public MuzzioVisionaryArchitect copy() { + return new MuzzioVisionaryArchitect(this); + } +} diff --git a/Mage.Sets/src/mage/sets/vintagemasters/SelvalaExplorerReturned.java b/Mage.Sets/src/mage/sets/vintagemasters/SelvalaExplorerReturned.java new file mode 100644 index 00000000000..3a88cb54f45 --- /dev/null +++ b/Mage.Sets/src/mage/sets/vintagemasters/SelvalaExplorerReturned.java @@ -0,0 +1,112 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.vintagemasters; + +import java.util.UUID; +import mage.MageInt; +import mage.Mana; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.dynamicvalue.common.ParleyCount; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DrawCardAllEffect; +import mage.cards.CardImpl; +import mage.constants.AbilityWord; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author LevelX2 + */ +public class SelvalaExplorerReturned extends CardImpl { + + public SelvalaExplorerReturned(UUID ownerId) { + super(ownerId, 260, "Selvala, Explorer Returned", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{G}{W}"); + this.expansionSetCode = "VMA"; + this.supertype.add("Legendary"); + this.subtype.add("Elf"); + this.subtype.add("Scout"); + this.power = new MageInt(2); + this.toughness = new MageInt(4); + + // Parley - {T}: Each player reveals the top card of his or her library. For each nonland card revealed this way, add {G} to your mana pool and you gain 1 life. Then each player draws a card. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SelvalaExplorerReturnedEffect(), new TapSourceCost()); + ability.setAbilityWord(AbilityWord.PARLEY); + Effect effect = new DrawCardAllEffect(1); + effect.setText("Then each player draws a card"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public SelvalaExplorerReturned(final SelvalaExplorerReturned card) { + super(card); + } + + @Override + public SelvalaExplorerReturned copy() { + return new SelvalaExplorerReturned(this); + } +} + +class SelvalaExplorerReturnedEffect extends OneShotEffect { + + public SelvalaExplorerReturnedEffect() { + super(Outcome.Benefit); + this.staticText = "Each player reveals the top card of his or her library. For each nonland card revealed this way, add {G} to your mana pool and you gain 1 life"; + } + + public SelvalaExplorerReturnedEffect(final SelvalaExplorerReturnedEffect effect) { + super(effect); + } + + @Override + public SelvalaExplorerReturnedEffect copy() { + return new SelvalaExplorerReturnedEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + int parley = ParleyCount.getInstance().calculate(game, source, this); + if (parley > 0) { + controller.getManaPool().addMana(new Mana(0, parley, 0, 0, 0, 0, 0), game, source); + controller.gainLife(parley, game); + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/visions/ArmyAnts.java b/Mage.Sets/src/mage/sets/visions/ArmyAnts.java new file mode 100644 index 00000000000..91bf8d80ae5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/ArmyAnts.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterControlledLandPermanent; +import mage.target.common.TargetControlledPermanent; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author fireshoes + */ +public class ArmyAnts extends CardImpl { + + public ArmyAnts(UUID ownerId) { + super(ownerId, 126, "Army Ants", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{B}{R}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Insect"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {tap}, Sacrifice a land: Destroy target land. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new DestroyTargetEffect(), + new TapSourceCost()); + ability.addCost(new SacrificeTargetCost(new TargetControlledPermanent(new FilterControlledLandPermanent()))); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public ArmyAnts(final ArmyAnts card) { + super(card); + } + + @Override + public ArmyAnts copy() { + return new ArmyAnts(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/Betrayal.java b/Mage.Sets/src/mage/sets/visions/Betrayal.java new file mode 100644 index 00000000000..db86ed389fc --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/Betrayal.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BecomesTappedAttachedTriggeredAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class Betrayal extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature an opponent controls"); + + static { + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public Betrayal(UUID ownerId) { + super(ownerId, 26, "Betrayal", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{U}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Aura"); + + // Enchant creature an opponent controls + TargetPermanent auraTarget = new TargetCreaturePermanent(filter); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.Detriment)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Whenever enchanted creature becomes tapped, you draw a card. + this.addAbility(new BecomesTappedAttachedTriggeredAbility(new DrawCardSourceControllerEffect(1), false)); + } + + public Betrayal(final Betrayal card) { + super(card); + } + + @Override + public Betrayal copy() { + return new Betrayal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/Chronatog.java b/Mage.Sets/src/mage/sets/visions/Chronatog.java new file mode 100644 index 00000000000..96dc557dda3 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/Chronatog.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.LimitedTimesPerTurnActivatedAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.turn.SkipNextTurnSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class Chronatog extends CardImpl { + + public Chronatog(UUID ownerId) { + super(ownerId, 28, "Chronatog", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{U}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Atog"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {0}: Chronatog gets +3/+3 until end of turn. You skip your next turn. Activate this ability only once each turn. + Ability ability = new LimitedTimesPerTurnActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(3, 3, Duration.EndOfTurn), new GenericManaCost(0)); + ability.addEffect(new SkipNextTurnSourceEffect()); + this.addAbility(ability); + } + + public Chronatog(final Chronatog card) { + super(card); + } + + @Override + public Chronatog copy() { + return new Chronatog(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/Desertion.java b/Mage.Sets/src/mage/sets/visions/Desertion.java index 728c4856058..5c2f1b08387 100644 --- a/Mage.Sets/src/mage/sets/visions/Desertion.java +++ b/Mage.Sets/src/mage/sets/visions/Desertion.java @@ -56,7 +56,6 @@ public class Desertion extends CardImpl { super(ownerId, 30, "Desertion", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{3}{U}{U}"); this.expansionSetCode = "VIS"; - // Counter target spell. If an artifact or creature spell is countered this way, put that card onto the battlefield under your control instead of into its owner's graveyard. this.getSpellAbility().addEffect(new DesertionEffect()); this.getSpellAbility().addTarget(new TargetSpell()); @@ -81,7 +80,7 @@ class DesertionEffect extends OneShotEffect { new CardTypePredicate(CardType.ARTIFACT), new CardTypePredicate(CardType.CREATURE))); } - + public DesertionEffect() { super(Outcome.Detriment); this.staticText = "Counter target spell. If an artifact or creature spell is countered this way, put that card onto the battlefield under your control instead of into its owner's graveyard."; @@ -106,7 +105,7 @@ class DesertionEffect extends OneShotEffect { if (stackObject instanceof Spell) { game.rememberLKI(objectId, Zone.STACK, (Spell) stackObject); game.getStack().remove(stackObject); - if (!((Spell) stackObject).isCopiedSpell() && filter.match(stackObject, source.getControllerId(), game)) { + if (!((Spell) stackObject).isCopiedSpell() && filter.match(stackObject, source.getSourceId(), source.getControllerId(), game)) { MageObject card = game.getObject(stackObject.getSourceId()); if (card instanceof Card) { ((Card) card).putOntoBattlefield(game, Zone.STACK, source.getSourceId(), source.getControllerId()); @@ -120,5 +119,5 @@ class DesertionEffect extends OneShotEffect { } return false; } - + } diff --git a/Mage.Sets/src/mage/sets/visions/EmeraldCharm.java b/Mage.Sets/src/mage/sets/visions/EmeraldCharm.java new file mode 100644 index 00000000000..9897e61e069 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/EmeraldCharm.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.abilities.Mode; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.UntapTargetEffect; +import mage.abilities.effects.common.continuous.LoseAbilityTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterEnchantmentPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; +import mage.target.common.TargetEnchantmentPermanent; + +/** + * + * @author fireshoes + */ +public class EmeraldCharm extends CardImpl { + + private static final FilterEnchantmentPermanent filter = new FilterEnchantmentPermanent("non-Aura enchantment"); + + static { + filter.add(Predicates.not(new SubtypePredicate("Aura"))); + } + + public EmeraldCharm(UUID ownerId) { + super(ownerId, 56, "Emerald Charm", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{G}"); + this.expansionSetCode = "VIS"; + + // Choose one - Untap target permanent; + this.getSpellAbility().addEffect(new UntapTargetEffect()); + this.getSpellAbility().addTarget(new TargetPermanent()); + + // or destroy target non-Aura enchantment; + Mode mode = new Mode(); + mode.getEffects().add(new DestroyTargetEffect()); + mode.getTargets().add(new TargetEnchantmentPermanent(filter)); + this.getSpellAbility().addMode(mode); + + // or target creature loses flying until end of turn. + mode = new Mode(); + mode.getEffects().add(new LoseAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn)); + mode.getTargets().add(new TargetCreaturePermanent()); + this.getSpellAbility().addMode(mode); + } + + public EmeraldCharm(final EmeraldCharm card) { + super(card); + } + + @Override + public EmeraldCharm copy() { + return new EmeraldCharm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/GoblinRecruiter.java b/Mage.Sets/src/mage/sets/visions/GoblinRecruiter.java index b278362bbc4..b2951b39274 100644 --- a/Mage.Sets/src/mage/sets/visions/GoblinRecruiter.java +++ b/Mage.Sets/src/mage/sets/visions/GoblinRecruiter.java @@ -120,7 +120,7 @@ class GoblinRecruiterEffect extends OneShotEffect { if (numberOfGoblins > 0) { if (cards.size() > 1) { TargetCard targetCard = new TargetCard(Zone.LIBRARY, putOnTopOfLibraryFilter); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Benefit, cards, targetCard, game); Card card = cards.get(targetCard.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/visions/MagmaMine.java b/Mage.Sets/src/mage/sets/visions/MagmaMine.java new file mode 100644 index 00000000000..aac5b04b731 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/MagmaMine.java @@ -0,0 +1,76 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author fireshoes + */ +public class MagmaMine extends CardImpl { + + public MagmaMine(UUID ownerId) { + super(ownerId, 149, "Magma Mine", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "VIS"; + + // {4}: Put a pressure counter on Magma Mine. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, + new AddCountersSourceEffect(CounterType.PRESSURE.createInstance(), true), + new GenericManaCost(4))); + + // {tap}, Sacrifice Magma Mine: Magma Mine deals damage equal to the number of pressure counters on it to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(new CountersCount(CounterType.PRESSURE)), new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public MagmaMine(final MagmaMine card) { + super(card); + } + + @Override + public MagmaMine copy() { + return new MagmaMine(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/RainbowEfreet.java b/Mage.Sets/src/mage/sets/visions/RainbowEfreet.java new file mode 100644 index 00000000000..654cb7b4e1a --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/RainbowEfreet.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PhaseOutSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class RainbowEfreet extends CardImpl { + + public RainbowEfreet(UUID ownerId) { + super(ownerId, 41, "Rainbow Efreet", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Efreet"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // {U}{U}: Rainbow Efreet phases out. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PhaseOutSourceEffect(), new ManaCostsImpl("{U}{U}"))); + } + + public RainbowEfreet(final RainbowEfreet card) { + super(card); + } + + @Override + public RainbowEfreet copy() { + return new RainbowEfreet(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/RighteousAura.java b/Mage.Sets/src/mage/sets/visions/RighteousAura.java new file mode 100644 index 00000000000..fd13176fe8b --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/RighteousAura.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.PayLifeCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventNextDamageFromChosenSourceToYouEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author anonymous + */ +public class RighteousAura extends CardImpl { + + public RighteousAura(UUID ownerId) { + super(ownerId, 120, "Righteous Aura", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + this.expansionSetCode = "VIS"; + + // {W}, Pay 2 life: The next time a source of your choice would deal damage to you this turn, prevent that damage. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventNextDamageFromChosenSourceToYouEffect(Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addCost(new PayLifeCost(2)); + this.addAbility(ability); + } + + public RighteousAura(final RighteousAura card) { + super(card); + } + + @Override + public RighteousAura copy() { + return new RighteousAura(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/Simoon.java b/Mage.Sets/src/mage/sets/visions/Simoon.java new file mode 100644 index 00000000000..e0cac5096b1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/Simoon.java @@ -0,0 +1,100 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.List; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.permanent.ControllerIdPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class Simoon extends CardImpl { + + public Simoon(UUID ownerId) { + super(ownerId, 136, "Simoon", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{R}{G}"); + this.expansionSetCode = "VIS"; + + // Simoon deals 1 damage to each creature target opponent controls. + this.getSpellAbility().addEffect(new SimoonEffect()); + this.getSpellAbility().addTarget(new TargetOpponent()); + } + + public Simoon(final Simoon card) { + super(card); + } + + @Override + public Simoon copy() { + return new Simoon(this); + } +} + +class SimoonEffect extends OneShotEffect { + + public SimoonEffect() { + super(Outcome.Damage); + this.staticText = "{this} deals 1 damage to each creature target opponent controls"; + } + + public SimoonEffect(final SimoonEffect effect) { + super(effect); + } + + @Override + public SimoonEffect copy() { + return new SimoonEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getFirstTarget()); + if (player != null) { + FilterCreaturePermanent filter = new FilterCreaturePermanent(); + filter.add(new ControllerIdPredicate(player.getId())); + List creatures = game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game); + for (Permanent creature : creatures) { + creature.damage(1, source.getSourceId(), game, false, true); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/visions/TarPitWarrior.java b/Mage.Sets/src/mage/sets/visions/TarPitWarrior.java new file mode 100644 index 00000000000..f6212d37c3c --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/TarPitWarrior.java @@ -0,0 +1,64 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BecomesTargetTriggeredAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class TarPitWarrior extends CardImpl { + + public TarPitWarrior(UUID ownerId) { + super(ownerId, 20, "Tar Pit Warrior", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Cyclops"); + this.subtype.add("Warrior"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // When Tar Pit Warrior becomes the target of a spell or ability, sacrifice it. + this.addAbility(new BecomesTargetTriggeredAbility(new SacrificeSourceEffect())); + } + + public TarPitWarrior(final TarPitWarrior card) { + super(card); + } + + @Override + public TarPitWarrior copy() { + return new TarPitWarrior(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/TeferisHonorGuard.java b/Mage.Sets/src/mage/sets/visions/TeferisHonorGuard.java new file mode 100644 index 00000000000..8b8d79bf05d --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/TeferisHonorGuard.java @@ -0,0 +1,70 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PhaseOutSourceEffect; +import mage.abilities.keyword.FlankingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class TeferisHonorGuard extends CardImpl { + + public TeferisHonorGuard(UUID ownerId) { + super(ownerId, 122, "Teferi's Honor Guard", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "VIS"; + this.subtype.add("Human"); + this.subtype.add("Knight"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flanking + this.addAbility(new FlankingAbility()); + + // {U}{U}: Teferi's Honor Guard phases out. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new PhaseOutSourceEffect(), new ManaCostsImpl("{U}{U}"))); + } + + public TeferisHonorGuard(final TeferisHonorGuard card) { + super(card); + } + + @Override + public TeferisHonorGuard copy() { + return new TeferisHonorGuard(this); + } +} diff --git a/Mage.Sets/src/mage/sets/visions/TeferisRealm.java b/Mage.Sets/src/mage/sets/visions/TeferisRealm.java index 9664f0e51d0..d66cc24eace 100644 --- a/Mage.Sets/src/mage/sets/visions/TeferisRealm.java +++ b/Mage.Sets/src/mage/sets/visions/TeferisRealm.java @@ -74,49 +74,51 @@ public class TeferisRealm extends CardImpl { } class TeferisRealmEffect extends OneShotEffect { - + private static final String ARTIFACT = "Artifact"; private static final String CREATURE = "Creature"; private static final String LAND = "Land"; - private static final String NON_AURA_ENCHANTMENT = "Non-Aura enchantment"; + private static final String NON_AURA_ENCHANTMENT = "Non-Aura enchantment"; private static final HashSet choices = new HashSet<>(); - static{ + + static { choices.add(ARTIFACT); choices.add(CREATURE); choices.add(LAND); - choices.add(NON_AURA_ENCHANTMENT); - } - + choices.add(NON_AURA_ENCHANTMENT); + } + public TeferisRealmEffect() { super(Outcome.Detriment); this.staticText = "that player chooses artifact, creature, land, or non-Aura enchantment. All nontoken permanents of that type phase out"; } - + public TeferisRealmEffect(final TeferisRealmEffect effect) { super(effect); } - + @Override public TeferisRealmEffect copy() { return new TeferisRealmEffect(this); } - + @Override public boolean apply(Game game, Ability source) { Player player = game.getPlayer(getTargetPointer().getFirst(game, source)); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + if (player != null && controller != null) { Choice choiceImpl = new ChoiceImpl(true); choiceImpl.setMessage("Phase out which kind of permanents?"); choiceImpl.setChoices(choices); - while(!player.choose(outcome, choiceImpl, game)) { - if (player.isInGame()) { + while (!player.choose(outcome, choiceImpl, game)) { + if (player.canRespond()) { return false; } } String choosenType = choiceImpl.getChoice(); FilterPermanent filter = new FilterPermanent(); filter.add(Predicates.not(new TokenPredicate())); - switch(choosenType) { + switch (choosenType) { case ARTIFACT: filter.add(new CardTypePredicate(CardType.ARTIFACT)); break; @@ -133,11 +135,11 @@ class TeferisRealmEffect extends OneShotEffect { default: return false; } - game.informPlayers(player.getLogName() + " chooses " + choosenType +"s to phase out"); - for(Permanent permanent: game.getBattlefield().getAllActivePermanents(filter, player.getId(), game)) { + game.informPlayers(player.getLogName() + " chooses " + choosenType + "s to phase out"); + for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, controller.getId(), game)) { permanent.phaseOut(game); } - return true; + return true; } return false; } diff --git a/Mage.Sets/src/mage/sets/visions/Undo.java b/Mage.Sets/src/mage/sets/visions/Undo.java new file mode 100644 index 00000000000..9addffe6d72 --- /dev/null +++ b/Mage.Sets/src/mage/sets/visions/Undo.java @@ -0,0 +1,54 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.visions; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class Undo extends mage.sets.starter1999.Undo { + + public Undo(UUID ownerId) { + super(ownerId); + this.cardNumber = 47; + this.expansionSetCode = "VIS"; + this.rarity = Rarity.COMMON; + } + + public Undo(final Undo card) { + super(card); + } + + @Override + public Undo copy() { + return new Undo(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/Abeyance.java b/Mage.Sets/src/mage/sets/weatherlight/Abeyance.java new file mode 100644 index 00000000000..fe3b4d4f6e4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/Abeyance.java @@ -0,0 +1,121 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.mana.ManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.target.TargetPlayer; + +/** + * + * @author fireshoes + */ +public class Abeyance extends CardImpl { + + public Abeyance(UUID ownerId) { + super(ownerId, 117, "Abeyance", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{1}{W}"); + this.expansionSetCode = "WTH"; + + // Until end of turn, target player can't cast instant or sorcery spells, and that player can't activate abilities that aren't mana abilities. + this.getSpellAbility().addEffect(new AbeyanceEffect()); + this.getSpellAbility().addTarget(new TargetPlayer()); + + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public Abeyance(final Abeyance card) { + super(card); + } + + @Override + public Abeyance copy() { + return new Abeyance(this); + } +} + +class AbeyanceEffect extends ContinuousRuleModifyingEffectImpl { + + public AbeyanceEffect() { + super(Duration.EndOfTurn, Outcome.Detriment); + staticText = "Until end of turn, target player can't cast instant or sorcery spells, and that player can't activate abilities that aren't mana abilities"; + } + + public AbeyanceEffect(final AbeyanceEffect effect) { + super(effect); + } + + @Override + public AbeyanceEffect copy() { + return new AbeyanceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + return true; + } + + @Override + public String getInfoMessage(Ability source, GameEvent event, Game game) { + MageObject mageObject = game.getObject(source.getSourceId()); + if (mageObject != null) { + return "You can't cast instant or sorcery spells or activate abilities that aren't mana abilities this turn (" + mageObject.getLogName() + ")."; + } + return null; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getPlayerId().equals(source.getFirstTarget())) { + MageObject object = game.getObject(event.getSourceId()); + if (event.getType() == GameEvent.EventType.CAST_SPELL) { + if (object.getCardType().contains(CardType.INSTANT) || object.getCardType().contains(CardType.SORCERY)) { + return true; + } + } + if (event.getType() == GameEvent.EventType.ACTIVATE_ABILITY) { + Ability ability = game.getAbility(event.getTargetId(), event.getSourceId()); + if (ability != null && !(ability instanceof ManaAbility)) { + return true; + } + } + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/Alms.java b/Mage.Sets/src/mage/sets/weatherlight/Alms.java new file mode 100644 index 00000000000..d9f4aaf5416 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/Alms.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.ExileTopCardOfGraveyardCost; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Alms extends CardImpl { + + public Alms(UUID ownerId) { + super(ownerId, 119, "Alms", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}"); + this.expansionSetCode = "WTH"; + + // {1}, Exile the top card of your graveyard: Prevent the next 1 damage that would be dealt to target creature this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 1), new GenericManaCost(1)); + ability.addCost(new ExileTopCardOfGraveyardCost(1)); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public Alms(final Alms card) { + super(card); + } + + @Override + public Alms copy() { + return new Alms(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/BarrowGhoul.java b/Mage.Sets/src/mage/sets/weatherlight/BarrowGhoul.java new file mode 100644 index 00000000000..24451a04e2a --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/BarrowGhoul.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.costs.common.ExileTopCreatureCardOfGraveyardCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; + +/** + * + * @author fireshoes + */ +public class BarrowGhoul extends CardImpl { + + public BarrowGhoul(UUID ownerId) { + super(ownerId, 3, "Barrow Ghoul", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Zombie"); + this.power = new MageInt(4); + this.toughness = new MageInt(4); + + // At the beginning of your upkeep, sacrifice Barrow Ghoul unless you exile the top creature card of your graveyard. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new ExileTopCreatureCardOfGraveyardCost(1)), TargetController.YOU, false)); + } + + public BarrowGhoul(final BarrowGhoul card) { + super(card); + } + + @Override + public BarrowGhoul copy() { + return new BarrowGhoul(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/CinderGiant.java b/Mage.Sets/src/mage/sets/weatherlight/CinderGiant.java new file mode 100644 index 00000000000..574899c6fcd --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/CinderGiant.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.effects.common.DamageAllEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.predicate.permanent.AnotherPredicate; + +/** + * + * @author fireshoes + */ +public class CinderGiant extends CardImpl { + + private static final FilterControlledCreaturePermanent filter = new FilterControlledCreaturePermanent("each other creature you control"); + static { + filter.add(new AnotherPredicate()); + } + + public CinderGiant(UUID ownerId) { + super(ownerId, 93, "Cinder Giant", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Giant"); + this.power = new MageInt(5); + this.toughness = new MageInt(3); + + // At the beginning of your upkeep, Cinder Giant deals 2 damage to each other creature you control. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new DamageAllEffect(2, filter), TargetController.YOU, false)); + } + + public CinderGiant(final CinderGiant card) { + super(card); + } + + @Override + public CinderGiant copy() { + return new CinderGiant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/Doomsday.java b/Mage.Sets/src/mage/sets/weatherlight/Doomsday.java index 518336e86b3..201d7196b68 100644 --- a/Mage.Sets/src/mage/sets/weatherlight/Doomsday.java +++ b/Mage.Sets/src/mage/sets/weatherlight/Doomsday.java @@ -115,7 +115,7 @@ class DoomsdayEffect extends OneShotEffect { } //Put the chosen cards on top of your library in any order target = new TargetCard(Zone.PICK, new FilterCard("Card to put on top")); - while (cards.size() > 1 && player.isInGame()) { + while (cards.size() > 1 && player.canRespond()) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/weatherlight/Downdraft.java b/Mage.Sets/src/mage/sets/weatherlight/Downdraft.java new file mode 100644 index 00000000000..0ec3c65aaf9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/Downdraft.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageAllEffect; +import mage.abilities.effects.common.continuous.LoseAbilityTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.AbilityPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class Downdraft extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying"); + + static { + filter.add(new AbilityPredicate(FlyingAbility.class)); + } + + public Downdraft(UUID ownerId) { + super(ownerId, 67, "Downdraft", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{G}"); + this.expansionSetCode = "WTH"; + + // {G}: Target creature loses flying until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, + new LoseAbilityTargetEffect(FlyingAbility.getInstance(), Duration.EndOfTurn), + new ManaCostsImpl("{G}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + // Sacrifice Downdraft: Downdraft deals 2 damage to each creature with flying. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageAllEffect(2, filter), new SacrificeSourceCost())); + } + + public Downdraft(final Downdraft card) { + super(card); + } + + @Override + public Downdraft copy() { + return new Downdraft(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/DwarvenThaumaturgist.java b/Mage.Sets/src/mage/sets/weatherlight/DwarvenThaumaturgist.java new file mode 100644 index 00000000000..7eb2a3b3855 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/DwarvenThaumaturgist.java @@ -0,0 +1,71 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.continuous.SwitchPowerToughnessTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class DwarvenThaumaturgist extends CardImpl { + + public DwarvenThaumaturgist(UUID ownerId) { + super(ownerId, 98, "Dwarven Thaumaturgist", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Dwarf"); + this.subtype.add("Shaman"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {tap}: Switch target creature's power and toughness until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new SwitchPowerToughnessTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public DwarvenThaumaturgist(final DwarvenThaumaturgist card) { + super(card); + } + + @Override + public DwarvenThaumaturgist copy() { + return new DwarvenThaumaturgist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/LotusVale.java b/Mage.Sets/src/mage/sets/weatherlight/LotusVale.java index 9183f46d57c..dd7447e37ef 100644 --- a/Mage.Sets/src/mage/sets/weatherlight/LotusVale.java +++ b/Mage.Sets/src/mage/sets/weatherlight/LotusVale.java @@ -30,8 +30,10 @@ package mage.sets.weatherlight; import java.util.UUID; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.AddManaOfAnyColorEffect; import mage.abilities.effects.common.EnterBattlefieldPayCostOrPutGraveyardEffect; -import mage.abilities.mana.AnyColorManaAbility; +import mage.abilities.mana.SimpleManaAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Rarity; @@ -43,11 +45,12 @@ import mage.target.common.TargetControlledPermanent; /** * - * @author anonymous + * @author Luna Skyrise */ public class LotusVale extends CardImpl { - + private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("two untapped lands"); + static { filter.add(Predicates.not(new TappedPredicate())); } @@ -57,10 +60,11 @@ public class LotusVale extends CardImpl { this.expansionSetCode = "WTH"; // If Lotus Vale would enter the battlefield, sacrifice two untapped lands instead. If you do, put Lotus Vale onto the battlefield. If you don't, put it into its owner's graveyard. - this.addAbility(new SimpleStaticAbility(Zone.ALL, new EnterBattlefieldPayCostOrPutGraveyardEffect(new SacrificeTargetCost(new TargetControlledPermanent(2, 2, filter, false))))); + this.addAbility(new SimpleStaticAbility(Zone.ALL, new EnterBattlefieldPayCostOrPutGraveyardEffect( + new SacrificeTargetCost(new TargetControlledPermanent(2, 2, filter, false))))); // {tap}: Add three mana of any one color to your mana pool. - this.addAbility(new AnyColorManaAbility()); + this.addAbility(new SimpleManaAbility(Zone.BATTLEFIELD, new AddManaOfAnyColorEffect(3), new TapSourceCost())); } public LotusVale(final LotusVale card) { diff --git a/Mage.Sets/src/mage/sets/weatherlight/MantaRay.java b/Mage.Sets/src/mage/sets/weatherlight/MantaRay.java new file mode 100644 index 00000000000..8a649c14744 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/MantaRay.java @@ -0,0 +1,90 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.ControlsPermanentsControllerTriggeredAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.SacrificeSourceEffect; +import mage.abilities.effects.common.combat.CantAttackUnlessDefenderControllsPermanent; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.common.FilterLandPermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; + +/** + * + * @author fireshoes + */ +public class MantaRay extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("except by blue creatures"); + + static { + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLUE))); + } + + public MantaRay(UUID ownerId) { + super(ownerId, 42, "Manta Ray", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Fish"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // Manta Ray can't attack unless defending player controls an Island. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantAttackUnlessDefenderControllsPermanent(new FilterLandPermanent("Island", "an Island")))); + + // Manta Ray can't be blocked except by blue creatures. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + + // When you control no Islands, sacrifice Manta Ray. + this.addAbility(new ControlsPermanentsControllerTriggeredAbility( + new FilterLandPermanent("Island", "no Islands"), Filter.ComparisonType.Equal, 0, + new SacrificeSourceEffect())); + + } + + public MantaRay(final MantaRay card) { + super(card); + } + + @Override + public MantaRay copy() { + return new MantaRay(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/NaturesKiss.java b/Mage.Sets/src/mage/sets/weatherlight/NaturesKiss.java new file mode 100644 index 00000000000..abf514ddc89 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/NaturesKiss.java @@ -0,0 +1,78 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.ExileTopCardOfGraveyardCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class NaturesKiss extends CardImpl { + + public NaturesKiss(UUID ownerId) { + super(ownerId, 78, "Nature's Kiss", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + this.addAbility(new EnchantAbility(auraTarget.getTargetName())); + + // {1}, Exile the top card of your graveyard: Enchanted creature gets +1/+1 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.EndOfTurn), new ManaCostsImpl("{1}")); + ability.addCost(new ExileTopCardOfGraveyardCost(1)); + this.addAbility(ability); + } + + public NaturesKiss(final NaturesKiss card) { + super(card); + } + + @Override + public NaturesKiss copy() { + return new NaturesKiss(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/Necratog.java b/Mage.Sets/src/mage/sets/weatherlight/Necratog.java new file mode 100644 index 00000000000..24dbc5189d4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/Necratog.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.ExileTopCreatureCardOfGraveyardCost; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class Necratog extends CardImpl { + + public Necratog(UUID ownerId) { + super(ownerId, 18, "Necratog", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{B}{B}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Atog"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // Exile the top creature card of your graveyard: Necratog gets +2/+2 until end of turn. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostSourceEffect(2, 2, Duration.EndOfTurn), new ExileTopCreatureCardOfGraveyardCost(1))); + } + + public Necratog(final Necratog card) { + super(card); + } + + @Override + public Necratog copy() { + return new Necratog(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/weatherlight/PhyrexianFurnace.java b/Mage.Sets/src/mage/sets/weatherlight/PhyrexianFurnace.java new file mode 100644 index 00000000000..3c324921697 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/PhyrexianFurnace.java @@ -0,0 +1,113 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.ExileTargetEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetPlayer; +import mage.target.common.TargetCardInGraveyard; + +/** + * + * @author fireshoes + */ +public class PhyrexianFurnace extends CardImpl { + + public PhyrexianFurnace(UUID ownerId) { + super(ownerId, 155, "Phyrexian Furnace", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{1}"); + this.expansionSetCode = "WTH"; + + // {tap}: Exile the bottom card of target player's graveyard. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PhyrexianFurnaceEffect(), new TapSourceCost()); + ability.addTarget(new TargetPlayer()); + this.addAbility(ability); + + // {1}, Sacrifice Phyrexian Furnace: Exile target card from a graveyard. Draw a card. + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ExileTargetEffect(), new ManaCostsImpl("{1}")); + ability.addTarget(new TargetCardInGraveyard()); + ability.addEffect(new DrawCardSourceControllerEffect(1)); + this.addAbility(ability); + } + + public PhyrexianFurnace(final PhyrexianFurnace card) { + super(card); + } + + @Override + public PhyrexianFurnace copy() { + return new PhyrexianFurnace(this); + } +} + +class PhyrexianFurnaceEffect extends OneShotEffect { + + public PhyrexianFurnaceEffect() { + super(Outcome.Benefit); + this.staticText = "exile the bottom card of target player's graveyard"; + } + + public PhyrexianFurnaceEffect(final PhyrexianFurnaceEffect effect) { + super(effect); + } + + @Override + public PhyrexianFurnaceEffect copy() { + return new PhyrexianFurnaceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getFirstTarget()); + if (player != null) { + Card bottomCard = null; + for (Card card :player.getGraveyard().getCards(game)) { + bottomCard = card; + break; + } + if (bottomCard != null) { + return player.moveCardToExileWithInfo(bottomCard, null, "", source.getSourceId(), game, Zone.GRAVEYARD, true); + } + return true; + } + return false; + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/weatherlight/PsychicVortex.java b/Mage.Sets/src/mage/sets/weatherlight/PsychicVortex.java new file mode 100644 index 00000000000..b829bd3c80d --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/PsychicVortex.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.costs.CostImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.effects.common.discard.DiscardHandControllerEffect; +import mage.abilities.keyword.CumulativeUpkeepAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterControlledLandPermanent; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class PsychicVortex extends CardImpl { + + public PsychicVortex(UUID ownerId) { + super(ownerId, 50, "Psychic Vortex", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}{U}"); + this.expansionSetCode = "WTH"; + + // Cumulative upkeep-Draw a card. + this.addAbility(new CumulativeUpkeepAbility(new PsychicVortexCost())); + + // At the beginning of your end step, sacrifice a land and discard your hand. + Effect effect = new SacrificeTargetEffect(); + effect.setText("sacrifice a land"); + Ability ability = new BeginningOfEndStepTriggeredAbility(effect, TargetController.YOU, false); + effect = new DiscardHandControllerEffect(); + effect.setText("and discard your hand"); + ability.addEffect(effect); + ability.addTarget(new TargetControlledPermanent(new FilterControlledLandPermanent())); + this.addAbility(ability); + } + + public PsychicVortex(final PsychicVortex card) { + super(card); + } + + @Override + public PsychicVortex copy() { + return new PsychicVortex(this); + } +} + +class PsychicVortexCost extends CostImpl { + + PsychicVortexCost() { + this.text = "Draw a card."; + } + + @Override + public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { + Player controller = game.getPlayer(controllerId); + if (controller != null) { + controller.drawCards(1, game); + this.paid = true; + return true; + } + return false; + } + + @Override + public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { + Player controller = game.getPlayer(controllerId); + return controller.getLibrary().size() > 0; + } + + @Override + public PsychicVortexCost copy() { + return new PsychicVortexCost(); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/weatherlight/RogueElephant.java b/Mage.Sets/src/mage/sets/weatherlight/RogueElephant.java new file mode 100644 index 00000000000..be79f2afd4e --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/RogueElephant.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledLandPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; +import mage.target.common.TargetControlledPermanent; + +/** + * + * @author fireshoes + */ +public class RogueElephant extends CardImpl { + + private static final FilterControlledLandPermanent filter = new FilterControlledLandPermanent("a Forest"); + + static{ + filter.add(new SubtypePredicate("Forest")); + } + + public RogueElephant(UUID ownerId) { + super(ownerId, 81, "Rogue Elephant", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{G}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Elephant"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Rogue Elephant enters the battlefield, sacrifice it unless you sacrifice a Forest. + this.addAbility(new EntersBattlefieldTriggeredAbility(new SacrificeSourceUnlessPaysEffect(new SacrificeTargetCost(new TargetControlledPermanent(filter))))); + } + + public RogueElephant(final RogueElephant card) { + super(card); + } + + @Override + public RogueElephant copy() { + return new RogueElephant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/TendrilsOfDespair.java b/Mage.Sets/src/mage/sets/weatherlight/TendrilsOfDespair.java new file mode 100644 index 00000000000..0e04d0c179b --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/TendrilsOfDespair.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.discard.DiscardTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class TendrilsOfDespair extends CardImpl { + + public TendrilsOfDespair(UUID ownerId) { + super(ownerId, 25, "Tendrils of Despair", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{B}"); + this.expansionSetCode = "WTH"; + + // As an additional cost to cast Tendrils of Despair, sacrifice a creature. + this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent())); + + // Target opponent discards two cards. + this.getSpellAbility().addTarget(new TargetOpponent()); + this.getSpellAbility().addEffect(new DiscardTargetEffect(2)); + } + + public TendrilsOfDespair(final TendrilsOfDespair card) { + super(card); + } + + @Override + public TendrilsOfDespair copy() { + return new TendrilsOfDespair(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/Thundermare.java b/Mage.Sets/src/mage/sets/weatherlight/Thundermare.java new file mode 100644 index 00000000000..6a8f1b8be50 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/Thundermare.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Thundermare extends mage.sets.portal.Thundermare { + + public Thundermare(UUID ownerId) { + super(ownerId); + this.cardNumber = 116; + this.expansionSetCode = "WTH"; + } + + public Thundermare(final Thundermare card) { + super(card); + } + + @Override + public Thundermare copy() { + return new Thundermare(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/TolarianSerpent.java b/Mage.Sets/src/mage/sets/weatherlight/TolarianSerpent.java new file mode 100644 index 00000000000..5446010fb4b --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/TolarianSerpent.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.OnEventTriggeredAbility; +import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.events.GameEvent.EventType; + +/** + * + * @author fireshoes + */ +public class TolarianSerpent extends CardImpl { + + public TolarianSerpent(UUID ownerId) { + super(ownerId, 57, "Tolarian Serpent", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{5}{U}{U}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Serpent"); + this.power = new MageInt(7); + this.toughness = new MageInt(7); + + // At the beginning of your upkeep, put the top seven cards of your library into your graveyard. + this.addAbility(new OnEventTriggeredAbility(EventType.UPKEEP_STEP_PRE, + "beginning of your upkeep", + new PutTopCardOfLibraryIntoGraveControllerEffect(7), false)); + } + + public TolarianSerpent(final TolarianSerpent card) { + super(card); + } + + @Override + public TolarianSerpent copy() { + return new TolarianSerpent(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/UrborgJustice.java b/Mage.Sets/src/mage/sets/weatherlight/UrborgJustice.java new file mode 100644 index 00000000000..03384120f2b --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/UrborgJustice.java @@ -0,0 +1,113 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.Set; +import java.util.UUID; + +import mage.MageObjectReference; +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.SacrificeEffect; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetOpponent; +import mage.watchers.common.CardsPutIntoGraveyardWatcher; + +/** + * + * @author andyfries + */ +public class UrborgJustice extends CardImpl { + + public UrborgJustice(UUID ownerId) { + super(ownerId, 26, "Urborg Justice", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{B}{B}"); + this.expansionSetCode = "WTH"; + + // Target opponent sacrifices a creature for each creature put into your graveyard from the battlefield this turn. + this.getSpellAbility().addWatcher(new CardsPutIntoGraveyardWatcher()); + SacrificeEffect sacrificeEffect = new SacrificeEffect(new FilterCreaturePermanent(), new UrborgJusticeDynamicValue(), ""); + sacrificeEffect.setText("Target opponent sacrifices a creature for each creature put into your graveyard from the battlefield this turn"); + + this.getSpellAbility().addEffect(sacrificeEffect); + this.getSpellAbility().addTarget(new TargetOpponent()); + } + + public UrborgJustice(final UrborgJustice card) { + super(card); + } + + @Override + public UrborgJustice copy() { + return new UrborgJustice(this); + } +} + +class UrborgJusticeDynamicValue implements DynamicValue { + + @Override + public UrborgJusticeDynamicValue copy() { + return new UrborgJusticeDynamicValue(); + } + + @Override + public String toString() { + return "1"; + } + + @Override + public String getMessage() { + return "creature put into your graveyard from the battlefield this turn"; + } + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + CardsPutIntoGraveyardWatcher watcher = (CardsPutIntoGraveyardWatcher) game.getState().getWatchers().get("CardsPutIntoGraveyardWatcher"); + + int count = 0; + Player controller = game.getPlayer(sourceAbility.getControllerId()); + if (controller != null && watcher != null) { + Set cardsInGraveyard = watcher.getCardsPutToGraveyardFromBattlefield(); + for (MageObjectReference mor : cardsInGraveyard) { + if (game.getState().getZoneChangeCounter(mor.getSourceId()) == mor.getZoneChangeCounter()) { + Card card = game.getCard(mor.getSourceId()); + if (card != null && card.getOwnerId().equals(sourceAbility.getControllerId()) && card.getCardType().contains(CardType.CREATURE)) { + count++; + } + } + } + } + return count; + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/VodalianIllusionist.java b/Mage.Sets/src/mage/sets/weatherlight/VodalianIllusionist.java new file mode 100644 index 00000000000..8684a6b2bdf --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/VodalianIllusionist.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PhaseOutTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class VodalianIllusionist extends CardImpl { + + public VodalianIllusionist(UUID ownerId) { + super(ownerId, 58, "Vodalian Illusionist", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {U}{U}, {tap}: Target creature phases out. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PhaseOutTargetEffect(), new ManaCostsImpl("{U}{U}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public VodalianIllusionist(final VodalianIllusionist card) { + super(card); + } + + @Override + public VodalianIllusionist copy() { + return new VodalianIllusionist(this); + } +} diff --git a/Mage.Sets/src/mage/sets/weatherlight/ZombieScavengers.java b/Mage.Sets/src/mage/sets/weatherlight/ZombieScavengers.java new file mode 100644 index 00000000000..126280485b5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/weatherlight/ZombieScavengers.java @@ -0,0 +1,65 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.weatherlight; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.ExileTopCreatureCardOfGraveyardCost; +import mage.abilities.effects.common.RegenerateSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author fireshoes + */ +public class ZombieScavengers extends CardImpl { + + public ZombieScavengers(UUID ownerId) { + super(ownerId, 29, "Zombie Scavengers", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "WTH"; + this.subtype.add("Zombie"); + this.power = new MageInt(3); + this.toughness = new MageInt(1); + + // Exile the top creature card of your graveyard: Regenerate Zombie Scavengers. + this.addAbility(new SimpleActivatedAbility(Zone.BATTLEFIELD, new RegenerateSourceEffect(), new ExileTopCreatureCardOfGraveyardCost(1))); + } + + public ZombieScavengers(final ZombieScavengers card) { + super(card); + } + + @Override + public ZombieScavengers copy() { + return new ZombieScavengers(this); + } +} diff --git a/Mage.Sets/src/mage/sets/worldwake/CanopyCover.java b/Mage.Sets/src/mage/sets/worldwake/CanopyCover.java index ca6ca52f355..71c8ff7ec97 100644 --- a/Mage.Sets/src/mage/sets/worldwake/CanopyCover.java +++ b/Mage.Sets/src/mage/sets/worldwake/CanopyCover.java @@ -28,12 +28,6 @@ package mage.sets.worldwake; import java.util.UUID; -import mage.constants.AttachmentType; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.RestrictionEffect; @@ -43,33 +37,32 @@ import mage.abilities.keyword.EnchantAbility; import mage.abilities.keyword.FlyingAbility; import mage.abilities.keyword.ReachAbility; import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.FilterObject; import mage.filter.FilterStackObject; -import mage.filter.predicate.permanent.ControllerPredicate; import mage.game.Game; import mage.game.permanent.Permanent; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; - - /** * @author noxx */ public class CanopyCover extends CardImpl { - private static final FilterStackObject filter = new FilterStackObject("spells or abilities your opponents control"); + private static final FilterObject filter = new FilterStackObject("spells or abilities your opponents control"); - static { - filter.add(new ControllerPredicate(TargetController.OPPONENT)); - } - public CanopyCover(UUID ownerId) { super(ownerId, 98, "Canopy Cover", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); this.expansionSetCode = "WWK"; this.subtype.add("Aura"); - // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); @@ -81,7 +74,7 @@ public class CanopyCover extends CardImpl { this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new OrchardSpiritEffect())); // Enchanted creature can't be the target of spells or abilities your opponents control. - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeTargetedAttachedEffect(filter, Duration.WhileOnBattlefield, AttachmentType.AURA))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new CantBeTargetedAttachedEffect(filter, Duration.WhileOnBattlefield, AttachmentType.AURA, TargetController.OPPONENT))); } public CanopyCover(final CanopyCover card) { diff --git a/Mage.Sets/src/mage/sets/worldwake/DeadReckoning.java b/Mage.Sets/src/mage/sets/worldwake/DeadReckoning.java index fcae572f925..9f4235be957 100644 --- a/Mage.Sets/src/mage/sets/worldwake/DeadReckoning.java +++ b/Mage.Sets/src/mage/sets/worldwake/DeadReckoning.java @@ -28,14 +28,13 @@ package mage.sets.worldwake; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.game.Game; @@ -54,7 +53,6 @@ public class DeadReckoning extends CardImpl { super(ownerId, 56, "Dead Reckoning", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{1}{B}{B}"); this.expansionSetCode = "WWK"; - // You may put target creature card from your graveyard on top of your library. If you do, Dead Reckoning deals damage equal to that card's power to target creature. this.getSpellAbility().addEffect(new DeadReckoningEffect()); @@ -103,7 +101,7 @@ class DeadReckoningEffect extends OneShotEffect { int power = creatureInGraveyard.getPower().getValue(); Permanent creature = game.getPermanent(target2.getFirstTarget()); if (creature != null) { - creature.damage(power, id, game, true, true); + creature.damage(power, source.getSourceId(), game, true, true); return true; } } diff --git a/Mage.Sets/src/mage/sets/worldwake/DeathforgeShaman.java b/Mage.Sets/src/mage/sets/worldwake/DeathforgeShaman.java index e2fd72a1fac..74cf754a08d 100644 --- a/Mage.Sets/src/mage/sets/worldwake/DeathforgeShaman.java +++ b/Mage.Sets/src/mage/sets/worldwake/DeathforgeShaman.java @@ -27,6 +27,7 @@ */ package mage.sets.worldwake; +import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTriggeredAbility; @@ -42,8 +43,6 @@ import mage.game.Game; import mage.players.Player; import mage.target.TargetPlayer; -import java.util.UUID; - /** * * @author jeffwadsworth @@ -61,7 +60,7 @@ public class DeathforgeShaman extends CardImpl { // Multikicker {R} this.addAbility(new MultikickerAbility("{R}")); - + // When Deathforge Shaman enters the battlefield, it deals damage to target player equal to twice the number of times it was kicked. Ability ability = new EntersBattlefieldTriggeredAbility(new DeathforgeShamanEffect()); ability.addTarget(new TargetPlayer()); @@ -101,7 +100,7 @@ class DeathforgeShamanEffect extends OneShotEffect { Player player = game.getPlayer(source.getFirstTarget()); if (player != null) { - player.damage(damage, id, game, false, true); + player.damage(damage, source.getSourceId(), game, false, true); return true; } return false; diff --git a/Mage.Sets/src/mage/sets/worldwake/Groundswell.java b/Mage.Sets/src/mage/sets/worldwake/Groundswell.java index 9598babd39e..fdcb5411d82 100644 --- a/Mage.Sets/src/mage/sets/worldwake/Groundswell.java +++ b/Mage.Sets/src/mage/sets/worldwake/Groundswell.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,24 +20,22 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.worldwake; import java.util.UUID; - +import mage.abilities.condition.common.LandfallCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.AddContinuousEffectToGame; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Rarity; -import mage.abilities.condition.LockedInCondition; -import mage.abilities.condition.common.LandfallCondition; -import mage.abilities.decorator.ConditionalContinuousEffect; -import mage.abilities.effects.common.continuous.BoostTargetEffect; -import mage.cards.CardImpl; import mage.target.common.TargetCreaturePermanent; import mage.watchers.common.LandfallWatcher; @@ -54,8 +52,10 @@ public class Groundswell extends CardImpl { // Target creature gets +2/+2 until end of turn. //Landfall - If you had a land enter the battlefield under your control this turn, that creature gets +4/+4 until end of turn instead. this.getSpellAbility().addWatcher(new LandfallWatcher()); - this.getSpellAbility().addEffect(new ConditionalContinuousEffect(new BoostTargetEffect(4, 4, Duration.EndOfTurn), new BoostTargetEffect(2, 2, Duration.EndOfTurn), - new LockedInCondition(LandfallCondition.getInstance()), + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new AddContinuousEffectToGame(new BoostTargetEffect(4, 4, Duration.EndOfTurn)), + new AddContinuousEffectToGame(new BoostTargetEffect(2, 2, Duration.EndOfTurn)), + LandfallCondition.getInstance(), "Target creature gets +2/+2 until end of turn.
Landfall — If you had a land enter the battlefield under your control this turn, that creature gets +4/44 until end of turn instead")); this.getSpellAbility().addTarget(new TargetCreaturePermanent()); } diff --git a/Mage.Sets/src/mage/sets/worldwake/ShorelineSalvager.java b/Mage.Sets/src/mage/sets/worldwake/ShorelineSalvager.java index f452d321786..765fc14cb19 100644 --- a/Mage.Sets/src/mage/sets/worldwake/ShorelineSalvager.java +++ b/Mage.Sets/src/mage/sets/worldwake/ShorelineSalvager.java @@ -28,15 +28,15 @@ package mage.sets.worldwake; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; import mage.MageInt; import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; import mage.abilities.condition.common.PermanentsOnTheBattlefieldCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; import mage.filter.FilterPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; import mage.filter.predicate.permanent.ControllerPredicate; @@ -64,7 +64,7 @@ public class ShorelineSalvager extends CardImpl { this.toughness = new MageInt(3); // Whenever Shoreline Salvager deals combat damage to a player, if you control an Island, you may draw a card. - this.addAbility(new ConditionalTriggeredAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new DrawCardSourceControllerEffect(1), true), new PermanentsOnTheBattlefieldCondition(filter), rule, true)); + this.addAbility(new ConditionalTriggeredAbility(new DealsCombatDamageToAPlayerTriggeredAbility(new DrawCardSourceControllerEffect(1), true), new PermanentsOnTheBattlefieldCondition(filter), rule)); } public ShorelineSalvager(final ShorelineSalvager card) { diff --git a/Mage.Sets/src/mage/sets/worldwake/StoneforgeMystic.java b/Mage.Sets/src/mage/sets/worldwake/StoneforgeMystic.java index 6d1f9a9bae8..3a87eb36ce0 100644 --- a/Mage.Sets/src/mage/sets/worldwake/StoneforgeMystic.java +++ b/Mage.Sets/src/mage/sets/worldwake/StoneforgeMystic.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -35,26 +35,16 @@ import mage.abilities.common.EntersBattlefieldTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.abilities.effects.common.search.SearchLibraryPutInHandEffect; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; import mage.filter.FilterCard; -import mage.filter.common.FilterArtifactCard; -import mage.filter.predicate.mageobject.CardTypePredicate; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.players.Player; -import mage.target.Target; -import mage.target.common.TargetCardInHand; import mage.target.common.TargetCardInLibrary; - - /** * * @author BetaSteward_at_googlemail.com @@ -64,7 +54,6 @@ public class StoneforgeMystic extends CardImpl { private static final FilterCard filter = new FilterCard("an Equipment card"); static { - filter.add(new CardTypePredicate(CardType.ARTIFACT)); filter.add(new SubtypePredicate("Equipment")); } @@ -82,7 +71,7 @@ public class StoneforgeMystic extends CardImpl { this.addAbility(new EntersBattlefieldTriggeredAbility(new SearchLibraryPutInHandEffect(target, true, true), true)); // {1}{W}, {T}: You may put an Equipment card from your hand onto the battlefield. - SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new StoneforgeMysticEffect(), new ManaCostsImpl("{1}{W}")); + SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PutPermanentOnBattlefieldEffect(filter), new ManaCostsImpl("{1}{W}")); ability.addCost(new TapSourceCost()); this.addAbility(ability); } @@ -97,44 +86,3 @@ public class StoneforgeMystic extends CardImpl { } } - -class StoneforgeMysticEffect extends OneShotEffect { - - private static final FilterArtifactCard filter = new FilterArtifactCard("an Equipment card from your hand"); - - static { - filter.add(new SubtypePredicate("Equipment")); - } - - public StoneforgeMysticEffect() { - super(Outcome.Benefit); - this.staticText = "You may put an Equipment card from your hand onto the battlefield"; - } - - public StoneforgeMysticEffect(final StoneforgeMysticEffect effect) { - super(effect); - } - - @Override - public StoneforgeMysticEffect copy() { - return new StoneforgeMysticEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - Target target = new TargetCardInHand(filter); - if (target.canChoose(source.getSourceId(), source.getControllerId(), game) - && controller.chooseUse(outcome, "Put an Equipment from your hand to battlefield?", source, game) - && controller.chooseTarget(outcome, target, source, game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - controller.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - } - } - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/worldwake/UrgeToFeed.java b/Mage.Sets/src/mage/sets/worldwake/UrgeToFeed.java index 63b2dd60258..ad2d8e2ba1b 100644 --- a/Mage.Sets/src/mage/sets/worldwake/UrgeToFeed.java +++ b/Mage.Sets/src/mage/sets/worldwake/UrgeToFeed.java @@ -28,15 +28,14 @@ package mage.sets.worldwake; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; import mage.constants.Duration; import mage.constants.Outcome; +import mage.constants.Rarity; import mage.constants.TargetController; import mage.counters.CounterType; import mage.filter.common.FilterCreaturePermanent; @@ -45,6 +44,7 @@ import mage.filter.predicate.mageobject.SubtypePredicate; import mage.filter.predicate.permanent.ControllerPredicate; import mage.filter.predicate.permanent.TappedPredicate; import mage.game.Game; +import mage.game.permanent.Permanent; import mage.target.common.TargetCreaturePermanent; /** @@ -59,7 +59,6 @@ public class UrgeToFeed extends CardImpl { super(ownerId, 70, "Urge to Feed", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{B}{B}"); this.expansionSetCode = "WWK"; - // Target creature gets -3/-3 until end of turn. You may tap any number of untapped Vampire creatures you control. If you do, put a +1/+1 counter on each of those Vampires. this.getSpellAbility().addEffect(new BoostTargetEffect(-3, -3, Duration.EndOfTurn)); this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); @@ -97,20 +96,17 @@ class UrgeToFeedEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - TargetCreaturePermanent target = new TargetCreaturePermanent(filter); - while (true) { - target.clearChosen(); - if (target.canChoose(source.getControllerId(), game) && target.choose(Outcome.Tap, source.getControllerId(), source.getSourceId(), game)) { - UUID vampire = target.getFirstTarget(); + TargetCreaturePermanent target = new TargetCreaturePermanent(0, Integer.MAX_VALUE, filter, true); + if (target.canChoose(source.getControllerId(), game) && target.choose(Outcome.Tap, source.getControllerId(), source.getSourceId(), game)) { + for (UUID vampireId : target.getTargets()) { + Permanent vampire = game.getPermanent(vampireId); if (vampire != null) { - game.getPermanent(vampire).tap(game); - game.getPermanent(vampire).addCounters(CounterType.P1P1.createInstance(), game); + vampire.tap(game); + vampire.addCounters(CounterType.P1P1.createInstance(), game); } - } else { - break; } } - return false; + return true; } @Override diff --git a/Mage.Sets/src/mage/sets/zendikar/BloodchiefAscension.java b/Mage.Sets/src/mage/sets/zendikar/BloodchiefAscension.java index de0290a429d..ee80fdde649 100644 --- a/Mage.Sets/src/mage/sets/zendikar/BloodchiefAscension.java +++ b/Mage.Sets/src/mage/sets/zendikar/BloodchiefAscension.java @@ -29,21 +29,21 @@ package mage.sets.zendikar; import java.util.UUID; import mage.abilities.Ability; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; -import mage.constants.Zone; import mage.abilities.common.BeginningOfEndStepTriggeredAbility; import mage.abilities.common.PutCardIntoGraveFromAnywhereAllTriggeredAbility; import mage.abilities.condition.Condition; -import mage.abilities.condition.common.SourceHasCounterCondition; import mage.abilities.condition.common.OpponentLostLifeCondition; +import mage.abilities.condition.common.SourceHasCounterCondition; import mage.abilities.decorator.ConditionalTriggeredAbility; import mage.abilities.effects.common.GainLifeEffect; import mage.abilities.effects.common.LoseLifeTargetEffect; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.SetTargetPointer; +import mage.constants.TargetController; +import mage.constants.Zone; import mage.counters.CounterType; import mage.filter.FilterCard; @@ -69,7 +69,7 @@ public class BloodchiefAscension extends CardImpl { new PutCardIntoGraveFromAnywhereAllTriggeredAbility( new LoseLifeTargetEffect(2), true, new FilterCard("a card"), TargetController.OPPONENT, SetTargetPointer.PLAYER), new SourceHasCounterCondition(CounterType.QUEST, 3), - "Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life", true); + "Whenever a card is put into an opponent's graveyard from anywhere, if {this} has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life"); ability.addEffect(new GainLifeEffect(2)); this.addAbility(ability); diff --git a/Mage.Sets/src/mage/sets/zendikar/BraveTheElements.java b/Mage.Sets/src/mage/sets/zendikar/BraveTheElements.java index e5da2306596..caf72def1f8 100644 --- a/Mage.Sets/src/mage/sets/zendikar/BraveTheElements.java +++ b/Mage.Sets/src/mage/sets/zendikar/BraveTheElements.java @@ -106,7 +106,7 @@ class BraveTheElementsChooseColorEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/zendikar/CelestialMantle.java b/Mage.Sets/src/mage/sets/zendikar/CelestialMantle.java index a4fc1945330..d6565ac388e 100644 --- a/Mage.Sets/src/mage/sets/zendikar/CelestialMantle.java +++ b/Mage.Sets/src/mage/sets/zendikar/CelestialMantle.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.zendikar; import java.util.UUID; @@ -34,7 +33,6 @@ import mage.abilities.TriggeredAbilityImpl; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.UntapAllLandsControllerEffect; import mage.abilities.effects.common.continuous.BoostEnchantedEffect; import mage.abilities.keyword.EnchantAbility; import mage.cards.CardImpl; @@ -58,22 +56,26 @@ import mage.target.common.TargetCreaturePermanent; */ public class CelestialMantle extends CardImpl { - public CelestialMantle (UUID ownerId) { + public CelestialMantle(UUID ownerId) { super(ownerId, 6, "Celestial Mantle", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{3}{W}{W}{W}"); this.expansionSetCode = "ZEN"; this.subtype.add("Aura"); - + // Enchant creature TargetPermanent auraTarget = new TargetCreaturePermanent(); this.getSpellAbility().addTarget(auraTarget); this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); Ability ability = new EnchantAbility(auraTarget.getTargetName()); this.addAbility(ability); + + // Enchanted creature gets +3/+3. this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(3, 3, Duration.WhileOnBattlefield))); + + // Whenever enchanted creature deals combat damage to a player, double its controller's life total. this.addAbility(new CelestialMantleAbility()); } - public CelestialMantle (final CelestialMantle card) { + public CelestialMantle(final CelestialMantle card) { super(card); } @@ -88,7 +90,6 @@ class CelestialMantleAbility extends TriggeredAbilityImpl { public CelestialMantleAbility() { super(Zone.BATTLEFIELD, new CelestialMantleEffect()); - this.addEffect(new UntapAllLandsControllerEffect()); } public CelestialMantleAbility(final CelestialMantleAbility ability) { @@ -107,7 +108,7 @@ class CelestialMantleAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - DamagedPlayerEvent damageEvent = (DamagedPlayerEvent)event; + DamagedPlayerEvent damageEvent = (DamagedPlayerEvent) event; Permanent p = game.getPermanent(event.getSourceId()); return damageEvent.isCombatDamage() && p != null && p.getAttachments().contains(this.getSourceId()); } @@ -119,6 +120,7 @@ class CelestialMantleAbility extends TriggeredAbilityImpl { } class CelestialMantleEffect extends OneShotEffect { + CelestialMantleEffect() { super(Outcome.GainLife); } diff --git a/Mage.Sets/src/mage/sets/zendikar/GoblinGuide.java b/Mage.Sets/src/mage/sets/zendikar/GoblinGuide.java index 8f07a34ec05..d21d96e185d 100644 --- a/Mage.Sets/src/mage/sets/zendikar/GoblinGuide.java +++ b/Mage.Sets/src/mage/sets/zendikar/GoblinGuide.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.zendikar; import java.util.UUID; @@ -108,10 +107,10 @@ class GoblinGuideTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - if (event.getSourceId().equals(this.getSourceId()) ) { + if (event.getSourceId().equals(this.getSourceId())) { UUID defenderId = game.getCombat().getDefendingPlayerId(getSourceId(), game); if (defenderId != null) { - for (Effect effect :this.getEffects()) { + for (Effect effect : this.getEffects()) { // set here because attacking creature can be removed until effect resolves effect.setTargetPointer(new FixedTarget(defenderId)); } @@ -134,8 +133,8 @@ class GoblinGuideTriggeredAbility extends TriggeredAbilityImpl { return new GoblinGuideTriggeredAbility(this); } - } + class GoblinGuideEffect extends OneShotEffect { public GoblinGuideEffect() { @@ -153,7 +152,7 @@ class GoblinGuideEffect extends OneShotEffect { } @Override - public boolean apply(Game game, Ability source) { + public boolean apply(Game game, Ability source) { Player defender = game.getPlayer(getTargetPointer().getFirst(game, source)); MageObject sourceObject = game.getObject(source.getSourceId()); if (sourceObject != null && defender != null) { @@ -163,7 +162,7 @@ class GoblinGuideEffect extends OneShotEffect { cards.add(card); defender.revealCards(sourceObject.getName(), cards, game); if (card.getCardType().contains(CardType.LAND)) { - defender.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + defender.moveCards(card, null, Zone.HAND, source, game); } } return true; @@ -171,4 +170,4 @@ class GoblinGuideEffect extends OneShotEffect { return false; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java b/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java index 1ba0cf97ec5..a05963c6ca2 100644 --- a/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java +++ b/Mage.Sets/src/mage/sets/zendikar/GuulDrazVampire.java @@ -29,6 +29,7 @@ package mage.sets.zendikar; import java.util.UUID; import mage.MageInt; +import mage.abilities.Ability; import mage.abilities.common.SimpleStaticAbility; import mage.abilities.condition.Condition; import mage.abilities.condition.common.TenOrLessLifeCondition; @@ -49,7 +50,7 @@ import mage.constants.Zone; public class GuulDrazVampire extends CardImpl { private static final String rule1 = "As long as an opponent has 10 or less life, {this} gets +2/+1"; - private static final String rule2 = "As long as an opponent has 10 or less life, {this} has intimidate"; + private static final String rule2 = "and has intimidate. (It can't be blocked except by artifact creatures and/or creatures that share a color with it.)"; public GuulDrazVampire(UUID ownerId) { super(ownerId, 93, "Guul Draz Vampire", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}"); @@ -64,9 +65,9 @@ public class GuulDrazVampire extends CardImpl { // As long as an opponent has 10 or less life, Guul Draz Vampire gets +2/+1 and has intimidate. (It can't be blocked except by artifact creatures and/or creatures that share a color with it.) Condition condition = new TenOrLessLifeCondition(TenOrLessLifeCondition.CheckType.AN_OPPONENT); ConditionalContinuousEffect effect1 = new ConditionalContinuousEffect(new BoostSourceEffect(2, 1, Duration.WhileOnBattlefield), condition, rule1); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect1)); - ConditionalContinuousEffect effect2 = new ConditionalContinuousEffect(new GainAbilitySourceEffect(IntimidateAbility.getInstance()), condition, rule2); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect2)); + Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, effect1); + ability.addEffect(new ConditionalContinuousEffect(new GainAbilitySourceEffect(IntimidateAbility.getInstance()), condition, rule2)); + this.addAbility(ability); } diff --git a/Mage.Sets/src/mage/sets/zendikar/HellfireMongrel.java b/Mage.Sets/src/mage/sets/zendikar/HellfireMongrel.java index a4a5ba090ba..00260eb4154 100644 --- a/Mage.Sets/src/mage/sets/zendikar/HellfireMongrel.java +++ b/Mage.Sets/src/mage/sets/zendikar/HellfireMongrel.java @@ -30,11 +30,9 @@ package mage.sets.zendikar; import java.util.UUID; import mage.MageInt; import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; import mage.abilities.condition.Condition; import mage.abilities.decorator.ConditionalTriggeredAbility; -import mage.abilities.effects.Effect; import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; @@ -42,9 +40,7 @@ import mage.constants.Rarity; import mage.constants.TargetController; import mage.constants.Zone; import mage.game.Game; -import mage.game.events.GameEvent; import mage.players.Player; -import mage.target.targetpointer.FixedTarget; /** * @@ -64,9 +60,9 @@ public class HellfireMongrel extends CardImpl { // At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, Hellfire Mongrel deals 2 damage to him or her. this.addAbility(new ConditionalTriggeredAbility( new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), TargetController.OPPONENT, false, true), - new CardsInActivePlayersHandCondition(), - "At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, {this} deals 2 damage to him or her.", - false)); + new CardsInActivePlayersHandCondition(), + "At the beginning of each opponent's upkeep, if that player has two or fewer cards in hand, {this} deals 2 damage to him or her." + )); } public HellfireMongrel(final HellfireMongrel card) { diff --git a/Mage.Sets/src/mage/sets/zendikar/KabiraEvangel.java b/Mage.Sets/src/mage/sets/zendikar/KabiraEvangel.java index 35c7d52e50c..b2d00f04395 100644 --- a/Mage.Sets/src/mage/sets/zendikar/KabiraEvangel.java +++ b/Mage.Sets/src/mage/sets/zendikar/KabiraEvangel.java @@ -118,7 +118,7 @@ class KabiraEvangelChooseColorEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage.Sets/src/mage/sets/zendikar/KalitasBloodchiefOfGhet.java b/Mage.Sets/src/mage/sets/zendikar/KalitasBloodchiefOfGhet.java index 3e521b30c4d..2e34253f3ee 100644 --- a/Mage.Sets/src/mage/sets/zendikar/KalitasBloodchiefOfGhet.java +++ b/Mage.Sets/src/mage/sets/zendikar/KalitasBloodchiefOfGhet.java @@ -28,10 +28,6 @@ package mage.sets.zendikar; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; @@ -40,6 +36,10 @@ import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.CreateTokenEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.game.permanent.token.Token; @@ -53,16 +53,16 @@ public class KalitasBloodchiefOfGhet extends CardImpl { public KalitasBloodchiefOfGhet(UUID ownerId) { super(ownerId, 99, "Kalitas, Bloodchief of Ghet", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{5}{B}{B}"); + this.supertype.add("Legendary"); this.expansionSetCode = "ZEN"; this.subtype.add("Vampire"); this.subtype.add("Warrior"); - this.power = new MageInt(5); - this.toughness = new MageInt(5); - // {B}{B}{B}, {T}: Destroy target creature. If that creature dies this way, put a black Vampire creature token onto the battlefield. Its power is equal to that creature's power and its toughness is equal to that creature's toughness. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new KalitasDestroyEffect(), new ManaCostsImpl("{B}{B}{B}")); ability.addCost(new TapSourceCost()); + this.power = new MageInt(5); + this.toughness = new MageInt(5); ability.addTarget(new TargetCreaturePermanent()); this.addAbility(ability); } @@ -114,4 +114,4 @@ class VampireToken extends Token { toughness = new MageInt(tokenToughness); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/zendikar/LavaballTrap.java b/Mage.Sets/src/mage/sets/zendikar/LavaballTrap.java index 0c9f4be3efe..058b40ffe23 100644 --- a/Mage.Sets/src/mage/sets/zendikar/LavaballTrap.java +++ b/Mage.Sets/src/mage/sets/zendikar/LavaballTrap.java @@ -30,9 +30,6 @@ package mage.sets.zendikar; import java.util.HashMap; import java.util.Map; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.costs.AlternativeCostImpl; import mage.abilities.costs.Cost; @@ -40,8 +37,11 @@ import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.DamageAllEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.WatcherScope; import mage.filter.common.FilterCreaturePermanent; +import mage.filter.common.FilterLandPermanent; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.permanent.Permanent; @@ -59,7 +59,6 @@ public class LavaballTrap extends CardImpl { this.expansionSetCode = "ZEN"; this.subtype.add("Trap"); - // If an opponent had two or more lands enter the battlefield under his or her control this turn, you may pay {3}{R}{R} rather than pay Lavaball Trap's mana cost. this.getSpellAbility().addAlternativeCost(new LavaballTrapAlternativeCost()); this.getSpellAbility().addWatcher(new LavaballTrapWatcher()); @@ -67,7 +66,7 @@ public class LavaballTrap extends CardImpl { // Destroy two target lands. Lavaball Trap deals 4 damage to each creature. this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addEffect(new DamageAllEffect(4, new FilterCreaturePermanent())); - this.getSpellAbility().addTarget(new TargetLandPermanent(2)); + this.getSpellAbility().addTarget(new TargetLandPermanent(2, 2, new FilterLandPermanent("lands"), false)); } @@ -164,4 +163,4 @@ class LavaballTrapAlternativeCost extends AlternativeCostImpl { public String getText() { return "If an opponent had two or more lands enter the battlefield under his or her control this turn, you may pay {3}{R}{R} rather than pay Lavaball Trap's mana cost"; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/zendikar/LuminarchAscension.java b/Mage.Sets/src/mage/sets/zendikar/LuminarchAscension.java index 5464750d433..466a68220af 100644 --- a/Mage.Sets/src/mage/sets/zendikar/LuminarchAscension.java +++ b/Mage.Sets/src/mage/sets/zendikar/LuminarchAscension.java @@ -61,7 +61,7 @@ public class LuminarchAscension extends CardImpl { this.expansionSetCode = "ZEN"; // At the beginning of each opponent's end step, if you didn't lose life this turn, you may put a quest counter on Luminarch Ascension. - this.addAbility(new ConditionalTriggeredAbility(new LuminarchAscensionTriggeredAbility(), YouLostNoLifeThisTurnCondition.getInstance(), rule, true)); + this.addAbility(new ConditionalTriggeredAbility(new LuminarchAscensionTriggeredAbility(), YouLostNoLifeThisTurnCondition.getInstance(), rule)); // {1}{W}: Put a 4/4 white Angel creature token with flying onto the battlefield. Activate this ability only if Luminarch Ascension has four or more quest counters on it. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CreateTokenEffect(new AngelToken()), new ManaCostsImpl("{1}{W}")); diff --git a/Mage.Sets/src/mage/sets/zendikar/MagosiTheWaterveil.java b/Mage.Sets/src/mage/sets/zendikar/MagosiTheWaterveil.java index 578345c2938..6850c94e1c8 100644 --- a/Mage.Sets/src/mage/sets/zendikar/MagosiTheWaterveil.java +++ b/Mage.Sets/src/mage/sets/zendikar/MagosiTheWaterveil.java @@ -28,9 +28,6 @@ package mage.sets.zendikar; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.common.EntersBattlefieldTappedAbility; import mage.abilities.common.SimpleActivatedAbility; @@ -38,17 +35,15 @@ import mage.abilities.costs.common.RemoveCountersSourceCost; import mage.abilities.costs.common.ReturnToHandSourceCost; import mage.abilities.costs.common.TapSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.effects.common.turn.AddExtraTurnControllerEffect; +import mage.abilities.effects.common.turn.SkipNextTurnSourceEffect; import mage.abilities.mana.BlueManaAbility; import mage.cards.CardImpl; -import mage.constants.Outcome; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.constants.Zone; import mage.counters.CounterType; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.game.turn.TurnMod; -import mage.players.Player; /** * @@ -62,21 +57,22 @@ public class MagosiTheWaterveil extends CardImpl { // Magosi, the Waterveil enters the battlefield tapped. this.addAbility(new EntersBattlefieldTappedAbility()); - - // {tap}: Add {U} to your mana pool. + + // {T}: Add {U} to your mana pool. this.addAbility(new BlueManaAbility()); - - // {U}, {tap}: Put an eon counter on Magosi, the Waterveil. Skip your next turn. - Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new MagosiTheWaterveilEffect(), new ManaCostsImpl("{U}")); + + // {U}, {T}: Put an eon counter on Magosi, the Waterveil. Skip your next turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersSourceEffect(CounterType.EON.createInstance()), new ManaCostsImpl("{U}")); + ability.addEffect(new SkipNextTurnSourceEffect()); ability.addCost(new TapSourceCost()); this.addAbility(ability); - - // {tap}, Remove an eon counter from Magosi, the Waterveil and return it to its owner's hand: Take an extra turn after this one. + + // {T}, Remove an eon counter from Magosi, the Waterveil and return it to its owner's hand: Take an extra turn after this one. Ability ability2 = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddExtraTurnControllerEffect(), new TapSourceCost()); ability2.addCost(new RemoveCountersSourceCost(CounterType.EON.createInstance())); ability2.addCost(new ReturnToHandSourceCost()); this.addAbility(ability2); - + } public MagosiTheWaterveil(final MagosiTheWaterveil card) { @@ -88,35 +84,3 @@ public class MagosiTheWaterveil extends CardImpl { return new MagosiTheWaterveil(this); } } - -class MagosiTheWaterveilEffect extends OneShotEffect { - - public MagosiTheWaterveilEffect() { - super(Outcome.Neutral); - staticText = "Put an eon counter on Magosi, the Waterveil. Skip your next turn"; - } - - public MagosiTheWaterveilEffect(final MagosiTheWaterveilEffect effect) { - super(effect); - } - - @Override - public MagosiTheWaterveilEffect copy() { - return new MagosiTheWaterveilEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent magosi = game.getPermanent(source.getSourceId()); - Player player = game.getPlayer(source.getControllerId()); - - if (magosi != null) { - magosi.addCounters(CounterType.EON.createInstance(), game); - } - if (player != null) { - game.getState().getTurnMods().add(new TurnMod(player.getId(), true)); - } - return true; - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/zendikar/MarkOfMutiny.java b/Mage.Sets/src/mage/sets/zendikar/MarkOfMutiny.java index 1f329686b98..d7b27e2f34f 100644 --- a/Mage.Sets/src/mage/sets/zendikar/MarkOfMutiny.java +++ b/Mage.Sets/src/mage/sets/zendikar/MarkOfMutiny.java @@ -25,19 +25,19 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.zendikar; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.UntapTargetEffect; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.effects.common.continuous.GainControlTargetEffect; import mage.abilities.effects.common.counter.AddCountersTargetEffect; -import mage.abilities.effects.common.UntapTargetEffect; import mage.abilities.keyword.HasteAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; import mage.counters.CounterType; import mage.target.common.TargetCreaturePermanent; @@ -47,18 +47,28 @@ import mage.target.common.TargetCreaturePermanent; */ public class MarkOfMutiny extends CardImpl { - public MarkOfMutiny (UUID ownerId) { + public MarkOfMutiny(UUID ownerId) { super(ownerId, 137, "Mark of Mutiny", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{R}"); this.expansionSetCode = "ZEN"; + // Gain control of target creature until end of turn. + // Put a +1/+1 counter on it and untap it. + // That creature gains haste until end of turn. (It can attack and this turn.) this.getSpellAbility().addTarget(new TargetCreaturePermanent()); this.getSpellAbility().addEffect(new GainControlTargetEffect(Duration.EndOfTurn)); - this.getSpellAbility().addEffect(new AddCountersTargetEffect(CounterType.P1P1.createInstance())); - this.getSpellAbility().addEffect(new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn)); - this.getSpellAbility().addEffect(new UntapTargetEffect()); + Effect effect = new AddCountersTargetEffect(CounterType.P1P1.createInstance()); + effect.setText("Put a +1/+1 counter on it"); + this.getSpellAbility().addEffect(effect); + effect = new UntapTargetEffect(); + effect.setText("and untap it"); + this.getSpellAbility().addEffect(effect); + effect = new GainAbilityTargetEffect(HasteAbility.getInstance(), Duration.EndOfTurn); + effect.setText("That creature gains haste until end of turn. (It can {T} attack and this turn.)"); + this.getSpellAbility().addEffect(effect); + } - public MarkOfMutiny (final MarkOfMutiny card) { + public MarkOfMutiny(final MarkOfMutiny card) { super(card); } diff --git a/Mage.Sets/src/mage/sets/zendikar/MerfolkWayfinder.java b/Mage.Sets/src/mage/sets/zendikar/MerfolkWayfinder.java index 6ecc9dbbdfe..5232704f31f 100644 --- a/Mage.Sets/src/mage/sets/zendikar/MerfolkWayfinder.java +++ b/Mage.Sets/src/mage/sets/zendikar/MerfolkWayfinder.java @@ -116,7 +116,7 @@ class MerfolkWayfinderEffect extends OneShotEffect { player.revealCards("Merfolk Wayfinder", cardsToReveal, game); TargetCard target = new TargetCard(Zone.PICK, new FilterCard("card to put on the bottom of your library")); - while (player.isInGame() && cards.size() > 1) { + while (player.canRespond() && cards.size() > 1) { player.choose(Outcome.Neutral, cards, target, game); Card card = cards.get(target.getFirstTarget(), game); if (card != null) { diff --git a/Mage.Sets/src/mage/sets/zendikar/PitfallTrap.java b/Mage.Sets/src/mage/sets/zendikar/PitfallTrap.java index 7d6e1f96dd7..7ba0ab5b4d7 100644 --- a/Mage.Sets/src/mage/sets/zendikar/PitfallTrap.java +++ b/Mage.Sets/src/mage/sets/zendikar/PitfallTrap.java @@ -28,14 +28,14 @@ package mage.sets.zendikar; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.costs.AlternativeCostImpl; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.common.DestroyTargetEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.filter.common.FilterAttackingCreature; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.AbilityPredicate; @@ -48,7 +48,7 @@ import mage.target.common.TargetAttackingCreature; */ public class PitfallTrap extends CardImpl { - private static final FilterAttackingCreature filter = new FilterAttackingCreature("creature without flying"); + private static final FilterAttackingCreature filter = new FilterAttackingCreature("attacking creature without flying"); static { filter.add(Predicates.not(new AbilityPredicate(FlyingAbility.class))); @@ -59,10 +59,9 @@ public class PitfallTrap extends CardImpl { this.expansionSetCode = "ZEN"; this.subtype.add("Trap"); - // If exactly one creature is attacking, you may pay {W} rather than pay Pitfall Trap's mana cost. this.getSpellAbility().addAlternativeCost(new PitfallTrapAlternativeCost()); - + // Destroy target attacking creature without flying. this.getSpellAbility().addEffect(new DestroyTargetEffect()); this.getSpellAbility().addTarget(new TargetAttackingCreature(1, 1, filter, false)); @@ -106,4 +105,4 @@ class PitfallTrapAlternativeCost extends AlternativeCostImpl { public String getText() { return "If exactly one creature is attacking, you may pay {W} rather than pay Pitfall Trap's mana cost"; } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/zendikar/PredatoryUrge.java b/Mage.Sets/src/mage/sets/zendikar/PredatoryUrge.java index 76273506c4c..bf1fac671b9 100644 --- a/Mage.Sets/src/mage/sets/zendikar/PredatoryUrge.java +++ b/Mage.Sets/src/mage/sets/zendikar/PredatoryUrge.java @@ -28,22 +28,21 @@ package mage.sets.zendikar; import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.DamageEachOtherEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; import mage.constants.AttachmentType; import mage.constants.CardType; import mage.constants.Outcome; import mage.constants.Rarity; import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.common.SimpleActivatedAbility; -import mage.abilities.common.SimpleStaticAbility; -import mage.abilities.costs.common.TapSourceCost; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.AttachEffect; -import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; -import mage.abilities.keyword.EnchantAbility; -import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; import mage.target.TargetPermanent; import mage.target.common.TargetCreaturePermanent; @@ -67,9 +66,11 @@ public class PredatoryUrge extends CardImpl { this.addAbility(ability); // Enchanted creature has "{tap}: This creature deals damage equal to its power to target creature. // That creature deals damage equal to its power to this creature." - ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PredatoryUrgeEffect(), new TapSourceCost()); + ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageEachOtherEffect(), new TapSourceCost()); ability.addTarget(new TargetCreaturePermanent()); - this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(ability, AttachmentType.AURA))); + Effect effect = new GainAbilityAttachedEffect(ability, AttachmentType.AURA); + effect.setText("Enchanted creature has \"{T}: This creature deals damage equal to its power to target creature. That creature deals damage equal to its power to this creature.\""); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, effect)); } public PredatoryUrge(final PredatoryUrge card) { @@ -81,42 +82,3 @@ public class PredatoryUrge extends CardImpl { return new PredatoryUrge(this); } } - -class PredatoryUrgeEffect extends OneShotEffect { - - public PredatoryUrgeEffect() { - super(Outcome.Damage); - this.staticText = "This creature deals damage equal to its power to target creature. That creature deals damage equal to its power to this creature."; - } - - public PredatoryUrgeEffect(final PredatoryUrgeEffect effect) { - super(effect); - } - - @Override - public PredatoryUrgeEffect copy() { - return new PredatoryUrgeEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - boolean sourceOnBattlefield = true; - Permanent targetCreature = game.getPermanent(source.getFirstTarget()); - Permanent sourceCreature = game.getPermanent(source.getSourceId()); - if (sourceCreature == null) { - sourceCreature = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD); - sourceOnBattlefield = false; - } - - if (sourceCreature != null && targetCreature != null - && sourceCreature.getCardType().contains(CardType.CREATURE) - && targetCreature.getCardType().contains(CardType.CREATURE)) { - targetCreature.damage(sourceCreature.getPower().getValue(), sourceCreature.getId(), game, false, true); - if (sourceOnBattlefield) { - sourceCreature.damage(targetCreature.getPower().getValue(), targetCreature.getId(), game, false, true); - } - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/zendikar/QuestForTheGravelord.java b/Mage.Sets/src/mage/sets/zendikar/QuestForTheGravelord.java index 540570e9664..ddba7cf5ceb 100644 --- a/Mage.Sets/src/mage/sets/zendikar/QuestForTheGravelord.java +++ b/Mage.Sets/src/mage/sets/zendikar/QuestForTheGravelord.java @@ -32,7 +32,6 @@ import mage.constants.CardType; import mage.constants.Rarity; import mage.constants.Zone; import mage.MageInt; -import mage.ObjectColor; import mage.abilities.common.DiesCreatureTriggeredAbility; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.RemoveCountersSourceCost; @@ -53,7 +52,6 @@ public class QuestForTheGravelord extends CardImpl { super(ownerId, 108, "Quest for the Gravelord", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{B}"); this.expansionSetCode = "ZEN"; - // Whenever a creature dies, you may put a quest counter on Quest for the Gravelord. this.addAbility(new DiesCreatureTriggeredAbility(new AddCountersSourceEffect(CounterType.QUEST.createInstance()), true)); // Remove three quest counters from Quest for the Gravelord and sacrifice it: Put a 5/5 black Zombie Giant creature token onto the battlefield. @@ -86,4 +84,4 @@ class ZombieToken extends Token { power = new MageInt(5); toughness = new MageInt(5); } -} \ No newline at end of file +} diff --git a/Mage.Sets/src/mage/sets/zendikar/RavenousTrap.java b/Mage.Sets/src/mage/sets/zendikar/RavenousTrap.java index d01bf7f2758..f21710f496f 100644 --- a/Mage.Sets/src/mage/sets/zendikar/RavenousTrap.java +++ b/Mage.Sets/src/mage/sets/zendikar/RavenousTrap.java @@ -27,21 +27,15 @@ */ package mage.sets.zendikar; -import java.util.ArrayList; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; import mage.abilities.Ability; import mage.abilities.costs.AlternativeCostImpl; import mage.abilities.costs.mana.GenericManaCost; -import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.ExileGraveyardAllTargetPlayerEffect; import mage.cards.CardImpl; -import mage.constants.Outcome; -import mage.constants.Zone; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.game.Game; -import mage.players.Player; import mage.target.TargetPlayer; import mage.watchers.common.CardsPutIntoGraveyardWatcher; @@ -56,7 +50,6 @@ public class RavenousTrap extends CardImpl { this.expansionSetCode = "ZEN"; this.subtype.add("Trap"); - // If an opponent had three or more cards put into his or her graveyard from anywhere this turn, you may pay {0} rather than pay Ravenous Trap's mana cost. this.getSpellAbility().addAlternativeCost( new RavenousTrapAlternativeCost()); @@ -97,7 +90,7 @@ class RavenousTrapAlternativeCost extends AlternativeCostImpl { public boolean isAvailable(Game game, Ability source) { CardsPutIntoGraveyardWatcher watcher = (CardsPutIntoGraveyardWatcher) game.getState().getWatchers().get("CardsPutIntoGraveyardWatcher"); if (watcher != null) { - for (UUID opponentId: game.getOpponents(source.getControllerId())) { + for (UUID opponentId : game.getOpponents(source.getControllerId())) { if (watcher.getAmountCardsPutToGraveyard(opponentId) > 2) { return true; } @@ -108,6 +101,6 @@ class RavenousTrapAlternativeCost extends AlternativeCostImpl { @Override public String getText() { - return "If an opponent had three or more cards put into his or her graveyard from anywhere this turn, you may pay {0} rather than pay Ravenous Trap's mana cost"; + return "If an opponent had three or more cards put into his or her graveyard from anywhere this turn, you may pay {0} rather than pay {this}'s mana cost"; } } diff --git a/Mage.Sets/src/mage/sets/zendikar/RuinousMinotaur.java b/Mage.Sets/src/mage/sets/zendikar/RuinousMinotaur.java index 84d78b7cc11..9942935f688 100644 --- a/Mage.Sets/src/mage/sets/zendikar/RuinousMinotaur.java +++ b/Mage.Sets/src/mage/sets/zendikar/RuinousMinotaur.java @@ -30,16 +30,11 @@ package mage.sets.zendikar; import java.util.UUID; import mage.constants.CardType; import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; -import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.common.SacrificeTargetEffect; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.effects.common.SacrificeControllerEffect; import mage.cards.CardImpl; -import mage.filter.common.FilterControlledLandPermanent; -import mage.filter.common.FilterControlledPermanent; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.target.common.TargetControlledPermanent; +import mage.filter.common.FilterLandPermanent; /** * @@ -57,7 +52,8 @@ public class RuinousMinotaur extends CardImpl { this.toughness = new MageInt(2); // Whenever Ruinous Minotaur deals damage to an opponent, sacrifice a land. - this.addAbility(new RuinousMinotaurTriggeredAbility()); + this.addAbility(new DealsDamageToOpponentTriggeredAbility(new SacrificeControllerEffect(new FilterLandPermanent(), 1, ""), false, false)); + } public RuinousMinotaur(final RuinousMinotaur card) { @@ -69,38 +65,3 @@ public class RuinousMinotaur extends CardImpl { return new RuinousMinotaur(this); } } - -class RuinousMinotaurTriggeredAbility extends TriggeredAbilityImpl { - - private static final FilterControlledPermanent filter = new FilterControlledLandPermanent(); - - public RuinousMinotaurTriggeredAbility() { - super(Zone.BATTLEFIELD, new SacrificeTargetEffect(), false); - this.addTarget(new TargetControlledPermanent(filter)); - } - - public RuinousMinotaurTriggeredAbility(final RuinousMinotaurTriggeredAbility ability) { - super(ability); - } - - @Override - public RuinousMinotaurTriggeredAbility copy() { - return new RuinousMinotaurTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == GameEvent.EventType.DAMAGED_PLAYER; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return event.getSourceId().equals(this.sourceId) - && game.getOpponents(this.getControllerId()).contains(event.getTargetId()); - } - - @Override - public String getRule() { - return "Whenever {this} deals damage to an opponent, sacrifice a land."; - } -} diff --git a/Mage.Sets/src/mage/sets/zendikar/SlaughterCry.java b/Mage.Sets/src/mage/sets/zendikar/SlaughterCry.java index 6fb34df8f7f..434d95e4dfc 100644 --- a/Mage.Sets/src/mage/sets/zendikar/SlaughterCry.java +++ b/Mage.Sets/src/mage/sets/zendikar/SlaughterCry.java @@ -28,13 +28,14 @@ package mage.sets.zendikar; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; +import mage.abilities.effects.Effect; import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.keyword.FirstStrikeAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; import mage.target.common.TargetCreaturePermanent; /** @@ -47,10 +48,14 @@ public class SlaughterCry extends CardImpl { super(ownerId, 149, "Slaughter Cry", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); this.expansionSetCode = "ZEN"; - + // Target creature gets +3/+0 and gains first strike until end of turn. (It deals combat damage before creatures without first strike.) this.getSpellAbility().addTarget(new TargetCreaturePermanent()); - this.getSpellAbility().addEffect(new BoostTargetEffect(3, 0, Duration.EndOfTurn)); - this.getSpellAbility().addEffect(new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn)); + Effect effect = new BoostTargetEffect(3, 0, Duration.EndOfTurn); + effect.setText("Target creature gets +3/+0"); + this.getSpellAbility().addEffect(effect); + effect = new GainAbilityTargetEffect(FirstStrikeAbility.getInstance(), Duration.EndOfTurn); + effect.setText("and gains first strike until end of turn. (It deals combat damage before creatures without first strike.)"); + this.getSpellAbility().addEffect(effect); } public SlaughterCry(final SlaughterCry card) { diff --git a/Mage.Sets/src/mage/sets/zendikar/SpireBarrage.java b/Mage.Sets/src/mage/sets/zendikar/SpireBarrage.java index e5c2426261d..55e035ac355 100644 --- a/Mage.Sets/src/mage/sets/zendikar/SpireBarrage.java +++ b/Mage.Sets/src/mage/sets/zendikar/SpireBarrage.java @@ -27,26 +27,25 @@ */ package mage.sets.zendikar; -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.TargetController; +import java.util.UUID; import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; import mage.abilities.effects.common.DamageTargetEffect; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; import mage.filter.common.FilterLandPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; import mage.filter.predicate.permanent.ControllerPredicate; import mage.target.common.TargetCreatureOrPlayer; -import java.util.UUID; - /** * * @author North */ public class SpireBarrage extends CardImpl { - private static final FilterLandPermanent filter = new FilterLandPermanent("Mountains"); + private static final FilterLandPermanent filter = new FilterLandPermanent("Mountain you control"); static { filter.add(new SubtypePredicate("Mountain")); @@ -57,7 +56,6 @@ public class SpireBarrage extends CardImpl { super(ownerId, 150, "Spire Barrage", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{4}{R}"); this.expansionSetCode = "ZEN"; - // Spire Barrage deals damage to target creature or player equal to the number of Mountains you control. this.getSpellAbility().addEffect(new DamageTargetEffect(new PermanentsOnBattlefieldCount(filter))); this.getSpellAbility().addTarget(new TargetCreatureOrPlayer()); diff --git a/Mage.Sets/src/mage/sets/zendikar/VinesOfVastwood.java b/Mage.Sets/src/mage/sets/zendikar/VinesOfVastwood.java index d67de8aa3f2..cb72eb9e989 100644 --- a/Mage.Sets/src/mage/sets/zendikar/VinesOfVastwood.java +++ b/Mage.Sets/src/mage/sets/zendikar/VinesOfVastwood.java @@ -25,23 +25,22 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.sets.zendikar; import java.util.UUID; import mage.abilities.condition.LockedInCondition; -import mage.constants.CardType; -import mage.constants.Duration; -import mage.constants.Rarity; import mage.abilities.condition.common.KickedCondition; import mage.abilities.decorator.ConditionalContinuousEffect; import mage.abilities.effects.common.CantBeTargetedTargetEffect; import mage.abilities.effects.common.continuous.BoostTargetEffect; import mage.abilities.keyword.KickerAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; import mage.constants.TargetController; +import mage.filter.FilterObject; import mage.filter.FilterStackObject; -import mage.filter.predicate.permanent.ControllerPredicate; import mage.target.common.TargetCreaturePermanent; /** @@ -49,12 +48,8 @@ import mage.target.common.TargetCreaturePermanent; */ public class VinesOfVastwood extends CardImpl { - private static final FilterStackObject filter = new FilterStackObject("spells or abilities your opponents control"); + private static final FilterObject filter = new FilterStackObject("spells or abilities your opponents control"); - static { - filter.add(new ControllerPredicate(TargetController.OPPONENT)); - } - private static final String staticText = "If {this} was kicked, that creature gets +4/+4 until end of turn"; public VinesOfVastwood(UUID ownerId) { @@ -66,7 +61,7 @@ public class VinesOfVastwood extends CardImpl { // Target creature can't be the target of spells or abilities your opponents control this turn. this.getSpellAbility().addTarget(new TargetCreaturePermanent()); - this.getSpellAbility().addEffect(new CantBeTargetedTargetEffect(filter, Duration.EndOfTurn)); + this.getSpellAbility().addEffect(new CantBeTargetedTargetEffect(filter, Duration.EndOfTurn, TargetController.OPPONENT)); // If Vines of Vastwood was kicked, that creature gets +4/+4 until end of turn. this.getSpellAbility().addEffect(new ConditionalContinuousEffect(new BoostTargetEffect(4, 4, Duration.EndOfTurn), @@ -82,4 +77,3 @@ public class VinesOfVastwood extends CardImpl { return new VinesOfVastwood(this); } } - diff --git a/Mage.Sets/src/mage/sets/zendikar/WarrenInstigator.java b/Mage.Sets/src/mage/sets/zendikar/WarrenInstigator.java index 8179345ad2d..7cbe2539675 100644 --- a/Mage.Sets/src/mage/sets/zendikar/WarrenInstigator.java +++ b/Mage.Sets/src/mage/sets/zendikar/WarrenInstigator.java @@ -29,23 +29,14 @@ package mage.sets.zendikar; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; -import mage.abilities.TriggeredAbilityImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; +import mage.abilities.effects.common.PutPermanentOnBattlefieldEffect; import mage.abilities.keyword.DoubleStrikeAbility; -import mage.cards.Card; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterCreatureCard; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.events.GameEvent; -import mage.game.events.GameEvent.EventType; -import mage.players.Player; -import mage.target.common.TargetCardInHand; /** * @@ -53,6 +44,12 @@ import mage.target.common.TargetCardInHand; */ public class WarrenInstigator extends CardImpl { + private static final FilterCreatureCard filter = new FilterCreatureCard("a Goblin creature card"); + + static { + filter.add(new SubtypePredicate("Goblin")); + } + public WarrenInstigator(UUID ownerId) { super(ownerId, 154, "Warren Instigator", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{R}{R}"); this.expansionSetCode = "ZEN"; @@ -63,7 +60,9 @@ public class WarrenInstigator extends CardImpl { this.toughness = new MageInt(1); this.addAbility(DoubleStrikeAbility.getInstance()); - this.addAbility(new WarrenInstigatorTriggeredAbility()); + + // Whenever Warren Instigator deals damage to an opponent, you may put a Goblin creature card from your hand onto the battlefield. + this.addAbility(new DealsDamageToOpponentTriggeredAbility(new PutPermanentOnBattlefieldEffect(filter), false)); } public WarrenInstigator(final WarrenInstigator card) { @@ -75,72 +74,3 @@ public class WarrenInstigator extends CardImpl { return new WarrenInstigator(this); } } - -class WarrenInstigatorTriggeredAbility extends TriggeredAbilityImpl { - - public WarrenInstigatorTriggeredAbility() { - super(Zone.BATTLEFIELD, new WarrenInstigatorEffect(), true); - } - - public WarrenInstigatorTriggeredAbility(final WarrenInstigatorTriggeredAbility ability) { - super(ability); - } - - @Override - public WarrenInstigatorTriggeredAbility copy() { - return new WarrenInstigatorTriggeredAbility(this); - } - - @Override - public boolean checkEventType(GameEvent event, Game game) { - return event.getType() == EventType.DAMAGED_PLAYER; - } - - @Override - public boolean checkTrigger(GameEvent event, Game game) { - return event.getSourceId().equals(this.sourceId) - && game.getOpponents(this.getControllerId()).contains(event.getTargetId()); - } - - @Override - public String getRule() { - return "Whenever {this} deals damage to an opponent, you may put a Goblin creature card from your hand onto the battlefield."; - } -} - -class WarrenInstigatorEffect extends OneShotEffect { - - public WarrenInstigatorEffect() { - super(Outcome.PutCreatureInPlay); - this.staticText = "you may put a Goblin creature card from your hand onto the battlefield"; - } - - public WarrenInstigatorEffect(final WarrenInstigatorEffect effect) { - super(effect); - } - - @Override - public WarrenInstigatorEffect copy() { - return new WarrenInstigatorEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null) { - return false; - } - - FilterCreatureCard filter = new FilterCreatureCard("Goblin creature card from your hand"); - filter.add(new SubtypePredicate("Goblin")); - TargetCardInHand target = new TargetCardInHand(filter); - if (player.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - card.putOntoBattlefield(game, Zone.HAND, source.getSourceId(), source.getControllerId()); - return true; - } - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/zendikar/WorldQueller.java b/Mage.Sets/src/mage/sets/zendikar/WorldQueller.java index c1c52dd604c..d85879e1ff7 100644 --- a/Mage.Sets/src/mage/sets/zendikar/WorldQueller.java +++ b/Mage.Sets/src/mage/sets/zendikar/WorldQueller.java @@ -120,7 +120,7 @@ class WorldQuellerEffect extends OneShotEffect { if (you != null && sourceCreature != null) { Choice choiceImpl = new ChoiceImpl(); choiceImpl.setChoices(choice); - while (you.isInGame() && !you.choose(Outcome.Neutral, choiceImpl, game)) {} + while (you.canRespond() && !you.choose(Outcome.Neutral, choiceImpl, game)) {} CardType type = null; String choosenType = choiceImpl.getChoice(); @@ -150,7 +150,7 @@ class WorldQuellerEffect extends OneShotEffect { // you always go first if (target.canChoose(you.getId(), game)) { - while (you.isInGame() && !target.isChosen() && target.canChoose(you.getId(), game)) { + while (you.canRespond() && !target.isChosen() && target.canChoose(you.getId(), game)) { you.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } Permanent permanent = game.getPermanent(target.getFirstTarget()); diff --git a/Mage.Stats/pom.xml b/Mage.Stats/pom.xml index bad954e962b..91da9f71b06 100644 --- a/Mage.Stats/pom.xml +++ b/Mage.Stats/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 org.mage diff --git a/Mage.Tests/CMDNorinTheWary.dck b/Mage.Tests/CMDNorinTheWary.dck new file mode 100644 index 00000000000..74c3bd1c172 --- /dev/null +++ b/Mage.Tests/CMDNorinTheWary.dck @@ -0,0 +1,75 @@ +1 [BOK:108] In the Web of War +1 [7ED:319] Static Orb +1 [ALA:101] Goblin Assault +1 [8ED:204] Obliterate +1 [ORI:149] Ghirapur Gearcrafter +1 [SCG:85] Decree of Annihilation +1 [ONS:317] Forgotten Cave +1 [MRD:282] Great Furnace +1 [EVE:179] Springjack Pasture +1 [VIS:141] Anvil of Bogardan +1 [JOU:89] Bearer of the Heavens +1 [ODY:214] Price of Glory +1 [9ED:176] Blood Moon +1 [M10:212] Howling Mine +1 [CMD:114] Chaos Warp +1 [M12:153] Scrambleverse +1 [10E:204] Furnace of Rath +1 [ZEN:228] Valakut, the Molten Pinnacle +1 [M12:160] Warstorm Surge +1 [AVR:126] Archwing Dragon +1 [M15:149] Hoarding Dragon +1 [4ED:189] Strip Mine +1 [ORI:145] Fiery Impulse +1 [CSP:149] Scrying Sheets +1 [ORI:142] Enthralling Victor +1 [ORI:144] Fiery Conclusion +1 [ORI:139] Demolish +1 [MMQ:320] High Market +1 [M12:224] Buried Ruin +1 [TOR:113] Radiate +1 [M10:163] Warp World +1 [TSP:188] Word of Seizing +1 [DST:122] Genesis Chamber +1 [TSP:275] Kher Keep +1 [ORI:134] Call of the Full Moon +1 [ORI:136] Chandra's Fury +26 [CSP:154] Snow-Covered Mountain +1 [ONS:212] Gratuitous Violence +1 [ORI:133] Boggart Brute +1 [ONS:213] Insurrection +1 [TMP:210] Tooth and Claw +1 [ORI:129] Act of Treason +1 [BOK:120] Twist Allegiance +1 [CMD:136] Stranglehold +1 [M13:145] Reverberate +1 [EXO:102] Shattering Pulse +1 [9ED:312] Teferi's Puzzle Box +1 [M14:162] Wild Ricochet +1 [3ED:274] Sol Ring +1 [3ED:152] Fork +1 [DGM:34] Possibility Storm +1 [USG:188] Gamble +1 [5ED:64] Smoke +1 [STH:93] Mogg Infestation +1 [ULG:80] Goblin Welder +1 [ALA:119] Vicious Shadows +1 [ORI:163] Smash to Smithereens +1 [THS:135] Purphoros, God of the Forge +1 [CON:136] Font of Mythos +1 [7ED:307] Meekstone +1 [TSB:68] Pandemonium +1 [GTC:248] Thespian's Stage +1 [3ED:184] Wheel of Fortune +1 [M15:242] Darksteel Citadel +1 [M11:160] Wild Evocation +1 [RTR:111] Vandalblast +1 [TSP:175] Reiterate +1 [M14:148] Ogre Battledriver +1 [ORI:156] Molten Vortex +1 [MIR:183] Illicit Auction +1 [ULG:123] Crawlspace +1 [5ED:246] Jokulhaups +1 [JOU:93] Dictate of the Twin Gods +1 [5ED:249] Mana Flare +SB: 1 [TSP:171] Norin the Wary diff --git a/Mage.Tests/pom.xml b/Mage.Tests/pom.xml index c502712f6de..94b1da2ba9d 100644 --- a/Mage.Tests/pom.xml +++ b/Mage.Tests/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage-tests diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastCreaturesTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastCreaturesTest.java index f65e7655177..d14393676f2 100644 --- a/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastCreaturesTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastCreaturesTest.java @@ -29,7 +29,6 @@ package org.mage.test.AI.basic; import mage.constants.PhaseStep; import mage.constants.Zone; -import org.junit.Ignore; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBaseAI; @@ -52,7 +51,7 @@ public class CastCreaturesTest extends CardTestPlayerBaseAI { assertPermanentCount(playerA, "Silvercoat Lion", 1); } - + @Test public void testSimpleCast2() { addCard(Zone.HAND, playerA, "Silvercoat Lion"); @@ -65,9 +64,8 @@ public class CastCreaturesTest extends CardTestPlayerBaseAI { assertPermanentCount(playerA, "Silvercoat Lion", 2); } - + @Test - @Ignore // AI should cast Myr Enforcer -> Check why it does not public void testSimpleCast3() { // Affinity for artifacts (This spell costs less to cast for each artifact you control.) addCard(Zone.HAND, playerA, "Myr Enforcer"); @@ -80,5 +78,84 @@ public class CastCreaturesTest extends CardTestPlayerBaseAI { execute(); assertPermanentCount(playerA, "Myr Enforcer", 1); - } + } + + @Test + public void testSimpleCast4() { + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + addCard(Zone.BATTLEFIELD, playerA, "Mountain"); + addCard(Zone.HAND, playerA, "Plains"); + skipInitShuffling(); + + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + + addCard(Zone.HAND, playerA, "Fireshrieker"); + addCard(Zone.HAND, playerA, "Blazing Specter"); // {2}{R}{B} + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Plains", 2); + assertPermanentCount(playerA, "Fireshrieker", 0); + assertPermanentCount(playerA, "Blazing Specter", 1); + } + + @Test + public void testCast4Creature() { + addCard(Zone.LIBRARY, playerA, "Swamp", 1); + addCard(Zone.LIBRARY, playerA, "Mountain", 1); + addCard(Zone.LIBRARY, playerA, "Island", 1); + addCard(Zone.HAND, playerA, "Plains"); + skipInitShuffling(); + + addCard(Zone.HAND, playerA, "Loyal Sentry"); // {W} 1/1 + addCard(Zone.HAND, playerA, "Silvercoat Lion"); // {1}{W} 2/2 + addCard(Zone.HAND, playerA, "Rootwater Commando"); // {2}{U} 2/2 + addCard(Zone.HAND, playerA, "Bog Wraith"); // {3}{B} 3/3 + + setStopAt(7, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Plains", 1); + assertPermanentCount(playerA, "Mountain", 1); + assertPermanentCount(playerA, "Island", 1); + assertPermanentCount(playerA, "Swamp", 1); + + // assertLife(playerB, 11); // 1 + 1+2 + 1+2+2 = + assertPermanentCount(playerA, "Loyal Sentry", 1); + assertPermanentCount(playerA, "Silvercoat Lion", 1); + assertPermanentCount(playerA, "Rootwater Commando", 1); + assertPermanentCount(playerA, "Bog Wraith", 1); + + } + + @Test + public void testCast4Creature2() { + addCard(Zone.LIBRARY, playerA, "Swamp", 1); + addCard(Zone.LIBRARY, playerA, "Swamp", 1); + addCard(Zone.LIBRARY, playerA, "Plains", 1); + + addCard(Zone.HAND, playerA, "Island", 1); + addCard(Zone.HAND, playerA, "Plains"); + skipInitShuffling(); + + addCard(Zone.HAND, playerA, "Loyal Sentry"); // {W} 1/1 + addCard(Zone.HAND, playerA, "Steadfast Guard"); // {W}{W} 2/2 + addCard(Zone.HAND, playerA, "Rootwater Commando"); // {2}{U} 2/2 + addCard(Zone.HAND, playerA, "Bog Wraith"); // {3}{B} 3/3 + + setStopAt(7, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Plains", 2); + assertPermanentCount(playerA, "Island", 1); + assertPermanentCount(playerA, "Swamp", 1); + + // assertLife(playerB, 11); // 1 + 1+2 + 1+2+2 = + assertPermanentCount(playerA, "Loyal Sentry", 1); + assertPermanentCount(playerA, "Steadfast Guard", 1); + assertPermanentCount(playerA, "Rootwater Commando", 1); + assertPermanentCount(playerA, "Bog Wraith", 1); + + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastDestroySpellsTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastDestroySpellsTest.java new file mode 100644 index 00000000000..458bd5012f9 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CastDestroySpellsTest.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.AI.basic; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBaseAI; + +/** + * + * @author LevelX2 + */ +public class CastDestroySpellsTest extends CardTestPlayerBaseAI { + + /** + * + * + */ + @Test + public void testOrzhovCharm() { + // Choose one - + // Return target creature you control and all Auras you control attached to it to their owner's hand; + // or destroy target creature and you lose life equal to its toughness; + // or return target creature card with converted mana cost 1 or less from your graveyard to the battlefield. + addCard(Zone.HAND, playerA, "Orzhov Charm"); // {W}{B} + + addCard(Zone.BATTLEFIELD, playerA, "Fetid Heath", 1); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + + // Cycling abilities you activate cost you up to {2} less to activate. + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertLife(playerA, 18); + + assertGraveyardCount(playerA, "Orzhov Charm", 1); + assertGraveyardCount(playerB, "Silvercoat Lion", 1); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/CombatTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CombatTest.java new file mode 100644 index 00000000000..4310dac8920 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/CombatTest.java @@ -0,0 +1,51 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.AI.basic; + +import org.mage.test.serverside.base.CardTestPlayerBaseAI; + +/** + * + * @author LevelX2 + */ +public class CombatTest extends CardTestPlayerBaseAI { + + /* + * Combat is not integrated yet in the CardTestPlayerBaseAI + * + * TODO: Modify CardTestPlayerBaseAI to use the AI combat acting + * + * Tests to create: + * AI is not attacking if opponent has a creature that can't block + * AI is not blocking also if able if the damage the attacker will do will kill the AI + * AI is not able to block with two or more creatures one attacking creature to kill it. Even if none of the AI creatures will die + * AI attacks with a flyer even if opponent has a bigger flyer that kills AI + * Opponent of AI has only 1 life. AI has more creatures that can attack taht do at least 1 damage than opponent has blockers. Ai should attack with all needed creatures + * + */ +} diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/PreventRepeatedActionsTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/PreventRepeatedActionsTest.java new file mode 100644 index 00000000000..1a6259d8e10 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/PreventRepeatedActionsTest.java @@ -0,0 +1,108 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.AI.basic; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.filter.common.FilterLandPermanent; +import mage.game.permanent.Permanent; +import org.junit.Assert; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBaseAI; + +/** + * + * @author LevelX2 + */ +public class PreventRepeatedActionsTest extends CardTestPlayerBaseAI { + + /** + * Check that an equipment is not switched again an again between creatures + * + */ + @Test + public void testEquipOnlyOnce() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 6); + + // Equipped creature gets +1/+1. + // Equip {1}({1}: Attach to target creature you control. Equip only as a sorcery.) + addCard(Zone.BATTLEFIELD, playerA, "Fireshrieker", 1); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion", 2); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + int tappedLands = 0; + for (Permanent permanent : currentGame.getBattlefield().getAllActivePermanents(new FilterLandPermanent(), playerA.getId(), currentGame)) { + if (permanent.isTapped()) { + tappedLands++; + } + } + Assert.assertEquals("AI should only used Equipment once", 2, tappedLands); + } + + /** + * If the AI on a local server gets control of a Basalt Monolith it will + * infinite loop taping for three mana and then using the mana to untap lol. + * Seeing the computer durdle troll is quite the hillarious thing + */ + @Test + public void testBasaltMonolith() { + // Basalt Monolith doesn't untap during your untap step. + // {T}: Add {3} to your mana pool. + // {3}: Untap Basalt Monolith. + addCard(Zone.BATTLEFIELD, playerA, "Basalt Monolith", 1); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertTapped("Basalt Monolith", false); + } + + /** + * AI gets stuck with two Kiora's Followers #1167 + */ + @Test + public void testKiorasFollower() { + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2, true); + // {T}: Untap another target permanent. + addCard(Zone.BATTLEFIELD, playerA, "Kiora's Follower", 1, true); + addCard(Zone.BATTLEFIELD, playerA, "Kiora's Follower", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 2); + + attack(2, playerB, "Silvercoat Lion"); + attack(2, playerB, "Silvercoat Lion"); + + setStopAt(2, PhaseStep.END_TURN); + execute(); + + assertLife(playerA, 16); + assertTapped("Kiora's Follower", false); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/TargetsAreChosenTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/TargetsAreChosenTest.java new file mode 100644 index 00000000000..31a037b721b --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/TargetsAreChosenTest.java @@ -0,0 +1,225 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.AI.basic; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.filter.Filter; +import org.junit.Ignore; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBaseAI; + +/** + * + * @author LevelX2 + */ +public class TargetsAreChosenTest extends CardTestPlayerBaseAI { + + /** + * Check that the AI selects a target from the own artifacts and also an + * artifact from the opponent artficats + */ + @Test + public void testRackAndRuin() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); + // Destroy two target artifacts. + addCard(Zone.HAND, playerA, "Rack and Ruin"); // {2}{R} + + addCard(Zone.BATTLEFIELD, playerA, "Mox Emerald", 2); + addCard(Zone.BATTLEFIELD, playerB, "Juggernaut"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Rack and Ruin", 1); + assertGraveyardCount(playerA, "Mox Emerald", 1); + assertGraveyardCount(playerB, "Juggernaut", 1); + } + + /** + * Check that the AI does not cast Rack and Ruin if it would destroy the + * owly creature on the battlefield owned by the AI + */ + @Test + public void testRackAndRuin2() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); + // Destroy two target artifacts. + addCard(Zone.HAND, playerA, "Rack and Ruin"); // {2}{R} + + addCard(Zone.BATTLEFIELD, playerB, "Mox Emerald"); + addCard(Zone.BATTLEFIELD, playerA, "Juggernaut"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Rack and Ruin", 0); + } + + /** + * Check that the AI does cast Rack and Ruin if it would destroy two targets + * of the opponent + */ + @Test + public void testRackAndRuin3() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); + // Destroy two target artifacts. + addCard(Zone.HAND, playerA, "Rack and Ruin"); // {2}{R} + + addCard(Zone.BATTLEFIELD, playerB, "Mox Emerald", 4); + addCard(Zone.BATTLEFIELD, playerA, "Juggernaut", 1); + addCard(Zone.BATTLEFIELD, playerA, "Composite Golem", 1); + addCard(Zone.BATTLEFIELD, playerA, "Mox Emerald", 1); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Rack and Ruin", 1); + assertGraveyardCount(playerB, "Mox Emerald", 2); + + } + + /** + * Target only opponent creatures to tap + */ + @Test + public void testFrostBreath1() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 3); + // Tap up to two target creatures. Those creatures don't untap during their controller's next untap step. + addCard(Zone.HAND, playerA, "Frost Breath"); // {2}{U} + + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); + addCard(Zone.BATTLEFIELD, playerB, "Pillarfield Ox", 1); + addCard(Zone.BATTLEFIELD, playerA, "Juggernaut", 1); + addCard(Zone.BATTLEFIELD, playerA, "Composite Golem", 1); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Frost Breath", 1); + assertTapped("Silvercoat Lion", true); + assertTapped("Pillarfield Ox", true); + assertTapped("Juggernaut", false); + assertTapped("Composite Golem", false); + + } + + /** + * Target only opponent creatures also if more targets are possible + */ + @Test + public void testFrostBreath2() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 3); + // Tap up to two target creatures. Those creatures don't untap during their controller's next untap step. + addCard(Zone.HAND, playerA, "Frost Breath"); // {2}{U} + + addCard(Zone.BATTLEFIELD, playerB, "Pillarfield Ox", 1); + addCard(Zone.BATTLEFIELD, playerA, "Juggernaut", 1); + addCard(Zone.BATTLEFIELD, playerA, "Composite Golem", 1); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Frost Breath", 1); + assertTapped("Pillarfield Ox", true); + assertTapped("Juggernaut", false); + assertTapped("Composite Golem", false); + + } + + /** + * Spell is not cast if only own creatures can be targeted + */ + @Test + public void testFrostBreath3() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 3); + // Tap up to two target creatures. Those creatures don't untap during their controller's next untap step. + addCard(Zone.HAND, playerA, "Frost Breath"); // {2}{U} + + addCard(Zone.BATTLEFIELD, playerA, "Juggernaut", 1); + addCard(Zone.BATTLEFIELD, playerA, "Composite Golem", 1); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Frost Breath", 0); + assertTapped("Juggernaut", false); + assertTapped("Composite Golem", false); + + } + + /** + * + */ + @Test + public void testNefashu() { + // Whenever Nefashu attacks, up to five target creatures each get -1/-1 until end of turn. + addCard(Zone.BATTLEFIELD, playerA, "Nefashu"); // 5/3 + + addCard(Zone.BATTLEFIELD, playerB, "Bellows Lizard", 5); + // Whenever a creature an opponent controls dies, put a +1/+1 counter on Malakir Cullblade. + addCard(Zone.BATTLEFIELD, playerA, "Malakir Cullblade", 5); + + attack(3, playerA, "Nefashu"); + setStopAt(3, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + assertGraveyardCount(playerB, "Bellows Lizard", 5); + assertPowerToughness(playerA, "Malakir Cullblade", 6, 6, Filter.ComparisonScope.All); + assertTapped("Nefashu", true); + + assertLife(playerB, 15); + } + + /** + * Test that AI counters creatire spell + */ + @Test + @Ignore // counter spells don't seem to be cast by AI + public void testRewind() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); + // Counter target spell. Untap up to four lands. + addCard(Zone.HAND, playerA, "Rewind"); // {2}{U}{U} + + addCard(Zone.BATTLEFIELD, playerB, "Plains", 4); + // Renown 1 (When this creature deals combat damage to a player, if it isn't renowned, put a +1/+1 counter on it and it becomes renowned.) + // {W}{W}: Tap target creature. + addCard(Zone.HAND, playerB, "Kytheon's Irregulars", 1); + + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Kytheon's Irregulars"); + setStopAt(2, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerB, "Kytheon's Irregulars", 0); + assertGraveyardCount(playerB, "Kytheon's Irregulars", 1); + assertGraveyardCount(playerA, "Rewind", 1); + + assertTappedCount("Island", true, 0); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/AI/basic/TriggeredAbilityTest.java b/Mage.Tests/src/test/java/org/mage/test/AI/basic/TriggeredAbilityTest.java new file mode 100644 index 00000000000..16087622d1f --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/AI/basic/TriggeredAbilityTest.java @@ -0,0 +1,47 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.AI.basic; + +import org.mage.test.serverside.base.CardTestPlayerBaseAI; + +/** + * + * @author LevelX2 + */ +public class TriggeredAbilityTest extends CardTestPlayerBaseAI { + + /* + * + * TODO: Create tests and fix AI to be able to handle tested situations + * + * Tests to create: + * AI has the only one creature in play and plays a Gilt-Leaf Winnower. AI should select No if asked to use the destray effect becuase it targets the AI creature + * + * + */ +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/DeathtouchTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/DeathtouchTest.java index 72766b529a5..1f9a2f19cfb 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/DeathtouchTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/DeathtouchTest.java @@ -37,32 +37,31 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * @author LevelX2 */ public class DeathtouchTest extends CardTestPlayerBase { - + @Test public void simpleDeathtouchDuringCombat() { addCard(Zone.BATTLEFIELD, playerA, "Archangel of Thune"); // Creature - Rat 1/1 // Deathtouch addCard(Zone.BATTLEFIELD, playerB, "Typhoid Rats"); - - + attack(2, playerB, "Typhoid Rats"); block(2, playerA, "Archangel of Thune", "Typhoid Rats"); - + setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); execute(); - + assertLife(playerA, 23); assertLife(playerB, 20); - + assertGraveyardCount(playerA, "Archangel of Thune", 1); assertGraveyardCount(playerB, "Typhoid Rats", 1); } - + /** - * Checks if a creature getting damage from Marath abilitity dies - * from Deathtouch, if Marath is equiped with Deathtouch giving Equipment - * and Marath dies from removing the +1/+1 counters. + * Checks if a creature getting damage from Marath abilitity dies from + * Deathtouch, if Marath is equiped with Deathtouch giving Equipment and + * Marath dies from removing the +1/+1 counters. */ @Test public void testMarathWillOfTheWild() { @@ -73,21 +72,20 @@ public class DeathtouchTest extends CardTestPlayerBase { // Equipped creature has deathtouch and lifelink. addCard(Zone.BATTLEFIELD, playerA, "Basilisk Collar"); /* - {R}{G}{W} Legendary Creature - Elemental Beast - Marath, Will of the Wild enters the battlefield with a number of +1/+1 counters on - it equal to the amount of mana spent to cast it. - {X}, Remove X +1/+1 counters from Marath: Choose one - - * Put X +1/+1 counters on target creature - * Marath deals X damage to target creature or player - * Put an X/X green Elemental creature token onto the battlefield. X can't be 0 - */ + {R}{G}{W} Legendary Creature - Elemental Beast + Marath, Will of the Wild enters the battlefield with a number of +1/+1 counters on + it equal to the amount of mana spent to cast it. + {X}, Remove X +1/+1 counters from Marath: Choose one - + * Put X +1/+1 counters on target creature + * Marath deals X damage to target creature or player + * Put an X/X green Elemental creature token onto the battlefield. X can't be 0 + */ addCard(Zone.HAND, playerA, "Marath, Will of the Wild", 1); - + addCard(Zone.BATTLEFIELD, playerB, "Archangel of Thune"); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN , playerA, "Marath, Will of the Wild"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Marath, Will of the Wild"); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Equip {2}", "Marath, Will of the Wild"); activateAbility(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "{X},Remove X +1/+1 counters from Marath", "Archangel of Thune"); @@ -104,6 +102,45 @@ public class DeathtouchTest extends CardTestPlayerBase { assertLife(playerB, 20); } - + @Test + public void testMarathWillOfTheWildEleshNorn() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain"); + addCard(Zone.BATTLEFIELD, playerA, "Forest"); + addCard(Zone.BATTLEFIELD, playerA, "Plains"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 10); + + // Equipped creature has deathtouch and lifelink. + addCard(Zone.BATTLEFIELD, playerA, "Basilisk Collar"); + /* + {R}{G}{W} Legendary Creature - Elemental Beast + Marath, Will of the Wild enters the battlefield with a number of +1/+1 counters on + it equal to the amount of mana spent to cast it. + {X}, Remove X +1/+1 counters from Marath: Choose one - + * Put X +1/+1 counters on target creature + * Marath deals X damage to target creature or player + * Put an X/X green Elemental creature token onto the battlefield. X can't be 0 + */ + addCard(Zone.HAND, playerA, "Marath, Will of the Wild", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Elesh Norn, Grand Cenobite"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Marath, Will of the Wild"); + + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Equip {2}", "Marath, Will of the Wild"); + + activateAbility(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "{X},Remove X +1/+1 counters from Marath", "Elesh Norn, Grand Cenobite"); + setModeChoice(playerA, "2"); // Marath deals X damage to target creature or player + setChoice(playerA, "X=1"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Marath, Will of the Wild", 0); // died because he's 0/0 + assertPermanentCount(playerB, "Elesh Norn, Grand Cenobite", 0); // died from deathtouch + + assertLife(playerA, 21); // +1 from lifelink doing 1 damage with Marath to Elesh Norn + assertLife(playerB, 20); + + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/KickerTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/KickerTest.java index 2e7f90fdfa0..d669602b0bd 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/KickerTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/KickerTest.java @@ -328,4 +328,39 @@ public class KickerTest extends CardTestPlayerBase { } + /** + * Check that kicker condition does also work for kicker cards with multiple + * kicker options + * + */ + @Test + public void testKickerCondition() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 3); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 3); + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); + + // Kicker {1}{G} and/or {2}{U} + // When {this} enters the battlefield, if it was kicked with its {1}{G} kicker, destroy target creature with flying. + // When {this} enters the battlefield, if it was kicked with its {2}{U} kicker, draw two cards. + addCard(Zone.HAND, playerA, "Sunscape Battlemage", 1); // 2/2 {2}{W} + + addCard(Zone.BATTLEFIELD, playerB, "Birds of Paradise", 1); + addCard(Zone.BATTLEFIELD, playerB, "Island", 1); + // Counter target spell if it was kicked. + addCard(Zone.HAND, playerB, "Ertai's Trickery", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sunscape Battlemage"); + addTarget(playerA, "Birds of Paradise"); + setChoice(playerA, "Yes"); // {1}{G} destroy target creature with flying + setChoice(playerA, "Yes"); // {2}{U} draw two cards + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Ertai's Trickery", "Sunscape Battlemage"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerB, "Birds of Paradise", 1); + assertGraveyardCount(playerB, "Ertai's Trickery", 1); + assertGraveyardCount(playerA, "Sunscape Battlemage", 1); + + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/LandfallTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/LandfallTest.java index 5e3b1b177cc..e1eae68db04 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/LandfallTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/LandfallTest.java @@ -30,6 +30,7 @@ package org.mage.test.cards.abilities.keywords; import mage.abilities.keyword.IntimidateAbility; import mage.constants.PhaseStep; import mage.constants.Zone; +import org.junit.Ignore; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBase; @@ -37,22 +38,21 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author LevelX2 */ - public class LandfallTest extends CardTestPlayerBase { @Test public void testNormalUse() { - addCard(Zone.BATTLEFIELD, playerA, "Plains",3); - addCard(Zone.HAND, playerA, "Plains"); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 3); + addCard(Zone.HAND, playerA, "Plains"); // Instant - {1}{W} // Target player gains 4 life. - // Landfall - If you had a land enter the battlefield under your control this turn, that player gains 8 life instead. - addCard(Zone.HAND, playerA, "Rest for the Weary",2); - + // Landfall - If you had a land enter the battlefield under your control this turn, that player gains 8 life instead. + addCard(Zone.HAND, playerA, "Rest for the Weary", 2); + playLand(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Plains"); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Rest for the Weary"); - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerA, "Rest for the Weary"); setStopAt(2, PhaseStep.BEGIN_COMBAT); @@ -61,57 +61,59 @@ public class LandfallTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Plains", 4); assertGraveyardCount(playerA, "Rest for the Weary", 2); assertLife(playerA, 32); // + 8 from 1 turn + 4 from second turn - assertLife(playerB, 20); - - } + assertLife(playerB, 20); + + } + /** - * If you Hive Mind an opponent's Rest for the Weary and redirect its target to yourself when it's not your turn, - * the game spits out this message and rolls back to before Rest for the Weary was cast. - * + * If you Hive Mind an opponent's Rest for the Weary and redirect its target + * to yourself when it's not your turn, the game spits out this message and + * rolls back to before Rest for the Weary was cast. + * */ @Test public void testHiveMind() { - addCard(Zone.BATTLEFIELD, playerA, "Plains",2); - + addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); + // Whenever a player casts an instant or sorcery spell, each other player copies that spell. Each of those players may choose new targets for his or her copy. - addCard(Zone.BATTLEFIELD, playerB, "Hive Mind"); + addCard(Zone.BATTLEFIELD, playerB, "Hive Mind"); // Instant - {1}{W} // Target player gains 4 life. - // Landfall - If you had a land enter the battlefield under your control this turn, that player gains 8 life instead. - addCard(Zone.HAND, playerA, "Rest for the Weary",1); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Rest for the Weary"); + // Landfall - If you had a land enter the battlefield under your control this turn, that player gains 8 life instead. + addCard(Zone.HAND, playerA, "Rest for the Weary", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Rest for the Weary"); setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); assertGraveyardCount(playerA, "Rest for the Weary", 1); - assertLife(playerA, 24); - assertLife(playerB, 24); - - } - + assertLife(playerA, 24); + assertLife(playerB, 24); + + } + @Test public void testSurrakarMarauder() { - // Landfall - Whenever a land enters the battlefield under your control, Surrakar Marauder gains intimidate until end of turn. - addCard(Zone.BATTLEFIELD, playerA, "Surrakar Marauder",1); - addCard(Zone.HAND, playerA, "Plains"); - + // Landfall - Whenever a land enters the battlefield under your control, Surrakar Marauder gains intimidate until end of turn. + addCard(Zone.BATTLEFIELD, playerA, "Surrakar Marauder", 1); + addCard(Zone.HAND, playerA, "Plains"); + playLand(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Plains"); - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); assertPermanentCount(playerA, "Plains", 1); - + assertAbility(playerA, "Surrakar Marauder", IntimidateAbility.getInstance(), true); - - assertLife(playerA, 20); - assertLife(playerB, 20); - - } - + + assertLife(playerA, 20); + assertLife(playerB, 20); + + } + /** * Searing Blaze's landfall doesn't appear to be working. My opponent played * a mountain, then played searing blaze targeting my Tasigur, the Golden @@ -122,82 +124,98 @@ public class LandfallTest extends CardTestPlayerBase { public void testSearingBlaze() { // Searing Blaze deals 1 damage to target player and 1 damage to target creature that player controls. // Landfall - If you had a land enter the battlefield under your control this turn, Searing Blaze deals 3 damage to that player and 3 damage to that creature instead. - addCard(Zone.HAND, playerA, "Searing Blaze",1); - addCard(Zone.BATTLEFIELD, playerA, "Mountain",1); - addCard(Zone.HAND, playerA, "Mountain"); + addCard(Zone.HAND, playerA, "Searing Blaze", 1); + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); + addCard(Zone.HAND, playerA, "Mountain"); - addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion",1); + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); - playLand(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Mountain"); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Searing Blaze"); - - + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Searing Blaze"); + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); assertPermanentCount(playerA, "Mountain", 2); - assertGraveyardCount(playerA, "Searing Blaze" , 1); - - assertLife(playerA, 20); - assertLife(playerB, 17); - - assertGraveyardCount(playerB, "Silvercoat Lion" , 1); - - } + assertGraveyardCount(playerA, "Searing Blaze", 1); + + assertLife(playerA, 20); + assertLife(playerB, 17); + + assertGraveyardCount(playerB, "Silvercoat Lion", 1); + + } @Test public void testGroundswellWithoutLandfall() { // Target creature gets +2/+2 until end of turn. //Landfall - If you had a land enter the battlefield under your control this turn, that creature gets +4/+4 until end of turn instead. - addCard(Zone.HAND, playerB, "Groundswell",1); - addCard(Zone.BATTLEFIELD, playerB, "Forest",1); + addCard(Zone.HAND, playerB, "Groundswell", 1); + addCard(Zone.BATTLEFIELD, playerB, "Forest", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); - addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion",1); - attack(2, playerB, "Silvercoat Lion"); - castSpell(2, PhaseStep.DECLARE_ATTACKERS, playerB, "Groundswell", "Silvercoat Lion"); - - + castSpell(2, PhaseStep.DECLARE_ATTACKERS, playerB, "Groundswell", "Silvercoat Lion"); + setStopAt(2, PhaseStep.END_COMBAT); execute(); assertPermanentCount(playerB, "Forest", 1); - assertGraveyardCount(playerB, "Groundswell" , 1); + assertGraveyardCount(playerB, "Groundswell", 1); - assertPermanentCount(playerB, "Silvercoat Lion" , 1); + assertPermanentCount(playerB, "Silvercoat Lion", 1); assertPowerToughness(playerB, "Silvercoat Lion", 4, 4); - + assertLife(playerA, 16); // 2 + 4 - assertLife(playerB, 20); - } - + assertLife(playerB, 20); + } + + /* + 21:09: Turn 8 arucki (25 - 16) + 21:09: arucki draws a card + 21:09: Ability triggers: Sylvan Library [868] - At the beginning of your draw step, you may draw two additional cards. If you do, choose two cards in your hand drawn this turn. For each of those cards, pay 4 life or put the card on top of your library. + 21:09: arucki draws two cards + 21:09: arucki loses 4 life + 21:09: arucki pays 4 life to keep a card on hand + 21:09: arucki puts 1 card(s) back to library + 21:09: arucki plays Twilight Mire [f4d] + 21:10: arucki activates: Inkmoth Nexus [1b5] becomes a 1/1 Blinkmoth artifact creature with flying and infect until end of turn. It's still a land. (It deals damage to creatures in the form of -1/-1 counters and to players in the form of poison counters.). from Inkmoth Nexus [1b5] + 21:10: arucki casts Groundswell [b28] targeting Inkmoth Nexus [1b5] + 21:10: Ability triggers: Wild Defiance [990] - Whenever a creature you control becomes the target of an instant or sorcery spell, that creature gets +3/+3 until end of turn + 21:10: arucki puts Groundswell [b28] from stack into his or her graveyard + 21:10: arucki attacks with 1 creature + 21:10: Attacker: Inkmoth Nexus 1b5 unblocked + */ @Test + @Ignore public void testGroundswellWithLandfall() { // Target creature gets +2/+2 until end of turn. //Landfall - If you had a land enter the battlefield under your control this turn, that creature gets +4/+4 until end of turn instead. - addCard(Zone.HAND, playerB, "Groundswell",1); - addCard(Zone.HAND, playerB, "Forest"); + addCard(Zone.HAND, playerB, "Groundswell", 1); // Instant + addCard(Zone.BATTLEFIELD, playerB, "Forest"); + addCard(Zone.HAND, playerB, "Twilight Mire"); - addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion",1); + // Whenever a creature you control becomes the target of an instant or sorcery spell, that creature gets +3/+3 until end of turn. + addCard(Zone.BATTLEFIELD, playerB, "Wild Defiance", 1); - - playLand(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Forest"); + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); + + playLand(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Twilight Mire"); attack(2, playerB, "Silvercoat Lion"); - castSpell(2, PhaseStep.DECLARE_ATTACKERS, playerB, "Groundswell", "Silvercoat Lion"); - - + castSpell(2, PhaseStep.DECLARE_ATTACKERS, playerB, "Groundswell", "Silvercoat Lion"); + setStopAt(2, PhaseStep.END_COMBAT); execute(); - assertPermanentCount(playerB, "Forest", 1); - assertGraveyardCount(playerB, "Groundswell" , 1); + assertPermanentCount(playerB, "Twilight Mire", 1); + assertGraveyardCount(playerB, "Groundswell", 1); - assertPermanentCount(playerB, "Silvercoat Lion" , 1); - assertPowerToughness(playerB, "Silvercoat Lion", 6, 6); - - assertLife(playerA, 14); // 2 + 4 - assertLife(playerB, 20); - } + assertPermanentCount(playerB, "Silvercoat Lion", 1); + assertPowerToughness(playerB, "Silvercoat Lion", 9, 9); + + assertLife(playerA, 11); // 2 + 4 + 3 + assertLife(playerB, 20); + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/MorphTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/MorphTest.java index b3cc3a25c95..60991689d79 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/MorphTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/MorphTest.java @@ -39,28 +39,28 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author levelX2 */ - public class MorphTest extends CardTestPlayerBase { /** - * Tests if a creature with Morph is cast normal, it behaves as normal creature + * Tests if a creature with Morph is cast normal, it behaves as normal + * creature * */ @Test public void testCastMoprhCreatureWithoutMorph() { - /* - Pine Walker - Creature - Elemental - 5/5 - Morph {4}{G} (You may cast this card face down as a 2/2 creature for . Turn it face up any time for its morph cost.) - Whenever Pine Walker or another creature you control is turned face up, untap that creature. - */ + /* + Pine Walker + Creature - Elemental + 5/5 + Morph {4}{G} (You may cast this card face down as a 2/2 creature for . Turn it face up any time for its morph cost.) + Whenever Pine Walker or another creature you control is turned face up, untap that creature. + */ addCard(Zone.HAND, playerA, "Pine Walker"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 5); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "No"); // cast it normal as 5/5 - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); @@ -69,7 +69,6 @@ public class MorphTest extends CardTestPlayerBase { } - /** * Cast the creature face down as a 2/2 */ @@ -77,10 +76,10 @@ public class MorphTest extends CardTestPlayerBase { public void testCastFaceDown() { addCard(Zone.HAND, playerA, "Pine Walker"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); @@ -88,6 +87,7 @@ public class MorphTest extends CardTestPlayerBase { assertPowerToughness(playerA, "", 2, 2); } + /** * Test triggered turn face up ability of Pine Walker */ @@ -95,29 +95,29 @@ public class MorphTest extends CardTestPlayerBase { public void testTurnFaceUpTrigger() { addCard(Zone.HAND, playerA, "Pine Walker"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 5); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + attack(3, playerA, ""); - + activateAbility(3, PhaseStep.POSTCOMBAT_MAIN, playerA, "{4}{G}: Turn this face-down permanent face up."); setStopAt(3, PhaseStep.END_TURN); execute(); assertLife(playerB, 18); - + assertPermanentCount(playerA, "", 0); - assertPermanentCount(playerA, "Pine Walker", 1); + assertPermanentCount(playerA, "Pine Walker", 1); assertPowerToughness(playerA, "Pine Walker", 5, 5); assertTapped("Pine Walker", false); } - + /** - * Test that the triggered "turned face up" ability of Pine Walker does not trigger - * as long as Pine Walker is not turned face up. - * + * Test that the triggered "turned face up" ability of Pine Walker does not + * trigger as long as Pine Walker is not turned face up. + * */ @Test public void testDoesNotTriggerFaceDown() { @@ -127,34 +127,35 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerA, "Icefeather Aven"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); addCard(Zone.BATTLEFIELD, playerA, "Island", 3); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Icefeather Aven"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Icefeather Aven", NO_TARGET, "Pine Walker", StackClause.WHILE_NOT_ON_STACK); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + attack(3, playerA, ""); attack(3, playerA, ""); activateAbility(3, PhaseStep.DECLARE_BLOCKERS, playerA, "{1}{G}{U}: Turn this face-down permanent face up."); setChoice(playerA, "No"); // Don't use return permanent to hand effect - + setStopAt(3, PhaseStep.POSTCOMBAT_MAIN); execute(); assertLife(playerA, 20); assertLife(playerB, 16); - + assertHandCount(playerA, "Pine Walker", 0); assertHandCount(playerA, "Icefeather Aven", 0); assertPermanentCount(playerA, "", 1); - assertPermanentCount(playerA, "Icefeather Aven", 1); + assertPermanentCount(playerA, "Icefeather Aven", 1); assertTapped("Icefeather Aven", true); } /** - * Test that Morph creature do not trigger abilities with their face up attributes - * + * Test that Morph creature do not trigger abilities with their face up + * attributes + * */ @Test public void testMorphedRemovesAttributesCreature() { @@ -162,104 +163,106 @@ public class MorphTest extends CardTestPlayerBase { // Creature - Goblin Warrior // 2/2 // When Ponyback Brigade enters the battlefield or is turned face up, put three 1/1 red Goblin creature tokens onto the battlefield. - // Morph {2}{R}{W}{B}(You may cast this card face down as a 2/2 creature for . Turn it face up any time for its morph cost.) + // Morph {2}{R}{W}{B}(You may cast this card face down as a 2/2 creature for . Turn it face up any time for its morph cost.) addCard(Zone.HAND, playerA, "Ponyback Brigade"); addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); - + addCard(Zone.BATTLEFIELD, playerB, "Soldier of the Pantheon", 1); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Ponyback Brigade"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - assertLife(playerB, 20); // and not 21 - + assertLife(playerB, 20); // and not 21 + assertPermanentCount(playerA, "", 1); assertPermanentCount(playerB, "Soldier of the Pantheon", 1); } - - /** + + /** * Test to copy a morphed 2/2 creature - * + * */ @Test public void testCopyAMorphedCreature() { addCard(Zone.HAND, playerA, "Pine Walker"); addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); - + // Clever Impersonator {2}{U}{U} // Creature - Shapeshifter // 0/0 // You may have Clever Impersonator enter the battlefield as a copy of any nonland permanent on the battlefield. addCard(Zone.HAND, playerB, "Clever Impersonator", 1); addCard(Zone.BATTLEFIELD, playerB, "Island", 4); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Clever Impersonator"); setChoice(playerB, "Yes"); // use to copy a nonland permanent addTarget(playerB, ""); // Morphed creature - + setStopAt(2, PhaseStep.BEGIN_COMBAT); execute(); assertLife(playerB, 20); - - assertPermanentCount(playerA, "", 1); - assertPowerToughness(playerA, "", 2,2); - assertPermanentCount(playerB, "", 1); - assertPowerToughness(playerB, "", 2,2); - } - + assertPermanentCount(playerA, "", 1); + assertPowerToughness(playerA, "", 2, 2); + assertPermanentCount(playerB, "", 1); + assertPowerToughness(playerB, "", 2, 2); + + } + /** - * - * + * + * */ @Test public void testPineWalkerWithUnboostEffect() { addCard(Zone.HAND, playerA, "Pine Walker"); addCard(Zone.BATTLEFIELD, playerA, "Forest", 8); - + // Doomwake Giant {4}{B} // Creature - Giant // 4/6 // Constellation - When Doomwake Giant or another enchantment enters the battlefield under your control, creatures your opponents control get -1/-1 until end of turn. addCard(Zone.HAND, playerB, "Doomwake Giant", 1); addCard(Zone.BATTLEFIELD, playerB, "Swamp", 5); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pine Walker"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Doomwake Giant"); // activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerA, "{2}{R}{W}{B}: Turn this face-down permanent face up."); activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerA, "{4}{G}: Turn this face-down permanent face up."); - + setStopAt(2, PhaseStep.END_TURN); execute(); assertLife(playerB, 20); - - assertHandCount(playerA, "Pine Walker", 0); + + assertHandCount(playerA, "Pine Walker", 0); assertHandCount(playerB, "Doomwake Giant", 0); assertPermanentCount(playerA, "", 0); assertPermanentCount(playerB, "Doomwake Giant", 1); assertPermanentCount(playerA, "Pine Walker", 1); - assertPowerToughness(playerA, "Pine Walker", 4,4); + assertPowerToughness(playerA, "Pine Walker", 4, 4); + + } - } /** - * If a morph is on the table and an enemy Doomwake Giant comes down, the morph goes - * down to 1/1 correctly. If you unmorph the 2/2 and is also a 2/2 after umorphing, - * the morph will be erroneously reduced to 0/0 and die. - * + * If a morph is on the table and an enemy Doomwake Giant comes down, the + * morph goes down to 1/1 correctly. If you unmorph the 2/2 and is also a + * 2/2 after umorphing, the morph will be erroneously reduced to 0/0 and + * die. + * */ @Test public void testDoomwakeGiantEffect() { @@ -267,38 +270,40 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Swamp", 6); addCard(Zone.BATTLEFIELD, playerA, "Plains", 6); addCard(Zone.BATTLEFIELD, playerA, "Mountain", 6); - + // Doomwake Giant {4}{B} // Creature - Giant // 4/6 // Constellation - When Doomwake Giant or another enchantment enters the battlefield under your control, creatures your opponents control get -1/-1 until end of turn. addCard(Zone.HAND, playerB, "Doomwake Giant", 1); addCard(Zone.BATTLEFIELD, playerB, "Swamp", 5); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Ponyback Brigade"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Doomwake Giant"); activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerA, "{2}{R}{W}{B}: Turn this face-down permanent face up."); - + setStopAt(2, PhaseStep.END_TURN); execute(); assertLife(playerB, 20); - - assertHandCount(playerA, "Ponyback Brigade", 0); + + assertHandCount(playerA, "Ponyback Brigade", 0); assertHandCount(playerB, "Doomwake Giant", 0); assertPermanentCount(playerA, "", 0); assertPermanentCount(playerA, "Goblin", 3); - assertPowerToughness(playerA, "Goblin", 1,1,Filter.ComparisonScope.Any); + assertPowerToughness(playerA, "Goblin", 1, 1, Filter.ComparisonScope.Any); assertPermanentCount(playerB, "Doomwake Giant", 1); assertPermanentCount(playerA, "Ponyback Brigade", 1); - assertPowerToughness(playerA, "Ponyback Brigade", 1,1); + assertPowerToughness(playerA, "Ponyback Brigade", 1, 1); } + /** - * Clone a Morph creature that was cast face down and meanwhile was turned face up + * Clone a Morph creature that was cast face down and meanwhile was turned + * face up * */ @Test @@ -326,12 +331,13 @@ public class MorphTest extends CardTestPlayerBase { assertHandCount(playerA, "Clone", 0); assertPermanentCount(playerA, "Sagu Mauler", 2); - assertPowerToughness(playerA, "Sagu Mauler", 6,6,Filter.ComparisonScope.Any); + assertPowerToughness(playerA, "Sagu Mauler", 6, 6, Filter.ComparisonScope.Any); } + /** - * Check that you can't counter a creature cast for it morph costs - * with Disdainful Stroke if it's normal cmc > 3 + * Check that you can't counter a creature cast for it morph costs with + * Disdainful Stroke if it's normal cmc > 3 * */ @Test @@ -366,16 +372,17 @@ public class MorphTest extends CardTestPlayerBase { } /** - * Check that an effect like "Target creature and all other creatures with the same name" does - * only effect one face down creature, also if multiple on the battlefield. Because they have no - * name, they don't have the same name. + * Check that an effect like "Target creature and all other creatures with + * the same name" does only effect one face down creature, also if multiple + * on the battlefield. Because they have no name, they don't have the same + * name. * */ @Test public void testEchoingDecaySameNameEffect() { // Sagu Mauler 6/6 - Creature - Beast // Trample, hexproof - // Morph {3}{G}{B} (You may cast this card face down as a 2/2 creature for . Turn it face up any time for its morph cost.) + // Morph {3}{G}{B} (You may cast this card face down as a 2/2 creature for {3}. Turn it face up any time for its morph cost.) addCard(Zone.HAND, playerA, "Sagu Mauler", 2); addCard(Zone.BATTLEFIELD, playerA, "Forest", 6); @@ -387,7 +394,7 @@ public class MorphTest extends CardTestPlayerBase { castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sagu Mauler"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sagu Mauler"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sagu Mauler", NO_TARGET, "Sagu Mauler", StackClause.WHILE_NOT_ON_STACK); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Echoing Decay", ""); @@ -405,11 +412,11 @@ public class MorphTest extends CardTestPlayerBase { } /** - * I played a Akroma, Angel of Fury face down, and my opponent tried to counter it. - * The counter failed and Akroma face successfully play face down, when it should have - * been countered. (The card text on akroma should not prevent her from being countered). + * I played a Akroma, Angel of Fury face down, and my opponent tried to + * counter it. The counter failed and Akroma face successfully play face + * down, when it should have been countered. (The card text on akroma should + * not prevent her from being countered). */ - @Test public void testRuleModifyingEffectsFromManifestedCardWontBeAppliedAbilities() { addCard(Zone.HAND, playerA, "Akroma, Angel of Fury", 1); @@ -418,7 +425,6 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Counterspell", 1); addCard(Zone.BATTLEFIELD, playerB, "Island", 2); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Akroma, Angel of Fury"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Counterspell", "Akroma, Angel of Fury"); @@ -432,11 +438,11 @@ public class MorphTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Akroma, Angel of Fury", 1); } - /** - * Check if a face down Morph creature gets exiled, it will - * be face up in exile zone. - */ + /** + * Check if a face down Morph creature gets exiled, it will be face up in + * exile zone. + */ @Test public void testExileFaceDownCreature() { addCard(Zone.HAND, playerA, "Birchlore Rangers", 1); @@ -445,7 +451,6 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Swords to Plowshares", 1); addCard(Zone.BATTLEFIELD, playerB, "Plains", 1); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Birchlore Rangers"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature @@ -460,8 +465,7 @@ public class MorphTest extends CardTestPlayerBase { assertGraveyardCount(playerB, "Swords to Plowshares", 1); assertExileCount("Birchlore Rangers", 1); - - for (Card card: currentGame.getExile().getAllCards(currentGame)) { + for (Card card : currentGame.getExile().getAllCards(currentGame)) { if (card.getName().equals("Birchlore Rangers")) { Assert.assertEquals("Birchlore Rangers has to be face up in exile", false, card.isFaceDown(currentGame)); break; @@ -469,11 +473,11 @@ public class MorphTest extends CardTestPlayerBase { } } - /** - * Check that a DiesTriggeredAbility of a creature does not trigger - * if the creature dies face down - */ + /** + * Check that a DiesTriggeredAbility of a creature does not trigger if the + * creature dies face down + */ @Test public void testDiesTriggeredDoesNotTriggerIfFaceDown() { // Flying @@ -486,7 +490,6 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Lightning Bolt", 1); addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Ashcloud Phoenix"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature @@ -501,20 +504,19 @@ public class MorphTest extends CardTestPlayerBase { assertGraveyardCount(playerB, "Lightning Bolt", 1); assertGraveyardCount(playerA, "Ashcloud Phoenix", 1); - - for (Card card: playerA.getGraveyard().getCards(currentGame)) { + for (Card card : playerA.getGraveyard().getCards(currentGame)) { if (card.getName().equals("Ashcloud Phoenix")) { Assert.assertEquals("Ashcloud Phoenix has to be face up in graveyard", false, card.isFaceDown(currentGame)); break; } } - } - /** - * Check that a DiesTriggeredAbility of a creature does not trigger - * if the creature dies face down in combat - */ + } + /** + * Check that a DiesTriggeredAbility of a creature does not trigger if the + * creature dies face down in combat + */ @Test public void testDiesTriggeredDoesNotTriggerInCombatIfFaceDown() { // Flying @@ -524,24 +526,22 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerA, "Ashcloud Phoenix", 1); addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); - // First strike, forestwalk, vigilance + // First strike, forestwalk, vigilance // (This creature deals combat damage before creatures without first strike, it can't be blocked as long as defending player controls a Forest, and attacking doesn't cause this creature to tap.) addCard(Zone.BATTLEFIELD, playerB, "Mirri, Cat Warrior"); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Ashcloud Phoenix"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature attack(2, playerB, "Mirri, Cat Warrior"); - block(2, playerA, "", "Mirri, Cat Warrior"); + block(2, playerA, "", "Mirri, Cat Warrior"); setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); execute(); assertGraveyardCount(playerA, "Ashcloud Phoenix", 1); - - for (Card card: playerA.getGraveyard().getCards(currentGame)) { + for (Card card : playerA.getGraveyard().getCards(currentGame)) { if (card.getName().equals("Ashcloud Phoenix")) { Assert.assertEquals("Ashcloud Phoenix has to be face up in graveyard", false, card.isFaceDown(currentGame)); break; @@ -551,13 +551,14 @@ public class MorphTest extends CardTestPlayerBase { assertLife(playerA, 20); assertLife(playerB, 20); - } - /** - * Supplant Form does not work correctly with morph creatures. If you bounce and copy - * a face-down morph, the created token should be a colorless 2/2, but the token created - * is instead the face-up of what the morph creature was. - */ + } + /** + * Supplant Form does not work correctly with morph creatures. If you bounce + * and copy a face-down morph, the created token should be a colorless 2/2, + * but the token created is instead the face-up of what the morph creature + * was. + */ @Test public void testSupplantFormWithMorphedCreature() { addCard(Zone.HAND, playerA, "Akroma, Angel of Fury", 1); @@ -567,7 +568,6 @@ public class MorphTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Supplant Form", 1); addCard(Zone.BATTLEFIELD, playerB, "Island", 6); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Akroma, Angel of Fury"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Supplant Form", ""); @@ -579,18 +579,17 @@ public class MorphTest extends CardTestPlayerBase { assertGraveyardCount(playerB, "Supplant Form", 1); assertHandCount(playerA, "Akroma, Angel of Fury", 1); - + assertPermanentCount(playerB, "Akroma, Angel of Fury", 0); assertPermanentCount(playerB, "", 1); assertPowerToughness(playerB, "", 2, 2); - } - - /** - * Dragonlord Kolaghan passive of 10 damage works when you play a morph creature - * and it isn't suposed to. Because it is nameless. - */ + } + /** + * Dragonlord Kolaghan passive of 10 damage works when you play a morph + * creature and it isn't suposed to. Because it is nameless. + */ @Test public void testDragonlordKolaghan() { addCard(Zone.GRAVEYARD, playerA, "Akroma, Angel of Fury", 1); @@ -602,7 +601,6 @@ public class MorphTest extends CardTestPlayerBase { // Whenever an opponent casts a creature or planeswalker spell with the same name as a card in his or her graveyard, that player loses 10 life. addCard(Zone.BATTLEFIELD, playerB, "Dragonlord Kolaghan", 1); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Akroma, Angel of Fury"); setChoice(playerA, "Yes"); // cast it face down as 2/2 creature @@ -610,8 +608,8 @@ public class MorphTest extends CardTestPlayerBase { execute(); assertLife(playerA, 20); - + assertPermanentCount(playerA, "", 1); - } + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RecoverTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RecoverTest.java new file mode 100644 index 00000000000..41b6b4470c2 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RecoverTest.java @@ -0,0 +1,105 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.abilities.keywords; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class RecoverTest extends CardTestPlayerBase { + + /** + * 702.58a Recover is a triggered ability that functions only while the card + * with recover is in a player’s graveyard. “Recover [cost]” means “When a + * creature is put into your graveyard from the battlefield, you may pay + * [cost]. If you do, return this card from your graveyard to your hand. + * Otherwise, exile this card.” + */ + @Test + public void testReturnToHand() { + addCard(Zone.BATTLEFIELD, playerA, "Plains", 4); + // You gain 4 life. + // Recover {1}{W} + addCard(Zone.HAND, playerA, "Sun's Bounty"); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); + addCard(Zone.HAND, playerB, "Lightning Bolt", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sun's Bounty"); + + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Lightning Bolt", "Silvercoat Lion"); + setChoice(playerA, "Yes"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertGraveyardCount(playerB, "Lightning Bolt", 1); + assertHandCount(playerA, "Sun's Bounty", 1); + assertGraveyardCount(playerA, "Silvercoat Lion", 1); + + assertLife(playerA, 24); + + assertTappedCount("Plains", true, 4); + + } + + @Test + public void testGoingToExile() { + addCard(Zone.BATTLEFIELD, playerA, "Plains", 4); + // You gain 4 life. + // Recover {1}{W} + addCard(Zone.HAND, playerA, "Sun's Bounty"); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); + addCard(Zone.HAND, playerB, "Lightning Bolt", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sun's Bounty"); + + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Lightning Bolt", "Silvercoat Lion"); + setChoice(playerA, "No"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertTappedCount("Plains", true, 2); + + assertGraveyardCount(playerB, "Lightning Bolt", 1); + assertExileCount("Sun's Bounty", 1); + assertGraveyardCount(playerA, "Silvercoat Lion", 1); + + assertLife(playerA, 24); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RetraceTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RetraceTest.java index 8a056cbecfd..190d8e44776 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RetraceTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RetraceTest.java @@ -36,19 +36,16 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author LevelX2 */ - public class RetraceTest extends CardTestPlayerBase { /** - * 702.78. Retrace - * 702.78a Retrace appears on some instants and sorceries. It represents a static ability - * that functions while the card is in a player's graveyard. "Retrace" means "You may cast - * this card from your graveyard by discarding a land card as an additional cost to cast it." - * Casting a spell using its retrace ability follows the rules for paying additional costs - * in rules 601.2b and 601.2e-g. + * 702.78. Retrace 702.78a Retrace appears on some instants and sorceries. + * It represents a static ability that functions while the card is in a + * player's graveyard. "Retrace" means "You may cast this card from your + * graveyard by discarding a land card as an additional cost to cast it." + * Casting a spell using its retrace ability follows the rules for paying + * additional costs in rules 601.2b and 601.2e-g. */ - - @Test public void SimpleRetrace() { addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); @@ -60,16 +57,16 @@ public class RetraceTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Silvercoat Lion", 1); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Raven's Crime", playerB); - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - assertGraveyardCount(playerA,"Raven's Crime", 1); - assertGraveyardCount(playerA,"Swamp", 1); - - assertGraveyardCount(playerB,"Silvercoat Lion", 1); + assertGraveyardCount(playerA, "Raven's Crime", 1); + assertGraveyardCount(playerA, "Swamp", 1); + + assertGraveyardCount(playerB, "Silvercoat Lion", 1); } - + /** * Test that it does cost {B}{1} + land discard */ @@ -86,14 +83,14 @@ public class RetraceTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Silvercoat Lion", 1); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Raven's Crime", playerB); - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - assertGraveyardCount(playerA,"Raven's Crime", 1); - assertGraveyardCount(playerA,"Swamp", 0); // because not enough mana - - assertGraveyardCount(playerB,"Silvercoat Lion", 0); // because not enough mana + assertGraveyardCount(playerA, "Raven's Crime", 1); + assertGraveyardCount(playerA, "Swamp", 0); // because not enough mana + + assertGraveyardCount(playerB, "Silvercoat Lion", 0); // because not enough mana } /** @@ -112,14 +109,41 @@ public class RetraceTest extends CardTestPlayerBase { addCard(Zone.HAND, playerB, "Silvercoat Lion", 1); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Raven's Crime", playerB); - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - assertGraveyardCount(playerA,"Raven's Crime", 1); - assertGraveyardCount(playerA,"Swamp", 1); - - assertGraveyardCount(playerB,"Silvercoat Lion", 1); + assertGraveyardCount(playerA, "Raven's Crime", 1); + assertGraveyardCount(playerA, "Swamp", 1); + + assertGraveyardCount(playerB, "Silvercoat Lion", 1); + } + + /** + * I noticed the other day that I was not able to cast Worm Harvest from the + * graveyard. I'm not sure if this is an issue with all cards with the + * "retrace" ability but I figured it should be mentioned! + */ + @Test + public void RetraceCastFromGraveyard() { + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 5); + + // Target player discards a card. + // Retrace + addCard(Zone.GRAVEYARD, playerA, "Worm Harvest"); + addCard(Zone.GRAVEYARD, playerA, "Swamp", 2); + addCard(Zone.HAND, playerA, "Mountain", 1); + + // Put a 1/1 black and green Worm creature token onto the battlefield for each land card in your graveyard. + // Retrace (You may cast this card from your graveyard by discarding a land card in addition to paying its other costs.) + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Worm Harvest"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Worm", 3); + + assertGraveyardCount(playerA, "Mountain", 1); + } - } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RippleTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RippleTest.java new file mode 100644 index 00000000000..4217495e540 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/RippleTest.java @@ -0,0 +1,112 @@ +package org.mage.test.cards.abilities.keywords; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * @author klayhamn + */ +public class RippleTest extends CardTestPlayerBase { + + /** + * 702.59.Ripple + * 702.59a Ripple is a triggered ability that functions only while the card with ripple is on the stack. “Ripple N” means + * “When you cast this spell, you may reveal the top N cards of your library, or, if there are fewer than N cards in your + * library, you may reveal all the cards in your library. If you reveal cards from your library this way, you may cast any + * of those cards with the same name as this spell without paying their mana costs, then put all revealed cards not cast + * this way on the bottom of your library in any order.” + * 702.59b If a spell has multiple instances of ripple, each triggers separately. + */ + + @Test + public void testRippleWhenSameCardNotFound() { + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 4); + addCard(Zone.HAND, playerA, "Surging Dementia",2 ); + addCard(Zone.LIBRARY, playerA, "Swamp", 4); + + + addCard(Zone.HAND, playerB, "Island", 3); + addCard(Zone.LIBRARY, playerB, "Island", 3); + + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Surging Dementia", playerB); + setChoice(playerA, "Yes"); + + setStopAt(2, PhaseStep.END_TURN); + + execute(); + + assertHandCount(playerB, 3); // should have 1 less + assertHandCount(playerA, 1); // after cast, one remains + + assertGraveyardCount(playerA, "Surging Dementia", 1); // 1 cast + assertGraveyardCount(playerB, "Island", 1); // 1 discarded + } + + @Test + public void testRippleWhenSameCardFoundOnce() { + + removeAllCardsFromLibrary(playerA); + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 4); + addCard(Zone.HAND, playerA, "Surging Dementia",2 ); + addCard(Zone.LIBRARY, playerA, "Surging Dementia",1); + addCard(Zone.LIBRARY, playerA, "Swamp", 3); + + + addCard(Zone.HAND, playerB, "Island", 3); + addCard(Zone.LIBRARY, playerB, "Island", 3); + + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Surging Dementia", playerB); + setChoice(playerA, "Yes"); + addTarget(playerA, playerB); + + setStopAt(2, PhaseStep.END_TURN); + + execute(); + + assertHandCount(playerB, 2); // should have 2 less + assertHandCount(playerA, 1); // after cast, one remains in hand + assertGraveyardCount(playerA, "Surging Dementia", 2); // 2 were cast + assertGraveyardCount(playerB, "Island", 2); // 2 were discarded + + } + + @Test + public void testRippleWhenSameCardFoundMoreThanOnce() { + + + removeAllCardsFromLibrary(playerA); + skipInitShuffling(); + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 4); + addCard(Zone.HAND, playerA, "Surging Dementia",2 ); + + addCard(Zone.LIBRARY, playerA, "Surging Dementia",1); + addCard(Zone.LIBRARY, playerA, "Swamp", 2); + addCard(Zone.LIBRARY, playerA, "Surging Dementia",1); + addCard(Zone.LIBRARY, playerA, "Swamp", 2); + + + addCard(Zone.HAND, playerB, "Island", 3); + addCard(Zone.LIBRARY, playerB, "Island", 3); + + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Surging Dementia", playerB); + setChoice(playerA, "Yes"); + addTarget(playerA, playerB); + + setStopAt(2, PhaseStep.END_TURN); + + execute(); + + assertHandCount(playerB, 1); // should have 3 less + assertHandCount(playerA, 1); // after cast, one remains in hand + assertGraveyardCount(playerA, "Surging Dementia", 3); // 3 were cast + assertGraveyardCount(playerB, "Island", 3); // 3 were discarded + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/StormTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/StormTest.java index 6caa1dcf763..fbefd4b0063 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/StormTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/keywords/StormTest.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package org.mage.test.cards.abilities.keywords; import mage.constants.PhaseStep; @@ -41,23 +40,20 @@ import org.mage.test.serverside.base.CardTestPlayerBase; public class StormTest extends CardTestPlayerBase { /** - * 702.39. Storm - * 702.39a Storm is a triggered ability that functions on the stack. “Storm” means “When you cast this - * spell, put a copy of it onto the stack for each other spell that was cast before it this turn. If the + * 702.39. Storm 702.39a Storm is a triggered ability that functions on the + * stack. “Storm” means “When you cast this spell, put a copy of it onto the + * stack for each other spell that was cast before it this turn. If the * spell has any targets, you may choose new targets for any of the copies.” - * 702.39b If a spell has multiple instances of storm, each triggers separately. - * + * 702.39b If a spell has multiple instances of storm, each triggers + * separately. + * */ - /** - * Grapeshot - * Sorcery, 1R (2) - * Grapeshot deals 1 damage to target creature or player. - * Storm (When you cast this spell, copy it for each spell cast before it - * this turn. You may choose new targets for the copies.) - * + * Grapeshot Sorcery, 1R (2) Grapeshot deals 1 damage to target creature or + * player. Storm (When you cast this spell, copy it for each spell cast + * before it this turn. You may choose new targets for the copies.) + * */ - @Test public void testStorm1x() { addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); @@ -105,7 +101,7 @@ public class StormTest extends CardTestPlayerBase { assertLife(playerB, 7); } - + @Test public void testStorm4x() { addCard(Zone.BATTLEFIELD, playerA, "Mountain", 6); @@ -123,7 +119,7 @@ public class StormTest extends CardTestPlayerBase { assertLife(playerB, 3); } - + @Test public void testNoStorm() { addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); @@ -136,13 +132,13 @@ public class StormTest extends CardTestPlayerBase { assertLife(playerB, 19); } - + /** - * If a spell with storm gets countered, the strom trigger is also stifled, which isn't how its supposed to work. - * For example a Chalic of the Void set to 1 counters Flusterstorm and also counters the storm trigger, which shouldn't happen + * If a spell with storm gets countered, the strom trigger is also stifled, + * which isn't how its supposed to work. For example a Chalic of the Void + * set to 1 counters Flusterstorm and also counters the storm trigger, which + * shouldn't happen */ - - @Test public void testStormSpellCountered() { addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); @@ -155,20 +151,21 @@ public class StormTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerB, "Island", 2); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", playerB); - + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Grapeshot", playerB); castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Counterspell", "Grapeshot"); - + setStopAt(1, PhaseStep.END_TURN); execute(); assertLife(playerB, 16); // 3 (Lightning Bolt) + 1 from Storm copied Grapeshot } - + /** - * I provide a game log fo the issue with storm mentioned earlier. I guess Pyromancer Ascension is a culprit. - * - * + * I provide a game log fo the issue with storm mentioned earlier. I guess + * Pyromancer Ascension is a culprit. + * + * */ @Test public void testStormAndPyromancerAscension() { @@ -178,7 +175,7 @@ public class StormTest extends CardTestPlayerBase { // Whenever you cast an instant or sorcery spell while Pyromancer Ascension has two or more quest counters on it, you may copy that spell. You may choose new targets for the copy. addCard(Zone.BATTLEFIELD, playerA, "Pyromancer Ascension", 1); // Grapeshot deals 1 damage to target creature or player. - Sorcery {1}{R} - // Storm (When you cast this spell, copy it for each spell cast before it this turn. You may choose new targets for the copies.) + // Storm (When you cast this spell, copy it for each spell cast before it this turn. You may choose new targets for the copies.) addCard(Zone.LIBRARY, playerA, "Grapeshot", 2); skipInitShuffling(); // Look at the top two cards of your library. Put one of them into your hand and the other on the bottom of your library. @@ -198,5 +195,102 @@ public class StormTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Grapeshot", 1); assertCounterCount("Pyromancer Ascension", CounterType.QUEST, 2); assertLife(playerB, 8); // 6 from the Shocks + 5 from Grapeshot + 1 from Pyromancer Ascencsion copy - } + } + + /** + * I provide a game log fo the issue with storm mentioned earlier. I guess + * Pyromancer Ascension is a culprit. + * + * + */ + @Test + public void testStormAndFlashback() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 8); + addCard(Zone.BATTLEFIELD, playerA, "Island", 1); + // Geistflame deals 1 damage to target creature or player. + // Flashback {3}{R} (You may cast this card from your graveyard for its flashback cost. Then exile it.) + addCard(Zone.HAND, playerA, "Geistflame", 2); // {R} + addCard(Zone.LIBRARY, playerA, "Grapeshot", 2); + skipInitShuffling(); + // Look at the top two cards of your library. Put one of them into your hand and the other on the bottom of your library. + addCard(Zone.HAND, playerA, "Sleight of Hand"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sleight of Hand"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Geistflame", playerB); + activateAbility(1, PhaseStep.BEGIN_COMBAT, playerA, "Flashback {3}{R}"); + addTarget(playerA, playerB); + castSpell(1, PhaseStep.END_COMBAT, playerA, "Geistflame", playerB); + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Grapeshot", playerB); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertExileCount("Geistflame", 1); + assertGraveyardCount(playerA, "Geistflame", 1); + assertGraveyardCount(playerA, "Grapeshot", 1); + assertLife(playerB, 12); // 3 from the Geistflame + 5 from Grapeshot + } + + /* + * I cast Wheel of Fortune. (1st) + * I cast Mox Emerald. (2nd) + * I cast Turnabout. (3rd) + * I cast Yawgmoth's Will. (4th) + * I cast Palinchron from graveyard. (5th) + * I cast Mind's Desire from graveyard. Storm makes 2 + * copies (instead of 5). (6th) I cast Turnabout from graveyard. (7th) I + * cast Golgari Signet from exile. (8th) I cast Empty the Warrens. Storm + * makes 5 copies (instead of 8). (9th) + * + */ + @Test + public void testStormYawgmothsWill() { + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 3); + addCard(Zone.BATTLEFIELD, playerA, "Island", 10); + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); + // Each player discards his or her hand, + // then draws seven cards. + addCard(Zone.HAND, playerA, "Wheel of Fortune", 1); // {2}{R} + addCard(Zone.LIBRARY, playerA, "Mox Emerald", 1); + // Choose artifact, creature, or land. Tap all untapped permanents of the chosen type target player controls, or untap all tapped permanents of that type that player controls. + addCard(Zone.LIBRARY, playerA, "Turnabout", 1); // {2}{U}{U} + + // Until end of turn, you may play cards from your graveyard. + // If a card would be put into your graveyard from anywhere this turn, exile that card instead. + addCard(Zone.LIBRARY, playerA, "Yawgmoth's Will", 1); // {2}{B} + skipInitShuffling(); + + // Flying + // When Palinchron enters the battlefield, untap up to seven lands. + // {2}{U}{U}: Return Palinchron to its owner's hand. + addCard(Zone.HAND, playerA, "Palinchron", 1); // {5}{U}{U} + // Shuffle your library. Then exile the top card of your library. Until end of turn, you may play that card without paying its mana cost. + // Storm + addCard(Zone.HAND, playerA, "Mind's Desire", 1); // {4}{U}{U} + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Wheel of Fortune"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Mox Emerald"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Turnabout"); + setChoice(playerA, "Land"); + setChoice(playerA, "Untap"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Yawgmoth's Will"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Palinchron"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Mind's Desire"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Wheel of Fortune", 1); + assertPermanentCount(playerA, "Mox Emerald", 1); + assertGraveyardCount(playerA, "Turnabout", 1); + assertPermanentCount(playerA, "Palinchron", 1); + + assertExileCount("Yawgmoth's Will", 1); + assertExileCount("Mind's Desire", 1); + + assertExileCount(playerA, 8); // 6 from Mind's Desire and the Desire and the Yawgmoth's Will + + } + } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/oneshot/counterspell/NotOfThisWorldTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/oneshot/counterspell/NotOfThisWorldTest.java new file mode 100644 index 00000000000..41d3992a219 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/oneshot/counterspell/NotOfThisWorldTest.java @@ -0,0 +1,72 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.abilities.oneshot.counterspell; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class NotOfThisWorldTest extends CardTestPlayerBase { + + /** + * Not of This World doesn't work when trying to counter a triggerd ability + * from The Abyss targeting your owned and controlled Ruhan of the Fomori . + * At the time I didn't have any mana open, but Ruhan of the Fomori should + * qualify for the alternative casting cost (7 less) or Not of This World. + */ + @Test + public void testCounterFirstSpell() { + // At the beginning of each player's upkeep, destroy target nonartifact creature that player controls of his or her choice. It can't be regenerated. + addCard(Zone.BATTLEFIELD, playerA, "The Abyss", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Island", 7); + // Counter target spell or ability that targets a permanent you control. + // Not of This World costs {7} less to cast if it targets a spell or ability that targets a creature you control with power 7 or greater. + addCard(Zone.HAND, playerB, "Not of This World"); + + // At the beginning of combat on your turn, choose an opponent at random. Ruhan of the Fomori attacks that player this combat if able. + addCard(Zone.BATTLEFIELD, playerB, "Ruhan of the Fomori", 1); // 7/7 + + addTarget(playerB, "Ruhan of the Fomori"); + castSpell(2, PhaseStep.UPKEEP, playerB, "Not of This World", "stack ability (At the beginning of each player's upkeep"); + + setStopAt(2, PhaseStep.PRECOMBAT_MAIN); + execute(); + + assertGraveyardCount(playerB, "Not of This World", 1); + assertPermanentCount(playerB, "Ruhan of the Fomori", 1); + + assertTapped("Island", false); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/abilities/other/ThrummingStoneTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/other/ThrummingStoneTest.java new file mode 100644 index 00000000000..1b84ec26f63 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/abilities/other/ThrummingStoneTest.java @@ -0,0 +1,59 @@ +package org.mage.test.cards.abilities.other; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * @author klayhamn + */ +public class ThrummingStoneTest extends CardTestPlayerBase { + + @Test + public void testApplyForNoneRippleCardsWhenSingleRipple() throws Exception { + + removeAllCardsFromLibrary(playerA); + + addCard(Zone.BATTLEFIELD, playerA, "Thrumming Stone"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp"); + addCard(Zone.HAND, playerA, "Shadowborn Apostle"); + + addCard(Zone.LIBRARY, playerA, "Shadowborn Apostle", 1); + addCard(Zone.LIBRARY, playerA, "Swamp", 3); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Shadowborn Apostle"); + setChoice(playerA, "Yes"); + + setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + assertPermanentCount(playerA, "Shadowborn Apostle", 2); + + } + + @Test + public void testApplyForNoneRippleCardsWhenMultiRipple() throws Exception { + + removeAllCardsFromLibrary(playerA); + + addCard(Zone.BATTLEFIELD, playerA, "Thrumming Stone"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp"); + addCard(Zone.HAND, playerA, "Shadowborn Apostle"); + + addCard(Zone.LIBRARY, playerA, "Shadowborn Apostle"); + addCard(Zone.LIBRARY, playerA, "Swamp", 3); + addCard(Zone.LIBRARY, playerA, "Shadowborn Apostle"); + + skipInitShuffling(); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Shadowborn Apostle"); + setChoice(playerA, "Yes"); + + setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + assertPermanentCount(playerA, "Shadowborn Apostle", 3); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/continuous/BoostEnchantedTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/continuous/BoostEnchantedTest.java new file mode 100644 index 00000000000..f7db7fd18d7 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/continuous/BoostEnchantedTest.java @@ -0,0 +1,92 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.continuous; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class BoostEnchantedTest extends CardTestPlayerBase { + + @Test + public void testFirebreathingNormal() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion", 1); + // {R}: Enchanted creature gets +1/+0 until end of turn. + addCard(Zone.HAND, playerA, "Firebreathing"); // {R} Enchantment - Aura + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Firebreathing", "Silvercoat Lion"); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{R}: Enchanted creature"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Firebreathing", 1); + assertPowerToughness(playerA, "Silvercoat Lion", 3, 2); + } + + /** + * On Ghitu Firebreathing (and probably other similar cards), when you + * activate the ability to give +1/0 to the enchanted creature and the + * return Ghitu Firebreathing to your hand, the +1/0 goes away on the + * creature. If you re-cast Ghitu Firebreathing onto the creature, the boost + * returns. + * + * Gatherer Rulings: 9/25/2006 If you return Ghitu Firebreathing to its + * owner's hand while the +1/+0 ability is on the stack, that ability will + * still give the creature that was last enchanted by Ghitu Firebreathing + * +1/+0. + * + */ + @Test + public void testFirebreathingReturnToHand() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion", 1); + // {R}: Enchanted creature gets +1/+0 until end of turn. + addCard(Zone.HAND, playerA, "Firebreathing"); // {R} Enchantment - Aura + + addCard(Zone.BATTLEFIELD, playerB, "Island", 2); + addCard(Zone.HAND, playerB, "Boomerang"); // {U}{U} Instant + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Firebreathing", "Silvercoat Lion"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Boomerang", "Firebreathing"); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{R}: Enchanted creature", NO_TARGET, "Boomerang"); + + setStopAt(1, PhaseStep.END_COMBAT); + execute(); + + assertHandCount(playerA, "Firebreathing", 1); + assertGraveyardCount(playerB, "Boomerang", 1); + assertPowerToughness(playerA, "Silvercoat Lion", 3, 2); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/continuous/ChiefOfTheFoundryTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/continuous/ChiefOfTheFoundryTest.java new file mode 100644 index 00000000000..823961576c0 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/continuous/ChiefOfTheFoundryTest.java @@ -0,0 +1,59 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.continuous; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.filter.Filter; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class ChiefOfTheFoundryTest extends CardTestPlayerBase { + + /** + * Having two Chief of Foundry's out doesn't make them buff each other. + */ + @Test + public void testBoostOtherFoundry() { + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 6); + addCard(Zone.HAND, playerA, "Chief of the Foundry"); + addCard(Zone.HAND, playerA, "Chief of the Foundry"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chief of the Foundry"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chief of the Foundry"); + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPowerToughness(playerA, "Chief of the Foundry", 3, 4, Filter.ComparisonScope.All); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/copy/FlameshadowConjuringTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/copy/FlameshadowConjuringTest.java new file mode 100644 index 00000000000..423ac6c2084 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/copy/FlameshadowConjuringTest.java @@ -0,0 +1,75 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.copy; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class FlameshadowConjuringTest extends CardTestPlayerBase { + + /** + * My opponent ran into an issue with Priest of the Blood Rite being copied + * with Flameshadow Conjuring. His copy was made and removed correctly at + * the end of the turn, but the "lose two life a turn" trigger still + * happened twice. + * + * TODO: Seems like there are too much triggered abilities in + * TriggeredAbilities as the TriggeredAbilities get removed from + * PlayerImpl.removeFromBattlefield() + */ + @Test + public void testCopyAndItsEffectsRemoved() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 4); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); + // Whenever a nontoken creature enters the battlefield under your control, you may pay {R}. If you do, put a token onto the battlefield that's a copy of that creature. + // That token gains haste. Exile it at the beginning of the next end step. + addCard(Zone.BATTLEFIELD, playerA, "Flameshadow Conjuring", 1); + + // When Priest of the Blood Rite enters the battlefield, put a 5/5 black Demon creature token with flying onto the battlefield. + // At the beginning of your upkeep, you lose 2 life. + addCard(Zone.HAND, playerA, "Priest of the Blood Rite", 1); // {3}{B}{B} + setChoice(playerB, "Yes"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Priest of the Blood Rite"); + setStopAt(3, PhaseStep.UPKEEP); + execute(); + + assertPermanentCount(playerA, "Priest of the Blood Rite", 1); + assertPermanentCount(playerA, "Demon", 2); + + assertLife(playerB, 20); + assertLife(playerA, 18); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/copy/KikiJikiMirrorBreakerTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/copy/KikiJikiMirrorBreakerTest.java index ac9048c91a4..d252e8a6a79 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/copy/KikiJikiMirrorBreakerTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/copy/KikiJikiMirrorBreakerTest.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package org.mage.test.cards.copy; import mage.constants.PhaseStep; @@ -79,6 +78,7 @@ public class KikiJikiMirrorBreakerTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Voice of Resurgence", 1); addCard(Zone.BATTLEFIELD, playerB, "Mountain", 3); + // Flamebreak deals 3 damage to each creature without flying and each player. Creatures dealt damage this way can't be regenerated this turn. addCard(Zone.HAND, playerB, "Flamebreak"); activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Put a token that's a copy of target nonlegendary creature you control onto the battlefield. That token has haste. Sacrifice it at the beginning of the next end step."); @@ -97,7 +97,41 @@ public class KikiJikiMirrorBreakerTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Elemental", 2); - } -} \ No newline at end of file + /** + * Kiki-Jiki, Mirror Breaker creates a copy of Humble Defector, activate + * Humble defector, token gets sacrificed while under opponents control. + */ + @Test + public void testTokenNotSacrificedIfNotControlled() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 1); + // Tap target creature you don't control. + // Overload {3}{U} + addCard(Zone.HAND, playerA, "Blustersquall", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Kiki-Jiki, Mirror Breaker", 1); + // {T}: Draw two cards. Target opponent gains control of Humble Defector. Activate this ability only during your turn. + addCard(Zone.BATTLEFIELD, playerB, "Humble Defector", 1); + + castSpell(2, PhaseStep.UPKEEP, playerA, "Blustersquall", "Humble Defector"); // Tap nontoken Defector so only the Token can be used later + + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{T}: Put a token that's a copy of target nonlegendary creature you control onto the battlefield. That token has haste. Sacrifice it at the beginning of the next end step."); + + activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "{T}: Draw two cards. Target opponent gains control"); + + setStopAt(3, PhaseStep.UPKEEP); + execute(); + + assertLife(playerA, 20); + assertLife(playerB, 20); + + assertHandCount(playerB, 3); // normal 1 draw of turn two + 2 from Defector + + assertGraveyardCount(playerA, "Blustersquall", 1); + assertPermanentCount(playerB, "Humble Defector", 1); + assertPermanentCount(playerA, "Humble Defector", 1); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/BattlefieldThaumaturgeTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/BattlefieldThaumaturgeTest.java new file mode 100644 index 00000000000..a779b7e5ee5 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/BattlefieldThaumaturgeTest.java @@ -0,0 +1,299 @@ +package org.mage.test.cards.cost.modification; + +import mage.abilities.keyword.HexproofAbility; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.game.permanent.Permanent; +import org.junit.Assert; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * Battlefield Thaumaturge: + * Creature - Human Wizard + * Each instant and sorcery spell you cast costs {1} less to cast for each creature it targets. + * Heroic - Whenever you cast a spell that targets Battlefield Thaumaturge, Battlefield Thaumaturge gains hexproof until end of turn. + * + * @author Simown + */ +public class BattlefieldThaumaturgeTest extends CardTestPlayerBase { + + @Test + public void testSingleTargetReduction() { + + addCard(Zone.BATTLEFIELD, playerA, "Battlefield Thaumaturge"); + addCard(Zone.BATTLEFIELD, playerA, "Mountain"); + addCard(Zone.BATTLEFIELD, playerA, "Island"); + addCard(Zone.HAND, playerA, "Lightning Strike"); + + addCard(Zone.BATTLEFIELD, playerB, "Akroan Skyguard"); + + // Lightning Strike - {1}{R} - Lightning Strike deals 3 damage to target creature or player. + // Because Battlefield Thaumaturge is on the battlefield, and the creature is targeted by the + // Lightning Strike it will be payable with {R}. + castSpell(2, PhaseStep.POSTCOMBAT_MAIN, playerA, "Lightning Strike", "Akroan Skyguard"); + setStopAt(2, PhaseStep.END_TURN); + execute(); + + // PlayerA still has the Battlefield Thaumaturge + assertPermanentCount(playerA, "Battlefield Thaumaturge", 1); + // The Akroan Skyguard has been killed by the Lightning Strike + assertPermanentCount(playerB, "Akroan Skyguard", 0); + assertGraveyardCount(playerB, "Akroan Skyguard", 1); + + // Check {R} has been used to pay, and the other land remains untapped + assertTappedCount("Mountain", true, 1); + assertTappedCount("Island", false, 1); + } + + @Test + public void testStriveTargetingReduction1() { + + addCard(Zone.BATTLEFIELD, playerA, "Battlefield Thaumaturge"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 3); + addCard(Zone.BATTLEFIELD, playerA, "Forest", 4); + addCard(Zone.BATTLEFIELD, playerA, "Pharika's Chosen"); + addCard(Zone.HAND, playerA, "Silence the Believers"); + + addCard(Zone.BATTLEFIELD, playerB, "Battlewise Hoplite"); + /** + * Silence the Believers - {2}{B}{B} + * Exile any number of target creatures and all Auras attached to them + * Strive - Silence the Believers costs {2}{B} more to cast for each target beyond the first. + * Targetting a creature on both sides of the battlefield. + */ + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerA, "Silence the Believers", "Pharika's Chosen^Battlewise Hoplite"); + setStopAt(2, PhaseStep.END_TURN); + execute(); + + // Both creatures were exiled + assertExileCount("Pharika's Chosen", 1); + assertExileCount("Battlewise Hoplite", 1); + // Not still on the battlefield or in the graveyard + assertPermanentCount(playerA, "Pharika's Chosen", 0); + assertPermanentCount(playerB, "Battlewise Hoplite", 0); + assertGraveyardCount(playerA, "Pharika's Chosen", 0); + assertGraveyardCount(playerB, "Battlewise Hoplite", 0); + + /* Cost to exile 2 permanents will be: + * + {2}{B}{B} for the base spell + * + {2}{B} for an additional target + * - {2} for Battlefield Thaumaturge cost reducing effect + * = {2}{B}{B}{B} to pay. + */ + // Check 3 Swamps have been tapped to pay the reduced cost + assertTappedCount("Swamp", true, 3); + // And 2 Forests for the colorless mana + assertTappedCount("Forest", true, 2); + // And the rest of the Forests remain untapped + assertTappedCount("Forest", false, 2); + } + + @Test + public void testStriveTargetingReduction2() { + + String [] creatures = {"Battlefield Thaumaturge", "Agent of Horizons", "Blood-Toll Harpy", "Anvilwrought Raptor", "Fleshmad Steed" }; + for(String creature : creatures) { + addCard(Zone.BATTLEFIELD, playerA, creature); + } + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.BATTLEFIELD, playerA, "Island", 5); + addCard(Zone.HAND, playerA, "Launch the Fleet"); + + // Launch the Fleet - {W} + // Strive - Launch the Fleet costs {1} more to cast for each target beyond the first. + // Until end of turn, any number of target creatures each gain "Whenever this creature attacks, put a 1/1 white Soldier token onto the battlefield tapped and attacking." + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Launch the Fleet", createTargetingString(creatures)); + for(String creature : creatures) { + attack(3, playerA, creature); + } + setStopAt(3, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + // 5 initial creatures + 5 soldier tokens + 6 lands + assertPermanentCount(playerA, 16); + // The initial creatures exist + for(String creature : creatures) { + assertPermanentCount(playerA, creature, 1); + } + // Each has a solider token generated while attacking + assertPermanentCount(playerA, "Soldier", 5); + // Battlefield Thaumaturge will have hexproof from heroic trigger + Permanent battlefieldThaumaturge = getPermanent("Battlefield Thaumaturge", playerA.getId()); + Assert.assertTrue("Battlefield Thaumaturge must have hexproof", battlefieldThaumaturge.getAbilities().contains(HexproofAbility.getInstance())); + + assertLife(playerA, 20); + // 5 initial creatures + 5 soldier tokens => 16 damage + assertLife(playerB, 4); + /* Cost to have 5 attackers generate soldier tokens + * + {W} for the base spell + * + {4} for an additional targets + * - {4} for Battlefield Thaumaturge cost reducing effect (reduce {1} per target) + * = {W} to pay. + */ + assertTappedCount("Plains", true, 1); + // No other mana has been tapped to pay costs + assertTappedCount("Island", false, 5); + } + + @Test + public void testVariableCostReduction() { + addCard(Zone.BATTLEFIELD, playerA, "Battlefield Thaumaturge"); + addCard(Zone.BATTLEFIELD, playerA, "Island", 2); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 4); + addCard(Zone.HAND, playerA, "Curse of the Swine"); + + String [] opponentsCreatures = {"Fleecemane Lion", "Sedge Scorpion", "Boon Satyr", "Bronze Sable"}; + for(String creature: opponentsCreatures) { + addCard(Zone.BATTLEFIELD, playerB, creature); + } + + /* Curse of the Swine - {X}{U}{U} + * Exile X target creatures. For each creature exiled this way, + * its controller puts a 2/2 green Boar creature token onto the battlefield + */ + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Curse of the Swine"); + setChoice(playerA, "X=4"); + addTarget(playerA, createTargetingString(opponentsCreatures)); + setStopAt(1, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + // All the opponents creatures have been exiled from the battlefield + for(String creature: opponentsCreatures) { + assertPermanentCount(playerB, creature, 0); + assertGraveyardCount(playerB, creature, 0); + assertExileCount(creature, 1); + } + + // All 4 creatures have been replaced by boars + assertPermanentCount(playerB, "Boar", 4); + + /* Cost to target 4 permanents will be: + * + {4}{U}{U} for the base spell with X = 4 + * - {4} for Battlefield Thaumaturge cost reducing effect as 4 creatures are targetted + * = {U}{U} to pay. + */ + // Check 2 islands have been tapped to pay the reduced cost + assertTappedCount("Island", true, 2); + // And the rest of the lands remain untapped + assertTappedCount("Plains", false, 4); + } + + @Test + public void testMutipleTargetReduction() { + + String [] playerACreatures = {"Battlefield Thaumaturge", "Sedge Scorpion", "Boon Satyr"}; + String [] playerBCreatures = {"Agent of Horizons", "Blood-Toll Harpy", "Anvilwrought Raptor"}; + + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 4); + // Creatures for player A + for(String creature: playerACreatures) { + addCard(Zone.BATTLEFIELD, playerA, creature); + } + addCard(Zone.HAND, playerA, "Descent of the Dragons"); + // Creatures for player B + for(String creature: playerBCreatures) { + addCard(Zone.BATTLEFIELD, playerB, creature); + } + /* Descent of the Dragons - {4}{R}{R} + * Destroy any number of target creatures. + * For each creature destroyed this way, its controller puts a 4/4 red Dragon creature token with flying onto the battlefield. + * Battlefield Thaumaturge should reduce the cost of the spell when cast, before he is destroyed and replaced with a dragon. + */ + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Descent of the Dragons", createTargetingString(playerACreatures) + "^" + createTargetingString(playerBCreatures)); + setStopAt(1, PhaseStep.END_TURN); + execute(); + + // All creatures have been put in the graveyard + for(String creature: playerACreatures) { + assertPermanentCount(playerA, creature, 0); + assertGraveyardCount(playerA, creature, 1); + } + for(String creature: playerBCreatures) { + assertPermanentCount(playerB, creature, 0); + assertGraveyardCount(playerB, creature, 1); + } + + // And each player has 3 dragons + assertPermanentCount(playerA, "Dragon", 3); + assertPermanentCount(playerB, "Dragon", 3); + + /* Cost to target 6 creatures will be + * + {4}{R}{R} for the fixed cost base spell + * - {4} for Battlefield Thaumaturge cost reducing effect + * each creature targeted will reduce the cost by {1} so the cost + * can only be reduced by {4} maximum using Battlefield Thaumaturge + * even though 6 creatures are targeted. + * = {R}{R} to pay. + */ + // Check 2 mountains have been tapped to pay the reduced cost + assertTappedCount("Mountain", true, 2); + // And the rest of the lands remain untapped + assertTappedCount("Swamp", false, 4); + } + + @Test + public void testTargetNonCreature() { + + addCard(Zone.BATTLEFIELD, playerA, "Battlefield Thaumaturge"); + addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); + addCard(Zone.HAND, playerA, "Fade into Antiquity"); + + addCard(Zone.BATTLEFIELD, playerB, "Heliod, God of the Sun"); + + // Fade into Antiquity - Sorcery - {2}{G} - Exile target artifact or enchantment. + // Battlefield Thaumaturge only reduces the cost instants and sorceries where the target is a creature + // No cost reduction for targeting an enchantment (devotion is too low for Heliod to be a creature) + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Fade into Antiquity", "Heliod, God of the Sun"); + setStopAt(1, PhaseStep.END_TURN); + execute(); + + // PlayerA still has the Battlefield Thaumaturge + assertPermanentCount(playerA, "Battlefield Thaumaturge", 1); + // Heliod has been exiled + assertPermanentCount(playerB, "Heliod, God of the Sun", 0); + assertGraveyardCount(playerB, "Heliod, God of the Sun", 0); + assertExileCount("Heliod, God of the Sun", 1); + + // Expect full amount paid, i.e. all lands are tapped. Cost was not reduced by Battlefield Thaumaturge, no creature was targeted. + assertTappedCount("Forest", true, 3); + } + + @Test + public void testTargetWithAura() { + + addCard(Zone.BATTLEFIELD, playerA, "Battlefield Thaumaturge"); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 5); + addCard(Zone.HAND, playerA, "Spectra Ward"); + + // Spectra Ward - {3}{W}{W} - Aura + // Enchanted creature gets +2/+2 and has protection from all colors. This effect doesn't remove auras. + // Battlefield Thaumaturge only reduces the cost instants and sorceries targeting creatures. + // No cost reduction for targeting a creature with an Aura. + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Spectra Ward", "Battlefield Thaumaturge"); + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Battlefield Thaumaturge", 1); + assertPermanentCount(playerA, "Spectra Ward", 1); + // Battlefield Thaumaturge will have hexproof from heroic trigger + Permanent battlefieldThaumaturge = getPermanent("Battlefield Thaumaturge", playerA.getId()); + Assert.assertTrue("Battlefield Thaumaturge must have hexproof", battlefieldThaumaturge.getAbilities().contains(HexproofAbility.getInstance())); + + // No cost reduction from Battlefield Thaumaturge, full amount paid + assertTappedCount("Plains", true, 5); + } + + private String createTargetingString(String [] targets) { + StringBuilder targetBuilder = new StringBuilder(); + for (String target : targets) { + if (targetBuilder.length() > 0) { + targetBuilder.append('^'); + } + targetBuilder.append(target); + } + return targetBuilder.toString(); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/CostModificationTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/CostModificationTest.java index c0022e21951..bb002da08cd 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/CostModificationTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/CostModificationTest.java @@ -8,7 +8,7 @@ import org.mage.test.serverside.base.CardTestPlayerBase; /** * * also tests cost reduction effects - * + * * @author BetaSteward */ public class CostModificationTest extends CardTestPlayerBase { @@ -46,16 +46,12 @@ public class CostModificationTest extends CardTestPlayerBase { } /** - * Test that cost reduction also works with mana source restriction - * Myr Superion - * Spend only mana produced by creatures to cast Myr Superion + * Test that cost reduction also works with mana source restriction Myr + * Superion Spend only mana produced by creatures to cast Myr Superion * - * Etherium Sculptor {1}{U} - * Artifact Creature - Vedalken Artificer - * 1/2 + * Etherium Sculptor {1}{U} Artifact Creature - Vedalken Artificer 1/2 * Artifact spells you cast cost {1} less to cast. */ - @Test public void testCostReductionWithManaSourceRestrictionWorking() { // Artifact spells you cast cost {1} less to cast @@ -95,4 +91,31 @@ public class CostModificationTest extends CardTestPlayerBase { assertHandCount(playerA, "Myr Superion", 1); // Can't be cast because mana was not produced by a creature } + /* + I had Goblin Electromancer, but somehow Pyretic Ritual wasn't cheaper howeverDesperate Ritual was. + */ + @Test + public void testCostReductionForPyreticRitual() { + // Instant and sorcery spells you cast cost {1} less to cast. + addCard(Zone.BATTLEFIELD, playerA, "Goblin Electromancer"); + addCard(Zone.BATTLEFIELD, playerA, "Mountain"); + + // Add {R}{R}{R} to your mana pool. + addCard(Zone.HAND, playerA, "Pyretic Ritual"); + // Fated Conflagration deals 5 damage to target creature or planeswalker. + // If it's your turn, scry 2. (Look at the top two cards of your library, then put any number of them on the bottom of your library and the rest on top in any order.) + addCard(Zone.HAND, playerA, "Fated Conflagration"); + + addCard(Zone.BATTLEFIELD, playerB, "Carnivorous Moss-Beast"); // 4/5 + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Pyretic Ritual"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Fated Conflagration", "Carnivorous Moss-Beast"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Pyretic Ritual", 1); + assertGraveyardCount(playerA, "Fated Conflagration", 1); + assertGraveyardCount(playerB, "Carnivorous Moss-Beast", 1); + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/HeartstoneTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/HeartstoneTest.java new file mode 100644 index 00000000000..60253c99c6e --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/cost/modification/HeartstoneTest.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.cost.modification; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class HeartstoneTest extends CardTestPlayerBase { + + /** + * Heartstone is not reducing the cost of Sigil Tracer 's activated ability + */ + @Test + public void testSigilTracer() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 2); + // {1}{U}, Tap two untapped Wizards you control: Copy target instant or sorcery spell. You may choose new targets for the copy. + addCard(Zone.BATTLEFIELD, playerA, "Sigil Tracer"); + // Activated abilities of creatures cost {1} less to activate. This effect can't reduce the amount of mana an ability costs to activate to less than one mana. + addCard(Zone.BATTLEFIELD, playerA, "Heartstone"); + addCard(Zone.BATTLEFIELD, playerA, "Fugitive Wizard"); + + addCard(Zone.BATTLEFIELD, playerB, "Mountain"); + addCard(Zone.HAND, playerB, "Lightning Bolt"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Lightning Bolt", playerA); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{1}{U},Tap two untapped Wizards you control: Copy target instant or sorcery spell. You may choose new targets for the copy.", "Lightning Bolt"); + setChoice(playerA, "Yes"); + addTarget(playerA, playerB); + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerB, "Lightning Bolt", 1); + + assertTapped("Fugitive Wizard", true); + assertLife(playerA, 17); + assertLife(playerB, 17); + + assertTappedCount("Island", true, 1); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/emblems/EmblemsTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/emblems/EmblemsTest.java index 66b7aa73c35..0c211862d2c 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/emblems/EmblemsTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/emblems/EmblemsTest.java @@ -14,8 +14,8 @@ import org.mage.test.serverside.base.CardTestPlayerBase; public class EmblemsTest extends CardTestPlayerBase { /** - * Venser The Sojourner: - * -8: You get an emblem with "Whenever you cast a spell, exile target permanent." + * Venser The Sojourner: -8: You get an emblem with "Whenever you cast a + * spell, exile target permanent." */ @Test public void testVenserTheSojournerEmblem() { @@ -40,8 +40,8 @@ public class EmblemsTest extends CardTestPlayerBase { } /** - * Sorin, Lord of Innistrad: - * -2: You get an emblem with "Creatures you control get +1/+0." + * Sorin, Lord of Innistrad: -2: You get an emblem with "Creatures you + * control get +1/+0." */ @Test public void testSorinLordOfInnistradEmblem() { @@ -67,8 +67,9 @@ public class EmblemsTest extends CardTestPlayerBase { } /** - * Tamiyo, the Moon Sage: - * -8: You get an emblem with "You have no maximum hand size" and "Whenever a card is put into your graveyard from anywhere, you may return it to your hand." + * Tamiyo, the Moon Sage: -8: You get an emblem with "You have no maximum + * hand size" and "Whenever a card is put into your graveyard from anywhere, + * you may return it to your hand." * * Tests "You have no maximum hand size" */ @@ -88,10 +89,12 @@ public class EmblemsTest extends CardTestPlayerBase { } /** - * Tamiyo, the Moon Sage: - * -8: You get an emblem with "You have no maximum hand size" and "Whenever a card is put into your graveyard from anywhere, you may return it to your hand." + * Tamiyo, the Moon Sage: -8: You get an emblem with "You have no maximum + * hand size" and "Whenever a card is put into your graveyard from anywhere, + * you may return it to your hand." * - * Tests "Whenever a card is put into your graveyard from anywhere, you may return it to your hand." + * Tests "Whenever a card is put into your graveyard from anywhere, you may + * return it to your hand." */ @Test public void testTamiyoTheMoonSageSecondEmblem() { @@ -119,4 +122,39 @@ public class EmblemsTest extends CardTestPlayerBase { } Assert.assertTrue("Couldn't find a card in hand: Elite Vanguard", found); } + + /** + * Liliana, Defiant Necromancer: -8: You get an emblem with "Whenever a + * creature you control dies, return it to the battlefield under your + * control at the beginning of the next end step."; + * + * Tests "Whenever a creature you control dies, return it to the battlefield + * under your control at the beginning of the next end step." + */ + @Test + public void testLilianaDefiantNecromancer() { + addCard(Zone.BATTLEFIELD, playerA, "Liliana, Defiant Necromancer"); + addCard(Zone.BATTLEFIELD, playerA, "Elite Vanguard"); + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion"); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 2); + addCard(Zone.HAND, playerB, "Lightning Bolt", 2); + + addCounters(1, PhaseStep.UPKEEP, playerA, "Liliana, Defiant Necromancer", CounterType.LOYALTY, 6); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "-8: You get an emblem"); + + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Lightning Bolt", "Elite Vanguard"); + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Lightning Bolt", "Silvercoat Lion"); + + setStopAt(2, PhaseStep.UPKEEP); + execute(); + + assertEmblemCount(playerA, 1); + + assertPermanentCount(playerA, "Liliana, Defiant Necromancer", 1); + assertPermanentCount(playerA, "Elite Vanguard", 1); + assertGraveyardCount(playerB, "Silvercoat Lion", 1); + + assertHandCount(playerA, 0); + + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/mana/CryptGhastTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/mana/CryptGhastTest.java new file mode 100644 index 00000000000..623c3b44258 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/mana/CryptGhastTest.java @@ -0,0 +1,103 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.mana; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class CryptGhastTest extends CardTestPlayerBase { + + @Test + public void TestNormal() { + //Extort (Whenever you cast a spell, you may pay {WB}. If you do, each opponent loses 1 life and you gain that much life.) + // Whenever you tap a Swamp for mana, add {B} to your mana pool (in addition to the mana the land produces). + addCard(Zone.BATTLEFIELD, playerA, "Crypt Ghast", 1); + addCard(Zone.HAND, playerA, "Erebos's Titan", 1); + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + // Swamp Mountain + addCard(Zone.BATTLEFIELD, playerA, "Badlands", 1); + + activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R} to your mana pool"); + activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {B} to your mana pool"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Erebos's Titan"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Erebos's Titan", 1); + + } + + /** + * Crypt Ghast was still effective (doubling swamp {B} Mana and providiong + * the option to extort) as if it was on the battlefield after being killed + * with Nin, the Pain Artist controlled by me and then exiled into a Mimic + * Vat controlled by Crypt Ghast's controller. + */ + @Test + public void TestExiled() { + //Extort (Whenever you cast a spell, you may pay {WB}. If you do, each opponent loses 1 life and you gain that much life.) + // Whenever you tap a Swamp for mana, add {B} to your mana pool (in addition to the mana the land produces). + addCard(Zone.BATTLEFIELD, playerA, "Crypt Ghast", 1); + // Imprint - Whenever a nontoken creature dies, you may exile that card. If you do, return each other card exiled with Mimic Vat to its owner's graveyard. + // {3},{T}: Put a token onto the battlefield that's a copy of the exiled card. It gains haste. Exile it at the beginning of the next end step. + addCard(Zone.BATTLEFIELD, playerA, "Mimic Vat", 1); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + // Swamp Mountain + addCard(Zone.BATTLEFIELD, playerA, "Badlands", 1); + addCard(Zone.HAND, playerA, "Erebos's Titan", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Island", 2); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 2); + // {X}{U}{R},{T}: Nin, the Pain Artist deals X damage to target creature. That creature's controller draws X cards. + addCard(Zone.BATTLEFIELD, playerB, "Nin, the Pain Artist", 1); + + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{X}{U}{R},{T}: {this} deals X damage to target creature", "Crypt Ghast"); + setChoice(playerB, "X=2"); + + // Crypt Ghast may no longer give additional mana + activateManaAbility(3, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {R} to your mana pool"); + activateManaAbility(3, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {B} to your mana pool"); + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Erebos's Titan"); + + setStopAt(3, PhaseStep.PRECOMBAT_MAIN); + execute(); + + assertPermanentCount(playerA, "Erebos's Titan", 0); + assertTapped("Nin, the Pain Artist", true); + assertExileCount("Crypt Ghast", 1); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/GideonTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/GideonTest.java new file mode 100644 index 00000000000..51cbfff98f6 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/GideonTest.java @@ -0,0 +1,79 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.planeswalker; + +import mage.abilities.keyword.IndestructibleAbility; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.counters.CounterType; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class GideonTest extends CardTestPlayerBase { + + // Gideon, Battle-Forged + // +2: Up to one target creature an opponent controls attacks Gideon, Battle-Forged during its controller's next turn if able. + // +1: Until your next turn, target creature gains indestructible. Untap that creature. + // 0: Until end of turn, Gideon, Battle-Forged becomes a 4/4 Human Soldier creature with indestructible that's still a planeswalker. Prevent all damage that would be dealt to him this turn. + @Test + public void testGideonBattleForged() { + // At end of combat, if Kytheon, Hero of Akros and at least two other creatures attacked this combat, exile Kytheon, + // then return him to the battlefield transformed under his owner's control. + // {2}{W}: Kytheon gains indestructible until end of turn. + addCard(Zone.BATTLEFIELD, playerB, "Kytheon, Hero of Akros"); + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion"); + addCard(Zone.BATTLEFIELD, playerB, "Pillarfield Ox"); + + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); + addCard(Zone.HAND, playerA, "Lightning Bolt", 1); + + attack(2, playerB, "Kytheon, Hero of Akros"); + attack(2, playerB, "Silvercoat Lion"); + attack(2, playerB, "Pillarfield Ox"); + + activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "+1: Until your next turn, target creature gains indestructible. Untap that creature.", "Silvercoat Lion"); + + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt"); + + setStopAt(4, PhaseStep.PRECOMBAT_MAIN); + execute(); + + assertGraveyardCount(playerA, "Lightning Bolt", 1); + assertPermanentCount(playerB, "Gideon, Battle-Forged", 1); + assertCounterCount("Gideon, Battle-Forged", CounterType.LOYALTY, 4); + assertLife(playerA, 14); + + assertPermanentCount(playerB, "Silvercoat Lion", 1); + assertAbility(playerB, "Silvercoat Lion", IndestructibleAbility.getInstance(), false); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/UginTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/UginTest.java new file mode 100644 index 00000000000..bc396fbfd04 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/planeswalker/UginTest.java @@ -0,0 +1,91 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.planeswalker; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.counters.CounterType; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class UginTest extends CardTestPlayerBase { + + @Test + public void testCard() { + // +2: Ugin, the Spirit Dragon deals 3 damage to target creature or player. + // -X: Exile each permanent with converted mana cost X or less that's one or more colors. + // -10: You gain 7 life, draw 7 cards, then put up to seven permanent cards from your hand onto the battlefield. + addCard(Zone.BATTLEFIELD, playerA, "Ugin, the Spirit Dragon"); // starts with 7 Loyality counters + // Whenever a creature dies, you may put a quest counter on Quest for the Gravelord. + addCard(Zone.BATTLEFIELD, playerA, "Quest for the Gravelord"); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion"); + + addCard(Zone.LIBRARY, playerB, "Forest", 2); + addCard(Zone.BATTLEFIELD, playerB, "Forest", 6); + // When Nissa, Vastwood Seer enters the battlefield, you may search your library for a basic Forest card, reveal it, put it into your hand, then shuffle your library. + // Whenever a land enters the battlefield under your control, if you control seven or more lands, exile Nissa, then return her to the battlefield transformed under her owner's control. + // +1: Reveal the top card of your library. If it's a land card, put it onto the battlefield. Otherwise, put it into your hand. + // -2: Put a legendary 4/4 green Elemental creature token named Ashaya, the Awoken World onto the battlefield. + // -7: Untap up to six target lands. They become 6/6 Elemental creatures. They're still lands. + addCard(Zone.HAND, playerB, "Nissa, Vastwood Seer"); + + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "+2: {source} deals 3 damage to target creature or player.", playerB); + + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Nissa, Vastwood Seer"); + playLand(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Forest"); + activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "-2: Put a legendary 4/4 green Elemental creature token named Ashaya, the Awoken World onto the battlefield."); + + attack(3, playerA, "Silvercoat Lion"); + block(3, playerB, "Ashaya, the Awoken World", "Silvercoat Lion"); + + activateAbility(3, PhaseStep.POSTCOMBAT_MAIN, playerA, "-X: Exile each permanent with converted mana cost X or less that's one or more colors"); + setChoice(playerA, "X=0"); + + setStopAt(3, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Ugin, the Spirit Dragon", 1); + assertCounterCount("Ugin, the Spirit Dragon", CounterType.LOYALTY, 9); // 7 + 2 - 0 + + assertGraveyardCount(playerA, "Silvercoat Lion", 1); + assertPermanentCount(playerB, "Ashaya, the Awoken World", 0); + + assertExileCount("Nissa, Vastwood Seer", 1); + + assertCounterCount("Quest for the Gravelord", CounterType.QUEST, 1); + + assertLife(playerA, 20); + assertLife(playerB, 17); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/replacement/ZoneChangeReplacementTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/ZoneChangeReplacementTest.java index adf0480d7d6..b2f712686de 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/replacement/ZoneChangeReplacementTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/ZoneChangeReplacementTest.java @@ -25,24 +25,23 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package org.mage.test.cards.replacement; import mage.constants.PhaseStep; import mage.constants.Zone; +import mage.counters.CounterType; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBase; /** * Checks if change zone replacement effects work as intended - * + * * @author LevelX2 */ - public class ZoneChangeReplacementTest extends CardTestPlayerBase { - // If Darksteel Colossus would be put into a graveyard from anywhere, - // reveal Darksteel Colossus and shuffle it into its owner's library instead. + // If Darksteel Colossus would be put into a graveyard from anywhere, + // reveal Darksteel Colossus and shuffle it into its owner's library instead. @Test public void testFromLibraryZoneChange() { addCard(Zone.LIBRARY, playerA, "Darksteel Colossus"); @@ -51,7 +50,7 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { addCard(Zone.HAND, playerA, "Tome Scour"); addCard(Zone.BATTLEFIELD, playerA, "Island", 1); skipInitShuffling(); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Tome Scour", playerA); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -59,9 +58,9 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Darksteel Colossus", 0); assertGraveyardCount(playerA, 5); // 4 + Tome Scour - + } - + @Test public void testFromHandZoneChange() { addCard(Zone.HAND, playerA, "Progenitus"); @@ -69,8 +68,8 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { // Target player reveals his or her hand. You choose a nonland card from it. That player discards that card. addCard(Zone.HAND, playerA, "Distress"); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Distress", playerA); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Distress", playerA); setChoice(playerA, "Progenitus"); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -78,7 +77,7 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Progenitus", 0); assertGraveyardCount(playerA, 1); // Distress - + assertHandCount(playerA, "Progenitus", 0); } @@ -88,13 +87,13 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { // Diabolic Edict - Instant - {1}{B} // Target player sacrifices a creature. addCard(Zone.HAND, playerA, "Diabolic Edict"); - // Whenever a nontoken creature is put into your graveyard from the battlefield, if Bridge from + // Whenever a nontoken creature is put into your graveyard from the battlefield, if Bridge from // Below is in your graveyard, put a 2/2 black Zombie creature token onto the battlefield. addCard(Zone.GRAVEYARD, playerA, "Bridge from Below"); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); setChoice(playerA, "Silvercoat Lion"); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -103,7 +102,7 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Silvercoat Lion", 1); assertGraveyardCount(playerA, 3); // Diabolic Edict + Bridge from Below + Silvercoat Lion assertPermanentCount(playerA, "Zombie", 1); // Silvercoat Lion goes to graveyard so a Zombie tokes is created - + } @Test @@ -112,13 +111,13 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { // Diabolic Edict - Instant - {1}{B} // Target player sacrifices a creature. addCard(Zone.HAND, playerA, "Diabolic Edict"); - // Whenever a nontoken creature is put into your graveyard from the battlefield, if Bridge from + // Whenever a nontoken creature is put into your graveyard from the battlefield, if Bridge from // Below is in your graveyard, put a 2/2 black Zombie creature token onto the battlefield. addCard(Zone.GRAVEYARD, playerA, "Bridge from Below"); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); setChoice(playerA, "Progenitus"); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -127,13 +126,11 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Progenitus", 0); assertGraveyardCount(playerA, 2); // Diabolic Edict + Bridge from Below assertPermanentCount(playerA, "Zombie", 0); // Progenitus never touches graveyard - so no Zombie tokes is created - + } - + // Have Progenitus and Humility on the battlefield. Destroy Progenitus. Progenitus should go to the graveyard // since it doesn't have any replacement effect. Currently, it gets shuffled into the library. - - @Test public void testHumilityDeactivatesReplacementEffectAbilities() { // Protection from everything @@ -147,8 +144,8 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { addCard(Zone.HAND, playerA, "Diabolic Edict"); addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Diabolic Edict", playerA); setChoice(playerA, "Progenitus"); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -157,10 +154,9 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Progenitus", 0); assertGraveyardCount(playerA, "Progenitus", 1); assertGraveyardCount(playerA, 2); // Diabolic Edict + Progenitus - - + } - + @Test public void testHumilityAndKumano() { // Enchantment {2}{W}{W} @@ -178,9 +174,9 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); // 2/2 addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerA, "Aggressive Urge", "Kumano's Pupils"); - + attack(2, playerB, "Silvercoat Lion"); block(2, playerA, "Kumano's Pupils", "Silvercoat Lion"); @@ -194,16 +190,14 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Kumano's Pupils", 1); assertPowerToughness(playerA, "Kumano's Pupils", 2, 2); assertPermanentCount(playerB, "Silvercoat Lion", 0); - + assertExileCount("Silvercoat Lion", 0); assertGraveyardCount(playerB, "Silvercoat Lion", 1); - - } + } // A creature gets damage from Kumano's Pupils and is destroyed after. // The creature has to go to exile. - @Test public void testCreatureGetsExiledByKumano() { // 3/3 @@ -237,12 +231,9 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { } - - // A creature gets damage from Kumano's Pupils and returns to hand after. // Then it's cast again. This new permanent instance is destroyed. It may not // got to exile because only previous instance was damgaged by Kumano's Pupils. - @Test public void testPermanentNewInstanceAndKumano() { // 3/3 @@ -262,10 +253,9 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); addCard(Zone.BATTLEFIELD, playerB, "Plains", 4); - attack(2, playerB, "Pillarfield Ox"); block(2, playerA, "Kumano's Pupils", "Pillarfield Ox"); - + castSpell(2, PhaseStep.COMBAT_DAMAGE, playerA, "Unsummon", "Pillarfield Ox"); castSpell(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "Pillarfield Ox"); castSpell(2, PhaseStep.POSTCOMBAT_MAIN, playerA, "Terminate", "Pillarfield Ox"); @@ -286,11 +276,11 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerB, "Pillarfield Ox", 1); } - /** - * Test that a countered spell of a card that goes always to library back - * instead of into the graveyard. - */ + /** + * Test that a countered spell of a card that goes always to library back + * instead of into the graveyard. + */ @Test public void testCounterAndMoveToLibrary() { addCard(Zone.BATTLEFIELD, playerA, "Plains", 7); @@ -298,12 +288,12 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { // {W}{U}{B}{R}{G}: Exile target permanent. // If Legacy Weapon would be put into a graveyard from anywhere, reveal Legacy Weapon and shuffle it into its owner's library instead. addCard(Zone.HAND, playerA, "Legacy Weapon"); - + addCard(Zone.BATTLEFIELD, playerB, "Island", 2); // Counter target spell. At the beginning of your next main phase, add {X} to your mana pool, where X is that spell's converted mana cost. addCard(Zone.HAND, playerB, "Mana Drain"); addCard(Zone.HAND, playerB, "Legacy Weapon"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Legacy Weapon"); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Mana Drain", "Legacy Weapon"); @@ -317,34 +307,33 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertHandCount(playerA, "Legacy Weapon", 0); assertPermanentCount(playerA, "Legacy Weapon", 0); assertGraveyardCount(playerA, "Legacy Weapon", 0); - - assertGraveyardCount(playerB, "Mana Drain", 1); - - assertPermanentCount(playerB, "Legacy Weapon", 1); - - } - - /** - * Test that a returned creature of Whip of Erebos - * got exiled if it is destroyed by a spell - */ + assertGraveyardCount(playerB, "Mana Drain", 1); + + assertPermanentCount(playerB, "Legacy Weapon", 1); + + } + + /** + * Test that a returned creature of Whip of Erebos got exiled if it is + * destroyed by a spell + */ @Test public void testWhipOfErebos() { addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); // Destroy target nonartifact, nonblack creature. It can't be regenerated. - addCard(Zone.HAND, playerA, "Terror"); - - // {2}{B}{B}, {T}: Return target creature card from your graveyard to the battlefield. + addCard(Zone.HAND, playerA, "Terror"); + + // {2}{B}{B}, {T}: Return target creature card from your graveyard to the battlefield. // It gains haste. Exile it at the beginning of the next end step. // If it would leave the battlefield, exile it instead of putting it anywhere else. // Activate this ability only any time you could cast a sorcery. addCard(Zone.BATTLEFIELD, playerB, "Whip of Erebos"); addCard(Zone.BATTLEFIELD, playerB, "Swamp", 4); addCard(Zone.GRAVEYARD, playerB, "Silvercoat Lion"); - + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{2}{B}{B},{T}: Return target creature", "Silvercoat Lion"); - + castSpell(2, PhaseStep.BEGIN_COMBAT, playerA, "Terror", "Silvercoat Lion"); setStopAt(2, PhaseStep.END_COMBAT); execute(); @@ -354,10 +343,43 @@ public class ZoneChangeReplacementTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Terror", 1); assertExileCount("Silvercoat Lion", 1); - + } - - -} + /** + * Jace, Vryn’s Prodigy – Jace, Telepath Unbound + * + * You can't whip him back with Whip of Erebos , flip him and then keep him. + * I think he is considered a new object after being exiled by his own + * trigger, so whip shouldn't affect him anymore. + */ + @Test + public void testWhipOfErebosTransformPlaneswalker() { + // {2}{B}{B}, {T}: Return target creature card from your graveyard to the battlefield. + // It gains haste. Exile it at the beginning of the next end step. + // If it would leave the battlefield, exile it instead of putting it anywhere else. + // Activate this ability only any time you could cast a sorcery. + addCard(Zone.BATTLEFIELD, playerB, "Whip of Erebos"); + addCard(Zone.BATTLEFIELD, playerB, "Swamp", 4); + addCard(Zone.GRAVEYARD, playerB, "Swamp", 5); + addCard(Zone.GRAVEYARD, playerB, "Jace, Vryn's Prodigy"); + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{2}{B}{B},{T}: Return target creature", "Jace, Vryn's Prodigy"); + + // {T}: Draw a card, then discard a card. If there are five or more cards in your graveyard, exile Jace, Vryn's Prodigy, then return him to the battefield transformed under his owner's control. + activateAbility(2, PhaseStep.BEGIN_COMBAT, playerB, "{T}: Draw a card, then discard a card. If there are five or more cards in your graveyard"); + + activateAbility(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "+1: Up to one target creature gets -2/-0 until your next turn"); + setStopAt(3, PhaseStep.UNTAP); + execute(); + + assertLife(playerA, 20); + assertLife(playerB, 20); + + assertPermanentCount(playerB, "Jace, Vryn's Prodigy", 0); + assertPermanentCount(playerB, "Jace, Telepath Unbound", 1); + assertCounterCount("Jace, Telepath Unbound", CounterType.LOYALTY, 6); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/CanopyCoverTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/CanopyCoverTest.java new file mode 100644 index 00000000000..d3c0125f01a --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/CanopyCoverTest.java @@ -0,0 +1,93 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.replacement.canttarget; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class CanopyCoverTest extends CardTestPlayerBase { + + /** + * Test spell + */ + @Test + public void testCantBeTargetedWithSpells() { + addCard(Zone.HAND, playerB, "Lightning Bolt"); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); + + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion"); // 2/2 Creature - Lion + // Enchanted creature can't be the target of spells or abilities your opponents control. + addCard(Zone.HAND, playerA, "Canopy Cover"); // Enchantment - Aura + + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Canopy Cover", "Silvercoat Lion"); + + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "Lightning Bolt", "Silvercoat Lion"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Canopy Cover", 1); + assertPermanentCount(playerA, "Silvercoat Lion", 1); + + assertHandCount(playerB, "Lightning Bolt", 1); + } + + @Test + public void testCantBeTargetedWithAbilities() { + // {U},Sacrifice AEther Spellbomb: Return target creature to its owner's hand. + addCard(Zone.BATTLEFIELD, playerB, "AEther Spellbomb"); + addCard(Zone.BATTLEFIELD, playerB, "Island", 1); + + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion"); // 2/2 Creature - Lion + // Enchanted creature can't be the target of spells or abilities your opponents control. + addCard(Zone.HAND, playerA, "Canopy Cover"); // Enchantment - Aura + + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Canopy Cover", "Silvercoat Lion"); + + activateAbility(1, PhaseStep.POSTCOMBAT_MAIN, playerB, "{U},Sacrifice", "Silvercoat Lion"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Canopy Cover", 1); + assertPermanentCount(playerA, "Silvercoat Lion", 1); + + assertGraveyardCount(playerB, "AEther Spellbomb", 0); + assertPermanentCount(playerB, "AEther Spellbomb", 1); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/GaeasRevengeTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/GaeasRevengeTest.java new file mode 100644 index 00000000000..34fa2d09766 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/replacement/canttarget/GaeasRevengeTest.java @@ -0,0 +1,81 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.replacement.canttarget; + +import mage.abilities.keyword.TrampleAbility; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class GaeasRevengeTest extends CardTestPlayerBase { + + /** + * Test spell + */ + @Test + public void testGreenCanTargetWithSpells() { + addCard(Zone.HAND, playerA, "Titanic Growth"); + // Gaea's Revenge can't be countered. + // Haste + // Gaea's Revenge can't be the target of nongreen spells or abilities from nongreen sources. + addCard(Zone.BATTLEFIELD, playerA, "Gaea's Revenge"); // 8/5 Creature - Elemental + + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Titanic Growth", "Gaea's Revenge"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + assertPowerToughness(playerA, "Gaea's Revenge", 12, 9); + } + + @Test + public void testGreenCanTargetWithAnAbilitiy() { + // Gaea's Revenge can't be countered. + // Haste + // Gaea's Revenge can't be the target of nongreen spells or abilities from nongreen sources. + addCard(Zone.BATTLEFIELD, playerB, "Gaea's Revenge"); // 8/5 Creature - Elemental + // Whenever a creature you control becomes blocked, it gets +1/+1 until end of turn. + // {1}{G}: Target creature you control gains trample until end of turn. + addCard(Zone.BATTLEFIELD, playerB, "Somberwald Alpha"); // 3/2 Creature - Wolf + + addCard(Zone.BATTLEFIELD, playerB, "Forest", 2); + + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{1}{G}: Target creature", "Gaea's Revenge"); + + setStopAt(2, PhaseStep.BEGIN_COMBAT); + execute(); + assertAbility(playerB, "Gaea's Revenge", TrampleAbility.getInstance(), true); + assertPowerToughness(playerB, "Gaea's Revenge", 8, 5); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/rules/CantSearchTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/rules/CantSearchTest.java new file mode 100644 index 00000000000..f823f473314 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/rules/CantSearchTest.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.rules; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class CantSearchTest extends CardTestPlayerBase { + + /** + * Stranglehold doesn´t stop your opponents from searching libraries, at the + * moment it doesn´t work at all. Opponents were able to search their and my + * library in multiple gammes. + */ + @Test + public void testStranglehold() { + // Your opponents can't search libraries. + // If an opponent would begin an extra turn, that player skips that turn instead. + addCard(Zone.BATTLEFIELD, playerB, "Stranglehold"); + + addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); + // Search your library for a basic land card and put that card onto the battlefield tapped. Then shuffle your library. + addCard(Zone.HAND, playerA, "Rampant Growth", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Rampant Growth"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Rampant Growth", 1); + assertPermanentCount(playerA, 2); // only the two forests + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/single/ChronozoaTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/single/ChronozoaTest.java new file mode 100644 index 00000000000..7125bdce733 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/single/ChronozoaTest.java @@ -0,0 +1,101 @@ +package org.mage.test.cards.single; + +import java.util.List; + +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.counters.Counter; +import mage.counters.CounterType; +import mage.counters.Counters; +import mage.game.permanent.Permanent; +import mage.game.permanent.PermanentToken; + +import org.junit.Assert; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * Created by glerman on 22/6/15. + */ +public class ChronozoaTest extends CardTestPlayerBase { + // Flying + // Vanishing 3 + // When Chronozoa dies, if it had no time counters on it, put two tokens that are copies of it onto the battlefield. + + /** + * Test that time counters are removed before the draw phase + */ + @Test + public void testVanishing() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); + addCard(Zone.HAND, playerA, "Chronozoa"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chronozoa"); + + setStopAt(5, PhaseStep.DRAW); + execute(); + + // Make sure one time counter was removed at beginning of playerA turn num 3 + assertCounterCount("Chronozoa", CounterType.TIME, 1); + } + + /** + * Test that the tokens are put to battlefield if the last time counter is removed + */ + @Test + public void testDuplicationEffect() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); + addCard(Zone.HAND, playerA, "Chronozoa"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chronozoa"); + + setStopAt(9, PhaseStep.PRECOMBAT_MAIN); + execute(); + + // The original Chronozoa card should be in graveyard + assertGraveyardCount(playerA, 1); + + final List creatures = currentGame.getBattlefield().getAllActivePermanents(CardType.CREATURE); + Assert.assertEquals(2, creatures.size()); + + for (final Permanent creature : creatures) { + // Make sure the creatures are Chronozoa tokens + Assert.assertEquals("Chronozoa", creature.getName()); + Assert.assertEquals("Chronozoa has to be a token", true, creature instanceof PermanentToken); + + // Make sure each token has 2 time counters + final Counters counters = creature.getCounters(); + Assert.assertEquals(1, counters.size()); + for(final Counter counter : counters.values()) { + Assert.assertEquals(CounterType.TIME.getName(), counter.getName()); + Assert.assertEquals(2, counter.getCount()); + } + } + } + + @Test + public void testChronozoaDestroyedWithTimeCounters() throws Exception { + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); + addCard(Zone.HAND, playerA, "Chronozoa"); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); + addCard(Zone.HAND, playerB, "Lightning Bolt"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chronozoa"); + // Destroy Chronozoa the same phase it should duplicate -> due to stack Chronozoa is destroyed before duplication + castSpell(7, PhaseStep.UPKEEP, playerB, "Lightning Bolt", "Chronozoa"); + + setStopAt(7, PhaseStep.PRECOMBAT_MAIN); + execute(); + + // Chronozoa in gy + assertGraveyardCount(playerA, 1); + // Lightning Bolt in gt + assertGraveyardCount(playerB, 1); + + // Chronozoa shouldn't duplicate + final List creatures = currentGame.getBattlefield().getAllActivePermanents(CardType.CREATURE); + Assert.assertTrue(creatures.isEmpty()); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/single/DustOfMomentsTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/single/DustOfMomentsTest.java new file mode 100644 index 00000000000..bd0af195e47 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/single/DustOfMomentsTest.java @@ -0,0 +1,61 @@ +package org.mage.test.cards.single; + +import java.util.List; + +import mage.constants.CardType; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.permanent.Permanent; + +import org.junit.Assert; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * Created by glerman on 29/6/15. + */ +public class DustOfMomentsTest extends CardTestPlayerBase { + + @Test + public void testRemoveCounters() throws Exception { + initGame(); + setModeChoice(playerA, "1"); // Chose the remove 2 time counters option + setStopAt(3, PhaseStep.END_TURN); + execute(); + + // Chronozoa should have duplicated + final List activeCreatures = currentGame.getBattlefield().getAllActivePermanents(CardType.CREATURE); + Assert.assertEquals(2, activeCreatures.size()); + + for (final Permanent creature : activeCreatures) { + Assert.assertEquals("Chronozoa", creature.getName()); + Assert.assertEquals(3, creature.getCounters().getCount(CounterType.TIME)); + } + // Check time counters on kraken + assertCounterOnExiledCardCount("Deep-Sea Kraken", CounterType.TIME, 6); + } + + @Test + public void testAddCounters() throws Exception { + initGame(); + setModeChoice(playerA, "2"); // Chose the add 2 time counters option + setStopAt(3, PhaseStep.END_TURN); + execute(); + + assertCounterCount("Chronozoa", CounterType.TIME, 4); + assertCounterOnExiledCardCount("Deep-Sea Kraken", CounterType.TIME, 10); + } + + private void initGame() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 7); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.HAND, playerA, "Chronozoa"); + addCard(Zone.HAND, playerA, "Deep-Sea Kraken"); + addCard(Zone.HAND, playerA, "Dust of Moments"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Chronozoa"); + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Suspend"); // Casts Deep-Sea Kraken as Suspend + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Dust of Moments"); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/single/NornsAnnexTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/single/NornsAnnexTest.java new file mode 100644 index 00000000000..2336b6aa895 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/single/NornsAnnexTest.java @@ -0,0 +1,27 @@ +package org.mage.test.cards.single; + +import mage.constants.PhaseStep; +import mage.constants.Zone; + +import org.junit.Ignore; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * Created by glerman on 23/6/15. + */ +@Ignore +public class NornsAnnexTest extends CardTestPlayerBase{ + @Test + @Ignore + public void testNornsAnnex() { + addCard(Zone.BATTLEFIELD, playerA, "Norn's Annex"); + addCard(Zone.BATTLEFIELD, playerB, "Brindle Boar"); + attack(2, playerB, "Brindle Boar", playerA); + setStopAt(2, PhaseStep.END_TURN); + execute(); + + + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/single/OmniscienceTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/single/OmniscienceTest.java index a75dbc61e3d..ad4f7febe71 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/single/OmniscienceTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/single/OmniscienceTest.java @@ -25,11 +25,11 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package org.mage.test.cards.single; import mage.constants.PhaseStep; import mage.constants.Zone; +import org.junit.Ignore; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBase; @@ -37,27 +37,24 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author LevelX2 */ - public class OmniscienceTest extends CardTestPlayerBase { /** - * Omniscience {7}{U}{U}{U} + * Omniscience {7}{U}{U}{U} * - * Enchantment - * You may cast nonland cards from your hand without paying their mana costs. + * Enchantment You may cast nonland cards from your hand without paying + * their mana costs. * */ - @Test public void testCastingCreature() { addCard(Zone.BATTLEFIELD, playerA, "Omniscience"); - - /* player.getPlayable does not take alternate - casting costs in account, so for the test the mana has to be available - but won't be used - */ - addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); + /* player.getPlayable does not take alternate + casting costs in account, so for the test the mana has to be available + but won't be used + */ + addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); addCard(Zone.HAND, playerA, "Silvercoat Lion"); @@ -80,7 +77,7 @@ public class OmniscienceTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Island", 1); addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); - + // Fire deals 2 damage divided as you choose among one or two target creatures and/or players. addCard(Zone.HAND, playerA, "Fire // Ice"); @@ -94,7 +91,7 @@ public class OmniscienceTest extends CardTestPlayerBase { assertLife(playerA, 20); assertLife(playerB, 18); - + assertTapped("Island", false); assertTapped("Mountain", false); } @@ -104,9 +101,9 @@ public class OmniscienceTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Omniscience"); /* player.getPlayable does not take alternate - casting costs in account, so for the test the mana has to be available - but won't be used - */ + casting costs in account, so for the test the mana has to be available + but won't be used + */ addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); addCard(Zone.BATTLEFIELD, playerA, "Ornithopter", 1); @@ -124,12 +121,13 @@ public class OmniscienceTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Ornithopter", 1); assertTapped("Mountain", false); } - /** - * Spell get cast for 0 if Omniscience is being in play. - * But with Trinisphere it costs at least {3}. - * Cost/alternate cost (Omniscience) + additional costs - cost reductions + minimum cost (Trinishpere) = total cost. - */ + /** + * Spell get cast for 0 if Omniscience is being in play. But with + * Trinisphere it costs at least {3}. Cost/alternate cost (Omniscience) + + * additional costs - cost reductions + minimum cost (Trinishpere) = total + * cost. + */ @Test public void testCastingWithTrinisphere() { addCard(Zone.BATTLEFIELD, playerA, "Omniscience"); @@ -153,4 +151,45 @@ public class OmniscienceTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Silvercoat Lion", 1); assertTapped("Plains", true); // plains have to be tapped because {3} have to be paid } + + /** + * Omniscience is not allowing me to cast spells for free. I'm playing a + * Commander game against the Computer, if that helps. + * + * Edit: It's not letting me cast fused spells for free. Others seems to be + * working. + */ + @Test + @Ignore // targeting of fused/split spells not supported by thestplayer + public void testCastingFusedSpell() { + addCard(Zone.BATTLEFIELD, playerA, "Omniscience"); + addCard(Zone.BATTLEFIELD, playerA, "Island", 2); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 3); + addCard(Zone.BATTLEFIELD, playerA, "Silvercoat Lion"); + + addCard(Zone.BATTLEFIELD, playerB, "Pillarfield Ox"); + + /* + * Instant + * Far {1}{U} Return target creature to its owner's hand. + * Away{2}{B} Target player sacrifices a creature. + * Fuse (You may cast one or both halves of this card from your hand.) + */ + addCard(Zone.HAND, playerA, "Far // Away"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "fused Far // Away", "Silvercoat Lion^targetPlayer=PlayerB"); + playerB.addTarget("Pillarfield Ox"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertHandCount(playerA, 1); + assertHandCount(playerB, 0); + + assertGraveyardCount(playerA, "Far // Away", 1); + + assertPermanentCount(playerB, "Pillarfield Ox", 0); + assertGraveyardCount(playerB, "Pillarfield Ox", 1); + } + } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/SpellskiteTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/SpellskiteTest.java index 083a1936058..0eed350bc6f 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/SpellskiteTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/SpellskiteTest.java @@ -36,11 +36,11 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author LevelX2 */ - public class SpellskiteTest extends CardTestPlayerBase { /** - * Tests that Wild Defiance triggers for Spellskite if spell target is changed to Spellskite + * Tests that Wild Defiance triggers for Spellskite if spell target is + * changed to Spellskite */ @Test public void testDisabledEffectOnChangeZone() { @@ -64,19 +64,22 @@ public class SpellskiteTest extends CardTestPlayerBase { assertLife(playerB, 20); assertPowerToughness(playerA, "Spellskite", 3, 7); - + } /** - * If Spellskite changes controller, its activated ability can activate but doesn't resolve properly. - * - * The specific instance was a Spellskite controlled by Vedalken Shackles. Land was targeted by Frost Titan, - * controller (not owner) of Spellskite paid the redirection cost, ability went on the stack, seemed to resolve, + * If Spellskite changes controller, its activated ability can activate but + * doesn't resolve properly. + * + * The specific instance was a Spellskite controlled by Vedalken Shackles. + * Land was targeted by Frost Titan, controller (not owner) of Spellskite + * paid the redirection cost, ability went on the stack, seemed to resolve, * target never changed. - * + * */ /** - * TODO: This test fails sometimes when building the complete Test Project -> Find the reason + * TODO: This test fails sometimes when building the complete Test Project + * -> Find the reason */ @Test public void testAfterChangeOfController() { @@ -88,17 +91,17 @@ public class SpellskiteTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerB, "Island", 6); // {UP}: Change a target of target spell or ability to Spellskite. - addCard(Zone.BATTLEFIELD, playerB, "Spellskite", 1); + addCard(Zone.BATTLEFIELD, playerB, "Spellskite", 1); // {4}{U}{U} - // Whenever Frost Titan becomes the target of a spell or ability an opponent controls, counter that spell or ability unless its controller pays 2. + // Whenever Frost Titan becomes the target of a spell or ability an opponent controls, counter that spell or ability unless its controller pays 2. // Whenever Frost Titan enters the battlefield or attacks, tap target permanent. It doesn't untap during its controller's next untap step. addCard(Zone.HAND, playerB, "Frost Titan", 1); - + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{2},{T}: Gain control", "Spellskite"); castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerB, "Frost Titan"); addTarget(playerB, "Silvercoat Lion"); - + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerA, "{UP}: Change a target", "stack ability (Whenever {this} enters "); setStopAt(2, PhaseStep.BEGIN_COMBAT); @@ -106,13 +109,13 @@ public class SpellskiteTest extends CardTestPlayerBase { assertPermanentCount(playerA, "Spellskite", 1); assertPermanentCount(playerB, "Frost Titan", 1); - + assertTapped("Spellskite", true); // (Battlefield) Tapped state is not equal (Silvercoat Lion) expected: but was: assertTapped("Silvercoat Lion", false); - - } - + + } + /** * Spellskite fails to redirect Cryptic Command on itself */ @@ -123,21 +126,21 @@ public class SpellskiteTest extends CardTestPlayerBase { // Counter target spell; // or return target permanent to its owner's hand; // or tap all creatures your opponents control; - // or draw a card. + // or draw a card. addCard(Zone.HAND, playerA, "Cryptic Command"); - + addCard(Zone.BATTLEFIELD, playerB, "Spellskite", 1); addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); addCard(Zone.BATTLEFIELD, playerB, "Mountain", 1); addCard(Zone.BATTLEFIELD, playerB, "Island", 1); addCard(Zone.HAND, playerB, "Lightning Bolt", 1); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Lightning Bolt", playerA); - - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Cryptic Command", "mode=1Lightning Bolt^mode=2Silvercoat Lion", "Lightning Bolt"); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Cryptic Command", "mode=1Lightning Bolt^mode=2Silvercoat Lion", "Lightning Bolt"); setModeChoice(playerA, "1"); // Counter target spell - setModeChoice(playerA, "2"); // return target permanent to its owner's hand - + setModeChoice(playerA, "2"); // return target permanent to its owner's hand + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerB, "{UP}: Change a target of target spell or ability to {this}.", "Cryptic Command"); setStopAt(1, PhaseStep.BEGIN_COMBAT); @@ -146,12 +149,52 @@ public class SpellskiteTest extends CardTestPlayerBase { assertGraveyardCount(playerB, "Lightning Bolt", 1); assertGraveyardCount(playerA, "Cryptic Command", 1); - + assertHandCount(playerB, "Spellskite", 1); assertPermanentCount(playerB, "Silvercoat Lion", 1); assertLife(playerA, 20); assertLife(playerB, 20); - - } -} \ No newline at end of file + + } + + /** + * My opponent cast Cryptic Command tapping all of my creatures and bouncing + * a Blade Splicer token I had. I activated a Spellskite but got an error + * stating that Spellskite is not a legal target. + */ + @Test + public void testSpellskite2() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); + // Choose two - + // Counter target spell; + // or return target permanent to its owner's hand; + // or tap all creatures your opponents control; + // or draw a card. + addCard(Zone.HAND, playerA, "Cryptic Command"); + + addCard(Zone.BATTLEFIELD, playerB, "Spellskite", 1); + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); + + addCard(Zone.BATTLEFIELD, playerB, "Island", 1); + + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerA, "Cryptic Command", "mode=2Silvercoat Lion"); + setModeChoice(playerA, "2"); // return target permanent to its owner's hand + setModeChoice(playerA, "3"); // tap all creatures your opponents control + + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerB, "{UP}: Change a target of target spell or ability to {this}.", "Cryptic Command"); + + setStopAt(2, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Cryptic Command", 1); + + assertHandCount(playerB, "Spellskite", 1); + assertPermanentCount(playerB, "Silvercoat Lion", 1); + assertTapped("Silvercoat Lion", true); + + assertLife(playerA, 20); + assertLife(playerB, 20); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/combat/damage/GravebladeMarauderTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/combat/damage/GravebladeMarauderTest.java new file mode 100644 index 00000000000..bab7f3ca404 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/combat/damage/GravebladeMarauderTest.java @@ -0,0 +1,58 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.triggers.combat.damage; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class GravebladeMarauderTest extends CardTestPlayerBase { + + @Test + public void testTwoAttackers() { + addCard(Zone.GRAVEYARD, playerB, "Silvercoat Lion", 3); + + // Whenever Graveblade Marauder deals combat damage to a player, that player loses life equal to the number of creature cards in your graveyard. + addCard(Zone.BATTLEFIELD, playerB, "Graveblade Marauder", 2);// 1/4 + + attack(2, playerB, "Graveblade Marauder"); + attack(2, playerB, "Graveblade Marauder"); + + setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + assertLife(playerA, 12); // 1 + 3 + 1 + 3 = 8 + assertLife(playerB, 20); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/PutIntoGraveTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/PutIntoGraveTest.java new file mode 100644 index 00000000000..50b07342741 --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/PutIntoGraveTest.java @@ -0,0 +1,68 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.triggers.dies; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class PutIntoGraveTest extends CardTestPlayerBase { + + /** + * When I go to Nature's Claim my Chromatic Star, I dont end up drawing a + * card. + */ + @Test + public void testDiesTriggeredAbility() { + addCard(Zone.BATTLEFIELD, playerA, "Forest", 1); + // Destroy target artifact or enchantment. Its controller gains 4 life. + addCard(Zone.HAND, playerA, "Nature's Claim", 1); + + // {1}, {T}, Sacrifice Chromatic Star: Add one mana of any color to your mana pool. + // When Chromatic Star is put into a graveyard from the battlefield, draw a card. + addCard(Zone.BATTLEFIELD, playerA, "Chromatic Star", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Nature's Claim", "Chromatic Star"); + + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertLife(playerA, 24); + + assertGraveyardCount(playerA, "Nature's Claim", 1); + assertGraveyardCount(playerA, "Chromatic Star", 1); + + assertHandCount(playerA, 1); + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/ReefWormTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/ReefWormTest.java index 7c57a3d80fe..def1af26a6c 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/ReefWormTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/ReefWormTest.java @@ -34,9 +34,9 @@ import org.mage.test.serverside.base.CardTestPlayerBase; /** * Checks that a dies triggered ability of a Token works + * * @author LevelX2 */ - public class ReefWormTest extends CardTestPlayerBase { @Test @@ -50,16 +50,18 @@ public class ReefWormTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerB, "Reef Worm", 1); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", "Reef Worm"); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", "Fish"); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", "Whale"); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Lightning Bolt", "Whale"); + castSpell(1, PhaseStep.BEGIN_COMBAT, playerA, "Lightning Bolt", "Fish"); + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Lightning Bolt", "Whale"); + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Lightning Bolt", "Whale"); - setStopAt(1, PhaseStep.BEGIN_COMBAT); + setStopAt(1, PhaseStep.END_TURN); execute(); assertLife(playerA, 20); assertLife(playerB, 20); + assertGraveyardCount(playerA, "Lightning Bolt", 4); + assertPermanentCount(playerB, "Fish", 0); assertPermanentCount(playerB, "Whale", 0); assertPermanentCount(playerB, "Kraken", 1); @@ -68,4 +70,4 @@ public class ReefWormTest extends CardTestPlayerBase { assertGraveyardCount(playerA, "Lightning Bolt", 4); } -} \ No newline at end of file +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/SidisiBroodTyrantTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/SidisiBroodTyrantTest.java index 2971d74545b..eaaefeed1d8 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/SidisiBroodTyrantTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/SidisiBroodTyrantTest.java @@ -36,12 +36,12 @@ import org.mage.test.serverside.base.CardTestPlayerBase; * * @author LevelX2 */ - public class SidisiBroodTyrantTest extends CardTestPlayerBase { /** - * Tests that if Sidisi, Brood Tyrant leaves the battlefield - * before it's first ability resolves, there will be no Zombie token added to the battlefield + * Tests that if Sidisi, Brood Tyrant leaves the battlefield before it's + * first ability resolves, there will be no Zombie token added to the + * battlefield * */ @Test @@ -73,4 +73,43 @@ public class SidisiBroodTyrantTest extends CardTestPlayerBase { } + /** + * Another potential bug would be related to Sidisi, Brood Tyrant 's second + * trigger. If there is one in play and I play a Satyr Wayfinder or a Gather + * the Pack, then mill some creatures, Sidisi should trigger and make a + * Zombie token, right? This doesn't seem to work currently. + * + */ + @Test + public void testDiesTriggeredAbilityNormal() { + // {1}{B}{G}{U} + // Whenever Sidisi, Brood Tyrant enters the battlefield or attacks, put the top three cards of your library into your graveyard + // Whenever one or more creature cards are put into your graveyard from your library, put a 2/2 black Zombie creature token onto the battlefield. + addCard(Zone.HAND, playerA, "Sidisi, Brood Tyrant"); // 2/2 {1}{B}{G}{U} + + // When Satyr Wayfinder enters the battlefield, reveal the top four cards of your library. You may put a land card from among them into your hand. Put the rest into your graveyard. + addCard(Zone.HAND, playerA, "Satyr Wayfinder"); // 1/1 {1}{G} + + addCard(Zone.BATTLEFIELD, playerA, "Swamp"); + addCard(Zone.BATTLEFIELD, playerA, "Forest", 4); + addCard(Zone.BATTLEFIELD, playerA, "Island"); + addCard(Zone.LIBRARY, playerA, "Silvercoat Lion", 3); + addCard(Zone.LIBRARY, playerA, "Swamp", 1); + addCard(Zone.LIBRARY, playerA, "Silvercoat Lion", 3); + skipInitShuffling(); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Sidisi, Brood Tyrant"); + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Satyr Wayfinder"); + setChoice(playerA, "Yes"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertPermanentCount(playerA, "Sidisi, Brood Tyrant", 1); + assertPermanentCount(playerA, "Satyr Wayfinder", 1); + assertHandCount(playerA, "Swamp", 1); + assertGraveyardCount(playerA, "Silvercoat Lion", 6); + assertPermanentCount(playerA, "Zombie", 2); + + } } diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/TouchOfMoongloveTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/TouchOfMoongloveTest.java new file mode 100644 index 00000000000..432d69d6c9b --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/triggers/dies/TouchOfMoongloveTest.java @@ -0,0 +1,83 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.cards.triggers.dies; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class TouchOfMoongloveTest extends CardTestPlayerBase { + + /** + * I blocked my opponent's Pharika's Disciple with a Cleric of the Forward + * Order and Guardian Automaton. He cast Touch of Moonglove on his Pharika's + * Disciple and both of my creatures were killed, but I only lost 2 life + * instead of 4.(and gained 3 from Guardian Automaton dying). + * + */ + @Test + public void testDiesAndControllerDamage() { + addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); + // When Cleric of the Forward Order enters the battlefield, you gain 2 life for each creature you control named Cleric of the Forward Order. + addCard(Zone.HAND, playerA, "Cleric of the Forward Order", 1); + // When Guardian Automaton dies, you gain 3 life. + addCard(Zone.BATTLEFIELD, playerA, "Guardian Automaton", 1); // 3/3 + + addCard(Zone.BATTLEFIELD, playerB, "Swamp", 1); + // Target creature you control gets +1/+0 and gains deathtouch until end of turn. + // Whenever a creature dealt damage by that creature this turn dies, its controller loses 2 life. + addCard(Zone.HAND, playerB, "Touch of Moonglove"); // {B} + addCard(Zone.BATTLEFIELD, playerB, "Pharika's Disciple", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Cleric of the Forward Order"); + attack(2, playerB, "Pharika's Disciple"); + block(2, playerA, "Cleric of the Forward Order", "Pharika's Disciple"); + block(2, playerA, "Guardian Automaton", "Pharika's Disciple"); + + castSpell(2, PhaseStep.DECLARE_BLOCKERS, playerB, "Touch of Moonglove", "Pharika's Disciple"); + + setStopAt(2, PhaseStep.POSTCOMBAT_MAIN); + execute(); + + assertGraveyardCount(playerB, "Touch of Moonglove", 1); + assertGraveyardCount(playerA, "Cleric of the Forward Order", 1); + assertGraveyardCount(playerB, "Pharika's Disciple", 1); + + assertGraveyardCount(playerA, "Guardian Automaton", 1); + + assertLife(playerA, 21); // +2 by Cleric + 2x -2 by Touch +3 by Guardian Automation + assertLife(playerB, 20); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/watchers/BoseijuTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/watchers/BoseijuTest.java index 63340f54f37..e19a37ef2e4 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/watchers/BoseijuTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/watchers/BoseijuTest.java @@ -14,30 +14,33 @@ public class BoseijuTest extends CardTestPlayerBase { * Boseiju, Who Shelters All * Legendary Land * Boseiju, Who Shelters All enters the battlefield tapped. - * {T}, Pay 2 life: Add {1} to your mana pool. If that mana is spent on an + * {T}, Pay 2 life: Add {1} to your mana pool. If that mana is spent on an * instant or sorcery spell, that spell can't be countered by spells or abilities. * - */ - + */ + // test that instants and soceries can't be countered when Boseiju mana is used @Test public void testCantCounter() { - addCard(Zone.BATTLEFIELD, playerA, "Island", 6); + addCard(Zone.BATTLEFIELD, playerA, "Island", 4); addCard(Zone.BATTLEFIELD, playerA, "Boseiju, Who Shelters All"); - addCard(Zone.HAND, playerA, "Brilliant Plan"); - addCard(Zone.HAND, playerA, "Counterspell"); - + addCard(Zone.BATTLEFIELD, playerB, "Island", 2); + // Draw three cards. + addCard(Zone.HAND, playerA, "Brilliant Plan"); // {4}{U} + + addCard(Zone.HAND, playerB, "Counterspell"); // {U}{U} + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Brilliant Plan"); - castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Counterspell", "Brilliant Plan"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerB, "Counterspell", "Brilliant Plan"); + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - + this.assertHandCount(playerA, 3); - this.assertGraveyardCount(playerA, "Counterspell", 1); - + this.assertGraveyardCount(playerB, "Counterspell", 1); + } - + // test that instants and soceries can be countered when Boseiju mana is not used @Test public void testCanCounter() { @@ -45,16 +48,16 @@ public class BoseijuTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Boseiju, Who Shelters All"); addCard(Zone.HAND, playerA, "Mental Note"); addCard(Zone.HAND, playerA, "Counterspell"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Mental Note"); castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Counterspell", "Mental Note"); - + setStopAt(1, PhaseStep.BEGIN_COMBAT); execute(); - + this.assertHandCount(playerA, 0); this.assertGraveyardCount(playerA, 2); - + } - + } diff --git a/Mage.Tests/src/test/java/org/mage/test/commander/duel/CommanderManaReplacmentTest.java b/Mage.Tests/src/test/java/org/mage/test/commander/duel/CommanderManaReplacmentTest.java new file mode 100644 index 00000000000..84ee71449bd --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/commander/duel/CommanderManaReplacmentTest.java @@ -0,0 +1,82 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.commander.duel; + +import java.io.FileNotFoundException; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.GameException; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestCommanderDuelBase; + +/** + * + * @author LevelX2 + */ +public class CommanderManaReplacmentTest extends CardTestCommanderDuelBase { + + @Override + protected Game createNewGameAndPlayers() throws GameException, FileNotFoundException { + setDecknamePlayerA("CommanderDuel_UW.dck"); // Commander = Daxos of Meletis + return super.createNewGameAndPlayers(); + } + + /** + * This issue appears to arise in both Commander Two Player Duel and + * Commander Free For All. Whenever a player (call her player 1) controls a + * permanent with a mana doubling continuous effect (e.g. Mana Flare) and + * another player (call her player 2) taps an affected permanent for mana + * that is outside of player 1's color identity, player 2 gets an additional + * colorless mana rather than the correct color of mana. I suspect the + * reason for this is that Xmage is treating Mana Flare as producing mana of + * the appropriate color and adding it to another player's mana pool, which + * is both incorrect in the game rules and would cause this problem. + * + * For example, I am playing a mono red deck and control a Mana Flare. You + * are playing a mono green deck and you tap a Forest for mana. You should + * add GG to your mana pool, but instead, Xmage shows you adding 1G to your + * mana pool. + */ + @Test + public void castCommanderWithFlash() { + addCard(Zone.BATTLEFIELD, playerA, "Island", 1); + addCard(Zone.HAND, playerA, "Vedalken Mastermind", 1); // {U}{U} + + addCard(Zone.BATTLEFIELD, playerB, "Mana Flare"); + + activateManaAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "{T}: Add {U}"); // should add {U}{U} + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Vedalken Mastermind"); + setStopAt(1, PhaseStep.PRECOMBAT_MAIN); + execute(); + + assertPermanentCount(playerA, "Vedalken Mastermind", 1); + + } + +} diff --git a/Mage.Tests/src/test/java/org/mage/test/commander/duel/NorinTheWaryTest.java b/Mage.Tests/src/test/java/org/mage/test/commander/duel/NorinTheWaryTest.java new file mode 100644 index 00000000000..cb5e232b7ef --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/commander/duel/NorinTheWaryTest.java @@ -0,0 +1,118 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.commander.duel; + +import java.io.FileNotFoundException; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.GameException; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestCommanderDuelBase; + +/** + * + * @author LevelX2 + */ +public class NorinTheWaryTest extends CardTestCommanderDuelBase { + + @Override + protected Game createNewGameAndPlayers() throws GameException, FileNotFoundException { + // When a player casts a spell or a creature attacks, exile Norin the Wary. Return it to the battlefield under its owner's control at the beginning of the next end step. + setDecknamePlayerA("CMDNorinTheWary.dck"); // Commander = Norin the Wary {R} + return super.createNewGameAndPlayers(); + } + + @Test + public void castNorinTheWary() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Norin the Wary"); + setStopAt(1, PhaseStep.BEGIN_COMBAT); + execute(); + + assertPermanentCount(playerA, "Norin the Wary", 1); + } + + @Test + public void castNorinTheWaryToExile() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.HAND, playerA, "Lightning Bolt", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Norin the Wary"); + castSpell(1, PhaseStep.BEGIN_COMBAT, playerA, "Lightning Bolt", playerB); + setChoice(playerA, "No"); + setStopAt(1, PhaseStep.END_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Lightning Bolt", 1); + assertPermanentCount(playerA, "Norin the Wary", 0); + assertExileCount("Norin the Wary", 1); + + assertLife(playerB, 37); + + } + + @Test + public void castNorinTheWaryToExileAndReturn() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.HAND, playerA, "Lightning Bolt", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Norin the Wary"); + castSpell(1, PhaseStep.BEGIN_COMBAT, playerA, "Lightning Bolt", playerB); + setChoice(playerA, "No"); + setStopAt(2, PhaseStep.UPKEEP); + execute(); + + assertGraveyardCount(playerA, "Lightning Bolt", 1); + assertPermanentCount(playerA, "Norin the Wary", 1); + assertExileCount("Norin the Wary", 0); + + assertLife(playerB, 37); + + } + + @Test + public void castNorinTheWaryToCommandAndReturn() { + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 2); + addCard(Zone.HAND, playerA, "Lightning Bolt", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Norin the Wary"); + castSpell(1, PhaseStep.BEGIN_COMBAT, playerA, "Lightning Bolt", playerB); + setChoice(playerA, "Yes"); + setStopAt(2, PhaseStep.UPKEEP); + execute(); + + assertGraveyardCount(playerA, "Lightning Bolt", 1); + assertPermanentCount(playerA, "Norin the Wary", 1); + assertExileCount("Norin the Wary", 0); + + assertLife(playerB, 37); + + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/multiplayer/BloodchiefAscensionTest.java b/Mage.Tests/src/test/java/org/mage/test/multiplayer/BloodchiefAscensionTest.java index abad3873732..54944174eae 100644 --- a/Mage.Tests/src/test/java/org/mage/test/multiplayer/BloodchiefAscensionTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/multiplayer/BloodchiefAscensionTest.java @@ -39,108 +39,156 @@ import org.mage.test.serverside.base.CardTestMultiPlayerBase; * @author LevelX2 */ public class BloodchiefAscensionTest extends CardTestMultiPlayerBase { - - @Test + + @Test public void testBloodchiefAscensionAllPlayers() { // Enchantment // At the beginning of each end step, if an opponent lost 2 or more life this turn, you may put a quest counter on Bloodchief Ascension. (Damage causes loss of life.) - // Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life. + // Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life. addCard(Zone.BATTLEFIELD, playerA, "Bloodchief Ascension"); - - addCard(Zone.BATTLEFIELD, playerA, "Mountain",3); + + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); addCard(Zone.HAND, playerA, "Fireball"); - addCard(Zone.BATTLEFIELD, playerD, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerD, "Mountain", 3); addCard(Zone.HAND, playerD, "Fireball"); - addCard(Zone.BATTLEFIELD, playerC, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerC, "Mountain", 3); addCard(Zone.HAND, playerC, "Fireball"); - addCard(Zone.BATTLEFIELD, playerB, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 3); addCard(Zone.HAND, playerB, "Fireball"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Fireball", playerA); setChoice(playerA, "X=2"); - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerD, "Fireball", playerD); setChoice(playerD, "X=2"); - + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerC, "Fireball", playerC); setChoice(playerC, "X=2"); - + castSpell(4, PhaseStep.PRECOMBAT_MAIN, playerB, "Fireball", playerB); setChoice(playerB, "X=2"); - - // Player order: A -> D -> C -> B + // Player order: A -> D -> C -> B setStopAt(4, PhaseStep.END_TURN); execute(); - + assertLife(playerA, 18); assertLife(playerB, 18); assertLife(playerC, 18); assertLife(playerD, 18); - + assertGraveyardCount(playerA, "Fireball", 1); assertGraveyardCount(playerB, "Fireball", 1); assertGraveyardCount(playerC, "Fireball", 1); assertGraveyardCount(playerD, "Fireball", 1); - - assertCounterCount("Bloodchief Ascension", CounterType.QUEST, 2); // 1 opponent out of range - } - /** - * One of my opponents in a multiplayer game had a Bloodchief Ascension in play. I took lethal damage on my turn, - * but he didn't get a counter on Bloodchief Ascension at my end step. I think he should, even though I had left - * the game from dying, because of: - * - * 800.4g. If a player leaves the game during his or her turn, that turn continues to its completion without an - * active player. If the active player would receive priority, instead the next player in turn order receives priority, - * or the top object on the stack resolves, or the phase or step ends, whichever is appropriate. - */ + } + + /** + * One of my opponents in a multiplayer game had a Bloodchief Ascension in + * play. I took lethal damage on my turn, but he didn't get a counter on + * Bloodchief Ascension at my end step. I think he should, even though I had + * left the game from dying, because of: + * + * 800.4g. If a player leaves the game during his or her turn, that turn + * continues to its completion without an active player. If the active + * player would receive priority, instead the next player in turn order + * receives priority, or the top object on the stack resolves, or the phase + * or step ends, whichever is appropriate. + */ @Test public void testBloodchiefAscension() { // Enchantment // At the beginning of each end step, if an opponent lost 2 or more life this turn, you may put a quest counter on Bloodchief Ascension. (Damage causes loss of life.) - // Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life. + // Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life. addCard(Zone.BATTLEFIELD, playerA, "Bloodchief Ascension"); - addCard(Zone.BATTLEFIELD, playerA, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerA, "Mountain", 3); addCard(Zone.HAND, playerA, "Fireball"); - addCard(Zone.BATTLEFIELD, playerD, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerD, "Mountain", 3); addCard(Zone.HAND, playerD, "Fireball"); - addCard(Zone.BATTLEFIELD, playerC, "Mountain",3); + addCard(Zone.BATTLEFIELD, playerC, "Mountain", 3); addCard(Zone.HAND, playerC, "Fireball"); - addCard(Zone.BATTLEFIELD, playerB, "Mountain",21); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 21); addCard(Zone.HAND, playerB, "Fireball"); - + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Fireball", playerA); setChoice(playerA, "X=2"); - + castSpell(2, PhaseStep.PRECOMBAT_MAIN, playerD, "Fireball", playerD); setChoice(playerD, "X=2"); - + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerC, "Fireball", playerC); setChoice(playerC, "X=2"); - + castSpell(4, PhaseStep.PRECOMBAT_MAIN, playerB, "Fireball", playerB); setChoice(playerB, "X=20"); - - // Player order: A -> D -> C -> B + // Player order: A -> D -> C -> B setStopAt(4, PhaseStep.END_TURN); execute(); - + assertLife(playerA, 18); assertLife(playerB, 0); assertLife(playerC, 18); assertLife(playerD, 18); - + Assert.assertTrue("playerB has lost", playerB.hasLost()); - + assertGraveyardCount(playerA, "Fireball", 1); assertGraveyardCount(playerC, "Fireball", 1); - assertGraveyardCount(playerD, "Fireball", 1); - - assertCounterCount("Bloodchief Ascension", CounterType.QUEST, 2); // 1 opponent out of range + assertGraveyardCount(playerD, "Fireball", 1); + + assertCounterCount("Bloodchief Ascension", CounterType.QUEST, 2); // 1 opponent out of range + + } + + /** + * Bloodchief Ascension effect is not working corretly on multiplayer. + * Whenever one player activated Jace's Archivist, the damage of the + * discarded cards was going on a single player, not on the players who + * discarded the cards. + */ + @Test + public void testJacesArchivist() { + // Enchantment + // At the beginning of each end step, if an opponent lost 2 or more life this turn, you may put a quest counter on Bloodchief Ascension. (Damage causes loss of life.) + // Whenever a card is put into an opponent's graveyard from anywhere, if Bloodchief Ascension has three or more quest counters on it, you may have that player lose 2 life. If you do, you gain 2 life. + + skipInitShuffling(); + addCard(Zone.LIBRARY, playerA, "Auramancer"); + addCard(Zone.HAND, playerA, "Auramancer", 2); + + addCard(Zone.BATTLEFIELD, playerD, "Bloodchief Ascension"); + addCounters(2, PhaseStep.UPKEEP, playerD, "Bloodchief Ascension", CounterType.QUEST, 3); + addCard(Zone.BATTLEFIELD, playerD, "Island", 1); + // {U}, {T}: Each player discards his or her hand, then draws cards equal to the greatest number of cards a player discarded this way. + addCard(Zone.BATTLEFIELD, playerD, "Jace's Archivist", 1); // {1}{U}{U} + addCard(Zone.LIBRARY, playerD, "Demolish"); + addCard(Zone.HAND, playerD, "Demolish", 1); + + addCard(Zone.HAND, playerC, "Cobblebrute", 4); + addCard(Zone.HAND, playerB, "Bellows Lizard", 5); + + // Player order: A -> D -> C -> B + activateAbility(2, PhaseStep.PRECOMBAT_MAIN, playerD, "{U},{T}: Each player discards"); + setStopAt(2, PhaseStep.BEGIN_COMBAT); + execute(); + + assertGraveyardCount(playerA, "Auramancer", 3); + assertGraveyardCount(playerD, "Demolish", 2); + assertGraveyardCount(playerC, "Cobblebrute", 4); + + assertHandCount(playerA, 4); + assertHandCount(playerD, 4); + assertHandCount(playerC, 4); + assertHandCount(playerB, "Bellows Lizard", 5); + + assertLife(playerA, 14); + assertLife(playerD, 34); + assertLife(playerC, 12); + assertLife(playerB, 20); } } diff --git a/Mage.Tests/src/test/java/org/mage/test/player/TestPlayer.java b/Mage.Tests/src/test/java/org/mage/test/player/TestPlayer.java index adb8160badd..7806999ead1 100644 --- a/Mage.Tests/src/test/java/org/mage/test/player/TestPlayer.java +++ b/Mage.Tests/src/test/java/org/mage/test/player/TestPlayer.java @@ -253,6 +253,9 @@ public class TestPlayer implements Player { int targetsSet = 0; for (Player player : game.getPlayers().values()) { if (player.getName().equals(target)) { + if (ability.getTargets().isEmpty()) { + throw new UnsupportedOperationException("Ability has no targets, but there is a player target set - " + ability.toString()); + } ability.getTargets().get(0).addTarget(player.getId(), ability, game); targetsSet++; break; @@ -1415,6 +1418,11 @@ public class TestPlayer implements Player { return computerPlayer.isInGame(); } + @Override + public boolean canRespond() { + return computerPlayer.canRespond(); + } + @Override public boolean hasWon() { return computerPlayer.hasWon(); @@ -1665,22 +1673,41 @@ public class TestPlayer implements Player { } @Override - public boolean moveCards(List cards, Zone fromZone, Zone toZone, Ability source, Game game) { + public boolean moveCards(Set cards, Zone fromZone, Zone toZone, Ability source, Game game) { return computerPlayer.moveCards(cards, fromZone, toZone, source, game); } +// @Override +// public boolean moveCards(Cards cards, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName) { +// return computerPlayer.moveCards(cards, fromZone, toZone, source, game); +// } +// +// @Override +// public boolean moveCards(Card card, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName) { +// return computerPlayer.moveCards(card, fromZone, toZone, source, game); +// } +// +// @Override +// public boolean moveCards(Set cards, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName) { +// return computerPlayer.moveCards(cards, fromZone, toZone, source, game); +// } @Override - public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone) { - return computerPlayer.moveCardToHandWithInfo(card, sourceId, game, fromZone); + public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game) { + return computerPlayer.moveCardToHandWithInfo(card, sourceId, game); } @Override - public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone, boolean withName) { - return computerPlayer.moveCardToHandWithInfo(card, sourceId, game, fromZone, withName); + public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, boolean withName) { + return computerPlayer.moveCardToHandWithInfo(card, sourceId, game, withName); } @Override - public boolean moveCardsToGraveyardWithInfo(List allCards, Ability source, Game game, Zone fromZone) { + public boolean moveCardsToExile(Set cards, Ability source, Game game, boolean withName, UUID exileId, String exileZoneName) { + return computerPlayer.moveCardsToExile(cards, source, game, withName, exileId, exileZoneName); + } + + @Override + public boolean moveCardsToGraveyardWithInfo(Set allCards, Ability source, Game game, Zone fromZone) { return computerPlayer.moveCardsToGraveyardWithInfo(allCards, source, game, fromZone); } @@ -1826,8 +1853,8 @@ public class TestPlayer implements Player { } @Override - public boolean playMana(ManaCost unpaid, String promptText, Game game) { - return computerPlayer.playMana(unpaid, promptText, game); + public boolean playMana(Ability ability, ManaCost unpaid, String promptText, Game game) { + return computerPlayer.playMana(ability, unpaid, promptText, game); } @Override diff --git a/Mage.Tests/src/test/java/org/mage/test/serverside/base/CardTestPlayerBaseAI.java b/Mage.Tests/src/test/java/org/mage/test/serverside/base/CardTestPlayerBaseAI.java index 2f50da22db0..910f3de6ec4 100644 --- a/Mage.Tests/src/test/java/org/mage/test/serverside/base/CardTestPlayerBaseAI.java +++ b/Mage.Tests/src/test/java/org/mage/test/serverside/base/CardTestPlayerBaseAI.java @@ -41,11 +41,10 @@ import org.mage.test.serverside.base.impl.CardTestPlayerAPIImpl; * * @author LevelX2 */ - public abstract class CardTestPlayerBaseAI extends CardTestPlayerAPIImpl { - - int skill = 9; - + + int skill = 6; + @Override protected Game createNewGameAndPlayers() throws GameException, FileNotFoundException { Game game = new TwoPlayerDuel(MultiplayerAttackOption.LEFT, RangeOfInfluence.ONE, 0, 20); @@ -53,8 +52,8 @@ public abstract class CardTestPlayerBaseAI extends CardTestPlayerAPIImpl { playerA = createPlayer(game, playerA, "PlayerA"); playerB = createPlayer(game, playerB, "PlayerB"); return game; - } - + } + @Override protected TestPlayer createPlayer(String name) { if (name.equals("PlayerA")) { @@ -65,7 +64,7 @@ public abstract class CardTestPlayerBaseAI extends CardTestPlayerAPIImpl { return super.createPlayer(name); } - public void setAISkill(int skill) { + public void setAISkill(int skill) { this.skill = skill; } } diff --git a/Mage.Tests/src/test/java/org/mage/test/serverside/base/impl/CardTestPlayerAPIImpl.java b/Mage.Tests/src/test/java/org/mage/test/serverside/base/impl/CardTestPlayerAPIImpl.java index 331f42e4fea..d40b5113bff 100644 --- a/Mage.Tests/src/test/java/org/mage/test/serverside/base/impl/CardTestPlayerAPIImpl.java +++ b/Mage.Tests/src/test/java/org/mage/test/serverside/base/impl/CardTestPlayerAPIImpl.java @@ -219,6 +219,7 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement * * @param player {@link Player} to remove all library cards from. */ + @Override public void removeAllCardsFromLibrary(TestPlayer player) { getCommands(player).put(Zone.LIBRARY, "clear"); } @@ -241,6 +242,7 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement * playerB. * @param cardName Card name in string format. */ + @Override public void addCard(Zone gameZone, TestPlayer player, String cardName) { addCard(gameZone, player, cardName, 1, false); } @@ -254,6 +256,7 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement * @param cardName Card name in string format. * @param count Amount of cards to be added. */ + @Override public void addCard(Zone gameZone, TestPlayer player, String cardName, int count) { addCard(gameZone, player, cardName, count, false); } @@ -270,6 +273,7 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement * permanent should be tapped. In case gameZone is other than Battlefield, * {@link IllegalArgumentException} is thrown */ + @Override public void addCard(Zone gameZone, TestPlayer player, String cardName, int count, boolean tapped) { if (gameZone.equals(Zone.BATTLEFIELD)) { @@ -324,6 +328,7 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement * @param player {@link Player} to set life count for. * @param life Life count to set. */ + @Override public void setLife(TestPlayer player, int life) { getCommands(player).put(Zone.OUTSIDE, "life:" + String.valueOf(life)); } @@ -711,6 +716,28 @@ public abstract class CardTestPlayerAPIImpl extends MageTestPlayerBase implement Assert.assertEquals("(Battlefield) Tapped state is not equal (" + cardName + ")", tapped, found.isTapped()); } + /** + * Assert whether X permanents of the same name are tapped or not. + * + * @param cardName Name of the permanent that should be checked. + * @param tapped Whether the permanent is tapped or not + * @param count The amount of this permanents that should be tapped + */ + public void assertTappedCount(String cardName, boolean tapped, int count) throws AssertionError { + int tappedAmount = 0; + Permanent found = null; + for (Permanent permanent : currentGame.getBattlefield().getAllActivePermanents()) { + if (permanent.getName().equals(cardName)) { + if (permanent.isTapped() == tapped) { + tappedAmount++; + } + found = permanent; + } + } + Assert.assertNotNull("There is no such permanent on the battlefield, cardName=" + cardName, found); + Assert.assertEquals("(Battlefield) " + count + " permanents (" + cardName + ") are not " + ((tapped) ? "" : "un") + "tapped.", count, tappedAmount); + } + /** * Assert whether a permanent is attacking or not * diff --git a/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java b/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java index 0836462b604..8828f01d06d 100644 --- a/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/serverside/cards/abilities/ProtectionFromColorTest.java @@ -38,4 +38,47 @@ public class ProtectionFromColorTest extends CardTestPlayerBase { // One should have been destroyed by Royal Assassin assertPermanentCount(playerB, "Runeclaw Bear", 0); } + + @Test + public void testProtectionChosenColor() { + addCard(Zone.BATTLEFIELD, playerA, "Plains"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp"); + // Defender + // As Order of the Stars enters the battlefield, choose a color. + // Order of the Stars has protection from the chosen color. + addCard(Zone.HAND, playerA, "Order of the Stars"); // 0/1 {W} + // Put target creature card from a graveyard onto the battlefield under your control. You lose life equal to its converted mana cost. + addCard(Zone.HAND, playerA, "Reanimate"); // {B} + + addCard(Zone.BATTLEFIELD, playerB, "Silvercoat Lion", 1); + addCard(Zone.BATTLEFIELD, playerB, "Mountain", 4); + // Seismic Shudder deals 1 damage to each creature without flying. + addCard(Zone.HAND, playerB, "Seismic Shudder", 2); // {1}{R} + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Order of the Stars"); + setChoice(playerA, "White"); + + attack(2, playerB, "Silvercoat Lion"); + block(2, playerA, "Order of the Stars", "Silvercoat Lion"); + + castSpell(2, PhaseStep.POSTCOMBAT_MAIN, playerB, "Seismic Shudder"); + + castSpell(3, PhaseStep.PRECOMBAT_MAIN, playerA, "Reanimate", "Order of the Stars"); + setChoice(playerA, "Red"); + + castSpell(3, PhaseStep.POSTCOMBAT_MAIN, playerB, "Seismic Shudder"); + + setStopAt(3, PhaseStep.END_TURN); + execute(); + + assertGraveyardCount(playerB, "Seismic Shudder", 2); + assertGraveyardCount(playerA, "Reanimate", 1); + assertPermanentCount(playerA, "Order of the Stars", 1); + assertPermanentCount(playerB, "Silvercoat Lion", 1); + + assertLife(playerA, 19); + assertLife(playerB, 20); + + } + } diff --git a/Mage.Tests/src/test/java/org/mage/test/turnmod/SkipTurnTest.java b/Mage.Tests/src/test/java/org/mage/test/turnmod/SkipTurnTest.java new file mode 100644 index 00000000000..71c88bf394d --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/turnmod/SkipTurnTest.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package org.mage.test.turnmod; + +import mage.constants.PhaseStep; +import mage.constants.Zone; +import mage.counters.CounterType; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class SkipTurnTest extends CardTestPlayerBase { + + @Test + public void testEaterOfDays() { + // At the beginning of your upkeep or whenever you cast a green spell, put a charge counter on Shrine of Boundless Growth. + // {T}, Sacrifice Shrine of Boundless Growth: Add {1} to your mana pool for each charge counter on Shrine of Boundless Growth. + addCard(Zone.HAND, playerA, "Shrine of Boundless Growth", 1); + addCard(Zone.BATTLEFIELD, playerA, "Island", 7); + // Flying + // Trample + // When Eater of Days enters the battlefield, you skip your next two turns. + addCard(Zone.HAND, playerA, "Eater of Days", 1); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Eater of Days"); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Shrine of Boundless Growth"); + + setStopAt(5, PhaseStep.PRECOMBAT_MAIN); + execute(); + + assertPermanentCount(playerA, "Eater of Days", 1); + assertPermanentCount(playerA, "Shrine of Boundless Growth", 1); + assertCounterCount("Shrine of Boundless Growth", CounterType.CHARGE, 1); + } +} diff --git a/Mage.Tests/src/test/java/org/mage/test/utils/ManaOptionsTest.java b/Mage.Tests/src/test/java/org/mage/test/utils/ManaOptionsTest.java index b1e78318af3..9d528310d3c 100644 --- a/Mage.Tests/src/test/java/org/mage/test/utils/ManaOptionsTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/utils/ManaOptionsTest.java @@ -30,13 +30,16 @@ package org.mage.test.utils; import mage.abilities.mana.ManaOptions; import mage.constants.PhaseStep; import mage.constants.Zone; +import mage.counters.CounterType; import org.junit.Assert; +import org.junit.Ignore; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBase; /** - * This test checks if the calculated possible mana options are correct related to the given mana sources available. - * + * This test checks if the calculated possible mana options are correct related + * to the given mana sources available. + * * @author LevelX2 */ public class ManaOptionsTest extends CardTestPlayerBase { @@ -45,12 +48,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { public void testSimpleMana() { addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{G}{G}{G}", getManaOption(0, manaOptions)); } @@ -62,12 +65,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { public void testTinderFarm() { addCard(Zone.BATTLEFIELD, playerA, "Tinder Farm", 3); - setStopAt(2, PhaseStep. UPKEEP); + setStopAt(2, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",4, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 4, manaOptions.size()); Assert.assertEquals("{G}{G}{G}", getManaOption(0, manaOptions)); Assert.assertEquals("{R}{G}{G}{W}", getManaOption(1, manaOptions)); Assert.assertEquals("{R}{R}{G}{W}{W}", getManaOption(2, manaOptions)); @@ -82,12 +85,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { public void testAdarkarWastes() { addCard(Zone.BATTLEFIELD, playerA, "Adarkar Wastes", 3); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",4, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 4, manaOptions.size()); Assert.assertEquals("{W}{W}{W}", getManaOption(0, manaOptions)); Assert.assertEquals("{U}{W}{W}", getManaOption(1, manaOptions)); Assert.assertEquals("{U}{U}{W}", getManaOption(2, manaOptions)); @@ -95,7 +98,6 @@ public class ManaOptionsTest extends CardTestPlayerBase { } - // Chromatic Sphere // {1}, {T}, Sacrifice Chromatic Sphere: Add one mana of any color to your mana pool. Draw a card. @Test @@ -103,12 +105,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Plains", 2); addCard(Zone.BATTLEFIELD, playerA, "Chromatic Sphere", 2); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{Any}{Any}", getManaOption(0, manaOptions)); } @@ -120,12 +122,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); addCard(Zone.BATTLEFIELD, playerA, "Orochi Leafcaller", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{W}{W}{Any}{Any}", getManaOption(0, manaOptions)); } @@ -138,14 +140,15 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 2); addCard(Zone.BATTLEFIELD, playerA, "Crystal Quarry", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{1}{G}{G}{W}{W}", getManaOption(0, manaOptions)); } + // Crystal Quarry // {T}: {1} Add to your mana pool. // {5}, {T}: Add {W}{U}{B}{R}{G} to your mana pool. @@ -155,12 +158,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); addCard(Zone.BATTLEFIELD, playerA, "Crystal Quarry", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",2, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 2, manaOptions.size()); Assert.assertEquals("{1}{G}{G}{G}{W}{W}", getManaOption(0, manaOptions)); Assert.assertEquals("{R}{G}{U}{W}{B}", getManaOption(1, manaOptions)); } @@ -174,15 +177,15 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); addCard(Zone.BATTLEFIELD, playerA, "Nykthos, Shrine to Nyx", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{G}{G}{G}{G}{G}", getManaOption(0, manaOptions)); } - + @Test public void testNykthos2() { addCard(Zone.BATTLEFIELD, playerA, "Sedge Scorpion", 4); @@ -190,12 +193,12 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 3); addCard(Zone.BATTLEFIELD, playerA, "Nykthos, Shrine to Nyx", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",2, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 2, manaOptions.size()); Assert.assertEquals("{G}{G}{G}{G}{G}", getManaOption(0, manaOptions)); Assert.assertEquals("{R}{R}{R}{G}", getManaOption(1, manaOptions)); } @@ -206,36 +209,149 @@ public class ManaOptionsTest extends CardTestPlayerBase { addCard(Zone.BATTLEFIELD, playerA, "Forest", 1); addCard(Zone.BATTLEFIELD, playerA, "Nykthos, Shrine to Nyx", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",1, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); Assert.assertEquals("{1}{G}{Any}", getManaOption(0, manaOptions)); } @Test public void testMix1() { + // {1}, {T}, Sacrifice Chromatic Star: Add one mana of any color to your mana pool. + // When Chromatic Star is put into a graveyard from the battlefield, draw a card. addCard(Zone.BATTLEFIELD, playerA, "Chromatic Star", 1); + // {1}, {T}, Sacrifice Chromatic Sphere: Add one mana of any color to your mana pool. Draw a card. addCard(Zone.BATTLEFIELD, playerA, "Chromatic Sphere", 1); + // {T}: Add {1} to your mana pool. If you control an Urza's Mine and an Urza's Power-Plant, add {3} to your mana pool instead. addCard(Zone.BATTLEFIELD, playerA, "Urza's Tower", 1); + // {T}: Add {1} to your mana pool. + // {T}: Add {R} or {G} to your mana pool. Each opponent gains 1 life. addCard(Zone.BATTLEFIELD, playerA, "Grove of the Burnwillows", 1); - setStopAt(1, PhaseStep. UPKEEP); + setStopAt(1, PhaseStep.UPKEEP); execute(); ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); - Assert.assertEquals("mana variations don't fit",2, manaOptions.size()); + Assert.assertEquals("mana variations don't fit", 2, manaOptions.size()); Assert.assertEquals("{Any}{Any}", getManaOption(0, manaOptions)); Assert.assertEquals("{Any}{Any}", getManaOption(1, manaOptions)); } - private String getManaOption(int index, ManaOptions manaOptions) { + @Test + public void testFetidHeath() { + addCard(Zone.BATTLEFIELD, playerA, "Fetid Heath", 1); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + + setStopAt(1, PhaseStep.UPKEEP); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 3, manaOptions.size()); + Assert.assertEquals("{W}{W}", getManaOption(0, manaOptions)); + Assert.assertEquals("{W}{B}", getManaOption(1, manaOptions)); + Assert.assertEquals("{B}{B}", getManaOption(2, manaOptions)); + } + + /** + * Don't use mana sources that only reduce available mana + */ + @Test + public void testCabalCoffers1() { + addCard(Zone.BATTLEFIELD, playerA, "Cabal Coffers", 1); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + + setStopAt(1, PhaseStep.UPKEEP); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); + Assert.assertEquals("{W}{B}", getManaOption(0, manaOptions)); + } + + @Test + public void testCabalCoffers2() { + addCard(Zone.BATTLEFIELD, playerA, "Cabal Coffers", 1); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 2); + + setStopAt(1, PhaseStep.UPKEEP); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 2, manaOptions.size()); + Assert.assertEquals("{W}{B}{B}", getManaOption(0, manaOptions)); + Assert.assertEquals("{B}{B}{B}", getManaOption(1, manaOptions)); + } + + @Test + public void testMageRingNetwork() { + // {T}: Add {1} to your mana pool. + // {T}, {1} : Put a storage counter on Mage-Ring Network. + // {T}, Remove X storage counters from Mage-Ring Network: Add {X} to your mana pool. + addCard(Zone.BATTLEFIELD, playerA, "Mage-Ring Network", 1); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + + setStopAt(1, PhaseStep.UPKEEP); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); + Assert.assertEquals("{1}{W}{B}", getManaOption(0, manaOptions)); + } + + @Test + public void testMageRingNetwork2() { + // {T}: Add {1} to your mana pool. + // {T}, {1} : Put a storage counter on Mage-Ring Network. + // {T}, Remove X storage counters from Mage-Ring Network: Add {X} to your mana pool. + addCard(Zone.BATTLEFIELD, playerA, "Mage-Ring Network", 1); + addCounters(1, PhaseStep.UPKEEP, playerA, "Mage-Ring Network", CounterType.STORAGE, 4); + addCard(Zone.BATTLEFIELD, playerA, "Plains", 1); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + + setStopAt(1, PhaseStep.DRAW); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); + Assert.assertEquals("{4}{W}{B}", getManaOption(0, manaOptions)); + } + + @Test + @Ignore // TriggeredManaAbilities not supported yet for getAvailableMana + public void testCryptGhast() { + //Extort (Whenever you cast a spell, you may pay {WB}. If you do, each opponent loses 1 life and you gain that much life.) + // Whenever you tap a Swamp for mana, add {B} to your mana pool (in addition to the mana the land produces). + addCard(Zone.BATTLEFIELD, playerA, "Crypt Ghast", 1); + + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 1); + + setStopAt(1, PhaseStep.UPKEEP); + execute(); + + ManaOptions manaOptions = playerA.getAvailableManaTest(currentGame); + + Assert.assertEquals("mana variations don't fit", 1, manaOptions.size()); + Assert.assertEquals("{B}{B}", getManaOption(0, manaOptions)); + } + + // TODO + // Test Calciform Pools combination mana lands + private String getManaOption(int index, ManaOptions manaOptions) { if (manaOptions.size() < index + 1) { return ""; } return manaOptions.get(index).toString(); } -} \ No newline at end of file +} diff --git a/Mage.Tests/src/test/java/org/mage/test/utils/ManaUtilTest.java b/Mage.Tests/src/test/java/org/mage/test/utils/ManaUtilTest.java index 07bc006edf3..3534b4a6acf 100644 --- a/Mage.Tests/src/test/java/org/mage/test/utils/ManaUtilTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/utils/ManaUtilTest.java @@ -1,9 +1,16 @@ package org.mage.test.utils; +import java.util.HashMap; +import java.util.LinkedHashMap; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.costs.mana.ManaCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.mana.*; +import mage.abilities.mana.BasicManaAbility; +import mage.abilities.mana.BlackManaAbility; +import mage.abilities.mana.ManaAbility; +import mage.abilities.mana.RedManaAbility; +import mage.abilities.mana.WhiteManaAbility; import mage.cards.Card; import mage.cards.repository.CardRepository; import mage.util.ManaUtil; @@ -11,10 +18,6 @@ import org.junit.Assert; import org.junit.Test; import org.mage.test.serverside.base.CardTestPlayerBase; -import java.util.HashMap; -import java.util.LinkedHashMap; -import java.util.UUID; - /** * @author noxx */ @@ -47,7 +50,7 @@ public class ManaUtilTest extends CardTestPlayerBase { testManaToPayVsLand("{2}", "Cavern of Souls", 2, 2); // can't auto choose to pay testManaToPayVsLand("{2}", "Eldrazi Temple", 2, 2); // can't auto choose to pay - + // hybrid mana testManaToPayVsLand("{W/R}{W/R}{W/R}", "Sacred Foundry", 2, 1); // auto choose for hybrid mana: choose any testManaToPayVsLand("{R}{W/R}", "Sacred Foundry", 2, RedManaAbility.class); // auto choose for hybrid mana: we should choose {R} @@ -55,6 +58,9 @@ public class ManaUtilTest extends CardTestPlayerBase { testManaToPayVsLand("{G}{W/R}{W}", "Sacred Foundry", 2, WhiteManaAbility.class); // auto choose for hybrid mana: choose {W} testManaToPayVsLand("{W/B}{W/B}", "Swamp", 1, BlackManaAbility.class); + testManaToPayVsLand("{R}", "Glimmervoid", 1, 1); + testManaToPayVsLand("{R}{1}", "Glimmervoid", 1, 1); + // we can't auto choose here: // let say we auto choose {R}, then we have to use it to pay for {R} not {W/R} (as {W/R} is more generic cost) // but in such case what is left to pay is {W/R}{W} and it is possible that we won't have 2 white sources @@ -66,15 +72,33 @@ public class ManaUtilTest extends CardTestPlayerBase { testManaToPayVsLand("{W/R}{R/G}", "Sacred Foundry", 2, 2); // can't auto choose to pay } + @Test + public void testManaCondensing() { + Assert.assertEquals("{5}{W}", ManaUtil.condenseManaCostString(("{1}{1}{1}{2}{W}"))); + Assert.assertEquals("{4}{B}{B}", ManaUtil.condenseManaCostString("{2}{B}{2}{B}")); + Assert.assertEquals("{6}{R}{R}{R}{U}", ManaUtil.condenseManaCostString("{R}{1}{R}{2}{R}{3}{U}")); + Assert.assertEquals("{5}{B}{U}{W}", ManaUtil.condenseManaCostString("{1}{B}{W}{4}{U}")); + Assert.assertEquals("{8}{B}{G}{G}{U}", ManaUtil.condenseManaCostString("{1}{G}{1}{2}{3}{G}{B}{U}{1}")); + Assert.assertEquals("{3}{R}{U}", ManaUtil.condenseManaCostString("{3}{R}{U}")); + Assert.assertEquals("{10}", ManaUtil.condenseManaCostString("{1}{2}{3}{4}")); + Assert.assertEquals("{B}{G}{R}{U}{W}", ManaUtil.condenseManaCostString("{B}{G}{R}{U}{W}")); + Assert.assertEquals("{R}{R}", ManaUtil.condenseManaCostString("{R}{R}")); + Assert.assertEquals("{U}", ManaUtil.condenseManaCostString("{U}")); + Assert.assertEquals("{2}", ManaUtil.condenseManaCostString("{2}")); + Assert.assertEquals("", ManaUtil.condenseManaCostString("{}")); + } + /** * Common way to test ManaUtil.tryToAutoPay * - * We get all mana abilities, then try to auto pay and compare to expected1 and expected2 params. + * We get all mana abilities, then try to auto pay and compare to expected1 + * and expected2 params. * * @param manaToPay Mana that should be paid using land. * @param landName Land to use as mana producer. * @param expected1 The amount of mana abilities the land should have. - * @param expected2 The amount of mana abilities that ManaUtil.tryToAutoPay should be returned after optimization. + * @param expected2 The amount of mana abilities that ManaUtil.tryToAutoPay + * should be returned after optimization. */ private void testManaToPayVsLand(String manaToPay, String landName, int expected1, int expected2) { ManaCost unpaid = new ManaCostsImpl(manaToPay); @@ -84,19 +108,20 @@ public class ManaUtilTest extends CardTestPlayerBase { HashMap useableAbilities = getManaAbilities(card); Assert.assertEquals(expected1, useableAbilities.size()); - useableAbilities = ManaUtil.tryToAutoPay(unpaid, (LinkedHashMap)useableAbilities); + useableAbilities = ManaUtil.tryToAutoPay(unpaid, (LinkedHashMap) useableAbilities); Assert.assertEquals(expected2, useableAbilities.size()); } /** - * Another way to test ManaUtil.tryToAutoPay - * Here we also check what ability was auto chosen + * Another way to test ManaUtil.tryToAutoPay Here we also check what ability + * was auto chosen * - * N.B. This method can be used ONLY if we have one ability left that auto choose mode! - * That's why we assert the following: - * Assert.assertEquals(1, useableAbilities.size()); + * N.B. This method can be used ONLY if we have one ability left that auto + * choose mode! That's why we assert the following: Assert.assertEquals(1, + * useableAbilities.size()); * - * We get all mana abilities, then try to auto pay and compare to expected1 and expected2 params. + * We get all mana abilities, then try to auto pay and compare to expected1 + * and expected2 params. * * @param manaToPay Mana that should be paid using land. * @param landName Land to use as mana producer. @@ -111,7 +136,7 @@ public class ManaUtilTest extends CardTestPlayerBase { HashMap useableAbilities = getManaAbilities(card); Assert.assertEquals(expected1, useableAbilities.size()); - useableAbilities = ManaUtil.tryToAutoPay(unpaid, (LinkedHashMap)useableAbilities); + useableAbilities = ManaUtil.tryToAutoPay(unpaid, (LinkedHashMap) useableAbilities); Assert.assertEquals(1, useableAbilities.size()); ManaAbility ability = useableAbilities.values().iterator().next(); Assert.assertTrue("Wrong mana ability has been chosen", expectedChosen.isInstance(ability)); @@ -125,12 +150,13 @@ public class ManaUtilTest extends CardTestPlayerBase { */ private HashMap getManaAbilities(Card card) { HashMap useableAbilities = new LinkedHashMap<>(); - for (Ability ability: card.getAbilities()) { + for (Ability ability : card.getAbilities()) { if (ability instanceof ManaAbility) { ability.newId(); // we need to assign id manually as we are not in game - useableAbilities.put(ability.getId(), (ManaAbility)ability); + useableAbilities.put(ability.getId(), (ManaAbility) ability); } } return useableAbilities; } + } diff --git a/Mage.Updater/pom.xml b/Mage.Updater/pom.xml index 1cba689e490..90d4db3a1a6 100644 --- a/Mage.Updater/pom.xml +++ b/Mage.Updater/pom.xml @@ -5,7 +5,7 @@ mage-root org.mage - 1.4.2 + 1.4.3 4.0.0 diff --git a/Mage/pom.xml b/Mage/pom.xml index 02ac85bd1fe..c13b047036a 100644 --- a/Mage/pom.xml +++ b/Mage/pom.xml @@ -7,7 +7,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 mage diff --git a/Mage/src/mage/Mana.java b/Mage/src/mage/Mana.java index 5708e081e5b..b9b3e04c8fa 100644 --- a/Mage/src/mage/Mana.java +++ b/Mage/src/mage/Mana.java @@ -1,36 +1,36 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage; import java.io.Serializable; import mage.constants.ColoredManaSymbol; import mage.constants.ManaType; +import static mage.constants.ManaType.COLORLESS; import mage.filter.FilterMana; import mage.util.Copyable; import mage.util.ThreadLocalStringBuilder; @@ -57,7 +57,8 @@ public class Mana implements Comparable, Serializable, Copyable { public static final Mana BlackMana = BlackMana(1); public static final Mana ColorlessMana = ColorlessMana(1); - public Mana() {} + public Mana() { + } public Mana(final Mana mana) { this.red = mana.red; @@ -212,11 +213,10 @@ public class Mana implements Comparable, Serializable, Copyable { } } - public int count() { return red + green + blue + white + black + colorless + any; } - + public int countColored() { return red + green + blue + white + black + any; } @@ -283,9 +283,9 @@ public class Mana implements Comparable, Serializable, Copyable { } return sbMana.toString(); } - + private static final transient ThreadLocalStringBuilder threadLocalBuilder = new ThreadLocalStringBuilder(10); - + @Override public Mana copy() { return new Mana(this); @@ -342,38 +342,38 @@ public class Mana implements Comparable, Serializable, Copyable { Mana compare = avail.copy(); compare.subtract(this); if (compare.getRed() < 0 && compare.getAny() > 0) { - int diff = Math.min( compare.getAny(), Math.abs(compare.getRed())); + int diff = Math.min(compare.getAny(), Math.abs(compare.getRed())); compare.setAny(compare.getAny() - diff); compare.setRed(compare.getRed() + diff); } if (compare.getGreen() < 0 && compare.getAny() > 0) { - int diff = Math.min( compare.getAny(), Math.abs(compare.getGreen())); + int diff = Math.min(compare.getAny(), Math.abs(compare.getGreen())); compare.setAny(compare.getAny() - diff); compare.setGreen(compare.getGreen() + diff); } if (compare.getBlue() < 0 && compare.getAny() > 0) { - int diff = Math.min( compare.getAny(), Math.abs(compare.getBlue())); + int diff = Math.min(compare.getAny(), Math.abs(compare.getBlue())); compare.setAny(compare.getAny() - diff); compare.setBlue(compare.getBlue() + diff); } if (compare.getBlack() < 0 && compare.getAny() > 0) { - int diff = Math.min( compare.getAny(), Math.abs(compare.getBlack())); + int diff = Math.min(compare.getAny(), Math.abs(compare.getBlack())); compare.setAny(compare.getAny() - diff); compare.setBlack(compare.getBlack() + diff); } if (compare.getWhite() < 0 && compare.getAny() > 0) { - int diff = Math.min( compare.getAny(), Math.abs(compare.getWhite())); + int diff = Math.min(compare.getAny(), Math.abs(compare.getWhite())); compare.setAny(compare.getAny() - diff); compare.setWhite(compare.getWhite() + diff); } if (compare.getColorless() < 0) { int remaining = 0; - remaining += Math.min(0,compare.getRed()); - remaining += Math.min(0,compare.getWhite()); - remaining += Math.min(0,compare.getGreen()); - remaining += Math.min(0,compare.getBlack()); - remaining += Math.min(0,compare.getBlue()); - remaining += Math.min(0,compare.getAny()); + remaining += Math.min(0, compare.getRed()); + remaining += Math.min(0, compare.getWhite()); + remaining += Math.min(0, compare.getGreen()); + remaining += Math.min(0, compare.getBlack()); + remaining += Math.min(0, compare.getBlue()); + remaining += Math.min(0, compare.getAny()); if (remaining > 0) { int diff = Math.min(remaining, Math.abs(compare.getColorless())); compare.setColorless(compare.getColorless() + diff); @@ -510,7 +510,7 @@ public class Mana implements Comparable, Serializable, Copyable { } public int get(ManaType manaType) { - switch(manaType) { + switch (manaType) { case BLACK: return black; case BLUE: @@ -528,7 +528,7 @@ public class Mana implements Comparable, Serializable, Copyable { } public void set(ManaType manaType, int amount) { - switch(manaType) { + switch (manaType) { case BLACK: black = amount; break; @@ -569,39 +569,39 @@ public class Mana implements Comparable, Serializable, Copyable { } public boolean equalManaValue(Mana mana) { - return this.any == mana.any && - this.red == mana.red && - this.green == mana.green && - this.white == mana.white && - this.blue == mana.blue && - this.black == mana.black && - this.colorless == mana.colorless; + return this.any == mana.any + && this.red == mana.red + && this.green == mana.green + && this.white == mana.white + && this.blue == mana.blue + && this.black == mana.black + && this.colorless == mana.colorless; } /** - * Don't takes any mana into account to be usable in calculating available mana + * Don't takes any mana into account to be usable in calculating available + * mana + * * @param mana - * @return + * @return */ public boolean includesMana(Mana mana) { - return this.green >= mana.green && - this.blue >= mana.blue && - this.white >= mana.white && - this.black >= mana.black && - this.red >= mana.red && - ( - this.colorless >= mana.colorless || - this.countColored() >= mana.countColored() + mana.colorless - ); + return this.green >= mana.green + && this.blue >= mana.blue + && this.white >= mana.white + && this.black >= mana.black + && this.red >= mana.red + && (this.colorless >= mana.colorless + || this.countColored() >= mana.countColored() + mana.colorless); } /** - * Returns the mana that is more colored but does not contain - * one less mana in any color but colorless - * if you call with {1}{W}{R} and {G}{W}{R} you get back {G}{W}{R} - * if you call with {G}{W}{R} and {G}{W}{R} you get back {G}{W}{R} - * if you call with {G}{W}{B} and {G}{W}{R} you get back null + * Returns the mana that is more colored or has a greater amount but does + * not contain one less mana in any color but colorless if you call with + * {1}{W}{R} and {G}{W}{R} you get back {G}{W}{R} if you call with {G}{W}{R} + * and {G}{W}{R} you get back {G}{W}{R} if you call with {G}{W}{B} and + * {G}{W}{R} you get back null * * @param mana1 * @param mana2 @@ -610,22 +610,41 @@ public class Mana implements Comparable, Serializable, Copyable { public static Mana getMoreValuableMana(Mana mana1, Mana mana2) { Mana moreMana; Mana lessMana; - if (mana2.count() > mana1.count() || mana2.getAny() > mana1.getAny() || mana2.getColorless() < mana1.getColorless()) { + if (mana2.countColored() > mana1.countColored() || mana2.getAny() > mana1.getAny() || mana2.count() > mana1.count()) { moreMana = mana2; lessMana = mana1; } else { moreMana = mana1; lessMana = mana2; } - if (lessMana.getWhite() > moreMana.getWhite() || - lessMana.getRed() > moreMana.getRed() || - lessMana.getGreen() > moreMana.getGreen() || - lessMana.getBlue() > moreMana.getBlue() || - lessMana.getBlack() > moreMana.getBlack() || - lessMana.getAny() > moreMana.getAny() - ) { + if (lessMana.getWhite() > moreMana.getWhite() + || lessMana.getRed() > moreMana.getRed() + || lessMana.getGreen() > moreMana.getGreen() + || lessMana.getBlue() > moreMana.getBlue() + || lessMana.getBlack() > moreMana.getBlack() + || lessMana.getAny() > moreMana.getAny()) { return null; } return moreMana; } + + public int getDifferentColors() { + int count = 0; + if (blue > 0) { + count++; + } + if (black > 0) { + count++; + } + if (green > 0) { + count++; + } + if (white > 0) { + count++; + } + if (red > 0) { + count++; + } + return count; + } } diff --git a/Mage/src/mage/abilities/ActivatedAbilityImpl.java b/Mage/src/mage/abilities/ActivatedAbilityImpl.java index e5e1b819a53..ffdc3d4e019 100644 --- a/Mage/src/mage/abilities/ActivatedAbilityImpl.java +++ b/Mage/src/mage/abilities/ActivatedAbilityImpl.java @@ -1,38 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities; import java.util.UUID; - -import mage.constants.AbilityType; -import mage.constants.TimingRule; -import mage.constants.Zone; import mage.abilities.costs.Cost; import mage.abilities.costs.Costs; import mage.abilities.costs.mana.ManaCosts; @@ -40,12 +35,14 @@ import mage.abilities.costs.mana.PhyrexianManaCost; import mage.abilities.effects.Effect; import mage.abilities.effects.Effects; import mage.cards.Card; +import mage.constants.AbilityType; import mage.constants.AsThoughEffectType; import mage.constants.TargetController; +import mage.constants.TimingRule; +import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; - /** * * @author BetaSteward_at_googlemail.com @@ -62,7 +59,7 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa this.checkPlayableMode = false; } - public ActivatedAbilityImpl(ActivatedAbilityImpl ability) { + public ActivatedAbilityImpl(final ActivatedAbilityImpl ability) { super(ability); timing = ability.timing; mayActivate = ability.mayActivate; @@ -94,7 +91,7 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa public ActivatedAbilityImpl(Zone zone, Effects effects, ManaCosts cost) { super(AbilityType.ACTIVATED, zone); if (effects != null) { - for (Effect effect: effects) { + for (Effect effect : effects) { this.addEffect(effect); } } @@ -110,7 +107,7 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa } if (cost != null) { if (cost instanceof PhyrexianManaCost) { - this.addManaCost((PhyrexianManaCost)cost); + this.addManaCost((PhyrexianManaCost) cost); } else { this.addCost(cost); } @@ -123,7 +120,7 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa this.addEffect(effect); } if (costs != null) { - for (Cost cost: costs) { + for (Cost cost : costs) { this.addCost(cost); } } @@ -132,7 +129,7 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa public ActivatedAbilityImpl(Zone zone, Effects effects, Cost cost) { super(AbilityType.ACTIVATED, zone); if (effects != null) { - for (Effect effect: effects) { + for (Effect effect : effects) { this.addEffect(effect); } } @@ -143,13 +140,13 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa public ActivatedAbilityImpl(Zone zone, Effects effects, Costs costs) { super(AbilityType.ACTIVATED, zone); - for (Effect effect: effects) { + for (Effect effect : effects) { if (effect != null) { this.addEffect(effect); } } if (costs != null) { - for (Cost cost: costs) { + for (Cost cost : costs) { this.addCost(cost); } } @@ -161,23 +158,23 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa @Override public boolean canActivate(UUID playerId, Game game) { //20091005 - 602.2 - switch(mayActivate){ + switch (mayActivate) { case ANY: break; - + case NOT_YOU: - if(controlsAbility(playerId, game)){ + if (controlsAbility(playerId, game)) { return false; } break; - + case OPPONENT: - if (! game.getPlayer(controllerId).hasOpponent(playerId, game)){ + if (!game.getPlayer(controllerId).hasOpponent(playerId, game)) { return false; } - break; + break; case YOU: - if(!controlsAbility(playerId, game)){ + if (!controlsAbility(playerId, game)) { return false; } break; @@ -192,8 +189,8 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa return false; } //20091005 - 602.5d/602.5e - if (timing == TimingRule.INSTANT || game.canPlaySorcery(playerId) || - game.getContinuousEffects().asThough(sourceId, AsThoughEffectType.ACTIVATE_AS_INSTANT, this, controllerId, game)) { + if (timing == TimingRule.INSTANT || game.canPlaySorcery(playerId) + || game.getContinuousEffects().asThough(sourceId, AsThoughEffectType.ACTIVATE_AS_INSTANT, this, controllerId, game)) { if (costs.canPay(this, sourceId, controllerId, game) && canChooseTarget(game)) { this.activatorId = playerId; return true; @@ -205,9 +202,8 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa protected boolean controlsAbility(UUID playerId, Game game) { if (this.controllerId != null && this.controllerId.equals(playerId)) { return true; - } - else { - Card card = (Card)game.getObject(this.sourceId); + } else { + Card card = (Card) game.getObject(this.sourceId); if (card != null && game.getState().getZone(this.sourceId) != Zone.BATTLEFIELD) { return card.getOwnerId().equals(playerId); } @@ -240,5 +236,5 @@ public abstract class ActivatedAbilityImpl extends AbilityImpl implements Activa public boolean isCheckPlayableMode() { return checkPlayableMode; } - + } diff --git a/Mage/src/mage/abilities/SpellAbility.java b/Mage/src/mage/abilities/SpellAbility.java index 2c2d9c0fa2d..1dedf4b81e7 100644 --- a/Mage/src/mage/abilities/SpellAbility.java +++ b/Mage/src/mage/abilities/SpellAbility.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities; import java.util.UUID; @@ -65,17 +64,17 @@ public class SpellAbility extends ActivatedAbilityImpl { this.cardName = cardName; this.spellAbilityType = spellAbilityType; this.addManaCost(cost); - switch(spellAbilityType) { + switch (spellAbilityType) { case SPLIT_FUSED: this.name = "Cast fused " + cardName; break; default: this.name = "Cast " + cardName; } - + } - public SpellAbility(SpellAbility ability) { + public SpellAbility(final SpellAbility ability) { super(ability); this.spellAbilityType = ability.spellAbilityType; this.cardName = ability.cardName; @@ -83,9 +82,9 @@ public class SpellAbility extends ActivatedAbilityImpl { public boolean spellCanBeActivatedRegularlyNow(UUID playerId, Game game) { MageObject object = game.getObject(sourceId); - return timing == TimingRule.INSTANT || - object.hasAbility(FlashAbility.getInstance().getId(), game) || - game.canPlaySorcery(playerId); + return timing == TimingRule.INSTANT + || object.hasAbility(FlashAbility.getInstance().getId(), game) + || game.canPlaySorcery(playerId); } @Override @@ -96,7 +95,7 @@ public class SpellAbility extends ActivatedAbilityImpl { return false; } // fix for Gitaxian Probe and casting opponent's spells - if (!game.getContinuousEffects().asThough(getSourceId(), AsThoughEffectType.PLAY_FROM_NOT_OWN_HAND_ZONE, playerId, game) + if (!game.getContinuousEffects().asThough(getSourceId(), AsThoughEffectType.PLAY_FROM_NOT_OWN_HAND_ZONE, playerId, game) && !controllerId.equals(playerId)) { return false; } @@ -122,13 +121,13 @@ public class SpellAbility extends ActivatedAbilityImpl { if (getSpellAbilityType().equals(SpellAbilityType.SPLIT_FUSED)) { SplitCard splitCard = (SplitCard) game.getCard(getSourceId()); if (splitCard != null) { - return (splitCard.getLeftHalfCard().getSpellAbility().canChooseTarget(game) + return (splitCard.getLeftHalfCard().getSpellAbility().canChooseTarget(game) && splitCard.getRightHalfCard().getSpellAbility().canChooseTarget(game)); } return false; } else { - return canChooseTarget(game); + return canChooseTarget(game); } } } diff --git a/Mage/src/mage/abilities/TriggeredAbilities.java b/Mage/src/mage/abilities/TriggeredAbilities.java index 430ae354192..969e3cb78fa 100644 --- a/Mage/src/mage/abilities/TriggeredAbilities.java +++ b/Mage/src/mage/abilities/TriggeredAbilities.java @@ -43,6 +43,7 @@ import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; +import mage.game.stack.Spell; /** * @@ -95,6 +96,9 @@ public class TriggeredAbilities extends ConcurrentHashMap keysToRemove = new ArrayList<>(); + for (Entry entry : this.entrySet()) { + if (game.getObject(entry.getValue().getSourceId()) == null) { + keysToRemove.add(entry.getKey()); + } + } + for (String key : keysToRemove) { + remove(key); + } + } + public TriggeredAbilities copy() { return new TriggeredAbilities(this); } diff --git a/Mage/src/mage/abilities/TriggeredAbility.java b/Mage/src/mage/abilities/TriggeredAbility.java index b2c5e9cb535..b00b022a552 100644 --- a/Mage/src/mage/abilities/TriggeredAbility.java +++ b/Mage/src/mage/abilities/TriggeredAbility.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities; import java.util.UUID; @@ -39,19 +38,25 @@ import mage.game.events.GameEvent; public interface TriggeredAbility extends Ability { void trigger(Game game, UUID controllerId); - + /** - * This check for the relevant event types is called at first to prevent further actions if - * the current event is ignored from this triggered ability + * This check for the relevant event types is called at first to prevent + * further actions if the current event is ignored from this triggered + * ability + * * @param event * @param game * @return */ boolean checkEventType(GameEvent event, Game game); + boolean checkTrigger(GameEvent event, Game game); + boolean checkInterveningIfClause(Game game); + boolean isOptional(); + @Override TriggeredAbility copy(); - + } diff --git a/Mage/src/mage/abilities/TriggeredAbilityImpl.java b/Mage/src/mage/abilities/TriggeredAbilityImpl.java index fdbcf485ee5..0c9cf7411c5 100644 --- a/Mage/src/mage/abilities/TriggeredAbilityImpl.java +++ b/Mage/src/mage/abilities/TriggeredAbilityImpl.java @@ -84,7 +84,7 @@ public abstract class TriggeredAbilityImpl extends AbilityImpl implements Trigge }*/ @Override public boolean resolve(Game game) { - if (optional) { + if (isOptional()) { MageObject object = game.getObject(getSourceId()); Player player = game.getPlayer(this.getControllerId()); if (player != null) { @@ -124,7 +124,7 @@ public abstract class TriggeredAbilityImpl extends AbilityImpl implements Trigge StringBuilder sb = new StringBuilder(); if (!superRule.isEmpty()) { String ruleLow = superRule.toLowerCase(); - if (optional) { + if (isOptional()) { if (ruleLow.startsWith("you ")) { if (!ruleLow.startsWith("you may")) { StringBuilder newRule = new StringBuilder(superRule); @@ -197,4 +197,9 @@ public abstract class TriggeredAbilityImpl extends AbilityImpl implements Trigge return super.isInUseableZone(game, source, event); } + @Override + public boolean isOptional() { + return optional; + } + } diff --git a/Mage/src/mage/abilities/abilityword/StriveAbility.java b/Mage/src/mage/abilities/abilityword/StriveAbility.java index 404933fde23..cc7c57bd046 100644 --- a/Mage/src/mage/abilities/abilityword/StriveAbility.java +++ b/Mage/src/mage/abilities/abilityword/StriveAbility.java @@ -39,6 +39,7 @@ import mage.constants.Outcome; import mage.constants.Zone; import mage.game.Game; import mage.target.Target; +import mage.util.ManaUtil; /** * @@ -50,7 +51,7 @@ public class StriveAbility extends SimpleStaticAbility { private final String striveCost; public StriveAbility(String manaString) { - super(Zone.STACK, new StriveCostIncreasementEffect(new ManaCostsImpl(manaString))); + super(Zone.STACK, new StriveCostIncreasingEffect(new ManaCostsImpl(manaString))); setRuleAtTheTop(true); this.striveCost = manaString; } @@ -71,29 +72,32 @@ public class StriveAbility extends SimpleStaticAbility { } } -class StriveCostIncreasementEffect extends CostModificationEffectImpl { +class StriveCostIncreasingEffect extends CostModificationEffectImpl { private ManaCostsImpl striveCosts = null; - public StriveCostIncreasementEffect(ManaCostsImpl striveCosts) { + public StriveCostIncreasingEffect(ManaCostsImpl striveCosts) { super(Duration.WhileOnStack, Outcome.Benefit, CostModificationType.INCREASE_COST); this.striveCosts = striveCosts; } - protected StriveCostIncreasementEffect(StriveCostIncreasementEffect effect) { + protected StriveCostIncreasingEffect(StriveCostIncreasingEffect effect) { super(effect); this.striveCosts = effect.striveCosts; } @Override public boolean apply(Game game, Ability source, Ability abilityToModify) { - // Target target = abilityToModify.getTargets().get(0); for (Target target : abilityToModify.getTargets()) { if (target.getMaxNumberOfTargets() == Integer.MAX_VALUE) { int additionalTargets = target.getTargets().size() - 1; + StringBuilder sb = new StringBuilder(); for (int i = 0; i < additionalTargets; i++) { - abilityToModify.getManaCostsToPay().add(striveCosts.copy()); + // Build up a string of strive costs for each target + sb.append(striveCosts.getText()); } + String finalCost = ManaUtil.condenseManaCostString(sb.toString()); + abilityToModify.getManaCostsToPay().add(new ManaCostsImpl(finalCost)); return true; } } @@ -106,7 +110,7 @@ class StriveCostIncreasementEffect extends CostModificationEffectImpl { } @Override - public StriveCostIncreasementEffect copy() { - return new StriveCostIncreasementEffect(this); + public StriveCostIncreasingEffect copy() { + return new StriveCostIncreasingEffect(this); } } diff --git a/Mage/src/mage/abilities/common/AttackedByCreatureTriggeredAbility.java b/Mage/src/mage/abilities/common/AttackedByCreatureTriggeredAbility.java index 456d02029c8..b3182dc1c41 100644 --- a/Mage/src/mage/abilities/common/AttackedByCreatureTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/AttackedByCreatureTriggeredAbility.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.common; import java.util.UUID; @@ -57,13 +56,13 @@ public class AttackedByCreatureTriggeredAbility extends TriggeredAbilityImpl { public AttackedByCreatureTriggeredAbility(Effect effect, boolean optional, SetTargetPointer setTargetPointer) { this(Zone.BATTLEFIELD, effect, optional, setTargetPointer); } - + public AttackedByCreatureTriggeredAbility(Zone zone, Effect effect, boolean optional, SetTargetPointer setTargetPointer) { super(zone, effect, optional); this.setTargetPointer = setTargetPointer; } - - public AttackedByCreatureTriggeredAbility(AttackedByCreatureTriggeredAbility ability) { + + public AttackedByCreatureTriggeredAbility(final AttackedByCreatureTriggeredAbility ability) { super(ability); this.setTargetPointer = ability.setTargetPointer; } @@ -80,9 +79,9 @@ public class AttackedByCreatureTriggeredAbility extends TriggeredAbilityImpl { if (getControllerId().equals(playerId) && attackingCreature != null) { if (!setTargetPointer.equals(SetTargetPointer.NONE)) { for (Effect effect : this.getEffects()) { - switch(setTargetPointer) { + switch (setTargetPointer) { case PERMANENT: - effect.setTargetPointer(new FixedTarget(event.getTargetId())); + effect.setTargetPointer(new FixedTarget(attackingCreature.getId())); break; case PLAYER: effect.setTargetPointer(new FixedTarget(attackingCreature.getControllerId())); diff --git a/Mage/src/mage/abilities/common/BecomesBlockedAllTriggeredAbility.java b/Mage/src/mage/abilities/common/BecomesBlockedAllTriggeredAbility.java index 452b40bfadb..58a00f4543c 100644 --- a/Mage/src/mage/abilities/common/BecomesBlockedAllTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/BecomesBlockedAllTriggeredAbility.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.common; import mage.abilities.TriggeredAbilityImpl; @@ -41,7 +40,6 @@ import mage.target.targetpointer.FixedTarget; * * @author LevelX2 */ - public class BecomesBlockedAllTriggeredAbility extends TriggeredAbilityImpl { private FilterCreaturePermanent filter; @@ -50,6 +48,7 @@ public class BecomesBlockedAllTriggeredAbility extends TriggeredAbilityImpl { public BecomesBlockedAllTriggeredAbility(Effect effect, boolean optional) { this(effect, optional, new FilterCreaturePermanent("a creature"), false); } + public BecomesBlockedAllTriggeredAbility(Effect effect, boolean optional, FilterCreaturePermanent filter, boolean setTargetPointer) { super(Zone.BATTLEFIELD, effect, optional); this.filter = filter; @@ -72,7 +71,7 @@ public class BecomesBlockedAllTriggeredAbility extends TriggeredAbilityImpl { Permanent permanent = game.getPermanent(event.getTargetId()); if (permanent != null && filter.match(permanent, getSourceId(), getControllerId(), game)) { if (setTargetPointer) { - for(Effect effect :this.getEffects()) { + for (Effect effect : this.getEffects()) { effect.setTargetPointer(new FixedTarget(event.getTargetId())); } } @@ -83,9 +82,7 @@ public class BecomesBlockedAllTriggeredAbility extends TriggeredAbilityImpl { @Override public String getRule() { - StringBuilder sb = new StringBuilder("Whenever ").append(filter.getMessage()); - sb.append(" becomes blocked, ").append(super.getRule()); - return sb.toString(); + return "Whenever " + filter.getMessage() + " becomes blocked, " + super.getRule(); } @Override diff --git a/Mage/src/mage/abilities/common/BecomesTappedAttachedTriggeredAbility.java b/Mage/src/mage/abilities/common/BecomesTappedAttachedTriggeredAbility.java new file mode 100644 index 00000000000..3c09bae181c --- /dev/null +++ b/Mage/src/mage/abilities/common/BecomesTappedAttachedTriggeredAbility.java @@ -0,0 +1,80 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.common; + +import mage.constants.Zone; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.GameEvent.EventType; +import mage.game.permanent.Permanent; + +/** + * + * @author LoneFox + */ +public class BecomesTappedAttachedTriggeredAbility extends TriggeredAbilityImpl { + + public BecomesTappedAttachedTriggeredAbility(Effect effect, boolean isOptional) { + super(Zone.BATTLEFIELD, effect, isOptional); + } + + public BecomesTappedAttachedTriggeredAbility(Effect effect) { + super(Zone.BATTLEFIELD, effect); + } + + public BecomesTappedAttachedTriggeredAbility(final BecomesTappedAttachedTriggeredAbility ability) { + super(ability); + } + + @Override + public BecomesTappedAttachedTriggeredAbility copy() { + return new BecomesTappedAttachedTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.TAPPED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Permanent enchantment = game.getPermanent(this.getSourceId()); + if(enchantment == null) { + return false; + } + Permanent enchanted = game.getPermanent(enchantment.getAttachedTo()); + return enchanted != null && event.getTargetId().equals(enchanted.getId()); + } + + @Override + public String getRule() { + return "Whenever enchanted creature becomes tapped, " + super.getRule(); + } +} diff --git a/Mage/src/mage/abilities/common/BecomesTargetAttachedTriggeredAbility.java b/Mage/src/mage/abilities/common/BecomesTargetAttachedTriggeredAbility.java new file mode 100644 index 00000000000..f7f89e62e89 --- /dev/null +++ b/Mage/src/mage/abilities/common/BecomesTargetAttachedTriggeredAbility.java @@ -0,0 +1,87 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.common; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; + +/** + * + * @author LoneFox + */ +public class BecomesTargetAttachedTriggeredAbility extends TriggeredAbilityImpl { + + private final String enchantType; + + public BecomesTargetAttachedTriggeredAbility(Effect effect) { + this(effect, "creature"); + } + + public BecomesTargetAttachedTriggeredAbility(Effect effect, String enchantType) { + super(Zone.BATTLEFIELD, effect); + this.enchantType = enchantType; + } + + public BecomesTargetAttachedTriggeredAbility(final BecomesTargetAttachedTriggeredAbility ability) { + super(ability); + this.enchantType = ability.enchantType; + } + + @Override + public BecomesTargetAttachedTriggeredAbility copy() { + return new BecomesTargetAttachedTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.TARGETED; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Permanent enchantment = game.getPermanent(sourceId); + if (enchantment != null && enchantment.getAttachedTo() != null) { + if (event.getTargetId().equals(enchantment.getAttachedTo())) { + return true; + } + } + return false; + } + + @Override + public String getRule() { + return "When enchanted " + enchantType + " becomes the target of a spell or ability, " + super.getRule(); + } +} diff --git a/Mage/src/mage/abilities/common/ControlsPermanentsControllerTriggeredAbility.java b/Mage/src/mage/abilities/common/ControlsPermanentsControllerTriggeredAbility.java new file mode 100644 index 00000000000..56fb65590e8 --- /dev/null +++ b/Mage/src/mage/abilities/common/ControlsPermanentsControllerTriggeredAbility.java @@ -0,0 +1,96 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.common; + +import mage.abilities.StateTriggeredAbility; +import mage.abilities.effects.Effect; +import mage.constants.Zone; +import mage.filter.Filter.ComparisonType; +import mage.filter.FilterPermanent; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * State triggered ability that triggers if the ability controller controlls the + * defined number of permanents. + * + * @author LevelX2 + */ +public class ControlsPermanentsControllerTriggeredAbility extends StateTriggeredAbility { + + protected final FilterPermanent filter; + protected final ComparisonType type; + protected final int value; + + public ControlsPermanentsControllerTriggeredAbility(FilterPermanent filter, ComparisonType type, int value, Effect effect) { + super(Zone.BATTLEFIELD, effect); + this.filter = filter; + this.value = value; + this.type = type; + } + + public ControlsPermanentsControllerTriggeredAbility(final ControlsPermanentsControllerTriggeredAbility ability) { + super(ability); + this.filter = ability.filter; + this.type = ability.type; + this.value = ability.value; + } + + @Override + public ControlsPermanentsControllerTriggeredAbility copy() { + return new ControlsPermanentsControllerTriggeredAbility(this); + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + int inputValue = game.getBattlefield().countAll(filter, getControllerId(), game); + switch (type) { + case Equal: + if (inputValue != value) { + return false; + } + break; + case GreaterThan: + if (inputValue <= value) { + return false; + } + break; + case LessThan: + if (inputValue >= value) { + return false; + } + break; + } + return true; + } + + @Override + public String getRule() { + return "When you control " + filter.getMessage() + ", " + super.getRule(); + } +} diff --git a/Mage/src/mage/abilities/common/DamageDealtToAttachedTriggeredAbility.java b/Mage/src/mage/abilities/common/DamageDealtToAttachedTriggeredAbility.java new file mode 100644 index 00000000000..90e4b5fb267 --- /dev/null +++ b/Mage/src/mage/abilities/common/DamageDealtToAttachedTriggeredAbility.java @@ -0,0 +1,98 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.common; + +import java.util.UUID; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.Effect; +import mage.constants.SetTargetPointer; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + */ +public class DamageDealtToAttachedTriggeredAbility extends TriggeredAbilityImpl { + + protected SetTargetPointer setTargetPointer; + + public DamageDealtToAttachedTriggeredAbility(Effect effect, boolean optional) { + this(Zone.BATTLEFIELD, effect, optional, SetTargetPointer.NONE); + } + + public DamageDealtToAttachedTriggeredAbility(Zone zone, Effect effect, boolean optional, SetTargetPointer setTargetPointer) { + super(zone, effect, optional); + this.setTargetPointer = setTargetPointer; + } + + public DamageDealtToAttachedTriggeredAbility(final DamageDealtToAttachedTriggeredAbility ability) { + super(ability); + this.setTargetPointer = ability.setTargetPointer; + } + + @Override + public DamageDealtToAttachedTriggeredAbility copy() { + return new DamageDealtToAttachedTriggeredAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == EventType.DAMAGED_CREATURE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Permanent enchantment = game.getPermanent(sourceId); + UUID targetId = event.getTargetId(); + if(enchantment != null && enchantment.getAttachedTo() != null && targetId.equals(enchantment.getAttachedTo())) { + for(Effect effect : this.getEffects()) { + effect.setValue("damage", event.getAmount()); + switch(setTargetPointer) { + case PERMANENT: + effect.setTargetPointer(new FixedTarget(targetId)); + break; + case PLAYER: + effect.setTargetPointer(new FixedTarget(game.getPermanentOrLKIBattlefield(targetId).getControllerId())); + break; + } + } + return true; + } + return false; + } + + @Override + public String getRule() { + return "Whenever enchanted creature is dealt damage, " + super.getRule(); + } +} diff --git a/Mage/src/mage/abilities/effects/common/DealsDamageToOpponentTriggeredAbility.java b/Mage/src/mage/abilities/common/DealsDamageToOpponentTriggeredAbility.java similarity index 97% rename from Mage/src/mage/abilities/effects/common/DealsDamageToOpponentTriggeredAbility.java rename to Mage/src/mage/abilities/common/DealsDamageToOpponentTriggeredAbility.java index aa25f2b6e83..811b091401d 100644 --- a/Mage/src/mage/abilities/effects/common/DealsDamageToOpponentTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/DealsDamageToOpponentTriggeredAbility.java @@ -25,13 +25,12 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ -package mage.abilities.effects.common; +package mage.abilities.common; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.effects.Effect; import mage.constants.Zone; import mage.game.Game; -import mage.game.events.DamagePlayerEvent; import mage.game.events.DamagedPlayerEvent; import mage.game.events.GameEvent; import mage.target.targetpointer.FixedTarget; @@ -45,8 +44,8 @@ public class DealsDamageToOpponentTriggeredAbility extends TriggeredAbilityImpl public DealsDamageToOpponentTriggeredAbility(Effect effect) { this(effect, false, false); - } - + } + public DealsDamageToOpponentTriggeredAbility(Effect effect, boolean optional) { this(effect, optional, false); } diff --git a/Mage/src/mage/abilities/common/DiesCreatureTriggeredAbility.java b/Mage/src/mage/abilities/common/DiesCreatureTriggeredAbility.java index 6b4202de140..fe0a3240d55 100644 --- a/Mage/src/mage/abilities/common/DiesCreatureTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/DiesCreatureTriggeredAbility.java @@ -26,7 +26,7 @@ public class DiesCreatureTriggeredAbility extends TriggeredAbilityImpl { this(effect, optional, new FilterCreaturePermanent("another creature")); filter.add(new AnotherPredicate()); } - + public DiesCreatureTriggeredAbility(Effect effect, boolean optional, boolean another, boolean setTargetPointer) { this(effect, optional, new FilterCreaturePermanent("another creature")); filter.add(new AnotherPredicate()); @@ -38,12 +38,16 @@ public class DiesCreatureTriggeredAbility extends TriggeredAbilityImpl { } public DiesCreatureTriggeredAbility(Effect effect, boolean optional, FilterCreaturePermanent filter, boolean setTargetPointer) { - super(Zone.BATTLEFIELD, effect, optional); + this(Zone.BATTLEFIELD, effect, optional, filter, setTargetPointer); + } + + public DiesCreatureTriggeredAbility(Zone zone, Effect effect, boolean optional, FilterCreaturePermanent filter, boolean setTargetPointer) { + super(zone, effect, optional); this.filter = filter; this.setTargetPointer = setTargetPointer; } - public DiesCreatureTriggeredAbility(DiesCreatureTriggeredAbility ability) { + public DiesCreatureTriggeredAbility(final DiesCreatureTriggeredAbility ability) { super(ability); this.filter = ability.filter; this.setTargetPointer = ability.setTargetPointer; diff --git a/Mage/src/mage/abilities/common/DiesTriggeredAbility.java b/Mage/src/mage/abilities/common/DiesTriggeredAbility.java index 412d9518f09..aac46fbe9d8 100644 --- a/Mage/src/mage/abilities/common/DiesTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/DiesTriggeredAbility.java @@ -1,40 +1,40 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.common; -import mage.constants.Zone; import mage.MageObject; import mage.abilities.effects.Effect; +import mage.constants.Zone; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.ZoneChangeEvent; import mage.game.permanent.Permanent; +import mage.game.permanent.PermanentToken; /** * @@ -58,14 +58,22 @@ public class DiesTriggeredAbility extends ZoneChangeTriggeredAbility { public boolean isInUseableZone(Game game, MageObject source, GameEvent event) { // check it was previously on battlefield Permanent before = ((ZoneChangeEvent) event).getTarget(); - if (!this.hasSourceObjectAbility(game, before, event)) { + if (!(before instanceof PermanentToken) && !this.hasSourceObjectAbility(game, before, event)) { return false; - } + } // check now it is in graveyard Zone after = game.getState().getZone(sourceId); return before != null && after != null && Zone.GRAVEYARD.match(after); } + @Override + public boolean checkEventType(GameEvent event, Game game) { + if (super.checkEventType(event, game)) { + return ((ZoneChangeEvent) event).getFromZone().equals(Zone.BATTLEFIELD) && ((ZoneChangeEvent) event).getToZone().equals(Zone.GRAVEYARD); + } + return event.getType() == GameEvent.EventType.ZONE_CHANGE; + } + @Override public DiesTriggeredAbility copy() { return new DiesTriggeredAbility(this); @@ -80,7 +88,7 @@ public class DiesTriggeredAbility extends ZoneChangeTriggeredAbility { return false; } } - for (Effect effect: getEffects()) { + for (Effect effect : getEffects()) { effect.setValue("diedPermanent", zEvent.getTarget()); } return true; diff --git a/Mage/src/mage/abilities/common/LicidAbility.java b/Mage/src/mage/abilities/common/LicidAbility.java new file mode 100644 index 00000000000..a321266836d --- /dev/null +++ b/Mage/src/mage/abilities/common/LicidAbility.java @@ -0,0 +1,232 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.abilities.common; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.ActivatedAbilityImpl; +import mage.abilities.SpecialAction; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCost; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.CreateSpecialActionEffect; +import mage.abilities.effects.common.RemoveSpecialActionEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.Target; +import mage.target.common.TargetCreaturePermanent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author emerald000 + */ +public class LicidAbility extends ActivatedAbilityImpl { + + public LicidAbility(ManaCost activationCost, ManaCost specialActionCost) { + super(Zone.BATTLEFIELD, new LicidEffect(specialActionCost), activationCost); + this.addCost(new TapSourceCost()); + this.addTarget(new TargetCreaturePermanent()); + } + + public LicidAbility(LicidAbility ability) { + super(ability); + } + + @Override + public LicidAbility copy() { + return new LicidAbility(this); + } +} + +class LicidEffect extends OneShotEffect { + + private final ManaCost specialActionCost; + + LicidEffect(ManaCost specialActionCost) { + super(Outcome.Neutral); + this.specialActionCost = specialActionCost; + this.staticText = "{this} loses this ability and becomes an Aura enchantment with enchant creature. Attach it to target creature. You may pay " + specialActionCost.getText() + " to end this effect"; + } + + LicidEffect(final LicidEffect effect) { + super(effect); + this.specialActionCost = effect.specialActionCost; + } + + @Override + public LicidEffect copy() { + return new LicidEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent licid = (Permanent) source.getSourceObjectIfItStillExists(game); + if (licid != null) { + UUID messageId = UUID.randomUUID(); + LicidContinuousEffect effect = new LicidContinuousEffect(messageId); + effect.setTargetPointer(new FixedTarget(licid.getId())); + game.addEffect(effect, source); + new AttachEffect(Outcome.Neutral).apply(game, source); + SpecialAction specialAction = new LicidSpecialAction(this.specialActionCost, messageId, licid.getIdName()); + new CreateSpecialActionEffect(specialAction).apply(game, source); + return true; + } + return false; + } +} + +class LicidContinuousEffect extends ContinuousEffectImpl { + + private final UUID messageId; + + LicidContinuousEffect(UUID messageId) { + super(Duration.Custom, Outcome.Neutral); + this.messageId = messageId; + } + + LicidContinuousEffect(LicidContinuousEffect ability) { + super(ability); + this.messageId = ability.messageId; + } + + @Override + public boolean apply(Game game, Ability source) { + return false; + } + + @Override + public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { + Permanent licid = (Permanent) source.getSourceObjectIfItStillExists(game); + if (licid != null) { + switch (layer) { + case TypeChangingEffects_4: + licid.getCardType().clear(); + licid.getCardType().add(CardType.ENCHANTMENT); + licid.getSubtype().clear(); + licid.getSubtype().add("Aura"); + break; + case AbilityAddingRemovingEffects_6: + for (Ability ability : licid.getAbilities(game)) { + for (Effect effect : ability.getEffects()) { + if (effect instanceof LicidEffect) { + licid.getAbilities(game).remove(ability); + break; + } + } + } + Ability ability = new EnchantAbility("creature"); + ability.setRuleAtTheTop(true); + licid.addAbility(ability, source.getSourceId(), game); + licid.getSpellAbility().getTargets().clear(); + Target target = new TargetCreaturePermanent(); + target.addTarget(this.getTargetPointer().getFirst(game, source), source, game); + licid.getSpellAbility().getTargets().add(target); + } + return true; + } + discard(); + return false; + } + + @Override + public boolean hasLayer(Layer layer) { + return layer == Layer.TypeChangingEffects_4 || layer == Layer.AbilityAddingRemovingEffects_6; + } + + @Override + public boolean isInactive(Ability source, Game game) { + Object object = game.getState().getValue(this.messageId.toString()); + return object != null; + } + + @Override + public LicidContinuousEffect copy() { + return new LicidContinuousEffect(this); + } +} + +class LicidSpecialAction extends SpecialAction { + + LicidSpecialAction(ManaCost cost, UUID messageId, String licidName) { + super(); + this.addCost(cost); + this.addEffect(new LicidSpecialActionEffect(messageId, this.getId(), licidName)); + } + + LicidSpecialAction(final LicidSpecialAction ability) { + super(ability); + } + + @Override + public LicidSpecialAction copy() { + return new LicidSpecialAction(this); + } +} + +class LicidSpecialActionEffect extends OneShotEffect { + + private final UUID messageId; + private final UUID generatingSpecialActionId; + + LicidSpecialActionEffect(UUID messageId, UUID generatingSpecialActionId, String licidName) { + super(Outcome.Neutral); + this.messageId = messageId; + this.generatingSpecialActionId = generatingSpecialActionId; + this.staticText = "End " + licidName + " Effect"; + } + + LicidSpecialActionEffect(final LicidSpecialActionEffect effect) { + super(effect); + this.messageId = effect.messageId; + this.generatingSpecialActionId = effect.generatingSpecialActionId; + } + + @Override + public LicidSpecialActionEffect copy() { + return new LicidSpecialActionEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + new RemoveSpecialActionEffect(this.generatingSpecialActionId).apply(game, source); + game.getState().setValue(this.messageId.toString(), true); + return true; + } +} diff --git a/Mage/src/mage/abilities/common/OnEventTriggeredAbility.java b/Mage/src/mage/abilities/common/OnEventTriggeredAbility.java index b1130c36a49..c724b43fbe3 100644 --- a/Mage/src/mage/abilities/common/OnEventTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/OnEventTriggeredAbility.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.common; import mage.abilities.TriggeredAbilityImpl; @@ -58,13 +57,17 @@ public class OnEventTriggeredAbility extends TriggeredAbilityImpl { } public OnEventTriggeredAbility(EventType eventType, String eventName, boolean allPlayers, Effect effect) { + this(eventType, eventName, allPlayers, effect, false); + } + + public OnEventTriggeredAbility(EventType eventType, String eventName, boolean allPlayers, Effect effect, boolean optional) { super(Zone.BATTLEFIELD, effect); this.eventType = eventType; this.eventName = eventName; this.allPlayers = allPlayers; } - public OnEventTriggeredAbility(OnEventTriggeredAbility ability) { + public OnEventTriggeredAbility(final OnEventTriggeredAbility ability) { super(ability); this.eventType = ability.eventType; this.eventName = ability.eventName; @@ -78,7 +81,7 @@ public class OnEventTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { - if (allPlayers || event.getPlayerId().equals(this.controllerId) ) { + if (allPlayers || event.getPlayerId().equals(this.controllerId)) { return true; } return false; diff --git a/Mage/src/mage/abilities/common/PutCardIntoGraveFromAnywhereAllTriggeredAbility.java b/Mage/src/mage/abilities/common/PutCardIntoGraveFromAnywhereAllTriggeredAbility.java index 77fef28b1d6..fb2b469a727 100644 --- a/Mage/src/mage/abilities/common/PutCardIntoGraveFromAnywhereAllTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/PutCardIntoGraveFromAnywhereAllTriggeredAbility.java @@ -44,7 +44,6 @@ import mage.target.targetpointer.FixedTarget; * * @author LevelX2 */ - public class PutCardIntoGraveFromAnywhereAllTriggeredAbility extends TriggeredAbilityImpl { private final FilterCard filter; @@ -58,7 +57,7 @@ public class PutCardIntoGraveFromAnywhereAllTriggeredAbility extends TriggeredAb public PutCardIntoGraveFromAnywhereAllTriggeredAbility(Effect effect, boolean optional, FilterCard filter, TargetController targetController) { this(effect, optional, filter, targetController, SetTargetPointer.NONE); } - + public PutCardIntoGraveFromAnywhereAllTriggeredAbility(Effect effect, boolean optional, FilterCard filter, TargetController targetController, SetTargetPointer setTargetPointer) { this(Zone.BATTLEFIELD, effect, optional, filter, targetController, setTargetPointer); } @@ -110,13 +109,13 @@ public class PutCardIntoGraveFromAnywhereAllTriggeredAbility extends TriggeredAb if (card != null && filter.match(card, getSourceId(), getControllerId(), game)) { switch (setTargetPointer) { case CARD: - for (Effect effect: getEffects()) { - effect.setTargetPointer(new FixedTarget(card.getId())); + for (Effect effect : getEffects()) { + effect.setTargetPointer(new FixedTarget(card.getId(), card.getZoneChangeCounter(game))); } break; case PLAYER: - for (Effect effect: getEffects()) { - effect.setTargetPointer(new FixedTarget(card.getOwnerId())); + for (Effect effect : getEffects()) { + effect.setTargetPointer(new FixedTarget(card.getOwnerId(), 0)); } break; diff --git a/Mage/src/mage/abilities/common/SpellCastAllTriggeredAbility.java b/Mage/src/mage/abilities/common/SpellCastAllTriggeredAbility.java index 51882dc3bbd..4b552ae9ed0 100644 --- a/Mage/src/mage/abilities/common/SpellCastAllTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/SpellCastAllTriggeredAbility.java @@ -86,10 +86,10 @@ public class SpellCastAllTriggeredAbility extends TriggeredAbilityImpl { @Override public boolean checkTrigger(GameEvent event, Game game) { Spell spell = game.getStack().getSpell(event.getTargetId()); - if (spell != null && filter.match(spell, getControllerId(), game)) { + if (spell != null && filter.match(spell, getSourceId(), getControllerId(), game)) { if (!setTargetPointer.equals(SetTargetPointer.NONE)) { for (Effect effect : this.getEffects()) { - switch(setTargetPointer) { + switch (setTargetPointer) { case SPELL: effect.setTargetPointer(new FixedTarget(spell.getId())); break; diff --git a/Mage/src/mage/abilities/common/SpellCastControllerTriggeredAbility.java b/Mage/src/mage/abilities/common/SpellCastControllerTriggeredAbility.java index 471bda4c7ec..d576a13690a 100644 --- a/Mage/src/mage/abilities/common/SpellCastControllerTriggeredAbility.java +++ b/Mage/src/mage/abilities/common/SpellCastControllerTriggeredAbility.java @@ -47,7 +47,8 @@ public class SpellCastControllerTriggeredAbility extends TriggeredAbilityImpl { protected String rule; /** - * If true, the source that triggered the ability will be set as target to effect. + * If true, the source that triggered the ability will be set as target to + * effect. */ protected boolean rememberSource = false; @@ -58,7 +59,7 @@ public class SpellCastControllerTriggeredAbility extends TriggeredAbilityImpl { public SpellCastControllerTriggeredAbility(Effect effect, FilterSpell filter, boolean optional) { this(effect, filter, optional, false); } - + public SpellCastControllerTriggeredAbility(Effect effect, FilterSpell filter, boolean optional, String rule) { this(effect, filter, optional, false); this.rule = rule; @@ -90,7 +91,7 @@ public class SpellCastControllerTriggeredAbility extends TriggeredAbilityImpl { public boolean checkTrigger(GameEvent event, Game game) { if (event.getPlayerId().equals(this.getControllerId())) { Spell spell = game.getStack().getSpell(event.getTargetId()); - if (spell != null && filter.match(spell, getControllerId(), game)) { + if (spell != null && filter.match(spell, getSourceId(), getControllerId(), game)) { if (rememberSource) { this.getEffects().get(0).setTargetPointer(new FixedTarget(spell.getId())); } diff --git a/Mage/src/mage/abilities/common/TurnFaceUpAbility.java b/Mage/src/mage/abilities/common/TurnFaceUpAbility.java index 0b6b9e0a0d3..f08922dbaba 100644 --- a/Mage/src/mage/abilities/common/TurnFaceUpAbility.java +++ b/Mage/src/mage/abilities/common/TurnFaceUpAbility.java @@ -1,38 +1,37 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.common; import mage.abilities.Ability; -import mage.abilities.ActivatedAbilityImpl; import mage.abilities.SpecialAction; import mage.abilities.costs.Cost; import mage.abilities.costs.Costs; +import mage.abilities.costs.mana.ManaCost; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; import mage.constants.AbilityType; @@ -47,17 +46,23 @@ import mage.players.Player; * * @author LevelX2 */ - -public class TurnFaceUpAbility extends SpecialAction { +public class TurnFaceUpAbility extends SpecialAction { public TurnFaceUpAbility(Costs costs) { this(costs, false); } - + public TurnFaceUpAbility(Costs costs, boolean megamorph) { super(Zone.BATTLEFIELD); this.addEffect(new TurnFaceUpEffect(megamorph)); - this.addCost(costs); + for (Cost cost : costs) { + if (cost instanceof ManaCost) { + this.addManaCost((ManaCost) cost); + } else { + this.addCost(cost); + } + } + this.usesStack = false; this.abilityType = AbilityType.SPECIAL_ACTION; this.setRuleVisible(false); // will be made visible only to controller in CardView @@ -76,10 +81,10 @@ public class TurnFaceUpAbility extends SpecialAction { class TurnFaceUpEffect extends OneShotEffect { private final boolean megamorph; - + public TurnFaceUpEffect(boolean megamorph) { super(Outcome.Benefit); - this.staticText = "Turn this face-down permanent face up" +(megamorph ? " and put a +1/+1 counter on it":""); + this.staticText = "Turn this face-down permanent face up" + (megamorph ? " and put a +1/+1 counter on it" : ""); this.megamorph = megamorph; } @@ -97,13 +102,14 @@ class TurnFaceUpEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); Card card = game.getCard(source.getSourceId()); - if (controller != null && card !=null) { + if (controller != null && card != null) { Permanent sourcePermanent = game.getPermanent(source.getSourceId()); if (sourcePermanent != null) { if (sourcePermanent.turnFaceUp(game, source.getControllerId())) { if (megamorph) { sourcePermanent.addCounters(CounterType.P1P1.createInstance(), game); } + game.getState().setValue(source.getSourceId().toString() + "TurnFaceUpX", source.getManaCostsToPay().getX()); return true; } } diff --git a/Mage/src/mage/abilities/condition/common/LastTimeCounterRemovedCondition.java b/Mage/src/mage/abilities/condition/common/LastTimeCounterRemovedCondition.java new file mode 100644 index 00000000000..0c47125c9ca --- /dev/null +++ b/Mage/src/mage/abilities/condition/common/LastTimeCounterRemovedCondition.java @@ -0,0 +1,35 @@ +package mage.abilities.condition.common; + +import mage.abilities.Ability; +import mage.abilities.condition.Condition; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * Created by glerman on 20/6/15. + */ +public class LastTimeCounterRemovedCondition implements Condition{ + + + private static final LastTimeCounterRemovedCondition fInstance = new LastTimeCounterRemovedCondition(); + + public static LastTimeCounterRemovedCondition getInstance() { + return fInstance; + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent == null) { + permanent = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD); + } + if (permanent != null) { + final int timeCounters = permanent.getCounters().getCount(CounterType.TIME); + return timeCounters == 0; + } else { + return false; + } + } +} diff --git a/Mage/src/mage/abilities/costs/OptionalAdditionalCost.java b/Mage/src/mage/abilities/costs/OptionalAdditionalCost.java index 75f75c5a414..83aa204299e 100644 --- a/Mage/src/mage/abilities/costs/OptionalAdditionalCost.java +++ b/Mage/src/mage/abilities/costs/OptionalAdditionalCost.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs; /** @@ -52,15 +51,15 @@ public interface OptionalAdditionalCost extends Cost { String getReminderText(); /** - * Returns a text suffix for the game log, that can be added to - * the cast message. + * Returns a text suffix for the game log, that can be added to the cast + * message. * - * @param position - if there are multiple costs, it's the postion the cost is set (starting with 0) + * @param position - if there are multiple costs, it's the postion the cost + * is set (starting with 0) * @return */ String getCastSuffixMessage(int position); - /** * If the player intends to pay the cost, the cost will be activated * @@ -96,8 +95,9 @@ public interface OptionalAdditionalCost extends Cost { /** * Returns the number of times the cost was activated + * * @return */ int getActivateCount(); - + } diff --git a/Mage/src/mage/abilities/costs/OptionalAdditionalCostImpl.java b/Mage/src/mage/abilities/costs/OptionalAdditionalCostImpl.java index 6132df52fc8..489d8690ea7 100644 --- a/Mage/src/mage/abilities/costs/OptionalAdditionalCostImpl.java +++ b/Mage/src/mage/abilities/costs/OptionalAdditionalCostImpl.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs; /** @@ -33,10 +32,7 @@ package mage.abilities.costs; * @author LevelX2 * @param */ - - -public class OptionalAdditionalCostImpl extends CostsImpl implements OptionalAdditionalCost{ - +public class OptionalAdditionalCostImpl extends CostsImpl implements OptionalAdditionalCost { protected String name; protected String reminderText; @@ -104,26 +100,26 @@ public class OptionalAdditionalCostImpl e } /** - * Returns a text suffix for the game log, that can be added to - * the cast message. + * Returns a text suffix for the game log, that can be added to the cast + * message. * - * @param position - if there are multiple costs, it's the postion the cost is set (starting with 0) + * @param position - if there are multiple costs, it's the postion the cost + * is set (starting with 0) * @return */ @Override public String getCastSuffixMessage(int position) { StringBuilder sb = new StringBuilder(); if (isActivated() && (!isRepeatable() || getActivateCount() > 0)) { - sb.append(position > 0 ? " and ":"").append(" with "); + sb.append(position > 0 ? " and " : "").append(" with "); if (isRepeatable()) { - sb.append(getActivateCount()).append(getActivateCount() > 1? " times ":" time "); + sb.append(getActivateCount()).append(getActivateCount() > 1 ? " times " : " time "); } sb.append(name); } - return sb.toString(); + return sb.toString(); } - /** * If the player intends to pay the cost, the cost will be activated * @@ -132,7 +128,9 @@ public class OptionalAdditionalCostImpl e public void activate() { activated = true; ++activatedCounter; - }; + } + + ; /** * Reset the activate and count information @@ -152,7 +150,7 @@ public class OptionalAdditionalCostImpl e @Override public void setRepeatable(boolean repeatable) { this.repeatable = repeatable; - } + } /** * Can the cost be multiple times activated @@ -162,7 +160,9 @@ public class OptionalAdditionalCostImpl e @Override public boolean isRepeatable() { return repeatable; - }; + } + + ; /** * Returns if the cost was activated @@ -170,20 +170,24 @@ public class OptionalAdditionalCostImpl e * @return */ @Override - public boolean isActivated(){ + public boolean isActivated() { return activated; - }; + } + + ; /** * Returns the number of times the cost was activated * @return */ @Override - public int getActivateCount(){ + public int getActivateCount() { return activatedCounter; - }; + } + + ; + - @Override public OptionalAdditionalCostImpl copy() { return new OptionalAdditionalCostImpl(this); diff --git a/Mage/src/mage/abilities/costs/OptionalAdditionalSourceCosts.java b/Mage/src/mage/abilities/costs/OptionalAdditionalSourceCosts.java index 41bebeb4fa6..041d11a3c84 100644 --- a/Mage/src/mage/abilities/costs/OptionalAdditionalSourceCosts.java +++ b/Mage/src/mage/abilities/costs/OptionalAdditionalSourceCosts.java @@ -33,11 +33,14 @@ import mage.game.Game; /** * Interface for abilities that add additional costs to the source. * - * Example of such additional source costs: {@link mage.abilities.keyword.KickerAbility} + * Example of such additional source costs: + * {@link mage.abilities.keyword.KickerAbility} * * @author LevelX2 */ public interface OptionalAdditionalSourceCosts { + void addOptionalAdditionalCosts(Ability ability, Game game); + String getCastMessageSuffix(); -} \ No newline at end of file +} diff --git a/Mage/src/mage/abilities/costs/VariableCostImpl.java b/Mage/src/mage/abilities/costs/VariableCostImpl.java index cb8245e78c8..c020d7922ba 100644 --- a/Mage/src/mage/abilities/costs/VariableCostImpl.java +++ b/Mage/src/mage/abilities/costs/VariableCostImpl.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.costs; import java.util.UUID; @@ -39,7 +38,6 @@ import mage.target.Targets; * * @author LevelX2 */ - public abstract class VariableCostImpl implements Cost, VariableCost { protected UUID id; @@ -53,10 +51,12 @@ public abstract class VariableCostImpl implements Cost, VariableCost { public VariableCostImpl(String actionText) { this("X", actionText); } + /** * * @param xText string for the defined value - * @param actionText what happens with the value (e.g. "to tap", "to exile from your graveyard") + * @param actionText what happens with the value (e.g. "to tap", "to exile + * from your graveyard") */ public VariableCostImpl(String xText, String actionText) { id = UUID.randomUUID(); @@ -122,11 +122,13 @@ public abstract class VariableCostImpl implements Cost, VariableCost { @Override public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { return true; /* not used */ + } @Override public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { return true; /* not used */ + } @Override @@ -154,7 +156,7 @@ public abstract class VariableCostImpl implements Cost, VariableCost { int xValue = 0; Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - xValue = controller.announceXCost(0, getMaxValue(source, game), + xValue = controller.announceXCost(getMinValue(source, game), getMaxValue(source, game), new StringBuilder("Announce the number of ").append(actionText).toString(), game, source, this); } diff --git a/Mage/src/mage/abilities/costs/common/ExileTopCardOfGraveyardCost.java b/Mage/src/mage/abilities/costs/common/ExileTopCardOfGraveyardCost.java new file mode 100644 index 00000000000..997753dc722 --- /dev/null +++ b/Mage/src/mage/abilities/costs/common/ExileTopCardOfGraveyardCost.java @@ -0,0 +1,63 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.costs.common; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.CostImpl; +import mage.cards.Card; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class ExileTopCardOfGraveyardCost extends CostImpl { + + private final int amount; + + public ExileTopCardOfGraveyardCost(int amount) { + this.amount = amount; + this.text = "Exile the top card of your graveyard"; + } + + public ExileTopCardOfGraveyardCost(ExileTopCardOfGraveyardCost cost) { + super(cost); + this.amount = cost.amount; + } + + @Override + public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { + Player controller = game.getPlayer(controllerId); + if(controller == null) { + return false; + } + return controller.getGraveyard().size() >= amount; + } + + @Override + public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { + Player controller = game.getPlayer(controllerId); + if(controller != null) { + Card topCard = null; + for (Card card :controller.getGraveyard().getCards(game)) { + topCard = card; + } + if (topCard != null) { + controller.moveCardToExileWithInfo(topCard, null, "", ability.getSourceId(), game, Zone.GRAVEYARD, true); + paid = true; + } + } + return paid; + } + + @Override + public ExileTopCardOfGraveyardCost copy() { + return new ExileTopCardOfGraveyardCost(this); + } +} \ No newline at end of file diff --git a/Mage/src/mage/abilities/costs/common/ExileTopCreatureCardOfGraveyardCost.java b/Mage/src/mage/abilities/costs/common/ExileTopCreatureCardOfGraveyardCost.java new file mode 100644 index 00000000000..00f0b18eef0 --- /dev/null +++ b/Mage/src/mage/abilities/costs/common/ExileTopCreatureCardOfGraveyardCost.java @@ -0,0 +1,66 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.costs.common; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.costs.CostImpl; +import mage.cards.Card; +import mage.constants.CardType; +import mage.constants.Zone; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author fireshoes + */ +public class ExileTopCreatureCardOfGraveyardCost extends CostImpl { + + private final int amount; + + public ExileTopCreatureCardOfGraveyardCost(int amount) { + this.amount = amount; + this.text = "Exile the top creature card of your graveyard"; + } + + public ExileTopCreatureCardOfGraveyardCost(ExileTopCreatureCardOfGraveyardCost cost) { + super(cost); + this.amount = cost.amount; + } + + @Override + public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { + Player controller = game.getPlayer(controllerId); + if(controller == null) { + return false; + } + return controller.getGraveyard().size() >= amount; + } + + @Override + public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { + Player controller = game.getPlayer(controllerId); + if(controller != null) { + Card topCard = null; + for (Card card :controller.getGraveyard().getCards(game)) { + if (card.getCardType().contains(CardType.CREATURE)) { + topCard = card; + } + } + if (topCard != null) { + controller.moveCardToExileWithInfo(topCard, null, "", ability.getSourceId(), game, Zone.GRAVEYARD, true); + paid = true; + } + } + return paid; + } + + @Override + public ExileTopCreatureCardOfGraveyardCost copy() { + return new ExileTopCreatureCardOfGraveyardCost(this); + } +} diff --git a/Mage/src/mage/abilities/costs/common/RemoveCounterCost.java b/Mage/src/mage/abilities/costs/common/RemoveCounterCost.java index 28526853e3b..85f7676eb46 100644 --- a/Mage/src/mage/abilities/costs/common/RemoveCounterCost.java +++ b/Mage/src/mage/abilities/costs/common/RemoveCounterCost.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,16 +20,14 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs.common; import java.util.HashSet; -import java.util.List; import java.util.Set; import java.util.UUID; import mage.abilities.Ability; @@ -55,7 +53,7 @@ public class RemoveCounterCost extends CostImpl { private String name; private CounterType counterTypeToRemove; private int countersToRemove; - + public RemoveCounterCost(TargetPermanent target) { this(target, null); } @@ -88,7 +86,7 @@ public class RemoveCounterCost extends CostImpl { if (controller != null) { target.clearChosen(); if (target.choose(Outcome.UnboostCreature, controllerId, sourceId, game)) { - for (UUID targetId: (List)target.getTargets()) { + for (UUID targetId : target.getTargets()) { Permanent permanent = game.getPermanent(targetId); if (permanent != null) { if (permanent.getCounters().size() > 0 && (counterTypeToRemove == null || permanent.getCounters().containsKey(counterTypeToRemove))) { @@ -123,18 +121,19 @@ public class RemoveCounterCost extends CostImpl { int numberOfCountersSelected = 1; if (countersLeft > 1 && countersOnPermanent > 1) { numberOfCountersSelected = controller.getAmount(1, Math.min(countersLeft, countersOnPermanent), - new StringBuilder("Remove how many counters from ").append(permanent.getIdName()).toString(), game); + new StringBuilder("Remove how many counters from ").append(permanent.getIdName()).toString(), game); } permanent.removeCounters(counterName, numberOfCountersSelected, game); - if (permanent.getCounters().getCount(counterName) == 0 ){ + if (permanent.getCounters().getCount(counterName) == 0) { permanent.getCounters().removeCounter(counterName); } countersRemoved += numberOfCountersSelected; - if (!game.isSimulation()) + if (!game.isSimulation()) { game.informPlayers(new StringBuilder(controller.getLogName()) - .append(" removes ").append(numberOfCountersSelected == 1 ? "a":numberOfCountersSelected).append(" ") - .append(counterName).append(numberOfCountersSelected == 1 ? " counter from ":" counters from ") - .append(permanent.getName()).toString()); + .append(" removes ").append(numberOfCountersSelected == 1 ? "a" : numberOfCountersSelected).append(" ") + .append(counterName).append(numberOfCountersSelected == 1 ? " counter from " : " counters from ") + .append(permanent.getName()).toString()); + } if (countersRemoved == countersToRemove) { this.paid = true; break; @@ -160,7 +159,7 @@ public class RemoveCounterCost extends CostImpl { if (counterTypeToRemove != null) { sb.append(counterTypeToRemove.getName()); } - sb.append(countersToRemove == 1 ? " counter from ":" counters from ").append(target.getMaxNumberOfTargets() == 1 ? "a ":"").append(target.getTargetName()); + sb.append(countersToRemove == 1 ? " counter from " : " counters from ").append(target.getMaxNumberOfTargets() == 1 ? "a " : "").append(target.getTargetName()); return sb.toString(); } diff --git a/Mage/src/mage/abilities/costs/common/RemoveVariableCountersSourceCost.java b/Mage/src/mage/abilities/costs/common/RemoveVariableCountersSourceCost.java index 49020791d4c..7678d644736 100644 --- a/Mage/src/mage/abilities/costs/common/RemoveVariableCountersSourceCost.java +++ b/Mage/src/mage/abilities/costs/common/RemoveVariableCountersSourceCost.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs.common; import mage.abilities.Ability; @@ -39,37 +38,38 @@ import mage.game.permanent.Permanent; * * @author LevelX2 */ -public class RemoveVariableCountersSourceCost extends VariableCostImpl { +public class RemoveVariableCountersSourceCost extends VariableCostImpl { protected int minimalCountersToPay = 0; private String counterName; - public RemoveVariableCountersSourceCost(Counter counter, int minimalCountersToPay) { - super(new StringBuilder(counter.getName()).append(" counters to remove").toString()); - this.minimalCountersToPay = minimalCountersToPay; - this.counterName = counter.getName(); - this.text = new StringBuilder("Remove ").append(xText).append(" ").append(counterName).append(" counters from {this}").toString(); - } - public RemoveVariableCountersSourceCost(Counter counter) { this(counter, 0); } - - public RemoveVariableCountersSourceCost(Counter counter, int minimalCountersToPay, String text) { - this(counter, minimalCountersToPay); - this.text = text; - } public RemoveVariableCountersSourceCost(Counter counter, String text) { - this(counter); - this.text = text; + this(counter, 0, text); + } + + public RemoveVariableCountersSourceCost(Counter counter, int minimalCountersToPay) { + this(counter, minimalCountersToPay, ""); + } + + public RemoveVariableCountersSourceCost(Counter counter, int minimalCountersToPay, String text) { + super(counter.getName() + " counters to remove"); + this.minimalCountersToPay = minimalCountersToPay; + this.counterName = counter.getName(); + if (text == null || text.isEmpty()) { + this.text = "Remove X " + counterName + " counters from {this}"; + } else { + this.text = text; + } } public RemoveVariableCountersSourceCost(final RemoveVariableCountersSourceCost cost) { super(cost); this.minimalCountersToPay = cost.minimalCountersToPay; this.counterName = cost.counterName; - this.text = cost.text; } @Override @@ -98,4 +98,3 @@ public class RemoveVariableCountersSourceCost extends VariableCostImpl { } } - diff --git a/Mage/src/mage/abilities/costs/common/ReturnToHandFromGraveyardCost.java b/Mage/src/mage/abilities/costs/common/ReturnToHandFromGraveyardCost.java index 91b85072c9a..48dc5dcdadb 100644 --- a/Mage/src/mage/abilities/costs/common/ReturnToHandFromGraveyardCost.java +++ b/Mage/src/mage/abilities/costs/common/ReturnToHandFromGraveyardCost.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,22 +20,19 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs.common; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.costs.CostImpl; import mage.constants.Outcome; -import mage.constants.Zone; import mage.game.Game; import mage.players.Player; -import mage.target.TargetCard; import mage.target.common.TargetCardInYourGraveyard; /** @@ -52,6 +49,7 @@ public class ReturnToHandFromGraveyardCost extends CostImpl { this.text = new StringBuilder("return ").append(target.getTargetName()).append(" from graveyard to it's owner's hand").toString(); } } + public ReturnToHandFromGraveyardCost(ReturnToHandFromGraveyardCost cost) { super(cost); } @@ -61,12 +59,12 @@ public class ReturnToHandFromGraveyardCost extends CostImpl { Player controller = game.getPlayer(controllerId); if (controller != null) { if (targets.choose(Outcome.ReturnToHand, controllerId, sourceId, game)) { - for (UUID targetId: targets.get(0).getTargets()) { + for (UUID targetId : targets.get(0).getTargets()) { mage.cards.Card targetCard = game.getCard(targetId); if (targetCard == null) { return false; } - paid |= controller.moveCardToHandWithInfo(targetCard, sourceId, game, Zone.HAND); + paid |= controller.moveCardToHandWithInfo(targetCard, sourceId, game); } } } diff --git a/Mage/src/mage/abilities/costs/common/ReturnToHandTargetPermanentCost.java b/Mage/src/mage/abilities/costs/common/ReturnToHandTargetPermanentCost.java index 4506854c705..6a0e383c83f 100644 --- a/Mage/src/mage/abilities/costs/common/ReturnToHandTargetPermanentCost.java +++ b/Mage/src/mage/abilities/costs/common/ReturnToHandTargetPermanentCost.java @@ -25,14 +25,12 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.costs.common; import java.util.UUID; import mage.abilities.Ability; import mage.abilities.costs.CostImpl; import mage.constants.Outcome; -import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; @@ -62,12 +60,12 @@ public class ReturnToHandTargetPermanentCost extends CostImpl { Player controller = game.getPlayer(controllerId); if (controller != null) { if (targets.choose(Outcome.ReturnToHand, controllerId, sourceId, game)) { - for (UUID targetId: targets.get(0).getTargets()) { + for (UUID targetId : targets.get(0).getTargets()) { Permanent permanent = game.getPermanent(targetId); if (permanent == null) { return false; } - paid |= controller.moveCardToHandWithInfo(permanent, sourceId, game, Zone.HAND); + paid |= controller.moveCardToHandWithInfo(permanent, sourceId, game); } } } @@ -84,5 +82,4 @@ public class ReturnToHandTargetPermanentCost extends CostImpl { return new ReturnToHandTargetPermanentCost(this); } - } diff --git a/Mage/src/mage/abilities/costs/mana/HybridManaCost.java b/Mage/src/mage/abilities/costs/mana/HybridManaCost.java index 0658d9e68c9..b8f9cdedb93 100644 --- a/Mage/src/mage/abilities/costs/mana/HybridManaCost.java +++ b/Mage/src/mage/abilities/costs/mana/HybridManaCost.java @@ -27,6 +27,8 @@ */ package mage.abilities.costs.mana; +import java.util.ArrayList; +import java.util.List; import mage.Mana; import mage.abilities.Ability; import mage.constants.ColoredManaSymbol; @@ -130,6 +132,14 @@ public class HybridManaCost extends ManaCostImpl { return mana1.equals(coloredManaSymbol) || mana2.equals(coloredManaSymbol); } + @Override + public List getManaOptions() { + List manaList = new ArrayList<>(); + manaList.add(new Mana(mana1)); + manaList.add(new Mana(mana2)); + return manaList; + } + public ColoredManaSymbol getMana1() { return mana1; } diff --git a/Mage/src/mage/abilities/costs/mana/ManaCost.java b/Mage/src/mage/abilities/costs/mana/ManaCost.java index 58d6aa1aa6f..b1616aaa577 100644 --- a/Mage/src/mage/abilities/costs/mana/ManaCost.java +++ b/Mage/src/mage/abilities/costs/mana/ManaCost.java @@ -1,33 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.costs.mana; +import java.util.List; import mage.Mana; import mage.abilities.Ability; import mage.abilities.costs.Cost; @@ -40,15 +40,27 @@ import mage.players.ManaPool; public interface ManaCost extends Cost { int convertedManaCost(); + Mana getMana(); + + List getManaOptions(); + Mana getPayment(); + void assignPayment(Game game, Ability ability, ManaPool pool); + void setPayment(Mana mana); + ManaCost getUnpaid(); + ManaOptions getOptions(); + boolean testPay(Mana testMana); + Filter getSourceFilter(); + void setSourceFilter(Filter filter); + boolean containsColor(ColoredManaSymbol coloredManaSymbol); @Override diff --git a/Mage/src/mage/abilities/costs/mana/ManaCostImpl.java b/Mage/src/mage/abilities/costs/mana/ManaCostImpl.java index e22723c32fe..c33e0f5799b 100644 --- a/Mage/src/mage/abilities/costs/mana/ManaCostImpl.java +++ b/Mage/src/mage/abilities/costs/mana/ManaCostImpl.java @@ -1,47 +1,47 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.costs.mana; +import java.util.ArrayList; +import java.util.List; import java.util.UUID; -import mage.constants.ColoredManaSymbol; -import mage.constants.ManaType; import mage.Mana; import mage.abilities.Ability; import mage.abilities.costs.CostImpl; import mage.abilities.mana.ManaOptions; +import mage.constants.ColoredManaSymbol; +import mage.constants.ManaType; import mage.filter.Filter; import mage.game.Game; import mage.players.ManaPool; import mage.players.Player; import mage.util.ManaUtil; - public abstract class ManaCostImpl extends CostImpl implements ManaCost { protected Mana payment; @@ -74,6 +74,13 @@ public abstract class ManaCostImpl extends CostImpl implements ManaCost { return cost; } + @Override + public List getManaOptions() { + List manaList = new ArrayList<>(); + manaList.add(cost); + return manaList; + } + @Override public ManaOptions getOptions() { return options; @@ -211,11 +218,10 @@ public abstract class ManaCostImpl extends CostImpl implements ManaCost { game.getState().getSpecialActions().removeManaActions(); while (!isPaid()) { ManaCost unpaid = this.getUnpaid(); - String promptText = ManaUtil.addSpecialManaPayAbilities(ability, game, unpaid); - if (player.playMana(unpaid, promptText, game)) { + String promptText = ManaUtil.addSpecialManaPayAbilities(ability, game, unpaid); + if (player.playMana(ability, unpaid, promptText, game)) { assignPayment(game, ability, player.getManaPool()); - } - else { + } else { return false; } game.getState().getSpecialActions().removeManaActions(); diff --git a/Mage/src/mage/abilities/costs/mana/ManaCosts.java b/Mage/src/mage/abilities/costs/mana/ManaCosts.java index e21c8fa2aca..2fe86c5345a 100644 --- a/Mage/src/mage/abilities/costs/mana/ManaCosts.java +++ b/Mage/src/mage/abilities/costs/mana/ManaCosts.java @@ -60,4 +60,5 @@ public interface ManaCosts extends List, ManaCost { @Override ManaCosts copy(); + } diff --git a/Mage/src/mage/abilities/costs/mana/ManaCostsImpl.java b/Mage/src/mage/abilities/costs/mana/ManaCostsImpl.java index 4b610c2af3f..c6d7654244a 100644 --- a/Mage/src/mage/abilities/costs/mana/ManaCostsImpl.java +++ b/Mage/src/mage/abilities/costs/mana/ManaCostsImpl.java @@ -100,6 +100,15 @@ public class ManaCostsImpl extends ArrayList implements M return mana; } + @Override + public List getManaOptions() { + List manaVariants = new ArrayList<>(); + for (ManaCost cost : this) { + manaVariants.addAll(cost.getManaOptions()); + } + return manaVariants; + } + @Override public Mana getPayment() { Mana manaTotal = new Mana(); @@ -122,7 +131,7 @@ public class ManaCostsImpl extends ArrayList implements M while (!isPaid()) { ManaCost unpaid = this.getUnpaid(); String promptText = ManaUtil.addSpecialManaPayAbilities(ability, game, unpaid); - if (player.playMana(unpaid, promptText, game)) { + if (player.playMana(ability, unpaid, promptText, game)) { assignPayment(game, ability, player.getManaPool()); } else { return false; diff --git a/Mage/src/mage/abilities/costs/mana/MonoHybridManaCost.java b/Mage/src/mage/abilities/costs/mana/MonoHybridManaCost.java index 44c207a159e..1d4a6170140 100644 --- a/Mage/src/mage/abilities/costs/mana/MonoHybridManaCost.java +++ b/Mage/src/mage/abilities/costs/mana/MonoHybridManaCost.java @@ -27,6 +27,8 @@ */ package mage.abilities.costs.mana; +import java.util.ArrayList; +import java.util.List; import mage.Mana; import mage.abilities.Ability; import mage.constants.ColoredManaSymbol; @@ -118,4 +120,12 @@ public class MonoHybridManaCost extends ManaCostImpl { public boolean containsColor(ColoredManaSymbol coloredManaSymbol) { return mana.equals(coloredManaSymbol); } + + @Override + public List getManaOptions() { + List manaList = new ArrayList<>(); + manaList.add(new Mana(mana)); + manaList.add(Mana.ColorlessMana(2)); + return manaList; + } } diff --git a/Mage/src/mage/abilities/decorator/ConditionalGainActivatedAbility.java b/Mage/src/mage/abilities/decorator/ConditionalGainActivatedAbility.java index f0456f2e11f..9fe5123f838 100644 --- a/Mage/src/mage/abilities/decorator/ConditionalGainActivatedAbility.java +++ b/Mage/src/mage/abilities/decorator/ConditionalGainActivatedAbility.java @@ -28,8 +28,6 @@ package mage.abilities.decorator; import java.util.UUID; - -import mage.constants.Zone; import mage.abilities.ActivatedAbilityImpl; import mage.abilities.condition.Condition; import mage.abilities.costs.Cost; @@ -38,6 +36,7 @@ import mage.abilities.costs.mana.ManaCosts; import mage.abilities.effects.Effect; import mage.abilities.effects.Effects; import mage.constants.EffectType; +import mage.constants.Zone; import mage.game.Game; /** @@ -47,12 +46,12 @@ import mage.game.Game; */ public class ConditionalGainActivatedAbility extends ActivatedAbilityImpl { - private Condition condition; - private String staticText = ""; + private final Condition condition; + private String staticText = ""; - private static final Effects emptyEffects = new Effects(); + private static final Effects emptyEffects = new Effects(); - public ConditionalGainActivatedAbility(Zone zone, Effect effect, ManaCosts cost, Condition condition, String rule) { + public ConditionalGainActivatedAbility(Zone zone, Effect effect, ManaCosts cost, Condition condition, String rule) { super(zone, effect, cost); this.condition = condition; this.staticText = rule; diff --git a/Mage/src/mage/abilities/decorator/ConditionalTriggeredAbility.java b/Mage/src/mage/abilities/decorator/ConditionalTriggeredAbility.java index 7a05e126a7c..abc62f152c4 100644 --- a/Mage/src/mage/abilities/decorator/ConditionalTriggeredAbility.java +++ b/Mage/src/mage/abilities/decorator/ConditionalTriggeredAbility.java @@ -1,9 +1,11 @@ package mage.abilities.decorator; +import mage.abilities.Modes; import mage.abilities.TriggeredAbility; import mage.abilities.TriggeredAbilityImpl; import mage.abilities.condition.Condition; import mage.abilities.effects.Effects; +import mage.constants.EffectType; import mage.game.Game; import mage.game.events.GameEvent; @@ -19,22 +21,26 @@ public class ConditionalTriggeredAbility extends TriggeredAbilityImpl { protected Condition condition; protected String text; + /** + * Triggered ability with a condition. Set the optionality for the trigger + * ability itself. + * + * @param ability + * @param condition + * @param text if null or empty, the rule text of the triggered ability + * itself is used. + */ public ConditionalTriggeredAbility(TriggeredAbility ability, Condition condition, String text) { - this(ability, condition, text, false); - } - - public ConditionalTriggeredAbility(TriggeredAbility ability, Condition condition, String text, boolean optional) { super(ability.getZone(), null); this.ability = ability; this.modes = ability.getModes(); this.condition = condition; - this.optional = optional; this.text = text; } public ConditionalTriggeredAbility(final ConditionalTriggeredAbility triggered) { super(triggered); - this.ability = triggered.ability; + this.ability = triggered.ability.copy(); this.condition = triggered.condition; this.text = triggered.text; } @@ -74,4 +80,19 @@ public class ConditionalTriggeredAbility extends TriggeredAbilityImpl { return ability.getEffects(); } + @Override + public Modes getModes() { + return ability.getModes(); + } + + @Override + public Effects getEffects(Game game, EffectType effectType) { + return ability.getEffects(game, effectType); + } + + @Override + public boolean isOptional() { + return ability.isOptional(); + } + } diff --git a/Mage/src/mage/abilities/dynamicvalue/IntPlusDynamicValue.java b/Mage/src/mage/abilities/dynamicvalue/IntPlusDynamicValue.java index bb787f1db5d..17b2373adee 100644 --- a/Mage/src/mage/abilities/dynamicvalue/IntPlusDynamicValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/IntPlusDynamicValue.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue; import mage.abilities.Ability; @@ -36,8 +35,8 @@ import mage.game.Game; * * @author LevelX2 */ - public class IntPlusDynamicValue implements DynamicValue { + private final DynamicValue value; private final int baseValue; @@ -57,7 +56,7 @@ public class IntPlusDynamicValue implements DynamicValue { } @Override - public DynamicValue copy() { + public IntPlusDynamicValue copy() { return new IntPlusDynamicValue(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/MultipliedValue.java b/Mage/src/mage/abilities/dynamicvalue/MultipliedValue.java index 142e4957461..66c92a0809a 100644 --- a/Mage/src/mage/abilities/dynamicvalue/MultipliedValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/MultipliedValue.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue; import mage.abilities.Ability; @@ -36,8 +35,8 @@ import mage.game.Game; * * @author LevelX2 */ - public class MultipliedValue implements DynamicValue { + private final DynamicValue value; private final int multplier; @@ -57,7 +56,7 @@ public class MultipliedValue implements DynamicValue { } @Override - public DynamicValue copy() { + public MultipliedValue copy() { return new MultipliedValue(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/AttackingCreatureCount.java b/Mage/src/mage/abilities/dynamicvalue/common/AttackingCreatureCount.java index cb14e541b48..085246aa33b 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/AttackingCreatureCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/AttackingCreatureCount.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -38,8 +37,6 @@ import mage.game.combat.CombatGroup; * * @author LevelX2 */ - - public class AttackingCreatureCount implements DynamicValue { private String message; @@ -67,7 +64,7 @@ public class AttackingCreatureCount implements DynamicValue { } @Override - public DynamicValue copy() { + public AttackingCreatureCount copy() { return new AttackingCreatureCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/AuraAttachedCount.java b/Mage/src/mage/abilities/dynamicvalue/common/AuraAttachedCount.java index 373025c4383..be484456be7 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/AuraAttachedCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/AuraAttachedCount.java @@ -27,15 +27,14 @@ */ package mage.abilities.dynamicvalue.common; +import java.util.List; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; import mage.game.Game; import mage.game.permanent.Permanent; -import java.util.List; -import java.util.UUID; - /** * * @author North @@ -74,7 +73,7 @@ public class AuraAttachedCount implements DynamicValue { } @Override - public DynamicValue copy() { + public AuraAttachedCount copy() { return new AuraAttachedCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/CardsInAllGraveyardsCount.java b/Mage/src/mage/abilities/dynamicvalue/common/CardsInAllGraveyardsCount.java index debf69c55dc..caec5c530a7 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/CardsInAllGraveyardsCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/CardsInAllGraveyardsCount.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; import java.util.UUID; @@ -72,7 +71,7 @@ public class CardsInAllGraveyardsCount implements DynamicValue { } @Override - public DynamicValue copy() { + public CardsInAllGraveyardsCount copy() { return new CardsInAllGraveyardsCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerGraveyardCount.java b/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerGraveyardCount.java index 114bbba06d8..c69bea308f6 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerGraveyardCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerGraveyardCount.java @@ -44,7 +44,7 @@ public class CardsInControllerGraveyardCount implements DynamicValue { } @Override - public DynamicValue copy() { + public CardsInControllerGraveyardCount copy() { return new CardsInControllerGraveyardCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerHandCount.java b/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerHandCount.java index f94de01572e..71e9836cb8a 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerHandCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/CardsInControllerHandCount.java @@ -7,6 +7,7 @@ import mage.game.Game; import mage.players.Player; public class CardsInControllerHandCount implements DynamicValue { + @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { if (sourceAbility != null) { @@ -19,7 +20,7 @@ public class CardsInControllerHandCount implements DynamicValue { } @Override - public DynamicValue copy() { + public CardsInControllerHandCount copy() { return new CardsInControllerHandCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/CardsInTargetPlayerHandCount.java b/Mage/src/mage/abilities/dynamicvalue/common/CardsInTargetPlayerHandCount.java index 27bab074560..393f45db14e 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/CardsInTargetPlayerHandCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/CardsInTargetPlayerHandCount.java @@ -22,7 +22,7 @@ public class CardsInTargetPlayerHandCount implements DynamicValue { } @Override - public DynamicValue copy() { + public CardsInTargetPlayerHandCount copy() { return new CardsInTargetPlayerHandCount(); } @@ -30,5 +30,5 @@ public class CardsInTargetPlayerHandCount implements DynamicValue { public String getMessage() { return "cards in target player's hand"; } - + } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ControllerGotLifeCount.java b/Mage/src/mage/abilities/dynamicvalue/common/ControllerGotLifeCount.java index a1df5caba3c..cb9571281a9 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ControllerGotLifeCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ControllerGotLifeCount.java @@ -25,9 +25,10 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; +import java.io.ObjectStreamException; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.MageSingleton; import mage.abilities.dynamicvalue.DynamicValue; @@ -35,18 +36,14 @@ import mage.abilities.effects.Effect; import mage.game.Game; import mage.watchers.common.PlayerGainedLifeWatcher; -import java.io.ObjectStreamException; -import java.util.UUID; - /** * Amount of life the controller got this turn. - * + * * @author LevelX2 */ - public class ControllerGotLifeCount implements DynamicValue, MageSingleton { - private static final ControllerGotLifeCount fINSTANCE = new ControllerGotLifeCount(); + private static final ControllerGotLifeCount fINSTANCE = new ControllerGotLifeCount(); private Object readResolve() throws ObjectStreamException { return fINSTANCE; @@ -70,7 +67,7 @@ public class ControllerGotLifeCount implements DynamicValue, MageSingleton { } @Override - public DynamicValue copy() { + public ControllerGotLifeCount copy() { return new ControllerGotLifeCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ControllerLifeCount.java b/Mage/src/mage/abilities/dynamicvalue/common/ControllerLifeCount.java index 688b28b63c9..e756e77e3e4 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ControllerLifeCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ControllerLifeCount.java @@ -7,6 +7,7 @@ import mage.game.Game; import mage.players.Player; public class ControllerLifeCount implements DynamicValue { + @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { Player p = game.getPlayer(sourceAbility.getControllerId()); @@ -17,7 +18,7 @@ public class ControllerLifeCount implements DynamicValue { } @Override - public DynamicValue copy() { + public ControllerLifeCount copy() { return new ControllerLifeCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/CountersCount.java b/Mage/src/mage/abilities/dynamicvalue/common/CountersCount.java index fd0e3926190..fdf010b7045 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/CountersCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/CountersCount.java @@ -1,15 +1,14 @@ package mage.abilities.dynamicvalue.common; -import mage.MageObject; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; -import mage.constants.Zone; import mage.counters.CounterType; import mage.game.Game; import mage.game.permanent.Permanent; public class CountersCount implements DynamicValue { + private final CounterType counter; public CountersCount(CounterType counter) { @@ -30,7 +29,7 @@ public class CountersCount implements DynamicValue { } @Override - public DynamicValue copy() { + public CountersCount copy() { return new CountersCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/DevotionCount.java b/Mage/src/mage/abilities/dynamicvalue/common/DevotionCount.java index 439f2146e3b..fd8edb3ebe5 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/DevotionCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/DevotionCount.java @@ -4,6 +4,8 @@ */ package mage.abilities.dynamicvalue.common; +import java.util.ArrayList; +import java.util.Arrays; import mage.abilities.Ability; import mage.abilities.costs.mana.ManaCost; import mage.abilities.dynamicvalue.DynamicValue; @@ -12,11 +14,9 @@ import mage.constants.ColoredManaSymbol; import mage.game.Game; import mage.game.permanent.Permanent; -import java.util.ArrayList; -import java.util.Arrays; - /** - * Each colored mana symbol (e.g. {U}) in the mana costs of permanents you control counts toward your devotion to that color. + * Each colored mana symbol (e.g. {U}) in the mana costs of permanents you + * control counts toward your devotion to that color. * * @author LevelX2 */ @@ -36,8 +36,8 @@ public class DevotionCount implements DynamicValue { public int calculate(Game game, Ability sourceAbility, Effect effect) { int devotion = 0; for (Permanent permanent : game.getBattlefield().getAllActivePermanents(sourceAbility.getControllerId())) { - for(ManaCost manaCost :permanent.getManaCost()) { - for(ColoredManaSymbol coloredManaSymbol: devotionColors) { + for (ManaCost manaCost : permanent.getManaCost()) { + for (ColoredManaSymbol coloredManaSymbol : devotionColors) { if (manaCost.containsColor(coloredManaSymbol)) { devotion++; break; // count each manaCost maximum of one time (Hybrid don't count for multiple colors of devotion) @@ -49,7 +49,7 @@ public class DevotionCount implements DynamicValue { } @Override - public DynamicValue copy() { + public DevotionCount copy() { return new DevotionCount(this); } @@ -62,7 +62,7 @@ public class DevotionCount implements DynamicValue { public String getMessage() { StringBuilder sb = new StringBuilder("devotion to "); int count = 0; - for (ColoredManaSymbol coloredManaSymbol:devotionColors) { + for (ColoredManaSymbol coloredManaSymbol : devotionColors) { if (count > 0) { sb.append(" and "); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/DevouredCreaturesCount.java b/Mage/src/mage/abilities/dynamicvalue/common/DevouredCreaturesCount.java index 7f3084786d9..4ce7c389bd5 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/DevouredCreaturesCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/DevouredCreaturesCount.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -40,7 +39,6 @@ import mage.game.permanent.Permanent; * * @author LevelX2 */ - public class DevouredCreaturesCount implements DynamicValue { int multiplier; @@ -65,7 +63,7 @@ public class DevouredCreaturesCount implements DynamicValue { if (sourcePermanent != null) { for (Ability ability : sourcePermanent.getAbilities()) { if (ability instanceof DevourAbility) { - for (Effect abilityEffect: ability.getEffects()) { + for (Effect abilityEffect : ability.getEffects()) { if (abilityEffect instanceof DevourEffect) { DevourEffect devourEffect = (DevourEffect) abilityEffect; return devourEffect.getDevouredCreaturesAmount(game, sourcePermanent.getId()) * multiplier; diff --git a/Mage/src/mage/abilities/dynamicvalue/common/DiscardCostCardConvertedMana.java b/Mage/src/mage/abilities/dynamicvalue/common/DiscardCostCardConvertedMana.java index 773e73e12ed..b14708d05eb 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/DiscardCostCardConvertedMana.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/DiscardCostCardConvertedMana.java @@ -15,11 +15,11 @@ public class DiscardCostCardConvertedMana implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost instanceof DiscardCardCost) { DiscardCardCost discardCost = (DiscardCardCost) cost; int cmc = 0; - for (Card card :discardCost.getCards()) { + for (Card card : discardCost.getCards()) { cmc += card.getManaCost().convertedManaCost(); } return cmc; @@ -29,7 +29,7 @@ public class DiscardCostCardConvertedMana implements DynamicValue { } @Override - public DynamicValue copy() { + public DiscardCostCardConvertedMana copy() { return new DiscardCostCardConvertedMana(); } @@ -38,7 +38,6 @@ public class DiscardCostCardConvertedMana implements DynamicValue { return ""; } - @Override public String getMessage() { return "the discarded card's converted mana cost"; diff --git a/Mage/src/mage/abilities/dynamicvalue/common/DomainValue.java b/Mage/src/mage/abilities/dynamicvalue/common/DomainValue.java index e61d565b90f..06c0efeef47 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/DomainValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/DomainValue.java @@ -15,6 +15,7 @@ public class DomainValue implements DynamicValue { private Integer amount; private boolean countTargetPlayer; + private UUID playerId; public DomainValue() { this(1); @@ -33,9 +34,15 @@ public class DomainValue implements DynamicValue { this.countTargetPlayer = countTargetPlayer; } + public DomainValue(Integer amount, UUID playerId) { + this(amount, false); + this.playerId = playerId; + } + public DomainValue(final DomainValue dynamicValue) { this.amount = dynamicValue.amount; this.countTargetPlayer = dynamicValue.countTargetPlayer; + this.playerId = dynamicValue.playerId; } @Override @@ -46,7 +53,10 @@ public class DomainValue implements DynamicValue { int haveSwamps = 0; int haveForests = 0; UUID targetPlayer; - if (countTargetPlayer) { + if(playerId != null) { + targetPlayer = playerId; + } + else if(countTargetPlayer) { targetPlayer = sourceAbility.getTargets().getFirstTarget(); } else { targetPlayer = sourceAbility.getControllerId(); @@ -74,7 +84,7 @@ public class DomainValue implements DynamicValue { } @Override - public DynamicValue copy() { + public DomainValue copy() { return new DomainValue(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/EquipmentAttachedCount.java b/Mage/src/mage/abilities/dynamicvalue/common/EquipmentAttachedCount.java index dcbba5c951a..6bc0e8c51c2 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/EquipmentAttachedCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/EquipmentAttachedCount.java @@ -27,15 +27,14 @@ */ package mage.abilities.dynamicvalue.common; +import java.util.List; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; import mage.game.Game; import mage.game.permanent.Permanent; -import java.util.List; -import java.util.UUID; - /** * * @author North, noxx @@ -73,7 +72,7 @@ public class EquipmentAttachedCount implements DynamicValue { } @Override - public DynamicValue copy() { + public EquipmentAttachedCount copy() { return new EquipmentAttachedCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ExileFromHandCostCardConvertedMana.java b/Mage/src/mage/abilities/dynamicvalue/common/ExileFromHandCostCardConvertedMana.java index eb24c0f60f3..29adcaf1eca 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ExileFromHandCostCardConvertedMana.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ExileFromHandCostCardConvertedMana.java @@ -36,20 +36,18 @@ import mage.cards.Card; import mage.game.Game; /** - * Calculates the converted mana costs of a card that was - * exiled from hand as cost. - * If no card was exiled the getManaCostsToPay().getX() will - * be used as value. + * Calculates the converted mana costs of a card that was exiled from hand as + * cost. If no card was exiled the getManaCostsToPay().getX() will be used as + * value. * * * @author LevelX2 */ - public class ExileFromHandCostCardConvertedMana implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost.isPaid() && cost instanceof ExileFromHandCost) { int xValue = 0; for (Card card : ((ExileFromHandCost) cost).getCards()) { @@ -62,7 +60,7 @@ public class ExileFromHandCostCardConvertedMana implements DynamicValue { } @Override - public DynamicValue copy() { + public ExileFromHandCostCardConvertedMana copy() { return new ExileFromHandCostCardConvertedMana(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ManaSpentToCastCount.java b/Mage/src/mage/abilities/dynamicvalue/common/ManaSpentToCastCount.java index a4734cb8daa..9ee09e5ea04 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ManaSpentToCastCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ManaSpentToCastCount.java @@ -39,9 +39,9 @@ import mage.game.stack.Spell; * * @author LevelX2 */ -public class ManaSpentToCastCount implements DynamicValue{ +public class ManaSpentToCastCount implements DynamicValue { - public ManaSpentToCastCount(){ + public ManaSpentToCastCount() { } @Override @@ -61,7 +61,7 @@ public class ManaSpentToCastCount implements DynamicValue{ } @Override - public DynamicValue copy() { + public ManaSpentToCastCount copy() { return new ManaSpentToCastCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ManaTypeInManaPoolCount.java b/Mage/src/mage/abilities/dynamicvalue/common/ManaTypeInManaPoolCount.java index 50275a242c2..1b0ebe8ff16 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ManaTypeInManaPoolCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ManaTypeInManaPoolCount.java @@ -34,7 +34,7 @@ public class ManaTypeInManaPoolCount implements DynamicValue { } @Override - public DynamicValue copy() { + public ManaTypeInManaPoolCount copy() { return new ManaTypeInManaPoolCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ManacostVariableValue.java b/Mage/src/mage/abilities/dynamicvalue/common/ManacostVariableValue.java index 38b6968264b..b6e7e2d6037 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/ManacostVariableValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/ManacostVariableValue.java @@ -13,7 +13,7 @@ public class ManacostVariableValue implements DynamicValue { } @Override - public DynamicValue copy() { + public ManacostVariableValue copy() { return new ManacostVariableValue(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/MorphManacostVariableValue.java b/Mage/src/mage/abilities/dynamicvalue/common/MorphManacostVariableValue.java new file mode 100644 index 00000000000..44c85ea4fa8 --- /dev/null +++ b/Mage/src/mage/abilities/dynamicvalue/common/MorphManacostVariableValue.java @@ -0,0 +1,42 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.dynamicvalue.common; + +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.Effect; +import mage.game.Game; + +/** + * + * @author LevelX2 + */ +public class MorphManacostVariableValue implements DynamicValue { + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + Integer xValue = (Integer) game.getState().getValue(sourceAbility.getSourceId().toString() + "TurnFaceUpX"); + if (xValue instanceof Integer) { + return xValue; + } + return 0; + } + + @Override + public MorphManacostVariableValue copy() { + return new MorphManacostVariableValue(); + } + + @Override + public String toString() { + return "X"; + } + + @Override + public String getMessage() { + return ""; + } +} diff --git a/Mage/src/mage/abilities/dynamicvalue/common/OpponentsLostLifeCount.java b/Mage/src/mage/abilities/dynamicvalue/common/OpponentsLostLifeCount.java index 3a227d20428..2603e6b02ca 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/OpponentsLostLifeCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/OpponentsLostLifeCount.java @@ -25,22 +25,19 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; import mage.game.Game; import mage.watchers.common.PlayerLostLifeWatcher; -import java.util.UUID; - /** * * @author LevelX2 */ - public class OpponentsLostLifeCount implements DynamicValue { @Override @@ -52,7 +49,7 @@ public class OpponentsLostLifeCount implements DynamicValue { PlayerLostLifeWatcher watcher = (PlayerLostLifeWatcher) game.getState().getWatchers().get("PlayerLostLifeWatcher"); if (watcher != null) { int amountLifeLost = 0; - for(UUID opponent: game.getOpponents(controllerId)){ + for (UUID opponent : game.getOpponents(controllerId)) { amountLifeLost += watcher.getLiveLost(opponent); } return amountLifeLost; @@ -61,7 +58,7 @@ public class OpponentsLostLifeCount implements DynamicValue { } @Override - public DynamicValue copy() { + public OpponentsLostLifeCount copy() { return new OpponentsLostLifeCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/ParleyCount.java b/Mage/src/mage/abilities/dynamicvalue/common/ParleyCount.java new file mode 100644 index 00000000000..9d70b0ac258 --- /dev/null +++ b/Mage/src/mage/abilities/dynamicvalue/common/ParleyCount.java @@ -0,0 +1,98 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.dynamicvalue.common; + +import java.io.ObjectStreamException; +import java.util.UUID; +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.MageSingleton; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.Effect; +import mage.cards.Card; +import mage.cards.CardsImpl; +import mage.constants.CardType; +import mage.game.Game; +import mage.players.Player; + +/** + * Don't use this for continuous effects because it applies a reveal effect! + * + * @author LevelX2 + */ +public class ParleyCount implements DynamicValue, MageSingleton { + + private static final ParleyCount fINSTANCE = new ParleyCount(); + + private Object readResolve() throws ObjectStreamException { + return fINSTANCE; + } + + public static ParleyCount getInstance() { + return fINSTANCE; + } + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + // Each player reveals the top card of his or her library. For each nonland card revealed this way + int parleyValue = 0; + MageObject sourceObject = game.getObject(sourceAbility.getSourceId()); + if (sourceObject != null) { + for (UUID playerId : game.getState().getPlayerList(sourceAbility.getControllerId())) { + Player player = game.getPlayer(playerId); + if (player != null) { + Card card = player.getLibrary().getFromTop(game); + if (card != null) { + if (!card.getCardType().contains(CardType.LAND)) { + parleyValue++; + } + player.revealCards(sourceObject.getIdName() + " (" + player.getName() + ")", new CardsImpl(card), game); + } + } + + } + } + return parleyValue; + } + + @Override + public ParleyCount copy() { + return fINSTANCE; + } + + @Override + public String toString() { + return "1"; + } + + @Override + public String getMessage() { + return "Parley"; + } + +} diff --git a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsOnBattlefieldCount.java b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsOnBattlefieldCount.java index a1875905cb4..0e1e2cd35a0 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsOnBattlefieldCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsOnBattlefieldCount.java @@ -1,3 +1,30 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -43,7 +70,7 @@ public class PermanentsOnBattlefieldCount implements DynamicValue { } @Override - public DynamicValue copy() { + public PermanentsOnBattlefieldCount copy() { return new PermanentsOnBattlefieldCount(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java index f1f7ef9b874..f53b9e1fbfb 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java @@ -1,3 +1,30 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -11,7 +38,6 @@ import mage.game.Game; * * @author LoneFox */ - public class PermanentsTargetOpponentControlsCount implements DynamicValue { private FilterPermanent filter; @@ -26,7 +52,7 @@ public class PermanentsTargetOpponentControlsCount implements DynamicValue { } public PermanentsTargetOpponentControlsCount(FilterPermanent filter, Integer multiplier) { - this.filter = filter; + this.filter = filter.copy(); this.multiplier = multiplier; } @@ -36,25 +62,24 @@ public class PermanentsTargetOpponentControlsCount implements DynamicValue { } @Override - public DynamicValue copy() { + public PermanentsTargetOpponentControlsCount copy() { return new PermanentsTargetOpponentControlsCount(this); } @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - if(sourceAbility.getFirstTarget() != null) { + if (sourceAbility.getFirstTarget() != null) { filter.add(new ControllerIdPredicate(sourceAbility.getFirstTarget())); int value = game.getBattlefield().count(filter, sourceAbility.getSourceId(), sourceAbility.getControllerId(), game); return multiplier * value; - } - else { + } else { return 0; } } @Override public String toString() { - if(multiplier != null) { + if (multiplier != null) { return multiplier.toString(); } return "X"; diff --git a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsYouOwnThatOpponentsControlCount.java b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsYouOwnThatOpponentsControlCount.java new file mode 100644 index 00000000000..bd454179977 --- /dev/null +++ b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsYouOwnThatOpponentsControlCount.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.dynamicvalue.common; + +import java.util.Set; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.effects.Effect; +import mage.game.Game; +import mage.game.permanent.Permanent; + +public class PermanentsYouOwnThatOpponentsControlCount implements DynamicValue { + + @Override + public int calculate(Game game, Ability sourceAbility, Effect effect) { + Set opponentIds = game.getOpponents(sourceAbility.getControllerId()); + int count = 0; + + for (Permanent permanent : game.getBattlefield().getActivePermanents(sourceAbility.getControllerId(), game)) { + if (!permanent.getOwnerId().equals(permanent.getControllerId()) && permanent.getOwnerId().equals(sourceAbility.getControllerId())) { + if (opponentIds.contains(permanent.getControllerId())) { + count++; + } + } + } + return count; + } + + @Override + public PermanentsYouOwnThatOpponentsControlCount copy() { + return new PermanentsYouOwnThatOpponentsControlCount(); + } + + @Override + public String getMessage() { + return "number of permanents you own that your opponents control"; + } + + @Override + public String toString() { + return "1"; + } +} diff --git a/Mage/src/mage/abilities/dynamicvalue/common/RemovedCountersForCostValue.java b/Mage/src/mage/abilities/dynamicvalue/common/RemovedCountersForCostValue.java index 4d27f4dacac..7fce69b56c9 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/RemovedCountersForCostValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/RemovedCountersForCostValue.java @@ -3,7 +3,6 @@ * To change this template file, choose Tools | Templates * and open the template in the editor. */ - package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -21,7 +20,7 @@ public class RemovedCountersForCostValue implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost instanceof RemoveVariableCountersSourceCost) { return ((RemoveVariableCountersSourceCost) cost).getAmount(); } @@ -31,11 +30,11 @@ public class RemovedCountersForCostValue implements DynamicValue { @Override public String getMessage() { - return "number of removed counters"; + return "number of removed counters"; } @Override - public DynamicValue copy() { + public RemovedCountersForCostValue copy() { return new RemovedCountersForCostValue(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/RevealTargetFromHandCostCount.java b/Mage/src/mage/abilities/dynamicvalue/common/RevealTargetFromHandCostCount.java index 373b5889e72..4e09ad6554c 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/RevealTargetFromHandCostCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/RevealTargetFromHandCostCount.java @@ -3,7 +3,6 @@ * To change this template file, choose Tools | Templates * and open the template in the editor. */ - package mage.abilities.dynamicvalue.common; import mage.abilities.Ability; @@ -21,7 +20,7 @@ public class RevealTargetFromHandCostCount implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost instanceof RevealTargetFromHandCost) { return ((RevealTargetFromHandCost) cost).getNumberRevealedCards(); } @@ -31,11 +30,11 @@ public class RevealTargetFromHandCostCount implements DynamicValue { @Override public String getMessage() { - return "number of revealed cards"; + return "number of revealed cards"; } @Override - public DynamicValue copy() { + public RevealTargetFromHandCostCount copy() { return new RevealTargetFromHandCostCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesPower.java b/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesPower.java index acfb07d3a66..a563d3c93fa 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesPower.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesPower.java @@ -15,11 +15,11 @@ public class SacrificeCostCreaturesPower implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost instanceof SacrificeTargetCost) { SacrificeTargetCost sacrificeCost = (SacrificeTargetCost) cost; int powerSum = 0; - for (Permanent permanent :sacrificeCost.getPermanents()) { + for (Permanent permanent : sacrificeCost.getPermanents()) { powerSum += permanent.getPower().getValue(); } return powerSum; @@ -29,7 +29,7 @@ public class SacrificeCostCreaturesPower implements DynamicValue { } @Override - public DynamicValue copy() { + public SacrificeCostCreaturesPower copy() { return new SacrificeCostCreaturesPower(); } @@ -38,7 +38,6 @@ public class SacrificeCostCreaturesPower implements DynamicValue { return "X"; } - @Override public String getMessage() { return "the sacrificed creature's power"; diff --git a/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesToughness.java b/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesToughness.java index 8df1b39c1b1..15256c9c716 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesToughness.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/SacrificeCostCreaturesToughness.java @@ -15,11 +15,11 @@ public class SacrificeCostCreaturesToughness implements DynamicValue { @Override public int calculate(Game game, Ability sourceAbility, Effect effect) { - for (Cost cost: sourceAbility.getCosts()) { + for (Cost cost : sourceAbility.getCosts()) { if (cost instanceof SacrificeTargetCost) { SacrificeTargetCost sacrificeCost = (SacrificeTargetCost) cost; int toughnessSum = 0; - for (Permanent permanent :sacrificeCost.getPermanents()) { + for (Permanent permanent : sacrificeCost.getPermanents()) { toughnessSum += permanent.getToughness().getValue(); } return toughnessSum; @@ -29,7 +29,7 @@ public class SacrificeCostCreaturesToughness implements DynamicValue { } @Override - public DynamicValue copy() { + public SacrificeCostCreaturesToughness copy() { return new SacrificeCostCreaturesToughness(); } @@ -38,7 +38,6 @@ public class SacrificeCostCreaturesToughness implements DynamicValue { return "X"; } - @Override public String getMessage() { return "the sacrificed creature's toughness"; diff --git a/Mage/src/mage/abilities/dynamicvalue/common/SignInversionDynamicValue.java b/Mage/src/mage/abilities/dynamicvalue/common/SignInversionDynamicValue.java index 2b50242ec4c..d029966a6a9 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/SignInversionDynamicValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/SignInversionDynamicValue.java @@ -6,6 +6,7 @@ import mage.abilities.effects.Effect; import mage.game.Game; public class SignInversionDynamicValue implements DynamicValue { + private final DynamicValue value; public SignInversionDynamicValue(DynamicValue value) { @@ -22,7 +23,7 @@ public class SignInversionDynamicValue implements DynamicValue { } @Override - public DynamicValue copy() { + public SignInversionDynamicValue copy() { return new SignInversionDynamicValue(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/SourcePermanentPowerCount.java b/Mage/src/mage/abilities/dynamicvalue/common/SourcePermanentPowerCount.java index 040973ca7d7..70c54d46ec4 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/SourcePermanentPowerCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/SourcePermanentPowerCount.java @@ -21,7 +21,7 @@ public class SourcePermanentPowerCount implements DynamicValue { } @Override - public DynamicValue copy() { + public SourcePermanentPowerCount copy() { return new SourcePermanentPowerCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/StaticValue.java b/Mage/src/mage/abilities/dynamicvalue/common/StaticValue.java index 73c981fd64c..13a1befea65 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/StaticValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/StaticValue.java @@ -1,18 +1,19 @@ package mage.abilities.dynamicvalue.common; - import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.effects.Effect; import mage.game.Game; public class StaticValue implements DynamicValue { + private int value = 0; private String message; - + public StaticValue(int value) { this(value, ""); } + public StaticValue(int value, String message) { this.value = value; this.message = message; @@ -29,7 +30,7 @@ public class StaticValue implements DynamicValue { } @Override - public DynamicValue copy() { + public StaticValue copy() { return new StaticValue(this); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/SunburstCount.java b/Mage/src/mage/abilities/dynamicvalue/common/SunburstCount.java index 0fa70eb8582..8cb1fbf5cd6 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/SunburstCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/SunburstCount.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.dynamicvalue.common; import mage.Mana; @@ -40,33 +39,32 @@ import mage.game.stack.StackObject; * * @author Nicolas */ +public class SunburstCount implements DynamicValue { + public SunburstCount() { -public class SunburstCount implements DynamicValue{ - public SunburstCount(){ - } - + @Override public int calculate(Game game, Ability source, Effect effect) { int count = 0; if (!game.getStack().isEmpty()) { StackObject spell = game.getStack().getFirst(); - if (spell != null && spell instanceof Spell && ((Spell)spell).getSourceId().equals(source.getSourceId())) { - Mana mana = ((Spell)spell).getSpellAbility().getManaCostsToPay().getPayment(); - if(mana.getBlack() > 0) { + if (spell != null && spell instanceof Spell && ((Spell) spell).getSourceId().equals(source.getSourceId())) { + Mana mana = ((Spell) spell).getSpellAbility().getManaCostsToPay().getPayment(); + if (mana.getBlack() > 0) { count++; } - if(mana.getBlue() > 0) { + if (mana.getBlue() > 0) { count++; } - if(mana.getGreen() > 0) { + if (mana.getGreen() > 0) { count++; } - if(mana.getRed() > 0) { + if (mana.getRed() > 0) { count++; } - if(mana.getWhite() > 0) { + if (mana.getWhite() > 0) { count++; } } @@ -75,14 +73,13 @@ public class SunburstCount implements DynamicValue{ } @Override - public DynamicValue copy() { + public SunburstCount copy() { return new SunburstCount(); } - @Override public String getMessage() { return "color of mana spent to cast it"; } - + } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/TargetConvertedManaCost.java b/Mage/src/mage/abilities/dynamicvalue/common/TargetConvertedManaCost.java index 97b33f5fba9..c56b5cfce51 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/TargetConvertedManaCost.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/TargetConvertedManaCost.java @@ -49,7 +49,7 @@ public class TargetConvertedManaCost implements DynamicValue { } @Override - public DynamicValue copy() { + public TargetConvertedManaCost copy() { return new TargetConvertedManaCost(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/TargetPermanentPowerCount.java b/Mage/src/mage/abilities/dynamicvalue/common/TargetPermanentPowerCount.java index d6bc27590fb..9cf6f74447e 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/TargetPermanentPowerCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/TargetPermanentPowerCount.java @@ -54,7 +54,7 @@ public class TargetPermanentPowerCount implements DynamicValue { } @Override - public DynamicValue copy() { + public TargetPermanentPowerCount copy() { return new TargetPermanentPowerCount(); } diff --git a/Mage/src/mage/abilities/dynamicvalue/common/UrzaTerrainValue.java b/Mage/src/mage/abilities/dynamicvalue/common/UrzaTerrainValue.java index 9ab2a9dd55c..3db1e5f9aab 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/UrzaTerrainValue.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/UrzaTerrainValue.java @@ -8,6 +8,7 @@ import mage.filter.predicate.mageobject.SubtypePredicate; import mage.game.Game; public class UrzaTerrainValue implements DynamicValue { + private final int value; public UrzaTerrainValue(int value) { @@ -19,24 +20,21 @@ public class UrzaTerrainValue implements DynamicValue { FilterControlledPermanent pp = new FilterControlledPermanent("Urza's Power Plant"); pp.add(new SubtypePredicate("Urza's Power-Plant")); PermanentsOnBattlefieldCount ppP = new PermanentsOnBattlefieldCount(pp); - if (ppP.calculate(game, sourceAbility, effect) < 1) - { + if (ppP.calculate(game, sourceAbility, effect) < 1) { return 1; } FilterControlledPermanent to = new FilterControlledPermanent("Urza's Tower"); to.add(new SubtypePredicate("Urza's Tower")); PermanentsOnBattlefieldCount toP = new PermanentsOnBattlefieldCount(to); - if (toP.calculate(game, sourceAbility, effect) < 1) - { + if (toP.calculate(game, sourceAbility, effect) < 1) { return 1; } FilterControlledPermanent mi = new FilterControlledPermanent("Urza's Mine"); mi.add(new SubtypePredicate("Urza's Mine")); PermanentsOnBattlefieldCount miP = new PermanentsOnBattlefieldCount(mi); - if (miP.calculate(game, sourceAbility, effect) < 1) - { + if (miP.calculate(game, sourceAbility, effect) < 1) { return 1; } @@ -44,7 +42,7 @@ public class UrzaTerrainValue implements DynamicValue { } @Override - public DynamicValue copy() { + public UrzaTerrainValue copy() { return new UrzaTerrainValue(value); } diff --git a/Mage/src/mage/abilities/effects/AuraReplacementEffect.java b/Mage/src/mage/abilities/effects/AuraReplacementEffect.java index e5cdec0b930..8c4a0e063e9 100644 --- a/Mage/src/mage/abilities/effects/AuraReplacementEffect.java +++ b/Mage/src/mage/abilities/effects/AuraReplacementEffect.java @@ -51,13 +51,15 @@ import mage.target.common.TargetCardInGraveyard; /** * Cards with the Aura subtype don't change the zone they are in, if there is no * valid target on the battlefield. Also, when entering the battlefield and it - * was not cast (so from Zone != Hand), this effect gets the target to whitch to attach it - * and adds the Aura the the battlefield and attachs it to the target. + * was not cast (so from Zone != Hand), this effect gets the target to whitch to + * attach it and adds the Aura the the battlefield and attachs it to the target. * The "attachTo:" value in game state has to be set therefore. - * - * If no "attachTo:" value is defined, the controlling player has to chose the aura target. * - * This effect is automatically added to ContinuousEffects at the start of a game + * If no "attachTo:" value is defined, the controlling player has to chose the + * aura target. + * + * This effect is automatically added to ContinuousEffects at the start of a + * game * * @author North */ @@ -93,7 +95,7 @@ public class AuraReplacementEffect extends ReplacementEffectImpl { return false; } // Aura enters the battlefield attached - Object object = game.getState().getValue("attachTo:"+card.getId()); + Object object = game.getState().getValue("attachTo:" + card.getId()); if (object != null && object instanceof PermanentCard) { return false; } @@ -113,18 +115,19 @@ public class AuraReplacementEffect extends ReplacementEffectImpl { targetId = stackAbility.getEffects().get(0).getTargetPointer().getFirst(game, stackAbility); } } - + if (targetId == null) { Target target = card.getSpellAbility().getTargets().get(0); enchantCardInGraveyard = target instanceof TargetCardInGraveyard; - if (enchantCardInGraveyard && target != null) { - target.clearChosen(); + if (target != null) { + target.clearChosen(); // neccessary if e.g. aura is blinked multiple times } Player player = game.getPlayer(card.getOwnerId()); Outcome auraOutcome = Outcome.BoostCreature; - Ability: for (Ability ability:card.getAbilities()) { + Ability: + for (Ability ability : card.getAbilities()) { if (ability instanceof SpellAbility) { - for (Effect effect: ability.getEffects()) { + for (Effect effect : ability.getEffects()) { if (effect instanceof AttachEffect) { auraOutcome = effect.getOutcome(); break Ability; @@ -167,13 +170,16 @@ public class AuraReplacementEffect extends ReplacementEffectImpl { game.getBattlefield().addPermanent(permanent); card.setZone(Zone.BATTLEFIELD, game); game.applyEffects(); - permanent.entersBattlefield(event.getSourceId(), game, fromZone, true); + boolean entered = permanent.entersBattlefield(event.getSourceId(), game, fromZone, true); game.applyEffects(); + if (!entered) { + return false; + } game.fireEvent(new ZoneChangeEvent(permanent, controllerId, fromZone, Zone.BATTLEFIELD)); if (targetCard != null) { permanent.attachTo(targetCard.getId(), game); - } + } if (targetPermanent != null) { targetPermanent.addAttachment(permanent.getId(), game); } @@ -183,7 +189,7 @@ public class AuraReplacementEffect extends ReplacementEffectImpl { } return true; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == GameEvent.EventType.ZONE_CHANGE; @@ -192,7 +198,7 @@ public class AuraReplacementEffect extends ReplacementEffectImpl { @Override public boolean applies(GameEvent event, Ability source, Game game) { if (((ZoneChangeEvent) event).getToZone().equals(Zone.BATTLEFIELD) - && !(((ZoneChangeEvent) event).getFromZone().equals(Zone.HAND)) ) { + && !(((ZoneChangeEvent) event).getFromZone().equals(Zone.HAND))) { Card card = game.getCard(event.getTargetId()); if (card != null && card.getCardType().contains(CardType.ENCHANTMENT) && card.hasSubtype("Aura")) { return true; diff --git a/Mage/src/mage/abilities/effects/ContinuousEffectImpl.java b/Mage/src/mage/abilities/effects/ContinuousEffectImpl.java index a3603203321..e793058a81d 100644 --- a/Mage/src/mage/abilities/effects/ContinuousEffectImpl.java +++ b/Mage/src/mage/abilities/effects/ContinuousEffectImpl.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects; import java.util.ArrayList; @@ -69,7 +68,7 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu protected boolean affectedObjectsSet = false; protected List affectedObjectList = new ArrayList<>(); protected boolean temporary = false; - + // until your next turn protected int startingTurn; protected UUID startingControllerId; @@ -96,7 +95,7 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu this.used = effect.used; this.discarded = effect.discarded; this.affectedObjectsSet = effect.affectedObjectsSet; - this.affectedObjectList.addAll(effect.affectedObjectList); + this.affectedObjectList.addAll(effect.affectedObjectList); this.temporary = effect.temporary; this.startingTurn = effect.startingTurn; this.startingControllerId = effect.startingControllerId; @@ -148,8 +147,8 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu } /** - * Sets the discarded state of the effect. So it - * will be removed on next check. + * Sets the discarded state of the effect. So it will be removed on next + * check. */ @Override public void discard() { @@ -160,7 +159,7 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu public void init(Ability source, Game game) { targetPointer.init(game, source); //20100716 - 611.2c - if (AbilityType.ACTIVATED.equals(source.getAbilityType()) + if (AbilityType.ACTIVATED.equals(source.getAbilityType()) || AbilityType.SPELL.equals(source.getAbilityType()) || AbilityType.TRIGGERED.equals(source.getAbilityType())) { if (layer != null) { @@ -174,11 +173,10 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu case PTChangingEffects_7: this.affectedObjectsSet = true; } - } - else { - if (hasLayer(Layer.CopyEffects_1) || hasLayer(Layer.ControlChangingEffects_2) || hasLayer(Layer.TextChangingEffects_3) || - hasLayer(Layer.TypeChangingEffects_4) || hasLayer(Layer.ColorChangingEffects_5) || hasLayer(Layer.AbilityAddingRemovingEffects_6) || - hasLayer(Layer.PTChangingEffects_7)) { + } else { + if (hasLayer(Layer.CopyEffects_1) || hasLayer(Layer.ControlChangingEffects_2) || hasLayer(Layer.TextChangingEffects_3) + || hasLayer(Layer.TypeChangingEffects_4) || hasLayer(Layer.ColorChangingEffects_5) || hasLayer(Layer.AbilityAddingRemovingEffects_6) + || hasLayer(Layer.PTChangingEffects_7)) { this.affectedObjectsSet = true; } } @@ -226,7 +224,7 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu return true; } if (toughness instanceof DomainValue) { - return ((DomainValue)toughness).getAmount() < 0; + return ((DomainValue) toughness).getAmount() < 0; } return false; } @@ -237,8 +235,10 @@ public abstract class ContinuousEffectImpl extends EffectImpl implements Continu } /** - * Returns the status if the effect is temporary added to the ContinuousEffects - * @return + * Returns the status if the effect is temporary added to the + * ContinuousEffects + * + * @return */ @Override public boolean isTemporary() { diff --git a/Mage/src/mage/abilities/effects/CopyCardEffect.java b/Mage/src/mage/abilities/effects/CopyCardEffect.java new file mode 100644 index 00000000000..3435e707673 --- /dev/null +++ b/Mage/src/mage/abilities/effects/CopyCardEffect.java @@ -0,0 +1,51 @@ +package mage.abilities.effects; + +import mage.abilities.Ability; +import mage.cards.Card; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.game.permanent.token.EmptyToken; +import mage.util.CardUtil; + +/** + * Created by glerman on 20/6/15. + */ +public class CopyCardEffect extends OneShotEffect { + + private final Card card; + private final int copies; + + public CopyCardEffect(Card card, int copies) { + super(Outcome.PutCreatureInPlay); + this.card = card; + this.copies = copies; + staticText = "Put a token onto the battlefield that's a copy of {this}"; + } + + public CopyCardEffect(final CopyCardEffect effect) { + super(effect); + this.card = effect.card; + this.copies = effect.copies; + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent == null) { + permanent = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD); + } + if (permanent != null) { + EmptyToken newToken = new EmptyToken(); + CardUtil.copyTo(newToken).from(permanent); + return newToken.putOntoBattlefield(copies, game, source.getSourceId(), source.getControllerId()); + } + return false; + } + + @Override + public CopyCardEffect copy() { + return new CopyCardEffect(this); + } +} diff --git a/Mage/src/mage/abilities/effects/common/AddManaAnyColorAttachedControllerEffect.java b/Mage/src/mage/abilities/effects/common/AddManaAnyColorAttachedControllerEffect.java index b81fd61aab9..d342c91b0c3 100644 --- a/Mage/src/mage/abilities/effects/common/AddManaAnyColorAttachedControllerEffect.java +++ b/Mage/src/mage/abilities/effects/common/AddManaAnyColorAttachedControllerEffect.java @@ -60,7 +60,7 @@ public class AddManaAnyColorAttachedControllerEffect extends ManaEffect { if (player != null) { ChoiceColor choice = new ChoiceColor(); while (!player.choose(outcome, choice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage/src/mage/abilities/effects/common/AddManaInAnyCombinationEffect.java b/Mage/src/mage/abilities/effects/common/AddManaInAnyCombinationEffect.java index 19f56cfeb80..4a87a976677 100644 --- a/Mage/src/mage/abilities/effects/common/AddManaInAnyCombinationEffect.java +++ b/Mage/src/mage/abilities/effects/common/AddManaInAnyCombinationEffect.java @@ -96,7 +96,7 @@ public class AddManaInAnyCombinationEffect extends ManaEffect { Mana mana = new Mana(); int amountOfManaLeft = amount.calculate(game, source, this); - while (amountOfManaLeft > 0 && player.isInGame()) { + while (amountOfManaLeft > 0 && player.canRespond()) { for (ColoredManaSymbol coloredManaSymbol: manaSymbols) { int number = player.getAmount(0, amountOfManaLeft, new StringBuilder("How many ").append(coloredManaSymbol.name()).append(" mana?").toString(), game); if (number > 0) { diff --git a/Mage/src/mage/abilities/effects/common/CantBeCounteredControlledEffect.java b/Mage/src/mage/abilities/effects/common/CantBeCounteredControlledEffect.java index 4776c73bf84..1d4de4da42d 100644 --- a/Mage/src/mage/abilities/effects/common/CantBeCounteredControlledEffect.java +++ b/Mage/src/mage/abilities/effects/common/CantBeCounteredControlledEffect.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common; import mage.MageObject; @@ -89,7 +88,7 @@ public class CantBeCounteredControlledEffect extends ContinuousRuleModifyingEffe public boolean applies(GameEvent event, Ability source, Game game) { Spell spell = game.getStack().getSpell(event.getTargetId()); if (spell != null && spell.getControllerId().equals(source.getControllerId()) - && filterTarget.match(spell, source.getControllerId(), game)) { + && filterTarget.match(spell, source.getSourceId(), source.getControllerId(), game)) { if (filterSource == null) { return true; } else { diff --git a/Mage/src/mage/abilities/effects/common/CantBeTargetedAllEffect.java b/Mage/src/mage/abilities/effects/common/CantBeTargetedAllEffect.java index 8fd76143d28..6e4322ca0cb 100644 --- a/Mage/src/mage/abilities/effects/common/CantBeTargetedAllEffect.java +++ b/Mage/src/mage/abilities/effects/common/CantBeTargetedAllEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import mage.abilities.Ability; @@ -60,7 +59,6 @@ public class CantBeTargetedAllEffect extends ContinuousRuleModifyingEffectImpl { setText(); } - public CantBeTargetedAllEffect(final CantBeTargetedAllEffect effect) { super(effect); if (effect.filterTarget != null) { @@ -92,10 +90,9 @@ public class CantBeTargetedAllEffect extends ContinuousRuleModifyingEffectImpl { if (permanent != null && filterTarget.match(permanent, source.getSourceId(), source.getControllerId(), game)) { if (filterSource == null) { return true; - } - else { + } else { StackObject sourceObject = game.getStack().getStackObject(event.getSourceId()); - if (sourceObject != null && filterSource.match(sourceObject, sourceObject.getSourceId(), game)) { + if (sourceObject != null && filterSource.match(sourceObject, source.getSourceId(), sourceObject.getControllerId(), game)) { return true; } } @@ -108,8 +105,7 @@ public class CantBeTargetedAllEffect extends ContinuousRuleModifyingEffectImpl { sb.append(filterTarget.getMessage()).append(" can't be the targets of "); if (filterSource != null) { sb.append(filterSource.getMessage()); - } - else { + } else { sb.append("spells"); } if (!duration.toString().isEmpty()) { diff --git a/Mage/src/mage/abilities/effects/common/CantBeTargetedAttachedEffect.java b/Mage/src/mage/abilities/effects/common/CantBeTargetedAttachedEffect.java index bf055b18060..132375bef28 100644 --- a/Mage/src/mage/abilities/effects/common/CantBeTargetedAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/CantBeTargetedAttachedEffect.java @@ -27,39 +27,43 @@ */ package mage.abilities.effects.common; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.constants.AttachmentType; import mage.constants.Duration; import mage.constants.Outcome; -import mage.filter.FilterStackObject; +import mage.constants.TargetController; +import mage.filter.FilterObject; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.game.permanent.Permanent; -import mage.game.stack.StackObject; +import mage.game.stack.StackAbility; /** * * @author LevelX2 */ - public class CantBeTargetedAttachedEffect extends ContinuousRuleModifyingEffectImpl { - private final FilterStackObject filterSource; + private final FilterObject filterSource; private final AttachmentType attachmentType; - - public CantBeTargetedAttachedEffect(FilterStackObject filterSource, Duration duration, AttachmentType attachmentType) { + private final TargetController targetController; + + public CantBeTargetedAttachedEffect(FilterObject filterSource, Duration duration, AttachmentType attachmentType, TargetController targetController) { super(duration, Outcome.Benefit); this.filterSource = filterSource; this.attachmentType = attachmentType; + this.targetController = targetController; } public CantBeTargetedAttachedEffect(final CantBeTargetedAttachedEffect effect) { super(effect); this.filterSource = effect.filterSource.copy(); this.attachmentType = effect.attachmentType; + this.targetController = effect.targetController; } @Override @@ -81,8 +85,18 @@ public class CantBeTargetedAttachedEffect extends ContinuousRuleModifyingEffectI public boolean applies(GameEvent event, Ability source, Game game) { Permanent attachment = game.getPermanent(source.getSourceId()); if (attachment != null && event.getTargetId().equals(attachment.getAttachedTo())) { - StackObject sourceObject = game.getStack().getStackObject(event.getSourceId()); - if (sourceObject != null && filterSource.match(sourceObject, source.getControllerId(), game)) { + if (targetController.equals(TargetController.OPPONENT) + && !game.getOpponents(source.getControllerId()).contains(event.getPlayerId())) { + return false; + } + MageObject mageObject = game.getObject(event.getSourceId()); + MageObject sourceObject; + if (mageObject instanceof StackAbility) { + sourceObject = ((StackAbility) mageObject).getSourceObject(game); + } else { + sourceObject = mageObject; + } + if (mageObject != null && filterSource.match(sourceObject, game)) { return true; } } @@ -103,13 +117,13 @@ public class CantBeTargetedAttachedEffect extends ContinuousRuleModifyingEffectI sb.append(" can't be the target of "); sb.append(filterSource.getMessage()); if (!duration.toString().isEmpty()) { - sb.append(" "); + sb.append(" "); if (duration.equals(Duration.EndOfTurn)) { sb.append("this turn"); } else { sb.append(duration.toString()); } - } + } return sb.toString(); } diff --git a/Mage/src/mage/abilities/effects/common/CantBeTargetedSourceEffect.java b/Mage/src/mage/abilities/effects/common/CantBeTargetedSourceEffect.java index d49b331c814..2a09645f968 100644 --- a/Mage/src/mage/abilities/effects/common/CantBeTargetedSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/CantBeTargetedSourceEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,22 +20,23 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.constants.Duration; import mage.constants.Outcome; -import mage.filter.FilterStackObject; +import mage.filter.FilterObject; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; +import mage.game.stack.StackAbility; import mage.game.stack.StackObject; /** @@ -44,9 +45,9 @@ import mage.game.stack.StackObject; */ public class CantBeTargetedSourceEffect extends ContinuousRuleModifyingEffectImpl { - private final FilterStackObject filterSource; + private final FilterObject filterSource; - public CantBeTargetedSourceEffect(FilterStackObject filterSource, Duration duration) { + public CantBeTargetedSourceEffect(FilterObject filterSource, Duration duration) { super(duration, Outcome.Benefit); this.filterSource = filterSource; setText(); @@ -66,7 +67,7 @@ public class CantBeTargetedSourceEffect extends ContinuousRuleModifyingEffectImp public boolean apply(Game game, Ability source) { return true; } - + @Override public boolean checksEventType(GameEvent event, Game game) { return event.getType() == EventType.TARGET; @@ -75,8 +76,14 @@ public class CantBeTargetedSourceEffect extends ContinuousRuleModifyingEffectImp @Override public boolean applies(GameEvent event, Ability source, Game game) { if (event.getTargetId().equals(source.getSourceId())) { - StackObject sourceObject = game.getStack().getStackObject(event.getSourceId()); - if (sourceObject != null && filterSource.match(sourceObject, source.getControllerId(), game)) { + StackObject stackObject = game.getStack().getStackObject(event.getSourceId()); + MageObject sourceObject; + if (stackObject instanceof StackAbility) { + sourceObject = ((StackAbility) stackObject).getSourceObject(game); + } else { + sourceObject = stackObject; + } + if (sourceObject != null && filterSource.match(sourceObject, game)) { return true; } } diff --git a/Mage/src/mage/abilities/effects/common/CantBeTargetedTargetEffect.java b/Mage/src/mage/abilities/effects/common/CantBeTargetedTargetEffect.java index 644b78b6459..387a5e03bfc 100644 --- a/Mage/src/mage/abilities/effects/common/CantBeTargetedTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/CantBeTargetedTargetEffect.java @@ -27,34 +27,43 @@ */ package mage.abilities.effects.common; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.ContinuousRuleModifyingEffectImpl; import mage.constants.Duration; import mage.constants.Outcome; -import mage.filter.FilterStackObject; +import mage.constants.TargetController; +import mage.filter.FilterObject; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; +import mage.game.stack.StackAbility; import mage.game.stack.StackObject; /** * * @author LevelX2 */ - public class CantBeTargetedTargetEffect extends ContinuousRuleModifyingEffectImpl { - private final FilterStackObject filterSource; + private final FilterObject filterSource; + private final TargetController targetController; - public CantBeTargetedTargetEffect(FilterStackObject filterSource, Duration duration) { + public CantBeTargetedTargetEffect(FilterObject filterSource, Duration duration) { + this(filterSource, duration, TargetController.ANY); + } + + public CantBeTargetedTargetEffect(FilterObject filterSource, Duration duration, TargetController targetController) { super(duration, Outcome.Benefit, false, false); + this.targetController = targetController; this.filterSource = filterSource; } public CantBeTargetedTargetEffect(final CantBeTargetedTargetEffect effect) { super(effect); this.filterSource = effect.filterSource.copy(); + this.targetController = effect.targetController; } @Override @@ -75,8 +84,18 @@ public class CantBeTargetedTargetEffect extends ContinuousRuleModifyingEffectImp @Override public boolean applies(GameEvent event, Ability source, Game game) { if (getTargetPointer().getTargets(game, source).contains(event.getTargetId())) { - StackObject sourceObject = game.getStack().getStackObject(event.getSourceId()); - if (sourceObject != null && filterSource.match(sourceObject, source.getControllerId(), game)) { + if (targetController.equals(TargetController.OPPONENT) + && !game.getOpponents(source.getControllerId()).contains(event.getPlayerId())) { + return false; + } + StackObject stackObject = game.getStack().getStackObject(event.getSourceId()); + MageObject sourceObject; + if (stackObject instanceof StackAbility) { + sourceObject = ((StackAbility) stackObject).getSourceObject(game); + } else { + sourceObject = stackObject; + } + if (sourceObject != null && filterSource.match(sourceObject, game)) { return true; } } @@ -95,13 +114,13 @@ public class CantBeTargetedTargetEffect extends ContinuousRuleModifyingEffectImp sb.append(" can't be the target of "); sb.append(filterSource.getMessage()); if (!duration.toString().isEmpty()) { - sb.append(" "); + sb.append(" "); if (duration.equals(Duration.EndOfTurn)) { sb.append("this turn"); } else { sb.append(duration.toString()); } - } + } return sb.toString(); } diff --git a/Mage/src/mage/abilities/effects/common/ChooseColorEffect.java b/Mage/src/mage/abilities/effects/common/ChooseColorEffect.java index 76c84fba229..8f22a961ad7 100644 --- a/Mage/src/mage/abilities/effects/common/ChooseColorEffect.java +++ b/Mage/src/mage/abilities/effects/common/ChooseColorEffect.java @@ -60,7 +60,7 @@ public class ChooseColorEffect extends OneShotEffect { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(outcome, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage/src/mage/abilities/effects/common/ChooseCreatureTypeEffect.java b/Mage/src/mage/abilities/effects/common/ChooseCreatureTypeEffect.java index b48288ca75e..2ebd99cc9d2 100644 --- a/Mage/src/mage/abilities/effects/common/ChooseCreatureTypeEffect.java +++ b/Mage/src/mage/abilities/effects/common/ChooseCreatureTypeEffect.java @@ -63,12 +63,13 @@ public class ChooseCreatureTypeEffect extends OneShotEffect { typeChoice.setMessage("Choose creature type"); typeChoice.setChoices(CardRepository.instance.getCreatureTypes()); while (!controller.choose(outcome, typeChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } - if (!game.isSimulation()) + if (!game.isSimulation()) { game.informPlayers(permanent.getName() + ": " + controller.getLogName() + " has chosen " + typeChoice.getChoice()); + } game.getState().setValue(permanent.getId() + "_type", typeChoice.getChoice()); permanent.addInfo("chosen type", CardUtil.addToolTipMarkTags("Chosen type: " + typeChoice.getChoice()), game); } diff --git a/Mage/src/mage/abilities/effects/common/ChooseLandTypeEffect.java b/Mage/src/mage/abilities/effects/common/ChooseLandTypeEffect.java new file mode 100644 index 00000000000..0480effa493 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/ChooseLandTypeEffect.java @@ -0,0 +1,61 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.repository.CardRepository; +import mage.choices.Choice; +import mage.choices.ChoiceImpl; +import mage.constants.Outcome; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.util.CardUtil; + +/** + * + * @author fireshoes + */ +public class ChooseLandTypeEffect extends OneShotEffect { + + public ChooseLandTypeEffect(Outcome outcome) { + super(outcome); + staticText = "choose a land type"; + } + + public ChooseLandTypeEffect(final ChooseLandTypeEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Permanent permanent = game.getPermanent(source.getSourceId()); + if (controller != null && permanent != null) { + Choice typeChoice = new ChoiceImpl(true); + typeChoice.setMessage("Choose land type"); + typeChoice.setChoices(CardRepository.instance.getLandTypes()); + while (!controller.choose(outcome, typeChoice, game)) { + if (!controller.canRespond()) { + return false; + } + } + if (!game.isSimulation()) { + game.informPlayers(permanent.getName() + ": " + controller.getLogName() + " has chosen " + typeChoice.getChoice()); + } + game.getState().setValue(permanent.getId() + "_type", typeChoice.getChoice()); + permanent.addInfo("chosen type", CardUtil.addToolTipMarkTags("Chosen type: " + typeChoice.getChoice()), game); + } + return false; + } + + @Override + public ChooseLandTypeEffect copy() { + return new ChooseLandTypeEffect(this); + } + +} diff --git a/Mage/src/mage/abilities/effects/common/ChooseModeEffect.java b/Mage/src/mage/abilities/effects/common/ChooseModeEffect.java index 83fcbb87039..796f3e7fce7 100644 --- a/Mage/src/mage/abilities/effects/common/ChooseModeEffect.java +++ b/Mage/src/mage/abilities/effects/common/ChooseModeEffect.java @@ -74,7 +74,7 @@ public class ChooseModeEffect extends OneShotEffect { choice.setMessage(choiceMessage); choice.getChoices().addAll(modes); while (!choice.isChosen()) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } controller.choose(Outcome.Neutral, choice, game); diff --git a/Mage/src/mage/abilities/effects/common/ClashWinReturnToHandSpellEffect.java b/Mage/src/mage/abilities/effects/common/ClashWinReturnToHandSpellEffect.java index 98bc04994d1..0ee9f0ac298 100644 --- a/Mage/src/mage/abilities/effects/common/ClashWinReturnToHandSpellEffect.java +++ b/Mage/src/mage/abilities/effects/common/ClashWinReturnToHandSpellEffect.java @@ -60,7 +60,7 @@ public class ClashWinReturnToHandSpellEffect extends OneShotEffect implements Ma if (ClashEffect.getInstance().apply(game, source)) { Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard(); if (spellCard != null) { - controller.moveCardToHandWithInfo(spellCard, source.getSourceId(), game, Zone.STACK); + controller.moveCards(spellCard, null, Zone.HAND, source, game); } } return true; diff --git a/Mage/src/mage/abilities/effects/common/CreateTokenEffect.java b/Mage/src/mage/abilities/effects/common/CreateTokenEffect.java index ee32ab0e86e..00c9dbd3a35 100644 --- a/Mage/src/mage/abilities/effects/common/CreateTokenEffect.java +++ b/Mage/src/mage/abilities/effects/common/CreateTokenEffect.java @@ -1,39 +1,40 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common; import java.util.ArrayList; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; import mage.constants.Outcome; import mage.game.Game; import mage.game.permanent.token.Token; @@ -51,6 +52,7 @@ public class CreateTokenEffect extends OneShotEffect { private boolean attacking; private UUID lastAddedTokenId; private ArrayList lastAddedTokenIds = new ArrayList<>(); + private boolean expansionSetCodeChecked; public CreateTokenEffect(Token token) { this(token, new StaticValue(1)); @@ -63,7 +65,7 @@ public class CreateTokenEffect extends OneShotEffect { public CreateTokenEffect(Token token, DynamicValue amount) { this(token, amount, false, false); } - + public CreateTokenEffect(Token token, int amount, boolean tapped, boolean attacking) { this(token, new StaticValue(amount), tapped, attacking); } @@ -74,6 +76,7 @@ public class CreateTokenEffect extends OneShotEffect { this.amount = amount.copy(); this.tapped = tapped; this.attacking = attacking; + this.expansionSetCodeChecked = false; setText(); } @@ -85,6 +88,7 @@ public class CreateTokenEffect extends OneShotEffect { this.attacking = effect.attacking; this.lastAddedTokenId = effect.lastAddedTokenId; this.lastAddedTokenIds.addAll(effect.lastAddedTokenIds); + this.expansionSetCodeChecked = effect.expansionSetCodeChecked; } @Override @@ -94,6 +98,9 @@ public class CreateTokenEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { + if (!expansionSetCodeChecked) { + updateExpansionSetCode(game, source); + } int value = amount.calculate(game, source, this); token.putOntoBattlefield(value, game, source.getSourceId(), source.getControllerId(), tapped, attacking); this.lastAddedTokenId = token.getLastAddedToken(); @@ -101,10 +108,18 @@ public class CreateTokenEffect extends OneShotEffect { return true; } + private void updateExpansionSetCode(Game game, Ability source) { + MageObject sourceObject = source.getSourceObject(game); + if (sourceObject instanceof Card) { + token.setExpansionSetCodeForImage(((Card) sourceObject).getExpansionSetCode()); + } + expansionSetCodeChecked = true; + } + public UUID getLastAddedTokenId() { return lastAddedTokenId; } - + public ArrayList getLastAddedTokenIds() { return lastAddedTokenIds; } diff --git a/Mage/src/mage/abilities/effects/common/CreateTokenTargetEffect.java b/Mage/src/mage/abilities/effects/common/CreateTokenTargetEffect.java index 9c0e72eef9e..91fcdb1c40d 100644 --- a/Mage/src/mage/abilities/effects/common/CreateTokenTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/CreateTokenTargetEffect.java @@ -1,23 +1,20 @@ package mage.abilities.effects.common; -import java.util.Locale; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.OneShotEffect; import mage.constants.Outcome; -import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.token.Token; -import mage.players.Player; import mage.util.CardUtil; /** * @author Loki */ - public class CreateTokenTargetEffect extends OneShotEffect { + private Token token; private DynamicValue amount; private boolean tapped; @@ -59,14 +56,10 @@ public class CreateTokenTargetEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { int value = amount.calculate(game, source, this); - Player controller = game.getPlayer(source.getControllerId()); - if (controller != null) { - if (value < 1) { - return true; - } + if (value > 0) { return token.putOntoBattlefield(value, game, source.getSourceId(), targetPointer.getFirst(game, source), tapped, attacking); } - return false; + return true; } @Override diff --git a/Mage/src/mage/abilities/effects/common/DamageAttachedControllerEffect.java b/Mage/src/mage/abilities/effects/common/DamageAttachedControllerEffect.java new file mode 100644 index 00000000000..b248481aad9 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/DamageAttachedControllerEffect.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ + +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author LoneFox + */ +public class DamageAttachedControllerEffect extends OneShotEffect { + + protected int amount; + + public DamageAttachedControllerEffect(int amount) { + super(Outcome.Damage); + this.amount = amount; + } + + public DamageAttachedControllerEffect(final DamageAttachedControllerEffect effect) { + super(effect); + this.amount = effect.amount; + } + + @Override + public DamageAttachedControllerEffect copy() { + return new DamageAttachedControllerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent enchantment = game.getPermanentOrLKIBattlefield(source.getSourceId()); + if(enchantment == null) { + return false; + } + Permanent enchanted = game.getPermanentOrLKIBattlefield(enchantment.getAttachedTo()); + if(enchanted == null) { + return false; + } + Player player = game.getPlayer(enchanted.getControllerId()); + if(player != null) { + player.damage(amount, source.getSourceId(), game, false, true); + return true; + } + return false; + } + + @Override + public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } + return "{this} deals " + amount + " damage to that creature's controller"; + } + +} diff --git a/Mage/src/mage/abilities/effects/common/DamageEachOtherEffect.java b/Mage/src/mage/abilities/effects/common/DamageEachOtherEffect.java new file mode 100644 index 00000000000..4c58bf38f51 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/DamageEachOtherEffect.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author LoneFox + */ +public class DamageEachOtherEffect extends OneShotEffect { + + public DamageEachOtherEffect() { + super(Outcome.Damage); + } + + public DamageEachOtherEffect(final DamageEachOtherEffect effect) { + super(effect); + } + + @Override + public DamageEachOtherEffect copy() { + return new DamageEachOtherEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + boolean sourceOnBattlefield = true; + Permanent targetCreature = game.getPermanent(source.getFirstTarget()); + Permanent sourceCreature = game.getPermanent(source.getSourceId()); + if (sourceCreature == null) { + sourceCreature = (Permanent) game.getLastKnownInformation(source.getSourceId(), Zone.BATTLEFIELD); + sourceOnBattlefield = false; + } + + if (sourceCreature != null && targetCreature != null + && sourceCreature.getCardType().contains(CardType.CREATURE) + && targetCreature.getCardType().contains(CardType.CREATURE)) { + targetCreature.damage(sourceCreature.getPower().getValue(), sourceCreature.getId(), game, false, true); + if (sourceOnBattlefield) { + sourceCreature.damage(targetCreature.getPower().getValue(), targetCreature.getId(), game, false, true); + } + return true; + } + return false; + } + + @Override + public String getText(Mode mode) { + if(staticText != null && !staticText.isEmpty()) { + return staticText; + } + return "{this} deals damage equal to its power to target creature. That creature deals damage equal to its power to {this}"; + } + +} diff --git a/Mage/src/mage/abilities/effects/common/DamageTargetControllerEffect.java b/Mage/src/mage/abilities/effects/common/DamageTargetControllerEffect.java new file mode 100644 index 00000000000..d8d7216746f --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/DamageTargetControllerEffect.java @@ -0,0 +1,103 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.dynamicvalue.DynamicValue; +import mage.abilities.dynamicvalue.common.StaticValue; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; + +/** + * + * @author LoneFox + */ +public class DamageTargetControllerEffect extends OneShotEffect { + + protected DynamicValue amount; + protected boolean preventable; + + public DamageTargetControllerEffect(int amount) { + this(new StaticValue(amount), true); + } + + public DamageTargetControllerEffect(int amount, boolean preventable) { + this(new StaticValue(amount), preventable); + } + + public DamageTargetControllerEffect(DynamicValue amount) { + this(amount, true); + } + + public DamageTargetControllerEffect(DynamicValue amount, boolean preventable) { + super(Outcome.Damage); + this.amount = amount; + this.preventable = preventable; + } + + public DamageTargetControllerEffect(final DamageTargetControllerEffect effect) { + super(effect); + amount = effect.amount.copy(); + preventable = effect.preventable; + } + + @Override + public DamageTargetControllerEffect copy() { + return new DamageTargetControllerEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(getTargetPointer().getFirst(game, source)); + if(permanent != null) { + Player targetController = game.getPlayer(permanent.getControllerId()); + if(targetController != null) { + targetController.damage(amount.calculate(game, source, this), source.getSourceId(), game, false, preventable); + } + return true; + } + return false; + } + + @Override + public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } + String text = "{this} deals " + amount.getMessage() + " damage to target " + + mode.getTargets().get(0).getTargetName() + "'s controller"; + if(!preventable) { + text += ". The damage can't be prevented"; + } + return text; + } +} diff --git a/Mage/src/mage/abilities/effects/common/DestroyTargetEffect.java b/Mage/src/mage/abilities/effects/common/DestroyTargetEffect.java index c001d57ae29..9339079cb1f 100644 --- a/Mage/src/mage/abilities/effects/common/DestroyTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/DestroyTargetEffect.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common; import java.util.UUID; @@ -37,6 +36,7 @@ import mage.game.Game; import mage.game.permanent.Permanent; import mage.target.Target; import mage.target.targetpointer.FirstTargetPointer; +import mage.target.targetpointer.SecondTargetPointer; import mage.util.CardUtil; /** @@ -84,8 +84,7 @@ public class DestroyTargetEffect extends OneShotEffect { } } } - } - else if (targetPointer.getTargets(game, source).size() > 0) { + } else if (targetPointer.getTargets(game, source).size() > 0) { for (UUID permanentId : targetPointer.getTargets(game, source)) { Permanent permanent = game.getPermanent(permanentId); if (permanent != null) { @@ -105,15 +104,23 @@ public class DestroyTargetEffect extends OneShotEffect { StringBuilder sb = new StringBuilder(); if (mode.getTargets().size() == 0) { sb.append("destroy that creature"); //TODO add possibility to specify text with targetPointer usage - } else if (mode.getTargets().get(0).getNumberOfTargets() == 1) { - String targetName = mode.getTargets().get(0).getTargetName(); - sb.append("destroy "); - if (!targetName.startsWith("another")) { - sb.append("target "); - } - sb.append(targetName); } else { - sb.append("Destroy ").append(CardUtil.numberToText(mode.getTargets().get(0).getNumberOfTargets())).append(" target ").append(mode.getTargets().get(0).getTargetName()); + Target target; + if (targetPointer instanceof SecondTargetPointer && mode.getTargets().size() > 1) { + target = mode.getTargets().get(1); + } else { + target = mode.getTargets().get(0); + } + if (target.getNumberOfTargets() == 1) { + String targetName = target.getTargetName(); + sb.append("destroy "); + if (!targetName.startsWith("another")) { + sb.append("target "); + } + sb.append(targetName); + } else { + sb.append("Destroy ").append(CardUtil.numberToText(target.getNumberOfTargets())).append(" target ").append(target.getTargetName()); + } } if (noRegen) { sb.append(". It can't be regenerated"); diff --git a/Mage/src/mage/abilities/effects/common/DiscardOntoBattlefieldEffect.java b/Mage/src/mage/abilities/effects/common/DiscardOntoBattlefieldEffect.java new file mode 100644 index 00000000000..137b33c5145 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/DiscardOntoBattlefieldEffect.java @@ -0,0 +1,96 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.effects.ReplacementEffectImpl; +import mage.cards.Card; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent.EventType; +import mage.game.events.GameEvent; +import mage.game.events.ZoneChangeEvent; +import mage.game.stack.StackObject; +import mage.players.Player; + +/** + * + * @author LoneFox + */ +public class DiscardOntoBattlefieldEffect extends ReplacementEffectImpl { + + public DiscardOntoBattlefieldEffect() { + super(Duration.EndOfGame, Outcome.PutCardInPlay); + staticText = "If a spell or ability an opponent controls causes you to discard {this}, put it onto the battlefield instead of putting it into your graveyard"; + } + + public DiscardOntoBattlefieldEffect(final DiscardOntoBattlefieldEffect effect) { + super(effect); + } + + @Override + public DiscardOntoBattlefieldEffect copy() { + return new DiscardOntoBattlefieldEffect(this); + } + + @Override + public boolean checksEventType(GameEvent event, Game game) { + return event.getType() == EventType.ZONE_CHANGE; + } + + @Override + public boolean applies(GameEvent event, Ability source, Game game) { + if (event.getTargetId().equals(source.getSourceId())) { + ZoneChangeEvent zcEvent = (ZoneChangeEvent) event; + if (zcEvent.getFromZone() == Zone.HAND && zcEvent.getToZone() == Zone.GRAVEYARD) { + StackObject spell = game.getStack().getStackObject(event.getSourceId()); + if (spell != null && game.getOpponents(source.getControllerId()).contains(spell.getControllerId())) { + return true; + } + } + } + return false; + } + + @Override + public boolean replaceEvent(GameEvent event, Ability source, Game game) { + Card card = game.getCard(source.getSourceId()); + if (card != null) { + Player owner = game.getPlayer(card.getOwnerId()); + if (owner != null) { + if (owner.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId())) { + return true; + } + } + } + return false; + } + +} diff --git a/Mage/src/mage/abilities/effects/common/DrawDiscardControllerEffect.java b/Mage/src/mage/abilities/effects/common/DrawDiscardControllerEffect.java index 20f1d46d6ed..811addcd588 100644 --- a/Mage/src/mage/abilities/effects/common/DrawDiscardControllerEffect.java +++ b/Mage/src/mage/abilities/effects/common/DrawDiscardControllerEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2011 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import mage.abilities.Ability; @@ -46,9 +45,9 @@ public class DrawDiscardControllerEffect extends OneShotEffect { private boolean optional; public DrawDiscardControllerEffect() { - this(1,1); + this(1, 1); } - + public DrawDiscardControllerEffect(int cardsToDraw, int cardsToDiscard) { this(cardsToDraw, cardsToDiscard, false); } @@ -59,11 +58,11 @@ public class DrawDiscardControllerEffect extends OneShotEffect { this.cardsToDiscard = cardsToDiscard; this.optional = optional; staticText = new StringBuilder("Draw ") - .append(cardsToDraw == 1?"a": CardUtil.numberToText(cardsToDraw)) - .append(" card").append(cardsToDraw == 1?" ": "s") + .append(cardsToDraw == 1 ? "a" : CardUtil.numberToText(cardsToDraw)) + .append(" card").append(cardsToDraw == 1 ? "" : "s") .append(", then discard ") - .append(cardsToDiscard == 1?"a": CardUtil.numberToText(cardsToDiscard)) - .append(" card").append(cardsToDiscard == 1?"": "s").toString(); + .append(cardsToDiscard == 1 ? "a" : CardUtil.numberToText(cardsToDiscard)) + .append(" card").append(cardsToDiscard == 1 ? "" : "s").toString(); } public DrawDiscardControllerEffect(final DrawDiscardControllerEffect effect) { diff --git a/Mage/src/mage/abilities/effects/common/DynamicManaEffect.java b/Mage/src/mage/abilities/effects/common/DynamicManaEffect.java index 7747f360756..d6f5cf01087 100644 --- a/Mage/src/mage/abilities/effects/common/DynamicManaEffect.java +++ b/Mage/src/mage/abilities/effects/common/DynamicManaEffect.java @@ -44,32 +44,39 @@ public class DynamicManaEffect extends BasicManaEffect { private final Mana computedMana; private final DynamicValue amount; + private final DynamicValue netAmount; private String text = null; private boolean oneChoice; public DynamicManaEffect(Mana mana, DynamicValue amount) { - super(mana); - this.amount = amount; - computedMana = new Mana(); + this(mana, amount, null); } public DynamicManaEffect(Mana mana, DynamicValue amount, String text) { this(mana, amount, text, false); } + public DynamicManaEffect(Mana mana, DynamicValue amount, String text, boolean oneChoice) { + this(mana, amount, text, oneChoice, null); + } + /** * * @param mana * @param amount * @param text - * @param oneChoice is all mana from the same colour or if false the player can choose different colours + * @param oneChoice is all mana from the same colour or if false the player + * can choose different colours + * @param netAmount a dynamic value that calculates the possible available + * mana (e.g. if you have to pay by removing counters from source) */ - public DynamicManaEffect(Mana mana, DynamicValue amount, String text, boolean oneChoice) { + public DynamicManaEffect(Mana mana, DynamicValue amount, String text, boolean oneChoice, DynamicValue netAmount) { super(mana); this.amount = amount; computedMana = new Mana(); this.text = text; this.oneChoice = oneChoice; + this.netAmount = netAmount; } public DynamicManaEffect(final DynamicManaEffect effect) { @@ -78,6 +85,11 @@ public class DynamicManaEffect extends BasicManaEffect { this.amount = effect.amount.copy(); this.text = effect.text; this.oneChoice = effect.oneChoice; + if (effect.netAmount != null) { + this.netAmount = effect.netAmount.copy(); + } else { + this.netAmount = null; + } } @Override @@ -106,9 +118,16 @@ public class DynamicManaEffect extends BasicManaEffect { return null; } - public Mana computeMana(boolean netMana ,Game game, Ability source){ + public Mana computeMana(boolean netMana, Game game, Ability source) { this.computedMana.clear(); - int count = amount.calculate(game, source, this); + int count; + if (netMana && netAmount != null) { + // calculate the maximum available mana + count = netAmount.calculate(game, source, this); + } else { + count = amount.calculate(game, source, this); + } + if (mana.getBlack() > 0) { computedMana.setBlack(count); } else if (mana.getBlue() > 0) { @@ -126,10 +145,10 @@ public class DynamicManaEffect extends BasicManaEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { ChoiceColor choiceColor = new ChoiceColor(); - for(int i = 0; i < count; i++){ + for (int i = 0; i < count; i++) { if (!choiceColor.isChosen()) { while (!controller.choose(Outcome.Benefit, choiceColor, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return computedMana; } } @@ -150,7 +169,7 @@ public class DynamicManaEffect extends BasicManaEffect { } } } - } + } } else { computedMana.setColorless(count); } diff --git a/Mage/src/mage/abilities/effects/common/EnvoyEffect.java b/Mage/src/mage/abilities/effects/common/EnvoyEffect.java new file mode 100644 index 00000000000..d9e584f607e --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/EnvoyEffect.java @@ -0,0 +1,101 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common; + +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.game.Game; +import mage.players.Player; +import mage.util.CardUtil; + +/** + * + * @author LoneFox + */ +public class EnvoyEffect extends OneShotEffect { + + private final FilterCard filter; + private final int numCards; + + public EnvoyEffect(FilterCard filter, int numCards) { + super(Outcome.DrawCard); + this.filter = filter; + this.numCards = numCards; + } + + public EnvoyEffect(final EnvoyEffect effect) { + super(effect); + this.filter = effect.filter.copy(); + this.numCards = effect.numCards; + } + + @Override + public EnvoyEffect copy() { + return new EnvoyEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { + return false; + } + Cards cards = new CardsImpl(); + cards.addAll(controller.getLibrary().getTopCards(game, numCards)); + controller.revealCards(sourceObject.getIdName(), cards, game); + Cards cardsToHand = new CardsImpl(); + for (Card card : cards.getCards(game)) { + if (filter.match(card, game)) { + cardsToHand.add(card); + } + } + cards.removeAll(cardsToHand); + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); + controller.putCardsOnBottomOfLibrary(cards, game, source, true); + return true; + } + + @Override + public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } + + return "Reveal the top " + CardUtil.numberToText(numCards) + " cards of your library. Put all " + + filter.getMessage() + " revealed this way into your hand and the rest on the bottom of your library in any order."; + } +} diff --git a/Mage/src/mage/abilities/effects/common/ExileAndReturnTransformedSourceEffect.java b/Mage/src/mage/abilities/effects/common/ExileAndReturnTransformedSourceEffect.java index 6b57e657d3c..6e99909a49e 100644 --- a/Mage/src/mage/abilities/effects/common/ExileAndReturnTransformedSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/ExileAndReturnTransformedSourceEffect.java @@ -60,16 +60,19 @@ public class ExileAndReturnTransformedSourceEffect extends OneShotEffect { // Creature has to be on the battlefield to get exiled and be able to return transformed Permanent sourceObject = game.getPermanent(source.getSourceId()); Player controller = game.getPlayer(source.getControllerId()); - if (sourceObject != null && controller != null) { + if (sourceObject != null && controller != null && sourceObject.getZoneChangeCounter(game) == source.getSourceObjectZoneChangeCounter()) { Card card = (Card) sourceObject; if (controller.moveCards(card, Zone.BATTLEFIELD, Zone.EXILED, source, game)) { - game.getState().setValue(TransformAbility.VALUE_KEY_ENTER_TRANSFORMED + source.getSourceId(), Boolean.TRUE); - controller.putOntoBattlefieldWithInfo(card, game, Zone.EXILED, source.getSourceId()); - if (additionalEffect != null) { - if (additionalEffect instanceof ContinuousEffect) { - game.addEffect((ContinuousEffect) additionalEffect, source); - } else { - additionalEffect.apply(game, source); + Player owner = game.getPlayer(card.getOwnerId()); + if (owner != null) { + game.getState().setValue(TransformAbility.VALUE_KEY_ENTER_TRANSFORMED + source.getSourceId(), Boolean.TRUE); + owner.putOntoBattlefieldWithInfo(card, game, Zone.EXILED, source.getSourceId()); + if (additionalEffect != null) { + if (additionalEffect instanceof ContinuousEffect) { + game.addEffect((ContinuousEffect) additionalEffect, source); + } else { + additionalEffect.apply(game, source); + } } } } diff --git a/Mage/src/mage/abilities/effects/common/ExileReturnToBattlefieldOwnerNextEndStepEffect.java b/Mage/src/mage/abilities/effects/common/ExileReturnToBattlefieldOwnerNextEndStepEffect.java index a49b20fd835..e608d796bf8 100644 --- a/Mage/src/mage/abilities/effects/common/ExileReturnToBattlefieldOwnerNextEndStepEffect.java +++ b/Mage/src/mage/abilities/effects/common/ExileReturnToBattlefieldOwnerNextEndStepEffect.java @@ -43,14 +43,27 @@ import mage.players.Player; public class ExileReturnToBattlefieldOwnerNextEndStepEffect extends OneShotEffect { private static final String effectText = "exile {this}. Return it to the battlefield under its owner's control at the beginning of the next end step"; + private boolean returnAlways; public ExileReturnToBattlefieldOwnerNextEndStepEffect() { + this(false); + } + + /** + * + * @param returnAlways return the permanent also if it does not go to exile + * but is moved to another zone (e.g. command zone by commander replacement + * effect) + */ + public ExileReturnToBattlefieldOwnerNextEndStepEffect(boolean returnAlways) { super(Outcome.Benefit); staticText = effectText; + this.returnAlways = returnAlways; } public ExileReturnToBattlefieldOwnerNextEndStepEffect(ExileReturnToBattlefieldOwnerNextEndStepEffect effect) { super(effect); + this.returnAlways = effect.returnAlways; } @Override @@ -60,7 +73,8 @@ public class ExileReturnToBattlefieldOwnerNextEndStepEffect extends OneShotEffec Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { int zcc = game.getState().getZoneChangeCounter(permanent.getId()); - if (controller.moveCardToExileWithInfo(permanent, source.getSourceId(), permanent.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true)) { + boolean exiled = controller.moveCardToExileWithInfo(permanent, source.getSourceId(), permanent.getIdName(), source.getSourceId(), game, Zone.BATTLEFIELD, true); + if (exiled || (returnAlways && (zcc == game.getState().getZoneChangeCounter(permanent.getId()) - 1))) { //create delayed triggered ability and return it from every public zone he was next moved to AtTheBeginOfNextEndStepDelayedTriggeredAbility delayedAbility = new AtTheBeginOfNextEndStepDelayedTriggeredAbility( new ReturnToBattlefieldUnderOwnerControlSourceEffect(false, zcc + 1)); diff --git a/Mage/src/mage/abilities/effects/common/LoseLifeTargetEffect.java b/Mage/src/mage/abilities/effects/common/LoseLifeTargetEffect.java index b057048f2d9..501f3850958 100644 --- a/Mage/src/mage/abilities/effects/common/LoseLifeTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/LoseLifeTargetEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import mage.abilities.Ability; @@ -103,5 +102,4 @@ public class LoseLifeTargetEffect extends OneShotEffect { return sb.toString(); } - } diff --git a/Mage/src/mage/abilities/effects/common/MayTapOrUntapTargetEffect.java b/Mage/src/mage/abilities/effects/common/MayTapOrUntapTargetEffect.java index 9e2c9523a66..f107f2e0a1c 100644 --- a/Mage/src/mage/abilities/effects/common/MayTapOrUntapTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/MayTapOrUntapTargetEffect.java @@ -12,6 +12,7 @@ import mage.players.Player; * @author Loki */ public class MayTapOrUntapTargetEffect extends OneShotEffect { + public MayTapOrUntapTargetEffect() { super(Outcome.Benefit); } @@ -47,9 +48,9 @@ public class MayTapOrUntapTargetEffect extends OneShotEffect { @Override public String getText(Mode mode) { if (mode.getTargets().isEmpty()) { - return "You may tap or untap it"; + return "you may tap or untap it"; } else { - return "You may tap or untap target " + mode.getTargets().get(0).getTargetName(); + return "you may tap or untap target " + mode.getTargets().get(0).getTargetName(); } } } diff --git a/Mage/src/mage/abilities/effects/common/NameACardEffect.java b/Mage/src/mage/abilities/effects/common/NameACardEffect.java index 519969bd13c..0123f9fd6f6 100644 --- a/Mage/src/mage/abilities/effects/common/NameACardEffect.java +++ b/Mage/src/mage/abilities/effects/common/NameACardEffect.java @@ -94,7 +94,7 @@ public class NameACardEffect extends OneShotEffect { } cardChoice.clearChoice(); while (!controller.choose(Outcome.Detriment, cardChoice, game)) { - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage/src/mage/abilities/effects/common/PhaseOutSourceEffect.java b/Mage/src/mage/abilities/effects/common/PhaseOutSourceEffect.java new file mode 100644 index 00000000000..1df8ff9ff37 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/PhaseOutSourceEffect.java @@ -0,0 +1,44 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.effects.common; + +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author fireshoes + */ +public class PhaseOutSourceEffect extends OneShotEffect { + + public PhaseOutSourceEffect() { + super(Outcome.Detriment); + this.staticText = "{this} phases out"; + } + + public PhaseOutSourceEffect(final PhaseOutSourceEffect effect) { + super(effect); + } + + @Override + public PhaseOutSourceEffect copy() { + return new PhaseOutSourceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + MageObject sourceObject = source.getSourceObjectIfItStillExists(game); + if (sourceObject instanceof Permanent) { + Permanent permanent = (Permanent) sourceObject; + return permanent.phaseOut(game); + } + return false; + } +} diff --git a/Mage/src/mage/abilities/effects/common/PhaseOutTargetEffect.java b/Mage/src/mage/abilities/effects/common/PhaseOutTargetEffect.java new file mode 100644 index 00000000000..68383139cf9 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/PhaseOutTargetEffect.java @@ -0,0 +1,68 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.effects.common; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.Target; +import mage.util.CardUtil; + +/** + * + * @author fireshoes + */ +public class PhaseOutTargetEffect extends OneShotEffect { + + public PhaseOutTargetEffect() { + super(Outcome.Detriment); + } + + public PhaseOutTargetEffect(final PhaseOutTargetEffect effect) { + super(effect); + } + + @Override + public PhaseOutTargetEffect copy() { + return new PhaseOutTargetEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + for (UUID target : targetPointer.getTargets(game, source)) { + Permanent permanent = game.getPermanent(target); + if (permanent != null) { + permanent.phaseOut(game); + } + } + return true; + } + + @Override + public String getText(Mode mode) { + if (staticText.length() > 0) { + return staticText + " phases out"; + } + + Target target = mode.getTargets().get(0); + if (target.getMaxNumberOfTargets() > 1) { + if (target.getMaxNumberOfTargets() == target.getNumberOfTargets()) { + return CardUtil.numberToText(target.getNumberOfTargets()) + " target " + target.getTargetName() + "s phase out"; + } else { + return "up to " + CardUtil.numberToText(target.getMaxNumberOfTargets()) + " target " + target.getTargetName() + "s phase out"; + } + } else if (target.getMaxNumberOfTargets() == 0){ + return "X target " + mode.getTargets().get(0).getTargetName() + " phase out"; + } else { + return "target " + mode.getTargets().get(0).getTargetName() + " phase out"; + } + } + +} \ No newline at end of file diff --git a/Mage/src/mage/abilities/effects/common/PutCreatureOnBattlefieldEffect.java b/Mage/src/mage/abilities/effects/common/PutCreatureOnBattlefieldEffect.java deleted file mode 100644 index 822c21199bb..00000000000 --- a/Mage/src/mage/abilities/effects/common/PutCreatureOnBattlefieldEffect.java +++ /dev/null @@ -1,67 +0,0 @@ -package mage.abilities.effects.common; - -import mage.abilities.Ability; -import mage.abilities.Mode; -import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; -import mage.constants.Outcome; -import mage.constants.Zone; -import mage.filter.common.FilterCreatureCard; -import mage.game.Game; -import mage.players.Player; -import mage.target.common.TargetCardInHand; - -/** - * @author magenoxx_at_gmail.com - */ -public class PutCreatureOnBattlefieldEffect extends OneShotEffect { - - private final FilterCreatureCard filter; - - public PutCreatureOnBattlefieldEffect() { - this(new FilterCreatureCard("a creature card")); - } - - public PutCreatureOnBattlefieldEffect(FilterCreatureCard filter) { - super(Outcome.PutCreatureInPlay); - this.filter = filter; - } - - public PutCreatureOnBattlefieldEffect(final PutCreatureOnBattlefieldEffect effect) { - super(effect); - this.filter = effect.filter.copy(); - } - - @Override - public PutCreatureOnBattlefieldEffect copy() { - return new PutCreatureOnBattlefieldEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - String choiceText = "Put " + filter.getMessage() + " from your hand onto the battlefield?"; - if (player == null || !player.chooseUse(Outcome.PutCreatureInPlay, choiceText, source, game)) { - return false; - } - - TargetCardInHand target = new TargetCardInHand(filter); - if (player.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { - Card card = game.getCard(target.getFirstTarget()); - if (card != null) { - player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); - return true; - } - } - return false; - } - - @Override - public String getText(Mode mode) { - if(this.staticText != null && !this.staticText.isEmpty()) { - return staticText; - } - - return "You may put " + filter.getMessage() + " from your hand onto the battlefield"; - } -} diff --git a/Mage/src/mage/abilities/effects/common/PutPermanentOnBattlefieldEffect.java b/Mage/src/mage/abilities/effects/common/PutPermanentOnBattlefieldEffect.java new file mode 100644 index 00000000000..12a208ab190 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/PutPermanentOnBattlefieldEffect.java @@ -0,0 +1,86 @@ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.common.FilterPermanentCard; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCardInHand; + +/** + * @author magenoxx_at_gmail.com + */ +public class PutPermanentOnBattlefieldEffect extends OneShotEffect { + + private final FilterCard filter; + private final boolean useTargetController; + + public PutPermanentOnBattlefieldEffect() { + this(new FilterPermanentCard("a permanent card"), false); + } + + public PutPermanentOnBattlefieldEffect(FilterCard filter) { + this(filter, false); + } + + public PutPermanentOnBattlefieldEffect(FilterCard filter, boolean useTargetController) { + super(Outcome.PutCardInPlay); + this.filter = filter; + this.useTargetController = useTargetController; + } + + public PutPermanentOnBattlefieldEffect(final PutPermanentOnBattlefieldEffect effect) { + super(effect); + this.filter = effect.filter.copy(); + this.useTargetController = effect.useTargetController; + } + + @Override + public PutPermanentOnBattlefieldEffect copy() { + return new PutPermanentOnBattlefieldEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player player; + if(useTargetController) { + player = game.getPlayer(getTargetPointer().getFirst(game, source)); + } + else { + player = game.getPlayer(source.getControllerId()); + } + String choiceText = "Put " + filter.getMessage() + " from your hand onto the battlefield?"; + if (player == null || !player.chooseUse(Outcome.PutCardInPlay, choiceText, source, game)) { + return false; + } + + TargetCardInHand target = new TargetCardInHand(filter); + if (player.choose(Outcome.PutCreatureInPlay, target, source.getSourceId(), game)) { + Card card = game.getCard(target.getFirstTarget()); + if (card != null) { + player.putOntoBattlefieldWithInfo(card, game, Zone.HAND, source.getSourceId()); + return true; + } + } + return false; + } + + @Override + public String getText(Mode mode) { + if(this.staticText != null && !this.staticText.isEmpty()) { + return staticText; + } + + if(useTargetController) { + return "that player may put " + filter.getMessage() + " from his or her hand onto the battlefield"; + } + else { + return "you may put " + filter.getMessage() + " from your hand onto the battlefield"; + } + } +} diff --git a/Mage/src/mage/abilities/effects/common/RemoveFromCombatTargetEffect.java b/Mage/src/mage/abilities/effects/common/RemoveFromCombatTargetEffect.java index 24eba041040..8c39c947169 100644 --- a/Mage/src/mage/abilities/effects/common/RemoveFromCombatTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/RemoveFromCombatTargetEffect.java @@ -1,37 +1,37 @@ /* -* Copyright 2012 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2012 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common; -import mage.constants.Outcome; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; import mage.game.Game; import mage.game.permanent.Permanent; @@ -51,11 +51,13 @@ public class RemoveFromCombatTargetEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Permanent permanent = game.getPermanent(targetPointer.getFirst(game, source)); - if (permanent != null) { - permanent.removeFromCombat(game); + for (UUID targetId : getTargetPointer().getTargets(game, source)) { + Permanent permanent = game.getPermanent(targetId); + if (permanent != null) { + permanent.removeFromCombat(game); + } } - return false; + return true; } @Override @@ -65,6 +67,9 @@ public class RemoveFromCombatTargetEffect extends OneShotEffect { @Override public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } return "Remove target " + mode.getTargets().get(0).getTargetName() + " from combat"; } diff --git a/Mage/src/mage/abilities/effects/common/ReturnFromGraveyardToHandTargetEffect.java b/Mage/src/mage/abilities/effects/common/ReturnFromGraveyardToHandTargetEffect.java index fda55a0478a..7e086481be5 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnFromGraveyardToHandTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnFromGraveyardToHandTargetEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,19 +20,17 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; -import java.util.UUID; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; +import mage.cards.CardsImpl; import mage.constants.Outcome; import mage.constants.Zone; import mage.game.Game; @@ -61,16 +59,11 @@ public class ReturnFromGraveyardToHandTargetEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - for (UUID cardId: getTargetPointer().getTargets(game, source)) { - Card card = game.getCard(cardId); - if (card != null && game.getState().getZone(cardId).equals(Zone.GRAVEYARD)) { - Player player = game.getPlayer(card.getOwnerId()); - if (player != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); - } - } + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + return controller.moveCards(new CardsImpl(getTargetPointer().getTargets(game, source)), null, Zone.HAND, source, game); } - return true; + return false; } @Override @@ -79,14 +72,14 @@ public class ReturnFromGraveyardToHandTargetEffect extends OneShotEffect { return staticText; } StringBuilder sb = new StringBuilder(); - Target target = mode.getTargets().get(0); + Target target = mode.getTargets().get(0); sb.append("return "); if (target.getMaxNumberOfTargets() > 1) { if (target.getMaxNumberOfTargets() != target.getNumberOfTargets()) { sb.append("up to "); } sb.append(CardUtil.numberToText(target.getMaxNumberOfTargets())).append(" "); - } + } if (!mode.getTargets().get(0).getTargetName().startsWith("another")) { sb.append("target "); } diff --git a/Mage/src/mage/abilities/effects/common/ReturnSourceFromGraveyardToHandEffect.java b/Mage/src/mage/abilities/effects/common/ReturnSourceFromGraveyardToHandEffect.java index 7dccfd5a674..e669693c00a 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnSourceFromGraveyardToHandEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnSourceFromGraveyardToHandEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import mage.abilities.Ability; @@ -61,7 +60,7 @@ public class ReturnSourceFromGraveyardToHandEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); Card card = controller.getGraveyard().get(source.getSourceId(), game); if (card != null) { - return controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + return controller.moveCards(card, null, Zone.HAND, source, game); } return false; } diff --git a/Mage/src/mage/abilities/effects/common/ReturnToHandFromBattlefieldAllEffect.java b/Mage/src/mage/abilities/effects/common/ReturnToHandFromBattlefieldAllEffect.java index aeddab66962..2b0a53aba5f 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnToHandFromBattlefieldAllEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnToHandFromBattlefieldAllEffect.java @@ -25,11 +25,12 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.Outcome; import mage.constants.Zone; import mage.filter.FilterPermanent; @@ -41,12 +42,10 @@ import mage.players.Player; * * @author Plopman */ - - public class ReturnToHandFromBattlefieldAllEffect extends OneShotEffect { private final FilterPermanent filter; - + public ReturnToHandFromBattlefieldAllEffect(FilterPermanent filter) { super(Outcome.ReturnToHand); this.filter = filter; @@ -62,9 +61,11 @@ public class ReturnToHandFromBattlefieldAllEffect extends OneShotEffect { public boolean apply(Game game, Ability source) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { + Cards cardsToHand = new CardsImpl(); for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { - controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + cardsToHand.add(permanent); } + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage/src/mage/abilities/effects/common/ReturnToHandSourceEffect.java b/Mage/src/mage/abilities/effects/common/ReturnToHandSourceEffect.java index 624fcf86de6..10893c286b6 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnToHandSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnToHandSourceEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -45,20 +45,23 @@ import mage.players.Player; public class ReturnToHandSourceEffect extends OneShotEffect { boolean fromBattlefieldOnly; - boolean returnFromNextZone ; - + boolean returnFromNextZone; + public ReturnToHandSourceEffect() { this(false); } - + public ReturnToHandSourceEffect(boolean fromBattlefieldOnly) { this(fromBattlefieldOnly, false); } /** - * - * @param fromBattlefieldOnly the object is only returned if it's on the battlefield as the effect resolves - * @param returnFromNextZone the object is only returned, if it has changed the zone one time after the source ability triggered or was activated (e.g. Angelic Destiny) + * + * @param fromBattlefieldOnly the object is only returned if it's on the + * battlefield as the effect resolves + * @param returnFromNextZone the object is only returned, if it has changed + * the zone one time after the source ability triggered or was activated + * (e.g. Angelic Destiny) */ public ReturnToHandSourceEffect(boolean fromBattlefieldOnly, boolean returnFromNextZone) { super(Outcome.ReturnToHand); @@ -83,8 +86,8 @@ public class ReturnToHandSourceEffect extends OneShotEffect { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { MageObject mageObject; - if (returnFromNextZone && - game.getState().getZoneChangeCounter(source.getSourceId()) == source.getSourceObjectZoneChangeCounter() + 1) { + if (returnFromNextZone + && game.getState().getZoneChangeCounter(source.getSourceId()) == source.getSourceObjectZoneChangeCounter() + 1) { mageObject = game.getObject(source.getSourceId()); } else { mageObject = source.getSourceObjectIfItStillExists(game); @@ -94,13 +97,13 @@ public class ReturnToHandSourceEffect extends OneShotEffect { case BATTLEFIELD: Permanent permanent = game.getPermanent(source.getSourceId()); if (permanent != null) { - return controller.moveCardToHandWithInfo(permanent, source.getSourceId(), game, Zone.BATTLEFIELD); + return controller.moveCards(permanent, null, Zone.HAND, source, game); } break; case GRAVEYARD: Card card = (Card) mageObject; if (!fromBattlefieldOnly) { - return controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD); + return controller.moveCards(card, null, Zone.HAND, source, game); } } } diff --git a/Mage/src/mage/abilities/effects/common/ReturnToHandSpellEffect.java b/Mage/src/mage/abilities/effects/common/ReturnToHandSpellEffect.java index ab34bb72add..c7f138bd302 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnToHandSpellEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnToHandSpellEffect.java @@ -31,7 +31,7 @@ public class ReturnToHandSpellEffect extends OneShotEffect implements MageSingle Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { Card spellCard = game.getStack().getSpell(source.getSourceId()).getCard(); - controller.moveCardToHandWithInfo(spellCard, source.getSourceId(), game, Zone.STACK); + controller.moveCards(spellCard, null, Zone.HAND, source, game); return true; } return false; diff --git a/Mage/src/mage/abilities/effects/common/ReturnToHandTargetEffect.java b/Mage/src/mage/abilities/effects/common/ReturnToHandTargetEffect.java index 0edac1ef0f5..ebf5260bbb5 100644 --- a/Mage/src/mage/abilities/effects/common/ReturnToHandTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/ReturnToHandTargetEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,26 +20,24 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common; import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; +import mage.cards.Cards; +import mage.cards.CardsImpl; import mage.constants.Outcome; import mage.constants.Zone; -import static mage.constants.Zone.BATTLEFIELD; -import static mage.constants.Zone.EXILED; -import static mage.constants.Zone.GRAVEYARD; import mage.game.Game; -import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.Target; import mage.util.CardUtil; @@ -72,40 +70,20 @@ public class ReturnToHandTargetEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - boolean result = true; // in case no target is selected Player controller = game.getPlayer(source.getControllerId()); if (controller == null) { return false; } + Cards cardsToHand = new CardsImpl(); + Zone fromZone = game.getState().getZone(targetPointer.getFirst(game, source)); + for (UUID targetId : targetPointer.getTargets(game, source)) { - switch (game.getState().getZone(targetId)) { - case BATTLEFIELD: - Permanent permanent = game.getPermanent(targetId); - if (permanent != null) { - controller.moveCardToHandWithInfo((Card) permanent, source.getSourceId(), game, Zone.BATTLEFIELD, withName); - } else { - result = false; - } - break; - case GRAVEYARD: - Card card = game.getCard(targetId); - if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.GRAVEYARD, withName); - } else { - result = false; - } - break; - case EXILED: - card = game.getCard(targetId); - if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.EXILED, withName); - } else { - result = false; - } - break; + MageObject mageObject = game.getObject(targetId); + if (mageObject instanceof Card) { + cardsToHand.add((Card) mageObject); } } - return result; + return controller.moveCards(cardsToHand, fromZone, Zone.HAND, source, game); } @Override diff --git a/Mage/src/mage/abilities/effects/common/RevealLibraryPutIntoHandEffect.java b/Mage/src/mage/abilities/effects/common/RevealLibraryPutIntoHandEffect.java index 78cf2a7424e..0d3335958e6 100644 --- a/Mage/src/mage/abilities/effects/common/RevealLibraryPutIntoHandEffect.java +++ b/Mage/src/mage/abilities/effects/common/RevealLibraryPutIntoHandEffect.java @@ -28,11 +28,13 @@ package mage.abilities.effects.common; import java.util.Set; +import mage.MageObject; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; +import mage.cards.Cards; import mage.cards.CardsImpl; import mage.constants.Outcome; import mage.constants.Zone; @@ -45,7 +47,6 @@ import mage.util.CardUtil; * * @author LevelX */ - public class RevealLibraryPutIntoHandEffect extends OneShotEffect { private DynamicValue amountCards; @@ -78,27 +79,26 @@ public class RevealLibraryPutIntoHandEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player == null) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller == null || sourceObject == null) { return false; } CardsImpl cards = new CardsImpl(); - int amount = Math.min(amountCards.calculate(game, source, this), player.getLibrary().size()); - for (int i = 0; i < amount; i++) { - cards.add(player.getLibrary().removeFromTop(game)); - } - player.revealCards(new StringBuilder("Put ").append(filter.getMessage()).append(" into hand").toString(), cards, game); + cards.addAll(controller.getLibrary().getTopCards(game, amountCards.calculate(game, source, this))); + controller.revealCards(sourceObject.getIdName(), cards, game); Set cardsList = cards.getCards(game); + Cards cardsToHand = new CardsImpl(); for (Card card : cardsList) { if (filter.match(card, game)) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); + cardsToHand.add(card); cards.remove(card); } } - - player.putCardsOnBottomOfLibrary(cards, game, source, anyOrder); + controller.moveCards(cardsToHand, null, Zone.HAND, source, game); + controller.putCardsOnBottomOfLibrary(cards, game, source, anyOrder); return true; } diff --git a/Mage/src/mage/abilities/effects/common/SacrificeAllEffect.java b/Mage/src/mage/abilities/effects/common/SacrificeAllEffect.java index 12ca8a7485a..f00f0433c0a 100644 --- a/Mage/src/mage/abilities/effects/common/SacrificeAllEffect.java +++ b/Mage/src/mage/abilities/effects/common/SacrificeAllEffect.java @@ -92,7 +92,7 @@ public class SacrificeAllEffect extends OneShotEffect { int numTargets = Math.min(amount.calculate(game, source, this), game.getBattlefield().countAll(filter, player.getId(), game)); TargetControlledPermanent target = new TargetControlledPermanent(numTargets, numTargets, filter, true); if (target.canChoose(player.getId(), game)) { - while (!target.isChosen() && player.isInGame()) { + while (!target.isChosen() && player.canRespond()) { player.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } perms.addAll(target.getTargets()); diff --git a/Mage/src/mage/abilities/effects/common/SacrificeEffect.java b/Mage/src/mage/abilities/effects/common/SacrificeEffect.java index ad24e45819a..a821c35458e 100644 --- a/Mage/src/mage/abilities/effects/common/SacrificeEffect.java +++ b/Mage/src/mage/abilities/effects/common/SacrificeEffect.java @@ -90,7 +90,7 @@ public class SacrificeEffect extends OneShotEffect{ // A spell or ability could have removed the only legal target this player // had, if thats the case this ability should fizzle. if (amount > 0 && target.canChoose(source.getSourceId(), player.getId(), game)) { - while (!target.isChosen() && target.canChoose(player.getId(), game) && player.isInGame()) { + while (!target.isChosen() && target.canChoose(player.getId(), game) && player.canRespond()) { player.chooseTarget(Outcome.Sacrifice, target, source, game); } diff --git a/Mage/src/mage/abilities/effects/common/SacrificeTargetEffect.java b/Mage/src/mage/abilities/effects/common/SacrificeTargetEffect.java index 0421dd32f11..024b3a856c7 100644 --- a/Mage/src/mage/abilities/effects/common/SacrificeTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/SacrificeTargetEffect.java @@ -1,38 +1,37 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common; import java.util.UUID; -import mage.constants.Outcome; import mage.abilities.Ability; import mage.abilities.Mode; import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; import mage.game.Game; import mage.game.permanent.Permanent; @@ -42,17 +41,31 @@ import mage.game.permanent.Permanent; */ public class SacrificeTargetEffect extends OneShotEffect { + protected UUID playerIdThatHasToSacrifice; + public SacrificeTargetEffect() { - super(Outcome.Sacrifice); + this(""); } public SacrificeTargetEffect(String text) { - this(); + this(text, null); + } + + /** + * + * @param text use this text as rule text for the effect + * @param playerIdThatHasToSacrifice only this playerId has to sacrifice + * (others can't) + */ + public SacrificeTargetEffect(String text, UUID playerIdThatHasToSacrifice) { + super(Outcome.Sacrifice); + this.playerIdThatHasToSacrifice = playerIdThatHasToSacrifice; staticText = text; } public SacrificeTargetEffect(final SacrificeTargetEffect effect) { super(effect); + this.playerIdThatHasToSacrifice = effect.playerIdThatHasToSacrifice; } @Override @@ -65,7 +78,7 @@ public class SacrificeTargetEffect extends OneShotEffect { int affectedTargets = 0; for (UUID permanentId : targetPointer.getTargets(game, source)) { Permanent permanent = game.getPermanent(permanentId); - if (permanent != null) { + if (permanent != null && (playerIdThatHasToSacrifice == null || playerIdThatHasToSacrifice.equals(permanent.getControllerId()))) { permanent.sacrifice(source.getSourceId(), game); affectedTargets++; } diff --git a/Mage/src/mage/abilities/effects/common/UntapAllEffect.java b/Mage/src/mage/abilities/effects/common/UntapAllEffect.java new file mode 100644 index 00000000000..b2b05b496d7 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/UntapAllEffect.java @@ -0,0 +1,69 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.filter.FilterPermanent; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author LevelX2 + */ +public class UntapAllEffect extends OneShotEffect { + + private final FilterPermanent filter; + + public UntapAllEffect(FilterPermanent filter) { + super(Outcome.Untap); + staticText = "untap all " + filter.getMessage(); + this.filter = filter; + } + + public UntapAllEffect(final UntapAllEffect effect) { + super(effect); + this.filter = effect.filter; + } + + @Override + public boolean apply(Game game, Ability source) { + for (Permanent permanent : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { + permanent.untap(game); + } + return true; + } + + @Override + public UntapAllEffect copy() { + return new UntapAllEffect(this); + } + +} diff --git a/Mage/src/mage/abilities/effects/common/combat/AttacksIfAbleAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/AttacksIfAbleAttachedEffect.java index f435569bed1..2a3d5d3df58 100644 --- a/Mage/src/mage/abilities/effects/common/combat/AttacksIfAbleAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/AttacksIfAbleAttachedEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -47,8 +47,8 @@ public class AttacksIfAbleAttachedEffect extends RequirementEffect { if (attachmentType.equals(AttachmentType.AURA)) { this.staticText = "Enchanted creature attacks each turn if able"; } else { - this.staticText = "Equiped creature attacks each turn if able"; - } + this.staticText = "Equipped creature attacks each turn if able"; + } } public AttacksIfAbleAttachedEffect(final AttacksIfAbleAttachedEffect effect) { diff --git a/Mage/src/mage/abilities/effects/common/combat/BlocksIfAbleAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/BlocksIfAbleAttachedEffect.java index d7584c2eb5b..02d817da833 100644 --- a/Mage/src/mage/abilities/effects/common/combat/BlocksIfAbleAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/BlocksIfAbleAttachedEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -47,8 +47,8 @@ public class BlocksIfAbleAttachedEffect extends RequirementEffect { if (attachmentType.equals(AttachmentType.AURA)) { this.staticText = "Enchanted creature blocks each turn if able"; } else { - this.staticText = "Equiped creature blocks each turn if able"; - } + this.staticText = "Equipped creature blocks each turn if able"; + } } public BlocksIfAbleAttachedEffect(final BlocksIfAbleAttachedEffect effect) { diff --git a/Mage/src/mage/abilities/effects/common/combat/CantAttackAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/CantAttackAttachedEffect.java index 7293e7b8a23..4c2c2141b0a 100644 --- a/Mage/src/mage/abilities/effects/common/combat/CantAttackAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/CantAttackAttachedEffect.java @@ -47,8 +47,8 @@ public class CantAttackAttachedEffect extends RestrictionEffect { if (attachmentType.equals(AttachmentType.AURA)) { this.staticText = "Enchanted creature can't attack"; } else { - this.staticText = "Equiped creature can't attack"; - } + this.staticText = "Equipped creature can't attack"; + } } public CantAttackAttachedEffect(final CantAttackAttachedEffect effect) { diff --git a/Mage/src/mage/abilities/effects/common/combat/CantAttackBlockAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/CantAttackBlockAttachedEffect.java index ba1c8e793f0..882fa731292 100644 --- a/Mage/src/mage/abilities/effects/common/combat/CantAttackBlockAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/CantAttackBlockAttachedEffect.java @@ -45,7 +45,7 @@ public class CantAttackBlockAttachedEffect extends RestrictionEffect { if (attachmentType.equals(AttachmentType.AURA)) { this.staticText = "Enchanted creature can't attack or block"; } else { - this.staticText = "Equiped creature can't attack or block"; + this.staticText = "Equipped creature can't attack or block"; } } @@ -67,7 +67,7 @@ public class CantAttackBlockAttachedEffect extends RestrictionEffect { public boolean canAttack(Game game) { return false; } - + @Override public boolean canBlock(Permanent attacker, Permanent blocker, Ability source, Game game) { return false; diff --git a/Mage/src/mage/abilities/effects/common/combat/CantAttackControllerAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/CantAttackControllerAttachedEffect.java index 465cac1abfa..693b73307a0 100644 --- a/Mage/src/mage/abilities/effects/common/combat/CantAttackControllerAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/CantAttackControllerAttachedEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -38,7 +38,7 @@ import mage.game.permanent.Permanent; /** - * + * * @author LevelX2 */ @@ -49,8 +49,8 @@ public class CantAttackControllerAttachedEffect extends RestrictionEffect { if (attachmentType.equals(AttachmentType.AURA)) { this.staticText = "Enchanted creature can't attack you or a planeswalker you control"; } else { - this.staticText = "Equiped creature can't attack you or a planeswalker you control"; - } + this.staticText = "Equipped creature can't attack you or a planeswalker you control"; + } } public CantAttackControllerAttachedEffect(final CantAttackControllerAttachedEffect effect) { @@ -71,7 +71,7 @@ public class CantAttackControllerAttachedEffect extends RestrictionEffect { return plainswalker == null || !plainswalker.getControllerId().equals(source.getControllerId()); } - + @Override public CantAttackControllerAttachedEffect copy() { return new CantAttackControllerAttachedEffect(this); diff --git a/Mage/src/mage/abilities/effects/common/combat/CantBlockAttachedEffect.java b/Mage/src/mage/abilities/effects/common/combat/CantBlockAttachedEffect.java index 06749ce98de..b42d9e082b1 100644 --- a/Mage/src/mage/abilities/effects/common/combat/CantBlockAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/combat/CantBlockAttachedEffect.java @@ -27,12 +27,13 @@ */ package mage.abilities.effects.common.combat; -import mage.constants.AttachmentType; -import mage.constants.Duration; import mage.abilities.Ability; import mage.abilities.effects.RestrictionEffect; +import mage.constants.AttachmentType; +import mage.constants.Duration; import mage.game.Game; import mage.game.permanent.Permanent; +import mage.target.targetpointer.FixedTarget; /** * @@ -40,17 +41,17 @@ import mage.game.permanent.Permanent; */ public class CantBlockAttachedEffect extends RestrictionEffect { - public CantBlockAttachedEffect(AttachmentType attachmentType) { + public CantBlockAttachedEffect(AttachmentType attachmentType) { this(attachmentType, Duration.WhileOnBattlefield); } - - public CantBlockAttachedEffect(AttachmentType attachmentType, Duration duration) { + + public CantBlockAttachedEffect(AttachmentType attachmentType, Duration duration) { super(duration); StringBuilder sb = new StringBuilder(); if (attachmentType.equals(AttachmentType.AURA)) { sb.append("Enchanted creature can't block"); } else { - sb.append("Equiped creature can't block"); + sb.append("Equipped creature can't block"); } if (!duration.toString().isEmpty()) { sb.append(" ").append(duration.toString()); @@ -62,8 +63,22 @@ public class CantBlockAttachedEffect extends RestrictionEffect { super(effect); } + @Override + public void init(Ability source, Game game) { + super.init(source, game); + if (affectedObjectsSet) { + Permanent equipment = game.getPermanent(source.getSourceId()); + if (equipment != null && equipment.getAttachedTo() != null) { + this.setTargetPointer(new FixedTarget(equipment.getAttachedTo(), game.getState().getZoneChangeCounter(equipment.getAttachedTo()))); + } + } + } + @Override public boolean applies(Permanent permanent, Ability source, Game game) { + if (affectedObjectsSet) { + return targetPointer.getFirst(game, source).equals(permanent.getId()); + } return permanent.getAttachments().contains(source.getSourceId()); } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BecomesChosenNonWallCreatureTypeTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BecomesChosenNonWallCreatureTypeTargetEffect.java index 3055295f8fd..316ef45e413 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BecomesChosenNonWallCreatureTypeTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BecomesChosenNonWallCreatureTypeTargetEffect.java @@ -40,7 +40,7 @@ public class BecomesChosenNonWallCreatureTypeTargetEffect extends OneShotEffect types.remove("Wall"); typeChoice.setChoices(types); while (!player.choose(Outcome.BoostCreature, typeChoice, game)) { - if (!player.isInGame()) { + if (!player.canRespond()) { return false; } } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorOrColorsTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorOrColorsTargetEffect.java index 87393154748..dcdbe3ef9f2 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorOrColorsTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorOrColorsTargetEffect.java @@ -78,7 +78,7 @@ public class BecomesColorOrColorsTargetEffect extends OneShotEffect { } ChoiceColor choiceColor = new ChoiceColor(); controller.choose(Outcome.Benefit, choiceColor, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } if (!game.isSimulation()) diff --git a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorSourceEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorSourceEffect.java index e7205a7b5bf..89f5c58ad6d 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorSourceEffect.java @@ -80,7 +80,7 @@ public class BecomesColorSourceEffect extends ContinuousEffectImpl { ChoiceColor choice = new ChoiceColor(); while(!choice.isChosen()) { controller.choose(Outcome.PutManaInPool, choice, game); - if(!controller.isInGame()) { + if(!controller.canRespond()) { return; } } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorTargetEffect.java index 975beaa6e71..f1d1369cdb8 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BecomesColorTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BecomesColorTargetEffect.java @@ -83,7 +83,7 @@ public class BecomesColorTargetEffect extends ContinuousEffectImpl { ChoiceColor choice = new ChoiceColor(); while (!choice.isChosen()) { controller.choose(Outcome.PutManaInPool, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return; } } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BecomesSubtypeAllEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BecomesSubtypeAllEffect.java index 36c62e51adb..80e7bcdb69b 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BecomesSubtypeAllEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BecomesSubtypeAllEffect.java @@ -6,8 +6,11 @@ package mage.abilities.effects.common.continuous; import java.util.ArrayList; +import java.util.Iterator; +import mage.MageObjectReference; import mage.abilities.Ability; +import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.ContinuousEffectImpl; import mage.constants.Duration; import mage.constants.Layer; @@ -25,21 +28,23 @@ public class BecomesSubtypeAllEffect extends ContinuousEffectImpl { protected ArrayList subtypes = new ArrayList(); protected boolean loseOther; // loses other subtypes + protected FilterCreaturePermanent filter; - public BecomesSubtypeAllEffect(Duration duration, String subtype) { + public BecomesSubtypeAllEffect(Duration duration, String subtype) { this(duration, createArrayList(subtype)); } public BecomesSubtypeAllEffect(Duration duration, ArrayList subtypes) { - this(duration, subtypes, true); + this(duration, subtypes, new FilterCreaturePermanent("All creatures"), true); } public BecomesSubtypeAllEffect(Duration duration, - ArrayList subtypes, boolean loseOther) { + ArrayList subtypes, FilterCreaturePermanent filter, boolean loseOther) { super(duration, Outcome.Detriment); this.subtypes = subtypes; this.staticText = setText(); this.loseOther = loseOther; + this.filter = filter; } private static ArrayList createArrayList(String subtype) { @@ -52,7 +57,7 @@ public class BecomesSubtypeAllEffect extends ContinuousEffectImpl { super(effect); this.subtypes.addAll(effect.subtypes); this.loseOther = effect.loseOther; - this.loseOther = effect.loseOther; + this.filter = effect.filter; } @Override @@ -68,9 +73,7 @@ public class BecomesSubtypeAllEffect extends ContinuousEffectImpl { @Override public boolean apply(Layer layer, SubLayer sublayer, Ability source, Game game) { - - for (Permanent permanent : game.getBattlefield() - .getAllActivePermanents(new FilterCreaturePermanent(), game)) { + for (Permanent permanent : game.getBattlefield().getAllActivePermanents(filter, game)) { if (permanent != null) { switch (layer) { case TypeChangingEffects_4: diff --git a/Mage/src/mage/abilities/effects/common/continuous/BoostAllEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BoostAllEffect.java index d050cfe0f5d..70622957cea 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BoostAllEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BoostAllEffect.java @@ -1,43 +1,42 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common.continuous; import java.util.Iterator; import mage.MageObjectReference; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.SubLayer; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.ContinuousEffectImpl; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; import mage.filter.common.FilterCreaturePermanent; import mage.game.Game; import mage.game.permanent.Permanent; @@ -84,9 +83,9 @@ public class BoostAllEffect extends ContinuousEffectImpl { this.toughness = toughness; this.filter = filter; this.excludeSource = excludeSource; - + this.lockedInPT = lockedInPT; - if (rule == null) { + if (rule == null || rule.isEmpty()) { setText(); } else { this.staticText = rule; @@ -111,7 +110,7 @@ public class BoostAllEffect extends ContinuousEffectImpl { public void init(Ability source, Game game) { super.init(source, game); if (this.affectedObjectsSet) { - for (Permanent perm: game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { + for (Permanent perm : game.getBattlefield().getActivePermanents(filter, source.getControllerId(), source.getSourceId(), game)) { if (!(excludeSource && perm.getId().equals(source.getSourceId()))) { affectedObjectList.add(new MageObjectReference(perm, game)); } @@ -143,7 +142,7 @@ public class BoostAllEffect extends ContinuousEffectImpl { } } - } + } return true; } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BoostEnchantedEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BoostEnchantedEffect.java index f806ef6541a..0f60a80c170 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BoostEnchantedEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BoostEnchantedEffect.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,24 +20,24 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.effects.common.continuous; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.SubLayer; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.ContinuousEffectImpl; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; import mage.game.Game; import mage.game.permanent.Permanent; +import mage.target.targetpointer.FixedTarget; /** * @@ -79,15 +79,37 @@ public class BoostEnchantedEffect extends ContinuousEffectImpl { } @Override - public boolean apply(Game game, Ability source) { - Permanent enchantment = game.getPermanent(source.getSourceId()); - if (enchantment != null && enchantment.getAttachedTo() != null) { - Permanent creature = game.getPermanent(enchantment.getAttachedTo()); - if (creature != null) { - creature.addPower(power.calculate(game, source, this)); - creature.addToughness(toughness.calculate(game, source, this)); + public void init(Ability source, Game game) { + super.init(source, game); + if (affectedObjectsSet) { + // Added boosts of activated or triggered abilities exist independent from the source they are created by + // so a continuous effect for the permanent itself with the attachment is created + Permanent equipment = game.getPermanent(source.getSourceId()); + if (equipment != null && equipment.getAttachedTo() != null) { + this.setTargetPointer(new FixedTarget(equipment.getAttachedTo(), game.getState().getZoneChangeCounter(equipment.getAttachedTo()))); } } + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = null; + if (affectedObjectsSet) { + permanent = game.getPermanent(targetPointer.getFirst(game, source)); + if (permanent == null) { + discard(); + return true; + } + } else { + Permanent equipment = game.getPermanent(source.getSourceId()); + if (equipment != null && equipment.getAttachedTo() != null) { + permanent = game.getPermanent(equipment.getAttachedTo()); + } + } + if (permanent != null) { + permanent.addPower(power.calculate(game, source, this)); + permanent.addToughness(toughness.calculate(game, source, this)); + } return true; } @@ -95,16 +117,15 @@ public class BoostEnchantedEffect extends ContinuousEffectImpl { StringBuilder sb = new StringBuilder(); sb.append("Enchanted creature gets "); String p = power.toString(); - if(!p.startsWith("-")) { + if (!p.startsWith("-")) { sb.append("+"); } sb.append(p).append("/"); String t = toughness.toString(); - if(!t.startsWith("-")){ - if(p.startsWith("-")) { + if (!t.startsWith("-")) { + if (p.startsWith("-")) { sb.append("-"); - } - else { + } else { sb.append("+"); } } diff --git a/Mage/src/mage/abilities/effects/common/continuous/BoostTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/BoostTargetEffect.java index 0cbb14b528d..1d11baae793 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/BoostTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/BoostTargetEffect.java @@ -115,8 +115,11 @@ public class BoostTargetEffect extends ContinuousEffectImpl { if (staticText != null && !staticText.isEmpty()) { return staticText; } - StringBuilder sb = new StringBuilder(); + if (mode == null || mode.getTargets().size() == 0) { + return "no target"; + } Target target = mode.getTargets().get(0); + StringBuilder sb = new StringBuilder(); if (target.getMaxNumberOfTargets() > 1) { if (target.getNumberOfTargets() < target.getNumberOfTargets()) { sb.append("up to "); diff --git a/Mage/src/mage/abilities/effects/common/continuous/ExchangeControlTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/ExchangeControlTargetEffect.java index a795f208948..729dbfe325f 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/ExchangeControlTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/ExchangeControlTargetEffect.java @@ -25,9 +25,9 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - + package mage.abilities.effects.common.continuous; - + import java.util.*; import mage.constants.Duration; import mage.constants.Layer; @@ -38,57 +38,57 @@ import mage.abilities.Mode; import mage.abilities.effects.ContinuousEffectImpl; import mage.game.Game; import mage.game.permanent.Permanent; - + /** * @author magenoxx_at_googlemail.com */ public class ExchangeControlTargetEffect extends ContinuousEffectImpl { - + private String rule; private boolean withSource; private boolean withSecondTarget; private Map zoneChangeCounter = new HashMap<>(); private Map lockedControllers = new HashMap<>(); - + public ExchangeControlTargetEffect(Duration duration, String rule) { this(duration, rule, false); } - + public ExchangeControlTargetEffect(Duration duration, String rule, boolean withSource) { this(duration, rule, withSource, false); } - + public ExchangeControlTargetEffect(Duration duration, String rule, boolean withSource, boolean withSecondTarget) { super(duration, Layer.ControlChangingEffects_2, SubLayer.NA, Outcome.GainControl); this.withSource = withSource; this.withSecondTarget = withSecondTarget; this.rule = rule; } - + public ExchangeControlTargetEffect(final ExchangeControlTargetEffect effect) { super(effect); this.rule = effect.rule; this.withSource = effect.withSource; this.withSecondTarget = effect.withSecondTarget; - this.lockedControllers = effect.lockedControllers; - this.zoneChangeCounter = effect.zoneChangeCounter; + this.lockedControllers = new HashMap(effect.lockedControllers); + this.zoneChangeCounter = new HashMap(effect.zoneChangeCounter); } - + @Override public ExchangeControlTargetEffect copy() { return new ExchangeControlTargetEffect(this); } - + @Override public boolean isInactive(Ability source, Game game) { return isDiscarded(); } - + @Override public void init(Ability source, Game game) { Permanent permanent1 = null; Permanent permanent2 = null; - + if (withSource) { permanent1 = game.getPermanent(targetPointer.getFirst(game, source)); permanent2 = game.getPermanent(source.getSourceId()); @@ -115,13 +115,13 @@ public class ExchangeControlTargetEffect extends ContinuousEffectImpl { this.lockedControllers.put(permanent1.getId(), permanent2.getControllerId()); this.zoneChangeCounter.put(permanent1.getId(), permanent1.getZoneChangeCounter(game)); this.lockedControllers.put(permanent2.getId(), permanent1.getControllerId()); - this.zoneChangeCounter.put(permanent2.getId(), permanent2.getZoneChangeCounter(game)); + this.zoneChangeCounter.put(permanent2.getId(), permanent2.getZoneChangeCounter(game)); } else { // discard if there are less than 2 permanents discard(); } } - + @Override public boolean apply(Game game, Ability source) { Set toDelete = new HashSet<>(); @@ -137,7 +137,7 @@ public class ExchangeControlTargetEffect extends ContinuousEffectImpl { } if (!toDelete.isEmpty()) { for(UUID uuid: toDelete) { - zoneChangeCounter.remove(uuid); + zoneChangeCounter.remove(uuid); } if (zoneChangeCounter.isEmpty()) { discard(); @@ -146,7 +146,7 @@ public class ExchangeControlTargetEffect extends ContinuousEffectImpl { } return true; } - + @Override public String getText(Mode mode) { return this.rule; diff --git a/Mage/src/mage/abilities/effects/common/continuous/GainAbilityAttachedEffect.java b/Mage/src/mage/abilities/effects/common/continuous/GainAbilityAttachedEffect.java index 3029a00fc14..9120ccb5512 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/GainAbilityAttachedEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/GainAbilityAttachedEffect.java @@ -45,35 +45,36 @@ public class GainAbilityAttachedEffect extends ContinuousEffectImpl { protected Ability ability; protected AttachmentType attachmentType; - protected boolean fixedTarget = false; + protected boolean independentEffect; + + public GainAbilityAttachedEffect(Ability ability, AttachmentType attachmentType) { + this(ability, attachmentType, Duration.WhileOnBattlefield); + } + + public GainAbilityAttachedEffect(Ability ability, AttachmentType attachmentType, Duration duration) { + this(ability, attachmentType, duration, null); + } public GainAbilityAttachedEffect(Ability ability, AttachmentType attachmentType, Duration duration, String rule) { super(duration, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); this.ability = ability; this.attachmentType = attachmentType; - this.duration = duration; - if (duration == Duration.EndOfTurn) { - fixedTarget = true; + switch (duration) { + case WhileOnBattlefield: + case WhileInGraveyard: + case WhileOnStack: + independentEffect = false; + break; + default: + // such effects exist independent from the enchantment that created the effect + independentEffect = true; } - this.staticText = rule; - } - public GainAbilityAttachedEffect(Ability ability, AttachmentType attachmentType, Duration duration) { - super(duration, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); - this.ability = ability; - this.attachmentType = attachmentType; - this.duration = duration; - if (duration == Duration.EndOfTurn) { - fixedTarget = true; + if (rule == null) { + setText(); + } else { + this.staticText = rule; } - setText(); - } - - public GainAbilityAttachedEffect(Ability ability, AttachmentType attachmentType) { - super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); - this.ability = ability; - this.attachmentType = attachmentType; - setText(); } public GainAbilityAttachedEffect(final GainAbilityAttachedEffect effect) { @@ -81,7 +82,7 @@ public class GainAbilityAttachedEffect extends ContinuousEffectImpl { this.ability = effect.ability.copy(); ability.newId(); // This is needed if the effect is copied e.g. by a clone so the ability can be added multiple times to permanents this.attachmentType = effect.attachmentType; - this.fixedTarget = effect.fixedTarget; + this.independentEffect = effect.independentEffect; } @Override @@ -92,27 +93,31 @@ public class GainAbilityAttachedEffect extends ContinuousEffectImpl { @Override public void init(Ability source, Game game) { super.init(source, game); - if (fixedTarget) { + if (affectedObjectsSet) { Permanent equipment = game.getPermanent(source.getSourceId()); if (equipment != null && equipment.getAttachedTo() != null) { - this.setTargetPointer(new FixedTarget(equipment.getAttachedTo())); + this.setTargetPointer(new FixedTarget(equipment.getAttachedTo(), game.getState().getZoneChangeCounter(equipment.getAttachedTo()))); } } } @Override public boolean apply(Game game, Ability source) { - Permanent creature = null; - if (fixedTarget) { - creature = game.getPermanent(targetPointer.getFirst(game, source)); + Permanent permanent = null; + if (affectedObjectsSet) { + permanent = game.getPermanent(targetPointer.getFirst(game, source)); + if (permanent == null) { + discard(); + return true; + } } else { Permanent equipment = game.getPermanent(source.getSourceId()); if (equipment != null && equipment.getAttachedTo() != null) { - creature = game.getPermanent(equipment.getAttachedTo()); + permanent = game.getPermanent(equipment.getAttachedTo()); } } - if (creature != null) { - creature.addAbility(ability, source.getSourceId(), game, false); + if (permanent != null) { + permanent.addAbility(ability, source.getSourceId(), game, false); } return true; } diff --git a/Mage/src/mage/abilities/effects/common/continuous/GainAbilityTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/GainAbilityTargetEffect.java index 404c0476d7f..097da54a5dc 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/GainAbilityTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/GainAbilityTargetEffect.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.effects.common.continuous; import java.util.Locale; @@ -85,10 +84,10 @@ public class GainAbilityTargetEffect extends ContinuousEffectImpl { } /** - * Used to set a duration to the next durationPhaseStep of the - * first controller of the effect. - * - * @param phaseStep + * Used to set a duration to the next durationPhaseStep of the first + * controller of the effect. + * + * @param phaseStep */ public void setDurationToPhase(PhaseStep phaseStep) { durationPhaseStep = phaseStep; @@ -105,8 +104,10 @@ public class GainAbilityTargetEffect extends ContinuousEffectImpl { @Override public boolean isInactive(Ability source, Game game) { - if (durationPhaseStep != null && durationPhaseStep.equals(game.getPhase().getStep().getType())) - { + if (super.isInactive(source, game)) { + return true; + } + if (durationPhaseStep != null && durationPhaseStep.equals(game.getPhase().getStep().getType())) { if (!sameStep && game.getActivePlayerId().equals(durationPlayerId) || game.getPlayer(durationPlayerId).hasReachedNextTurnAfterLeaving()) { return true; } @@ -157,7 +158,7 @@ public class GainAbilityTargetEffect extends ContinuousEffectImpl { } StringBuilder sb = new StringBuilder(); Target target = mode.getTargets().get(0); - if(target.getMaxNumberOfTargets() > 1){ + if (target.getMaxNumberOfTargets() > 1) { if (target.getNumberOfTargets() < target.getMaxNumberOfTargets()) { sb.append("Up to"); } diff --git a/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorSourceEffect.java b/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorSourceEffect.java index 656c7b23fce..1dc0ffe2002 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorSourceEffect.java @@ -72,7 +72,7 @@ public class GainProtectionFromColorSourceEffect extends GainAbilitySourceEffect colorChoice.setMessage("Choose color for protection ability"); while (!colorChoice.isChosen()) { controller.choose(outcome, colorChoice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { discard(); return; } diff --git a/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorTargetEffect.java b/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorTargetEffect.java index a6af9b8dcc6..c54a6b44217 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/GainProtectionFromColorTargetEffect.java @@ -73,7 +73,7 @@ public class GainProtectionFromColorTargetEffect extends GainAbilityTargetEffect choice.clearChoice(); while (!choice.isChosen()) { controller.choose(Outcome.Protect, choice, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return; } } diff --git a/Mage/src/mage/abilities/effects/common/continuous/LoseAbilitySourceEffect.java b/Mage/src/mage/abilities/effects/common/continuous/LoseAbilitySourceEffect.java index fcfafd3dca0..2c898399a06 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/LoseAbilitySourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/LoseAbilitySourceEffect.java @@ -1,54 +1,54 @@ -/* - * To change this template, choose Tools | Templates - * and open the template in the editor. - */ -package mage.abilities.effects.common.continuous; - -import mage.abilities.Ability; -import mage.abilities.effects.ContinuousEffectImpl; -import mage.constants.Duration; -import mage.constants.Layer; -import mage.constants.Outcome; -import mage.constants.SubLayer; -import mage.game.Game; -import mage.game.permanent.Permanent; -/** - * - * @author Noahsark - */ -public class LoseAbilitySourceEffect extends ContinuousEffectImpl{ - - protected Ability ability; - - public LoseAbilitySourceEffect(Ability ability){ - this(ability, Duration.WhileOnBattlefield); - } - - public LoseAbilitySourceEffect(Ability ability, Duration duration){ - super(duration, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.LoseAbility); - this.ability = ability; - staticText = "{this} loses \"" + ability.getRule() + "\"" + duration.toString(); - } - - public LoseAbilitySourceEffect(final LoseAbilitySourceEffect effect){ - super(effect); - this.ability = effect.ability.copy(); - } - - @Override - public LoseAbilitySourceEffect copy(){ - return new LoseAbilitySourceEffect(this); - } - - @Override - public boolean apply(Game game, Ability source){ - Permanent permanent = game.getPermanent(source.getSourceId()); - if (permanent != null){ - // 112.10 - while (permanent.getAbilities().remove(ability)) { - - } - } - return true; - } -} +/* + * To change this template, choose Tools | Templates + * and open the template in the editor. + */ +package mage.abilities.effects.common.continuous; + +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; +import mage.game.Game; +import mage.game.permanent.Permanent; +/** + * + * @author Noahsark + */ +public class LoseAbilitySourceEffect extends ContinuousEffectImpl{ + + protected Ability ability; + + public LoseAbilitySourceEffect(Ability ability){ + this(ability, Duration.WhileOnBattlefield); + } + + public LoseAbilitySourceEffect(Ability ability, Duration duration){ + super(duration, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.LoseAbility); + this.ability = ability; + staticText = "{this} loses " + ability.getRule() + duration.toString(); + } + + public LoseAbilitySourceEffect(final LoseAbilitySourceEffect effect){ + super(effect); + this.ability = effect.ability.copy(); + } + + @Override + public LoseAbilitySourceEffect copy(){ + return new LoseAbilitySourceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source){ + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null){ + // 112.10 + while (permanent.getAbilities().remove(ability)) { + + } + } + return true; + } +} diff --git a/Mage/src/mage/abilities/effects/common/continuous/PlayTheTopCardEffect.java b/Mage/src/mage/abilities/effects/common/continuous/PlayTheTopCardEffect.java index 0c68c6db678..f75123d0e09 100644 --- a/Mage/src/mage/abilities/effects/common/continuous/PlayTheTopCardEffect.java +++ b/Mage/src/mage/abilities/effects/common/continuous/PlayTheTopCardEffect.java @@ -27,6 +27,7 @@ */ package mage.abilities.effects.common.continuous; +import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.AsThoughEffectImpl; import mage.cards.Card; @@ -37,8 +38,6 @@ import mage.filter.FilterCard; import mage.game.Game; import mage.players.Player; -import java.util.UUID; - /** * @author nantuko */ @@ -50,7 +49,7 @@ public class PlayTheTopCardEffect extends AsThoughEffectImpl { this(new FilterCard()); staticText = "You may play the top card of your library"; } - + public PlayTheTopCardEffect(FilterCard filter) { super(AsThoughEffectType.PLAY_FROM_NOT_OWN_HAND_ZONE, Duration.WhileOnBattlefield, Outcome.Benefit); this.filter = filter; @@ -75,9 +74,10 @@ public class PlayTheTopCardEffect extends AsThoughEffectImpl { @Override public boolean applies(UUID objectId, Ability source, UUID affectedControllerId, Game game) { Card cardOnTop = game.getCard(objectId); - if (cardOnTop != null && - affectedControllerId.equals(source.getControllerId()) && - filter.match(cardOnTop, game)) { + if (cardOnTop != null + && affectedControllerId.equals(source.getControllerId()) + && cardOnTop.getOwnerId().equals(source.getControllerId()) + && filter.match(cardOnTop, game)) { Player player = game.getPlayer(cardOnTop.getOwnerId()); if (player != null && cardOnTop.equals(player.getLibrary().getFromTop(game))) { return true; @@ -86,4 +86,4 @@ public class PlayTheTopCardEffect extends AsThoughEffectImpl { return false; } -} \ No newline at end of file +} diff --git a/Mage/src/mage/abilities/effects/common/continuous/PlayWithHandRevealedEffect.java b/Mage/src/mage/abilities/effects/common/continuous/PlayWithHandRevealedEffect.java new file mode 100644 index 00000000000..ebbb47260b8 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/continuous/PlayWithHandRevealedEffect.java @@ -0,0 +1,114 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common.continuous; + +import java.util.ArrayList; +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.Mode; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; +import mage.constants.TargetController; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author LoneFox + */ +public class PlayWithHandRevealedEffect extends ContinuousEffectImpl { + + private TargetController who; + + public PlayWithHandRevealedEffect(TargetController who) { + super(Duration.WhileOnBattlefield, Layer.PlayerEffects, SubLayer.NA, Outcome.Detriment); + this.who = who; + } + + public PlayWithHandRevealedEffect(final PlayWithHandRevealedEffect effect) { + super(effect); + who = effect.who; + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { + Iterable affectedPlayers; + switch(who) { + case ANY: + affectedPlayers = controller.getInRange(); + break; + case OPPONENT: + affectedPlayers = game.getOpponents(source.getControllerId()); + break; + case YOU: + ArrayList tmp = new ArrayList(); + tmp.add(source.getControllerId()); + affectedPlayers = tmp; + break; + default: + return false; + } + + for(UUID playerID: affectedPlayers) { + Player player = game.getPlayer(playerID); + if (player != null) { + player.revealCards(player.getName() + "'s hand cards", player.getHand(), game, false); + } + } + return true; + } + return false; + } + + @Override + public PlayWithHandRevealedEffect copy() { + return new PlayWithHandRevealedEffect(this); + } + + @Override + public String getText(Mode mode) { + if (staticText != null && !staticText.isEmpty()) { + return staticText; + } + switch(who) { + case ANY: + return "Players play with their hands revealed"; + case OPPONENT: + return "Your opponents play with their hands revealed"; + case YOU: + return "Play with your hand revealed"; + default: + return "Unknown TargetController for PlayWithHandRevealedEffect"; + } + } +} diff --git a/Mage/src/mage/abilities/effects/common/counter/AddRemoveAllTimeSuspentCountersEffect.java b/Mage/src/mage/abilities/effects/common/counter/AddRemoveAllTimeSuspentCountersEffect.java new file mode 100644 index 00000000000..6c1e8525bcb --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/counter/AddRemoveAllTimeSuspentCountersEffect.java @@ -0,0 +1,125 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.common.counter; + +import java.util.ArrayList; +import java.util.List; + +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.constants.Outcome; +import mage.counters.Counter; +import mage.filter.Filter; +import mage.game.Game; +import mage.players.Player; + +/** + * + * @author Gal Lerman + */ +public class AddRemoveAllTimeSuspentCountersEffect extends OneShotEffect { + + private final Counter counter; + private final Filter filter; + private final boolean removeCounter; + private final String actionStr; + + public AddRemoveAllTimeSuspentCountersEffect(Counter counter, Filter filter, boolean removeCounter) { + super(Outcome.Benefit); + this.counter = counter; + this.filter = filter; + this.removeCounter= removeCounter; + actionStr = removeCounter ? " removes " : " puts "; + setText(); + } + + public AddRemoveAllTimeSuspentCountersEffect(final AddRemoveAllTimeSuspentCountersEffect effect) { + super(effect); + this.counter = effect.counter.copy(); + this.filter = effect.filter.copy(); + this.removeCounter = effect.removeCounter; + this.actionStr = effect.actionStr; + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (controller != null && sourceObject != null) { + if (counter != null) { + List permanents = new ArrayList(game.getBattlefield().getAllActivePermanents()); + execute(game, controller, sourceObject, permanents, removeCounter); + final List exiledCards = game.getExile().getAllCards(game); + execute(game, controller, sourceObject, exiledCards, removeCounter); + } + return true; + } + return false; + } + + private void execute(final Game game, final Player controller, final MageObject sourceObject, final List cards, final boolean removeCounter) { + for (Card card : cards) { + if (filter.match(card, game)) { + final String counterName = counter.getName(); + if (removeCounter) { + final Counter existingCounterOfSameType = card.getCounters(game).get(counterName); + final int countersToRemove = Math.min(existingCounterOfSameType.getCount(), counter.getCount()); + final Counter modifiedCounter = new Counter(counterName, countersToRemove); + card.removeCounters(modifiedCounter, game); + } else { + card.addCounters(counter, game); + } + if (!game.isSimulation()) + game.informPlayers(new StringBuilder(sourceObject.getName()).append(": ") + .append(controller.getLogName()).append(actionStr) + .append(counter.getCount()).append(" ").append(counterName.toLowerCase()) + .append(" counter on ").append(card.getName()).toString()); + } + } + } + + private void setText() { + StringBuilder sb = new StringBuilder(); + final String actionsStr2 = removeCounter ? "remove " : " put "; + sb.append(actionsStr2); + if (counter.getCount() > 1) { + sb.append(Integer.toString(counter.getCount())).append(" ").append(counter.getName().toLowerCase()).append(" counters on each "); + } else { + sb.append("a ").append(counter.getName().toLowerCase()).append(" counter on each "); + } + sb.append(filter.getMessage()); + staticText = sb.toString(); + } + + @Override + public AddRemoveAllTimeSuspentCountersEffect copy() { + return new AddRemoveAllTimeSuspentCountersEffect(this); + } +} diff --git a/Mage/src/mage/abilities/effects/common/discard/DiscardCardYouChooseTargetEffect.java b/Mage/src/mage/abilities/effects/common/discard/DiscardCardYouChooseTargetEffect.java index 76462b5b011..d77f5ca6a46 100644 --- a/Mage/src/mage/abilities/effects/common/discard/DiscardCardYouChooseTargetEffect.java +++ b/Mage/src/mage/abilities/effects/common/discard/DiscardCardYouChooseTargetEffect.java @@ -134,7 +134,7 @@ public class DiscardCardYouChooseTargetEffect extends OneShotEffect { Cards revealedCards = new CardsImpl(Zone.HAND); numberToReveal = Math.min(player.getHand().size(), numberToReveal); if (player.getHand().size() > numberToReveal) { - TargetCardInHand chosenCards = new TargetCardInHand(numberToReveal, numberToReveal, new FilterCard("card in "+ player.getLogName() +"'s hand")); + TargetCardInHand chosenCards = new TargetCardInHand(numberToReveal, numberToReveal, new FilterCard("card in " + player.getLogName() + "'s hand")); chosenCards.setNotTarget(true); if (chosenCards.canChoose(player.getId(), game) && player.chooseTarget(Outcome.Discard, player.getHand(), chosenCards, source, game)) { if (!chosenCards.getTargets().isEmpty()) { @@ -151,7 +151,7 @@ public class DiscardCardYouChooseTargetEffect extends OneShotEffect { revealedCards.addAll(player.getHand()); } - player.revealCards(sourceCard != null ? sourceCard.getName() :"Discard", revealedCards, game); + player.revealCards(sourceCard != null ? sourceCard.getIdName() + " (" + sourceCard.getZoneChangeCounter(game) + ")" : "Discard", revealedCards, game); boolean result = true; int filteredCardsCount = revealedCards.count(filter, source.getSourceId(), source.getControllerId(), game); @@ -183,7 +183,7 @@ public class DiscardCardYouChooseTargetEffect extends OneShotEffect { private String setText() { StringBuilder sb = new StringBuilder("Target "); - switch(targetController) { + switch (targetController) { case OPPONENT: sb.append("opponent"); break; diff --git a/Mage/src/mage/abilities/effects/common/discard/DiscardControllerEffect.java b/Mage/src/mage/abilities/effects/common/discard/DiscardControllerEffect.java index da0da5f3cba..fa9d314a213 100644 --- a/Mage/src/mage/abilities/effects/common/discard/DiscardControllerEffect.java +++ b/Mage/src/mage/abilities/effects/common/discard/DiscardControllerEffect.java @@ -27,12 +27,12 @@ */ package mage.abilities.effects.common.discard; -import mage.constants.Outcome; import mage.abilities.Ability; import mage.abilities.dynamicvalue.DynamicValue; import mage.abilities.dynamicvalue.common.StaticValue; import mage.abilities.effects.OneShotEffect; import mage.cards.Card; +import mage.constants.Outcome; import mage.game.Game; import mage.players.Player; import mage.util.CardUtil; @@ -98,7 +98,7 @@ public class DiscardControllerEffect extends OneShotEffect { } private void setText() { - StringBuilder sb = new StringBuilder("Discard "); + StringBuilder sb = new StringBuilder("discard "); if (amount.toString().equals("1")) { sb.append("a"); } else { diff --git a/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java b/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java index 8c6c4e35228..694e8bf70eb 100644 --- a/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java +++ b/Mage/src/mage/abilities/effects/common/search/SearchLibraryPutInHandEffect.java @@ -93,14 +93,12 @@ public class SearchLibraryPutInHandEffect extends SearchEffect { if (target.getTargets().size() > 0) { Cards cards = new CardsImpl(); for (UUID cardId : target.getTargets()) { - Card card = controller.getLibrary().remove(cardId, game); + Card card = game.getCard(cardId); if (card != null) { - controller.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY, revealCards); - if (revealCards) { - cards.add(card); - } + cards.add(card); } } + controller.moveCards(cards, null, Zone.HAND, source, game); if (revealCards) { String name = "Reveal"; Card sourceCard = game.getCard(source.getSourceId()); diff --git a/Mage/src/mage/abilities/effects/common/turn/SkipNextTurnSourceEffect.java b/Mage/src/mage/abilities/effects/common/turn/SkipNextTurnSourceEffect.java index ff1431ad21f..511a0f1c388 100644 --- a/Mage/src/mage/abilities/effects/common/turn/SkipNextTurnSourceEffect.java +++ b/Mage/src/mage/abilities/effects/common/turn/SkipNextTurnSourceEffect.java @@ -10,20 +10,29 @@ import mage.abilities.effects.OneShotEffect; import mage.constants.Outcome; import mage.game.Game; import mage.game.turn.TurnMod; +import mage.util.CardUtil; /** * * @author Mael */ public class SkipNextTurnSourceEffect extends OneShotEffect { - + + int numberOfTurns; + public SkipNextTurnSourceEffect() { + this(1); + } + + public SkipNextTurnSourceEffect(int numberOfTurns) { super(Outcome.Neutral); - staticText = "You skip your next turn"; + this.numberOfTurns = numberOfTurns; + staticText = "you skip your next " + (numberOfTurns == 1 ? "turn" : CardUtil.numberToText(numberOfTurns) + " turns"); } public SkipNextTurnSourceEffect(final SkipNextTurnSourceEffect effect) { super(effect); + this.numberOfTurns = effect.numberOfTurns; } @Override @@ -33,7 +42,9 @@ public class SkipNextTurnSourceEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - game.getState().getTurnMods().add(new TurnMod(source.getControllerId(), true)); + for (int i = 0; i < numberOfTurns; i++) { + game.getState().getTurnMods().add(new TurnMod(source.getControllerId(), true)); + } return true; } } diff --git a/Mage/src/mage/abilities/effects/keyword/FatesealEffect.java b/Mage/src/mage/abilities/effects/keyword/FatesealEffect.java index beb7165fb05..4d19f86b4f4 100644 --- a/Mage/src/mage/abilities/effects/keyword/FatesealEffect.java +++ b/Mage/src/mage/abilities/effects/keyword/FatesealEffect.java @@ -90,7 +90,7 @@ public class FatesealEffect extends OneShotEffect { target1.setRequired(false); // move cards to the bottom of the library while (cards.size() > 0 && controller.choose(Outcome.Detriment, cards, target1, game)) { - if (!controller.isInGame() || !opponent.isInGame()) { + if (!controller.canRespond() || !opponent.canRespond()) { return false; } Card card = cards.get(target1.getFirstTarget(), game); diff --git a/Mage/src/mage/abilities/effects/keyword/ManifestEffect.java b/Mage/src/mage/abilities/effects/keyword/ManifestEffect.java index 7fbb96ce7cd..71e6293628d 100644 --- a/Mage/src/mage/abilities/effects/keyword/ManifestEffect.java +++ b/Mage/src/mage/abilities/effects/keyword/ManifestEffect.java @@ -27,7 +27,7 @@ */ package mage.abilities.effects.keyword; -import java.util.List; +import java.util.Set; import mage.MageObjectReference; import mage.abilities.Ability; import mage.abilities.costs.mana.ManaCosts; @@ -53,7 +53,7 @@ public class ManifestEffect extends OneShotEffect { private final int amount; - public ManifestEffect(int amount) { + public ManifestEffect(int amount) { super(Outcome.PutCreatureInPlay); this.amount = amount; this.staticText = setText(); @@ -75,8 +75,8 @@ public class ManifestEffect extends OneShotEffect { if (controller != null) { Ability newSource = source.copy(); newSource.setWorksFaceDown(true); - List cards = controller.getLibrary().getTopCards(game, amount); - for (Card card: cards) { + Set cards = controller.getLibrary().getTopCards(game, amount); + for (Card card : cards) { ManaCosts manaCosts = null; if (card.getCardType().contains(CardType.CREATURE)) { manaCosts = card.getSpellAbility().getManaCosts(); @@ -84,7 +84,7 @@ public class ManifestEffect extends OneShotEffect { manaCosts = new ManaCostsImpl("{0}"); } } - MageObjectReference objectReference= new MageObjectReference(card.getId(), card.getZoneChangeCounter(game) +1, game); + MageObjectReference objectReference = new MageObjectReference(card.getId(), card.getZoneChangeCounter(game) + 1, game); game.addEffect(new BecomesFaceDownCreatureEffect(manaCosts, objectReference, Duration.Custom, FaceDownType.MANIFESTED), newSource); controller.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, newSource.getSourceId(), false, true); Permanent permanent = game.getPermanent(card.getId()); diff --git a/Mage/src/mage/abilities/effects/keyword/ManifestTargetPlayerEffect.java b/Mage/src/mage/abilities/effects/keyword/ManifestTargetPlayerEffect.java index f860993f4a4..897ff83f235 100644 --- a/Mage/src/mage/abilities/effects/keyword/ManifestTargetPlayerEffect.java +++ b/Mage/src/mage/abilities/effects/keyword/ManifestTargetPlayerEffect.java @@ -27,12 +27,11 @@ */ package mage.abilities.effects.keyword; -import java.util.List; +import java.util.Set; import mage.MageObjectReference; import mage.abilities.Ability; import mage.abilities.costs.mana.ManaCosts; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.ContinuousEffect; import mage.abilities.effects.OneShotEffect; import mage.abilities.effects.common.continuous.BecomesFaceDownCreatureEffect; import mage.abilities.effects.common.continuous.BecomesFaceDownCreatureEffect.FaceDownType; @@ -44,20 +43,18 @@ import mage.constants.Zone; import mage.game.Game; import mage.game.permanent.Permanent; import mage.players.Player; -import mage.target.targetpointer.FixedTarget; import mage.util.CardUtil; /** * * @author LevelX2 */ - public class ManifestTargetPlayerEffect extends OneShotEffect { private final int amount; private final String prefix; - public ManifestTargetPlayerEffect(int amount, String prefix) { + public ManifestTargetPlayerEffect(int amount, String prefix) { super(Outcome.PutCreatureInPlay); this.amount = amount; this.prefix = prefix; @@ -81,8 +78,8 @@ public class ManifestTargetPlayerEffect extends OneShotEffect { if (targetPlayer != null) { Ability newSource = source.copy(); newSource.setWorksFaceDown(true); - List cards = targetPlayer.getLibrary().getTopCards(game, amount); - for (Card card: cards) { + Set cards = targetPlayer.getLibrary().getTopCards(game, amount); + for (Card card : cards) { ManaCosts manaCosts = null; if (card.getCardType().contains(CardType.CREATURE)) { manaCosts = card.getSpellAbility().getManaCosts(); @@ -90,13 +87,13 @@ public class ManifestTargetPlayerEffect extends OneShotEffect { manaCosts = new ManaCostsImpl("{0}"); } } - MageObjectReference objectReference= new MageObjectReference(card.getId(), card.getZoneChangeCounter(game) +1, game); - game.addEffect(new BecomesFaceDownCreatureEffect(manaCosts, objectReference, Duration.Custom, FaceDownType.MANIFESTED), newSource); + MageObjectReference objectReference = new MageObjectReference(card.getId(), card.getZoneChangeCounter(game) + 1, game); + game.addEffect(new BecomesFaceDownCreatureEffect(manaCosts, objectReference, Duration.Custom, FaceDownType.MANIFESTED), newSource); targetPlayer.putOntoBattlefieldWithInfo(card, game, Zone.LIBRARY, newSource.getSourceId(), false, true); Permanent permanent = game.getPermanent(card.getId()); if (permanent != null) { permanent.setManifested(true); - } + } } return true; } diff --git a/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorAttachedEffect.java b/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorAttachedEffect.java new file mode 100644 index 00000000000..dd363575cef --- /dev/null +++ b/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorAttachedEffect.java @@ -0,0 +1,98 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.keyword; + +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.keyword.ProtectionAbility; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; +import mage.filter.FilterObject; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author LevelX2 + */ +public class ProtectionChosenColorAttachedEffect extends ContinuousEffectImpl { + + protected ObjectColor chosenColor; + protected ProtectionAbility protectionAbility; + protected boolean notRemoveItself; + + public ProtectionChosenColorAttachedEffect(boolean notRemoveItself) { + super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); + this.notRemoveItself = notRemoveItself; + staticText = "{source} has protection from the chosen color" + (notRemoveItself ? ". This effect doesn't remove {this}" : ""); + } + + public ProtectionChosenColorAttachedEffect(final ProtectionChosenColorAttachedEffect effect) { + super(effect); + if (effect.chosenColor != null) { + this.chosenColor = effect.chosenColor.copy(); + } + if (effect.protectionAbility != null) { + this.protectionAbility = effect.protectionAbility.copy(); + } + } + + @Override + public ProtectionChosenColorAttachedEffect copy() { + return new ProtectionChosenColorAttachedEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent attachement = game.getPermanent(source.getSourceId()); + if (attachement != null && attachement.getAttachedTo() != null) { + ObjectColor color = (ObjectColor) game.getState().getValue(attachement.getId() + "_color"); + if (color != null && (protectionAbility == null || !color.equals(chosenColor))) { + chosenColor = color; + FilterObject protectionFilter = new FilterObject(chosenColor.getDescription()); + protectionFilter.add(new ColorPredicate(chosenColor)); + protectionAbility = new ProtectionAbility(protectionFilter); + if (notRemoveItself) { + protectionAbility.setAuraIdNotToBeRemoved(source.getSourceId()); + } + } + if (protectionAbility != null) { + Permanent attachedTo = game.getPermanent(attachement.getAttachedTo()); + if (attachedTo != null) { + attachedTo.addAbility(protectionAbility, source.getSourceId(), game); + } + return true; + } + } + return false; + } +} diff --git a/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorSourceEffect.java b/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorSourceEffect.java new file mode 100644 index 00000000000..3674579d581 --- /dev/null +++ b/Mage/src/mage/abilities/effects/keyword/ProtectionChosenColorSourceEffect.java @@ -0,0 +1,90 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.effects.keyword; + +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.effects.ContinuousEffectImpl; +import mage.abilities.keyword.ProtectionAbility; +import mage.constants.Duration; +import mage.constants.Layer; +import mage.constants.Outcome; +import mage.constants.SubLayer; +import mage.filter.FilterObject; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author LevelX2 + */ +public class ProtectionChosenColorSourceEffect extends ContinuousEffectImpl { + + protected ObjectColor chosenColor; + protected ProtectionAbility protectionAbility; + + public ProtectionChosenColorSourceEffect() { + super(Duration.WhileOnBattlefield, Layer.AbilityAddingRemovingEffects_6, SubLayer.NA, Outcome.AddAbility); + staticText = "{source} has protection from the chosen color"; + } + + public ProtectionChosenColorSourceEffect(final ProtectionChosenColorSourceEffect effect) { + super(effect); + if (effect.chosenColor != null) { + this.chosenColor = effect.chosenColor.copy(); + } + if (effect.protectionAbility != null) { + this.protectionAbility = effect.protectionAbility.copy(); + } + } + + @Override + public ProtectionChosenColorSourceEffect copy() { + return new ProtectionChosenColorSourceEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Permanent permanent = game.getPermanent(source.getSourceId()); + if (permanent != null) { + ObjectColor color = (ObjectColor) game.getState().getValue(permanent.getId() + "_color"); + if (color != null && (protectionAbility == null || !color.equals(chosenColor))) { + chosenColor = color; + FilterObject protectionFilter = new FilterObject(chosenColor.getDescription()); + protectionFilter.add(new ColorPredicate(chosenColor)); + protectionAbility = new ProtectionAbility(protectionFilter); + } + if (protectionAbility != null) { + permanent.addAbility(protectionAbility, source.getSourceId(), game); + return true; + } + } + return false; + } +} diff --git a/Mage/src/mage/abilities/effects/keyword/ScryEffect.java b/Mage/src/mage/abilities/effects/keyword/ScryEffect.java index 2bcb26468aa..0fc7e4ad760 100644 --- a/Mage/src/mage/abilities/effects/keyword/ScryEffect.java +++ b/Mage/src/mage/abilities/effects/keyword/ScryEffect.java @@ -81,7 +81,7 @@ public class ScryEffect extends OneShotEffect { TargetCard target1 = new TargetCard(Zone.LIBRARY, filter1); target1.setRequired(false); // move cards to the bottom of the library - while (player.isInGame() && cards.size() > 0 && player.choose(Outcome.Detriment, cards, target1, game)) { + while (player.canRespond() && cards.size() > 0 && player.choose(Outcome.Detriment, cards, target1, game)) { Card card = cards.get(target1.getFirstTarget(), game); if (card != null) { cards.remove(card); diff --git a/Mage/src/mage/abilities/effects/keyword/SweepEffect.java b/Mage/src/mage/abilities/effects/keyword/SweepEffect.java index 01b10693559..5e3fc1f3d48 100644 --- a/Mage/src/mage/abilities/effects/keyword/SweepEffect.java +++ b/Mage/src/mage/abilities/effects/keyword/SweepEffect.java @@ -27,16 +27,15 @@ */ package mage.abilities.effects.keyword; -import java.util.UUID; import mage.abilities.Ability; import mage.abilities.effects.OneShotEffect; +import mage.cards.CardsImpl; import mage.constants.Outcome; import mage.constants.Zone; import mage.filter.FilterPermanent; import mage.filter.common.FilterControlledLandPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; import mage.game.Game; -import mage.game.permanent.Permanent; import mage.players.Player; import mage.target.Target; import mage.target.TargetPermanent; @@ -53,7 +52,7 @@ public class SweepEffect extends OneShotEffect { public SweepEffect(String sweepSubtype) { super(Outcome.Benefit); this.sweepSubtype = sweepSubtype; - this.staticText = "Sweep - Return any number of "+ sweepSubtype + (sweepSubtype.endsWith("s") ? "":"s") + " you control to their owner's hand"; + this.staticText = "Sweep - Return any number of " + sweepSubtype + (sweepSubtype.endsWith("s") ? "" : "s") + " you control to their owner's hand"; } public SweepEffect(final SweepEffect effect) { @@ -75,10 +74,7 @@ public class SweepEffect extends OneShotEffect { Target target = new TargetPermanent(0, Integer.MAX_VALUE, filter, true); if (controller.chooseTarget(outcome, target, source, game)) { game.getState().setValue(CardUtil.getCardZoneString("sweep", source.getSourceId(), game), target.getTargets().size()); - for (UUID uuid : target.getTargets()) { - Permanent land = game.getPermanent(uuid); - controller.moveCardToHandWithInfo(land, source.getSourceId(), game, Zone.HAND); - } + controller.moveCards(new CardsImpl(target.getTargets()), null, Zone.HAND, source, game); } return true; } diff --git a/Mage/src/mage/abilities/keyword/AnnihilatorAbility.java b/Mage/src/mage/abilities/keyword/AnnihilatorAbility.java index 548d64cd76c..7a43a5711c8 100644 --- a/Mage/src/mage/abilities/keyword/AnnihilatorAbility.java +++ b/Mage/src/mage/abilities/keyword/AnnihilatorAbility.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -79,7 +79,7 @@ public class AnnihilatorAbility extends TriggeredAbilityImpl { UUID defendingPlayerId = game.getCombat().getDefendingPlayerId(sourceId, game); if (defendingPlayerId != null) { // the id has to be set here because the source can be leave battlefield - for(Effect effect : getEffects()) { + for (Effect effect : getEffects()) { effect.setValue("defendingPlayerId", defendingPlayerId); } return true; @@ -90,8 +90,8 @@ public class AnnihilatorAbility extends TriggeredAbilityImpl { @Override public String getRule() { - return "Annihilator " + count + "(Whenever this creature attacks, defending player sacrifices " + - (count == 1 ? "a permanent": CardUtil.numberToText(count) + " permanents") + ".)"; + return "Annihilator " + count + "(Whenever this creature attacks, defending player sacrifices " + + (count == 1 ? "a permanent" : CardUtil.numberToText(count) + " permanents") + ".)"; } @Override @@ -121,17 +121,17 @@ class AnnihilatorEffect extends OneShotEffect { UUID defendingPlayerId = (UUID) getValue("defendingPlayerId"); Player player = null; if (defendingPlayerId != null) { - player= game.getPlayer(defendingPlayerId); + player = game.getPlayer(defendingPlayerId); } if (player != null) { int amount = Math.min(count, game.getBattlefield().countAll(filter, player.getId(), game)); - Target target = new TargetControlledPermanent(amount, amount, filter, false); + Target target = new TargetControlledPermanent(amount, amount, filter, true); if (target.canChoose(player.getId(), game)) { - while (!target.isChosen() && target.canChoose(player.getId(), game) && player.isInGame()) { + while (!target.isChosen() && target.canChoose(player.getId(), game) && player.canRespond()) { player.choose(Outcome.Sacrifice, target, source.getSourceId(), game); } for (int idx = 0; idx < target.getTargets().size(); idx++) { - Permanent permanent = game.getPermanent((UUID) target.getTargets().get(idx)); + Permanent permanent = game.getPermanent(target.getTargets().get(idx)); if (permanent != null) { permanent.sacrifice(source.getSourceId(), game); } diff --git a/Mage/src/mage/abilities/keyword/AuraSwapAbility.java b/Mage/src/mage/abilities/keyword/AuraSwapAbility.java index d4590bec685..ea4ddd1a6aa 100644 --- a/Mage/src/mage/abilities/keyword/AuraSwapAbility.java +++ b/Mage/src/mage/abilities/keyword/AuraSwapAbility.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.keyword; import mage.abilities.Ability; @@ -48,21 +47,21 @@ import mage.target.common.TargetCardInHand; * @author Mael */ public class AuraSwapAbility extends ActivatedAbilityImpl { - + public AuraSwapAbility(ManaCost manaCost) { super(Zone.BATTLEFIELD, new AuraSwapEffect(), manaCost); - + } - + public AuraSwapAbility(final AuraSwapAbility ability) { super(ability); } - + @Override public AuraSwapAbility copy() { return new AuraSwapAbility(this); } - + @Override public String getRule() { return new StringBuilder("Aura swap ").append(getManaCostsToPay().getText()).append(" (") @@ -72,42 +71,42 @@ public class AuraSwapAbility extends ActivatedAbilityImpl { } class AuraSwapEffect extends OneShotEffect { - + private static final FilterCard filter = new FilterCard(); - + static { filter.add(new SubtypePredicate("Aura")); } - + AuraSwapEffect() { super(Outcome.PutCardInPlay); this.staticText = "Exchange this Aura with an Aura card in your hand."; } - + AuraSwapEffect(final AuraSwapEffect effect) { super(effect); } - + @Override public AuraSwapEffect copy() { return new AuraSwapEffect(this); } - + @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - if (player != null) { + Player controller = game.getPlayer(source.getControllerId()); + if (controller != null) { Permanent auraPermanent = game.getPermanent(source.getSourceId()); if (auraPermanent != null && auraPermanent.getSubtype().contains("Aura") && auraPermanent.getOwnerId().equals(source.getControllerId())) { Permanent enchantedPermanent = game.getPermanent(auraPermanent.getAttachedTo()); filter.add(new AuraCardCanAttachToPermanentId(enchantedPermanent.getId())); TargetCardInHand target = new TargetCardInHand(0, 1, filter); - if (player.choose(Outcome.PutCardInPlay, target, source.getSourceId(), game)) { + if (controller.choose(Outcome.PutCardInPlay, target, source.getSourceId(), game)) { Card auraInHand = game.getCard(target.getFirstTarget()); if (auraInHand != null) { - player.putOntoBattlefieldWithInfo(auraInHand, game, Zone.HAND, source.getSourceId()); + controller.putOntoBattlefieldWithInfo(auraInHand, game, Zone.HAND, source.getSourceId()); enchantedPermanent.addAttachment(auraInHand.getId(), game); - player.moveCardToHandWithInfo(auraPermanent, source.getSourceId(), game, Zone.BATTLEFIELD); + controller.moveCards(auraPermanent, null, Zone.HAND, source, game); return true; } } diff --git a/Mage/src/mage/abilities/keyword/BushidoAbility.java b/Mage/src/mage/abilities/keyword/BushidoAbility.java index 30b239ece1a..3d51c036986 100644 --- a/Mage/src/mage/abilities/keyword/BushidoAbility.java +++ b/Mage/src/mage/abilities/keyword/BushidoAbility.java @@ -55,7 +55,7 @@ public class BushidoAbility extends BlocksOrBecomesBlockedTriggeredAbility { } static String getReminder(String xValue) { - return " (When this blocks or becomes blocked, it gets +" + xValue+ "/+" + xValue + " until end of turn.)"; + return " (Whenever this creature blocks or becomes blocked, it gets +" + xValue+ "/+" + xValue + " until end of turn.)"; } public BushidoAbility(final BushidoAbility ability) { diff --git a/Mage/src/mage/abilities/keyword/BuybackAbility.java b/Mage/src/mage/abilities/keyword/BuybackAbility.java index 321a7de0a80..b6981811892 100644 --- a/Mage/src/mage/abilities/keyword/BuybackAbility.java +++ b/Mage/src/mage/abilities/keyword/BuybackAbility.java @@ -96,6 +96,7 @@ public class BuybackAbility extends StaticAbility implements OptionalAdditionalS } } + @Override public boolean isActivated() { if (buybackCost != null) { return buybackCost.isActivated(); @@ -112,11 +113,11 @@ public class BuybackAbility extends StaticAbility implements OptionalAdditionalS @Override public void addOptionalAdditionalCosts(Ability ability, Game game) { if (ability instanceof SpellAbility) { - Player player = game.getPlayer(controllerId); + Player player = game.getPlayer(ability.getControllerId()); if (player != null) { this.resetBuyback(); if (buybackCost != null) { - if (player.chooseUse(Outcome.Benefit, new StringBuilder("Pay ").append(buybackCost.getText(false)).append(" ?").toString(), ability, game)) { + if (player.chooseUse(Outcome.Benefit, "Pay " + buybackCost.getText(false) + " ?", ability, game)) { buybackCost.activate(); for (Iterator it = ((Costs) buybackCost).iterator(); it.hasNext();) { Cost cost = (Cost) it.next(); diff --git a/Mage/src/mage/abilities/keyword/ChampionAbility.java b/Mage/src/mage/abilities/keyword/ChampionAbility.java index b020ee46945..568a1ef9463 100644 --- a/Mage/src/mage/abilities/keyword/ChampionAbility.java +++ b/Mage/src/mage/abilities/keyword/ChampionAbility.java @@ -68,42 +68,53 @@ import mage.util.CardUtil; * the former as the direct result of a champion ability. # * */ - public class ChampionAbility extends StaticAbility { protected String[] subtypes; protected String objectDescription; - public ChampionAbility(Card card, String subtype) { this(card, new String[]{subtype}); } - + + /** + * Champion one or more creature types or if the subtype array is empty + * champion every creature. + * + * @param card + * @param subtypes subtypes to champion with, if empty all creatures can be + * used + */ public ChampionAbility(Card card, String[] subtypes) { super(Zone.BATTLEFIELD, null); this.subtypes = subtypes; - StringBuilder sb = new StringBuilder("another "); ArrayList> subtypesPredicates = new ArrayList<>(); - int i = 0; - for (String subtype : this.subtypes) { - subtypesPredicates.add(new SubtypePredicate(subtype)); - if (i == 0) { - sb.append(subtype); - } else { - sb.append(" or ").append(subtype); + if (!subtypes[0].isEmpty()) { + int i = 0; + for (String subtype : this.subtypes) { + subtypesPredicates.add(new SubtypePredicate(subtype)); + if (i == 0) { + sb.append(subtype); + } else { + sb.append(" or ").append(subtype); + } + i++; } - i++; + } else { + sb.append("creature"); } this.objectDescription = sb.toString(); FilterControlledPermanent filter = new FilterControlledPermanent(objectDescription); - filter.add(Predicates.or(subtypesPredicates)); + if (!subtypesPredicates.isEmpty()) { + filter.add(Predicates.or(subtypesPredicates)); + } filter.add(new AnotherPredicate()); // When this permanent enters the battlefield, sacrifice it unless you exile another [object] you control. Ability ability1 = new EntersBattlefieldTriggeredAbility( - new SacrificeSourceUnlessPaysEffect(new ChampionExileCost(filter, new StringBuilder(card.getName()).append(" championed permanents").toString())),false); + new SacrificeSourceUnlessPaysEffect(new ChampionExileCost(filter, new StringBuilder(card.getName()).append(" championed permanents").toString())), false); ability1.setRuleVisible(false); addSubAbility(ability1); @@ -139,7 +150,7 @@ class ChampionExileCost extends CostImpl { private String exileZone = null; public ChampionExileCost(FilterControlledPermanent filter, String exileZone) { - this.addTarget(new TargetControlledPermanent(1,1,filter, true)); + this.addTarget(new TargetControlledPermanent(1, 1, filter, true)); this.text = "exile " + filter.getMessage() + " you control"; this.exileZone = exileZone; } @@ -152,11 +163,11 @@ class ChampionExileCost extends CostImpl { @Override public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { Player controller = game.getPlayer(controllerId); - MageObject sourceObject = ability.getSourceObject(game); + MageObject sourceObject = ability.getSourceObject(game); if (controller != null && sourceObject != null) { if (targets.choose(Outcome.Exile, controllerId, sourceId, game)) { UUID exileId = CardUtil.getExileZoneId(game, ability.getSourceId(), ability.getSourceObjectZoneChangeCounter()); - for (UUID targetId: targets.get(0).getTargets()) { + for (UUID targetId : targets.get(0).getTargets()) { Permanent permanent = game.getPermanent(targetId); if (permanent == null) { return false; diff --git a/Mage/src/mage/abilities/keyword/ChangelingAbility.java b/Mage/src/mage/abilities/keyword/ChangelingAbility.java index f36020d1bf6..94fb1debb65 100644 --- a/Mage/src/mage/abilities/keyword/ChangelingAbility.java +++ b/Mage/src/mage/abilities/keyword/ChangelingAbility.java @@ -29,9 +29,9 @@ package mage.abilities.keyword; import java.io.ObjectStreamException; -import mage.constants.Zone; import mage.abilities.MageSingleton; import mage.abilities.StaticAbility; +import mage.constants.Zone; /** @@ -61,7 +61,7 @@ public class ChangelingAbility extends StaticAbility implements MageSingleton { @Override public String getRule() { - return "Changeling (This card is every creature type at all times.)"; + return "Changeling (This card is every creature type.)"; } @Override diff --git a/Mage/src/mage/abilities/keyword/ConvokeAbility.java b/Mage/src/mage/abilities/keyword/ConvokeAbility.java index ef920d57d42..aac3ab7ab74 100644 --- a/Mage/src/mage/abilities/keyword/ConvokeAbility.java +++ b/Mage/src/mage/abilities/keyword/ConvokeAbility.java @@ -214,7 +214,7 @@ class ConvokeEffect extends OneShotEffect { chooseManaType.setMessage("Choose mana color to reduce from " + perm.getName()); while (!chooseManaType.isChosen()) { controller.choose(Outcome.Benefit, chooseManaType, game); - if (!controller.isInGame()) { + if (!controller.canRespond()) { return false; } } diff --git a/Mage/src/mage/abilities/keyword/ForecastAbility.java b/Mage/src/mage/abilities/keyword/ForecastAbility.java index eba53827b62..43ba532aae3 100644 --- a/Mage/src/mage/abilities/keyword/ForecastAbility.java +++ b/Mage/src/mage/abilities/keyword/ForecastAbility.java @@ -70,6 +70,7 @@ public class ForecastAbility extends LimitedTimesPerTurnActivatedAbility { @Override public boolean canActivate(UUID playerId, Game game) { // May be activated only during the upkeep step of the card's owner + // Because it can only be activated from a players hand it should be ok to check here with controllerId instead of card.getOwnerId(). if (!game.getActivePlayerId().equals(controllerId) || !PhaseStep.UPKEEP.equals(game.getStep().getType())) { return false; } diff --git a/Mage/src/mage/abilities/keyword/KickerAbility.java b/Mage/src/mage/abilities/keyword/KickerAbility.java index 48d33e124b9..d28edb5307c 100644 --- a/Mage/src/mage/abilities/keyword/KickerAbility.java +++ b/Mage/src/mage/abilities/keyword/KickerAbility.java @@ -37,10 +37,12 @@ import mage.abilities.SpellAbility; import mage.abilities.StaticAbility; import mage.abilities.costs.Cost; import mage.abilities.costs.Costs; +import mage.abilities.costs.CostsImpl; import mage.abilities.costs.OptionalAdditionalCost; import mage.abilities.costs.OptionalAdditionalCostImpl; import mage.abilities.costs.OptionalAdditionalSourceCosts; import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.costs.mana.ManaCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.costs.mana.VariableManaCost; import mage.constants.AbilityType; @@ -142,6 +144,13 @@ public class KickerAbility extends StaticAbility implements OptionalAdditionalSo for (OptionalAdditionalCost cost : kickerCosts) { cost.reset(); } + String key = getActivationKey(source, "", game); + for (String activationKey : activations.keySet()) { + if (activationKey.startsWith(key) && activations.get(activationKey) > 0) { + activations.put(key, 0); + } + } + } public int getXManaValue() { @@ -158,8 +167,17 @@ public class KickerAbility extends StaticAbility implements OptionalAdditionalSo public boolean isKicked(Game game, Ability source, String costText) { String key = getActivationKey(source, costText, game); - if (activations.containsKey(key)) { - return activations.get(key) > 0; + if (kickerCosts.size() > 1) { + for (String activationKey : activations.keySet()) { + if (activationKey.startsWith(key) && activations.get(activationKey) > 0) { + return true; + } + } + } else { + if (activations.containsKey(key)) { + return activations.get(key) > 0; + + } } return false; } @@ -199,7 +217,7 @@ public class KickerAbility extends StaticAbility implements OptionalAdditionalSo this.resetKicker(game, ability); for (OptionalAdditionalCost kickerCost : kickerCosts) { boolean again = true; - while (player.isInGame() && again) { + while (player.canRespond() && again) { String times = ""; if (kickerCost.isRepeatable()) { int activatedCount = getKickedCounter(game, ability); @@ -208,26 +226,20 @@ public class KickerAbility extends StaticAbility implements OptionalAdditionalSo if (kickerCost.canPay(ability, sourceId, controllerId, game) && player.chooseUse(Outcome.Benefit, "Pay " + times + kickerCost.getText(false) + " ?", ability, game)) { this.activateKicker(kickerCost, ability, game); - for (Iterator it = ((Costs) kickerCost).iterator(); it.hasNext();) { - Cost cost = (Cost) it.next(); - if (cost instanceof ManaCostsImpl) { - List varCosts = ((ManaCostsImpl) cost).getVariableCosts(); - if (!varCosts.isEmpty()) { - // use only first variable cost - xManaValue = game.getPlayer(this.controllerId).announceXMana(varCosts.get(0).getMinX(), Integer.MAX_VALUE, "Announce kicker value for " + varCosts.get(0).getText(), game, this); - // kicker variable X costs handled internally as multikicker with {1} cost (no multikicker on card) - if (!game.isSimulation()) { - game.informPlayers(game.getPlayer(this.controllerId).getLogName() + " announced a value of " + xManaValue + " for " + " kicker X "); + if (kickerCost instanceof Costs) { + for (Iterator itKickerCost = ((Costs) kickerCost).iterator(); itKickerCost.hasNext();) { + Object kickerCostObject = itKickerCost.next(); + if ((kickerCostObject instanceof Costs) || (kickerCostObject instanceof CostsImpl)) { + for (@SuppressWarnings("unchecked") Iterator itDetails = ((Costs) kickerCostObject).iterator(); itDetails.hasNext();) { + addKickerCostsToAbility(itDetails.next(), ability, game); } - ability.getManaCostsToPay().add(new GenericManaCost(xManaValue)); } else { - ability.getManaCostsToPay().add((ManaCostsImpl) cost.copy()); + addKickerCostsToAbility((Cost) kickerCostObject, ability, game); } - } else { - ability.getCosts().add(cost.copy()); } + } else { + addKickerCostsToAbility((Cost) kickerCost, ability, game); } - again = kickerCost.isRepeatable(); } else { again = false; @@ -238,6 +250,32 @@ public class KickerAbility extends StaticAbility implements OptionalAdditionalSo } } + private void addKickerCostsToAbility(Cost cost, Ability ability, Game game) { + if (cost instanceof ManaCostsImpl) { + @SuppressWarnings("unchecked") + List varCosts = ((ManaCostsImpl) cost).getVariableCosts(); + if (!varCosts.isEmpty()) { + // use only first variable cost + xManaValue = game.getPlayer(this.controllerId).announceXMana(varCosts.get(0).getMinX(), Integer.MAX_VALUE, "Announce kicker value for " + varCosts.get(0).getText(), game, this); + // kicker variable X costs handled internally as multikicker with {1} cost (no multikicker on card) + if (!game.isSimulation()) { + game.informPlayers(game.getPlayer(this.controllerId).getLogName() + " announced a value of " + xManaValue + " for " + " kicker X "); + } + ability.getManaCostsToPay().add(new GenericManaCost(xManaValue)); + ManaCostsImpl kickerManaCosts = (ManaCostsImpl) cost; + for (ManaCost manaCost : kickerManaCosts) { + if (!(manaCost instanceof VariableManaCost)) { + ability.getManaCostsToPay().add(manaCost.copy()); + } + } + } else { + ability.getManaCostsToPay().add((ManaCostsImpl) cost.copy()); + } + } else { + ability.getCosts().add(cost.copy()); + } + } + @Override public String getRule() { StringBuilder sb = new StringBuilder(); diff --git a/Mage/src/mage/abilities/keyword/ProtectionAbility.java b/Mage/src/mage/abilities/keyword/ProtectionAbility.java index 1cf4a57b8cc..3cacac49811 100644 --- a/Mage/src/mage/abilities/keyword/ProtectionAbility.java +++ b/Mage/src/mage/abilities/keyword/ProtectionAbility.java @@ -1,33 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.keyword; +import java.util.UUID; import mage.MageObject; import mage.abilities.StaticAbility; import mage.cards.Card; @@ -49,17 +49,20 @@ public class ProtectionAbility extends StaticAbility { protected Filter filter; protected boolean removeAuras; + protected UUID auraIdNotToBeRemoved; // defines an Aura objectId that will not be removed from this protection ability public ProtectionAbility(Filter filter) { super(Zone.BATTLEFIELD, null); this.filter = filter; this.removeAuras = true; + this.auraIdNotToBeRemoved = null; } public ProtectionAbility(final ProtectionAbility ability) { super(ability); this.filter = ability.filter.copy(); this.removeAuras = ability.removeAuras; + this.auraIdNotToBeRemoved = ability.auraIdNotToBeRemoved; } @Override @@ -69,7 +72,8 @@ public class ProtectionAbility extends StaticAbility { @Override public String getRule() { - return "Protection from " + filter.getMessage() + (removeAuras ? "":". This effect doesn't remove auras."); + + return "Protection from " + filter.getMessage() + (removeAuras ? "" : ". This effect doesn't remove auras."); } public boolean canTarget(MageObject source, Game game) { @@ -112,4 +116,13 @@ public class ProtectionAbility extends StaticAbility { public boolean removesAuras() { return removeAuras; } + + public UUID getAuraIdNotToBeRemoved() { + return auraIdNotToBeRemoved; + } + + public void setAuraIdNotToBeRemoved(UUID auraIdNotToBeRemoved) { + this.auraIdNotToBeRemoved = auraIdNotToBeRemoved; + } + } diff --git a/Mage/src/mage/abilities/keyword/ProvokeAbility.java b/Mage/src/mage/abilities/keyword/ProvokeAbility.java index 595d85a4a49..94b4c53f65d 100644 --- a/Mage/src/mage/abilities/keyword/ProvokeAbility.java +++ b/Mage/src/mage/abilities/keyword/ProvokeAbility.java @@ -55,7 +55,7 @@ import mage.target.common.TargetCreaturePermanent; public class ProvokeAbility extends AttacksTriggeredAbility { public ProvokeAbility() { - super(new UntapTargetEffect(), true, "Provoke (When this attacks, you may have target creature defending player controls untap and block it if able.)"); + super(new UntapTargetEffect(), true, "Provoke (Whenever this attacks, you may have target creature defending player controls untap and block it if able.)"); this.addEffect(new ProvokeRequirementEffect()); } diff --git a/Mage/src/mage/abilities/keyword/RecoverAbility.java b/Mage/src/mage/abilities/keyword/RecoverAbility.java new file mode 100644 index 00000000000..bd8cbb938d3 --- /dev/null +++ b/Mage/src/mage/abilities/keyword/RecoverAbility.java @@ -0,0 +1,144 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.abilities.keyword; + +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.costs.Cost; +import mage.abilities.costs.mana.ManaCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.ExileSourceEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.cards.Card; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.events.ZoneChangeEvent; +import mage.players.Player; + +/** + * 702.58a Recover is a triggered ability that functions only while the card + * with recover is in a player’s graveyard. “Recover [cost]” means “When a + * creature is put into your graveyard from the battlefield, you may pay [cost]. + * If you do, return this card from your graveyard to your hand. Otherwise, + * exile this card.” + * + * @author LevelX2 + */ +public class RecoverAbility extends TriggeredAbilityImpl { + + public RecoverAbility(Cost cost, Card card) { + super(Zone.GRAVEYARD, new RecoverEffect(cost, card.getCardType().contains(CardType.CREATURE)), false); + } + + public RecoverAbility(final RecoverAbility ability) { + super(ability); + } + + @Override + public RecoverAbility copy() { + return new RecoverAbility(this); + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.ZONE_CHANGE; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + ZoneChangeEvent zEvent = (ZoneChangeEvent) event; + if (zEvent.getFromZone().equals(Zone.BATTLEFIELD) && zEvent.getToZone().equals(Zone.GRAVEYARD)) { + if (zEvent.getTarget().getOwnerId().equals(getControllerId()) + && zEvent.getTarget().getCardType().contains(CardType.CREATURE) + && !zEvent.getTarget().getId().equals(getSourceId())) { + return true; + } + } + return false; + } + + @Override + public String getRule() { + return super.getRule(); + } +} + +class RecoverEffect extends OneShotEffect { + + protected Cost cost; + + public RecoverEffect(Cost cost, boolean creature) { + super(Outcome.ReturnToHand); + this.cost = cost; + this.staticText = setText(cost, creature); + } + + public RecoverEffect(final RecoverEffect effect) { + super(effect); + this.cost = effect.cost; + } + + @Override + public RecoverEffect copy() { + return new RecoverEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + Card sourceCard = game.getCard(source.getSourceId()); + if (controller != null && sourceCard != null + && game.getState().getZone(source.getSourceId()).equals(Zone.GRAVEYARD)) { + if (controller.chooseUse(Outcome.Damage, "Pay " + cost.getText() + " to recover " + sourceCard.getLogName() + "? (Otherwise the card will be exiled)", source, game)) { + cost.clearPaid(); + if (cost.pay(source, game, source.getSourceId(), controller.getId(), false)) { + return new ReturnToHandSourceEffect().apply(game, source); + } + } + return new ExileSourceEffect().apply(game, source); + } + return false; + } + + private String setText(Cost cost, boolean creature) { + StringBuilder sb = new StringBuilder(); + sb.append("Recover"); + if (cost instanceof ManaCost) { + sb.append(" ").append(cost.getText()).append(" "); + } else { + sb.append("—").append(cost.getText()).append(". "); + } + sb.append("(When ").append(creature ? "another" : "a").append(" creature is put into your graveyard from the battlefield, you may pay "); + sb.append(cost.getText()); + sb.append(". If you do, return this card from your graveyard to your hand. Otherwise, exile this card.)"); + return sb.toString(); + } +} diff --git a/Mage/src/mage/abilities/keyword/ReplicateAbility.java b/Mage/src/mage/abilities/keyword/ReplicateAbility.java index 4607b39af1d..8be57a3997e 100644 --- a/Mage/src/mage/abilities/keyword/ReplicateAbility.java +++ b/Mage/src/mage/abilities/keyword/ReplicateAbility.java @@ -113,7 +113,7 @@ public class ReplicateAbility extends StaticAbility implements OptionalAdditiona this.resetReplicate(); boolean again = true; - while (player.isInGame() && again) { + while (player.canRespond() && again) { String times = ""; if (additionalCost.isRepeatable()) { int numActivations = additionalCost.getActivateCount(); diff --git a/Mage/src/mage/abilities/keyword/RippleAbility.java b/Mage/src/mage/abilities/keyword/RippleAbility.java new file mode 100644 index 00000000000..ad404d5e871 --- /dev/null +++ b/Mage/src/mage/abilities/keyword/RippleAbility.java @@ -0,0 +1,126 @@ +package mage.abilities.keyword; + +import mage.MageObject; +import mage.abilities.Ability; +import mage.abilities.TriggeredAbilityImpl; +import mage.abilities.effects.OneShotEffect; +import mage.cards.Card; +import mage.cards.Cards; +import mage.cards.CardsImpl; +import mage.constants.Outcome; +import mage.constants.Zone; +import mage.filter.FilterCard; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.game.Game; +import mage.game.events.GameEvent; +import mage.game.stack.Spell; +import mage.players.Player; +import mage.target.TargetCard; +import mage.util.CardUtil; + +/** + * @author klayhamn + */ +public class RippleAbility extends TriggeredAbilityImpl { + + protected final int rippleNumber; + + public RippleAbility(int rippleNumber) { + super(Zone.STACK, new RippleEffect(rippleNumber), false); + this.rippleNumber = rippleNumber; + } + + public RippleAbility(RippleAbility ability) { + super(ability); + this.rippleNumber = ability.rippleNumber; + + } + + @Override + public boolean checkEventType(GameEvent event, Game game) { + return event.getType() == GameEvent.EventType.SPELL_CAST; + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + Spell spell = game.getStack().getSpell(event.getTargetId()); + if (spell != null && spell.getSourceId().equals(this.getSourceId())) { + return true; + } + return false; + + } + + @Override + public RippleAbility copy() { + return new RippleAbility(this); + } + + + @Override + public String getRule() { + return "Ripple ((When you cast this spell, you may reveal the top " + CardUtil.numberToText(rippleNumber) + " cards of your library. You may cast any revealed cards with the same name as this spell without paying their mana costs. Put the rest on the bottom of your library.))"; + } + + +} + +class RippleEffect extends OneShotEffect { + + protected int rippleNumber; + + public RippleEffect(int rippleNumber) { + super(Outcome.PlayForFree); + this.rippleNumber = rippleNumber; + } + + public RippleEffect(final RippleEffect effect) { + super(effect); + this.rippleNumber = effect.rippleNumber; + } + + @Override + public RippleEffect copy() { + return new RippleEffect(this); + } + + + @Override + public boolean apply(Game game, Ability source) { + Player player = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (player != null) { + if (!player.chooseUse(Outcome.Neutral, "Reveal " + rippleNumber + " cards from the top of your library?", source, game)){ + return true; //fizzle + } + // reveal to/**/p cards from library + Cards cards = new CardsImpl(); + cards.addAll(player.getLibrary().getTopCards(game, rippleNumber)); + player.revealCards(sourceObject.getIdName(), cards, game); + + // determine which card should be rippled + String cardNameToRipple = sourceObject.getName(); + FilterCard sameNameFilter = new FilterCard("card(s) with the name: \"" + cardNameToRipple + "\" to cast without paying their mana cost"); + sameNameFilter.add(new NamePredicate(cardNameToRipple)); + TargetCard target1 = new TargetCard(Zone.LIBRARY, sameNameFilter); + target1.setRequired(false); + + // choose cards to play for free + while (player.canRespond() && cards.count(sameNameFilter, game) > 0 && player.choose(Outcome.PlayForFree, cards, target1, game)) { + Card card = cards.get(target1.getFirstTarget(), game); + if (card != null) { + player.cast(card.getSpellAbility(), game, true); + cards.remove(card); + } + target1.clearChosen(); + } + // move cards that weren't cast to the bottom of the library + player.putCardsOnBottomOfLibrary(cards, game, source, true); + return true; + } + + return false; + } + +} + diff --git a/Mage/src/mage/abilities/keyword/SuspendAbility.java b/Mage/src/mage/abilities/keyword/SuspendAbility.java index 559b9c5c9a4..03b50951133 100644 --- a/Mage/src/mage/abilities/keyword/SuspendAbility.java +++ b/Mage/src/mage/abilities/keyword/SuspendAbility.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.abilities.keyword; import java.util.ArrayList; @@ -63,93 +62,97 @@ import mage.players.Player; * * 502.59. Suspend * - * 502.59a Suspend is a keyword that represents three abilities. The first is a static - * ability that functions while the card with suspend is in a player's hand. The second - * and third are triggered abilities that function in the removed-from-the-game zone. - * "Suspend N--[cost]" means "If you could play this card from your hand, you may pay - * [cost] and remove it from the game with N time counters on it. This is a special - * action that doesn't use the stack," and "At the beginning of your upkeep, if this - * card is suspended, remove a time counter from it," and "When the last time counter - * is removed from this card, if it's removed from the game, play it without paying its - * mana cost if able. If you can't, it remains removed from the game. If you play it - * this way and it's a creature, it gains haste until you lose control of it." + * 502.59a Suspend is a keyword that represents three abilities. The first is a + * static ability that functions while the card with suspend is in a player's + * hand. The second and third are triggered abilities that function in the + * removed-from-the-game zone. "Suspend N--[cost]" means "If you could play this + * card from your hand, you may pay [cost] and remove it from the game with N + * time counters on it. This is a special action that doesn't use the stack," + * and "At the beginning of your upkeep, if this card is suspended, remove a + * time counter from it," and "When the last time counter is removed from this + * card, if it's removed from the game, play it without paying its mana cost if + * able. If you can't, it remains removed from the game. If you play it this way + * and it's a creature, it gains haste until you lose control of it." * - * 502.59b A card is "suspended" if it's in the removed-from-the-game zone, has suspend, - * and has a time counter on it. + * 502.59b A card is "suspended" if it's in the removed-from-the-game zone, has + * suspend, and has a time counter on it. * - * 502.59c Playing a spell as an effect of its suspend ability follows the rules for - * paying alternative costs in rules 409.1b and 409.1f-h. + * 502.59c Playing a spell as an effect of its suspend ability follows the rules + * for paying alternative costs in rules 409.1b and 409.1f-h. * - * The phrase "if you could play this card from your hand" checks only for timing - * restrictions and permissions. This includes both what's inherent in the card's - * type (for example, if the card with suspend is a creature, it must be your main - * phase and the stack must be empty) and what's imposed by other abilities, such - * as flash or Meddling Mage's ability. Whether you could actually follow all steps - * in playing the card is irrelevant. If the card is impossible to play due to a - * lack of legal targets or an unpayable mana cost, for example, it may still be - * removed from the game with suspend. + * The phrase "if you could play this card from your hand" checks only for + * timing restrictions and permissions. This includes both what's inherent in + * the card's type (for example, if the card with suspend is a creature, it must + * be your main phase and the stack must be empty) and what's imposed by other + * abilities, such as flash or Meddling Mage's ability. Whether you could + * actually follow all steps in playing the card is irrelevant. If the card is + * impossible to play due to a lack of legal targets or an unpayable mana cost, + * for example, it may still be removed from the game with suspend. * - * Removing a card from the game with its suspend ability is not playing that card. - * This action doesn't use the stack and can't be responded to. + * Removing a card from the game with its suspend ability is not playing that + * card. This action doesn't use the stack and can't be responded to. * * If a spell with suspend has targets, the targets are chosen when the spell is * played, not when it's removed from the game. * - * If the first triggered ability of suspend is countered, no time counter is removed. - * The ability will trigger again during its owner's next upkeep. + * If the first triggered ability of suspend is countered, no time counter is + * removed. The ability will trigger again during its owner's next upkeep. * - * When the last time counter is removed from a suspended card, the second triggered - * ability of suspend will trigger. It doesn't matter why the time counter was removed - * or whose effect removed it. (The _Time Spiral_ reminder text is misleading on this point.) + * When the last time counter is removed from a suspended card, the second + * triggered ability of suspend will trigger. It doesn't matter why the time + * counter was removed or whose effect removed it. (The _Time Spiral_ reminder + * text is misleading on this point.) * - * If the second triggered ability of suspend is countered, the card can't be played. - * It remains in the removed-from-the-game zone without any time counters on it for the - * rest of the game, and it's no longer considered suspended. + * If the second triggered ability of suspend is countered, the card can't be + * played. It remains in the removed-from-the-game zone without any time + * counters on it for the rest of the game, and it's no longer considered + * suspended. * - * If the second triggered ability of suspend resolves, the card's owner must play the - * spell if possible, even if that player doesn't want to. Normal timing considerations - * for the spell are ignored (for example, if the suspended card is a creature and this - * ability resolves during your upkeep, you’re able to play the card), but other play - * restrictions are not ignored. + * If the second triggered ability of suspend resolves, the card's owner must + * play the spell if possible, even if that player doesn't want to. Normal + * timing considerations for the spell are ignored (for example, if the + * suspended card is a creature and this ability resolves during your upkeep, + * you’re able to play the card), but other play restrictions are not ignored. * - * If the second triggered ability of suspend resolves and the suspended card can't be - * played due to a lack of legal targets or a play restriction, for example, it remains - * in the removed-from-the-game zone without any time counters on it for the rest of the - * game, and it's no longer considered suspended. + * If the second triggered ability of suspend resolves and the suspended card + * can't be played due to a lack of legal targets or a play restriction, for + * example, it remains in the removed-from-the-game zone without any time + * counters on it for the rest of the game, and it's no longer considered + * suspended. * - * As the second triggered ability of suspend resolves, if playing the suspended card - * involves an additional cost, the card's owner must pay that cost if able. If he or - * she can't, the card remains removed from the game. If the additional cost includes - * mana, the situation is more complex. If the player has enough mana in his or her mana - * pool to pay the cost, that player must do so. If the player can't possibly pay the - * cost, the card remains removed from the game. However, if the player has the means - * to produce enough mana to pay the cost, then he or she has a choice: The player may - * play the spell, produce mana, and pay the cost. Or the player may choose to play no - * mana abilities, thus making the card impossible to play because the additional mana - * can't be paid. + * As the second triggered ability of suspend resolves, if playing the suspended + * card involves an additional cost, the card's owner must pay that cost if + * able. If he or she can't, the card remains removed from the game. If the + * additional cost includes mana, the situation is more complex. If the player + * has enough mana in his or her mana pool to pay the cost, that player must do + * so. If the player can't possibly pay the cost, the card remains removed from + * the game. However, if the player has the means to produce enough mana to pay + * the cost, then he or she has a choice: The player may play the spell, produce + * mana, and pay the cost. Or the player may choose to play no mana abilities, + * thus making the card impossible to play because the additional mana can't be + * paid. * - * A creature played via suspend comes into play with haste. It still has haste after - * the first turn it's in play as long as the same player controls it. As soon as another - * player takes control of it, it loses haste. + * A creature played via suspend comes into play with haste. It still has haste + * after the first turn it's in play as long as the same player controls it. As + * soon as another player takes control of it, it loses haste. * * * @author LevelX2 * */ - - public class SuspendAbility extends ActivatedAbilityImpl { private String ruleText; private boolean gainedTemporary; /** - * Gives the card the SuspendAbility - * - * @param suspend - amount of time counters, if Integer.MAX_VALUE is set there will be {X} costs and X counters added - * @param cost - null is used for temporary gained suspend ability - * @param card - card that has the suspend ability - */ + * Gives the card the SuspendAbility + * + * @param suspend - amount of time counters, if Integer.MAX_VALUE is set + * there will be {X} costs and X counters added + * @param cost - null is used for temporary gained suspend ability + * @param card - card that has the suspend ability + */ public SuspendAbility(int suspend, ManaCost cost, Card card) { this(suspend, cost, card, false); } @@ -165,16 +168,16 @@ public class SuspendAbility extends ActivatedAbilityImpl { } StringBuilder sb = new StringBuilder("Suspend "); if (cost != null) { - sb.append(suspend == Integer.MAX_VALUE ? "X":suspend).append(" - ").append(cost.getText()); + sb.append(suspend == Integer.MAX_VALUE ? "X" : suspend).append(" - ").append(cost.getText()); if (!shortRule) { sb.append(" (Rather than cast this card from your hand, pay ") - .append(cost.getText()) - .append(" and exile it with ") - .append((suspend == 1 ? "a time counter": (suspend == Integer.MAX_VALUE ? "X time counters": suspend + " time counters"))) - .append(" on it.") - .append(" At the beginning of your upkeep, remove a time counter. When the last is removed, cast it without paying its mana cost.") - .append(card.getCardType().contains(CardType.CREATURE)? " If you play it this way and it's a creature, it gains haste until you lose control of it.":"") - .append(")"); + .append(cost.getText()) + .append(" and exile it with ") + .append((suspend == 1 ? "a time counter" : (suspend == Integer.MAX_VALUE ? "X time counters" : suspend + " time counters"))) + .append(" on it.") + .append(" At the beginning of your upkeep, remove a time counter. When the last is removed, cast it without paying its mana cost.") + .append(card.getCardType().contains(CardType.CREATURE) ? " If you play it this way and it's a creature, it gains haste until you lose control of it." : "") + .append(")"); } if (card.getManaCost().isEmpty()) { setRuleAtTheTop(true); @@ -186,8 +189,9 @@ public class SuspendAbility extends ActivatedAbilityImpl { } /** - * Adds suspend to a card that does not have it regularly - * e.g. Epochrasite or added by Jhoira of the Ghitu + * Adds suspend to a card that does not have it regularly e.g. Epochrasite + * or added by Jhoira of the Ghitu + * * @param card * @param source * @param game @@ -229,10 +233,10 @@ public class SuspendAbility extends ActivatedAbilityImpl { @Override public boolean canActivate(UUID playerId, Game game) { MageObject object = game.getObject(sourceId); - return (object.getCardType().contains(CardType.INSTANT) || - object.hasAbility(FlashAbility.getInstance().getId(), game) || - game.getContinuousEffects().asThough(sourceId, AsThoughEffectType.CAST_AS_INSTANT, this, playerId, game) || - game.canPlaySorcery(playerId)); + return (object.getCardType().contains(CardType.INSTANT) + || object.hasAbility(FlashAbility.getInstance().getId(), game) + || game.getContinuousEffects().asThough(sourceId, AsThoughEffectType.CAST_AS_INSTANT, this, playerId, game) + || game.canPlaySorcery(playerId)); } @Override @@ -252,11 +256,12 @@ public class SuspendAbility extends ActivatedAbilityImpl { } class SuspendExileEffect extends OneShotEffect { + private int suspend; public SuspendExileEffect(int suspend) { super(Outcome.PutCardInPlay); - this.staticText = new StringBuilder("Suspend ").append(suspend == Integer.MAX_VALUE ? "X":suspend).toString(); + this.staticText = new StringBuilder("Suspend ").append(suspend == Integer.MAX_VALUE ? "X" : suspend).toString(); this.suspend = suspend; } @@ -281,8 +286,9 @@ class SuspendExileEffect extends OneShotEffect { suspend = source.getManaCostsToPay().getX(); } card.addCounters(CounterType.TIME.createInstance(suspend), game); - if (!game.isSimulation()) - game.informPlayers(new StringBuilder(controller.getLogName()).append(" suspends (").append(suspend).append(") ").append(card.getName()).toString()); + if (!game.isSimulation()) { + game.informPlayers(controller.getLogName() + " suspends (" + suspend + ") " + card.getLogName()); + } return true; } } @@ -357,14 +363,14 @@ class SuspendPlayCardEffect extends OneShotEffect { List abilitiesToRemove = new ArrayList<>(); for (Ability ability : card.getAbilities()) { if (ability instanceof SuspendAbility) { - if (((SuspendAbility)ability).isGainedTemporary()) { + if (((SuspendAbility) ability).isGainedTemporary()) { abilitiesToRemove.add(ability); } } } if (!abilitiesToRemove.isEmpty()) { for (Ability ability : card.getAbilities()) { - if (ability instanceof SuspendBeginningOfUpkeepTriggeredAbility || ability instanceof SuspendPlayCardAbility ) { + if (ability instanceof SuspendBeginningOfUpkeepTriggeredAbility || ability instanceof SuspendPlayCardAbility) { abilitiesToRemove.add(ability); } } @@ -434,4 +440,4 @@ class SuspendBeginningOfUpkeepTriggeredAbility extends ConditionalTriggeredAbili public SuspendBeginningOfUpkeepTriggeredAbility copy() { return new SuspendBeginningOfUpkeepTriggeredAbility(this); } -} \ No newline at end of file +} diff --git a/Mage/src/mage/abilities/keyword/TransmuteAbility.java b/Mage/src/mage/abilities/keyword/TransmuteAbility.java index 156a9dc8848..f4b095ea41a 100644 --- a/Mage/src/mage/abilities/keyword/TransmuteAbility.java +++ b/Mage/src/mage/abilities/keyword/TransmuteAbility.java @@ -5,7 +5,6 @@ import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.DiscardSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.OneShotEffect; -import mage.cards.Card; import mage.cards.Cards; import mage.cards.CardsImpl; import mage.constants.Outcome; @@ -17,25 +16,29 @@ import mage.game.Game; import mage.players.Player; import mage.target.common.TargetCardInLibrary; -import java.util.UUID; +import mage.MageObject; import mage.constants.TimingRule; /** * - * 702.52. Transmute + * 702.52. Transmute * - * 702.52a Transmute is an activated ability that functions only while the card with transmute is - * in a player’s hand. “Transmute [cost]” means “[Cost], Discard this card: Search your library for - * a card with the same converted mana cost as the discarded card, reveal that card, and put it into - * your hand. Then shuffle your library. Play this ability only any time you could play a sorcery.” + * 702.52a Transmute is an activated ability that functions only while the card + * with transmute is in a player’s hand. “Transmute [cost]” means “[Cost], + * Discard this card: Search your library for a card with the same converted + * mana cost as the discarded card, reveal that card, and put it into your hand. + * Then shuffle your library. Play this ability only any time you could play a + * sorcery.” * - * 702.52b Although the transmute ability is playable only if the card is in a player’s hand, it - * continues to exist while the object is in play and in all other zones. Therefore objects with - * transmute will be affected by effects that depend on objects having one or more activated abilities. + * 702.52b Although the transmute ability is playable only if the card is in a + * player’s hand, it continues to exist while the object is in play and in all + * other zones. Therefore objects with transmute will be affected by effects + * that depend on objects having one or more activated abilities. * * @author Loki */ public class TransmuteAbility extends SimpleActivatedAbility { + public TransmuteAbility(String manaCost) { super(Zone.HAND, new TransmuteEffect(), new ManaCostsImpl(manaCost)); this.setTiming(TimingRule.SORCERY); @@ -60,6 +63,7 @@ public class TransmuteAbility extends SimpleActivatedAbility { } class TransmuteEffect extends OneShotEffect { + TransmuteEffect() { super(Outcome.Benefit); staticText = "Transmute"; @@ -71,27 +75,20 @@ class TransmuteEffect extends OneShotEffect { @Override public boolean apply(Game game, Ability source) { - Player player = game.getPlayer(source.getControllerId()); - Card sourceCard = game.getCard(source.getSourceId()); - - if (sourceCard != null && player != null) { - FilterCard filter = new FilterCard("card with converted mana cost " + sourceCard.getManaCost().convertedManaCost()); - filter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.Equal, sourceCard.getManaCost().convertedManaCost())); + Player controller = game.getPlayer(source.getControllerId()); + MageObject sourceObject = game.getObject(source.getSourceId()); + if (sourceObject != null && controller != null) { + FilterCard filter = new FilterCard("card with converted mana cost " + sourceObject.getManaCost().convertedManaCost()); + filter.add(new ConvertedManaCostPredicate(Filter.ComparisonType.Equal, sourceObject.getManaCost().convertedManaCost())); TargetCardInLibrary target = new TargetCardInLibrary(1, filter); - if (player.searchLibrary(target, game)) { + if (controller.searchLibrary(target, game)) { if (target.getTargets().size() > 0) { - Cards revealed = new CardsImpl(); - for (UUID cardId : target.getTargets()) { - Card card = player.getLibrary().remove(cardId, game); - if (card != null) { - player.moveCardToHandWithInfo(card, source.getSourceId(), game, Zone.LIBRARY); - revealed.add(card); - } - } - player.revealCards("Search", revealed, game); + Cards revealed = new CardsImpl(target.getTargets()); + controller.revealCards(sourceObject.getIdName(), revealed, game); + controller.moveCards(revealed, null, Zone.HAND, source, game); } } - player.shuffleLibrary(game); + controller.shuffleLibrary(game); return true; } diff --git a/Mage/src/mage/abilities/keyword/VanishingUpkeepAbility.java b/Mage/src/mage/abilities/keyword/VanishingUpkeepAbility.java index 0d7d96b7c57..188ef1bf5a6 100644 --- a/Mage/src/mage/abilities/keyword/VanishingUpkeepAbility.java +++ b/Mage/src/mage/abilities/keyword/VanishingUpkeepAbility.java @@ -31,14 +31,14 @@ public class VanishingUpkeepAbility extends BeginningOfUpkeepTriggeredAbility { @Override public String getRule() { - return new StringBuilder("Vanishing ") - .append(vanishingAmount) - .append(" (This permanent enters the battlefield with ").append(CardUtil.numberToText(vanishingAmount)) - .append(" time counters on it. At the beginning of your upkeep, remove a time counter from it. When the last is removed, sacrifice it.)").toString(); + return "Vanishing " + vanishingAmount + + " (This permanent enters the battlefield with " + CardUtil.numberToText(vanishingAmount) + + " time counters on it. At the beginning of your upkeep, remove a time counter from it. When the last is removed, sacrifice it.)"; } } class VanishingEffect extends OneShotEffect { + VanishingEffect() { super(Outcome.Sacrifice); } @@ -47,7 +47,6 @@ class VanishingEffect extends OneShotEffect { super(effect); } - @Override public boolean apply(Game game, Ability source) { Permanent p = game.getPermanent(source.getSourceId()); @@ -55,6 +54,7 @@ class VanishingEffect extends OneShotEffect { int amount = p.getCounters().getCount(CounterType.TIME); if (amount > 0) { p.removeCounters(CounterType.TIME.createInstance(), game); + game.informPlayers("Removed a time counter from " + p.getLogName() + " (" + amount + " left)"); } return true; } diff --git a/Mage/src/mage/abilities/mana/CommanderColorIdentityManaAbility.java b/Mage/src/mage/abilities/mana/CommanderColorIdentityManaAbility.java index e3d1110c2d7..b3bb8d035cd 100644 --- a/Mage/src/mage/abilities/mana/CommanderColorIdentityManaAbility.java +++ b/Mage/src/mage/abilities/mana/CommanderColorIdentityManaAbility.java @@ -47,20 +47,19 @@ import mage.util.CardUtil; * * @author LevelX2 */ - public class CommanderColorIdentityManaAbility extends ManaAbility { private FilterMana commanderMana; public CommanderColorIdentityManaAbility() { - super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(),new TapSourceCost()); + super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), new TapSourceCost()); } - + public CommanderColorIdentityManaAbility(Cost cost) { super(Zone.BATTLEFIELD, new CommanderIdentityManaEffect(), cost); commanderMana = null; } - + public CommanderColorIdentityManaAbility(final CommanderColorIdentityManaAbility ability) { super(ability); this.commanderMana = ability.commanderMana; @@ -73,7 +72,7 @@ public class CommanderColorIdentityManaAbility extends ManaAbility { @Override public List getNetMana(Game game) { - if (netMana.isEmpty()) { + if (netMana.isEmpty() && game != null) { Player controller = game.getPlayer(getControllerId()); if (controller != null) { if (commanderMana == null) { @@ -110,7 +109,6 @@ public class CommanderColorIdentityManaAbility extends ManaAbility { return true; } - } class CommanderIdentityManaEffect extends ManaEffect { @@ -190,7 +188,7 @@ class CommanderIdentityManaEffect extends ManaEffect { break; } checkToFirePossibleEvents(mana, game, source); - controller.getManaPool().addMana(mana, game, source); + controller.getManaPool().addMana(mana, game, source); return true; } } diff --git a/Mage/src/mage/abilities/mana/DynamicManaAbility.java b/Mage/src/mage/abilities/mana/DynamicManaAbility.java index 72336b74e08..15a44b71c3f 100644 --- a/Mage/src/mage/abilities/mana/DynamicManaAbility.java +++ b/Mage/src/mage/abilities/mana/DynamicManaAbility.java @@ -48,6 +48,7 @@ public class DynamicManaAbility extends ManaAbility { /** * TapSourceCost added by default + * * @param mana * @param amount */ @@ -74,10 +75,24 @@ public class DynamicManaAbility extends ManaAbility { } public DynamicManaAbility(Mana mana, DynamicValue amount, Cost cost, String text, boolean oneChoice) { - super(Zone.BATTLEFIELD, new DynamicManaEffect(mana, amount, text, oneChoice), cost); - manaEffect = (DynamicManaEffect) this.getEffects().get(0); + this(mana, amount, cost, text, oneChoice, null); } + /** + * + * @param mana + * @param amount + * @param cost + * @param text + * @param oneChoice is all mana from the same colour or if false the player + * can choose different colours + * @param netAmount a dynamic value that calculates the possible available + * mana (e.g. if you have to pay by removing counters from source) + */ + public DynamicManaAbility(Mana mana, DynamicValue amount, Cost cost, String text, boolean oneChoice, DynamicValue netAmount) { + super(Zone.BATTLEFIELD, new DynamicManaEffect(mana, amount, text, oneChoice, netAmount), cost); + manaEffect = (DynamicManaEffect) this.getEffects().get(0); + } public DynamicManaAbility(final DynamicManaAbility ability) { super(ability); @@ -95,8 +110,9 @@ public class DynamicManaAbility extends ManaAbility { List newNetMana = new ArrayList<>(); if (game != null) { // TODO: effects from replacement effects like Mana Reflection are not considered yet + // TODO: effects that need a X payment (e.g. Mage-Ring Network) return always 0 newNetMana.add(manaEffect.computeMana(true, game, this)); - } - return newNetMana; + } + return newNetMana; } } diff --git a/Mage/src/mage/abilities/mana/ManaOptions.java b/Mage/src/mage/abilities/mana/ManaOptions.java index dbadf31cfb7..bb5977e813f 100644 --- a/Mage/src/mage/abilities/mana/ManaOptions.java +++ b/Mage/src/mage/abilities/mana/ManaOptions.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.abilities.mana; import java.util.ArrayList; @@ -37,17 +36,20 @@ import mage.game.Game; * * @author BetaSteward_at_googlemail.com * - * this class is used to build a list of all possible mana combinations - * it can be used to find all the ways to pay a mana cost - * or all the different mana combinations available to a player + * this class is used to build a list of all possible mana combinations it can + * be used to find all the ways to pay a mana cost or all the different mana + * combinations available to a player * */ public class ManaOptions extends ArrayList { - public ManaOptions () {}; + public ManaOptions() { + } + + ; public ManaOptions(final ManaOptions options) { - for (Mana mana: options) { + for (Mana mana : options) { this.add(mana.copy()); } } @@ -59,42 +61,41 @@ public class ManaOptions extends ArrayList { if (!abilities.isEmpty()) { if (abilities.size() == 1) { //if there is only one mana option available add it to all the existing options - List netManas = abilities.get(0).getNetMana(game); + List netManas = abilities.get(0).getNetMana(game); if (netManas.size() == 1) { addMana(netManas.get(0)); } else { List copy = copy(); this.clear(); - for (Mana netMana: netManas) { - for (Mana mana: copy) { + for (Mana netMana : netManas) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(netMana); this.add(newMana); - } - } + } + } } - - } - else if (abilities.size() > 1) { + + } else if (abilities.size() > 1) { //perform a union of all existing options and the new options List copy = copy(); this.clear(); - for (ManaAbility ability: abilities) { - for (Mana netMana: ability.getNetMana(game)) { + for (ManaAbility ability : abilities) { + for (Mana netMana : ability.getNetMana(game)) { SkipAddMana: - for (Mana mana: copy) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(netMana); - for(Mana existingMana: this) { + for (Mana existingMana : this) { if (existingMana.equalManaValue(newMana)) { - continue SkipAddMana; + continue SkipAddMana; } Mana moreValuable = Mana.getMoreValuableMana(newMana, existingMana); if (moreValuable != null) { // only keep the more valuable mana - existingMana.setToMana(newMana); + existingMana.setToMana(moreValuable); continue SkipAddMana; } } @@ -114,7 +115,7 @@ public class ManaOptions extends ArrayList { if (abilities.size() == 1) { //if there is only one mana option available add it to all the existing options ManaAbility ability = abilities.get(0); - List netManas = abilities.get(0).getNetMana(game); + List netManas = abilities.get(0).getNetMana(game); // no mana costs if (ability.getManaCosts().isEmpty()) { if (netManas.size() == 1) { @@ -122,15 +123,15 @@ public class ManaOptions extends ArrayList { } else { List copy = copy(); this.clear(); - for (Mana netMana: netManas) { - for (Mana mana: copy) { + for (Mana netMana : netManas) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(netMana); this.add(newMana); - } - } - } + } + } + } } else { // the ability has mana costs if (netManas.size() == 1) { @@ -138,27 +139,27 @@ public class ManaOptions extends ArrayList { } else { List copy = copy(); this.clear(); - for (Mana netMana: netManas) { - for (Mana mana: copy) { + for (Mana netMana : netManas) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(netMana); subtractCostAddMana(ability.getManaCosts().getMana(), netMana, ability.getCosts().isEmpty()); - } - } - } + } + } + } } } else if (abilities.size() > 1) { //perform a union of all existing options and the new options List copy = copy(); this.clear(); - for (ManaAbility ability: abilities) { - - List netManas = ability.getNetMana(game); - + for (ManaAbility ability : abilities) { + + List netManas = ability.getNetMana(game); + if (ability.getManaCosts().isEmpty()) { - for (Mana netMana: netManas) { - for (Mana mana: copy) { + for (Mana netMana : netManas) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(netMana); @@ -166,24 +167,26 @@ public class ManaOptions extends ArrayList { } } } else { - for (Mana netMana: netManas) { - CombineWithExisting: - for (Mana previousMana: copy) { - Mana newMana = new Mana(previousMana); - if (previousMana.includesMana(ability.getManaCosts().getMana())) { // costs can be paid - newMana.subtractCost(ability.getManaCosts().getMana()); - newMana.add(netMana); - // if the new mana is in all colors more than another already existing than replace - for (Mana existingMana: this) { - Mana moreValuable = Mana.getMoreValuableMana(newMana, existingMana); - if (moreValuable != null) { - existingMana.setToMana(moreValuable); - continue CombineWithExisting; - } + for (Mana netMana : netManas) { + for (Mana previousMana : copy) { + CombineWithExisting: + for (Mana manaOption : ability.getManaCosts().getManaOptions()) { + Mana newMana = new Mana(previousMana); + if (previousMana.includesMana(manaOption)) { // costs can be paid + newMana.subtractCost(manaOption); + newMana.add(netMana); + // if the new mana is in all colors more than another already existing than replace + for (Mana existingMana : this) { + Mana moreValuable = Mana.getMoreValuableMana(newMana, existingMana); + if (moreValuable != null) { + existingMana.setToMana(moreValuable); + continue CombineWithExisting; + } + } + // no existing Mana includes this new mana so add + this.add(newMana); } - // no existing Mana includes this new mana so add - this.add(newMana); - } + } } } } @@ -197,7 +200,7 @@ public class ManaOptions extends ArrayList { if (isEmpty()) { this.add(new Mana()); } - for (Mana mana: this) { + for (Mana mana : this) { mana.add(addMana); } } @@ -210,13 +213,12 @@ public class ManaOptions extends ArrayList { if (options.size() == 1) { //if there is only one mana option available add it to all the existing options addMana(options.get(0)); - } - else if (options.size() > 1) { + } else if (options.size() > 1) { //perform a union of all existing options and the new options List copy = copy(); this.clear(); - for (Mana addMana: options) { - for (Mana mana: copy) { + for (Mana addMana : options) { + for (Mana mana : copy) { Mana newMana = new Mana(); newMana.add(mana); newMana.add(addMana); @@ -240,15 +242,92 @@ public class ManaOptions extends ArrayList { // deactivated because it does cause loops TODO: Find reason repeatable = true; // only replace to any with mana costs only will be repeated if able } - for (Mana mana: this) { - while (mana.includesMana(cost)) { - mana.subtractCost(cost); - mana.add(addMana); - if (!repeatable) { - break; + List copy = copy(); + this.clear(); + for (Mana mana : copy) { + Mana oldMan = mana.copy(); + if (mana.includesMana(cost)) { + // colorless costs can be paid with different colored mana, can lead to different color combinations + if (cost.getColorless() > 0 && cost.getColorless() > mana.getColorless()) { + Mana coloredCost = cost.copy(); + coloredCost.setColorless(0); + mana.subtract(coloredCost); + for (Mana payCombination : getPossiblePayCombinations(cost.getColorless(), mana)) { + Mana newMana = mana.copy(); + newMana.subtract(payCombination); + newMana.add(addMana); + if (oldMan.contains(newMana) && oldMan.count() > newMana.count()) { + newMana.setToMana(oldMan); + } + this.add(newMana); + } + } else { + while (mana.includesMana(cost)) { + mana.subtractCost(cost); + mana.add(addMana); + if (!repeatable) { + break; + } + } + // Don't use mana that only reduce the available mana + if (oldMan.contains(mana) && oldMan.count() > mana.count()) { + mana.setToMana(oldMan); + } + this.add(mana); } } } } -} \ No newline at end of file + private List getPossiblePayCombinations(int number, Mana manaAvailable) { + List payCombinations = new ArrayList<>(); + List payCombinationsStrings = new ArrayList<>(); + if (manaAvailable.countColored() > 0) { + + for (int i = 0; i < number; i++) { + List existingManas = new ArrayList<>(); + if (i > 0) { + existingManas.addAll(payCombinations); + payCombinations.clear(); + payCombinationsStrings.clear(); + } else { + existingManas.add(new Mana()); + } + for (Mana existingMana : existingManas) { + Mana manaToPay = manaAvailable.copy(); + manaToPay.subtract(existingMana); + if (manaToPay.getBlack() > 0 && !payCombinationsStrings.contains(existingMana.toString() + Mana.BlackMana.toString())) { + manaToPay.subtract(Mana.BlackMana); + addManaCombination(Mana.BlackMana, existingMana, payCombinations, payCombinationsStrings); + } + if (manaToPay.getBlue() > 0 && !payCombinationsStrings.contains(existingMana.toString() + Mana.BlueMana.toString())) { + manaToPay.subtract(Mana.BlueMana); + addManaCombination(Mana.BlueMana, existingMana, payCombinations, payCombinationsStrings); + } + if (manaToPay.getGreen() > 0 && !payCombinationsStrings.contains(existingMana.toString() + Mana.GreenMana.toString())) { + manaToPay.subtract(Mana.GreenMana); + addManaCombination(Mana.GreenMana, existingMana, payCombinations, payCombinationsStrings); + } + if (manaToPay.getRed() > 0 && !payCombinationsStrings.contains(existingMana.toString() + Mana.RedMana.toString())) { + manaToPay.subtract(Mana.RedMana); + addManaCombination(Mana.RedMana, existingMana, payCombinations, payCombinationsStrings); + } + if (manaToPay.getWhite() > 0 && !payCombinationsStrings.contains(existingMana.toString() + Mana.WhiteMana.toString())) { + manaToPay.subtract(Mana.WhiteMana); + addManaCombination(Mana.WhiteMana, existingMana, payCombinations, payCombinationsStrings); + } + } + } + } else { + payCombinations.add(new Mana(0, 0, 0, 0, 0, number, 0)); + } + return payCombinations; + } + + private void addManaCombination(Mana mana, Mana existingMana, List payCombinations, List payCombinationsStrings) { + Mana newMana = existingMana.copy(); + newMana.add(mana); + payCombinations.add(newMana); + payCombinationsStrings.add(newMana.toString()); + } +} diff --git a/Mage/src/mage/cards/Card.java b/Mage/src/mage/cards/Card.java index 91217b0c02a..6e5ec8c1d32 100644 --- a/Mage/src/mage/cards/Card.java +++ b/Mage/src/mage/cards/Card.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.cards; import java.util.ArrayList; @@ -33,7 +32,6 @@ import java.util.List; import java.util.UUID; import mage.MageObject; import mage.Mana; -import mage.ObjectColor; import mage.abilities.Abilities; import mage.abilities.Ability; import mage.abilities.SpellAbility; @@ -46,26 +44,45 @@ import mage.game.Game; public interface Card extends MageObject { UUID getOwnerId(); + int getCardNumber(); + Rarity getRarity(); + void setOwnerId(UUID ownerId); + public Abilities getAbilities(Game game); + void setSpellAbility(SpellAbility ability); + SpellAbility getSpellAbility(); + List getRules(); // gets base card rules + List getRules(Game game); // gets card rules + in game modifications + String getExpansionSetCode(); + String getTokenSetCode(); + void setFaceDown(boolean value, Game game); + boolean isFaceDown(Game game); + boolean turnFaceUp(Game game, UUID playerId); + boolean turnFaceDown(Game game, UUID playerId); + boolean isFlipCard(); + String getFlipCardName(); + boolean isSplitCard(); boolean canTransform(); + Card getSecondCardFace(); + boolean isNightCard(); void assignNewId(); @@ -74,14 +91,18 @@ public interface Card extends MageObject { /** * Moves the card to the specified zone + * * @param zone * @param sourceId * @param game * @param flag If zone *
    - *
  • LIBRARY:
    • true - put on top
    • false - put on bottom
  • - *
  • BATTLEFIELD:
    • true - tapped
    • false - untapped
  • - *
  • GRAVEYARD:
    • true - not from Battlefield
    • false - from Battlefield
  • + *
  • LIBRARY:
    • true - put on top
    • false - put on + * bottom
  • + *
  • BATTLEFIELD:
    • true - tapped
    • false - + * untapped
  • + *
  • GRAVEYARD:
    • true - not from Battlefield
    • false - from + * Battlefield
  • *
* @return true if card was moved to zone */ @@ -91,6 +112,7 @@ public interface Card extends MageObject { /** * Moves the card to an exile zone + * * @param exileId set to null for generic exile zone * @param name used for exile zone with the specified exileId * @param sourceId @@ -98,15 +120,19 @@ public interface Card extends MageObject { * @return true if card was moved to zone */ boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game); - + boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game, ArrayList appliedEffects); - boolean cast(Game game, Zone fromZone, SpellAbility ability, UUID controllerId); + boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId); + boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped); + boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown); + boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown, ArrayList appliedEffects); + List getMana(); void build(); @@ -116,24 +142,30 @@ public interface Card extends MageObject { * @return true if there exists various art images for this card */ boolean getUsesVariousArt(); + Counters getCounters(Game game); void addCounters(String name, int amount, Game game); + void addCounters(String name, int amount, Game game, ArrayList appliedEffects); + void addCounters(Counter counter, Game game); + void addCounters(Counter counter, Game game, ArrayList appliedEffects); void removeCounters(String name, int amount, Game game); + void removeCounters(Counter counter, Game game); - + @Override Card copy(); - + /** * - * @return The main card of a split half card, otherwise thae card itself is returned + * @return The main card of a split half card, otherwise thae card itself is + * returned */ Card getMainCard(); - void setZone(Zone zone, Game game); + void setZone(Zone zone, Game game); } diff --git a/Mage/src/mage/cards/CardImpl.java b/Mage/src/mage/cards/CardImpl.java index 1706ac1fead..c353c8e8d31 100644 --- a/Mage/src/mage/cards/CardImpl.java +++ b/Mage/src/mage/cards/CardImpl.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.cards; import java.lang.reflect.Constructor; @@ -74,13 +73,14 @@ import mage.watchers.Watcher; import org.apache.log4j.Logger; public abstract class CardImpl extends MageObjectImpl implements Card { + private static final long serialVersionUID = 1L; private static final Logger logger = Logger.getLogger(CardImpl.class); protected UUID ownerId; protected int cardNumber; - protected String expansionSetCode; + public String expansionSetCode; protected String tokenSetCode; protected Rarity rarity; protected boolean canTransform; @@ -108,16 +108,15 @@ public abstract class CardImpl extends MageObjectImpl implements Card { Ability ability = new PlayLandAbility(name); ability.setSourceId(this.getId()); abilities.add(ability); - } - else { + } else { SpellAbility ability = new SpellAbility(manaCost, name, Zone.HAND, spellAbilityType); if (!cardType.contains(CardType.INSTANT)) { ability.setTiming(TimingRule.SORCERY); } ability.setSourceId(this.getId()); - abilities.add(ability); + abilities.add(ability); } - this.usesVariousArt = Character.isDigit(this.getClass().getName().charAt(this.getClass().getName().length()-1)); + this.usesVariousArt = Character.isDigit(this.getClass().getName().charAt(this.getClass().getName().length() - 1)); this.morphCard = false; } @@ -206,8 +205,12 @@ public abstract class CardImpl extends MageObjectImpl implements Card { game.getState().getCardState(objectId).addInfo(key, value); } - protected static final ArrayList rulesError = new ArrayList() {{add("Exception occured in rules generation");}}; - + protected static final ArrayList rulesError = new ArrayList() { + { + add("Exception occured in rules generation"); + } + }; + @Override public List getRules() { try { @@ -217,7 +220,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { } return rulesError; } - + @Override public List getRules(Game game) { try { @@ -228,7 +231,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { for (String data : cardState.getInfo().values()) { rules.add(data); } - for (Ability ability: cardState.getAbilities()) { + for (Ability ability : cardState.getAbilities()) { rules.add(ability.getRule()); } } @@ -243,6 +246,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { /** * Gets all base abilities - does not include additional abilities added by * other cards or effects + * * @return A list of {@link Ability} - this collection is modifiable */ @Override @@ -251,9 +255,10 @@ public abstract class CardImpl extends MageObjectImpl implements Card { } /** - * Gets all current abilities - includes additional abilities added by - * other cards or effects - * @param game + * Gets all current abilities - includes additional abilities added by other + * cards or effects + * + * @param game * @return A list of {@link Ability} - this collection is not modifiable */ @Override @@ -265,28 +270,28 @@ public abstract class CardImpl extends MageObjectImpl implements Card { Abilities all = new AbilitiesImpl<>(); all.addAll(abilities); all.addAll(otherAbilities); - return all; + return all; } protected void addAbility(Ability ability) { ability.setSourceId(this.getId()); abilities.add(ability); - for (Ability subAbility: ability.getSubAbilities()) { + for (Ability subAbility : ability.getSubAbilities()) { abilities.add(subAbility); } } protected void addAbilities(List abilities) { - for (Ability ability: abilities) { + for (Ability ability : abilities) { addAbility(ability); } } - + protected void addAbility(Ability ability, Watcher watcher) { addAbility(ability); ability.addWatcher(watcher); } - + @Override public SpellAbility getSpellAbility() { if (spellAbility == null) { @@ -322,9 +327,9 @@ public abstract class CardImpl extends MageObjectImpl implements Card { public List getMana() { List mana = new ArrayList<>(); for (ManaAbility ability : this.abilities.getManaAbilities(Zone.BATTLEFIELD)) { - for (Mana netMana: ability.getNetMana(null)) { + for (Mana netMana : ability.getNetMana(null)) { mana.add(netMana); - } + } } return mana; } @@ -357,14 +362,14 @@ public abstract class CardImpl extends MageObjectImpl implements Card { game.getPlayer(ownerId).getSideboard().remove(this); break; case COMMAND: - game.getState().getCommand().remove((Commander)game.getObject(objectId)); + game.getState().getCommand().remove((Commander) game.getObject(objectId)); break; case STACK: StackObject stackObject = game.getStack().getSpell(getId()); if (stackObject == null && (this instanceof SplitCard)) { // handle if half od Split cast is on the stack - stackObject = game.getStack().getSpell(((SplitCard)this).getLeftHalfCard().getId()); + stackObject = game.getStack().getSpell(((SplitCard) this).getLeftHalfCard().getId()); if (stackObject == null) { - stackObject = game.getStack().getSpell(((SplitCard)this).getRightHalfCard().getId()); + stackObject = game.getStack().getSpell(((SplitCard) this).getRightHalfCard().getId()); } } if (stackObject != null) { @@ -379,12 +384,12 @@ public abstract class CardImpl extends MageObjectImpl implements Card { logger.fatal(new StringBuilder("Invalid from zone [").append(fromZone) .append("] for card [").append(this.getName()) .append("] to zone [").append(toZone) - .append("] source [").append(sourceCard != null ? sourceCard.getName():"null").append("]").toString()); + .append("] source [").append(sourceCard != null ? sourceCard.getName() : "null").append("]").toString()); break; } game.rememberLKI(objectId, event.getFromZone(), this); } - + setFaceDown(false, game); updateZoneChangeCounter(game); switch (event.getToZone()) { @@ -406,8 +411,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { case LIBRARY: if (flag) { game.getPlayer(ownerId).getLibrary().putOnTop(this, game); - } - else { + } else { game.getPlayer(ownerId).getLibrary().putOnBottom(this, game); } break; @@ -417,20 +421,24 @@ public abstract class CardImpl extends MageObjectImpl implements Card { game.setZone(objectId, Zone.BATTLEFIELD); game.setScopeRelevant(true); game.applyEffects(); - permanent.entersBattlefield(sourceId, game, event.getFromZone(), true); + boolean entered = permanent.entersBattlefield(sourceId, game, event.getFromZone(), true); game.setScopeRelevant(false); game.applyEffects(); - if (flag) { - permanent.setTapped(true); + if (entered) { + if (flag) { + permanent.setTapped(true); + } + event.setTarget(permanent); + } else { + return false; } - event.setTarget(permanent); break; default: Card sourceCard = game.getCard(sourceId); logger.fatal(new StringBuilder("Invalid to zone [").append(toZone) - .append("] for card [").append(this.getName()) - .append("] to zone [").append(toZone) - .append("] source [").append(sourceCard != null ? sourceCard.getName():"null").append("]").toString()); + .append("] for card [").append(this.getName()) + .append("] to zone [").append(toZone) + .append("] source [").append(sourceCard != null ? sourceCard.getName() : "null").append("]").toString()); return false; } game.setZone(objectId, event.getToZone()); @@ -462,12 +470,12 @@ public abstract class CardImpl extends MageObjectImpl implements Card { case OUTSIDE: game.getPlayer(ownerId).getSideboard().remove(mainCard); break; - + case COMMAND: - game.getState().getCommand().remove((Commander)game.getObject(mainCard.getId())); + game.getState().getCommand().remove((Commander) game.getObject(mainCard.getId())); break; default: - //logger.warning("moveToZone, not fully implemented: from="+event.getFromZone() + ", to="+event.getToZone()); + //logger.warning("moveToZone, not fully implemented: from="+event.getFromZone() + ", to="+event.getToZone()); } game.rememberLKI(mainCard.getId(), event.getFromZone(), this); } @@ -479,6 +487,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { } return false; } + @Override public boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game) { return moveToExile(exileId, name, sourceId, game, null); @@ -514,7 +523,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { break; default: MageObject object = game.getObject(sourceId); - logger.warn(new StringBuilder("moveToExile, not fully implemented: from = ").append(fromZone).append(" - ").append(object != null ? object.getName():"null")); + logger.warn(new StringBuilder("moveToExile, not fully implemented: from = ").append(fromZone).append(" - ").append(object != null ? object.getName() : "null")); } game.rememberLKI(objectId, event.getFromZone(), this); } @@ -537,19 +546,19 @@ public abstract class CardImpl extends MageObjectImpl implements Card { public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId) { return this.putOntoBattlefield(game, fromZone, sourceId, controllerId, false, false, null); } - + @Override - public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped){ + public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped) { return this.putOntoBattlefield(game, fromZone, sourceId, controllerId, tapped, false, null); } @Override - public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown){ + public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown) { return this.putOntoBattlefield(game, fromZone, sourceId, controllerId, tapped, facedown, null); } - - @Override - public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown, ArrayList appliedEffects){ + + @Override + public boolean putOntoBattlefield(Game game, Zone fromZone, UUID sourceId, UUID controllerId, boolean tapped, boolean facedown, ArrayList appliedEffects) { ZoneChangeEvent event = new ZoneChangeEvent(this.objectId, sourceId, controllerId, fromZone, Zone.BATTLEFIELD, appliedEffects, tapped); if (facedown) { this.setFaceDown(true, game); @@ -582,7 +591,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { removed = true; break; default: - logger.warn("putOntoBattlefield, not fully implemented: fromZone="+fromZone); + logger.warn("putOntoBattlefield, not fully implemented: fromZone=" + fromZone); } game.rememberLKI(objectId, event.getFromZone(), this); if (!removed) { @@ -598,11 +607,13 @@ public abstract class CardImpl extends MageObjectImpl implements Card { game.setScopeRelevant(true); permanent.setTapped(tapped); permanent.setFaceDown(facedown, game); - permanent.entersBattlefield(sourceId, game, event.getFromZone(), true); + boolean entered = permanent.entersBattlefield(sourceId, game, event.getFromZone(), true); game.setScopeRelevant(false); game.applyEffects(); - game.addSimultaneousEvent(new ZoneChangeEvent(permanent, event.getPlayerId(), fromZone, Zone.BATTLEFIELD)); - return true; + if (entered) { + game.addSimultaneousEvent(new ZoneChangeEvent(permanent, event.getPlayerId(), fromZone, Zone.BATTLEFIELD)); + return true; + } } if (facedown) { this.setFaceDown(false, game); @@ -625,7 +636,7 @@ public abstract class CardImpl extends MageObjectImpl implements Card { GameEvent event = GameEvent.getEvent(GameEvent.EventType.TURNFACEUP, getId(), playerId); if (!game.replaceEvent(event)) { setFaceDown(false, game); - for (Ability ability :abilities) { // abilities that were set to not visible face down must be set to visible again + for (Ability ability : abilities) { // abilities that were set to not visible face down must be set to visible again if (ability.getWorksFaceDown() && !ability.getRuleVisible()) { ability.setRuleVisible(true); } @@ -678,7 +689,8 @@ public abstract class CardImpl extends MageObjectImpl implements Card { } @Override - public void build() {} + public void build() { + } @Override public boolean getUsesVariousArt() { diff --git a/Mage/src/mage/cards/Cards.java b/Mage/src/mage/cards/Cards.java index fffc342824a..313f183d6ad 100644 --- a/Mage/src/mage/cards/Cards.java +++ b/Mage/src/mage/cards/Cards.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.cards; import java.io.Serializable; @@ -39,18 +38,33 @@ import mage.game.Game; public interface Cards extends Set, Serializable { void add(Card card); + Card get(UUID cardId, Game game); + void remove(Card card); + void setOwner(UUID ownerId, Game game); + void addAll(List createCards); + + void addAll(Set createCards); + Set getCards(Game game); + Set getCards(FilterCard filter, Game game); + Set getCards(FilterCard filter, UUID sourceId, UUID playerId, Game game); + String getValue(Game game); + Collection getUniqueCards(Game game); + Card getRandom(Game game); + int count(FilterCard filter, Game game); + int count(FilterCard filter, UUID playerId, Game game); + int count(FilterCard filter, UUID sourceId, UUID playerId, Game game); Cards copy(); diff --git a/Mage/src/mage/cards/CardsImpl.java b/Mage/src/mage/cards/CardsImpl.java index c06e6db5f9a..d7799289e23 100644 --- a/Mage/src/mage/cards/CardsImpl.java +++ b/Mage/src/mage/cards/CardsImpl.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.cards; import java.io.Serializable; @@ -44,20 +43,20 @@ import mage.filter.FilterCard; import mage.game.Game; import mage.util.ThreadLocalStringBuilder; - /** * * @author BetaSteward_at_googlemail.com */ public class CardsImpl extends LinkedHashSet implements Cards, Serializable { - + private static final transient ThreadLocalStringBuilder threadLocalBuilder = new ThreadLocalStringBuilder(200); private static Random rnd = new Random(); private UUID ownerId; private Zone zone; - public CardsImpl() { } + public CardsImpl() { + } public CardsImpl(Card card) { if (card != null) { @@ -74,10 +73,10 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl public CardsImpl(Zone zone) { this.zone = zone; } - + public CardsImpl(Zone zone, Collection cards) { this(zone); - for (Card card: cards) { + for (Card card : cards) { this.add(card.getId()); } } @@ -117,7 +116,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public void setOwner(UUID ownerId, Game game) { this.ownerId = ownerId; - for (UUID card: this) { + for (UUID card : this) { game.getCard(card).setOwnerId(ownerId); } } @@ -134,7 +133,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public int count(FilterCard filter, Game game) { int result = 0; - for (UUID cardId: this) { + for (UUID cardId : this) { if (filter.match(game.getCard(cardId), game)) { result++; } @@ -145,7 +144,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public int count(FilterCard filter, UUID playerId, Game game) { int result = 0; - for (UUID card: this) { + for (UUID card : this) { if (filter.match(game.getCard(card), playerId, game)) { result++; } @@ -159,7 +158,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl return count(filter, playerId, game); } int result = 0; - for (UUID card: this) { + for (UUID card : this) { if (filter.match(game.getCard(card), sourceId, playerId, game)) { result++; } @@ -170,7 +169,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public Set getCards(FilterCard filter, UUID sourceId, UUID playerId, Game game) { Set cards = new LinkedHashSet<>(); - for (UUID card: this) { + for (UUID card : this) { boolean match = filter.match(game.getCard(card), sourceId, playerId, game); if (match) { cards.add(game.getCard(card)); @@ -182,7 +181,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public Set getCards(FilterCard filter, Game game) { Set cards = new LinkedHashSet<>(); - for (UUID card: this) { + for (UUID card : this) { boolean match = filter.match(game.getCard(card), game); if (match) { cards.add(game.getCard(card)); @@ -194,11 +193,11 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public Set getCards(Game game) { Set cards = new LinkedHashSet<>(); - for (UUID cardId: this) { + for (UUID cardId : this) { Card card = game.getCard(cardId); if (card != null) { // this can happen during the cancelation (player concedes) of a game cards.add(card); - } + } } return cards; } @@ -207,12 +206,12 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl public String getValue(Game game) { StringBuilder sb = threadLocalBuilder.get(); List cards = new ArrayList<>(); - for (UUID cardId: this) { + for (UUID cardId : this) { Card card = game.getCard(cardId); cards.add(card.getName()); } Collections.sort(cards); - for (String name: cards) { + for (String name : cards) { sb.append(name).append(":"); } return sb.toString(); @@ -220,7 +219,14 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public void addAll(List cards) { - for (Card card: cards) { + for (Card card : cards) { + add(card.getId()); + } + } + + @Override + public void addAll(Set cards) { + for (Card card : cards) { add(card.getId()); } } @@ -228,7 +234,7 @@ public class CardsImpl extends LinkedHashSet implements Cards, Serializabl @Override public Collection getUniqueCards(Game game) { Map cards = new HashMap<>(); - for(UUID cardId: this) { + for (UUID cardId : this) { Card card = game.getCard(cardId); if (!cards.containsKey(card.getName())) { cards.put(card.getName(), card); diff --git a/Mage/src/mage/cards/ExpansionSet.java b/Mage/src/mage/cards/ExpansionSet.java index 5a808a456c5..23c5649fbe3 100644 --- a/Mage/src/mage/cards/ExpansionSet.java +++ b/Mage/src/mage/cards/ExpansionSet.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.cards; import java.io.Serializable; @@ -61,7 +60,7 @@ public abstract class ExpansionSet implements Serializable { protected int numBoosterCommon; protected int numBoosterUncommon; protected int numBoosterRare; - protected int numBoosterDoubleFaced; + protected int numBoosterDoubleFaced; // -1 = include normally 0 = exclude 1-n = include explicit protected int ratioBoosterMythic; protected String packageName; @@ -112,18 +111,50 @@ public abstract class ExpansionSet implements Serializable { return name; } + public List create15CardBooster() { + // Forces 15 card booster packs. + // if the packs are too small, it adds commons to fill it out. + // if the packs are too big, it removes the first cards. + // since it adds lands then commons before uncommons + // and rares this should be the least disruptive. + List theBooster = this.createBooster(); + List commons = getCardsByRarity(Rarity.COMMON); + + while (15 > theBooster.size()) { + addToBooster(theBooster, commons); + } + + while (theBooster.size() > 15) { + theBooster.remove(0); + } + + return theBooster; + } + + protected void addToBooster(List booster, List cards) { + if (!cards.isEmpty()) { + CardInfo cardInfo = cards.remove(rnd.nextInt(cards.size())); + if (cardInfo != null) { + Card card = cardInfo.getCard(); + if (card != null) { + booster.add(card); + } + } + } + } + public List createBooster() { List booster = new ArrayList<>(); if (!hasBoosters) { return booster; } - + if (numBoosterLands > 0) { List basicLands = getCardsByRarity(Rarity.LAND); for (int i = 0; i < numBoosterLands; i++) { addToBooster(booster, basicLands); } - } + } List commons = getCardsByRarity(Rarity.COMMON); for (int i = 0; i < numBoosterCommon; i++) { addToBooster(booster, commons); @@ -217,7 +248,7 @@ public abstract class ExpansionSet implements Serializable { return booster; } - /* add double faced card for Innistrad booster + /* add double faced card for Innistrad booster * rarity near as the normal distribution */ private void addDoubleFace(List booster) { @@ -238,22 +269,10 @@ public abstract class ExpansionSet implements Serializable { } } - private void addToBooster(List booster, List cards) { - if (!cards.isEmpty()) { - CardInfo cardInfo = cards.remove(rnd.nextInt(cards.size())); - if (cardInfo != null) { - Card card = cardInfo.getCard(); - if (card != null) { - booster.add(card); - } - } - } - } - public boolean hasBoosters() { return hasBoosters; } - + public boolean hasBasicLands() { return hasBasicLands; } @@ -267,16 +286,18 @@ public abstract class ExpansionSet implements Serializable { } else { criteria.setCodes(this.code); } - criteria.rarities(rarity).doubleFaced(false); + criteria.rarities(rarity); + if (numBoosterDoubleFaced > -1) { + criteria.doubleFaced(false); + } if (maxCardNumberInBooster != Integer.MAX_VALUE) { criteria.maxCardNumber(maxCardNumberInBooster); } savedCardsInfos = CardRepository.instance.findCards(criteria); savedCards.put(rarity, savedCardsInfos); } - List cards = new ArrayList<>(); - cards.addAll(savedCardsInfos); - return cards; + // Return a copy of the saved cards information, as not to modify the original. + return new ArrayList<>(savedCardsInfos); } public List getSpecialCommon() { diff --git a/Mage/src/mage/cards/SplitCard.java b/Mage/src/mage/cards/SplitCard.java index 1bfe550d540..7aef9b2756d 100644 --- a/Mage/src/mage/cards/SplitCard.java +++ b/Mage/src/mage/cards/SplitCard.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.cards; import java.util.ArrayList; @@ -53,9 +52,9 @@ public abstract class SplitCard extends CardImpl { protected Card rightHalfCard; public SplitCard(UUID ownerId, int cardNumber, String nameLeft, String nameRight, Rarity rarity, CardType[] cardTypes, String costsLeft, String costsRight, boolean fused) { - super(ownerId, cardNumber, new StringBuilder(nameLeft).append(" // ").append(nameRight).toString(), rarity, cardTypes, costsLeft + costsRight, (fused ?SpellAbilityType.SPLIT_FUSED:SpellAbilityType.SPLIT)); - this.createLeftHalfCard(nameLeft, costsLeft); - this.createRightHalfCard(nameRight, costsRight); + super(ownerId, cardNumber, new StringBuilder(nameLeft).append(" // ").append(nameRight).toString(), rarity, cardTypes, costsLeft + costsRight, (fused ? SpellAbilityType.SPLIT_FUSED : SpellAbilityType.SPLIT)); + leftHalfCard = new SplitCardHalfImpl(this.getOwnerId(), this.getCardNumber(), nameLeft, this.rarity, cardTypes, costsLeft, this, SpellAbilityType.SPLIT_LEFT); + rightHalfCard = new SplitCardHalfImpl(this.getOwnerId(), this.getCardNumber(), nameRight, this.rarity, cardTypes, costsRight, this, SpellAbilityType.SPLIT_RIGHT); this.splitCard = true; } @@ -65,29 +64,11 @@ public abstract class SplitCard extends CardImpl { this.rightHalfCard = card.rightHalfCard.copy(); } - private Card createLeftHalfCard (String nameLeft, String costsLeft) { - CardType[] cardTypes = new CardType[getCardType().size()]; - this.getCardType().toArray(cardTypes); - leftHalfCard = new LeftHalfCard(this.getOwnerId(), this.getCardNumber(), nameLeft, this.rarity, cardTypes, costsLeft, this); - //leftHalfCard.getAbilities().setSourceId(objectId); + public Card getLeftHalfCard() { return leftHalfCard; } - private Card createRightHalfCard (String nameRight, String costsRight) { - CardType[] cardTypes = new CardType[getCardType().size()]; - this.getCardType().toArray(cardTypes); - rightHalfCard = new RightHalfCard(this.getOwnerId(), this.getCardNumber(), nameRight, this.rarity, cardTypes, costsRight, this); - //rightHalfCard.getAbilities().setSourceId(objectId); - return rightHalfCard; - } - - - - public Card getLeftHalfCard () { - return leftHalfCard; - } - - public Card getRightHalfCard () { + public Card getRightHalfCard() { return rightHalfCard; } @@ -114,7 +95,7 @@ public abstract class SplitCard extends CardImpl { @Override public boolean cast(Game game, Zone fromZone, SpellAbility ability, UUID controllerId) { - switch(ability.getSpellAbilityType()) { + switch (ability.getSpellAbilityType()) { case SPLIT_LEFT: return this.getLeftHalfCard().cast(game, fromZone, ability, controllerId); case SPLIT_RIGHT: @@ -131,17 +112,16 @@ public abstract class SplitCard extends CardImpl { game.setZone(getRightHalfCard().getId(), zone); } - @Override - public Abilities getAbilities(){ + public Abilities getAbilities() { Abilities allAbilites = new AbilitiesImpl<>(); for (Ability ability : super.getAbilities()) { - if (ability instanceof SpellAbility && !((SpellAbility)ability).getSpellAbilityType().equals(SpellAbilityType.SPLIT)) { + if (ability instanceof SpellAbility && !((SpellAbility) ability).getSpellAbilityType().equals(SpellAbilityType.SPLIT)) { allAbilites.add(ability); } } allAbilites.addAll(leftHalfCard.getAbilities()); - allAbilites.addAll(rightHalfCard.getAbilities()); + allAbilites.addAll(rightHalfCard.getAbilities()); return allAbilites; } @@ -149,15 +129,15 @@ public abstract class SplitCard extends CardImpl { public Abilities getAbilities(Game game) { Abilities allAbilites = new AbilitiesImpl<>(); for (Ability ability : super.getAbilities(game)) { - if (ability instanceof SpellAbility && !((SpellAbility)ability).getSpellAbilityType().equals(SpellAbilityType.SPLIT)) { + if (ability instanceof SpellAbility && !((SpellAbility) ability).getSpellAbilityType().equals(SpellAbilityType.SPLIT)) { allAbilites.add(ability); } } allAbilites.addAll(leftHalfCard.getAbilities(game)); - allAbilites.addAll(rightHalfCard.getAbilities(game)); + allAbilites.addAll(rightHalfCard.getAbilities(game)); return allAbilites; } - + @Override public List getRules() { List rules = new ArrayList<>(); @@ -179,136 +159,3 @@ public abstract class SplitCard extends CardImpl { } } - -/* - * The left side card of the split card - */ -class LeftHalfCard extends CardImpl { - - SplitCard splitCardParent; - - public LeftHalfCard(UUID ownerId, int cardNumber, String name, Rarity rarity, CardType[] cardTypes, String costs, SplitCard splitCardParent) { - super(ownerId, cardNumber, name, rarity, cardTypes, costs, SpellAbilityType.SPLIT_LEFT); - this.splitCardParent = splitCardParent; - } - - public LeftHalfCard(final LeftHalfCard card) { - super(card); - this.splitCardParent = card.splitCardParent; - } - - @Override - public LeftHalfCard copy() { - return new LeftHalfCard(this); - } - - @Override - public UUID getOwnerId() { - return splitCardParent.getOwnerId(); - } - - @Override - public String getImageName() { - return splitCardParent.getImageName(); - } - - @Override - public String getExpansionSetCode() { - return splitCardParent.getExpansionSetCode(); - } - - @Override - public int getCardNumber() { - return splitCardParent.getCardNumber(); - } - - @Override - public boolean moveToZone(Zone toZone, UUID sourceId, Game game, boolean flag, ArrayList appliedEffects) { - return splitCardParent.moveToZone(toZone, sourceId, game, flag, appliedEffects); - } - - @Override - public boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game, ArrayList appliedEffects) { - return splitCardParent.moveToExile(exileId, name, sourceId, game, appliedEffects); - } - - @Override - public Card getMainCard() { - return splitCardParent; - } - - @Override - public void setZone(Zone zone, Game game) { - super.setZone(zone, game); - game.setZone(splitCardParent.getId(), zone); - game.setZone(splitCardParent.getRightHalfCard().getId(), zone); - } - - -} - -/* - * The right side card of the split card - */ -class RightHalfCard extends CardImpl { - - SplitCard splitCardParent; - - public RightHalfCard(UUID ownerId, int cardNumber, String name, Rarity rarity, CardType[] cardTypes, String costs, SplitCard splitCardParent) { - super(ownerId, cardNumber, name, rarity, cardTypes, costs, SpellAbilityType.SPLIT_RIGHT); - this.splitCardParent = splitCardParent; - } - - public RightHalfCard(final RightHalfCard card) { - super(card); - this.splitCardParent = card.splitCardParent; - } - - @Override - public RightHalfCard copy() { - return new RightHalfCard(this); - } - - @Override - public UUID getOwnerId() { - return splitCardParent.getOwnerId(); - } - - @Override - public String getImageName() { - return splitCardParent.getImageName(); - } - - @Override - public String getExpansionSetCode() { - return splitCardParent.getExpansionSetCode(); - } - - @Override - public int getCardNumber() { - return splitCardParent.getCardNumber(); - } - - @Override - public boolean moveToZone(Zone toZone, UUID sourceId, Game game, boolean flag, ArrayList appliedEffects) { - return splitCardParent.moveToZone(toZone, sourceId, game, flag, appliedEffects); - } - - @Override - public boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game, ArrayList appliedEffects) { - return splitCardParent.moveToExile(exileId, name, sourceId, game, appliedEffects); - } - - @Override - public Card getMainCard() { - return splitCardParent; - } - - @Override - public void setZone(Zone zone, Game game) { - super.setZone(zone, game); - game.setZone(splitCardParent.getId(), zone); - game.setZone(splitCardParent.getLeftHalfCard().getId(), zone); - } - -} diff --git a/Mage/src/mage/cards/SplitCardHalf.java b/Mage/src/mage/cards/SplitCardHalf.java new file mode 100644 index 00000000000..52fa1086bb6 --- /dev/null +++ b/Mage/src/mage/cards/SplitCardHalf.java @@ -0,0 +1,16 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.cards; + +/** + * + * @author LevelX2 + */ +public interface SplitCardHalf extends Card { + + @Override + Card copy(); +} diff --git a/Mage/src/mage/cards/SplitCardHalfImpl.java b/Mage/src/mage/cards/SplitCardHalfImpl.java new file mode 100644 index 00000000000..af6cc3f6ab6 --- /dev/null +++ b/Mage/src/mage/cards/SplitCardHalfImpl.java @@ -0,0 +1,81 @@ +/* + * To change this license header, choose License Headers in Project Properties. + * To change this template file, choose Tools | Templates + * and open the template in the editor. + */ +package mage.cards; + +import java.util.ArrayList; +import java.util.UUID; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.SpellAbilityType; +import mage.constants.Zone; +import mage.game.Game; + +/** + * + * @author LevelX2 + */ +public class SplitCardHalfImpl extends CardImpl implements SplitCardHalf { + + SplitCard splitCardParent; + + public SplitCardHalfImpl(UUID ownerId, int cardNumber, String name, Rarity rarity, CardType[] cardTypes, String costs, SplitCard splitCardParent, SpellAbilityType spellAbilityType) { + super(ownerId, cardNumber, name, rarity, cardTypes, costs, spellAbilityType); + this.splitCardParent = splitCardParent; + } + + public SplitCardHalfImpl(final SplitCardHalfImpl card) { + super(card); + this.splitCardParent = card.splitCardParent; + } + + @Override + public UUID getOwnerId() { + return splitCardParent.getOwnerId(); + } + + @Override + public String getImageName() { + return splitCardParent.getImageName(); + } + + @Override + public String getExpansionSetCode() { + return splitCardParent.getExpansionSetCode(); + } + + @Override + public int getCardNumber() { + return splitCardParent.getCardNumber(); + } + + @Override + public boolean moveToZone(Zone toZone, UUID sourceId, Game game, boolean flag, ArrayList appliedEffects) { + return splitCardParent.moveToZone(toZone, sourceId, game, flag, appliedEffects); + } + + @Override + public boolean moveToExile(UUID exileId, String name, UUID sourceId, Game game, ArrayList appliedEffects) { + return splitCardParent.moveToExile(exileId, name, sourceId, game, appliedEffects); + } + + @Override + public Card getMainCard() { + return splitCardParent; + } + + @Override + public void setZone(Zone zone, Game game) { + game.setZone(splitCardParent.getId(), zone); + game.setZone(splitCardParent.getLeftHalfCard().getId(), zone); + game.setZone(splitCardParent.getRightHalfCard().getId(), zone); + } + + @Override + public SplitCardHalfImpl copy() { + return new SplitCardHalfImpl(this); + } + +} diff --git a/Mage/src/mage/cards/decks/importer/DckDeckImporter.java b/Mage/src/mage/cards/decks/importer/DckDeckImporter.java index ec57409bed3..f73423228e0 100644 --- a/Mage/src/mage/cards/decks/importer/DckDeckImporter.java +++ b/Mage/src/mage/cards/decks/importer/DckDeckImporter.java @@ -40,7 +40,7 @@ import mage.cards.repository.CardRepository; */ public class DckDeckImporter extends DeckImporter { - private static final Pattern pattern = Pattern.compile("(SB:)?\\s*(\\d*)\\s*\\[([a-zA-Z0-9]{2,4}):(\\d*)\\].*"); + private static final Pattern pattern = Pattern.compile("(SB:)?\\s*(\\d*)\\s*\\[([a-zA-Z0-9]{2,5}):(\\d*)\\].*"); @Override protected void readLine(String line, DeckCardLists deckList) { @@ -59,7 +59,7 @@ public class DckDeckImporter extends DeckImporter { String setCode = m.group(3); int cardNum = Integer.parseInt(m.group(4)); - DeckCardInfo deckCardInfo = null; + DeckCardInfo deckCardInfo = null; CardInfo cardInfo = CardRepository.instance.findCard(setCode, cardNum); if (cardInfo != null) { deckCardInfo = new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode()); diff --git a/Mage/src/mage/cards/decks/importer/DecDeckImporter.java b/Mage/src/mage/cards/decks/importer/DecDeckImporter.java index 3dc368d3065..617313d634e 100644 --- a/Mage/src/mage/cards/decks/importer/DecDeckImporter.java +++ b/Mage/src/mage/cards/decks/importer/DecDeckImporter.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,16 +20,13 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.cards.decks.importer; -import java.util.List; -import java.util.Random; import mage.cards.decks.DeckCardInfo; import mage.cards.decks.DeckCardLists; import mage.cards.repository.CardInfo; @@ -58,17 +55,15 @@ public class DecDeckImporter extends DeckImporter { String lineName = line.substring(delim).trim(); try { int num = Integer.parseInt(lineNum); - List cards = CardRepository.instance.findCards(lineName); - if (cards.isEmpty()) { + CardInfo cardInfo = CardRepository.instance.findPreferedCoreExpansionCard(lineName); + if (cardInfo == null) { sbMessage.append("Could not find card: '").append(lineName).append("' at line ").append(lineCount).append("\n"); } else { - Random random = new Random(); for (int i = 0; i < num; i++) { - CardInfo cardInfo = cards.get(random.nextInt(cards.size())); if (!sideboard) { - deckList.getCards().add(new DeckCardInfo(cardInfo.getName(),cardInfo.getCardNumber(), cardInfo.getSetCode())); + deckList.getCards().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } else { - deckList.getSideboard().add(new DeckCardInfo(cardInfo.getName(),cardInfo.getCardNumber(), cardInfo.getSetCode())); + deckList.getSideboard().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } } } diff --git a/Mage/src/mage/cards/decks/importer/MWSDeckImporter.java b/Mage/src/mage/cards/decks/importer/MWSDeckImporter.java index 09a19efe91c..3b29c552950 100644 --- a/Mage/src/mage/cards/decks/importer/MWSDeckImporter.java +++ b/Mage/src/mage/cards/decks/importer/MWSDeckImporter.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,7 +20,7 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. @@ -63,27 +63,28 @@ public class MWSDeckImporter extends DeckImporter { String lineName = line.substring(delim + 1).trim(); try { int num = Integer.parseInt(lineNum); - List cards = null; + CardInfo cardInfo = null; if (!setCode.isEmpty()) { CardCriteria criteria = new CardCriteria(); criteria.name(lineName); criteria.setCodes(setCode); + List cards = null; cards = CardRepository.instance.findCards(criteria); - } - if (cards == null || cards.isEmpty()) { - cards = CardRepository.instance.findCards(lineName); + if (!cards.isEmpty()) { + cardInfo = cards.get(new Random().nextInt(cards.size())); + } + } else { + cardInfo = CardRepository.instance.findPreferedCoreExpansionCard(lineName); } - if (cards.isEmpty()) { + if (cardInfo == null) { sbMessage.append("Could not find card: '").append(lineName).append("' at line ").append(lineCount).append("\n"); } else { - Random random = new Random(); for (int i = 0; i < num; i++) { - CardInfo cardInfo = cards.get(random.nextInt(cards.size())); if (!sideboard) { - deckList.getCards().add(new DeckCardInfo(cardInfo.getName(),cardInfo.getCardNumber(), cardInfo.getSetCode())); + deckList.getCards().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } else { - deckList.getSideboard().add(new DeckCardInfo(cardInfo.getName(),cardInfo.getCardNumber(), cardInfo.getSetCode())); + deckList.getSideboard().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } } } diff --git a/Mage/src/mage/cards/decks/importer/TxtDeckImporter.java b/Mage/src/mage/cards/decks/importer/TxtDeckImporter.java index 20a0a050b4e..dbfb00b268b 100644 --- a/Mage/src/mage/cards/decks/importer/TxtDeckImporter.java +++ b/Mage/src/mage/cards/decks/importer/TxtDeckImporter.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,27 +20,20 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.cards.decks.importer; import java.util.Arrays; -import java.util.Date; -import java.util.GregorianCalendar; import java.util.HashSet; -import java.util.List; import java.util.Set; import mage.cards.decks.DeckCardInfo; import mage.cards.decks.DeckCardLists; import mage.cards.repository.CardInfo; import mage.cards.repository.CardRepository; -import mage.cards.repository.ExpansionInfo; -import mage.cards.repository.ExpansionRepository; -import mage.constants.SetType; /** * @@ -48,15 +41,19 @@ import mage.constants.SetType; */ public class TxtDeckImporter extends DeckImporter { - public static final String[] SET_VALUES = new String[] { "lands", "creatures", "planeswalkers","other spells","sideboard cards" }; + public static final String[] SET_VALUES = new String[]{"lands", "creatures", "planeswalkers", "other spells", "sideboard cards", + "Instant", "Land", "Enchantment", "Artifact", "Sorcery", "Planeswalker", "Creature"}; public static final Set IGNORE_NAMES = new HashSet<>(Arrays.asList(SET_VALUES)); - + private boolean sideboard = false; private int emptyLinesInARow = 0; - @Override protected void readLine(String line, DeckCardLists deckList) { + if (line.toLowerCase().contains("sideboard")) { + sideboard = true; + return; + } if (line.startsWith("//")) { return; } @@ -70,57 +67,34 @@ public class TxtDeckImporter extends DeckImporter { emptyLinesInARow = 0; } - if (line.toLowerCase().startsWith("sideboard")) { - sideboard = true; - return; - } - - line = line.replace("\t"," "); // changing tabs to blanks as delimiter + line = line.replace("\t", " "); // changing tabs to blanks as delimiter int delim = line.indexOf(' '); if (delim < 0) { return; } String lineNum = line.substring(0, delim).trim(); - String lineName = line.substring(delim).replace("’","\'").trim(); - lineName = lineName.replace("&","//").replace("Æ", "AE").replace("ö", "ö"); + String lineName = line.substring(delim).replace("’", "\'").trim(); + lineName = lineName.replace("&", "//").replace("Æ", "AE").replace("ö", "ö"); if (lineName.contains("//") && !lineName.contains(" // ")) { - lineName = lineName.replace("//"," // "); + lineName = lineName.replace("//", " // "); } - if (IGNORE_NAMES.contains(lineName)) { + if (lineName.contains(" / ")) { + lineName = lineName.replace(" / ", " // "); + } + if (IGNORE_NAMES.contains(lineName) || IGNORE_NAMES.contains(lineNum)) { return; } try { - int num = Integer.parseInt(lineNum); - List cards = CardRepository.instance.findCards(lineName); - if (cards.isEmpty()) { + int num = Integer.parseInt(lineNum.replaceAll("\\D+", "")); + CardInfo cardInfo = CardRepository.instance.findPreferedCoreExpansionCard(lineName); + if (cardInfo == null) { sbMessage.append("Could not find card: '").append(lineName).append("' at line ").append(lineCount).append("\n"); } else { - // search the card released last with this name - Date lastReleaseDate = new GregorianCalendar(1900, 1, 1).getTime(); - Date lastExpansionDate = new GregorianCalendar(1900, 1, 1).getTime(); - CardInfo cardToUse = null; - for (CardInfo cardinfo: cards) { - ExpansionInfo set = ExpansionRepository.instance.getSetByCode(cardinfo.getSetCode()); - if (set != null) { - if ((set.getType().equals(SetType.EXPANSION) || set.getType().equals(SetType.CORE)) && - (lastExpansionDate == null || set.getReleaseDate().after(lastExpansionDate))) { - cardToUse = cardinfo; - lastExpansionDate = set.getReleaseDate(); - } - if (lastExpansionDate == null && (lastReleaseDate == null || set.getReleaseDate().after(lastReleaseDate))) { - cardToUse = cardinfo; - lastReleaseDate = set.getReleaseDate(); - } - } - } - if (cardToUse == null) { - cardToUse = cards.get(0); - } for (int i = 0; i < num; i++) { if (!sideboard) { - deckList.getCards().add(new DeckCardInfo(cardToUse.getName(),cardToUse.getCardNumber(), cardToUse.getSetCode())); + deckList.getCards().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } else { - deckList.getSideboard().add(new DeckCardInfo(cardToUse.getName(),cardToUse.getCardNumber(), cardToUse.getSetCode())); + deckList.getSideboard().add(new DeckCardInfo(cardInfo.getName(), cardInfo.getCardNumber(), cardInfo.getSetCode())); } } } diff --git a/Mage/src/mage/cards/repository/CardRepository.java b/Mage/src/mage/cards/repository/CardRepository.java index 3fa5172d4f5..96b798397b0 100644 --- a/Mage/src/mage/cards/repository/CardRepository.java +++ b/Mage/src/mage/cards/repository/CardRepository.java @@ -1,356 +1,401 @@ -/* - * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without modification, are - * permitted provided that the following conditions are met: - * - * 1. Redistributions of source code must retain the above copyright notice, this list of - * conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright notice, this list - * of conditions and the following disclaimer in the documentation and/or other materials - * provided with the distribution. - * - * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND - * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR - * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR - * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR - * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON - * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING - * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF - * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * - * The views and conclusions contained in the software and documentation are those of the - * authors and should not be interpreted as representing official policies, either expressed - * or implied, of BetaSteward_at_googlemail.com. - */ -package mage.cards.repository; - -import com.j256.ormlite.dao.Dao; -import com.j256.ormlite.dao.DaoManager; -import com.j256.ormlite.jdbc.JdbcConnectionSource; -import com.j256.ormlite.stmt.QueryBuilder; -import com.j256.ormlite.stmt.SelectArg; -import com.j256.ormlite.stmt.Where; -import com.j256.ormlite.support.ConnectionSource; -import com.j256.ormlite.support.DatabaseConnection; -import com.j256.ormlite.table.TableUtils; -import java.io.File; -import java.sql.SQLException; -import java.util.ArrayList; -import java.util.List; -import java.util.Random; -import java.util.Set; -import java.util.TreeSet; -import java.util.concurrent.Callable; -import mage.constants.CardType; -import org.apache.log4j.Logger; - -/** - * - * @author North - */ -public enum CardRepository { - - instance; - - private static final String JDBC_URL = "jdbc:h2:file:./db/cards.h2;AUTO_SERVER=TRUE"; - private static final String VERSION_ENTITY_NAME = "card"; - // raise this if db structure was changed - private static final long CARD_DB_VERSION = 41; - // raise this if new cards were added to the server - private static final long CARD_CONTENT_VERSION = 26; - - private final Random random = new Random(); - private Dao cardDao; - private Set classNames; - - private CardRepository() { - File file = new File("db"); - if (!file.exists()) { - file.mkdirs(); - } - try { - ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); - boolean obsolete = RepositoryUtil.isDatabaseObsolete(connectionSource, VERSION_ENTITY_NAME, CARD_DB_VERSION); - - if (obsolete) { - TableUtils.dropTable(connectionSource, CardInfo.class, true); - } - - TableUtils.createTableIfNotExists(connectionSource, CardInfo.class); - cardDao = DaoManager.createDao(connectionSource, CardInfo.class); - } catch (SQLException ex) { - ex.printStackTrace(); - } - } - - public void addCards(final List cards) { - try { - cardDao.callBatchTasks(new Callable() { - @Override - public Object call() throws Exception { - try { - for (CardInfo card : cards) { - cardDao.create(card); - if (classNames != null) { - classNames.add(card.getClassName()); - } - } - } catch (SQLException ex) { - Logger.getLogger(CardRepository.class).error("Error adding cards to DB: " + ex.getCause()); - } - return null; - } - }); - } catch (Exception ex) { - } - } - - public boolean cardExists(String className) { - try { - if (classNames == null) { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("className").where().isNotNull("className"); - List results = cardDao.query(qb.prepare()); - classNames = new TreeSet<>(); - for (CardInfo card : results) { - classNames.add(card.getClassName()); - } - } - return classNames.contains(className); - } catch (SQLException ex) { - } - return false; - } - - public Set getNames() { - Set names = new TreeSet<>(); - try { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("name"); - List results = cardDao.query(qb.prepare()); - for (CardInfo card : results) { - int result = card.getName().indexOf(" // "); - if (result > 0) { - names.add(card.getName().substring(0, result)); - names.add(card.getName().substring(result + 4)); - } else { - names.add(card.getName()); - } - } - } catch (SQLException ex) { - } - return names; - } - - public Set getNonLandNames() { - Set names = new TreeSet<>(); - try { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("name"); - qb.where().not().like("types", new SelectArg('%' + CardType.LAND.name() + '%')); - List results = cardDao.query(qb.prepare()); - for (CardInfo card : results) { - int result = card.getName().indexOf(" // "); - if (result > 0) { - names.add(card.getName().substring(0, result)); - names.add(card.getName().substring(result + 4)); - } else { - names.add(card.getName()); - } - } - } catch (SQLException ex) { - } - return names; - } - - public Set getCreatureNames() { - Set names = new TreeSet<>(); - try { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("name"); - qb.where().like("types", new SelectArg('%' + CardType.CREATURE.name() + '%')); - List results = cardDao.query(qb.prepare()); - for (CardInfo card : results) { - int result = card.getName().indexOf(" // "); - if (result > 0) { - names.add(card.getName().substring(0, result)); - names.add(card.getName().substring(result + 4)); - } else { - names.add(card.getName()); - } - } - } catch (SQLException ex) { - } - return names; - } - - public Set getNonLandAndNonCreatureNames() { - Set names = new TreeSet<>(); - try { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("name"); - Where where = qb.where(); - where.and(where.not().like("types", '%' + CardType.CREATURE.name() + '%'), where.not().like("types", '%' + CardType.LAND.name() + '%')); - List results = cardDao.query(qb.prepare()); - for (CardInfo card : results) { - int result = card.getName().indexOf(" // "); - if (result > 0) { - names.add(card.getName().substring(0, result)); - names.add(card.getName().substring(result + 4)); - } else { - names.add(card.getName()); - } - } - } catch (SQLException ex) { - } - return names; - } - - public Set getCreatureTypes() { - TreeSet subtypes = new TreeSet<>(); - try { - QueryBuilder qb = cardDao.queryBuilder(); - qb.distinct().selectColumns("subtypes"); - qb.where().like("types", new SelectArg('%' + CardType.CREATURE.name() + '%')); - List results = cardDao.query(qb.prepare()); - for (CardInfo card : results) { - subtypes.addAll(card.getSubTypes()); - } - // Removing Forest because of Dryad Arbor - subtypes.remove("Forest"); - // Some creature types are not directly included in card types and are added here manually - subtypes.add("Blinkmoth"); - subtypes.add("Camarid"); - subtypes.add("Caribou"); - subtypes.add("Citizen"); - subtypes.add("Coward"); - subtypes.add("Deserter"); - subtypes.add("Germ"); - subtypes.add("Graveborn"); - subtypes.add("Orb"); - subtypes.add("Pentavite"); - subtypes.add("Pincher"); - subtypes.add("Prism"); - subtypes.add("Reflection"); - subtypes.add("Sand"); - subtypes.add("Saproling"); - subtypes.add("Serf"); - subtypes.add("Splinter"); - subtypes.add("Survivor"); - subtypes.add("Tetravite"); - subtypes.add("Triskelavite"); - - } catch (SQLException ex) { - } - return subtypes; - } - - public CardInfo findCard(String setCode, int cardNumber) { - try { - QueryBuilder queryBuilder = cardDao.queryBuilder(); - queryBuilder.where().eq("setCode", new SelectArg(setCode)).and().eq("cardNumber", cardNumber).and().eq("nightCard", false); - List result = cardDao.query(queryBuilder.prepare()); - if (!result.isEmpty()) { - return result.get(0); - } - } catch (SQLException ex) { - } - return null; - } - - public List getClassNames() { - List names = new ArrayList<>(); - try { - List results = cardDao.queryForAll(); - for (CardInfo card : results) { - names.add(card.getClassName()); - } - } catch (SQLException ex) { - } - return names; - } - - public List getMissingCards(List classNames) { - try { - QueryBuilder queryBuilder = cardDao.queryBuilder(); - queryBuilder.where().not().in("className", classNames); - - return cardDao.query(queryBuilder.prepare()); - } catch (SQLException ex) { - } - return new ArrayList<>(); - } - - /** - * - * @param name - * @return random card with the provided name or null if none is found - */ - public CardInfo findCard(String name) { - List cards = findCards(name); - if (!cards.isEmpty()) { - return cards.get(random.nextInt(cards.size())); - } - return null; - } - - public List findCards(String name) { - try { - QueryBuilder queryBuilder = cardDao.queryBuilder(); - queryBuilder.where().eq("name", new SelectArg(name)); - - return cardDao.query(queryBuilder.prepare()); - } catch (SQLException ex) { - } - return new ArrayList<>(); - } - - public List findCards(CardCriteria criteria) { - try { - QueryBuilder queryBuilder = cardDao.queryBuilder(); - criteria.buildQuery(queryBuilder); - - return cardDao.query(queryBuilder.prepare()); - } catch (SQLException ex) { - } - return new ArrayList<>(); - } - - public long getContentVersionFromDB() { - try { - ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); - return RepositoryUtil.getDatabaseVersion(connectionSource, VERSION_ENTITY_NAME + "Content"); - } catch (SQLException ex) { - ex.printStackTrace(); - } - return 0; - } - - public void setContentVersion(long version) { - try { - ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); - RepositoryUtil.updateVersion(connectionSource, VERSION_ENTITY_NAME + "Content", version); - } catch (SQLException ex) { - ex.printStackTrace(); - } - } - - public long getContentVersionConstant() { - return CARD_CONTENT_VERSION; - } - - public void closeDB() { - try { - if (cardDao != null && cardDao.getConnectionSource() != null) { - DatabaseConnection conn = cardDao.getConnectionSource().getReadWriteConnection(); - conn.executeStatement("shutdown compact", 0); - } - - } catch (SQLException ex) { - - } - } -} +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.cards.repository; + +import com.j256.ormlite.dao.Dao; +import com.j256.ormlite.dao.DaoManager; +import com.j256.ormlite.jdbc.JdbcConnectionSource; +import com.j256.ormlite.stmt.QueryBuilder; +import com.j256.ormlite.stmt.SelectArg; +import com.j256.ormlite.stmt.Where; +import com.j256.ormlite.support.ConnectionSource; +import com.j256.ormlite.support.DatabaseConnection; +import com.j256.ormlite.table.TableUtils; +import java.io.File; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.Date; +import java.util.GregorianCalendar; +import java.util.List; +import java.util.Random; +import java.util.Set; +import java.util.TreeSet; +import java.util.concurrent.Callable; +import mage.constants.CardType; +import mage.constants.SetType; +import org.apache.log4j.Logger; + +/** + * + * @author North + */ +public enum CardRepository { + + instance; + + private static final String JDBC_URL = "jdbc:h2:file:./db/cards.h2;AUTO_SERVER=TRUE"; + private static final String VERSION_ENTITY_NAME = "card"; + // raise this if db structure was changed + private static final long CARD_DB_VERSION = 41; + // raise this if new cards were added to the server + private static final long CARD_CONTENT_VERSION = 32; + + private final Random random = new Random(); + private Dao cardDao; + private Set classNames; + + private CardRepository() { + File file = new File("db"); + if (!file.exists()) { + file.mkdirs(); + } + try { + ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); + boolean obsolete = RepositoryUtil.isDatabaseObsolete(connectionSource, VERSION_ENTITY_NAME, CARD_DB_VERSION); + + if (obsolete) { + TableUtils.dropTable(connectionSource, CardInfo.class, true); + } + + TableUtils.createTableIfNotExists(connectionSource, CardInfo.class); + cardDao = DaoManager.createDao(connectionSource, CardInfo.class); + } catch (SQLException ex) { + ex.printStackTrace(); + } + } + + public void addCards(final List cards) { + try { + cardDao.callBatchTasks(new Callable() { + @Override + public Object call() throws Exception { + try { + for (CardInfo card : cards) { + cardDao.create(card); + if (classNames != null) { + classNames.add(card.getClassName()); + } + } + } catch (SQLException ex) { + Logger.getLogger(CardRepository.class).error("Error adding cards to DB: " + ex.getCause()); + } + return null; + } + }); + } catch (Exception ex) { + } + } + + public boolean cardExists(String className) { + try { + if (classNames == null) { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("className").where().isNotNull("className"); + List results = cardDao.query(qb.prepare()); + classNames = new TreeSet<>(); + for (CardInfo card : results) { + classNames.add(card.getClassName()); + } + } + return classNames.contains(className); + } catch (SQLException ex) { + } + return false; + } + + public Set getNames() { + Set names = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("name"); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + int result = card.getName().indexOf(" // "); + if (result > 0) { + names.add(card.getName().substring(0, result)); + names.add(card.getName().substring(result + 4)); + } else { + names.add(card.getName()); + } + } + } catch (SQLException ex) { + } + return names; + } + + public Set getNonLandNames() { + Set names = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("name"); + qb.where().not().like("types", new SelectArg('%' + CardType.LAND.name() + '%')); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + int result = card.getName().indexOf(" // "); + if (result > 0) { + names.add(card.getName().substring(0, result)); + names.add(card.getName().substring(result + 4)); + } else { + names.add(card.getName()); + } + } + } catch (SQLException ex) { + } + return names; + } + + public Set getCreatureNames() { + Set names = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("name"); + qb.where().like("types", new SelectArg('%' + CardType.CREATURE.name() + '%')); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + int result = card.getName().indexOf(" // "); + if (result > 0) { + names.add(card.getName().substring(0, result)); + names.add(card.getName().substring(result + 4)); + } else { + names.add(card.getName()); + } + } + } catch (SQLException ex) { + } + return names; + } + + public Set getNonLandAndNonCreatureNames() { + Set names = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("name"); + Where where = qb.where(); + where.and(where.not().like("types", '%' + CardType.CREATURE.name() + '%'), where.not().like("types", '%' + CardType.LAND.name() + '%')); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + int result = card.getName().indexOf(" // "); + if (result > 0) { + names.add(card.getName().substring(0, result)); + names.add(card.getName().substring(result + 4)); + } else { + names.add(card.getName()); + } + } + } catch (SQLException ex) { + } + return names; + } + + public Set getCreatureTypes() { + TreeSet subtypes = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("subtypes"); + qb.where().like("types", new SelectArg('%' + CardType.CREATURE.name() + '%')); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + subtypes.addAll(card.getSubTypes()); + } + // Removing Forest because of Dryad Arbor + subtypes.remove("Forest"); + // Some creature types are not directly included in card types and are added here manually + subtypes.add("Blinkmoth"); + subtypes.add("Camarid"); + subtypes.add("Caribou"); + subtypes.add("Citizen"); + subtypes.add("Coward"); + subtypes.add("Deserter"); + subtypes.add("Germ"); + subtypes.add("Graveborn"); + subtypes.add("Orb"); + subtypes.add("Pentavite"); + subtypes.add("Pincher"); + subtypes.add("Prism"); + subtypes.add("Reflection"); + subtypes.add("Sand"); + subtypes.add("Saproling"); + subtypes.add("Serf"); + subtypes.add("Splinter"); + subtypes.add("Survivor"); + subtypes.add("Tetravite"); + subtypes.add("Triskelavite"); + + } catch (SQLException ex) { + } + return subtypes; + } + + public Set getLandTypes() { + TreeSet subtypes = new TreeSet<>(); + try { + QueryBuilder qb = cardDao.queryBuilder(); + qb.distinct().selectColumns("subtypes"); + qb.where().like("types", new SelectArg('%' + CardType.LAND.name() + '%')); + List results = cardDao.query(qb.prepare()); + for (CardInfo card : results) { + subtypes.addAll(card.getSubTypes()); + } + // Removing Dryad because of Dryad Arbor + subtypes.remove("Dryad"); + + } catch (SQLException ex) { + } + return subtypes; + } + + public CardInfo findCard(String setCode, int cardNumber) { + try { + QueryBuilder queryBuilder = cardDao.queryBuilder(); + queryBuilder.where().eq("setCode", new SelectArg(setCode)).and().eq("cardNumber", cardNumber).and().eq("nightCard", false); + List result = cardDao.query(queryBuilder.prepare()); + if (!result.isEmpty()) { + return result.get(0); + } + } catch (SQLException ex) { + } + return null; + } + + public List getClassNames() { + List names = new ArrayList<>(); + try { + List results = cardDao.queryForAll(); + for (CardInfo card : results) { + names.add(card.getClassName()); + } + } catch (SQLException ex) { + } + return names; + } + + public List getMissingCards(List classNames) { + try { + QueryBuilder queryBuilder = cardDao.queryBuilder(); + queryBuilder.where().not().in("className", classNames); + + return cardDao.query(queryBuilder.prepare()); + } catch (SQLException ex) { + } + return new ArrayList<>(); + } + + /** + * + * @param name + * @return random card with the provided name or null if none is found + */ + public CardInfo findCard(String name) { + List cards = findCards(name); + if (!cards.isEmpty()) { + return cards.get(random.nextInt(cards.size())); + } + return null; + } + + public CardInfo findPreferedCoreExpansionCard(String name) { + List cards = findCards(name); + if (!cards.isEmpty()) { + Date lastReleaseDate = new GregorianCalendar(1900, 1, 1).getTime(); + Date lastExpansionDate = new GregorianCalendar(1900, 1, 1).getTime(); + CardInfo cardToUse = null; + for (CardInfo cardinfo : cards) { + ExpansionInfo set = ExpansionRepository.instance.getSetByCode(cardinfo.getSetCode()); + if (set != null) { + if ((set.getType().equals(SetType.EXPANSION) || set.getType().equals(SetType.CORE)) + && (lastExpansionDate == null || set.getReleaseDate().after(lastExpansionDate))) { + cardToUse = cardinfo; + lastExpansionDate = set.getReleaseDate(); + } + if (lastExpansionDate == null && (lastReleaseDate == null || set.getReleaseDate().after(lastReleaseDate))) { + cardToUse = cardinfo; + lastReleaseDate = set.getReleaseDate(); + } + } + } + return cardToUse; + } + return null; + } + + public List findCards(String name) { + try { + QueryBuilder queryBuilder = cardDao.queryBuilder(); + queryBuilder.where().eq("name", new SelectArg(name)); + return cardDao.query(queryBuilder.prepare()); + } catch (SQLException ex) { + } + return new ArrayList<>(); + } + + public List findCards(CardCriteria criteria) { + try { + QueryBuilder queryBuilder = cardDao.queryBuilder(); + criteria.buildQuery(queryBuilder); + + return cardDao.query(queryBuilder.prepare()); + } catch (SQLException ex) { + } + return new ArrayList<>(); + } + + public long getContentVersionFromDB() { + try { + ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); + return RepositoryUtil.getDatabaseVersion(connectionSource, VERSION_ENTITY_NAME + "Content"); + } catch (SQLException ex) { + ex.printStackTrace(); + } + return 0; + } + + public void setContentVersion(long version) { + try { + ConnectionSource connectionSource = new JdbcConnectionSource(JDBC_URL); + RepositoryUtil.updateVersion(connectionSource, VERSION_ENTITY_NAME + "Content", version); + } catch (SQLException ex) { + ex.printStackTrace(); + } + } + + public long getContentVersionConstant() { + return CARD_CONTENT_VERSION; + } + + public void closeDB() { + try { + if (cardDao != null && cardDao.getConnectionSource() != null) { + DatabaseConnection conn = cardDao.getConnectionSource().getReadWriteConnection(); + conn.executeStatement("shutdown compact", 0); + } + + } catch (SQLException ex) { + + } + } +} diff --git a/Mage/src/mage/constants/AbilityWord.java b/Mage/src/mage/constants/AbilityWord.java index c050ab0e945..1ef899c62fd 100644 --- a/Mage/src/mage/constants/AbilityWord.java +++ b/Mage/src/mage/constants/AbilityWord.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.constants; /** @@ -33,15 +32,17 @@ package mage.constants; * @author LevelX2 */ public enum AbilityWord { + BLOODRUSH("Bloodrush"), CONSTELLATION("Constellation"), - FEROCIOUS("Ferocious"), + FEROCIOUS("Ferocious"), + FORMIDABLE("Formidable"), + GRANDEUR("Grandeur"), HELLBENT("Hellbent"), HEROIC("Heroic"), - FORMIDABLE("Formidable"), LANDFALL("Landfall"), METALCRAFT("Metalcraft"), - GRANDEUR("Grandeur"), + PARLEY("Parley"), RAID("Raid"); private final String text; diff --git a/Mage/src/mage/constants/Zone.java b/Mage/src/mage/constants/Zone.java index 52e6164223d..b5318c939ac 100644 --- a/Mage/src/mage/constants/Zone.java +++ b/Mage/src/mage/constants/Zone.java @@ -5,9 +5,19 @@ package mage.constants; * @author North */ public enum Zone { + HAND, GRAVEYARD, LIBRARY, BATTLEFIELD, STACK, EXILED, ALL, OUTSIDE, PICK, COMMAND; public boolean match(Zone zone) { return (this == zone || this == ALL || zone == ALL); } + + @Override + public String toString() { + if (this.equals(EXILED)) { + return "exile zone"; + } + return super.toString(); //To change body of generated methods, choose Tools | Templates. + } + } diff --git a/Mage/src/mage/counters/CounterType.java b/Mage/src/mage/counters/CounterType.java index e446016fa61..9b8aee1c616 100644 --- a/Mage/src/mage/counters/CounterType.java +++ b/Mage/src/mage/counters/CounterType.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.counters; /** @@ -34,6 +33,7 @@ package mage.counters; * @author nantuko */ public enum CounterType { + AGE("age"), AIM("aim"), ARROWHEAD("arrowhead"), @@ -55,6 +55,7 @@ public enum CounterType { FEATHER("feather"), FLOOD("flood"), FUSE("fuse"), + GOLD("gold"), HATCHLING("hatchling"), HOOFPRINT("hoofprint"), ICE("ice"), @@ -68,6 +69,7 @@ public enum CounterType { M1M1(new BoostCounter(-1, -1).name), MINING("mining"), P1P1(new BoostCounter(1, 1).name), + P2P2(new BoostCounter(2, 2).name), PAGE("page"), PAIN("pain"), PETRIFICATION("petrification"), @@ -75,14 +77,18 @@ public enum CounterType { POISON("poison"), PRESSURE("pressure"), QUEST("quest"), + SHIELD("shield"), + SHRED("shred"), SLIME("slime"), SPORE("spore"), STORAGE("storage"), + STRIFE("strife"), STUDY("study"), THEFT("theft"), TIME("time"), TOWER("tower"), VELOCITY("velocity"), + VERSE("verse"), VILE("vile"), WISH("wish"); @@ -111,7 +117,8 @@ public enum CounterType { } /** - * Create instance of counter type with defined amount of counters of the given type. + * Create instance of counter type with defined amount of counters of the + * given type. * * @param amount amount of counters of the given type. * @return @@ -120,10 +127,12 @@ public enum CounterType { switch (this) { case P1P1: return new BoostCounter(1, 1, amount); + case P2P2: + return new BoostCounter(2, 2, amount); case M1M1: return new BoostCounter(-1, -1, amount); default: return new Counter(name, amount); } } -} \ No newline at end of file +} diff --git a/Mage/src/mage/counters/Counters.java b/Mage/src/mage/counters/Counters.java index 6b1aca15edf..473106f081f 100644 --- a/Mage/src/mage/counters/Counters.java +++ b/Mage/src/mage/counters/Counters.java @@ -96,6 +96,16 @@ public class Counters extends HashMap implements Serializable { } } + public void removeAllCounters(CounterType counterType){ + removeAllCounters(counterType.getName()); + } + + public void removeAllCounters(String name){ + if (this.containsKey(name)){ + this.remove(name); + } + } + public int getCount(String name) { if (this.containsKey(name)) { return this.get(name).getCount(); diff --git a/Mage/src/mage/filter/FilterImpl.java b/Mage/src/mage/filter/FilterImpl.java index ecb3f9ee923..7def209d6ef 100644 --- a/Mage/src/mage/filter/FilterImpl.java +++ b/Mage/src/mage/filter/FilterImpl.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.filter; import java.util.ArrayList; @@ -52,7 +51,7 @@ public abstract class FilterImpl implements Filter { this.message = name; } - public FilterImpl(FilterImpl filter) { + public FilterImpl(FilterImpl filter) { this.message = filter.message; this.predicates = new ArrayList<>(filter.predicates); } diff --git a/Mage/src/mage/filter/FilterObject.java b/Mage/src/mage/filter/FilterObject.java index 29402389df3..3fc96e9c6b9 100644 --- a/Mage/src/mage/filter/FilterObject.java +++ b/Mage/src/mage/filter/FilterObject.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.filter; import mage.MageObject; @@ -46,7 +45,7 @@ public class FilterObject extends FilterImpl { super(name); } - public FilterObject(FilterObject filter) { + public FilterObject(FilterObject filter) { super(filter); } } diff --git a/Mage/src/mage/filter/FilterSpell.java b/Mage/src/mage/filter/FilterSpell.java index 258f2c9083d..9b6342aed7d 100644 --- a/Mage/src/mage/filter/FilterSpell.java +++ b/Mage/src/mage/filter/FilterSpell.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.filter; import java.util.UUID; @@ -50,13 +49,13 @@ public class FilterSpell extends FilterStackObject { public FilterSpell(final FilterSpell filter) { super(filter); } - + @Override - public boolean match(StackObject stackObject, UUID playerId, Game game) { + public boolean match(StackObject stackObject, UUID sourceId, UUID playerId, Game game) { if (!(stackObject instanceof Spell)) { return false; } - return super.match(stackObject, playerId, game); + return super.match(stackObject, sourceId, playerId, game); } @Override diff --git a/Mage/src/mage/filter/FilterStackObject.java b/Mage/src/mage/filter/FilterStackObject.java index 60a10aa913c..a7c478bd78a 100644 --- a/Mage/src/mage/filter/FilterStackObject.java +++ b/Mage/src/mage/filter/FilterStackObject.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.filter; import java.util.ArrayList; @@ -33,6 +32,7 @@ import java.util.List; import java.util.UUID; import mage.filter.predicate.ObjectPlayer; import mage.filter.predicate.ObjectPlayerPredicate; +import mage.filter.predicate.ObjectSourcePlayer; import mage.filter.predicate.Predicates; import mage.game.Game; import mage.game.permanent.Permanent; @@ -59,12 +59,12 @@ public class FilterStackObject extends FilterObject { this.extraPredicates = new ArrayList<>(filter.extraPredicates); } - public boolean match(StackObject stackObject, UUID playerId, Game game) { + public boolean match(StackObject stackObject, UUID sourceId, UUID playerId, Game game) { if (!this.match(stackObject, game)) { return false; } - return Predicates.and(extraPredicates).apply(new ObjectPlayer(stackObject, playerId), game); + return Predicates.and(extraPredicates).apply(new ObjectSourcePlayer(stackObject, sourceId, playerId), game); } public void add(ObjectPlayerPredicate predicate) { diff --git a/Mage/src/mage/filter/common/FilterSpellOrPermanent.java b/Mage/src/mage/filter/common/FilterSpellOrPermanent.java index 96631bbaaff..a4d3371cf63 100644 --- a/Mage/src/mage/filter/common/FilterSpellOrPermanent.java +++ b/Mage/src/mage/filter/common/FilterSpellOrPermanent.java @@ -1,5 +1,5 @@ /* - * + * * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. * * Redistribution and use in source and binary forms, with or without modification, are @@ -25,10 +25,11 @@ * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. - * + * */ package mage.filter.common; +import java.util.UUID; import mage.filter.FilterImpl; import mage.filter.FilterInPlay; import mage.filter.FilterPermanent; @@ -37,8 +38,6 @@ import mage.game.Game; import mage.game.permanent.Permanent; import mage.game.stack.Spell; -import java.util.UUID; - /** * * @author LevelX @@ -77,7 +76,7 @@ public class FilterSpellOrPermanent extends FilterImpl implements Filter @Override public boolean match(Object o, UUID sourceId, UUID playerId, Game game) { if (o instanceof Spell) { - return spellFilter.match((Spell) o, playerId, game); + return spellFilter.match((Spell) o, sourceId, playerId, game); } else if (o instanceof Permanent) { return permanentFilter.match((Permanent) o, sourceId, playerId, game); } diff --git a/Mage/src/mage/filter/predicate/mageobject/ChosenSubtypePredicate.java b/Mage/src/mage/filter/predicate/mageobject/ChosenSubtypePredicate.java new file mode 100644 index 00000000000..ca732ec3f98 --- /dev/null +++ b/Mage/src/mage/filter/predicate/mageobject/ChosenSubtypePredicate.java @@ -0,0 +1,57 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.filter.predicate.mageobject; + +import java.util.UUID; +import mage.MageObject; +import mage.filter.predicate.Predicate; +import mage.game.Game; + +/** + * + * @author LoneFox + */ +public class ChosenSubtypePredicate implements Predicate { + + private final UUID cardID; + + public ChosenSubtypePredicate(UUID cardID) { + this.cardID = cardID; + } + + @Override + public boolean apply(MageObject input, Game game) { + String subtype = (String) game.getState().getValue(cardID + "_type"); + return input.hasSubtype(subtype); + } + + @Override + public String toString() { + return "Chosen subtype"; + } +} diff --git a/Mage/src/mage/filter/predicate/mageobject/NumberOfTargetsPredicate.java b/Mage/src/mage/filter/predicate/mageobject/NumberOfTargetsPredicate.java index 787a14d2aca..7284bd1943d 100644 --- a/Mage/src/mage/filter/predicate/mageobject/NumberOfTargetsPredicate.java +++ b/Mage/src/mage/filter/predicate/mageobject/NumberOfTargetsPredicate.java @@ -34,7 +34,6 @@ import mage.filter.predicate.Predicate; import mage.game.Game; import mage.game.stack.Spell; import mage.target.Target; -import mage.target.Targets; /** * @@ -57,7 +56,7 @@ public class NumberOfTargetsPredicate implements Predicate { Mode mode = spell.getSpellAbility().getModes().get(modeId); for (Target target : mode.getTargets()) { numberOfTargets += target.getTargets().size(); - } + } } if (numberOfTargets == targets) { return true; diff --git a/Mage/src/mage/filter/predicate/permanent/CardCounterPredicate.java b/Mage/src/mage/filter/predicate/permanent/CardCounterPredicate.java new file mode 100644 index 00000000000..04fa0123400 --- /dev/null +++ b/Mage/src/mage/filter/predicate/permanent/CardCounterPredicate.java @@ -0,0 +1,36 @@ +package mage.filter.predicate.permanent; + +import mage.cards.Card; +import mage.counters.CounterType; +import mage.filter.predicate.Predicate; +import mage.game.Game; + +/** + * Created by glerman on 3/7/15. + */ +public class CardCounterPredicate implements Predicate{ + + private final CounterType counter; + + /** + * + * @param counter if null any counter selects the permanent + */ + public CardCounterPredicate(CounterType counter) { + this.counter = counter; + } + + @Override + public boolean apply(Card input, Game game) { + if (counter == null) { + return !input.getCounters(game).keySet().isEmpty(); + } else { + return input.getCounters(game).containsKey(counter); + } + } + + @Override + public String toString() { + return "CounterType(" + counter.getName() + ')'; + } +} diff --git a/Mage/src/mage/game/Exile.java b/Mage/src/mage/game/Exile.java index 821afc8d9a0..688a2727586 100644 --- a/Mage/src/mage/game/Exile.java +++ b/Mage/src/mage/game/Exile.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game; import java.io.Serializable; @@ -39,7 +38,6 @@ import java.util.UUID; import mage.cards.Card; import mage.util.Copyable; - /** * * @author BetaSteward_at_googlemail.com @@ -48,14 +46,14 @@ public class Exile implements Serializable, Copyable { private static final UUID PERMANENT = UUID.randomUUID(); - private Map exileZones = new HashMap(); + private Map exileZones = new HashMap<>(); public Exile() { createZone(PERMANENT, "Permanent"); } public Exile(final Exile exile) { - for (Entry entry: exile.exileZones.entrySet()) { + for (Entry entry : exile.exileZones.entrySet()) { exileZones.put(entry.getKey(), entry.getValue().copy()); } } @@ -93,7 +91,7 @@ public class Exile implements Serializable, Copyable { } public Card getCard(UUID cardId, Game game) { - for (ExileZone exile: exileZones.values()) { + for (ExileZone exile : exileZones.values()) { if (exile.contains(cardId)) { return game.getCard(cardId); } @@ -103,14 +101,14 @@ public class Exile implements Serializable, Copyable { public List getAllCards(Game game) { List cards = new ArrayList(); - for (ExileZone exile: exileZones.values()) { + for (ExileZone exile : exileZones.values()) { cards.addAll(exile.getCards(game)); } return cards; } public void removeCard(Card card, Game game) { - for (ExileZone exile: exileZones.values()) { + for (ExileZone exile : exileZones.values()) { if (exile.contains(card.getId())) { exile.remove(card); } @@ -123,7 +121,7 @@ public class Exile implements Serializable, Copyable { } public void clear() { - for (ExileZone exile: exileZones.values()) { + for (ExileZone exile : exileZones.values()) { exile.clear(); } } diff --git a/Mage/src/mage/game/Game.java b/Mage/src/mage/game/Game.java index 4e49903dc59..ff69876d5b6 100644 --- a/Mage/src/mage/game/Game.java +++ b/Mage/src/mage/game/Game.java @@ -154,6 +154,11 @@ public interface Game extends MageItem, Serializable { boolean canPlaySorcery(UUID playerId); + /** + * Id of the player the current turn it is. + * + * @return + */ UUID getActivePlayerId(); UUID getPriorityPlayerId(); diff --git a/Mage/src/mage/game/GameImpl.java b/Mage/src/mage/game/GameImpl.java index 9eb9c84baa4..2b0cd6990ca 100644 --- a/Mage/src/mage/game/GameImpl.java +++ b/Mage/src/mage/game/GameImpl.java @@ -44,6 +44,7 @@ import java.util.Random; import java.util.Set; import java.util.Stack; import java.util.UUID; +import mage.MageException; import mage.MageObject; import mage.abilities.Ability; import mage.abilities.ActivatedAbility; @@ -173,7 +174,7 @@ public abstract class GameImpl implements Game, Serializable { protected GameState state; private transient Stack savedStates = new Stack<>(); protected transient GameStates gameStates = new GameStates(); - // game states to allow player roll back + // game states to allow player rollback protected transient Map gameStatesRollBack = new HashMap<>(); protected boolean executingRollback; @@ -204,6 +205,7 @@ public abstract class GameImpl implements Game, Serializable { private int priorityTime; private final int startLife; + protected PlayerList playerList; public GameImpl(MultiplayerAttackOption attackOption, RangeOfInfluence range, int freeMulligans, int startLife) { this.id = UUID.randomUUID(); @@ -388,6 +390,11 @@ public abstract class GameImpl implements Game, Serializable { object = state.getBattlefield().getPermanent(objectId); return object; } + // can be an ability of a sacrificed Token trying to get it's source object + object = getLastKnownInformation(objectId, Zone.BATTLEFIELD); + if (object != null) { + return object; + } for (CommandObject commandObject : state.getCommand()) { if (commandObject instanceof Commander && commandObject.getId().equals(objectId)) { return commandObject; @@ -400,8 +407,6 @@ public abstract class GameImpl implements Game, Serializable { return commandObject; } } - // can be an ability of a sacrificed Token trying to get it's source object - object = getLastKnownInformation(objectId, Zone.BATTLEFIELD); } return object; } @@ -613,6 +618,7 @@ public abstract class GameImpl implements Game, Serializable { GameState restore = gameStates.rollback(stateNum); if (restore != null) { state.restore(restore); + playerList.setCurrent(state.getActivePlayerId()); } } } @@ -667,8 +673,8 @@ public abstract class GameImpl implements Game, Serializable { @Override public void resume() { - PlayerList players = state.getPlayerList(state.getActivePlayerId()); - Player player = getPlayer(players.get()); + playerList = state.getPlayerList(state.getActivePlayerId()); + Player player = getPlayer(playerList.get()); boolean wasPaused = state.isPaused(); state.resume(); if (!gameOver(null)) { @@ -679,7 +685,7 @@ public abstract class GameImpl implements Game, Serializable { state.getTurn().resumePlay(this, wasPaused); if (!isPaused() && !gameOver(null)) { endOfTurn(); - player = players.getNext(this); + player = playerList.getNext(this); state.setTurnNum(state.getTurnNum() + 1); } } @@ -688,8 +694,8 @@ public abstract class GameImpl implements Game, Serializable { protected void play(UUID nextPlayerId) { if (!isPaused() && !gameOver(null)) { - PlayerList players = state.getPlayerList(nextPlayerId); - Player playerByOrder = getPlayer(players.get()); + playerList = state.getPlayerList(nextPlayerId); + Player playerByOrder = getPlayer(playerList.get()); while (!isPaused() && !gameOver(null)) { playExtraTurns(); GameEvent event = new GameEvent(GameEvent.EventType.PLAY_TURN, null, null, playerByOrder.getId()); @@ -697,10 +703,9 @@ public abstract class GameImpl implements Game, Serializable { if (!playTurn(playerByOrder)) { break; } - state.setTurnNum(state.getTurnNum() + 1); } playExtraTurns(); - playerByOrder = players.getNext(this); + playerByOrder = playerList.getNext(this); } } if (gameOver(null) && !isSimulation()) { @@ -731,14 +736,13 @@ public abstract class GameImpl implements Game, Serializable { GameEvent event = new GameEvent(GameEvent.EventType.PLAY_TURN, null, null, extraTurn.getPlayerId()); if (!replaceEvent(event)) { Player extraPlayer = this.getPlayer(extraTurn.getPlayerId()); - if (extraPlayer != null && extraPlayer.isInGame()) { + if (extraPlayer != null && extraPlayer.canRespond()) { state.setExtraTurn(true); state.setTurnId(extraTurn.getId()); if (!this.isSimulation()) { informPlayers(extraPlayer.getLogName() + " takes an extra turn"); } playTurn(extraPlayer); - state.setTurnNum(state.getTurnNum() + 1); } } extraTurn = getNextExtraTurn(); @@ -765,6 +769,7 @@ public abstract class GameImpl implements Game, Serializable { } private boolean playTurn(Player player) { + boolean skipTurn = false; do { if (executingRollback) { executingRollback = false; @@ -778,41 +783,23 @@ public abstract class GameImpl implements Game, Serializable { state.setActivePlayerId(player.getId()); saveRollBackGameState(); } - this.logStartOfTurn(player); if (checkStopOnTurnOption()) { return false; } - state.getTurn().play(this, player); + skipTurn = state.getTurn().play(this, player); } while (executingRollback); if (isPaused() || gameOver(null)) { return false; } - endOfTurn(); + if (!skipTurn) { + endOfTurn(); + state.setTurnNum(state.getTurnNum() + 1); + } return true; } - private void logStartOfTurn(Player player) { - StringBuilder sb = new StringBuilder("Turn ").append(state.getTurnNum()).append(" "); - sb.append(player.getLogName()); - sb.append(" ("); - int delimiter = this.getPlayers().size() - 1; - for (Player gamePlayer : this.getPlayers().values()) { - sb.append(gamePlayer.getLife()); - int poison = gamePlayer.getCounters().getCount(CounterType.POISON); - if (poison > 0) { - sb.append("[P:").append(poison).append("]"); - } - if (delimiter > 0) { - sb.append(" - "); - delimiter--; - } - } - sb.append(")"); - fireStatusEvent(sb.toString(), true); - } - private boolean checkStopOnTurnOption() { if (gameOptions.stopOnTurn != null && gameOptions.stopAtStep == PhaseStep.UNTAP) { if (gameOptions.stopOnTurn.equals(state.getTurnNum())) { @@ -1171,6 +1158,7 @@ public abstract class GameImpl implements Game, Serializable { @Override public void playPriority(UUID activePlayerId, boolean resuming) { + int errorContinueCounter = 0; int bookmark = 0; clearAllBookmarks(); try { @@ -1191,7 +1179,7 @@ public abstract class GameImpl implements Game, Serializable { } player = getPlayer(state.getPlayerList().get()); state.setPriorityPlayerId(player.getId()); - while (!player.isPassed() && player.isInGame() && !isPaused() && !gameOver(null)) { + while (!player.isPassed() && player.canRespond() && !isPaused() && !gameOver(null)) { if (!resuming) { // 603.3. Once an ability has triggered, its controller puts it on the stack as an object that’s not a card the next time a player would receive priority checkStateAndTriggered(); @@ -1237,11 +1225,19 @@ public abstract class GameImpl implements Game, Serializable { } } catch (Exception ex) { logger.fatal("Game exception gameId: " + getId(), ex); - ex.printStackTrace(); this.fireErrorEvent("Game exception occurred: ", ex); restoreState(bookmark, ""); bookmark = 0; - continue; + Player activePlayer = this.getPlayer(getActivePlayerId()); + if (errorContinueCounter > 15) { + throw new MageException("Iterated player priority after game exception too often, game ends!"); + } + if (activePlayer != null && !activePlayer.isTestMode()) { + errorContinueCounter++; + continue; + } else { + throw new MageException("Error in testclass"); + } } state.getPlayerList().getNext(); } @@ -1249,6 +1245,7 @@ public abstract class GameImpl implements Game, Serializable { } catch (Exception ex) { logger.fatal("Game exception ", ex); this.fireErrorEvent("Game exception occurred: ", ex); + this.end(); } finally { resetLKI(); clearAllBookmarks(); @@ -1276,7 +1273,7 @@ public abstract class GameImpl implements Game, Serializable { protected boolean allPassed() { for (Player player : state.getPlayers().values()) { - if (!player.isPassed() && player.isInGame()) { + if (!player.isPassed() && player.canRespond()) { return false; } } @@ -2647,15 +2644,16 @@ public abstract class GameImpl implements Game, Serializable { GameState restore = gameStatesRollBack.get(turnToGoTo); if (restore != null) { informPlayers(GameLog.getPlayerRequestColoredText("Player request: Rolling back to start of turn " + restore.getTurnNum())); + state.restoreForRollBack(restore); + playerList.setCurrent(state.getActivePlayerId()); + // because restore uses the objects without copy each copy the state again + gameStatesRollBack.put(getTurnNum(), state.copy()); + executingRollback = true; for (Player playerObject : getPlayers().values()) { if (playerObject.isHuman() && playerObject.isInGame()) { playerObject.abort(); } } - state.restoreForRollBack(restore); - // because restore uses the objects without copy each copy the state again - gameStatesRollBack.put(getTurnNum(), state.copy()); - executingRollback = true; fireUpdatePlayersEvent(); } } diff --git a/Mage/src/mage/game/GameOptions.java b/Mage/src/mage/game/GameOptions.java index 7767880a589..fc3c8a7424f 100644 --- a/Mage/src/mage/game/GameOptions.java +++ b/Mage/src/mage/game/GameOptions.java @@ -4,8 +4,8 @@ import java.io.Serializable; import mage.constants.PhaseStep; /** - * Game options for Mage game. - * Mainly used in tests to configure {@link GameImpl} with specific params. + * Game options for Mage game. Mainly used in tests to configure + * {@link GameImpl} with specific params. * * @author ayratn */ @@ -23,8 +23,8 @@ public class GameOptions implements Serializable { public boolean testMode = false; /** - * Defines the turn number game should stop on. - * By default, is null meaning that game shouldn't stop on any specific turn. + * Defines the turn number game should stop on. By default, is null meaning + * that game shouldn't stop on any specific turn. */ public Integer stopOnTurn = null; @@ -37,9 +37,9 @@ public class GameOptions implements Serializable { * If true, library won't be shuffled at the beginning of the game */ public boolean skipInitShuffling = false; - + /** - * If true, players can roll back turn if all players agree + * If true, players can rollback turn if all players agree */ public boolean rollbackTurnsAllowed = true; } diff --git a/Mage/src/mage/game/GameState.java b/Mage/src/mage/game/GameState.java index 6c1aacb48dd..21824f7a41c 100644 --- a/Mage/src/mage/game/GameState.java +++ b/Mage/src/mage/game/GameState.java @@ -41,6 +41,7 @@ import mage.abilities.Ability; import mage.abilities.ActivatedAbility; import mage.abilities.DelayedTriggeredAbilities; import mage.abilities.DelayedTriggeredAbility; +import mage.abilities.MageSingleton; import mage.abilities.Mode; import mage.abilities.SpecialActions; import mage.abilities.StaticAbility; @@ -198,6 +199,7 @@ public class GameState implements Serializable, Copyable { public void restore(GameState state) { this.activePlayerId = state.activePlayerId; + this.playerList.setCurrent(state.activePlayerId); this.priorityPlayerId = state.priorityPlayerId; this.stack = state.stack; this.command = state.command; @@ -855,13 +857,19 @@ public class GameState implements Serializable, Copyable { * @param ability */ public void addOtherAbility(Card attachedTo, Ability ability) { - ability.setSourceId(attachedTo.getId()); - ability.setControllerId(attachedTo.getOwnerId()); + Ability newAbility; + if (ability instanceof MageSingleton) { + newAbility = ability; + } else { + newAbility = ability.copy(); + } + newAbility.setSourceId(attachedTo.getId()); + newAbility.setControllerId(attachedTo.getOwnerId()); if (!cardState.containsKey(attachedTo.getId())) { cardState.put(attachedTo.getId(), new CardState()); } - cardState.get(attachedTo.getId()).addAbility(ability); - addAbility(ability, attachedTo.getId(), attachedTo); + cardState.get(attachedTo.getId()).addAbility(newAbility); + addAbility(newAbility, attachedTo.getId(), attachedTo); } /** diff --git a/Mage/src/mage/game/combat/Combat.java b/Mage/src/mage/game/combat/Combat.java index 2c61cdbf047..8474758049c 100644 --- a/Mage/src/mage/game/combat/Combat.java +++ b/Mage/src/mage/game/combat/Combat.java @@ -166,13 +166,13 @@ public class Combat implements Serializable, Copyable { public void checkForRemoveFromCombat(Game game) { for (UUID creatureId : getAttackers()) { Permanent creature = game.getPermanent(creatureId); - if (!creature.getCardType().contains(CardType.CREATURE)) { + if (creature != null && !creature.getCardType().contains(CardType.CREATURE)) { removeFromCombat(creatureId, game, true); } } for (UUID creatureId : getBlockers()) { Permanent creature = game.getPermanent(creatureId); - if (!creature.getCardType().contains(CardType.CREATURE)) { + if (creature != null && !creature.getCardType().contains(CardType.CREATURE)) { removeFromCombat(creatureId, game, true); } } @@ -236,7 +236,7 @@ public class Combat implements Serializable, Copyable { if (!game.getPlayer(game.getActivePlayerId()).getAvailableAttackers(game).isEmpty()) { player.selectAttackers(game, attackerId); } - if (game.isPaused() || game.gameOver(null)) { + if (game.isPaused() || game.gameOver(null) || game.executingRollback()) { return; } // because of possible undo during declare attackers it's neccassary to call here the methods with "game.getCombat()." to get the valid combat object!!! @@ -246,7 +246,6 @@ public class Combat implements Serializable, Copyable { } public void resumeSelectAttackers(Game game) { - Player player = game.getPlayer(attackerId); for (CombatGroup group : groups) { for (UUID attacker : group.getAttackers()) { game.fireEvent(GameEvent.getEvent(GameEvent.EventType.ATTACKER_DECLARED, group.defenderId, attacker, attackerId)); @@ -254,7 +253,10 @@ public class Combat implements Serializable, Copyable { } game.fireEvent(GameEvent.getEvent(GameEvent.EventType.DECLARED_ATTACKERS, attackerId, attackerId)); if (!game.isSimulation()) { - game.informPlayers(new StringBuilder(player.getLogName()).append(" attacks with ").append(groups.size()).append(groups.size() == 1 ? " creature" : " creatures").toString()); + Player player = game.getPlayer(attackerId); + if (player != null) { + game.informPlayers(player.getLogName() + " attacks with " + groups.size() + (groups.size() == 1 ? " creature" : " creatures")); + } } } @@ -391,7 +393,7 @@ public class Combat implements Serializable, Copyable { } while (choose) { controller.selectBlockers(game, defenderId); - if (game.isPaused() || game.gameOver(null)) { + if (game.isPaused() || game.gameOver(null) || game.executingRollback()) { return; } if (!this.checkBlockRestrictions(defender, game)) { @@ -808,19 +810,21 @@ public class Combat implements Serializable, Copyable { // check now, if it already blocks a creature that mustBeBlockedByAtLeastOne if (possibleBlocker.getBlocking() > 0) { CombatGroup combatGroupOfPossibleBlocker = findGroupOfBlocker(possibleBlockerId); - for (UUID blockedAttackerId : combatGroupOfPossibleBlocker.getAttackers()) { - if (mustBeBlockedByAtLeastOne.containsKey(blockedAttackerId)) { - // blocks a creature that has to be blocked by at least one - if (combatGroupOfPossibleBlocker.getBlockers().size() == 1) { - // the creature blocks alone already a creature that has to be blocked by at least one, - // so this is ok - return null; + if (combatGroupOfPossibleBlocker != null) { + for (UUID blockedAttackerId : combatGroupOfPossibleBlocker.getAttackers()) { + if (mustBeBlockedByAtLeastOne.containsKey(blockedAttackerId)) { + // blocks a creature that has to be blocked by at least one + if (combatGroupOfPossibleBlocker.getBlockers().size() == 1) { + // the creature blocks alone already a creature that has to be blocked by at least one, + // so this is ok + return null; + } + // TODO: Check if the attacker is already blocked by another creature + // and despite there is need that this attacker blocks this attacker also + // I don't know why + Permanent blockedAttacker = game.getPermanent(blockedAttackerId); + return possibleBlocker.getIdName() + " blocks with other creatures " + blockedAttacker.getIdName() + ", which has to be blocked by only one creature. "; } - // TODO: Check if the attacker is already blocked by another creature - // and despite there is need that this attacker blocks this attacker also - // I don't know why - Permanent blockedAttacker = game.getPermanent(blockedAttackerId); - return possibleBlocker.getIdName() + " blocks with other creatures " + blockedAttacker.getIdName() + ", which has to be blocked by only one creature. "; } } } @@ -945,9 +949,12 @@ public class Combat implements Serializable, Copyable { if (!canDefenderBeAttacked(attackerId, defenderId, game)) { return false; } + Permanent attacker = game.getPermanent(attackerId); + if (attacker == null) { + return false; + } CombatGroup newGroup = new CombatGroup(defenderId, defender != null, defender != null ? defender.getControllerId() : defenderId); newGroup.attackers.add(attackerId); - Permanent attacker = game.getPermanent(attackerId); attacker.setAttacking(true); groups.add(newGroup); return true; diff --git a/Mage/src/mage/game/combat/CombatGroup.java b/Mage/src/mage/game/combat/CombatGroup.java index 1c50ff3d1b0..e7cf83c8a75 100644 --- a/Mage/src/mage/game/combat/CombatGroup.java +++ b/Mage/src/mage/game/combat/CombatGroup.java @@ -434,7 +434,7 @@ public class CombatGroup implements Serializable, Copyable { Player player = game.getPlayer(playerId); List blockerList = new ArrayList<>(blockers); blockerOrder.clear(); - while (true && player.isInGame()) { + while (true && player.canRespond()) { if (blockerList.size() == 1) { blockerOrder.add(blockerList.get(0)); break; diff --git a/Mage/src/mage/game/command/Commander.java b/Mage/src/mage/game/command/Commander.java index f3265532cfb..58793919e65 100644 --- a/Mage/src/mage/game/command/Commander.java +++ b/Mage/src/mage/game/command/Commander.java @@ -1,32 +1,34 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.command; +import java.util.List; +import java.util.UUID; import mage.MageInt; import mage.ObjectColor; import mage.abilities.Abilities; @@ -39,24 +41,14 @@ import mage.abilities.costs.mana.ManaCosts; import mage.cards.Card; import mage.constants.CardType; import mage.game.Game; - -import java.util.List; -import java.util.UUID; import mage.util.GameLog; -/** - * - * @author Plopman - */ - - -public class Commander implements CommandObject{ +public class Commander implements CommandObject { private final Card card; private final Abilities abilites = new AbilitiesImpl<>(); - - public Commander(Card card){ + public Commander(Card card) { this.card = card; abilites.add(new CastCommanderAbility(card)); for (Ability ability : card.getAbilities()) { @@ -66,15 +58,15 @@ public class Commander implements CommandObject{ } } } - + private Commander(Commander copy) { this.card = copy.card; } - - public Card getCard(){ + + public Card getCard() { return card; } - + @Override public UUID getSourceId() { return card.getId(); @@ -101,7 +93,7 @@ public class Commander implements CommandObject{ @Override public String getIdName() { - return card.getName() + " ["+card.getId().toString().substring(0,3) +"]"; + return card.getName() + " [" + card.getId().toString().substring(0, 3) + "]"; } @Override @@ -111,7 +103,7 @@ public class Commander implements CommandObject{ @Override public void setName(String name) { - + } @Override @@ -145,7 +137,7 @@ public class Commander implements CommandObject{ return true; } Abilities otherAbilities = game.getState().getAllOtherAbilities(getId()); - return otherAbilities != null && otherAbilities.containsKey(abilityId); + return otherAbilities != null && otherAbilities.containsKey(abilityId); } @Override @@ -201,17 +193,17 @@ public class Commander implements CommandObject{ @Override public int getZoneChangeCounter(Game game) { - throw new UnsupportedOperationException("Unsupported operation"); + return card.getZoneChangeCounter(game); } @Override public void updateZoneChangeCounter(Game game) { - throw new UnsupportedOperationException("Unsupported operation"); + card.updateZoneChangeCounter(game); } @Override public void setZoneChangeCounter(int value, Game game) { - throw new UnsupportedOperationException("Unsupported operation"); + card.setZoneChangeCounter(value, game); } - + } diff --git a/Mage/src/mage/game/command/Emblem.java b/Mage/src/mage/game/command/Emblem.java index 3321f3ead71..35b35b1a4c2 100644 --- a/Mage/src/mage/game/command/Emblem.java +++ b/Mage/src/mage/game/command/Emblem.java @@ -1,30 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.command; import java.util.ArrayList; @@ -86,7 +86,7 @@ public class Emblem implements CommandObject { } public void setControllerId(UUID controllerId) { - this.controllerId = controllerId; + this.controllerId = controllerId; this.abilites.setControllerId(controllerId); } @@ -101,9 +101,9 @@ public class Emblem implements CommandObject { @Override public String getIdName() { - return getName() + " ["+getId().toString().substring(0,3) +"]"; + return getName() + " [" + getId().toString().substring(0, 3) + "]"; } - + @Override public String getLogName() { return GameLog.getColoredObjectIdName(this); @@ -170,13 +170,16 @@ public class Emblem implements CommandObject { } @Override - public void adjustChoices(Ability ability, Game game) {} + public void adjustChoices(Ability ability, Game game) { + } @Override - public void adjustCosts(Ability ability, Game game) {} + public void adjustCosts(Ability ability, Game game) { + } @Override - public void adjustTargets(Ability ability, Game game) {} + public void adjustTargets(Ability ability, Game game) { + } @Override public UUID getId() { @@ -207,7 +210,7 @@ public class Emblem implements CommandObject { @Override public int getZoneChangeCounter(Game game) { - throw new UnsupportedOperationException("Unsupported operation"); + return 1; // Emblems can't move zones until now so return always 1 } @Override @@ -219,5 +222,5 @@ public class Emblem implements CommandObject { public void setZoneChangeCounter(int value, Game game) { throw new UnsupportedOperationException("Unsupported operation"); } - + } diff --git a/Mage/src/mage/game/draft/DraftCube.java b/Mage/src/mage/game/draft/DraftCube.java index 40f69ffcbbb..cb17656cca8 100644 --- a/Mage/src/mage/game/draft/DraftCube.java +++ b/Mage/src/mage/game/draft/DraftCube.java @@ -43,6 +43,7 @@ import org.apache.log4j.Logger; public abstract class DraftCube { public class CardIdentity { + private String name; private String extension; @@ -69,7 +70,7 @@ public abstract class DraftCube { } private static final Logger logger = Logger.getLogger(DraftCube.class); - + private static final Random rnd = new Random(); private final String name; private final int boosterSize = 15; @@ -88,13 +89,13 @@ public abstract class DraftCube { public List getCubeCards() { return cubeCards; } - + public List createBooster() { List booster = new ArrayList<>(); if (leftCubeCards.isEmpty()) { leftCubeCards.addAll(cubeCards); } - + for (int i = 0; i < boosterSize; i++) { boolean done = false; int notValid = 0; @@ -111,9 +112,9 @@ public abstract class DraftCube { cardInfo = cardList.get(0); } } else { - cardInfo = CardRepository.instance.findCard(cardId.getName()); + cardInfo = CardRepository.instance.findPreferedCoreExpansionCard(cardId.getName()); } - + if (cardInfo != null) { booster.add(cardInfo.getCard()); done = true; diff --git a/Mage/src/mage/game/draft/RandomBoosterDraft.java b/Mage/src/mage/game/draft/RandomBoosterDraft.java index ebd0a8a9ef3..cc7604b4478 100644 --- a/Mage/src/mage/game/draft/RandomBoosterDraft.java +++ b/Mage/src/mage/game/draft/RandomBoosterDraft.java @@ -50,28 +50,11 @@ public class RandomBoosterDraft extends BoosterDraft { resetBoosters(); } - @Override - public void start() { - while (!isAbort() && boosterNum < numberBoosters) { - openBooster(); - while (!isAbort() && pickCards()) { - if (boosterNum % 2 == 1) { - passLeft(); - } else { - passRight(); - } - fireUpdatePlayersEvent(); - } - } - resetBufferedCards(); - this.fireEndDraftEvent(); - } - @Override protected void openBooster() { if (boosterNum < numberBoosters) { for (DraftPlayer player: players.values()) { - player.setBooster(getNextBooster().createBooster()); + player.setBooster(getNextBooster().create15CardBooster()); } } boosterNum++; diff --git a/Mage/src/mage/game/events/GameEvent.java b/Mage/src/mage/game/events/GameEvent.java index 433ad158c39..fcabb52c61a 100644 --- a/Mage/src/mage/game/events/GameEvent.java +++ b/Mage/src/mage/game/events/GameEvent.java @@ -119,7 +119,20 @@ public class GameEvent implements Serializable { */ SPELL_CAST, ACTIVATE_ABILITY, ACTIVATED_ABILITY, - ADD_MANA, MANA_ADDED, + /* ADD_MANA + targetId id of the ability that added the mana + sourceId sourceId of the ability that added the mana + playerId player the mana is added to the mana pool for + mana the mana added + */ + ADD_MANA, + /* MANA_ADDED + targetId id of the ability that added the mana + sourceId sourceId of the ability that added the mana + playerId player the mana is added to the mana pool for + mana the mana added + */ + MANA_ADDED, /* MANA_PAYED targetId id if the ability the mana was paid for (not the sourceId) sourceId sourceId of the mana source diff --git a/Mage/src/mage/game/events/ZoneChangeGroupEvent.java b/Mage/src/mage/game/events/ZoneChangeGroupEvent.java index adb3e8cbc4b..fa36abb663e 100644 --- a/Mage/src/mage/game/events/ZoneChangeGroupEvent.java +++ b/Mage/src/mage/game/events/ZoneChangeGroupEvent.java @@ -1,33 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.events; -import java.util.List; +import java.util.Set; import java.util.UUID; import mage.cards.Card; import mage.constants.Zone; @@ -37,18 +37,18 @@ import mage.constants.Zone; * @author LevelX2 */ public class ZoneChangeGroupEvent extends GameEvent { - + private final Zone fromZone; private final Zone toZone; - private final List cards; + private final Set cards; - public ZoneChangeGroupEvent(List cards, UUID sourceId, UUID playerId, Zone fromZone, Zone toZone) { + public ZoneChangeGroupEvent(Set cards, UUID sourceId, UUID playerId, Zone fromZone, Zone toZone) { super(EventType.ZONE_CHANGE_GROUP, null, sourceId, playerId); this.fromZone = fromZone; this.toZone = toZone; this.cards = cards; - } - + } + public Zone getFromZone() { return fromZone; } @@ -57,7 +57,7 @@ public class ZoneChangeGroupEvent extends GameEvent { return toZone; } - public List getCards() { + public Set getCards() { return cards; } diff --git a/Mage/src/mage/game/permanent/Permanent.java b/Mage/src/mage/game/permanent/Permanent.java index 33221ea2fb7..9a53acdc2d1 100644 --- a/Mage/src/mage/game/permanent/Permanent.java +++ b/Mage/src/mage/game/permanent/Permanent.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent; import java.util.ArrayList; @@ -45,60 +44,89 @@ import mage.game.Game; public interface Permanent extends Card, Controllable { void setControllerId(UUID controllerId); + boolean isTapped(); + boolean untap(Game game); + boolean tap(Game game); + /** * use tap(game) - *

setTapped doesn't trigger TAPPED event and should be used - * only if you want permanent to enter battlefield tapped

+ *

+ * setTapped doesn't trigger TAPPED event and should be used only if you + * want permanent to enter battlefield tapped

* * @param tapped * @deprecated */ @Deprecated void setTapped(boolean tapped); + boolean canTap(); boolean isFlipped(); + boolean unflip(Game game); + boolean flip(Game game); boolean transform(Game game); + boolean isTransformed(); + void setTransformed(boolean value); boolean isPhasedIn(); + boolean phaseIn(Game game); + boolean phaseOut(Game game); boolean isMonstrous(); + void setMonstrous(boolean value); boolean isRenowned(); + void setRenowned(boolean value); void setCardNumber(int cid); + void setExpansionSetCode(String expansionSetCode); + void setRarity(Rarity rarity); + void setFlipCard(boolean flipCard); + void setFlipCardName(String flipCardName); + void setSecondCardFace(Card card); Counters getCounters(); List getAttachments(); + UUID getAttachedTo(); + void attachTo(UUID permanentId, Game game); + boolean addAttachment(UUID permanentId, Game game); + boolean removeAttachment(UUID permanentId, Game game); boolean canBeTargetedBy(MageObject source, UUID controllerId, Game game); + boolean hasProtectionFrom(MageObject source, Game game); + boolean cantBeEnchantedBy(MageObject source, Game game); + boolean wasControlledFromStartOfControllerTurn(); + boolean hasSummoningSickness(); + int getDamage(); + int damage(int damage, UUID sourceId, Game game, boolean combat, boolean preventable); int damage(int damage, UUID sourceId, Game game, boolean combat, boolean preventable, ArrayList appliedEffects); @@ -114,58 +142,83 @@ public interface Permanent extends Card, Controllable { * @return */ int markDamage(int damage, UUID sourceId, Game game, boolean preventable, boolean combat); + int applyDamage(Game game); void removeAllDamage(Game game); void reset(Game game); + boolean destroy(UUID sourceId, Game game, boolean noRegen); + boolean sacrifice(UUID sourceId, Game game); + boolean regenerate(UUID sourceId, Game game); + boolean fight(Permanent fightTarget, Ability source, Game game); - void entersBattlefield(UUID sourceId, Game game, Zone fromZone, boolean fireEvent); + boolean entersBattlefield(UUID sourceId, Game game, Zone fromZone, boolean fireEvent); + String getValue(); @Deprecated void addAbility(Ability ability); + @Deprecated void addAbility(Ability ability, Game game); + void addAbility(Ability ability, UUID sourceId, Game game); + void addAbility(Ability ability, UUID sourceId, Game game, boolean createNewId); void removeAllAbilities(UUID sourceId, Game game); void addLoyaltyUsed(); + boolean canLoyaltyBeUsed(Game game); - public void resetControl(); + boolean changeControllerId(UUID controllerId, Game game); + boolean checkControlChanged(Game game); void beginningOfTurn(Game game); + void endOfTurn(Game game); + int getTurnsOnBattlefield(); void addPower(int power); + void addToughness(int toughness); boolean isAttacking(); + int getBlocking(); + void setAttacking(boolean attacking); + void setBlocking(int blocking); + int getMaxBlocks(); + void setMaxBlocks(int maxBlocks); + int getMinBlockedBy(); + void setMinBlockedBy(int minBlockedBy); + int getMaxBlockedBy(); + boolean isRemovedFromCombat(); + void setRemovedFromCombat(boolean removedFromCombat); /** * Sets the maximum number of blockers the creature can be blocked by. - * Default = 0 which means there is no restriction in the number of blockers. + * Default = 0 which means there is no restriction in the number of + * blockers. * * @param maxBlockedBy maximum number of blockers */ @@ -180,11 +233,14 @@ public interface Permanent extends Card, Controllable { * @return */ boolean canAttack(UUID defenderId, Game game); + boolean canBlock(UUID attackerId, Game game); + boolean canBlockAny(Game game); /** - * Checks by restriction effects if the permanent can use activated abilities + * Checks by restriction effects if the permanent can use activated + * abilities * * @param game * @return true - permanent can use activated abilities @@ -192,11 +248,15 @@ public interface Permanent extends Card, Controllable { boolean canUseActivatedAbilities(Game game); boolean removeFromCombat(Game game); + boolean removeFromCombat(Game game, boolean withInfo); + boolean isDeathtouched(); /** - * Returns a list of object refrences that dealt damage this turn to this permanent + * Returns a list of object refrences that dealt damage this turn to this + * permanent + * * @return */ HashSet getDealtDamageByThisTurn(); @@ -222,13 +282,14 @@ public interface Permanent extends Card, Controllable { * Get card that was imprinted on this one. * * Can be null if no card was imprinted. + * * @return Imprinted card UUID. */ List getImprinted(); /** - * Allows to connect any card to permanent. - * Very similar to Imprint except that it is for internal use only. + * Allows to connect any card to permanent. Very similar to Imprint except + * that it is for internal use only. * * @param key * @param connectedCard @@ -236,8 +297,9 @@ public interface Permanent extends Card, Controllable { void addConnectedCard(String key, UUID connectedCard); /** - * Returns connected cards. - * Very similar to Imprint except that it is for internal use only. + * Returns connected cards. Very similar to Imprint except that it is for + * internal use only. + * * @param key * @return */ @@ -245,6 +307,7 @@ public interface Permanent extends Card, Controllable { /** * Clear all connected cards. + * * @param key */ void clearConnectedCards(String key); @@ -269,9 +332,11 @@ public interface Permanent extends Card, Controllable { void clearPairedCard(); void setMorphed(boolean value); + boolean isMorphed(); void setManifested(boolean value); + boolean isManifested(); @Override @@ -280,5 +345,6 @@ public interface Permanent extends Card, Controllable { // Simple int counter to set a timewise create order , the lower the number the earlier the object was created // if objects enter the battlefield at the same time they can get (and should) get the same number. int getCreateOrder(); + void setCreateOrder(int createOrder); } diff --git a/Mage/src/mage/game/permanent/PermanentImpl.java b/Mage/src/mage/game/permanent/PermanentImpl.java index eb93cb1d560..93b2f355be7 100644 --- a/Mage/src/mage/game/permanent/PermanentImpl.java +++ b/Mage/src/mage/game/permanent/PermanentImpl.java @@ -325,6 +325,11 @@ public abstract class PermanentImpl extends CardImpl implements Permanent { return counters; } + @Override + public Counters getCounters(Game game) { + return counters; + } + @Override public void addCounters(String name, int amount, Game game) { addCounters(name, amount, game, null); @@ -894,10 +899,10 @@ public abstract class PermanentImpl extends CardImpl implements Permanent { } @Override - public void entersBattlefield(UUID sourceId, Game game, Zone fromZone, boolean fireEvent) { + public boolean entersBattlefield(UUID sourceId, Game game, Zone fromZone, boolean fireEvent) { controlledFromStartOfControllerTurn = false; if (this.isFaceDown(game)) { - // remove some attributes here, bceause first apply effects comes later otherwise abilities (e.g. color related) will unintended trigger + // remove some attributes here, because first apply effects comes later otherwise abilities (e.g. color related) will unintended trigger MorphAbility.setPermanentToFaceDownCreature(this); } EntersTheBattlefieldEvent event = new EntersTheBattlefieldEvent(this, sourceId, getControllerId(), fromZone); @@ -909,7 +914,9 @@ public abstract class PermanentImpl extends CardImpl implements Permanent { game.addSimultaneousEvent(event); } } + return true; } + return false; } @Override @@ -950,7 +957,10 @@ public abstract class PermanentImpl extends CardImpl implements Permanent { @Override public boolean cantBeEnchantedBy(MageObject source, Game game) { for (ProtectionAbility ability : abilities.getProtectionAbilities()) { - if (!(source.getSubtype().contains("Aura") && !ability.removesAuras()) && !ability.canTarget(source, game)) { + if (!(source.getSubtype().contains("Aura") + && !ability.removesAuras()) + && !source.getId().equals(ability.getAuraIdNotToBeRemoved()) + && !ability.canTarget(source, game)) { return true; } } diff --git a/Mage/src/mage/game/permanent/PermanentToken.java b/Mage/src/mage/game/permanent/PermanentToken.java index be5e63776a0..d8e02c5e12f 100644 --- a/Mage/src/mage/game/permanent/PermanentToken.java +++ b/Mage/src/mage/game/permanent/PermanentToken.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent; import java.util.UUID; @@ -78,7 +77,7 @@ public class PermanentToken extends PermanentImpl { } this.abilities.setControllerId(this.controllerId); this.manaCost.clear(); - for (ManaCost cost: token.getManaCost()) { + for (ManaCost cost : token.getManaCost()) { this.getManaCost().add(cost.copy()); } this.cardType = token.getCardType(); @@ -95,8 +94,7 @@ public class PermanentToken extends PermanentImpl { game.rememberLKI(objectId, Zone.BATTLEFIELD, this); if (game.getPlayer(controllerId).removeFromBattlefield(this, game)) { game.setZone(objectId, zone); // needed for triggered dies abilities - game.addSimultaneousEvent(new ZoneChangeEvent(this, this.getControllerId(), Zone.BATTLEFIELD, zone)); // causes maybe a problem with Dies trigger of Tokens - // game.getState().removeTriggersOfSourceId(this.getId());// if token is gone endless triggered abilities have to be removed + game.addSimultaneousEvent(new ZoneChangeEvent(this, this.getControllerId(), Zone.BATTLEFIELD, zone)); return true; } } @@ -108,7 +106,7 @@ public class PermanentToken extends PermanentImpl { if (!game.replaceEvent(new ZoneChangeEvent(this, sourceId, this.getControllerId(), Zone.BATTLEFIELD, Zone.EXILED))) { game.rememberLKI(objectId, Zone.BATTLEFIELD, this); if (game.getPlayer(controllerId).removeFromBattlefield(this, game)) { - game.addSimultaneousEvent(new ZoneChangeEvent(this, sourceId, this.getControllerId(), Zone.BATTLEFIELD, Zone.EXILED)); + game.addSimultaneousEvent(new ZoneChangeEvent(this, sourceId, this.getControllerId(), Zone.BATTLEFIELD, Zone.EXILED)); return true; } } @@ -142,5 +140,4 @@ public class PermanentToken extends PermanentImpl { } } - } diff --git a/Mage/src/mage/game/permanent/token/BeastToken.java b/Mage/src/mage/game/permanent/token/BeastToken.java index f5d9b98a546..27c443fef1c 100644 --- a/Mage/src/mage/game/permanent/token/BeastToken.java +++ b/Mage/src/mage/game/permanent/token/BeastToken.java @@ -1,35 +1,37 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Random; import mage.MageInt; -import mage.ObjectColor; import mage.constants.CardType; /** @@ -38,25 +40,40 @@ import mage.constants.CardType; */ public class BeastToken extends Token { - public BeastToken() { - this("LRW"); - } - public BeastToken(String setCode) { - this(setCode, Integer.MIN_VALUE); + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("C14", "LRW", "M15", "M14", "DDL", "M13", "M12")); } - public BeastToken(String setCode, int tokenType) { + public BeastToken() { super("Beast", "3/3 green Beast creature token"); - setOriginalExpansionSetCode(setCode); - if (tokenType != Integer.MIN_VALUE) { - setTokenType(tokenType); - } + availableImageSetCodes = tokenImageSets; cardType.add(CardType.CREATURE); color.setGreen(true); subtype.add("Beast"); power = new MageInt(3); toughness = new MageInt(3); - + } + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + if (getOriginalExpansionSetCode().equals("C14")) { + this.setTokenType(new Random().nextInt(2) + 1); + } + if (getOriginalExpansionSetCode().equals("M15")) { + this.setTokenType(2); + } + } + + public BeastToken(final BeastToken token) { + super(token); + } + + @Override + public BeastToken copy() { + return new BeastToken(this); //To change body of generated methods, choose Tools | Templates. + } } diff --git a/Mage/src/mage/game/permanent/token/ElfToken.java b/Mage/src/mage/game/permanent/token/ElfToken.java index 11807debd70..06c4cbc1b91 100644 --- a/Mage/src/mage/game/permanent/token/ElfToken.java +++ b/Mage/src/mage/game/permanent/token/ElfToken.java @@ -1,33 +1,35 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; import mage.MageInt; import mage.constants.CardType; @@ -37,8 +39,15 @@ import mage.constants.CardType; */ public class ElfToken extends Token { + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("C14", "SHM", "EVG", "LRW", "ORI")); + } + public ElfToken() { super("Elf Warrior", "1/1 green Elf Warrior creature token"); + availableImageSetCodes = tokenImageSets; cardType.add(CardType.CREATURE); color.setGreen(true); subtype.add("Elf"); @@ -47,4 +56,20 @@ public class ElfToken extends Token { toughness = new MageInt(1); } + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + if (getOriginalExpansionSetCode().equals("SHM")) { + this.setTokenType(1); + } + } + + public ElfToken(final ElfToken token) { + super(token); + } + + @Override + public ElfToken copy() { + return new ElfToken(this); //To change body of generated methods, choose Tools | Templates. + } } diff --git a/Mage/src/mage/game/permanent/token/GoblinToken.java b/Mage/src/mage/game/permanent/token/GoblinToken.java index 6b37933e5d2..7b2dfd151f0 100644 --- a/Mage/src/mage/game/permanent/token/GoblinToken.java +++ b/Mage/src/mage/game/permanent/token/GoblinToken.java @@ -28,8 +28,6 @@ package mage.game.permanent.token; import java.util.Arrays; -import java.util.List; -import java.util.Random; import mage.MageInt; import mage.constants.CardType; @@ -39,22 +37,10 @@ import mage.constants.CardType; */ public class GoblinToken extends Token { - static List imageSetCodes = Arrays.asList( - "M10", "C14", "KTK", "EVG", "DTK" - ); - public GoblinToken() { - this(imageSetCodes.get(new Random().nextInt(imageSetCodes.size()))); - } - - public GoblinToken(String originalExpansionSetCode) { super("Goblin", "1/1 red Goblin creature token"); - if (!imageSetCodes.contains(originalExpansionSetCode)) { - this.setOriginalExpansionSetCode(imageSetCodes.get(new Random().nextInt(imageSetCodes.size()))); - } else { - this.setOriginalExpansionSetCode(originalExpansionSetCode); - } - + availableImageSetCodes.addAll(Arrays.asList("SOM", "M10", "C14", "KTK", "EVG", "DTK", "ORI", "DDG")); + cardType.add(CardType.CREATURE); subtype.add("Goblin"); diff --git a/Mage/src/mage/game/permanent/token/SoldierToken.java b/Mage/src/mage/game/permanent/token/SoldierToken.java index 8cf3fa003f5..956f808b5b7 100644 --- a/Mage/src/mage/game/permanent/token/SoldierToken.java +++ b/Mage/src/mage/game/permanent/token/SoldierToken.java @@ -1,33 +1,36 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Random; import mage.MageInt; import mage.constants.CardType; @@ -37,18 +40,38 @@ import mage.constants.CardType; */ public class SoldierToken extends Token { - public SoldierToken() { - this("10E"); + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("10E", "M15", "C14", "ORI", "ALA", "DDF", "THS", "M12", "M13", "MM2", "MMA", "RTR", "SOM")); } - public SoldierToken(String setCode) { + + public SoldierToken() { super("Soldier", "1/1 white Soldier creature token"); - this.setOriginalExpansionSetCode(setCode); + availableImageSetCodes = tokenImageSets; + cardType.add(CardType.CREATURE); color.setWhite(true); subtype.add("Soldier"); power = new MageInt(1); toughness = new MageInt(1); - + } + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + if (getOriginalExpansionSetCode().equals("THS")) { + this.setTokenType(new Random().nextInt(2) + 1); + } + } + + public SoldierToken(final SoldierToken token) { + super(token); + } + + @Override + public SoldierToken copy() { + return new SoldierToken(this); //To change body of generated methods, choose Tools | Templates. + } } diff --git a/Mage/src/mage/game/permanent/token/SquirrelToken.java b/Mage/src/mage/game/permanent/token/SquirrelToken.java index 88a35610725..c8b5e56fdb6 100644 --- a/Mage/src/mage/game/permanent/token/SquirrelToken.java +++ b/Mage/src/mage/game/permanent/token/SquirrelToken.java @@ -27,6 +27,9 @@ */ package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; import mage.MageInt; import mage.constants.CardType; @@ -36,12 +39,15 @@ import mage.constants.CardType; */ public class SquirrelToken extends Token { - public SquirrelToken() { - this("CNS"); + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("CNS")); } - public SquirrelToken(String setCode) { + + public SquirrelToken() { super("Squirrel", "1/1 green Squirrel creature token"); - setOriginalExpansionSetCode(setCode); + availableImageSetCodes = tokenImageSets; cardType.add(CardType.CREATURE); subtype.add("Squirrel"); diff --git a/Mage/src/mage/game/permanent/token/ThopterColorlessToken.java b/Mage/src/mage/game/permanent/token/ThopterColorlessToken.java index 6426e804355..840f15504be 100644 --- a/Mage/src/mage/game/permanent/token/ThopterColorlessToken.java +++ b/Mage/src/mage/game/permanent/token/ThopterColorlessToken.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,14 +20,17 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; +import java.util.Random; import mage.MageInt; import mage.abilities.keyword.FlyingAbility; import mage.constants.CardType; @@ -36,23 +39,41 @@ import mage.constants.CardType; * * @author fireshoes */ - public class ThopterColorlessToken extends Token { - public ThopterColorlessToken() { - this("EXO"); + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("EXO", "ORI")); } - public ThopterColorlessToken(String expansionSetCode) { - super("Thopter", "1/1 colorless Thopter creature token with flying"); - this.setOriginalExpansionSetCode(expansionSetCode); + public ThopterColorlessToken() { + super("Thopter", "1/1 colorless Thopter artifact creature token with flying"); + availableImageSetCodes = tokenImageSets; cardType.add(CardType.ARTIFACT); cardType.add(CardType.CREATURE); subtype.add("Thopter"); power = new MageInt(1); toughness = new MageInt(1); - + addAbility(FlyingAbility.getInstance()); } -} \ No newline at end of file + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + if (getOriginalExpansionSetCode().equals("ORI")) { + this.setTokenType(new Random().nextInt(2) + 1); + } + } + + public ThopterColorlessToken(final ThopterColorlessToken token) { + super(token); + } + + @Override + public ThopterColorlessToken copy() { + return new ThopterColorlessToken(this); //To change body of generated methods, choose Tools | Templates. + } + +} diff --git a/Mage/src/mage/game/permanent/token/Token.java b/Mage/src/mage/game/permanent/token/Token.java index 48d99e43dff..59d4727dbed 100644 --- a/Mage/src/mage/game/permanent/token/Token.java +++ b/Mage/src/mage/game/permanent/token/Token.java @@ -1,35 +1,35 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.permanent.token; import java.util.ArrayList; import java.util.List; +import java.util.Random; import java.util.UUID; import mage.MageObjectImpl; import mage.ObjectColor; @@ -44,8 +44,6 @@ import mage.game.events.GameEvent.EventType; import mage.game.events.ZoneChangeEvent; import mage.game.permanent.PermanentToken; import mage.players.Player; -import mage.util.CardUtil; - public class Token extends MageObjectImpl { @@ -56,22 +54,26 @@ public class Token extends MageObjectImpl { private int originalCardNumber; private String originalExpansionSetCode; private Card copySourceCard; // the card the Token is a copy from - + + // list of set codes tokene images are available for + protected List availableImageSetCodes = new ArrayList<>(); + public enum Type { + FIRST(1), SECOND(2); - + int code; - + Type(int code) { - this.code = code; + this.code = code; } - + int getCode() { return this.code; } } - + public Token(String name, String description) { this.name = name; this.description = description; @@ -95,9 +97,10 @@ public class Token extends MageObjectImpl { this.tokenType = token.tokenType; this.lastAddedTokenId = token.lastAddedTokenId; this.lastAddedTokenIds.addAll(token.lastAddedTokenIds); - this.originalCardNumber = token.originalCardNumber; + this.originalCardNumber = token.originalCardNumber; this.originalExpansionSetCode = token.originalExpansionSetCode; this.copySourceCard = token.copySourceCard; // will never be changed + this.availableImageSetCodes = token.availableImageSetCodes; } public String getDescription() { @@ -156,16 +159,18 @@ public class Token extends MageObjectImpl { this.lastAddedTokenId = newToken.getId(); game.setScopeRelevant(true); game.applyEffects(); - newToken.entersBattlefield(sourceId, game, Zone.OUTSIDE, true); + boolean entered = newToken.entersBattlefield(sourceId, game, Zone.OUTSIDE, true); game.setScopeRelevant(false); game.applyEffects(); - game.fireEvent(new ZoneChangeEvent(newToken, event.getPlayerId(), Zone.OUTSIDE, Zone.BATTLEFIELD)); - if (attacking && game.getCombat() != null) { - game.getCombat().addAttackingCreature(newToken.getId(), game); + if (entered) { + game.fireEvent(new ZoneChangeEvent(newToken, event.getPlayerId(), Zone.OUTSIDE, Zone.BATTLEFIELD)); + if (attacking && game.getCombat() != null) { + game.getCombat().addAttackingCreature(newToken.getId(), game); + } + if (!game.isSimulation()) { + game.informPlayers(controller.getLogName() + " puts a " + newToken.getLogName() + " token onto the battlefield"); + } } - if (!game.isSimulation()) { - game.informPlayers(controller.getLogName() + " puts a " + newToken.getLogName() + " token onto the battlefield"); - } } return true; @@ -207,5 +212,17 @@ public class Token extends MageObjectImpl { } } - + public void setExpansionSetCodeForImage(String code) { + if (availableImageSetCodes.size() > 0) { + if (availableImageSetCodes.contains(code)) { + setOriginalExpansionSetCode(code); + } else { + setOriginalExpansionSetCode(availableImageSetCodes.get(new Random().nextInt(availableImageSetCodes.size()))); + } + } else { + if (getOriginalExpansionSetCode() == null || getOriginalExpansionSetCode().isEmpty()) { + setOriginalExpansionSetCode(code); + } + } + } } diff --git a/Mage/src/mage/game/permanent/token/ZombieToken.java b/Mage/src/mage/game/permanent/token/ZombieToken.java index e64c978b46e..ab636da61fe 100644 --- a/Mage/src/mage/game/permanent/token/ZombieToken.java +++ b/Mage/src/mage/game/permanent/token/ZombieToken.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,14 +20,16 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.game.permanent.token; +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; import java.util.Random; import mage.MageInt; import mage.constants.CardType; @@ -38,16 +40,15 @@ import mage.constants.CardType; */ public class ZombieToken extends Token { - public ZombieToken() { - this("10E"); + final static private List tokenImageSets = new ArrayList<>(); + + static { + tokenImageSets.addAll(Arrays.asList("10E", "M10", "M11", "M12", "M13", "M14", "M15", "MBS", "ALA", "ISD", "C14", "CNS", "MMA", "BNG", "KTK", "DTK", "ORI")); } - public ZombieToken(String expansionSetCode) { + public ZombieToken() { super("Zombie", "2/2 black Zombie creature token"); - this.setOriginalExpansionSetCode(expansionSetCode); - if (expansionSetCode.equals("ISD")) { - this.setTokenType(new Random().nextInt(3) + 1); - } + availableImageSetCodes = tokenImageSets; cardType.add(CardType.CREATURE); color.setBlack(true); subtype.add("Zombie"); @@ -55,4 +56,20 @@ public class ZombieToken extends Token { toughness = new MageInt(2); } -} \ No newline at end of file + @Override + public void setExpansionSetCodeForImage(String code) { + super.setExpansionSetCodeForImage(code); + if (getOriginalExpansionSetCode().equals("ISD")) { + this.setTokenType(new Random().nextInt(3) + 1); + } + } + + public ZombieToken(final ZombieToken token) { + super(token); + } + + @Override + public ZombieToken copy() { + return new ZombieToken(this); //To change body of generated methods, choose Tools | Templates. + } +} diff --git a/Mage/src/mage/game/stack/StackAbility.java b/Mage/src/mage/game/stack/StackAbility.java index 0ab2eeb7bae..aa8d58de407 100644 --- a/Mage/src/mage/game/stack/StackAbility.java +++ b/Mage/src/mage/game/stack/StackAbility.java @@ -1,41 +1,45 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.game.stack; -import mage.constants.AbilityType; -import mage.constants.CardType; -import mage.constants.EffectType; -import mage.constants.Zone; +import java.util.ArrayList; +import java.util.List; +import java.util.UUID; import mage.MageInt; import mage.MageObject; import mage.ObjectColor; -import mage.abilities.*; +import mage.abilities.Abilities; +import mage.abilities.AbilitiesImpl; +import mage.abilities.Ability; +import mage.abilities.MageSingleton; +import mage.abilities.Mode; +import mage.abilities.Modes; +import mage.abilities.StateTriggeredAbility; import mage.abilities.costs.AlternativeCost; import mage.abilities.costs.Cost; import mage.abilities.costs.Costs; @@ -45,19 +49,19 @@ import mage.abilities.costs.mana.ManaCosts; import mage.abilities.costs.mana.ManaCostsImpl; import mage.abilities.effects.Effect; import mage.abilities.effects.Effects; +import mage.cards.Card; import mage.choices.Choice; import mage.choices.Choices; -import mage.game.Game; -import mage.target.Target; -import mage.target.Targets; - -import java.util.ArrayList; -import java.util.List; -import java.util.UUID; -import mage.cards.Card; +import mage.constants.AbilityType; import mage.constants.AbilityWord; +import mage.constants.CardType; +import mage.constants.EffectType; +import mage.constants.Zone; +import mage.game.Game; import mage.game.events.GameEvent; import mage.players.Player; +import mage.target.Target; +import mage.target.Targets; import mage.util.GameLog; import mage.watchers.Watcher; @@ -96,7 +100,7 @@ public class StackAbility extends StackObjImpl implements Ability { public boolean isActivated() { return ability.isActivated(); } - + @Override public boolean resolve(Game game) { if (ability.getTargets().stillLegal(ability, game)) { @@ -110,13 +114,14 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void reset(Game game) { } + public void reset(Game game) { + } @Override public void counter(UUID sourceId, Game game) { //20100716 - 603.8 if (ability instanceof StateTriggeredAbility) { - ((StateTriggeredAbility)ability).counter(game); + ((StateTriggeredAbility) ability).counter(game); } } @@ -127,14 +132,14 @@ public class StackAbility extends StackObjImpl implements Ability { @Override public String getIdName() { - return getName() + " ["+getId().toString().substring(0,3) +"]"; + return getName() + " [" + getId().toString().substring(0, 3) + "]"; } - + @Override public String getLogName() { return GameLog.getColoredObjectIdName(this); } - + @Override public String getImageName() { return name; @@ -221,9 +226,9 @@ public class StackAbility extends StackObjImpl implements Ability { @Override public int getConvertedManaCost() { - // Activated abilities have an "activation cost" but they don't have a characteristic related to that while on the stack. + // Activated abilities have an "activation cost" but they don't have a characteristic related to that while on the stack. // There are certain effects that interact with the cost to activate an ability (e.g., Training Grounds, Power Artifact) - // but nothing that looks for that quality of an ability once it's on the stack. + // but nothing that looks for that quality of an ability once it's on the stack. return 0; } @@ -258,13 +263,16 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void setSourceId(UUID sourceID) {} + public void setSourceId(UUID sourceID) { + } @Override - public void addCost(Cost cost) {} + public void addCost(Cost cost) { + } @Override - public void addEffect(Effect effect) {} + public void addEffect(Effect effect) { + } @Override public boolean activate(Game game, boolean noMana) { @@ -277,7 +285,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void addTarget(Target target) {} + public void addTarget(Target target) { + } @Override public UUID getFirstTarget() { @@ -290,7 +299,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void addChoice(Choice choice) {} + public void addChoice(Choice choice) { + } @Override public List getAlternativeCosts() { @@ -298,7 +308,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void addAlternativeCost(AlternativeCost cost) { } + public void addAlternativeCost(AlternativeCost cost) { + } @Override public ManaCosts getManaCosts() { @@ -306,12 +317,13 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public ManaCosts getManaCostsToPay ( ) { + public ManaCosts getManaCostsToPay() { return ability.getManaCostsToPay(); } @Override - public void addManaCost(ManaCost cost) { } + public void addManaCost(ManaCost cost) { + } @Override public AbilityType getAbilityType() { @@ -329,7 +341,7 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void setName(String name) { + public void setName(String name) { this.name = name; } @@ -344,7 +356,7 @@ public class StackAbility extends StackObjImpl implements Ability { card.adjustChoices(ability, game); } } - + @Override public void adjustCosts(Ability ability, Game game) { Card card = game.getCard(ability.getSourceId()); @@ -367,7 +379,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void addOptionalCost(Cost cost) {} + public void addOptionalCost(Cost cost) { + } @Override public boolean checkIfClause(Game game) { @@ -382,7 +395,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void newOriginalId() {} + public void newOriginalId() { + } @Override public Ability getStackAbility() { @@ -395,7 +409,8 @@ public class StackAbility extends StackObjImpl implements Ability { } @Override - public void addMode(Mode mode) {} + public void addMode(Mode mode) { + } @Override public Modes getModes() { @@ -455,7 +470,7 @@ public class StackAbility extends StackObjImpl implements Ability { public void setAdditionalCostsRuleVisible(boolean ruleAdditionalCostsVisible) { this.ability.setAdditionalCostsRuleVisible(ruleAdditionalCostsVisible); } - + @Override public UUID getOriginalId() { return this.ability.getOriginalId(); @@ -478,7 +493,7 @@ public class StackAbility extends StackObjImpl implements Ability { @Override public void setCostModificationActive(boolean active) { - throw new UnsupportedOperationException("Not supported. Only neede for flashbacked spells"); + throw new UnsupportedOperationException("Not supported. Only neede for flashbacked spells"); } @Override @@ -500,7 +515,7 @@ public class StackAbility extends StackObjImpl implements Ability { public void addWatcher(Watcher watcher) { throw new UnsupportedOperationException("Not supported."); } - + @Override public List getSubAbilities() { return this.ability.getSubAbilities(); @@ -513,7 +528,7 @@ public class StackAbility extends StackObjImpl implements Ability { @Override public MageObject getSourceObject(Game game) { - throw new UnsupportedOperationException("Not supported."); + return game.getBaseObject(getSourceId()); } @Override @@ -529,7 +544,7 @@ public class StackAbility extends StackObjImpl implements Ability { @Override public void setSourceObject(MageObject sourceObject, Game game) { throw new UnsupportedOperationException("Not supported."); - } + } @Override public int getZoneChangeCounter(Game game) { diff --git a/Mage/src/mage/game/stack/StackObjImpl.java b/Mage/src/mage/game/stack/StackObjImpl.java index c2a725153ad..8ca3c7a6be5 100644 --- a/Mage/src/mage/game/stack/StackObjImpl.java +++ b/Mage/src/mage/game/stack/StackObjImpl.java @@ -182,7 +182,7 @@ public abstract class StackObjImpl implements StackObject { newTarget.clearChosen(); } } - } while (targetController.isInGame() && (targetId.equals(newTarget.getFirstTarget()) || newTarget.getTargets().size() != 1)); + } while (targetController.canRespond() && (targetId.equals(newTarget.getFirstTarget()) || newTarget.getTargets().size() != 1)); // choose a new target } else { // build a target definition with exactly one possible target to select that replaces old target @@ -235,7 +235,7 @@ public abstract class StackObjImpl implements StackObject { newTarget.addTarget(tempTarget.getFirstTarget(), target.getTargetAmount(targetId), ability, game, false); } } - } while (again && targetController.isInGame()); + } while (again && targetController.canRespond()); } } // keep the target else { diff --git a/Mage/src/mage/game/turn/DeclareBlockersStep.java b/Mage/src/mage/game/turn/DeclareBlockersStep.java index 6343853aa58..02b6d804089 100644 --- a/Mage/src/mage/game/turn/DeclareBlockersStep.java +++ b/Mage/src/mage/game/turn/DeclareBlockersStep.java @@ -25,15 +25,13 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.game.turn; +import java.util.UUID; import mage.constants.PhaseStep; import mage.game.Game; import mage.game.events.GameEvent.EventType; -import java.util.UUID; - /** * * @author BetaSteward_at_googlemail.com @@ -63,7 +61,7 @@ public class DeclareBlockersStep extends Step { public void beginStep(Game game, UUID activePlayerId) { super.beginStep(game, activePlayerId); game.getCombat().selectBlockers(game); - if (!game.isPaused()) { + if (!game.isPaused() && !game.executingRollback()) { game.getCombat().acceptBlockers(game); game.getCombat().damageAssignmentOrder(game); } diff --git a/Mage/src/mage/game/turn/Phase.java b/Mage/src/mage/game/turn/Phase.java index 0fc741fcc4f..a474976eaae 100644 --- a/Mage/src/mage/game/turn/Phase.java +++ b/Mage/src/mage/game/turn/Phase.java @@ -1,16 +1,16 @@ /* * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. - * + * * Redistribution and use in source and binary forms, with or without modification, are * permitted provided that the following conditions are met: - * + * * 1. Redistributions of source code must retain the above copyright notice, this list of * conditions and the following disclaimer. - * + * * 2. Redistributions in binary form must reproduce the above copyright notice, this list * of conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. - * + * * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR @@ -20,12 +20,11 @@ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. - * + * * The views and conclusions contained in the software and documentation are those of the * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.game.turn; import java.io.Serializable; @@ -57,7 +56,8 @@ public abstract class Phase implements Serializable { public abstract Phase copy(); - public Phase() {} + public Phase() { + } public Phase(final Phase phase) { this.type = phase.type; @@ -69,7 +69,7 @@ public abstract class Phase implements Serializable { this.currentStep = phase.currentStep.copy(); } this.count = phase.count; - for (Step step: phase.steps) { + for (Step step : phase.steps) { this.steps.add(step.copy()); } } @@ -103,7 +103,7 @@ public abstract class Phase implements Serializable { if (beginPhase(game, activePlayerId)) { - for (Step step: steps) { + for (Step step : steps) { if (game.isPaused() || game.gameOver(null)) { return false; } @@ -134,7 +134,7 @@ public abstract class Phase implements Serializable { private boolean checkStopOnStepOption(Game game) { if (game.getOptions().stopOnTurn != null && game.getOptions().stopAtStep == getStep().getType()) { - if (game.getOptions().stopOnTurn.equals(game.getState().getTurnNum())) { + if (game.getOptions().stopOnTurn <= game.getState().getTurnNum()) { game.pause(); return true; } @@ -163,6 +163,9 @@ public abstract class Phase implements Serializable { currentStep = step; if (!game.getState().getTurnMods().skipStep(activePlayerId, currentStep.getType())) { playStep(game); + if (game.executingRollback()) { + return true; + } } } @@ -184,6 +187,7 @@ public abstract class Phase implements Serializable { public void endPhase(Game game, UUID activePlayerId) { game.fireEvent(new GameEvent(postEvent, null, null, activePlayerId)); + game.getState().getTriggers().removeAbilitiesOfNonExistingSources(game); // e.g. tokens that left the battlefield } public void prePriority(Game game, UUID activePlayerId) { @@ -202,13 +206,13 @@ public abstract class Phase implements Serializable { if (!currentStep.skipStep(game, activePlayerId)) { game.getState().increaseStepNum(); prePriority(game, activePlayerId); - if (!game.isPaused() && !game.gameOver(null)) { + if (!game.isPaused() && !game.gameOver(null) && !game.executingRollback()) { currentStep.priority(game, activePlayerId, false); - if(game.executingRollback()) { + if (game.executingRollback()) { return; - } + } } - if (!game.isPaused() && !game.gameOver(null)) { + if (!game.isPaused() && !game.gameOver(null) && !game.executingRollback()) { postPriority(game, activePlayerId); } } @@ -225,8 +229,7 @@ public abstract class Phase implements Serializable { if (wasPaused) { currentStep.resumeBeginStep(game, activePlayerId); resuming = false; - } - else { + } else { prePriority(game, activePlayerId); } case PRIORITY: diff --git a/Mage/src/mage/game/turn/Turn.java b/Mage/src/mage/game/turn/Turn.java index ec5d2f81ca1..30a367814ca 100644 --- a/Mage/src/mage/game/turn/Turn.java +++ b/Mage/src/mage/game/turn/Turn.java @@ -34,6 +34,7 @@ import java.util.List; import java.util.UUID; import mage.constants.PhaseStep; import mage.constants.TurnPhase; +import mage.counters.CounterType; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.permanent.Permanent; @@ -116,16 +117,24 @@ public class Turn implements Serializable { return null; } - public void play(Game game, Player activePlayer) { + /** + * + * @param game + * @param activePlayer + * @return true if turn is skipped + */ + public boolean play(Game game, Player activePlayer) { activePlayer.becomesActivePlayer(); this.setDeclareAttackersStepStarted(false); if (game.isPaused() || game.gameOver(null)) { - return; + return false; } if (game.getState().getTurnMods().skipTurn(activePlayer.getId())) { - return; + game.informPlayers(activePlayer.getLogName() + " skips his or her turn."); + return true; } + logStartOfTurn(game, activePlayer); checkTurnIsControlledByOtherPlayer(game, activePlayer.getId()); @@ -134,7 +143,7 @@ public class Turn implements Serializable { game.getPlayer(activePlayer.getId()).beginTurn(game); for (Phase phase : phases) { if (game.isPaused() || game.gameOver(null)) { - return; + return false; } if (!isEndTurnRequested() || phase.getType().equals(TurnPhase.END)) { currentPhase = phase; @@ -142,7 +151,7 @@ public class Turn implements Serializable { if (!game.getState().getTurnMods().skipPhase(activePlayer.getId(), currentPhase.getType())) { if (phase.play(game, activePlayer.getId())) { if (game.executingRollback()) { - return; + return false; } //20091005 - 500.4/703.4n game.emptyManaPools(); @@ -155,7 +164,7 @@ public class Turn implements Serializable { } } } - + return false; } public void resumePlay(Game game, boolean wasPaused) { @@ -327,4 +336,23 @@ public class Turn implements Serializable { return sb.toString(); } + private void logStartOfTurn(Game game, Player player) { + StringBuilder sb = new StringBuilder("Turn ").append(game.getState().getTurnNum()).append(" "); + sb.append(player.getLogName()); + sb.append(" ("); + int delimiter = game.getPlayers().size() - 1; + for (Player gamePlayer : game.getPlayers().values()) { + sb.append(gamePlayer.getLife()); + int poison = gamePlayer.getCounters().getCount(CounterType.POISON); + if (poison > 0) { + sb.append("[P:").append(poison).append("]"); + } + if (delimiter > 0) { + sb.append(" - "); + delimiter--; + } + } + sb.append(")"); + game.fireStatusEvent(sb.toString(), true); + } } diff --git a/Mage/src/mage/players/Library.java b/Mage/src/mage/players/Library.java index 190d01782d8..ec7cfc1942a 100644 --- a/Mage/src/mage/players/Library.java +++ b/Mage/src/mage/players/Library.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.players; import java.io.Serializable; @@ -35,6 +34,7 @@ import java.util.Arrays; import java.util.Collection; import java.util.Deque; import java.util.HashMap; +import java.util.HashSet; import java.util.Iterator; import java.util.List; import java.util.Map; @@ -65,14 +65,13 @@ public class Library implements Serializable { public Library(final Library lib) { this.emptyDraw = lib.emptyDraw; this.playerId = lib.playerId; - for (UUID id: lib.library) { + for (UUID id : lib.library) { this.library.addLast(id); } } /** - * Don't use this directly. - * Use instead. + * Don't use this directly. Use instead. */ public void shuffle() { UUID[] shuffled = library.toArray(new UUID[0]); @@ -88,7 +87,7 @@ public class Library implements Serializable { /** * Removes the top card of the Library and returns it - * + * * @param game * @return Card * @see Card @@ -133,8 +132,7 @@ public class Library implements Serializable { if (card.getOwnerId().equals(playerId)) { card.setZone(Zone.LIBRARY, game); library.addFirst(card.getId()); - } - else { + } else { game.getPlayer(card.getOwnerId()).getLibrary().putOnTop(card, game); } } @@ -146,8 +144,7 @@ public class Library implements Serializable { library.remove(card.getId()); } library.add(card.getId()); - } - else { + } else { game.getPlayer(card.getOwnerId()).getLibrary().putOnBottom(card, game); } } @@ -166,7 +163,7 @@ public class Library implements Serializable { public void set(Library newLibrary) { library.clear(); - for (UUID card: newLibrary.getCardList()) { + for (UUID card : newLibrary.getCardList()) { library.add(card); } } @@ -177,17 +174,17 @@ public class Library implements Serializable { public List getCards(Game game) { List cards = new ArrayList<>(); - for (UUID cardId: library) { + for (UUID cardId : library) { cards.add(game.getCard(cardId)); } return cards; } - public List getTopCards(Game game, int amount) { - List cards = new ArrayList<>(); + public Set getTopCards(Game game, int amount) { + Set cards = new HashSet<>(); Iterator it = library.iterator(); int count = 0; - while(it.hasNext() && count < amount) { + while (it.hasNext() && count < amount) { UUID cardId = it.next(); Card card = game.getCard(cardId); if (card != null) { @@ -200,7 +197,7 @@ public class Library implements Serializable { public Collection getUniqueCards(Game game) { Map cards = new HashMap<>(); - for (UUID cardId: library) { + for (UUID cardId : library) { Card card = game.getCard(cardId); if (!cards.containsKey(card.getName())) { cards.put(card.getName(), card); @@ -211,7 +208,7 @@ public class Library implements Serializable { public int count(FilterCard filter, Game game) { int result = 0; - for (UUID card: library) { + for (UUID card : library) { if (filter.match(game.getCard(card), game)) { result++; } @@ -219,20 +216,19 @@ public class Library implements Serializable { return result; } - public boolean isEmptyDraw() { return emptyDraw; } public void addAll(Set cards, Game game) { - for (Card card: cards) { + for (Card card : cards) { card.setZone(Zone.LIBRARY, game); library.add(card.getId()); } } public Card getCard(UUID cardId, Game game) { - for (UUID card: library) { + for (UUID card : library) { if (card.equals(cardId)) { return game.getCard(card); } @@ -242,7 +238,7 @@ public class Library implements Serializable { public Card remove(UUID cardId, Game game) { Iterator it = library.iterator(); - while(it.hasNext()) { + while (it.hasNext()) { UUID card = it.next(); if (card.equals(cardId)) { it.remove(); diff --git a/Mage/src/mage/players/ManaPool.java b/Mage/src/mage/players/ManaPool.java index 200faae6b79..f4745ac20ca 100644 --- a/Mage/src/mage/players/ManaPool.java +++ b/Mage/src/mage/players/ManaPool.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.players; import java.io.Serializable; @@ -63,7 +62,7 @@ public class ManaPool implements Serializable { private boolean autoPayment; // auto payment from mana pool: true - mode is active private boolean autoPaymentRestricted; // auto payment from mana pool: true - if auto Payment is on, it will only pay if one kind of mana is in the pool private ManaType unlockedManaType; // type of mana that was selected to pay manually - + private final Set doNotEmptyManaTypes = new HashSet<>(); public ManaPool(UUID playerId) { @@ -75,7 +74,7 @@ public class ManaPool implements Serializable { public ManaPool(final ManaPool pool) { this.playerId = pool.playerId; - for (ManaPoolItem item: pool.manaItems) { + for (ManaPoolItem item : pool.manaItems) { manaItems.add(item.copy()); } this.autoPayment = pool.autoPayment; @@ -105,24 +104,24 @@ public class ManaPool implements Serializable { } /** - * + * * @param manaType the mana type that should be paid * @param ability * @param filter * @param game - * @return + * @return */ public boolean pay(ManaType manaType, Ability ability, Filter filter, Game game) { if (!autoPayment && !manaType.equals(unlockedManaType)) { // if manual payment and the needed mana type was not unlocked, nothing will be paid return false; } - if (autoPayment && autoPaymentRestricted && !wasManaAddedBeyondStock() && !manaType.equals(unlockedManaType)) { + if (autoPayment && autoPaymentRestricted && !wasManaAddedBeyondStock() && !manaType.equals(unlockedManaType)) { // if automatic restricted payment and there is laready mana in the pool // and the needed mana type was not unlocked, nothing will be paid return false; } - + if (getConditional(manaType, ability, filter, game) > 0) { removeConditional(manaType, ability, game); lockManaType(); // pay only one mana if mana payment is set to manually @@ -134,7 +133,7 @@ public class ManaPool implements Serializable { if (!filter.match(sourceObject, game)) { continue; } - } + } if (!manaType.equals(unlockedManaType) && autoPayment && autoPaymentRestricted && mana.count() == mana.getStock()) { // no mana added beyond the stock so don't auto pay this continue; @@ -202,7 +201,7 @@ public class ManaPool implements Serializable { public void clearEmptyManaPoolRules() { doNotEmptyManaTypes.clear(); } - + public void addDoNotEmptyManaType(ManaType manaType) { doNotEmptyManaTypes.add(manaType); } @@ -217,7 +216,7 @@ public class ManaPool implements Serializable { if (!doNotEmptyManaTypes.contains(manaType)) { if (item.get(manaType) > 0) { if (!item.getDuration().equals(Duration.EndOfTurn) || game.getPhase().getType().equals(TurnPhase.END)) { - if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { + if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { int amount = item.get(manaType); item.clear(manaType); item.add(ManaType.COLORLESS, amount); @@ -230,7 +229,7 @@ public class ManaPool implements Serializable { if (conditionalItem != null) { if (conditionalItem.get(manaType) > 0) { if (!item.getDuration().equals(Duration.EndOfTurn) || game.getPhase().getType().equals(TurnPhase.END)) { - if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { + if (game.replaceEvent(new GameEvent(GameEvent.EventType.EMPTY_MANA_POOL, playerId, null, playerId))) { int amount = conditionalItem.get(manaType); conditionalItem.clear(manaType); conditionalItem.add(ManaType.COLORLESS, amount); @@ -246,8 +245,8 @@ public class ManaPool implements Serializable { if (item.count() == 0) { it.remove(); } - } - return total; + } + return total; } private int payX(Ability ability, Game game) { @@ -261,8 +260,7 @@ public class ManaPool implements Serializable { total += item.count(); it.remove(); } - } - else { + } else { total += item.count(); it.remove(); } @@ -272,10 +270,11 @@ public class ManaPool implements Serializable { /** * remove all mana from pool that applies and that matches filter + * * @param ability * @param game * @param filter - * @return + * @return */ public int payX(Ability ability, Game game, FilterMana filter) { if (filter == null) { @@ -297,8 +296,7 @@ public class ManaPool implements Serializable { } } } - } - else { + } else { if (filter.isBlack()) { total += item.getBlack(); item.removeBlack(); @@ -333,7 +331,7 @@ public class ManaPool implements Serializable { public Mana getMana() { Mana m = new Mana(); - for (ManaPoolItem item: manaItems) { + for (ManaPoolItem item : manaItems) { m.add(item.getMana()); } return m; @@ -375,12 +373,12 @@ public class ManaPool implements Serializable { public void addMana(Mana manaToAdd, Game game, Ability source) { addMana(manaToAdd, game, source, false); } - + public void addMana(Mana manaToAdd, Game game, Ability source, boolean emptyOnTurnsEnd) { Mana mana = manaToAdd.copy(); - if (!game.replaceEvent(new ManaEvent(EventType.ADD_MANA, source.getId(), source.getSourceId(), source.getControllerId(), mana))) { + if (!game.replaceEvent(new ManaEvent(EventType.ADD_MANA, source.getId(), source.getSourceId(), playerId, mana))) { if (mana instanceof ConditionalMana) { - ManaPoolItem item = new ManaPoolItem((ConditionalMana)mana, source.getSourceId(), source.getOriginalId()); + ManaPoolItem item = new ManaPoolItem((ConditionalMana) mana, source.getSourceId(), source.getOriginalId()); if (emptyOnTurnsEnd) { item.setDuration(Duration.EndOfTurn); } @@ -389,18 +387,18 @@ public class ManaPool implements Serializable { ManaPoolItem item = new ManaPoolItem(mana.getRed(), mana.getGreen(), mana.getBlue(), mana.getWhite(), mana.getBlack(), mana.getColorless(), source.getSourceId(), source.getOriginalId(), mana.getFlag()); if (emptyOnTurnsEnd) { item.setDuration(Duration.EndOfTurn); - } + } this.manaItems.add(item); } - GameEvent event = GameEvent.getEvent(GameEvent.EventType.MANA_ADDED, source.getId(), source.getSourceId(), source.getControllerId()); - event.setData(mana.toString()); - game.fireEvent(event); + ManaEvent manaEvent = new ManaEvent(EventType.MANA_ADDED, source.getId(), source.getSourceId(), playerId, mana); + manaEvent.setData(mana.toString()); + game.fireEvent(manaEvent); } } public List getConditionalMana() { List conditionalMana = new ArrayList<>(); - for (ManaPoolItem item: manaItems) { + for (ManaPoolItem item : manaItems) { if (item.isConditional()) { conditionalMana.add(item.getConditionalMana()); } @@ -410,7 +408,7 @@ public class ManaPool implements Serializable { public int count() { int x = 0; - for (ManaPoolItem item: manaItems) { + for (ManaPoolItem item : manaItems) { x += item.count(); } return x; @@ -465,7 +463,7 @@ public class ManaPool implements Serializable { mana.setStock(mana.count()); } } - + private boolean wasManaAddedBeyondStock() { for (ManaPoolItem mana : manaItems) { if (mana.getStock() < mana.count()) { diff --git a/Mage/src/mage/players/Player.java b/Mage/src/mage/players/Player.java index d9b3a914f70..4d450a9d58a 100644 --- a/Mage/src/mage/players/Player.java +++ b/Mage/src/mage/players/Player.java @@ -214,6 +214,14 @@ public interface Player extends MageItem, Copyable { */ boolean isInGame(); + /** + * Player is still active in game (has not left, lost or won the game) and + * no abort state is given. + * + * @return + */ + boolean canRespond(); + /** * Called if other player left the game * @@ -445,7 +453,7 @@ public interface Player extends MageItem, Copyable { boolean choosePile(Outcome outcome, String message, List pile1, List pile2, Game game); - boolean playMana(ManaCost unpaid, String promptText, Game game); + boolean playMana(Ability ability, ManaCost unpaid, String promptText, Game game); /** * Moves the cards from cards to the bottom of the players library. @@ -612,10 +620,15 @@ public interface Player extends MageItem, Copyable { */ boolean moveCards(Cards cards, Zone fromZone, Zone toZone, Ability source, Game game); - boolean moveCards(List cards, Zone fromZone, Zone toZone, Ability source, Game game); - +// boolean moveCards(Cards cards, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName); boolean moveCards(Card card, Zone fromZone, Zone toZone, Ability source, Game game); +// boolean moveCards(Card card, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName); + boolean moveCards(Set cards, Zone fromZone, Zone toZone, Ability source, Game game); + + // boolean moveCards(Set cards, Zone fromZone, Zone toZone, Ability source, Game game, boolean withName); + boolean moveCardsToExile(Set cards, Ability source, Game game, boolean withName, UUID exileId, String exileZoneName); + /** * Uses card.moveToZone and posts a inform message about moving the card * into the game log @@ -623,21 +636,19 @@ public interface Player extends MageItem, Copyable { * @param card * @param sourceId * @param game - * @param fromZone if null, this info isn't postet * @return */ - boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone); + boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game); /** * @param card * @param sourceId * @param game * @param withName show the card name in the log - * @param fromZone * @return * */ - boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone, boolean withName); + boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, boolean withName); /** * Uses card.moveToExile and posts a inform message about moving the card to @@ -648,7 +659,6 @@ public interface Player extends MageItem, Copyable { * @param exileName name of exile zone (optional) * @param sourceId * @param game - * @param fromZone if null, this info isn't postet * @param withName * @return */ @@ -675,7 +685,7 @@ public interface Player extends MageItem, Copyable { * @param fromZone if null, this info isn't postet * @return */ - boolean moveCardsToGraveyardWithInfo(List cards, Ability source, Game game, Zone fromZone); + boolean moveCardsToGraveyardWithInfo(Set cards, Ability source, Game game, Zone fromZone); /** * Uses card.moveToZone and posts a inform message about moving the card to diff --git a/Mage/src/mage/players/PlayerImpl.java b/Mage/src/mage/players/PlayerImpl.java index 052ab43222f..5998477bbec 100644 --- a/Mage/src/mage/players/PlayerImpl.java +++ b/Mage/src/mage/players/PlayerImpl.java @@ -693,7 +693,7 @@ public abstract class PlayerImpl implements Player, Serializable { @Override public Cards discard(int amount, boolean random, Ability source, Game game) { Cards discardedCards = new CardsImpl(); - if (this.getHand().size() == 1) { + if (this.getHand().size() == 1 || this.getHand().size() == amount) { discardedCards.addAll(this.getHand()); while (this.getHand().size() > 0) { discard(this.getHand().get(this.getHand().iterator().next(), game), source, game); @@ -859,14 +859,16 @@ public abstract class PlayerImpl implements Player, Serializable { /** * Can be cards or permanents that go to library * - * @param cards + * @param cardsToLibrary * @param game * @param source * @param anyOrder * @return */ @Override - public boolean putCardsOnTopOfLibrary(Cards cards, Game game, Ability source, boolean anyOrder) { + public boolean putCardsOnTopOfLibrary(Cards cardsToLibrary, Game game, Ability source, boolean anyOrder) { + Cards cards = new CardsImpl(cardsToLibrary); // prevent possible ConcurrentModificationException + cards.addAll(cardsToLibrary); if (cards.size() != 0) { if (!anyOrder) { for (UUID cardId : cards) { @@ -1399,7 +1401,7 @@ public abstract class PlayerImpl implements Player, Serializable { filter.add(Predicates.not(new PermanentIdPredicate(permanent.getId()))); } // while targets left and there is still allowed to untap - while (isInGame() && leftForUntap.size() > 0 && numberToUntap > 0) { + while (canRespond() && leftForUntap.size() > 0 && numberToUntap > 0) { // player has to select the permanent he wants to untap for this restriction Ability ability = handledEntry.getKey().getValue().iterator().next(); if (ability != null) { @@ -1449,7 +1451,7 @@ public abstract class PlayerImpl implements Player, Serializable { } } - } while (isInGame() && playerCanceledSelection); + } while (canRespond() && playerCanceledSelection); if (!game.isSimulation()) { // show in log which permanents were selected to untap @@ -2017,6 +2019,11 @@ public abstract class PlayerImpl implements Player, Serializable { return !hasQuit() && !hasLost() && !hasWon() && !hasLeft(); } + @Override + public boolean canRespond() { // abort is checked here to get out of player requests + return !hasQuit() && !hasLost() && !hasWon() && !hasLeft() && !abort; + } + @Override public boolean hasWon() { if (!this.loses) { @@ -2164,7 +2171,7 @@ public abstract class PlayerImpl implements Player, Serializable { public ManaOptions getManaAvailable(Game game) { ManaOptions available = new ManaOptions(); - List> sourceWithoutCosts = new ArrayList<>(); + List> sourceWithoutManaCosts = new ArrayList<>(); List> sourceWithCosts = new ArrayList<>(); for (Permanent permanent : game.getBattlefield().getAllActivePermanents(playerId)) { boolean canAdd = false; @@ -2183,12 +2190,12 @@ public abstract class PlayerImpl implements Player, Serializable { if (withCost) { sourceWithCosts.add(manaAbilities); } else { - sourceWithoutCosts.add(manaAbilities); + sourceWithoutManaCosts.add(manaAbilities); } } } - for (Abilities manaAbilities : sourceWithoutCosts) { + for (Abilities manaAbilities : sourceWithoutManaCosts) { available.addMana(manaAbilities, game); } for (Abilities manaAbilities : sourceWithCosts) { @@ -2608,8 +2615,10 @@ public abstract class PlayerImpl implements Player, Serializable { } private void addModeOptions(List options, Ability option, Game game) { + // TODO: Support modal spells with more than one selectable mode for (Mode mode : option.getModes().values()) { Ability newOption = option.copy(); + newOption.getModes().getSelectedModes().clear(); newOption.getModes().setMode(mode); if (newOption.getTargets().getUnchosen().size() > 0) { if (newOption.getManaCosts().getVariableCosts().size() > 0) { @@ -2867,8 +2876,9 @@ public abstract class PlayerImpl implements Player, Serializable { @Override public boolean moveCards(Cards cards, Zone fromZone, Zone toZone, Ability source, Game game) { - ArrayList cardList = new ArrayList<>(); + Set cardList = new HashSet<>(); for (UUID cardId : cards) { + fromZone = game.getState().getZone(cardId); if (fromZone.equals(Zone.BATTLEFIELD)) { Permanent permanent = game.getPermanent(cardId); if (permanent != null) { @@ -2886,7 +2896,7 @@ public abstract class PlayerImpl implements Player, Serializable { @Override public boolean moveCards(Card card, Zone fromZone, Zone toZone, Ability source, Game game) { - ArrayList cardList = new ArrayList<>(); + Set cardList = new HashSet<>(); if (card != null) { cardList.add(card); } @@ -2894,7 +2904,7 @@ public abstract class PlayerImpl implements Player, Serializable { } @Override - public boolean moveCards(List cards, Zone fromZone, Zone toZone, Ability source, Game game) { + public boolean moveCards(Set cards, Zone fromZone, Zone toZone, Ability source, Game game) { if (cards.isEmpty()) { return true; } @@ -2903,7 +2913,9 @@ public abstract class PlayerImpl implements Player, Serializable { case EXILED: boolean result = false; for (Card card : cards) { - result |= moveCardToExileWithInfo(card, null, "", source == null ? null : source.getSourceId(), game, fromZone, true); + fromZone = game.getState().getZone(card.getId()); + boolean withName = (fromZone.equals(Zone.BATTLEFIELD) || fromZone.equals(Zone.STACK)) || !card.isFaceDown(game); + result |= moveCardToExileWithInfo(card, null, "", source == null ? null : source.getSourceId(), game, fromZone, withName); } return result; case GRAVEYARD: @@ -2911,13 +2923,25 @@ public abstract class PlayerImpl implements Player, Serializable { case HAND: result = false; for (Card card : cards) { - result |= moveCardToHandWithInfo(card, source == null ? null : source.getSourceId(), game, fromZone); + fromZone = game.getState().getZone(card.getId()); + boolean hideCard = fromZone.equals(Zone.LIBRARY) + || (card.isFaceDown(game) && !fromZone.equals(Zone.STACK) && !fromZone.equals(Zone.BATTLEFIELD)); + result |= moveCardToHandWithInfo(card, source == null ? null : source.getSourceId(), game, !hideCard); } return result; case BATTLEFIELD: result = false; for (Card card : cards) { - result |= putOntoBattlefieldWithInfo(card, game, fromZone, source == null ? null : source.getSourceId()); + fromZone = game.getState().getZone(card.getId()); + result |= putOntoBattlefieldWithInfo(card, game, fromZone, source == null ? null : source.getSourceId(), false, !card.isFaceDown(game)); + } + return result; + case LIBRARY: + result = false; + for (Card card : cards) { + fromZone = game.getState().getZone(card.getId()); + boolean withName = fromZone.equals(Zone.BATTLEFIELD) || !card.isFaceDown(game); + result |= moveCardToLibraryWithInfo(card, source == null ? null : source.getSourceId(), game, fromZone, true, withName); } return result; default: @@ -2926,29 +2950,41 @@ public abstract class PlayerImpl implements Player, Serializable { } @Override - public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone) { - return this.moveCardToHandWithInfo(card, sourceId, game, fromZone, true); + public boolean moveCardsToExile(Set cards, Ability source, Game game, boolean withName, UUID exileId, String exileZoneName) { + if (cards.isEmpty()) { + return true; + } + game.fireEvent(new ZoneChangeGroupEvent(cards, source == null ? null : source.getSourceId(), this.getId(), null, Zone.EXILED)); + boolean result = false; + for (Card card : cards) { + Zone fromZone = game.getState().getZone(card.getId()); + result |= moveCardToExileWithInfo(card, exileId, exileZoneName, source == null ? null : source.getSourceId(), game, fromZone, withName); + } + return result; } @Override - public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, Zone fromZone, boolean withName) { + public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game) { + return this.moveCardToHandWithInfo(card, sourceId, game, true); + } + + @Override + public boolean moveCardToHandWithInfo(Card card, UUID sourceId, Game game, boolean withName) { boolean result = false; + Zone fromZone = game.getState().getZone(card.getId()); + if (fromZone.equals(Zone.BATTLEFIELD) && !(card instanceof Permanent)) { + card = game.getPermanent(card.getId()); + } if (card.moveToZone(Zone.HAND, sourceId, game, false)) { if (card instanceof PermanentCard) { card = game.getCard(card.getId()); } if (!game.isSimulation()) { - StringBuilder sb = new StringBuilder(this.getLogName()).append(" puts ").append(withName ? card.getLogName() : "a face down card"); - switch (fromZone) { - case EXILED: - sb.append(" from exile zone "); - break; - default: - sb.append(fromZone != null ? new StringBuilder(" from ").append(fromZone.toString().toLowerCase(Locale.ENGLISH)).append(" ") : ""); - break; - } - sb.append(card.getOwnerId().equals(this.getId()) ? "into his or her hand" : "into its owner's hand"); - game.informPlayers(sb.toString()); + game.informPlayers(this.getLogName() + " puts " + + (withName ? card.getLogName() : (card.isFaceDown(game) ? "a face down card" : "a card")) + + " from " + fromZone.toString().toLowerCase(Locale.ENGLISH) + " " + + (card.getOwnerId().equals(this.getId()) ? "into his or her hand" : "into its owner's hand") + ); } result = true; } @@ -2956,7 +2992,7 @@ public abstract class PlayerImpl implements Player, Serializable { } @Override - public boolean moveCardsToGraveyardWithInfo(List allCards, Ability source, Game game, Zone fromZone) { + public boolean moveCardsToGraveyardWithInfo(Set allCards, Ability source, Game game, Zone fromZone) { boolean result = true; UUID sourceId = source == null ? null : source.getSourceId(); while (!allCards.isEmpty()) { @@ -2991,12 +3027,13 @@ public abstract class PlayerImpl implements Player, Serializable { if (chooseOrder) { TargetCard target = new TargetCard(fromZone, new FilterCard("card to put on the top of your graveyard (last one chosen will be topmost)")); target.setRequired(true); - while (choosingPlayer.isInGame() && cards.size() > 1) { + while (choosingPlayer.canRespond() && cards.size() > 1) { choosingPlayer.chooseTarget(Outcome.Neutral, cards, target, source, game); UUID targetObjectId = target.getFirstTarget(); Card card = cards.get(targetObjectId, game); cards.remove(targetObjectId); if (card != null) { + fromZone = game.getState().getZone(card.getId()); result &= choosingPlayer.moveCardToGraveyardWithInfo(card, sourceId, game, fromZone); } target.clearChosen(); @@ -3017,6 +3054,7 @@ public abstract class PlayerImpl implements Player, Serializable { @Override public boolean moveCardToGraveyardWithInfo(Card card, UUID sourceId, Game game, Zone fromZone) { boolean result = false; + // Zone fromZone = game.getState().getZone(card.getId()); if (card.moveToZone(Zone.GRAVEYARD, sourceId, game, fromZone != null ? fromZone.equals(Zone.BATTLEFIELD) : false)) { if (!game.isSimulation()) { if (card instanceof PermanentCard) { @@ -3024,7 +3062,7 @@ public abstract class PlayerImpl implements Player, Serializable { } StringBuilder sb = new StringBuilder(this.getLogName()) .append(" puts ").append(card.getLogName()).append(" ") - .append(fromZone != null ? new StringBuilder("from ").append(fromZone.toString().toLowerCase(Locale.ENGLISH)).append(" ") : ""); + .append(fromZone != null ? "from " + fromZone.toString().toLowerCase(Locale.ENGLISH) + " " : ""); if (card.getOwnerId().equals(getId())) { sb.append("into his or her graveyard"); } else { diff --git a/Mage/src/mage/target/TargetImpl.java b/Mage/src/mage/target/TargetImpl.java index ab3eb6ef68e..aa4b2a27047 100644 --- a/Mage/src/mage/target/TargetImpl.java +++ b/Mage/src/mage/target/TargetImpl.java @@ -1,46 +1,53 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.target; -import mage.constants.Outcome; -import mage.constants.Zone; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Iterator; +import java.util.LinkedHashMap; +import java.util.List; +import java.util.Map; +import java.util.Random; +import java.util.Set; +import java.util.UUID; +import mage.MageObject; import mage.abilities.Ability; import mage.cards.Card; +import mage.constants.AbilityType; +import mage.constants.Outcome; +import mage.constants.Zone; import mage.game.Game; import mage.game.events.GameEvent; import mage.game.events.GameEvent.EventType; import mage.players.Player; -import java.util.*; -import mage.MageObject; -import mage.constants.AbilityType; - /** * * @author BetaSteward_at_googlemail.com @@ -104,7 +111,7 @@ public abstract class TargetImpl implements Target { public void setMinNumberOfTargets(int minNumberOftargets) { this.minNumberOfTargets = minNumberOftargets; } - + @Override public void setMaxNumberOfTargets(int maxNumberOftargets) { this.maxNumberOfTargets = maxNumberOftargets; @@ -116,7 +123,7 @@ public abstract class TargetImpl implements Target { if (targetController != null) { // Hint for the selecting player that the targets must be valid from the point of the ability controller // e.g. select opponent text may be misleading otherwise - suffix = " (target controlling!)"; + suffix = " (target controlling!)"; } if (getMaxNumberOfTargets() != 1) { StringBuilder sb = new StringBuilder(); @@ -158,7 +165,7 @@ public abstract class TargetImpl implements Target { public Zone getZone() { return zone; } - + @Override public boolean isRequired(UUID sourceId, Game game) { MageObject object = game.getObject(sourceId); @@ -168,12 +175,12 @@ public abstract class TargetImpl implements Target { return isRequired(); } } - + @Override public boolean isRequired() { return required; } - + @Override public boolean isRequired(Ability ability) { return ability == null || ability.isActivated() || !(ability.getAbilityType().equals(AbilityType.SPELL) || ability.getAbilityType().equals(AbilityType.ACTIVATED)); @@ -217,6 +224,7 @@ public abstract class TargetImpl implements Target { if (!targets.containsKey(id)) { targets.put(id, 0); rememberZoneChangeCounter(id, game); + chosen = targets.size() >= getNumberOfTargets(); } } } @@ -254,7 +262,7 @@ public abstract class TargetImpl implements Target { } } } - + @Override public void updateTarget(UUID id, Game game) { rememberZoneChangeCounter(id, game); @@ -315,7 +323,7 @@ public abstract class TargetImpl implements Target { int i = 0; int rnd = new Random().nextInt(possibleTargets.size()); Iterator it = possibleTargets.iterator(); - while( i < rnd) { + while (i < rnd) { it.next(); i++; } @@ -336,9 +344,9 @@ public abstract class TargetImpl implements Target { @Override public boolean isLegal(Ability source, Game game) { //20101001 - 608.2b - Set illegalTargets = new HashSet<>(); + Set illegalTargets = new HashSet<>(); // int replacedTargets = 0; - for (UUID targetId: targets.keySet()) { + for (UUID targetId : targets.keySet()) { Card card = game.getCard(targetId); if (card != null) { if (zoneChangeCounters.containsKey(targetId) && zoneChangeCounters.get(targetId) != card.getZoneChangeCounter(game)) { @@ -356,7 +364,7 @@ public abstract class TargetImpl implements Target { } } // remove illegal targets, needed to handle if only a subset of targets was illegal - for (UUID targetId: illegalTargets) { + for (UUID targetId : illegalTargets) { targets.remove(targetId); } // if (replacedTargets > 0 && replacedTargets == targets.size()) { @@ -368,28 +376,96 @@ public abstract class TargetImpl implements Target { return targets.size() > 0; } + /** + * Returns all possible different target combinations + * + * @param source + * @param game + * @return + */ @Override public List getTargetOptions(Ability source, Game game) { List options = new ArrayList<>(); - Set possibleTargets = possibleTargets(source.getSourceId(), source.getControllerId(), game); + List possibleTargets = new ArrayList<>(); + possibleTargets.addAll(possibleTargets(source.getSourceId(), source.getControllerId(), game)); possibleTargets.removeAll(getTargets()); - Iterator it = possibleTargets.iterator(); - while (it.hasNext()) { - UUID targetId = it.next(); + + // get the length of the array + // e.g. for {'A','B','C','D'} => N = 4 + int N = possibleTargets.size(); + // not enough targets, return no option + if (N < getNumberOfTargets()) { + return options; + } + // not target but that's allowed, return one empty option + if (N == 0) { TargetImpl target = this.copy(); - target.clearChosen(); - target.addTarget(targetId, source, game, true); - if (!target.isChosen()) { - Iterator it2 = possibleTargets.iterator(); - while (it2.hasNext()&& !target.isChosen()) { - UUID nextTargetId = it2.next(); - target.addTarget(nextTargetId, source, game, true); + options.add(target); + return options; + } + int maxK = getMaxNumberOfTargets() - getTargets().size(); + if (maxK > 5) { // Prevent endless iteration with targets set to INTEGER.maxvalue + maxK = 5; + if (N > 10) { // not more than 252 combinations + maxK = 4; + } + if (N > 20) { // not more than 4845 combinations + maxK = 3; + } + } + if (N < maxK) { // less possible targets than the maximum allowed so reduce the max + maxK = N; + } + int minK = getNumberOfTargets(); + if (getNumberOfTargets() == 0) { // add option without targets if possible + TargetImpl target = this.copy(); + options.add(target); + minK = 1; + } + for (int K = minK; K <= maxK; K++) { + // get the combination by index + // e.g. 01 --> AB , 23 --> CD + int combination[] = new int[K]; + + // position of current index + // if (r = 1) r* + // index ==> 0 | 1 | 2 + // element ==> A | B | C + int r = 0; + int index = 0; + + while (r >= 0) { + // possible indexes for 1st position "r=0" are "0,1,2" --> "A,B,C" + // possible indexes for 2nd position "r=1" are "1,2,3" --> "B,C,D" + + // for r = 0 ==> index < (4+ (0 - 2)) = 2 + if (index <= (N + (r - K))) { + combination[r] = index; + + // if we are at the last position print and increase the index + if (r == K - 1) { + //add the new target option + TargetImpl target = this.copy(); + for (int i = 0; i < combination.length; i++) { + target.addTarget(possibleTargets.get(combination[i]), source, game, true); + } + options.add(target); + index++; + } else { + // select index for next position + index = combination[r] + 1; + r++; + } + } else { + r--; + if (r > 0) { + index = combination[r] + 1; + } else { + index = combination[0] + 1; + } } } - if (target.isChosen()) { - options.add(target); - } - } + } return options; } @@ -458,6 +534,6 @@ public abstract class TargetImpl implements Target { } else { return game.getPlayer(playerId); } - } - + } + } diff --git a/Mage/src/mage/target/TargetSpell.java b/Mage/src/mage/target/TargetSpell.java index ec8dd9c6435..a070bbc3b7c 100644 --- a/Mage/src/mage/target/TargetSpell.java +++ b/Mage/src/mage/target/TargetSpell.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.target; import java.util.HashSet; @@ -84,7 +83,7 @@ public class TargetSpell extends TargetObject { } Spell spell = game.getStack().getSpell(id); if (spell != null) { - return filter.match(spell, source.getControllerId(), game); + return filter.match(spell, source.getSourceId(), source.getControllerId(), game); } return false; } @@ -92,12 +91,12 @@ public class TargetSpell extends TargetObject { @Override public boolean canChoose(UUID sourceId, UUID sourceControllerId, Game game) { int count = 0; - for (StackObject stackObject: game.getStack()) { + for (StackObject stackObject : game.getStack()) { // rule 114.4. A spell or ability on the stack is an illegal target for itself. if (sourceId != null && sourceId.equals(stackObject.getSourceId())) { continue; } - if (canBeChosen(stackObject, sourceControllerId, game)) { + if (canBeChosen(stackObject, sourceId, sourceControllerId, game)) { count++; if (count >= this.minNumberOfTargets) { return true; @@ -114,28 +113,28 @@ public class TargetSpell extends TargetObject { @Override public Set possibleTargets(UUID sourceId, UUID sourceControllerId, Game game) { - return possibleTargets(sourceControllerId, game); - } - - @Override - public Set possibleTargets(UUID sourceControllerId, Game game) { Set possibleTargets = new HashSet<>(); - for (StackObject stackObject: game.getStack()) { - if (canBeChosen(stackObject, sourceControllerId, game)) { + for (StackObject stackObject : game.getStack()) { + if (canBeChosen(stackObject, sourceId, sourceControllerId, game)) { possibleTargets.add(stackObject.getId()); } } return possibleTargets; } + @Override + public Set possibleTargets(UUID sourceControllerId, Game game) { + return this.possibleTargets(null, sourceControllerId, game); + } + @Override public TargetSpell copy() { return new TargetSpell(this); } - private boolean canBeChosen(StackObject stackObject, UUID sourceControllerId, Game game) { + private boolean canBeChosen(StackObject stackObject, UUID sourceID, UUID sourceControllerId, Game game) { return stackObject instanceof Spell && game.getPlayer(sourceControllerId).getInRange().contains(stackObject.getControllerId()) - && filter.match((Spell) stackObject, sourceControllerId, game); + && filter.match((Spell) stackObject, sourceID, sourceControllerId, game); } } diff --git a/Mage/src/mage/target/common/TargetCardInLibrary.java b/Mage/src/mage/target/common/TargetCardInLibrary.java index 69221dc3d8e..5d6205e80d3 100644 --- a/Mage/src/mage/target/common/TargetCardInLibrary.java +++ b/Mage/src/mage/target/common/TargetCardInLibrary.java @@ -1,33 +1,33 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.target.common; +import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.List; @@ -42,7 +42,6 @@ import mage.game.Game; import mage.players.Player; import mage.target.TargetCard; - /** * * @author BetaSteward_at_googlemail.com @@ -86,8 +85,7 @@ public class TargetCardInLibrary extends TargetCard { if (librarySearchLimit == Integer.MAX_VALUE) { cards = targetPlayer.getLibrary().getCards(game); } else { - int maxCards = Math.min(librarySearchLimit, targetPlayer.getLibrary().size()); - cards = targetPlayer.getLibrary().getTopCards(game, maxCards); + cards = new ArrayList<>(targetPlayer.getLibrary().getTopCards(game, librarySearchLimit)); } Collections.sort(cards, new CardNameComparator()); while (!isChosen() && !doneChosing()) { @@ -124,7 +122,6 @@ public class TargetCardInLibrary extends TargetCard { this.librarySearchLimit = librarySearchLimit; } - } class CardNameComparator implements Comparator { diff --git a/Mage/src/mage/target/targetpointer/FixedTarget.java b/Mage/src/mage/target/targetpointer/FixedTarget.java index 5a8f3c68d4d..f513ca21ba9 100644 --- a/Mage/src/mage/target/targetpointer/FixedTarget.java +++ b/Mage/src/mage/target/targetpointer/FixedTarget.java @@ -6,6 +6,7 @@ import java.util.UUID; import mage.abilities.Ability; import mage.cards.Card; import mage.game.Game; +import mage.game.permanent.Permanent; public class FixedTarget implements TargetPointer { @@ -18,6 +19,12 @@ public class FixedTarget implements TargetPointer { this.initialized = false; } + public FixedTarget(Permanent permanent, Game game) { + this.targetId = permanent.getId(); + this.zoneChangeCounter = permanent.getZoneChangeCounter(game); + this.initialized = true; + } + /** * Use this if you already want to fix the target object to the known zone * now (otherwise the zone will be set if the ability triggers or not at diff --git a/Mage/src/mage/util/ClassScanner.java b/Mage/src/mage/util/ClassScanner.java index 434258be2ed..88406c6250e 100644 --- a/Mage/src/mage/util/ClassScanner.java +++ b/Mage/src/mage/util/ClassScanner.java @@ -47,13 +47,13 @@ import java.util.jar.JarInputStream; public class ClassScanner { public static List findClasses(List packages, Class type) { - List cards = new ArrayList(); + List cards = new ArrayList<>(); try { ClassLoader classLoader = Thread.currentThread().getContextClassLoader(); assert classLoader != null; - HashMap dirs = new HashMap(); - TreeSet jars = new TreeSet(); + HashMap dirs = new HashMap<>(); + TreeSet jars = new TreeSet<>(); for (String packageName : packages) { String path = packageName.replace('.', '/'); Enumeration resources = classLoader.getResources(path); @@ -84,7 +84,7 @@ public class ClassScanner { } private static List findClasses(File directory, String packageName, Class type) { - List cards = new ArrayList(); + List cards = new ArrayList<>(); if (!directory.exists()) { return cards; } @@ -104,7 +104,7 @@ public class ClassScanner { } private static List findClassesInJar(File file, List packages, Class type) { - List cards = new ArrayList(); + List cards = new ArrayList<>(); if (!file.exists()) { return cards; } @@ -117,7 +117,7 @@ public class ClassScanner { break; } if (jarEntry.getName().endsWith(".class")) { - String className = jarEntry.getName().replace('/', '.').replace(".class", ""); + String className = jarEntry.getName().replace(".class", "").replace('/', '.'); int packageNameEnd = className.lastIndexOf('.'); String packageName = packageNameEnd != -1 ? className.substring(0, packageNameEnd) : ""; if (packages.contains(packageName)) { diff --git a/Mage/src/mage/util/GameLog.java b/Mage/src/mage/util/GameLog.java index 544b0a2d359..b6a59464e67 100644 --- a/Mage/src/mage/util/GameLog.java +++ b/Mage/src/mage/util/GameLog.java @@ -39,6 +39,7 @@ public class GameLog { static final String LOG_COLOR_PLAYER = "#20B2AA"; // LightSeaGreen static final String LOG_COLOR_PLAYER_REQUEST = "#D2691E"; // Chocolate static final String LOG_COLOR_PLAYER_CONFIRM = "#D2691E"; // Chocolate + // colors for more dark background static final String LOG_COLOR_GREEN = "#90EE90"; // LightGreen static final String LOG_COLOR_RED = "#FF6347"; // Tomato static final String LOG_COLOR_BLUE = "#87CEFA"; // LightSkyBlue @@ -46,6 +47,14 @@ public class GameLog { static final String LOG_COLOR_WHITE = "#F0E68C"; // Khaki static final String LOG_COLOR_MULTI = "#DAA520"; // GoldenRod static final String LOG_COLOR_COLORLESS = "#B0C4DE"; // LightSteelBlue + // colors for tooltip (light background) + static final String LOG_TT_COLOR_RED = "Red"; // Tomato + static final String LOG_TT_COLOR_GREEN = "Green"; // LightGreen + static final String LOG_TT_COLOR_BLUE = "Blue"; + static final String LOG_TT_COLOR_BLACK = "Black"; + static final String LOG_TT_COLOR_WHITE = "#CCDB00"; + static final String LOG_TT_COLOR_MULTI = "#FFAC40"; + static final String LOG_TT_COLOR_COLORLESS = "#94A4BA"; static final String LOG_COLOR_NEUTRAL = "#F0F8FF"; // AliceBlue public static String replaceNameByColoredName(MageObject mageObject, String text) { @@ -60,6 +69,10 @@ public class GameLog { return "" + mageObject.getName() + " [" + mageObject.getId().toString().substring(0, 3) + "]"; } + public static String getColoredObjectIdNameForTooltip(MageObject mageObject) { + return "" + mageObject.getName() + " [" + mageObject.getId().toString().substring(0, 3) + "]"; + } + public static String getNeutralColoredText(String text) { return "" + text + ""; } @@ -97,4 +110,22 @@ public class GameLog { return LOG_COLOR_BLACK; } } + + private static String getTooltipColorName(ObjectColor objectColor) { + if (objectColor.isMulticolored()) { + return LOG_TT_COLOR_MULTI; + } else if (objectColor.isColorless()) { + return LOG_TT_COLOR_COLORLESS; + } else if (objectColor.isRed()) { + return LOG_TT_COLOR_RED; + } else if (objectColor.isGreen()) { + return LOG_TT_COLOR_GREEN; + } else if (objectColor.isBlue()) { + return LOG_TT_COLOR_BLUE; + } else if (objectColor.isWhite()) { + return LOG_TT_COLOR_WHITE; + } else { + return LOG_TT_COLOR_BLACK; + } + } } diff --git a/Mage/src/mage/util/ManaUtil.java b/Mage/src/mage/util/ManaUtil.java index 6b8e0062926..6ff41cc3f4f 100644 --- a/Mage/src/mage/util/ManaUtil.java +++ b/Mage/src/mage/util/ManaUtil.java @@ -1,5 +1,6 @@ package mage.util; +import java.util.Arrays; import java.util.HashSet; import java.util.LinkedHashMap; import java.util.Set; @@ -19,6 +20,8 @@ import mage.abilities.mana.ManaAbility; import mage.abilities.mana.RedManaAbility; import mage.abilities.mana.WhiteManaAbility; import mage.cards.Card; +import mage.choices.Choice; +import mage.constants.ColoredManaSymbol; import mage.game.Game; /** @@ -77,6 +80,56 @@ public class ManaUtil { return useableAbilities; } + /** + * For Human players this is called before a player is asked to select a + * mana color to pay a specific cost. If the choice obvious, the color is + * auto picked by this method without bothering the human player + * + * @param choice the color choice to do + * @param unpaid the mana still to pay + * @return + */ + public static boolean tryToAutoSelectAManaColor(Choice choice, ManaCost unpaid) { + String colorToAutoPay = null; + if (unpaid.containsColor(ColoredManaSymbol.W) && choice.getChoices().contains("White")) { + colorToAutoPay = "White"; + } + if (unpaid.containsColor(ColoredManaSymbol.R) && choice.getChoices().contains("Red")) { + if (colorToAutoPay != null) { + return false; + } + colorToAutoPay = "Red"; + } + if (unpaid.containsColor(ColoredManaSymbol.G) && choice.getChoices().contains("Green")) { + if (colorToAutoPay != null) { + return false; + } + colorToAutoPay = "Green"; + } + if (unpaid.containsColor(ColoredManaSymbol.U) && choice.getChoices().contains("Blue")) { + if (colorToAutoPay != null) { + return false; + } + colorToAutoPay = "Blue"; + } + if (unpaid.containsColor(ColoredManaSymbol.B) && choice.getChoices().contains("Black")) { + if (colorToAutoPay != null) { + return false; + } + colorToAutoPay = "Black"; + } + // only colorless to pay so take first choice + if (unpaid.getMana().getDifferentColors() == 0) { + colorToAutoPay = choice.getChoices().iterator().next(); + } + // one possible useful option found + if (colorToAutoPay != null) { + choice.setChoice(colorToAutoPay); + return true; + } + return false; + } + private static LinkedHashMap getManaAbilitiesUsingManaSymbols(LinkedHashMap useableAbilities, ManaSymbols symbols, Mana unpaidMana) { Set countColored = new HashSet<>(); @@ -379,4 +432,45 @@ public class ManaUtil { return unpaid.getText(); } } + + /** + * Converts a collection of mana symbols into a single condensed string e.g. + * {1}{1}{1}{1}{1}{W} = {5}{W} {2}{B}{2}{B}{2}{B} = {6}{B}{B}{B} + * {1}{2}{R}{U}{1}{1} = {5}{R}{U} {B}{G}{R} = {B}{G}{R} + * + */ + public static String condenseManaCostString(String rawCost) { + int total = 0; + int index = 0; + // Split the string in to an array of numbers and colored mana symbols + String[] splitCost = rawCost.replace("{", "").replace("}", " ").split(" "); + // Sort alphabetically which will push1 the numbers to the front before the colored mana symbols + Arrays.sort(splitCost); + for (String c : splitCost) { + // If the string is a representation of a number + if (c.matches("\\d+")) { + total += Integer.parseInt(c); + } else { + // First non-number we see we can finish as they are sorted + break; + } + index++; + } + int splitCostLength = splitCost.length; + // No need to add {total} to the mana cost if total == 0 + int shift = (total > 0) ? 1 : 0; + String[] finalCost = new String[shift + splitCostLength - index]; + // Account for no colourless mana symbols seen + if (total > 0) { + finalCost[0] = String.valueOf(total); + } + System.arraycopy(splitCost, index, finalCost, shift, splitCostLength - index); + // Combine the cost back as a mana string + StringBuilder sb = new StringBuilder(); + for (String s : finalCost) { + sb.append("{" + s + "}"); + } + // Return the condensed string + return sb.toString(); + } } diff --git a/Mage/src/mage/watchers/common/CardsPutIntoGraveyardWatcher.java b/Mage/src/mage/watchers/common/CardsPutIntoGraveyardWatcher.java index 78195be8c11..c24c04d65e3 100644 --- a/Mage/src/mage/watchers/common/CardsPutIntoGraveyardWatcher.java +++ b/Mage/src/mage/watchers/common/CardsPutIntoGraveyardWatcher.java @@ -25,7 +25,6 @@ * authors and should not be interpreted as representing official policies, either expressed * or implied, of BetaSteward_at_googlemail.com. */ - package mage.watchers.common; import java.util.HashMap; @@ -34,6 +33,7 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Set; import java.util.UUID; +import mage.MageObjectReference; import mage.constants.WatcherScope; import mage.constants.Zone; import mage.game.Game; @@ -42,16 +42,16 @@ import mage.game.events.ZoneChangeEvent; import mage.watchers.Watcher; /** - * Counts amount of cards put into graveyards of players during the current turn. - * Also the UUIDs of cards that went to graveyard from Battlefield this turn. + * Counts amount of cards put into graveyards of players during the current + * turn. Also the UUIDs of cards that went to graveyard from Battlefield this + * turn. * * @author LevelX2 */ public class CardsPutIntoGraveyardWatcher extends Watcher { private final Map amountOfCardsThisTurn = new HashMap<>(); - private final Set cardsPutToGraveyardFromBattlefield = new HashSet<>(); - + private final Set cardsPutToGraveyardFromBattlefield = new HashSet<>(); public CardsPutIntoGraveyardWatcher() { super("CardsPutIntoGraveyardWatcher", WatcherScope.GAME); @@ -81,7 +81,7 @@ public class CardsPutIntoGraveyardWatcher extends Watcher { } amountOfCardsThisTurn.put(playerId, amount); if (((ZoneChangeEvent) event).getFromZone().equals(Zone.BATTLEFIELD)) { - cardsPutToGraveyardFromBattlefield.add(event.getTargetId()); + cardsPutToGraveyardFromBattlefield.add(new MageObjectReference(event.getTargetId(), game)); } } } @@ -95,10 +95,8 @@ public class CardsPutIntoGraveyardWatcher extends Watcher { return 0; } - public Set getCardsPutToGraveyardFromBattlefield() { - Set cards = new HashSet<>(); - cards.addAll(cardsPutToGraveyardFromBattlefield); - return cards; + public Set getCardsPutToGraveyardFromBattlefield() { + return cardsPutToGraveyardFromBattlefield; } @Override diff --git a/Mage/src/mage/watchers/common/CastSpellLastTurnWatcher.java b/Mage/src/mage/watchers/common/CastSpellLastTurnWatcher.java index 1b22784e905..d78f382b523 100644 --- a/Mage/src/mage/watchers/common/CastSpellLastTurnWatcher.java +++ b/Mage/src/mage/watchers/common/CastSpellLastTurnWatcher.java @@ -1,31 +1,30 @@ /* -* Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. -* -* Redistribution and use in source and binary forms, with or without modification, are -* permitted provided that the following conditions are met: -* -* 1. Redistributions of source code must retain the above copyright notice, this list of -* conditions and the following disclaimer. -* -* 2. Redistributions in binary form must reproduce the above copyright notice, this list -* of conditions and the following disclaimer in the documentation and/or other materials -* provided with the distribution. -* -* THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED -* WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND -* FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR -* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON -* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF -* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -* -* The views and conclusions contained in the software and documentation are those of the -* authors and should not be interpreted as representing official policies, either expressed -* or implied, of BetaSteward_at_googlemail.com. -*/ - + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ package mage.watchers.common; import java.util.ArrayList; @@ -41,9 +40,9 @@ import mage.game.events.GameEvent; import mage.watchers.Watcher; /** -* -* @author nantuko, BetaSteward_at_googlemail.com -*/ + * + * @author nantuko, BetaSteward_at_googlemail.com + */ public class CastSpellLastTurnWatcher extends Watcher { private final Map amountOfSpellsCastOnPrevTurn = new HashMap<>(); @@ -51,83 +50,84 @@ public class CastSpellLastTurnWatcher extends Watcher { private final List spellsCastThisTurnInOrder = new ArrayList<>(); public CastSpellLastTurnWatcher() { - super("CastSpellLastTurnWatcher", WatcherScope.GAME); + super("CastSpellLastTurnWatcher", WatcherScope.GAME); } public CastSpellLastTurnWatcher(final CastSpellLastTurnWatcher watcher) { - super(watcher); - for (Entry entry: watcher.amountOfSpellsCastOnCurrentTurn.entrySet()) { - amountOfSpellsCastOnCurrentTurn.put(entry.getKey(), entry.getValue()); - } - for (Entry entry: watcher.amountOfSpellsCastOnPrevTurn.entrySet()) { - amountOfSpellsCastOnPrevTurn.put(entry.getKey(), entry.getValue()); - } + super(watcher); + for (Entry entry : watcher.amountOfSpellsCastOnCurrentTurn.entrySet()) { + amountOfSpellsCastOnCurrentTurn.put(entry.getKey(), entry.getValue()); + } + for (Entry entry : watcher.amountOfSpellsCastOnPrevTurn.entrySet()) { + amountOfSpellsCastOnPrevTurn.put(entry.getKey(), entry.getValue()); + } + this.spellsCastThisTurnInOrder.addAll(watcher.spellsCastThisTurnInOrder); } @Override public void watch(GameEvent event, Game game) { - if (event.getType() == GameEvent.EventType.SPELL_CAST) { - spellsCastThisTurnInOrder.add(new MageObjectReference(event.getTargetId(), game)); - UUID playerId = event.getPlayerId(); - if (playerId != null) { - Integer amount = amountOfSpellsCastOnCurrentTurn.get(playerId); - if (amount == null) { - amount = 1; - } else { - amount = amount+1; - } - amountOfSpellsCastOnCurrentTurn.put(playerId, amount); - } - } + if (event.getType() == GameEvent.EventType.SPELL_CAST) { + spellsCastThisTurnInOrder.add(new MageObjectReference(event.getTargetId(), game)); + UUID playerId = event.getPlayerId(); + if (playerId != null) { + Integer amount = amountOfSpellsCastOnCurrentTurn.get(playerId); + if (amount == null) { + amount = 1; + } else { + amount = amount + 1; + } + amountOfSpellsCastOnCurrentTurn.put(playerId, amount); + } + } } @Override public void reset() { - amountOfSpellsCastOnPrevTurn.clear(); - amountOfSpellsCastOnPrevTurn.putAll(amountOfSpellsCastOnCurrentTurn); - amountOfSpellsCastOnCurrentTurn.clear(); - spellsCastThisTurnInOrder.clear(); + amountOfSpellsCastOnPrevTurn.clear(); + amountOfSpellsCastOnPrevTurn.putAll(amountOfSpellsCastOnCurrentTurn); + amountOfSpellsCastOnCurrentTurn.clear(); + spellsCastThisTurnInOrder.clear(); } public Map getAmountOfSpellsCastOnPrevTurn() { - return amountOfSpellsCastOnPrevTurn; + return amountOfSpellsCastOnPrevTurn; } public Map getAmountOfSpellsCastOnCurrentTurn() { - return amountOfSpellsCastOnCurrentTurn; + return amountOfSpellsCastOnCurrentTurn; } - + public int getAmountOfSpellsAllPlayersCastOnCurrentTurn() { int totalAmount = 0; - for(Integer amount: amountOfSpellsCastOnCurrentTurn.values()) { + for (Integer amount : amountOfSpellsCastOnCurrentTurn.values()) { totalAmount += amount; } return totalAmount; } public int getAmountOfSpellsPlayerCastOnCurrentTurn(UUID playerId) { - Integer value = amountOfSpellsCastOnCurrentTurn.get(playerId); - if (value != null) { - return value; - } else { - return 0; - } + Integer value = amountOfSpellsCastOnCurrentTurn.get(playerId); + if (value != null) { + return value; + } else { + return 0; + } } public int getSpellOrder(MageObjectReference spell, Game game) { - int index = 0; - for (MageObjectReference mor : spellsCastThisTurnInOrder) { - index++; - if (mor.equals(spell)) { - return index; - } - } - return 0; + int index = 0; + for (MageObjectReference mor : spellsCastThisTurnInOrder) { + index++; + if (mor.equals(spell)) { + return index; + } + } + return 0; } @Override public CastSpellLastTurnWatcher copy() { - return new CastSpellLastTurnWatcher(this); + return new CastSpellLastTurnWatcher(this); } } diff --git a/Utils/gen-card.pl b/Utils/gen-card.pl index 5410dacb5e7..d18b670427a 100755 --- a/Utils/gen-card.pl +++ b/Utils/gen-card.pl @@ -35,6 +35,7 @@ my $author; if (-e $authorFile) { open (DATA, $authorFile); $author = ; + chomp $author; close(DATA); } else { $author = 'anonymous'; @@ -136,7 +137,7 @@ foreach my $setName (keys %{$cards{$cardName}}) { if (!$baseRarity) { $baseRarity = $cards{$cardName}{$setName}[3]; - + $vars{'manaCost'} = fixCost($cards{$cardName}{$setName}[4]); $vars{'power'} = $cards{$cardName}{$setName}[6]; $vars{'toughness'} = $cards{$cardName}{$setName}[7]; @@ -156,7 +157,7 @@ foreach my $setName (keys %{$cards{$cardName}}) { } } $vars{'type'} = join(', ', @types); - + $vars{'abilitiesImports'} = ''; $vars{'abilities'} = ''; @@ -198,7 +199,7 @@ foreach my $setName (keys %{$cards{$cardName}}) { $vars{'abilitiesImports'} .= "\nimport mage.abilities.costs.mana.ManaCostsImpl;"; } - + $vars{'abilitiesImports'} .= "\nimport mage.abilities.keyword." . $kw . "Ability;"; } else { $vars{'abilities'} .= "\n // $kwUnchanged"; @@ -209,7 +210,7 @@ foreach my $setName (keys %{$cards{$cardName}}) { } } } - + if (!$notKeyWord) { $vars{'abilities'} .= "\n // $ability"; if ($simpleOnly eq 'true') { diff --git a/Utils/known-sets.txt b/Utils/known-sets.txt index e1055743c5f..37bea9d00ae 100644 --- a/Utils/known-sets.txt +++ b/Utils/known-sets.txt @@ -5,6 +5,7 @@ Apocalypse|apocalypse| Archenemy|archenemy| Arabian Nights|arabiannights| Avacyn Restored|avacynrestored| +Battle for Zendikar|battleforzendikar| Betrayers of Kamigawa|betrayersofkamigawa| Born of the Gods|bornofthegods| Champions of Kamigawa|championsofkamigawa| diff --git a/Utils/mtg-cards-data.txt b/Utils/mtg-cards-data.txt index b9bf4099936..9568d092c30 100644 --- a/Utils/mtg-cards-data.txt +++ b/Utils/mtg-cards-data.txt @@ -1,4 +1,4 @@ -Ardent Plea|Alara Reborn|1|U|{1}{W}{U}|Enchantment|||Exalted (Whenever a creature you control attacks alone, that creature gets +1/+1 until end of turn.)$Cascade (When you cast this spell, exile cards from the top of your library until you exile a nonland card that costs less. You may cast it without paying its mana cost. Put the exiled cards on the bottom in a random order.)| +Ardent Plea|Alara Reborn|1|U|{1}{W}{U}|Enchantment|||Exalted (Whenever a creature you control attacks alone, that creature gets +1/+1 until end of turn.)$Cascade (When you cast this spell, exile cards from the top of your library until you exile a nonland card that costs less. You may cast it without paying its mana cost. Put the exiled cards on the bottom in a random order.)| Aven Mimeomancer|Alara Reborn|2|R|{1}{W}{U}|Creature - Bird Wizard|3|1|Flying$At the beginning of your upkeep, you may put a feather counter on target creature. If you do, that creature is 3/1 and has flying for as long as it has a feather counter on it.| Ethercaste Knight|Alara Reborn|3|C|{W}{U}|Artifact Creature - Human Knight|1|3|Exalted (Whenever a creature you control attacks alone, that creature gets +1/+1 until end of turn.)| Ethersworn Shieldmage|Alara Reborn|4|C|{1}{W}{U}|Artifact Creature - Vedalken Wizard|2|2|Flash$When Ethersworn Shieldmage enters the battlefield, prevent all damage that would be dealt to artifact creatures this turn.| @@ -628,7 +628,7 @@ Desert Twister|Arabian Nights|30|U|{4}{G}{G}|Sorcery|||Destroy target permanent. Drop of Honey|Arabian Nights|31|R|{G}|Enchantment|||At the beginning of your upkeep, destroy the creature with the least power. It can't be regenerated. If two or more creatures are tied for least power, you choose one of them.$When there are no creatures on the battlefield, sacrifice Drop of Honey.| Erhnam Djinn|Arabian Nights|32|R|{3}{G}|Creature - Djinn|4|5|At the beginning of your upkeep, target non-Wall creature an opponent controls gains forestwalk until your next upkeep.| Ghazban Ogre|Arabian Nights|33|C|{G}|Creature - Ogre|2|2|At the beginning of your upkeep, if a player has more life than each other player, the player with the most life gains control of Ghazbán Ogre.| -Ifh-B ff Efreet|Arabian Nights|34|R|{2}{G}{G}|Creature - Efreet|3|3|Flying${G}: Ifh-Bíff Efreet deals 1 damage to each creature with flying and each player. Any player may activate this ability.| +Ifh-Biff Efreet|Arabian Nights|34|R|{2}{G}{G}|Creature - Efreet|3|3|Flying${G}: Ifh-Biff Efreet deals 1 damage to each creature with flying and each player. Any player may activate this ability.| Metamorphosis|Arabian Nights|35|C|{G}|Sorcery|||As an additional cost to cast Metamorphosis, sacrifice a creature.$Add X mana of any one color to your mana pool, where X is one plus the sacrificed creature's converted mana cost. Spend this mana only to cast creature spells.| Nafs Asp|Arabian Nights|36|C|{G}|Creature - Snake|1|1|Whenever Nafs Asp deals damage to a player, that player loses 1 life at the beginning of his or her next draw step unless he or she pays {1} before that draw step.| Nafs Asp|Arabian Nights|36|C|{G}|Creature - Snake|1|1|Whenever Nafs Asp deals damage to a player, that player loses 1 life at the beginning of his or her next draw step unless he or she pays {1} before that draw step.| @@ -5892,6 +5892,7 @@ Frost Walker|Friday Night Magic|181|U|{1}{U}|Creature - Elemental|4|1|When Frost Path to Exile|Friday Night Magic|182|U|{W}|Instant|||Exile target creature. Its controller may search his or her library for a basic land card, put that card onto the battlefield tapped, then shuffle his or her library.| Serum Visions|Friday Night Magic|183|C|{U}|Sorcery|||Draw a card.$Scry 2. (To scry 2, look at the top two cards of your library, then put any number of them on the bottom of your library and the rest on top in any order.)| Orator of Ojutai|Friday Night Magic|184|U|{1}{W}|Creature - Bird Monk|0|4|Defneder, flying$As an additional cost to cast Orator of Ojutai, you may reveal a Dragon card from your hand.$When Orator of Ojutai enters the battlefield, if you revealed a Dragon card or controlled a Dragon as you cast Orator of Ojutai, draw a card.| +Ultimate Price|Friday Night Magic|185|U|{1}{B}|Instant|||Destroy target monocolored creature.| Angel of Salvation|Future Sight|1|R|{6}{W}{W}|Creature - Angel|5|5|Flash; convoke (Each creature you tap while casting this spell reduces its cost by {1} or by one mana of that creature's color.)$Flying$When Angel of Salvation enters the battlefield, prevent the next 5 damage that would be dealt this turn to any number of target creatures and/or players, divided as you choose.| Knight of Sursi|Future Sight|10|C|{3}{W}|Creature - Human Knight|2|2|Flying; flanking (Whenever a creature without flanking blocks this creature, the blocking creature gets -1/-1 until end of turn.)$Suspend 3-{W} (Rather than cast this card from your hand, you may pay {W} and exile it with three time counters on it. At the beginning of your upkeep, remove a time counter. When the last is removed, cast it without paying its mana cost. It has haste.)| Haze of Rage|Future Sight|100|U|{1}{R}|Sorcery|||Buyback {2} (You may pay an additional {2} as you cast this spell. If you do, put this card into your hand as it resolves.)$Creatures you control get +1/+0 until end of turn.$Storm (When you cast this spell, copy it for each spell cast before it this turn.)| @@ -6707,10 +6708,10 @@ Dire Wolves|Ice Age|118|C|{2}{G}|Creature - Wolf|2|2|Dire Wolves has banding as Earthlore|Ice Age|119|C|{G}|Enchantment - Aura|||Enchant land you control$Tap enchanted land: Target blocking creature gets +1/+2 until end of turn. Activate this ability only if enchanted land is untapped.| Fear|Ice Age|12|C|{B}{B}|Enchantment - Aura|||Enchant creature (Target a creature as you cast this. This card enters the battlefield attached to that creature.)$Enchanted creature has fear. (It can't be blocked except by artifact creatures and/or black creatures.)| Elder Druid|Ice Age|120|R|{3}{G}|Creature - Elf Cleric Druid|2|2|{3}{G}, {tap}: You may tap or untap target artifact, creature, or land.| -Wiitigo|Ice Age|120|R|{3}{G}{G}{G}|Creature - Yeti|0|0|Wiitigo enters the battlefield with six +1/+1 counters on it.$At the beginning of your upkeep, put a +1/+1 counter on Wiitigo if it has blocked or been blocked since your last upkeep. Otherwise, remove a +1/+1 counter from it.| +Wiitigo|Ice Age|164|R|{3}{G}{G}{G}|Creature - Yeti|0|0|Wiitigo enters the battlefield with six +1/+1 counters on it.$At the beginning of your upkeep, put a +1/+1 counter on Wiitigo if it has blocked or been blocked since your last upkeep. Otherwise, remove a +1/+1 counter from it.| Essence Filter|Ice Age|121|C|{1}{G}{G}|Sorcery|||Destroy all enchantments or all nonwhite enchantments.| Fanatical Fever|Ice Age|122|U|{2}{G}{G}|Instant|||Target creature gets +3/+0 and gains trample until end of turn.| -Reclamation|Ice Age|122|R|{2}{G}{W}|Enchantment|||Black creatures can't attack unless their controller sacrifices a land for each black creature he or she controls that's attacking.| +Reclamation|Ice Age|378|R|{2}{G}{W}|Enchantment|||Black creatures can't attack unless their controller sacrifices a land for each black creature he or she controls that's attacking.| Folk of the Pines|Ice Age|123|C|{4}{G}|Creature - Dryad|2|5|{1}{G}: Folk of the Pines gets +1/+0 until end of turn.| Forbidden Lore|Ice Age|124|R|{2}{G}|Enchantment - Aura|||Enchant land$Enchanted land has "{tap}: Target creature gets +2/+1 until end of turn."| Forgotten Lore|Ice Age|125|U|{G}|Sorcery|||Target opponent chooses a card in your graveyard. You may pay {G}. If you do, repeat this process except that opponent can't choose a card already chosen for Forgotten Lore. Then put the last chosen card into your hand.| @@ -6730,7 +6731,7 @@ Hurricane|Ice Age|137|U|{X}{G}|Sorcery|||Hurricane deals X damage to each creatu Johtull Wurm|Ice Age|138|U|{5}{G}|Creature - Wurm|6|6|Whenever Johtull Wurm becomes blocked, it gets -2/-1 until end of turn for each creature blocking it beyond the first.| Juniper Order Druid|Ice Age|139|C|{2}{G}|Creature - Human Cleric Druid|1|1|{tap}: Untap target land.| Foul Familiar|Ice Age|14|C|{2}{B}|Creature - Spirit|3|1|Foul Familiar can't block.${B}, Pay 1 life: Return Foul Familiar to its owner's hand.| -Mind Warp|Ice Age|14|U|{X}{3}{B}|Sorcery|||Look at target player's hand and choose X cards from it. That player discards those cards.| +Mind Warp|Ice Age|36|U|{X}{3}{B}|Sorcery|||Look at target player's hand and choose X cards from it. That player discards those cards.| Lhurgoyf|Ice Age|140|R|{2}{G}{G}|Creature - Lhurgoyf|*|1+*|Lhurgoyf's power is equal to the number of creature cards in all graveyards and its toughness is equal to that number plus 1.| Lure|Ice Age|141|U|{1}{G}{G}|Enchantment - Aura|||Enchant creature$All creatures able to block enchanted creature do so.| Maddening Wind|Ice Age|142|U|{2}{G}|Enchantment - Aura|||Enchant creature$Cumulative upkeep {G} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$At the beginning of the upkeep of enchanted creature's controller, Maddening Wind deals 2 damage to that player.| @@ -6744,7 +6745,7 @@ Ritual of Subdual|Ice Age|149|R|{4}{G}{G}|Enchantment|||Cumulative upkeep {2} (This creature can't attack.)$Sacrifice Tinder Wall: Add {R}{R} to your mana pool.${R}, Sacrifice Tinder Wall: Tinder Wall deals 2 damage to target creature it's blocking.| Touch of Vitae|Ice Age|159|U|{2}{G}|Instant|||Until end of turn, target creature gains haste and "{0}: Untap this creature. Activate this ability only once."$Draw a card at the beginning of the next turn's upkeep.| Gaze of Pain|Ice Age|16|C|{1}{B}|Sorcery|||Until end of turn, whenever a creature you control attacks and isn't blocked, you may choose to have it deal damage equal to its power to a target creature. If you do, it assigns no combat damage this turn.| -Warning|Ice Age|16|C|{W}|Instant|||Prevent all combat damage that would be dealt by target attacking creature this turn.| +Warning|Ice Age|279|C|{W}|Instant|||Prevent all combat damage that would be dealt by target attacking creature this turn.| Venomous Breath|Ice Age|161|U|{3}{G}|Instant|||Choose target creature. At end of combat, destroy all creatures that blocked or were blocked by it this turn.| Wall of Pine Needles|Ice Age|162|U|{3}{G}|Creature - Plant Wall|3|3|Defender (This creature can't attack.)${G}: Regenerate Wall of Pine Needles.| Whiteout|Ice Age|163|U|{1}{G}|Instant|||All creatures lose flying until end of turn.$Sacrifice a snow land: Return Whiteout from your graveyard to your hand.| @@ -6855,7 +6856,7 @@ Heal|Ice Age|254|C|{W}|Instant|||Prevent the next 1 damage that would be dealt t Hipparion|Ice Age|255|U|{1}{W}|Creature - Horse|1|3|Hipparion can't block creatures with power 3 or greater unless you pay {1}.| Kelsinko Ranger|Ice Age|257|C|{W}|Creature - Human|1|1|{1}{W}: Target green creature gains first strike until end of turn.| Kjeldoran Elite Guard|Ice Age|258|U|{3}{W}|Creature - Human Soldier|2|2|{tap}: Target creature gets +2/+2 until end of turn. When that creature leaves the battlefield this turn, sacrifice Kjeldoran Elite Guard. Activate this ability only during combat.| -Kjeldoran Guard|Ice Age|258|C|{1}{W}|Creature - Human Soldier|1|1|{tap}: Target creature gets +1/+1 until end of turn. When that creature leaves the battlefield this turn, sacrifice Kjeldoran Guard. Activate this ability only during combat and only if defending player controls no snow lands.| +Kjeldoran Guard|Ice Age|259|C|{1}{W}|Creature - Human Soldier|1|1|{tap}: Target creature gets +1/+1 until end of turn. When that creature leaves the battlefield this turn, sacrifice Kjeldoran Guard. Activate this ability only during combat and only if defending player controls no snow lands.| Knight of Stromgald|Ice Age|26|U|{B}{B}|Creature - Human Knight|2|1|Protection from white${B}: Knight of Stromgald gains first strike until end of turn.${B}{B}: Knight of Stromgald gets +1/+0 until end of turn.| Kjeldoran Knight|Ice Age|260|R|{W}{W}|Creature - Human Knight|1|1|Banding (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.)${1}{W}: Kjeldoran Knight gets +1/+0 until end of turn.${W}{W}: Kjeldoran Knight gets +0/+2 until end of turn.| Kjeldoran Phalanx|Ice Age|261|R|{5}{W}|Creature - Human Soldier|2|5|First strike; banding (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.)| @@ -6921,7 +6922,7 @@ Sunstone|Ice Age|316|U|{3}|Artifact|||{2}, Sacrifice a snow land: Prevent all co Time Bomb|Ice Age|317|R|{4}|Artifact|||At the beginning of your upkeep, put a time counter on Time Bomb.${1}, {tap}, Sacrifice Time Bomb: Time Bomb deals damage equal to the number of time counters on it to each creature and each player.| Urza's Bauble|Ice Age|318|U|{0}|Artifact|||{tap}, Sacrifice Urza's Bauble: Look at a card at random in target player's hand. You draw a card at the beginning of the next turn's upkeep.| Vexing Arcanix|Ice Age|319|R|{4}|Artifact|||{3}, {tap}: Target player names a card, then reveals the top card of his or her library. If it's the named card, the player puts it into his or her hand. Otherwise, the player puts it into his or her graveyard and Vexing Arcanix deals 2 damage to him or her.| -Land Cap|Ice Age|319|R||Land|||Land Cap doesn't untap during your untap step if it has a depletion counter on it.$At the beginning of your upkeep, remove a depletion counter from Land Cap.${tap}: Add {W} or {U} to your mana pool. Put a depletion counter on Land Cap.| +Land Cap|Ice Age|338|R||Land|||Land Cap doesn't untap during your untap step if it has a depletion counter on it.$At the beginning of your upkeep, remove a depletion counter from Land Cap.${tap}: Add {W} or {U} to your mana pool. Put a depletion counter on Land Cap.| Leshrac's Sigil|Ice Age|32|U|{B}{B}|Enchantment|||Whenever an opponent casts a green spell, you may pay {B}{B}. If you do, look at that player's hand and choose a card from it. The player discards that card.${B}{B}: Return Leshrac's Sigil to its owner's hand.| Vibrating Sphere|Ice Age|320|R|{4}|Artifact|||As long as it's your turn, creatures you control get +2/+0.$As long as it's not your turn, creatures you control get -0/-2.| Walking Wall|Ice Age|321|U|{4}|Artifact Creature - Wall|0|6|Defender${3}: Walking Wall gets +3/-1 until end of turn and can attack this turn as though it didn't have defender. Activate this ability only once each turn.| @@ -6932,24 +6933,24 @@ Zuran Orb|Ice Age|325|U|{0}|Artifact|||Sacrifice a land: You gain 2 life.| Adarkar Wastes|Ice Age|326|R||Land|||{tap}: Add {1} to your mana pool.${tap}: Add {W} or {U} to your mana pool. Adarkar Wastes deals 1 damage to you.| Brushland|Ice Age|327|R||Land|||{tap}: Add {1} to your mana pool.${tap}: Add {G} or {W} to your mana pool. Brushland deals 1 damage to you.| Forest|Ice Age|328|L||Basic Land - Forest|||G| -Forest|Ice Age|328|L||Basic Land - Forest|||G| -Forest|Ice Age|328|L||Basic Land - Forest|||G| +Forest|Ice Age|329|L||Basic Land - Forest|||G| +Forest|Ice Age|330|L||Basic Land - Forest|||G| Lim-Dul's Cohort|Ice Age|33|C|{1}{B}{B}|Creature - Zombie|2|3|Whenever Lim-Dûl's Cohort blocks or becomes blocked by a creature, that creature can't be regenerated this turn.| Glacial Chasm|Ice Age|331|U||Land|||Cumulative upkeep-Pay 2 life. (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$When Glacial Chasm enters the battlefield, sacrifice a land.$Creatures you control can't attack.$Prevent all damage that would be dealt to you.| Halls of Mist|Ice Age|332|R||Land|||Cumulative upkeep {1} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$Creatures that attacked during their controller's last turn can't attack.| Ice Floe|Ice Age|333|U||Land|||You may choose not to untap Ice Floe during your untap step.${tap}: Tap target creature without flying that's attacking you. It doesn't untap during its controller's untap step for as long as Ice Floe remains tapped.| Island|Ice Age|334|L||Basic Land - Island|||U| -Island|Ice Age|334|L||Basic Land - Island|||U| -Island|Ice Age|334|L||Basic Land - Island|||U| +Island|Ice Age|335|L||Basic Land - Island|||U| +Island|Ice Age|336|L||Basic Land - Island|||U| Karplusan Forest|Ice Age|337|R||Land|||{tap}: Add {1} to your mana pool.${tap}: Add {R} or {G} to your mana pool. Karplusan Forest deals 1 damage to you.| Lava Tubes|Ice Age|339|R||Land|||Lava Tubes doesn't untap during your untap step if it has a depletion counter on it.$At the beginning of your upkeep, remove a depletion counter from Lava Tubes.${tap}: Add {B} or {R} to your mana pool. Put a depletion counter on Lava Tubes.| Lim-Dul's Hex|Ice Age|34|U|{1}{B}|Enchantment|||At the beginning of your upkeep, for each player, Lim-Dûl's Hex deals 1 damage to that player unless he or she pays {B} or {3}.| Mountain|Ice Age|340|L||Basic Land - Mountain|||R| -Mountain|Ice Age|340|L||Basic Land - Mountain|||R| -Mountain|Ice Age|340|L||Basic Land - Mountain|||R| -Plains|Ice Age|343|L||Basic Land - Plains|||W| -Plains|Ice Age|343|L||Basic Land - Plains|||W| +Mountain|Ice Age|341|L||Basic Land - Mountain|||R| +Mountain|Ice Age|342|L||Basic Land - Mountain|||R| Plains|Ice Age|343|L||Basic Land - Plains|||W| +Plains|Ice Age|344|L||Basic Land - Plains|||W| +Plains|Ice Age|345|L||Basic Land - Plains|||W| River Delta|Ice Age|346|R||Land|||River Delta doesn't untap during your untap step if it has a depletion counter on it.$At the beginning of your upkeep, remove a depletion counter from River Delta.${tap}: Add {U} or {B} to your mana pool. Put a depletion counter on River Delta.| Snow-Covered Forest|Ice Age|347|L||Basic Snow Land - Forest|||G| Snow-Covered Island|Ice Age|348|L||Basic Snow Land - Island|||U| @@ -6957,9 +6958,9 @@ Snow-Covered Mountain|Ice Age|349|L||Basic Snow Land - Mountain|||R| Mind Ravel|Ice Age|35|C|{2}{B}|Sorcery|||Target player discards a card.$Draw a card at the beginning of the next turn's upkeep.| Snow-Covered Plains|Ice Age|350|L||Basic Snow Land - Plains|||W| Snow-Covered Swamp|Ice Age|351|L||Basic Snow Land - Swamp|||B| -Swamp|Ice Age|351|L||Basic Land - Swamp|||B| -Swamp|Ice Age|351|L||Basic Land - Swamp|||B| -Swamp|Ice Age|351|L||Basic Land - Swamp|||B| +Swamp|Ice Age|353|L||Basic Land - Swamp|||B| +Swamp|Ice Age|354|L||Basic Land - Swamp|||B| +Swamp|Ice Age|355|L||Basic Land - Swamp|||B| Sulfurous Springs|Ice Age|352|R||Land|||{tap}: Add {1} to your mana pool.${tap}: Add {B} or {R} to your mana pool. Sulfurous Springs deals 1 damage to you.| Timberline Ridge|Ice Age|356|R||Land|||Timberline Ridge doesn't untap during your untap step if it has a depletion counter on it.$At the beginning of your upkeep, remove a depletion counter from Timberline Ridge.${tap}: Add {R} or {G} to your mana pool. Put a depletion counter on Timberline Ridge.| Underground River|Ice Age|357|R||Land|||{tap}: Add {1} to your mana pool.${tap}: Add {U} or {B} to your mana pool. Underground River deals 1 damage to you.| @@ -6971,7 +6972,7 @@ Diabolic Vision|Ice Age|362|U|{U}{B}|Sorcery|||Look at the top five cards of you Earthlink|Ice Age|363|R|{3}{B}{R}{G}|Enchantment|||At the beginning of your upkeep, sacrifice Earthlink unless you pay {2}.$Whenever a creature dies, that creature's controller sacrifices a land.| Elemental Augury|Ice Age|364|R|{U}{B}{R}|Enchantment|||{3}: Look at the top three cards of target player's library, then put them back in any order.| Essence Vortex|Ice Age|365|U|{1}{U}{B}|Instant|||Destroy target creature unless its controller pays life equal to its toughness. A creature destroyed this way can't be regenerated.| -Justice|Ice Age|366|U|{2}{W}{W}|Enchantment|||At the beginning of your upkeep, sacrifice Justice unless you pay {W}{W}.$$Whenever a red creature or spell deals damage, Justice deals that much damage to that creature's or spell's controller.| +Justice|Ice Age|256|U|{2}{W}{W}|Enchantment|||At the beginning of your upkeep, sacrifice Justice unless you pay {W}{W}.$$Whenever a red creature or spell deals damage, Justice deals that much damage to that creature's or spell's controller.| Fiery Justice|Ice Age|366|R|{R}{G}{W}|Sorcery|||Fiery Justice deals 5 damage divided as you choose among any number of target creatures and/or players. Target opponent gains 5 life.| Fire Covenant|Ice Age|367|U|{1}{B}{R}|Instant|||As an additional cost to cast Fire Covenant, pay X life.$Fire Covenant deals X damage divided as you choose among any number of target creatures.| Flooded Woodlands|Ice Age|368|R|{2}{U}{B}|Enchantment|||Green creatures can't attack unless their controller sacrifices a land for each green creature he or she controls that's attacking.| @@ -6993,13 +6994,13 @@ Stormbind|Ice Age|382|R|{1}{R}{G}|Enchantment|||{2}, Discard a card at random: S Wings of Aesthir|Ice Age|383|U|{W}{U}|Enchantment - Aura|||Enchant creature$Enchanted creature gets +1/+0 and has flying and first strike.| Minion of Tevesh Szat|Ice Age|39|R|{4}{B}{B}{B}|Creature - Demon Minion|4|4|At the beginning of your upkeep, Minion of Tevesh Szat deals 2 damage to you unless you pay {B}{B}.${tap}: Target creature gets +3/-2 until end of turn.| Burnt Offering|Ice Age|4|C|{B}|Instant|||As an additional cost to cast Burnt Offering, sacrifice a creature.$Add X mana in any combination of {B} and/or {R} to your mana pool, where X is the sacrificed creature's converted mana cost.| -Trailblazer|Ice Age|4|R|{2}{G}{G}|Instant|||Target creature is unblockable this turn.| +Trailblazer|Ice Age|160|R|{2}{G}{G}|Instant|||Target creature is unblockable this turn.| Mole Worms|Ice Age|40|U|{2}{B}|Creature - Worm|1|1|You may choose not to untap Mole Worms during your untap step.${tap}: Tap target land. It doesn't untap during its controller's untap step for as long as Mole Worms remains tapped.| Moor Fiend|Ice Age|41|C|{3}{B}|Creature - Horror|3|3|Swampwalk| Necropotence|Ice Age|42|R|{B}{B}{B}|Enchantment|||Skip your draw step.$Whenever you discard a card, exile that card from your graveyard.$Pay 1 life: Exile the top card of your library face down. Put that card into your hand at the beginning of your next end step.| Norritt|Ice Age|43|C|{3}{B}|Creature - Imp|1|1|{tap}: Untap target blue creature.${tap}: Choose target non-Wall creature the active player has controlled continuously since the beginning of the turn. That creature attacks this turn if able. If it doesn't, destroy it at the beginning of the next end step. Activate this ability only before attackers are declared.| Oath of Lim-Dul|Ice Age|44|R|{3}{B}|Enchantment|||Whenever you lose life, for each 1 life you lost, sacrifice a permanent other than Oath of Lim-Dûl unless you discard a card. (Damage dealt to you causes you to lose life.)${B}{B}: Draw a card.| -Melee|Ice Age|44|U|{4}{R}|Instant|||Cast Melee only during your turn and only during combat before blockers are declared.$You choose which creatures block this combat and how those creatures block.$Whenever a creature attacks and isn't blocked this combat, untap it and remove it from combat.| +Melee|Ice Age|200|U|{4}{R}|Instant|||Cast Melee only during your turn and only during combat before blockers are declared.$You choose which creatures block this combat and how those creatures block.$Whenever a creature attacks and isn't blocked this combat, untap it and remove it from combat.| Pestilence Rats|Ice Age|45|C|{2}{B}|Creature - Rat|*|3|Pestilence Rats's power is equal to the number of other Rats on the battlefield. (For example, as long as there are two other Rats on the battlefield, Pestilence Rats's power and toughness are 2/3.)| Pox|Ice Age|46|R|{B}{B}{B}|Sorcery|||Each player loses a third of his or her life, then discards a third of the cards in his or her hand, then sacrifices a third of the creatures he or she controls, then sacrifices a third of the lands he or she controls. Round up each time.| Seizures|Ice Age|47|C|{1}{B}|Enchantment - Aura|||Enchant creature$Whenever enchanted creature becomes tapped, Seizures deals 3 damage to that creature's controller unless that player pays {3}.| @@ -7027,7 +7028,7 @@ Dreams of the Dead|Ice Age|66|U|{3}{U}|Enchantment|||{1}{U}: Return target white Enervate|Ice Age|67|C|{1}{U}|Instant|||Tap target artifact, creature, or land.$$Draw a card at the beginning of the next turn's upkeep.| Errant Minion|Ice Age|68|C|{2}{U}|Enchantment - Aura|||Enchant creature$At the beginning of the upkeep of enchanted creature's controller, that player may pay any amount of mana. Errant Minion deals 2 damage to that player. Prevent X of that damage, where X is the amount of mana that player paid this way.| Essence Flare|Ice Age|69|C|{U}|Enchantment - Aura|||Enchant creature$Enchanted creature gets +2/+0.$At the beginning of the upkeep of enchanted creature's controller, put a -0/-1 counter on that creature.| -Flare|Ice Age|69|C|{2}{R}|Instant|||Flare deals 1 damage to target creature or player.$$Draw a card at the beginning of the next turn's upkeep.| +Flare|Ice Age|185|C|{2}{R}|Instant|||Flare deals 1 damage to target creature or player.$$Draw a card at the beginning of the next turn's upkeep.| Dark Banishing|Ice Age|7|C|{2}{B}|Instant|||Destroy target nonblack creature. It can't be regenerated.| Force Void|Ice Age|70|U|{2}{U}|Instant|||Counter target spell unless its controller pays {1}.$$Draw a card at the beginning of the next turn's upkeep.| Glacial Wall|Ice Age|71|U|{2}{U}|Creature - Wall|0|7|Defender (This creature can't attack.)| @@ -7039,7 +7040,7 @@ Illusionary Presence|Ice Age|76|R|{1}{U}{U}|Creature - Illusion|2|2|Cumulative u Tor Giant|Ice Age|76|C|{3}{R}|Creature - Giant|3|3|| Illusionary Terrain|Ice Age|77|U|{U}{U}|Enchantment|||Cumulative upkeep {2} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$As Illusionary Terrain enters the battlefield, choose two basic land types.$Basic lands of the first chosen type are the second chosen type.| Illusionary Wall|Ice Age|78|C|{4}{U}|Creature - Illusion Wall|7|4|Defender, flying, first strike$Cumulative upkeep {U} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)| -Aggression|Ice Age|78|U|{2}{R}|Enchantment - Aura|||Enchant non-Wall creature$Enchanted creature has first strike and trample.$At the beginning of the end step of enchanted creature's controller, destroy that creature if it didn't attack this turn.| +Aggression|Ice Age|169|U|{2}{R}|Enchantment - Aura|||Enchant non-Wall creature$Enchanted creature has first strike and trample.$At the beginning of the end step of enchanted creature's controller, destroy that creature if it didn't attack this turn.| Illusions of Grandeur|Ice Age|79|R|{3}{U}|Enchantment|||Cumulative upkeep {2} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$When Illusions of Grandeur enters the battlefield, you gain 20 life.$When Illusions of Grandeur leaves the battlefield, you lose 20 life.| Dark Ritual|Ice Age|8|C|{B}|Instant|||Add {B}{B}{B} to your mana pool.| Infuse|Ice Age|80|C|{2}{U}|Instant|||Untap target artifact, creature, or land.$$Draw a card at the beginning of the next turn's upkeep.| @@ -7053,15 +7054,15 @@ Mystic Remora|Ice Age|87|C|{U}|Enchantment|||Cumulative upkeep {1} (At the be Phantasmal Mount|Ice Age|88|U|{1}{U}|Creature - Illusion Horse|1|1|Flying${tap}: Target creature you control with toughness 2 or less gets +1/+1 and gains flying until end of turn. When Phantasmal Mount leaves the battlefield this turn, sacrifice that creature. When the creature leaves the battlefield this turn, sacrifice Phantasmal Mount.| Polar Kraken|Ice Age|89|R|{8}{U}{U}{U}|Creature - Kraken|11|11|Trample$Polar Kraken enters the battlefield tapped.$Cumulative upkeep-Sacrifice a land. (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)| Demonic Consultation|Ice Age|9|U|{B}|Instant|||Name a card. Exile the top six cards of your library, then reveal cards from the top of your library until you reveal the named card. Put that card into your hand and exile all other cards revealed this way.| -Formation|Ice Age|9|R|{1}{W}|Instant|||Target creature gains banding 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 a player controls are blocking or being blocked by a creature, that player divides that creature's combat damage, not its controller, among any of the creatures it's being blocked by or is blocking.)$Draw a card at the beginning of the next turn's upkeep.| +Formation|Ice Age|249|R|{1}{W}|Instant|||Target creature gains banding 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 a player controls are blocking or being blocked by a creature, that player divides that creature's combat damage, not its controller, among any of the creatures it's being blocked by or is blocking.)$Draw a card at the beginning of the next turn's upkeep.| Portent|Ice Age|90|C|{U}|Sorcery|||Look at the top three cards of target player's library, then put them back in any order. You may have that player shuffle his or her library.$Draw a card at the beginning of the next turn's upkeep.| Power Sink|Ice Age|91|C|{X}{U}|Instant|||Counter target spell unless its controller pays {X}. If he or she doesn't, that player taps all lands with mana abilities he or she controls and empties his or her mana pool.| -Blizzard|Ice Age|91|R|{G}{G}|Enchantment|||Cast Blizzard only if you control a snow land.$Cumulative upkeep {2} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$Creatures with flying don't untap during their controllers' untap steps.| +Blizzard|Ice Age|115|R|{G}{G}|Enchantment|||Cast Blizzard only if you control a snow land.$Cumulative upkeep {2} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$Creatures with flying don't untap during their controllers' untap steps.| Ray of Command|Ice Age|92|C|{3}{U}|Instant|||Untap target creature an opponent controls and gain control of it until end of turn. That creature gains haste until end of turn. When you lose control of the creature, tap it.| Ray of Erasure|Ice Age|93|C|{U}|Instant|||Target player puts the top card of his or her library into his or her graveyard.$Draw a card at the beginning of the next turn's upkeep.| Reality Twist|Ice Age|94|R|{U}{U}{U}|Enchantment|||Cumulative upkeep {1}{U}{U} (At the beginning of your upkeep, put an age counter on this permanent, then sacrifice it unless you pay its upkeep cost for each age counter on it.)$If tapped for mana, Plains produce {R}, Swamps produce {G}, Mountains produce {W}, and Forests produce {B} instead of any other type.| Sea Spirit|Ice Age|95|U|{4}{U}|Creature - Elemental Spirit|2|3|{U}: Sea Spirit gets +1/+0 until end of turn.| -Rally|Ice Age|95|C|{W}{W}|Instant|||Blocking creatures get +1/+1 until end of turn.| +Rally|Ice Age|272|C|{W}{W}|Instant|||Blocking creatures get +1/+1 until end of turn.| Shyft|Ice Age|96|R|{4}{U}|Creature - Shapeshifter|4|2|At the beginning of your upkeep, you may have Shyft become the color or colors of your choice. (This effect lasts indefinitely.)| Sibilant Spirit|Ice Age|97|R|{5}{U}|Creature - Spirit|5|6|Flying$Whenever Sibilant Spirit attacks, defending player may draw a card.| Silver Erne|Ice Age|98|U|{3}{U}|Creature - Bird|2|2|Flying, trample| @@ -7509,7 +7510,7 @@ Charging Troll|Invasion|239|U|{2}{G}{W}|Creature - Troll|3|3|Vigilance${G}: Rege Pledge of Loyalty|Invasion|24|U|{1}{W}|Enchantment - Aura|||Enchant creature$Enchanted creature has protection from the colors of permanents you control. This effect doesn't remove Pledge of Loyalty.| Cinder Shade|Invasion|240|U|{1}{B}{R}|Creature - Shade|1|1|{B}: Cinder Shade gets +1/+1 until end of turn.${R}, Sacrifice Cinder Shade: Cinder Shade deals damage equal to its power to target creature.| Coalition Victory|Invasion|241|R|{3}{W}{U}{B}{R}{G}|Sorcery|||You win the game if you control a land of each basic land type and a creature of each color.| -Crosis, the Purger|Invasion|242|R|{3}{U}|Legendary Creature - Dragon|6|6|Flying$Whenever Crosis, the Purger deals combat damage to a player, you may pay {2}{B}. If you do, choose a color, then that player reveals his or her hand and discards all cards of that color.| +Crosis, the Purger|Invasion|242|R|{3}{U}{B}{R}|Legendary Creature - Dragon|6|6|Flying$Whenever Crosis, the Purger deals combat damage to a player, you may pay {2}{B}. If you do, choose a color, then that player reveals his or her hand and discards all cards of that color.| Darigaaz, the Igniter|Invasion|243|R|{3}{B}{R}{G}|Legendary Creature - Dragon|6|6|Flying$Whenever Darigaaz, the Igniter deals combat damage to a player, you may pay {2}{R}. If you do, choose a color, then that player reveals his or her hand and Darigaaz deals damage to the player equal to the number of cards of that color revealed this way.| Dromar, the Banisher|Invasion|244|R|{3}{W}{U}{B}|Legendary Creature - Dragon|6|6|Flying$Whenever Dromar, the Banisher deals combat damage to a player, you may pay {2}{U}. If you do, choose a color, then return all creatures of that color to their owners' hands.| Dueling Grounds|Invasion|245|R|{1}{G}{W}|Enchantment|||No more than one creature can attack each turn.$No more than one creature can block each turn.| @@ -10651,7 +10652,7 @@ Exile|Masters Edition|12|C|{2}{W}|Instant|||Exile target nonwhite attacking crea Ghazban Ogre|Masters Edition|120|C|{G}|Creature - Ogre|2|2|At the beginning of your upkeep, if a player has more life than each other player, the player with the most life gains control of Ghazbán Ogre.| Hungry Mist|Masters Edition|121|C|{2}{G}{G}|Creature - Elemental|6|2|At the beginning of your upkeep, sacrifice Hungry Mist unless you pay {G}{G}.| Ice Storm|Masters Edition|122|U|{2}{G}|Sorcery|||Destroy target land.| -Ifh-B ff Efreet|Masters Edition|123|R|{2}{G}{G}|Creature - Efreet|3|3|Flying${G}: Ifh-Bíff Efreet deals 1 damage to each creature with flying and each player. Any player may activate this ability.| +Ifh-Biff Efreet|Masters Edition|123|R|{2}{G}{G}|Creature - Efreet|3|3|Flying${G}: Ifh-Biff Efreet deals 1 damage to each creature with flying and each player. Any player may activate this ability.| Nature's Lore|Masters Edition|124|C|{1}{G}|Sorcery|||Search your library for a Forest card and put that card onto the battlefield. Then shuffle your library.| Primal Order|Masters Edition|125|R|{2}{G}{G}|Enchantment|||At the beginning of each player's upkeep, Primal Order deals damage to that player equal to the number of nonbasic lands he or she controls.| Rabid Wombat|Masters Edition|126|U|{2}{G}{G}|Creature - Wombat|0|1|Vigilance$Rabid Wombat gets +2/+2 for each Aura attached to it.| @@ -11088,7 +11089,7 @@ Faerie Noble|Masters Edition III|117|U|{2}{G}|Creature - Faerie|1|2|Flying$Other Fire Sprites|Masters Edition III|118|C|{1}{G}|Creature - Faerie|1|1|Flying${G}, {tap}: Add {R} to your mana pool.| Freyalise's Winds|Masters Edition III|119|R|{2}{G}{G}|Enchantment|||Whenever a permanent becomes tapped, put a wind counter on it.$If a permanent with a wind counter on it would untap during its controller's untap step, remove all wind counters from it instead.| Guan Yu, Sainted Warrior|Masters Edition III|12|U|{3}{W}{W}|Legendary Creature - Human Soldier Warrior|3|5|Horsemanship (This creature can't be blocked except by creatures with horsemanship.)$When Guan Yu, Sainted Warrior is put into your graveyard from the battlefield, you may shuffle Guan Yu into your library.| -Gaea's Touch|Masters Edition III|120|U|{G}{G}|Enchantment|||You may play an additional land during your turn if that land is a basic Forest.$Sacrifice Gaea's Touch: Add {G}{G} to your mana pool.| +Gaea's Touch|Masters Edition III|120|U|{G}{G}|Enchantment|||You may put a basic Forest card from your hand onto the battlefield. Activate this ability only any time you could cast a sorcery and only once each turn.$Sacrifice Gaea's Touch: Add {G}{G} to your mana pool.| Giant Growth|Masters Edition III|121|C|{G}|Instant|||Target creature gets +3/+3 until end of turn.| Heavy Fog|Masters Edition III|122|C|{1}{G}|Instant|||Cast Heavy Fog only during the declare attackers step and only if you've been attacked this step.$Prevent all damage that would be dealt to you this turn by attacking creatures.| Hua Tuo, Honored Physician|Masters Edition III|123|R|{1}{G}{G}|Legendary Creature - Human|1|2|{tap}: Put target creature card from your graveyard on top of your library. Activate this ability only during your turn, before attackers are declared.| @@ -11919,7 +11920,7 @@ Tidal Wave|Mirage|100|U|{2}{U}|Instant|||Put a 5/5 blue Wall creature token with Vaporous Djinn|Mirage|101|U|{2}{U}{U}|Creature - Djinn|3|4|Flying$At the beginning of your upkeep, Vaporous Djinn phases out unless you pay {U}{U}. (While it's phased out, it's treated as though it doesn't exist. It phases in before you untap during your next untap step.)| Wave Elemental|Mirage|102|U|{2}{U}{U}|Creature - Elemental|2|3|{U}, {tap}, Sacrifice Wave Elemental: Tap up to three target creatures without flying.| Afiya Grove|Mirage|103|R|{1}{G}|Enchantment|||Afiya Grove enters the battlefield with three +1/+1 counters on it.$At the beginning of your upkeep, move a +1/+1 counter from Afiya Grove onto target creature.$When Afiya Grove has no +1/+1 counters on it, sacrifice it.| -Thirst|Mirage|104|C|{2}{U}|Enchantment - Aura|||Enchant creature$When Thirst enters the battlefield, tap enchanted creature.$Enchanted creature doesn't untap during its controller's untap step.$At the beginning of your upkeep, sacrifice Thirst unless you pay {U}.| +Thirst|Mirage|99|C|{2}{U}|Enchantment - Aura|||Enchant creature$When Thirst enters the battlefield, tap enchanted creature.$Enchanted creature doesn't untap during its controller's untap step.$At the beginning of your upkeep, sacrifice Thirst unless you pay {U}.| Armor of Thorns|Mirage|104|C|{1}{G}|Enchantment - Aura|||You may cast Armor of Thorns as though it had flash. If you cast it any time a sorcery couldn't have been cast, the controller of the permanent it becomes sacrifices it at the beginning of the next cleanup step.$Enchant nonblack creature$Enchanted creature gets +2/+2.| Barbed Foliage|Mirage|105|U|{2}{G}{G}|Enchantment|||Whenever a creature attacks you, it loses flanking until end of turn.$$Whenever a creature without flying attacks you, Barbed Foliage deals 1 damage to it.| Brushwagg|Mirage|106|R|{1}{G}{G}|Creature - Brushwagg|3|2|Whenever Brushwagg blocks or becomes blocked, it gets -2/+2 until end of turn.| @@ -11928,7 +11929,7 @@ Crash of Rhinos|Mirage|108|C|{6}{G}{G}|Creature - Rhino|8|4|Trample| Cycle of Life|Mirage|109|R|{1}{G}{G}|Enchantment|||Return Cycle of Life to its owner's hand: Target creature you cast this turn becomes 0/1 until your next upkeep. At the beginning of your next upkeep, put a +1/+1 counter on that creature.| Choking Sands|Mirage|11|C|{1}{B}{B}|Sorcery|||Destroy target non-Swamp land. If that land was nonbasic, Choking Sands deals 2 damage to the land's controller.| Decomposition|Mirage|110|U|{1}{G}|Enchantment - Aura|||Enchant black creature$Enchanted creature has "Cumulative upkeep-Pay 1 life." (At the beginning of its controller's upkeep, that player puts an age counter on it, then sacrifices it unless he or she pays its upkeep cost for each age counter on it.)$When enchanted creature dies, its controller loses 2 life.| -Wellspring|Mirage|110|R|{1}{G}{W}|Enchantment - Aura|||Enchant land$When Wellspring enters the battlefield, gain control of enchanted land until end of turn.$At the beginning of your upkeep, untap enchanted land. You gain control of that land until end of turn.| +Wellspring|Mirage|348|R|{1}{G}{W}|Enchantment - Aura|||Enchant land$When Wellspring enters the battlefield, gain control of enchanted land until end of turn.$At the beginning of your upkeep, untap enchanted land. You gain control of that land until end of turn.| Early Harvest|Mirage|111|R|{1}{G}{G}|Instant|||Target player untaps all basic lands he or she controls.| Fallow Earth|Mirage|112|U|{2}{G}|Sorcery|||Put target land on top of its owner's library.| Femeref Archers|Mirage|113|U|{2}{G}|Creature - Human Archer|2|2|{tap}: Femeref Archers deals 4 damage to target attacking creature with flying.| @@ -12024,7 +12025,7 @@ Subterranean Spirit|Mirage|195|R|{3}{R}{R}|Creature - Elemental Spirit|3|3|Prote Talruum Minotaur|Mirage|196|C|{2}{R}{R}|Creature - Minotaur Berserker|3|3|Haste| Telim'Tor|Mirage|197|R|{4}{R}|Legendary Creature - Human Knight|2|2|Flanking (Whenever a creature without flanking blocks this creature, the blocking creature gets -1/-1 until end of turn.)$Whenever Telim'Tor attacks, all attacking creatures with flanking get +1/+1 until end of turn.| Telim'Tor's Edict|Mirage|198|R|{R}|Instant|||Exile target permanent you own or control.$Draw a card at the beginning of the next turn's upkeep.| -Dwarven Miner|Mirage|199|U|{1}{R}|Creature - Dwarf|1|2|{2}{R}, {tap}: Destroy target nonbasic land.| +Dwarven Miner|Mirage|169|U|{1}{R}|Creature - Dwarf|1|2|{2}{R}, {tap}: Destroy target nonbasic land.| Torrent of Lava|Mirage|199|R|{X}{R}{R}|Sorcery|||Torrent of Lava deals X damage to each creature without flying.$As long as Torrent of Lava is on the stack, each creature has "{tap}: Prevent the next 1 damage that would be dealt to this creature by Torrent of Lava this turn."| Ashen Powder|Mirage|2|R|{2}{B}{B}|Sorcery|||Put target creature card from an opponent's graveyard onto the battlefield under your control.| Feral Shadow|Mirage|20|C|{2}{B}|Creature - Nightstalker|2|1|Flying| @@ -12130,32 +12131,32 @@ Mire Shade|Mirage|29|U|{1}{B}|Creature - Shade|1|1|{B}, Sacrifice a Swamp: Put a Crystal Vein|Mirage|290|U||Land|||{tap}: Add {1} to your mana pool.${tap}, Sacrifice Crystal Vein: Add {2} to your mana pool.| Flood Plain|Mirage|291|U||Land|||Flood Plain enters the battlefield tapped.${tap}, Sacrifice Flood Plain: Search your library for a Plains or Island card and put it onto the battlefield. Then shuffle your library.| Forest|Mirage|292|L||Basic Land - Forest|||G| -Forest|Mirage|292|L||Basic Land - Forest|||G| -Forest|Mirage|292|L||Basic Land - Forest|||G| -Forest|Mirage|292|L||Basic Land - Forest|||G| +Forest|Mirage|293|L||Basic Land - Forest|||G| +Forest|Mirage|294|L||Basic Land - Forest|||G| +Forest|Mirage|295|L||Basic Land - Forest|||G| Grasslands|Mirage|296|U||Land|||Grasslands enters the battlefield tapped.${tap}, Sacrifice Grasslands: Search your library for a Forest or Plains card and put it onto the battlefield. Then shuffle your library.| Island|Mirage|297|L||Basic Land - Island|||U| -Island|Mirage|297|L||Basic Land - Island|||U| -Island|Mirage|297|L||Basic Land - Island|||U| -Island|Mirage|297|L||Basic Land - Island|||U| +Island|Mirage|298|L||Basic Land - Island|||U| +Island|Mirage|299|L||Basic Land - Island|||U| +Island|Mirage|300|L||Basic Land - Island|||U| Barbed-Back Wurm|Mirage|3|U|{4}{B}|Creature - Wurm|4|3|{B}: Target green creature blocking Barbed-Back Wurm gets -1/-1 until end of turn.| Nocturnal Raid|Mirage|30|U|{2}{B}{B}|Instant|||Black creatures get +2/+0 until end of turn.| -Shimmer|Mirage|30|R|{2}{U}{U}|Enchantment|||As Shimmer enters the battlefield, choose a land type.$Each land of the chosen type has phasing. (It phases in or out before its controller untaps during each of his or her untap steps. While it's phased out, it's treated as though it doesn't exist.)| -Mountain|Mirage|301|L||Basic Land - Mountain|||R| -Mountain|Mirage|301|L||Basic Land - Mountain|||R| -Mountain|Mirage|301|L||Basic Land - Mountain|||R| +Shimmer|Mirage|92|R|{2}{U}{U}|Enchantment|||As Shimmer enters the battlefield, choose a land type.$Each land of the chosen type has phasing. (It phases in or out before its controller untaps during each of his or her untap steps. While it's phased out, it's treated as though it doesn't exist.)| Mountain|Mirage|301|L||Basic Land - Mountain|||R| +Mountain|Mirage|302|L||Basic Land - Mountain|||R| +Mountain|Mirage|303|L||Basic Land - Mountain|||R| +Mountain|Mirage|304|L||Basic Land - Mountain|||R| Mountain Valley|Mirage|305|U||Land|||Mountain Valley enters the battlefield tapped.${tap}, Sacrifice Mountain Valley: Search your library for a Mountain or Forest card and put it onto the battlefield. Then shuffle your library.| Plains|Mirage|306|L||Basic Land - Plains|||W| -Plains|Mirage|306|L||Basic Land - Plains|||W| -Plains|Mirage|306|L||Basic Land - Plains|||W| -Plains|Mirage|306|L||Basic Land - Plains|||W| +Plains|Mirage|307|L||Basic Land - Plains|||W| +Plains|Mirage|308|L||Basic Land - Plains|||W| +Plains|Mirage|309|L||Basic Land - Plains|||W| Painful Memories|Mirage|31|U|{1}{B}|Sorcery|||Look at target opponent's hand and choose a card from it. Put that card on top of that player's library.| Rocky Tar Pit|Mirage|310|U||Land|||Rocky Tar Pit enters the battlefield tapped.${tap}, Sacrifice Rocky Tar Pit: Search your library for a Swamp or Mountain card and put it onto the battlefield. Then shuffle your library.| Swamp|Mirage|311|L||Basic Land - Swamp|||B| -Swamp|Mirage|311|L||Basic Land - Swamp|||B| -Swamp|Mirage|311|L||Basic Land - Swamp|||B| -Swamp|Mirage|311|L||Basic Land - Swamp|||B| +Swamp|Mirage|312|L||Basic Land - Swamp|||B| +Swamp|Mirage|313|L||Basic Land - Swamp|||B| +Swamp|Mirage|314|L||Basic Land - Swamp|||B| Teferi's Isle|Mirage|315|R||Legendary Land|||Phasing (This phases in or out before you untap during each of your untap steps. While it's phased out, it's treated as though it doesn't exist.)$Teferi's Isle enters the battlefield tapped.${tap}: Add {U}{U} to your mana pool.| Asmira, Holy Avenger|Mirage|316|R|{2}{G}{W}|Legendary Creature - Human Cleric|2|3|Flying$At the beginning of each end step, put a +1/+1 counter on Asmira, Holy Avenger for each creature put into your graveyard from the battlefield this turn.| Benthic Djinn|Mirage|317|R|{2}{U}{B}|Creature - Djinn|5|3|Islandwalk$$At the beginning of your upkeep, you lose 2 life.| @@ -12513,7 +12514,7 @@ Override|Mirrodin|45|C|{2}{U}|Instant|||Counter target spell unless its controll Psychic Membrane|Mirrodin|46|U|{2}{U}|Creature - Wall|0|3|Defender (This creature can't attack.)$Whenever Psychic Membrane blocks, you may draw a card.| Quicksilver Elemental|Mirrodin|47|R|{3}{U}{U}|Creature - Elemental|3|4|{U}: Quicksilver Elemental gains all activated abilities of target creature until end of turn. (If any of the abilities use that creature's name, use this creature's name instead.)$You may spend blue mana as though it were mana of any color to pay the activation costs of Quicksilver Elemental's abilities.| Regress|Mirrodin|48|C|{2}{U}|Instant|||Return target permanent to its owner's hand.| -Shared Fate|Mirrodin|49|R|{4}{U}|Enchantment|||If a player would draw a card, that player exiles the top card of an opponent's library face down instead.$Each player may look at and play cards he or she exiled with Shared Fate.| +Shared Fate|Mirrodin|49|R|{4}{U}|Enchantment|||If a player would draw a card, that player exiles the top card of one of his or her opponents' libraries face down instead.$Each player may look at and play cards he or she exiled with Shared Fate.| Auriok Transfixer|Mirrodin|5|C|{W}|Creature - Human Scout|1|1|{W}, {tap}: Tap target artifact.| Slith Strider|Mirrodin|50|U|{1}{U}{U}|Creature - Slith|1|1|Whenever Slith Strider becomes blocked, draw a card.$Whenever Slith Strider deals combat damage to a player, put a +1/+1 counter on it.| Somber Hoverguard|Mirrodin|51|C|{5}{U}|Creature - Drone|3|2|Affinity for artifacts (This spell costs {1} less to cast for each artifact you control.)$Flying| @@ -14232,7 +14233,7 @@ Discombobulate|Onslaught|79|U|{2}{U}{U}|Instant|||Counter target spell. Look at Aven Soulgazer|Onslaught|8|U|{3}{W}{W}|Creature - Bird Cleric|3|3|Flying${2}{W}: Look at target face-down creature.| Dispersing Orb|Onslaught|80|U|{3}{U}|Enchantment|||{3}{U}, Sacrifice a permanent: Return target permanent to its owner's hand.| Disruptive Pitmage|Onslaught|81|C|{2}{U}|Creature - Human Wizard|1|1|{tap}: Counter target spell unless its controller pays {1}.$Morph {U} You may cast this card face downn as a 2/2 creature for {3}. Turn it face up any time for its morph cost.)| -Essence Fracture|Onslaught|82|U|{3}{U}|Sorcery|||Return two target creatures to their owners' hands.$Cycling {2}{U} ({2}{U}, Discard this card: Draw a card.)| +Essence Fracture|Onslaught|82|U|{3}{U}{U}|Sorcery|||Return two target creatures to their owners' hands.$Cycling {2}{U} ({2}{U}, Discard this card: Draw a card.)| Fleeting Aven|Onslaught|83|U|{1}{U}{U}|Creature - Bird Wizard|2|2|Flying$Whenever a player cycles a card, return Fleeting Aven to its owner's hand.| Future Sight|Onslaught|84|R|{2}{U}{U}{U}|Enchantment|||Play with the top card of your library revealed.$You may play the top card of your library.| Ghosthelm Courier|Onslaught|85|U|{2}{U}|Creature - Human Wizard|2|1|You may choose not to untap Ghosthelm Courier during your untap step.${2}{U}, {tap}: Target Wizard creature gets +2/+2 and has shroud for as long as Ghosthelm Courier remains tapped. (It can't be the target of spells or abilities.)| @@ -15733,7 +15734,7 @@ Zephyr Spirit|Ravnica: City of Guilds|76|C|{5}{U}|Creature - Spirit|0|6|When Zep Blood Funnel|Ravnica: City of Guilds|77|R|{1}{B}|Enchantment|||Noncreature spells you cast cost {2} less to cast.$Whenever you cast a noncreature spell, counter that spell unless you sacrifice a creature.| Brainspoil|Ravnica: City of Guilds|78|C|{3}{B}{B}|Sorcery|||Destroy target creature that isn't enchanted. It can't be regenerated.$Transmute {1}{B}{B} ({1}{B}{B}, Discard this card: Search your library for a card with the same converted mana cost as this card, reveal it, and put it into your hand. Then shuffle your library. Transmute only as a sorcery.)| Carrion Howler|Ravnica: City of Guilds|79|U|{3}{B}|Creature - Zombie Wolf|2|2|Pay 1 life: Carrion Howler gets +2/-1 until end of turn.| -Concerted Effort|Ravnica: City of Guilds|8|R|{2}{W}{W}|Enchantment|||At the beginning of each upkeep, all creatures you control gain flying until end of turn if a creature you control has flying. The same is true for fear, first strike, double strike, landwalk, protection, trample, and vigilance.| +Concerted Effort|Ravnica: City of Guilds|8|R|{2}{W}{W}|Enchantment|||At the beginning of each upkeep, creatures you control gain flying until end of turn if a creature you control has flying. The same is true for fear, first strike, double strike, landwalk, protection, trample, and vigilance.| Clinging Darkness|Ravnica: City of Guilds|80|C|{1}{B}|Enchantment - Aura|||Enchant creature$Enchanted creature gets -4/-1.| Dark Confidant|Ravnica: City of Guilds|81|R|{1}{B}|Creature - Human Wizard|2|1|At the beginning of your upkeep, reveal the top card of your library and put that card into your hand. You lose life equal to its converted mana cost.| Darkblast|Ravnica: City of Guilds|82|U|{B}|Instant|||Target creature gets -1/-1 until end of turn.$Dredge 3 (If you would draw a card, instead you may put exactly three cards from the top of your library into your graveyard. If you do, return this card from your graveyard to your hand. Otherwise, draw a card.)| @@ -19206,7 +19207,7 @@ Riptide|The Dark|38|C|{U}|Instant|||Tap all blue creatures.| Carnivorous Plant|The Dark|38|C|{3}{G}|Creature - Plant Wall|4|5|Defender| Elves of Deep Shadow|The Dark|39|U|{G}|Creature - Elf Druid|1|1|{tap}: Add {B} to your mana pool. Elves of Deep Shadow deals 1 damage to you.| Bog Rats|The Dark|4|C|{B}|Creature - Rat|1|1|Bog Rats can't be blocked by Walls.| -Gaea's Touch|The Dark|40|C|{G}{G}|Enchantment|||You may play an additional land during your turn if that land is a basic Forest.$Sacrifice Gaea's Touch: Add {G}{G} to your mana pool.| +Gaea's Touch|The Dark|40|C|{G}{G}|Enchantment|||You may put a basic Forest card from your hand onto the battlefield. Activate this ability only any time you could cast a sorcery and only once each turn.$Sacrifice Gaea's Touch: Add {G}{G} to your mana pool.| Hidden Path|The Dark|41|R|{2}{G}{G}{G}{G}|Enchantment|||Green creatures have forestwalk.| Land Leeches|The Dark|42|C|{1}{G}{G}|Creature - Leech|2|2|First strike| Marsh Viper|The Dark|44|C|{3}{G}|Creature - Snake|1|2|Whenever Marsh Viper deals damage to a player, that player gets two poison counters. (A player with ten or more poison counters loses the game.)| @@ -27232,3 +27233,20 @@ Island|Premium Deck Series: Slivers|38|L||Basic Land - Island|||U| Swamp|Premium Deck Series: Slivers|39|L||Basic Land - Swamp|||B| Mountain|Premium Deck Series: Slivers|40|L||Basic Land - Mountain|||R| Forest|Premium Deck Series: Slivers|41|L||Basic Land - Forest|||G| +Akroma, Angel of Fury|From the Vault: Angels|1|M|{5}{R}{R}{R}|Legendary Creature - Angel|6|6|Akroma, Angel of Fury can't be countered.$Flying, trample, protection from white and from blue${R}: Akroma, Angel of Fury gets +1/+0 until end of turn.$Morph {3}{R}{R}{R} You may cast this card face downn as a 2/2 creature for {3}. Turn it face up any time for its morph cost.)| +Akroma, Angel of Wrath|From the Vault: Angels|2|M|{5}{W}{W}{W}|Legendary Creature - Angel|6|6|Flying, first strike, vigilance, trample, haste, protection from black and from red| +Archangel of Strife|From the Vault: Angels|3|M|{5}{W}{W}|Creature - Angel|6|6|Flying$As Archangel of Strife enters the battlefield, each player chooses war or peace.$Creatures controlled by players who chose war get +3/+0.$Creatures controlled by players who chose peace get +0/+3.| +Aurelia, the Warleader|From the Vault: Angels|4|M|{2}{R}{R}{W}{W}|Legendary Creature - Angel|3|4|Flying, vigilance, haste$Whenever Aurelia, the Warleader attacks for the first time each turn, untap all creatures you control. After this phase, there is an additional combat phase.| +Avacyn, Angel of Hope|From the Vault: Angels|5|M|{5}{W}{W}{W}|Legendary Creature - Angel|8|8|Flying, vigilance$Avacyn, Angel of Hope and other permanents you control are indestructible.| +Baneslayer Angel|From the Vault: Angels|6|M|{3}{W}{W}|Creature - Angel|5|5|Flying, first strike, lifelink, protection from Demons and from Dragons| +Entreat the Angels|From the Vault: Angels|7|M|{X}{X}{W}{W}{W}|Sorcery|||Put X 4/4 white Angel creature tokens with flying onto the battlefield.$Miracle {X}{W}{W} (You may cast this card for its miracle cost when you draw it if it's the first card you drew this turn.)| +Exalted Angel|From the Vault: Angels|8|M|{4}{W}{W}|Creature - Angel|4|5|Flying$Whenever Exalted Angel deals damage, you gain that much life.$Morph {2}{W}{W} You may cast this card face downn as a 2/2 creature for {3}. Turn it face up any time for its morph cost.)| +Iona, Shield of Emeria|From the Vault: Angels|9|M|{6}{W}{W}{W}|Legendary Creature - Angel|7|7|Flying$As Iona, Shield of Emeria enters the battlefield, choose a color.$Your opponents can't cast spells of the chosen color.| +Iridescent Angel|From the Vault: Angels|10|M|{5}{W}{U}|Creature - Angel|4|4|Flying, protection from all colors| +Jenara, Asura of War|From the Vault: Angels|11|M|{G}{W}{U}|Legendary Creature - Angel|3|3|Flying${1}{W}: Put a +1/+1 counter on Jenara, Asura of War.| +Lightning Angel|From the Vault: Angels|12|M|{1}{R}{W}{U}|Creature - Angel|3|4|Flying, vigilance, haste| +Platinum Angel|From the Vault: Angels|13|M|{7}|Artifact Creature - Angel|4|4|Flying$You can't lose the game and your opponents can't win the game.| +Serra Angel|From the Vault: Angels|14|M|{3}{W}{W}|Creature - Angel|4|4|Flying$Vigilance (Attacking doesn't cause this creature to tap.)| +Tariel, Reckoner of Souls|From the Vault: Angels|15|M|{4}{W}{B}{R}|Legendary Creature - Angel|4|7|Flying, vigilance${tap}: Choose a creature card at random from target opponent's graveyard. Put that card onto the battlefield under your control.| +Oblivion Sower|Battle for Zendikar|999|M|{6}|Creature - Eldrazi|5|8|When you cast Oblivion Sower, target opponent exiles the top four cards of his or her library, then you may put any number of land cards that player owns from exile onto the battlefield under your control.| +Evolving Wilds|Battle for Zendikar|236|C||Land|||{T}, Sacrifice Evolving Wilds: Search your library for a basic land card and put it onto the battlefield tapped. Then shuffle your library.| \ No newline at end of file diff --git a/Utils/mtg-sets-data.txt b/Utils/mtg-sets-data.txt index c14da882fa5..090a2e72212 100644 --- a/Utils/mtg-sets-data.txt +++ b/Utils/mtg-sets-data.txt @@ -15,6 +15,7 @@ Anthologies|ATH| Antiquities|ATQ| Archenemy|ARC| Avacyn Restored|AVR| +Battle for Zendikar|BFZ| Betrayers of Kamigawa|BOK| Battle Royale Box Set|BRB| Beatdown Box Set|BTD| diff --git a/Utils/release/getting_implemented_cards.txt b/Utils/release/getting_implemented_cards.txt index 86a8ba4c884..02ecd0925f6 100644 --- a/Utils/release/getting_implemented_cards.txt +++ b/Utils/release/getting_implemented_cards.txt @@ -149,9 +149,20 @@ git log cd0cba6ec7d8799bb85247b7b4f5d545e170b093..HEAD --diff-filter=A --name-st since 1.4.2.v1 git log 0b26aaff6ec033a538179bf607b1c7a7736aedb2..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt -since 1.4.2.v1 +since 1.4.2.v2 git log 8d5137e40ebe1c029e737ef475935ff7cc40bb64..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt +since 1.4.2.v3 +git log 60c7a2b34b5dd9a64bd415b65424a559294cf52b..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt + +since 1.4.2.v4 +git log 193177d9999d56729a687ca3b1a2fc3f3b96d9e2..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt + +since 1.4.2.v5 +git log 8dca887fadbbea41fb649ff17c5fe547a82ef23a..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt + +since 1.4.3.v0 +git log 5de4637d9c7967612c207d3cf915c2861d922029..HEAD --diff-filter=A --name-status | sed -ne "s/^A[^u]Mage.Sets\/src\/mage\/sets\///p" | sort > added_cards.txt 3. Copy added_cards.txt to trunk\Utils folder 4. Run script: diff --git a/clean_dbs.sh b/clean_dbs.sh new file mode 100644 index 00000000000..9ccf51fd6d2 --- /dev/null +++ b/clean_dbs.sh @@ -0,0 +1,3 @@ +#!/usr/bin/env bash +# Cleans the DB from Server, Client and Test modules +find . -type f | grep -i cards.h2*.db | xargs rm -v \ No newline at end of file diff --git a/pom.xml b/pom.xml index a699b320497..4cde514dc42 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ org.mage mage-root - 1.4.2 + 1.4.3 pom Mage Root Mage Root POM @@ -73,7 +73,7 @@ - 1.4.2 + 1.4.3 UTF-8 diff --git a/readme.md b/readme.md index a7ee59046a3..590ae692157 100644 --- a/readme.md +++ b/readme.md @@ -7,19 +7,18 @@ There are public servers where you can play XMage against other players. You can You can visit the XMage forum [here](http://www.slightlymagic.net/forum/viewforum.php?f=70). ## Features -* Deck editor to build your desired decks. -* There is a simple computer AI opponent available. -* You can play either a two player duel or a multiplayer free-for-all game with up to 10 players. -* Commander format (also up to 10 players). -* Tiny Leaders duels. -* There are two tournament types supported, which can be played with up to 16 players: -* Elimination or swiss type handling -* Booster (also Cube) draft tournaments (4-16) -* Sealed (also from Cube) tournaments (2-16) +* Deck editor (load and save decks) +* Simple computer AI opponent +* Two player duel or a multiplayer free-for-all game with up to 10 players +* Supports special formats like Commander (up to 10 players), Cube, Tiny Leaders, Super Standard, Historic Standard +* There are two tournament types supported (elimination or swiss type handling), which can be played with up to 16 players: + * Booster (also Cube) draft tournaments (4-16) + * Sealed (also from Cube) tournaments (2-16) + ## Installation Download and install the [latest XMage release](http://XMage.de). -You will need to have the [Java Runtime Environment](http://java.com/en/) Version 7 or later. +You will need to have Version 7 or later of the [Java Runtime Environment](http://java.com/en/). Look [here](http://www.slightlymagic.net/forum/viewtopic.php?f=70&t=13632) for more detailed instructions. [Here](http://github.com/magefree/mage/wiki/Release-changes) you can find a log of the latest changes. @@ -32,4 +31,4 @@ If you are interested in developing XMage, here are some useful resources: * [Developer Testing Tools](http://github.com/magefree/mage/wiki/Developer-Testing-Tools) * [Double Faced Cards](http://github.com/magefree/mage/wiki/Double-Faced-Cards) * [Card Requests](http://www.slightlymagic.net/forum/viewtopic.php?f=70&t=4554) -* [Tournament Relevant Card Requests](http://www.slightlymagic.net/forum/viewtopic.php?f=70&t=14062) \ No newline at end of file +* [Tournament Relevant Card Requests](http://www.slightlymagic.net/forum/viewtopic.php?f=70&t=14062)