Commit graph

1432 commits

Author SHA1 Message Date
Evan Kranzler
0d038b1737 reorganized various constructed formats 2022-03-18 09:49:34 -04:00
Evan Kranzler
02017b9a88
Implementing The Prismatic Piper (Ready for review) (#8164)
* [CMR] Implemented The Prismatic Piper

* updated commander validation to handle The Prismatic Piper

* created abstract base class for commander variants

* added ability to prismatic piper

* added game init handling

* small revert

* small reorganization of tests

* added some validation tests for piper

* added more tests for piper

* add another test

* added decklist comments to tests

* added some more piper tests

* added another test

* added mana option tests

* added a companion test

* fix conflict

* updated abstract commander to work with Friends forever

* merge fix

* Deck: added details for illegal validation of companion card;

Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2022-03-17 18:02:29 -04:00
Alex W. Jackson
79b7a0a627 Remove obsolete adjustCosts and adjustTargets methods from MageObject interface 2022-03-12 19:01:59 -05:00
Evan Kranzler
bbb9382150
Reworking effects which allow casting spells from a selection of cards (ready for review) (#8136)
* added function for casting spells with specific attributes from a selection of cards

* updated cascade to use new method

* refactored various cards to use new methods

* added TestPlayer method

* fixed a small error

* text fix

* broke out some repeated code

* added missing notTarget setting

* add additional retain zone check

* some more cards refactored

* more refactoring

* added interface for split/modal cards

* reworked spell casting methods

* reworked multiple cast to prevent unnecessary dialogs

* fixed test failures due to change in functionality

* add AI code

* small nonfunctional change

* reworked Kaya, the Inexorable

* added currently failing test

* added more tests

* updated Geode Golem implementation

* fixed adventure/cascade interaction, added/updated tests

* some nonfunctional refactoring

* added interface for subcards

* [AFC] Implemented Fevered Suspicion

* [AFC] Implemented Extract Brain

* [AFC] updated Arcane Endeavor implementation

* [C17] reworked implementation of Izzet Chemister

* [ZEN] reworked implemented of Chandra Ablaze

* additional merge fix

* [SLD] updated Eleven, the Mage

* [NEO] Implemented Discover the Impossible

* [NEO] Implemented The Dragon-Kami Reborn / Dragon-Kami's Egg

* [NEO] Implemented Invoke Calamity

* [AFR] Implemented Rod of Absorption

* [VOC] Implemented Spectral Arcanist

* [VOC] added additional printings

* [NEO] added all variants

* [SLD] updated implementation of Ken, Burning Brawler
2022-03-09 08:03:54 -05:00
Evan Kranzler
605e7a7e50 updated pauper ban list 2022-03-07 18:30:59 -05:00
Evan Kranzler
5b7314dd1c updated pioneer ban list 2022-03-07 18:30:33 -05:00
Evan Kranzler
8aef097857 updated modern ban list 2022-03-07 18:30:24 -05:00
Jackie Ng
2e44b3246c
Add Feb 2022 vintage cube (#8731)
* Add Feb 2022 vintage cube (source: https://magic.wizards.com/en/articles/archive/magic-online/vintage-cube-february-update-2022-02-15)

* Fix 3 card typos
2022-03-02 20:18:15 -05:00
Evan Kranzler
4591ac07cc
Reworking goad effects (ready for review) (#8034)
* changing goad to designation, refactored goad effects to be continuous

* [AFC] Implemented Vengeful Ancestor

* reworked effects which goad an attached creature

* updated goading implementation

* updated combat with new goad logic

* some more changes, added a test

* another fix

* update to test, still fails

* added more failing tests

* more failing tests

* added additional goad check

* small fix to two tests (still failing

* added a regular combat test (passes and fails randomly)

* fixed bug in computer player random selection

* some changes to how TargetDefender is handled

* removed unnecessary class

* more combat fixes, tests pass now

* removed tests which no longer work due to combat changes

* small merge fix

* [NEC] Implemented Komainu Battle Armor

* [NEC] Implemented Kaima, the Fractured Calm

* [NEC] added all variants
2022-02-15 09:18:21 -05:00
Evan Kranzler
54203c16d3
[NEO] Implementing Compleated mechanic and hybrid phyrexian mana (ready for review) (#8677)
* [NEO] Implemented Tamiyo, Compleated Sage

* replaced PhyrexianManaCost calls with ManaCostsImpl calls

* updated phyrexian mana implementation

* added phyrexian hybrid symbol support

* updated starting loyalty implementation for planeswalkers

* change compleated to singleton

* implemented Compleated ability

* added some missing loyalty setters

* changed when loyalty is added to a walker to fix bugs

* slight change to some tests to fix them from failing

* fixed token issue
2022-02-10 10:25:23 -05:00
Evan Kranzler
8325bef4c1 updated australian highlander points list 2022-01-31 20:01:50 -05:00
Evan Kranzler
1880a88a89 updated canadian highlander points list 2022-01-31 20:01:37 -05:00
Evan Kranzler
809421635a updated duel commander ban list 2022-01-31 20:01:24 -05:00
Bryan Benson
4d0f53da67
Add cards to banned lists (#8616)
* Ban Invoke Prejudice

* Update banlist

https://www.hipstersofthecoast.com/2020/06/wizards-bans-7-cards-that-depict-racism-including-invoke-prejudice/

* Update Legacy banlist

https://www.hipstersofthecoast.com/2020/06/wizards-bans-7-cards-that-depict-racism-including-invoke-prejudice/

* Update banlist

https://www.hipstersofthecoast.com/2020/06/wizards-bans-7-cards-that-depict-racism-including-invoke-prejudice/

* Add stone-throwing devils to banlist

* Add Stone-Throwing Devils

* Update banlist

https://www.hipstersofthecoast.com/2020/06/wizards-bans-7-cards-that-depict-racism-including-invoke-prejudice/

* Update banist

https://www.hipstersofthecoast.com/2020/06/wizards-bans-7-cards-that-depict-racism-including-invoke-prejudice/
2022-01-29 19:09:41 -05:00
Evan Kranzler
bd33191308 updated standard ban list 2022-01-25 12:49:22 -05:00
Evan Kranzler
20f1186cdd updated legacy ban list 2022-01-25 12:49:10 -05:00
Evan Kranzler
135e4c346a updated pauper ban list 2022-01-25 12:49:02 -05:00
Evan Kranzler
d0a6a59bd9 added name credit to Mono Blue Cube (closes #8513) 2021-12-17 19:05:18 -05:00
Evan Kranzler
941a2be7e9 fixed validation for partner with abilities (fixes #8482) 2021-11-28 15:25:10 -05:00
Oleg Agafonov
1f381cffe5 GUI: improved cards with transform ability:
* added transform button to permanents on battlefield to view another card side;
* fixed wrong popup hints in some use cases (example: alternative side view by mouse wheel down, #8433);
2021-11-05 23:16:44 +04:00
Evan Kranzler
5d63d4214c various updates to historic format 2021-10-14 20:54:29 -04:00
Evan Kranzler
ca189af388 added Friends forever support to regular commander 2021-10-14 19:34:54 -04:00
Oleg Agafonov
58ab020065 Dev: pom clean up, improved parent/child structure; 2021-10-03 18:11:56 +04:00
Evan Kranzler
b5033a3b7a updated various ban lists 2021-10-02 10:26:39 -04:00
Oleg Agafonov
f9beed6a89 Dev: clear pom files, fixed wrong test packages and scope, added zip tests; 2021-09-29 16:01:36 +04:00
Oleg Agafonov
8418c6a09a AI: game logs improved (docs/wiki, added diff score per command and commands chain) 2021-09-26 18:43:57 +04:00
Oleg Agafonov
42325c7c2e AI improves:
* AI: fixed that AI was able to targeting an invalid player targets in some use cases (#5630);
* AI: fixed that AI was able to ignore targeted triggers in some use cases;
* AI: improved player targeting for not own chooses (if it's make a choice for another player);
2021-09-26 18:40:26 +04:00
Evan Kranzler
b895611c4d
Updating standard (don't merge until 9/24) (#8297)
* removed rotated cards from standard ban list

* updated standard legality to handle sets releasing after fall set inn the same year

* some more updates to standard

* small change
2021-09-24 22:07:12 -04:00
Oleg Agafonov
6bc5a00e8a * Alternative costs - fixed that it can be activated on free cast (example: cascade with overload, #6925, #7410, #7741, #6342); 2021-09-21 14:22:46 +04:00
Jeff Wadsworth
77845bd1df Fixed #8286. 2021-09-20 15:54:52 -05:00
Grath
1b27fdd6ba
Update Commander banned list 2021-09-13 12:23:16 -04:00
spjspj
5bbcf03cb6 EDH Power level update (based on Saltiest EDHREC survey). Update for Full Art Face art. 2021-09-11 23:32:34 +10:00
Oleg Agafonov
912e695f40 * GUI: fixed that some choose dialogs doesn't show possible targets (example: Haunting Voyage, #8223); 2021-09-05 13:07:13 +04:00
Oleg Agafonov
261f32d9b9 Fixed wrong targetId in CAST_SPELL, fixed miss code from 7b7bbcadd69dd717d980e1981031cb29d7c7b891; 2021-09-04 03:01:20 +04:00
Oleg Agafonov
2158d682cc Prepare new release 2021-08-30 14:44:03 +04:00
Oleg Agafonov
2efdb464fc Little refactor, additional logs for CheckPlayableState error; 2021-08-28 12:09:22 +04:00
Evan Kranzler
f8d030bef4
Adding dice rolling trigger/replacement (ready for review) (#7989)
* [AFR] Implemented DiceRolledTriggeredAbility
* [AFR] Implemented Brazen Dwarf
* [AFR] Implemented Feywild Trickster
* [AFC] Implemented Reckless Endeavor
* [AFR] Implemented Pixie Guide
* [AFR] Implemented Critical Hit
* [AFR] Implemented Netherese Puzzle Ward
* [AFC] Implemented Neverwinter Hydra
* [AFR] Implemented Farideh, Devil's Chosen
* [AFR] Implemented Barbarian Class
* [AFC] Implemented Vrondiss, Rage of Ancients
* [AFC] Implemented Arcane Endeavor
* Test framework: added planar die rolls support
* Test framework: added random results set up support in AI simulated games;
* AI: improved roll die results chooses in computer games;
* Roll die: improved combo support for planar die and roll die effects;

Co-authored-by: Daniel Bomar <dbdaniel42@gmail.com>
Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2021-08-26 14:06:10 +04:00
Oleg Agafonov
14838e670a Merge fix 2021-08-21 17:55:44 +04:00
Oleg Agafonov
e25d287864 Test framework: added test fails on errors in AI's simulated games; 2021-08-21 17:22:06 +04:00
Oleg Agafonov
7dcdc12c0f * Target permanent or suspended card - added AI support, fixed rollback errors in AI games (example: Shivan Sand-Mage, see #7896); 2021-08-21 17:19:45 +04:00
Oleg Agafonov
9fa487e60a * Suspend ability - fixed that suspend can be activated from opponent's hand; 2021-08-20 15:40:42 +04:00
Oleg Agafonov
43bdab8636 * GUI: added yes/no auto-answers for state base actions dialogs (example: commander change zone); 2021-08-16 02:00:53 +04:00
Oleg Agafonov
1664ee01cf Fixed miss copy code in Game object (lki, cards), removed unused code. Possible fixes:
* simulated games was able to change objects from another games (ConcurrentModificationException, related to d202278ccd, details in 3a6cdd2615);
* AI: fixed cards disappear in multiplayer games with computer (details in #6738);
2021-08-12 00:08:08 +04:00
Oleg Agafonov
b8a83bbdcb * Game: added new draft cube MTGO Legacy Cube 2021 May; 2021-08-10 12:42:53 +04:00
Oleg Agafonov
c9ab896d24 * GUI: added auto-choose for replacement effects (remember answer in dialog + reset answer in popup menu + new option in preferences; #4360, #328, #4219, #6676, #7914); 2021-08-09 11:26:11 +04:00
Oleg Agafonov
649db04030 * Game: added new cube MTGO Vintage Cube July 2021; 2021-08-06 22:57:41 +04:00
Evan Kranzler
f5687acfad [J21] Implemented Faceless Agent 2021-08-06 08:52:31 -04:00
Evan Kranzler
cdfe8be5fc updated duel commander ban list 2021-07-27 19:40:48 -04:00
Oleg Agafonov
c6a3d5e588 Prepare new release 2021-07-25 01:15:33 +04:00
Oleg Agafonov
ac8d3de474 * Game: tiny leaders game mode improves (fixed AI games errors, fixed commander dupes on game restart with Karn Liberated, #6113); 2021-07-24 14:32:00 +04:00
Oleg Agafonov
c1db466d05 AI: fixed computer's errors if all players quit the game; 2021-07-24 05:52:02 +04:00
Evan Kranzler
ad00f0dd3b updated historic ban list 2021-07-21 11:12:19 -04:00
Grath
7069ca7ecb
Update Commander ban list (#8004)
Hullbreacher was banned: https://mtgcommander.net/index.php/2021/07/12/july-2021-update/
2021-07-12 18:00:38 -04:00
Evan Kranzler
572104b8fc
Reworking card types in preparation for implementing Grist, the Hunger Tide (#7899)
Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2021-07-09 07:28:43 +04:00
Oleg Agafonov
b929b28e43 * AI: fixed game freezes with Karn Liberated in the game (#7922); 2021-07-02 15:03:06 +04:00
Oleg Agafonov
62d6675be6 AI: fixed that computer can't play commanders (#7955); 2021-07-01 18:21:15 +04:00
Evan Kranzler
2ab78b9f03 [STX] fixed Shadrix Silverquill not allowing players to choose no modes (fixes #7874) 2021-06-27 11:46:36 -04:00
spjspj
fe96a2de12 Fix broken condition for freeform commander (can be any creature or any Legendary card) 2021-06-22 00:00:38 +10:00
Evan Kranzler
f771dcdb24 updated historic ban list 2021-06-11 06:48:53 -04:00
Evan Kranzler
4ea8b95654 [HA5] added set 2021-06-11 06:48:20 -04:00
Evan Kranzler
d7960837a6 updated Historic ban list 2021-05-19 20:07:59 -04:00
gleeb
6d11b7f3e8 Add Rich Man Swiss Draft 2021-05-06 00:13:20 -07:00
Evan Kranzler
a61d5543fa replaced all instances of converted mana cost with mana value 2021-04-17 17:02:27 -04:00
Daniel Bomar
600cac6fc7
[READY FOR REVIEW] Implement a "multi-amount" dialog (#7528)
* Implemented chooseTargetAmount and new GUI dialog (distribute damage, distribute mana)
* Added tests and AI support;
* Test framework: added aliases support in TargetAmount dialogs;

Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2021-04-17 14:28:01 +04:00
Oleg Agafonov
05b1366c39 Fixed missing override, restored and additional comments 2021-04-02 11:43:42 +04:00
Evan Kranzler
6c54dde7d2 updated Duel Commander ban list 2021-03-29 18:27:21 -04:00
Evan Kranzler
51d7aac6ab updated historic legality and ban list 2021-03-27 07:06:12 -04:00
Evan Kranzler
4874ad31c1 [IKO] added workaround for Yorion, Sky Nomad not being usable in a two player match with limited set as deck type 2021-03-14 19:05:25 -04:00
Oleg Agafonov
2906f86324 Test framework: simplified AI logic and tests, added usage comments. Devs recommendations:
* in card's code use player.isComputer instead player.isHuman (it help to split Human/AI logic and test both by unit tests);
* usage example: AI hint to skip or auto-calculate choices instead call of real choose dialogs;
* unit tests for Human logic: call normal commands;
* unit tests for AI logic: call aiXXX commands;
2021-03-07 23:38:10 +04:00
Oleg Agafonov
dda69cd009 * AI: improved support of "as though mana" abilities (now computer can choose correct mana ability to pay, example: Draugr Necromancer);
* Dev: added card's LKI support of multi part cards (mdf/split/adventure);
* Dev: improved support of adding/removing counters from mdf cards;
* Draugr Necromancer - fixed support of mdf/split/adventure cards (#7620);
2021-02-27 20:14:12 +04:00
Oleg Agafonov
39f6b69391
Merge pull request #7584 from weirddan455/cascade
Implemented updated Cascade ruling 702.84a
2021-02-22 23:03:56 +01:00
Oleg Agafonov
91f4d78992 Changes related to Cascade ability (#7583):
* Cascade: added correct spell ability choose for forced cast of mdf and adventure cards (can contains one or both sides);
* Cascade: added tests from latest oracle changes;
* AI: improved spell ability choose for forced cast (example: cast target card without mana cost);
* GUI: improved spell ability choose for forced cast (now you can see only castable spells to choose);
* Other: fixed wrong PlayFromNotOwnHandZone in some cards, fixed NPE;
2021-02-23 02:00:38 +04:00
Daniel Bomar
bb0a995541
Tibalt, Cosmic Impostor - fixed that emblem can't cast not owned cards (#7598)
* Fixed ability.canChooseTarget not using correct playerId

* Fixed Necrotic Plague

* Revert "Fixed Necrotic Plague"

This reverts commit 7659039670293ce1ea428dad042511d9d75f9da6.

* Set target controller on Necrotic Plague and add check in canChooseTarget

* Add test for Tibalt + Ephemerate interaction

* Tests improved

Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2021-02-22 23:06:43 +04:00
Oleg Agafonov
650acf9e1e Test framework: fixed support of chooseAbilityForCast for commanders, added destroy target custom effect (#7593); 2021-02-22 16:05:48 +04:00
Oleg Agafonov
b6cb5cef9c Refactor: removed default comment headers 2021-02-21 08:15:16 +04:00
Evan Kranzler
25f234cbcc updated ban lists 2021-02-15 10:42:49 -05:00
Oleg Agafonov
eb64a7bb73 GUI: fixed broken add lands and random deck dialogs in deck editor (#7562); 2021-02-13 20:26:06 +04:00
Oleg Agafonov
10e557b873 * Performance: memory usage optimization for deck editor (part 2 of removed bloated usage of ManaCosts -> ManaColor objects, see #7515); 2021-02-12 22:12:18 +04:00
Oleg Agafonov
cf216c6802 Prepare new release 2021-02-07 22:24:40 +04:00
Oleg Agafonov
b2593fd818 Server: fixed jumpstart custom config; 2021-02-07 04:43:18 +04:00
Oleg Agafonov
f692a1f097 * Choice of Damnations - improved AI support, fixed rollback error in AI games;
* Pain's Reward - improved AI support, fixed rollback error in AI games;
* Volcano Hellion - improved AI support, fixed rollback error in AI games;
2021-02-06 12:48:53 +04:00
spjspj
7d267061d9
Merge pull request #7499 from spjspj/master
Adding in Jumpstart Elimination Custom Tournament option.  Creator of the table will be able to upload a Jumpstart Pack text file that uses the same format as here: https://github.com/magefree/mage/blob/master/Mage/src/main/resources/jumpstart/jumpstart.txt
2021-02-06 00:57:25 +11:00
Oleg Agafonov
dc0a29007c Commanders improves:
* [KHM] fixed that some effects can't find mdf commanders on battlefield (example: Fierce Guardianship, #7504);
* Oathbreaker: fixed that some cards that refer to commander can affects signature spells too;
2021-02-05 17:19:30 +04:00
Evan Kranzler
bc99de1a48 [KHM] fixed Frostpyre Arcanist being used incorrectly by AI (#7488) 2021-02-04 10:50:10 -05:00
spjspj
1e428105d5 Adding in Jumpstart Custom 2021-02-04 23:55:59 +11:00
Oleg Agafonov
5077a82585 * GUI: improved ability picker dialog for double sides, split and adventure cards (if one side is playable then you can see ability name before play/cast it, see #7361); 2021-02-03 08:52:31 +04:00
Evan Kranzler
144e2e933a updated Aus Highlander points list 2021-02-02 08:50:34 -05:00
Oleg Agafonov
ebbff82f82
Merge pull request #7335 from ddzn/feature/eurolanderDecks
Add new deck type European Highlander
2021-01-31 20:06:00 +01:00
Evan Kranzler
dacf30f4b9
Refactoring subtypes to make Maskwood Nexus work (ready for review) (#7432)
* removed and renamed SubTypeList

* updated subtype test

* refactored Changeling to be an ability that actually does something

* moved isAllCreatureTypes into SubTypes class

* renamed copyTo method to copyFrom

* added removeAllCreatureTypes where usable

* replaced some subtype methods

* replaced some more subtype methods

* replaced subtype mass add/remove methods

* updated more subtype methods

* fixed some errors

* made common shared creature type predicate

* refactored another card involving subtypes

* Added usage of object attribute in subTypes's write operations;

* Refactor: use same param styles in subtype methods

* Refactor: simplified usage of copy appliers;

* Refactor: fixed code usage in CopyApplier

Co-authored-by: Oleg Agafonov <jaydi85@gmail.com>
2021-01-26 08:52:35 -05:00
Oleg Agafonov
05f8311364 Game: fixed wrong card names in some cubes; 2021-01-23 07:18:12 +04:00
Jeff
9742a673f6 - clear the two attackers lists in AI attack code 2021-01-10 11:43:00 -06:00
jeffwadsworth
4aa1e726c9 - Refactor AI attacking code to include Planeswalkers. 2021-01-08 14:41:00 -06:00
ddzn
dd8e489fcb Add new deck type European Highlander 2021-01-07 13:31:08 +01:00
jeffwadsworth
aa6abe3045 - Revert AI planeswalker attack commit. 2021-01-06 17:04:43 -06:00
Jeff
a7e1c50122 - AI will now attack a Planeswalker first 2021-01-05 21:43:46 -06:00
Oleg Agafonov
767644f1c8 GUI: fixed that user can target/click on second side of mdf card instead the main side (related to #7297); 2020-12-27 01:39:18 +04:00
Oleg Agafonov
64e948e4b3 * AI: improved game performance by x10 for cards with target amount;
AI: added targeting name and amount info to simulation logs;
AI: removed duplicated target variations from target amount simulations;
2020-12-24 15:02:28 +04:00
LevelX2
aebf8b461f Updated Historic format to also work if only the client (not connected to a server) deck editor is started. 2020-12-23 18:03:32 +01:00
LevelX2
2daa5aae50 * Fixed that AI fired targeting event twice (fixes #7094). 2020-12-23 15:53:55 +01:00
Oleg Agafonov
255c292104 * Deals damage divided as you choose - fixed that some cards can't choose planeswalkers (example: Arc Lightning, see #7276);
Refactor: simplified FilterCreaturePlayerOrPlaneswalker to use single permanent filter;
2020-12-23 02:31:41 +04:00