Commit Graph

906 Commits

Author SHA1 Message Date
Sloth
c0f4b6066b - Added AI support for Polymorph and Proteus Staff. 2015-02-28 21:08:55 +00:00
Myrd
3430877613 Fix copying game with permanents changed to creatures in AI simulation. 2015-02-28 15:42:13 +00:00
Chris
d60cafa83c [maven-release-plugin] prepare for next development iteration 2015-02-27 15:29:09 +00:00
Chris
808e56e327 [maven-release-plugin] prepare release forge-1.5.36 2015-02-27 15:29:01 +00:00
excessum
3b114d8c46 - Fixed bug with triggered abilities and useRemovalNow() in DamageDealAi 2015-02-23 12:35:52 +00:00
excessum
e525e017bc - Implemented default choices for Fate Reforged sieges 2015-02-22 02:21:08 +00:00
excessum
7533b1a02b - Implemented AI for Ugin, the Spirit Dragon 2015-02-20 01:57:29 +00:00
excessum
4e37f7b442 - Fixed bug due to free pings in DamageDealAi caused by r28843 2015-02-17 11:55:39 +00:00
elcnesh
4a38b0d817 Huge update to the GUI codebase.
- Make match screen in gui-desktop non-singleton, allowing multiple games to be played simultaneously.
- Separate global gui commands (IGuiBase) from game-specific gui commands (IGuiGame), allowing games to send their commands to the correct gui.
2015-02-17 08:47:55 +00:00
Myrd
4ac5d67a02 Fix game copy error with manifested non-creatures. 2015-02-16 07:43:34 +00:00
Myrd
95f145a1cd Fix NPE in combat code that was caused by AI being confused when planning its blockers (i.e. planning how to block own attackers). 2015-02-16 02:13:03 +00:00
Myrd
3ecb80f8d2 Slightly better fix for make canceling Delve refund exiled cards. I think this fixes a bug in the previous fix where AI would never exile the cards they chose to delve. 2015-02-15 20:41:31 +00:00
Sloth
8bd2c59f27 - Improved AI using Withered Wretch. 2015-02-14 20:29:01 +00:00
Myrd
6af65c0db9 Fix GameCopier to preserve tracking of loyalty ability activations. 2015-02-14 18:56:26 +00:00
Myrd
251b85ac93 Improve some debug printing. 2015-02-14 17:40:08 +00:00
Myrd
4a97f483f8 Set activating player when evaluating mana producing permanent by AI, to avoid warnings being printed. 2015-02-14 16:20:28 +00:00
Myrd
7006d85d25 Fix some problems with recursive simulation and tweak debug output. Also, optimize evaluation in summon sick mode. 2015-02-14 16:13:04 +00:00
Chris
ea6a01b1bc [maven-release-plugin] prepare for next development iteration 2015-02-14 15:42:17 +00:00
Chris
a42465e9ca [maven-release-plugin] prepare release forge-1.5.35 2015-02-14 15:42:09 +00:00
Myrd
ed9bc163cf Optimize replacement effect lookup during AI calculating mana. 2015-02-14 15:06:14 +00:00
excessum
da74a6f70a - Fixed bug with the AI treating spells with DamageDeal SubAbility that can target players as free pings 2015-02-14 11:51:44 +00:00
excessum
8688494718 - Fixed AI for Polukranos, World Eater 2015-02-14 08:08:48 +00:00
Myrd
8aae10fedd Fix Simulation AI not being able to target some permanent types. 2015-02-14 05:59:26 +00:00
excessum
dd28144134 - Fixed AI for Chained to the Rocks 2015-02-14 03:11:12 +00:00
Myrd
b131f59976 Fix NPE with empty stack. 2015-02-13 05:41:40 +00:00
Myrd
cad21523ff Fix index out of bounds with multiple targets. 2015-02-13 05:24:25 +00:00
Myrd
edbbc582c7 Fix game copy error with monstrous with a test. 2015-02-13 05:17:22 +00:00
Myrd
0d748ed593 Don't recurse if the game is already over. 2015-02-13 04:58:13 +00:00
Myrd
2f161224b2 Simulation AI: Implement looking ahead more than one move. This allows, for example, choosing the SpellAbility to use a fetchland to get the right type of mana in order to play another spell in hand, just from simulation.
This is an initial implementation with a max recursion depth of 5.

There are many improvements that can be made - for example to speed it up, by caching the planned SA chain - so that (if things are going to plan), the chain doesn't have to be recomputed each time.

Also, the AI doesn't currently simulated both types of decisions for a fetchland (i.e. evaluate difference between fetching a Plains vs. a Forest) - it picks one arbitrarily, which sometimes causes it to miss better plays. This needs to be fixed.
2015-02-13 04:52:08 +00:00
Myrd
43005bc1e4 Copy cards in command zone too. 2015-02-13 04:15:01 +00:00
Myrd
b138ec3e1d Make CreatureEvaluator implement Function, so that a separate class isn't needed for that. 2015-02-12 05:11:55 +00:00
Myrd
e89324537c Tweak eval scoring for cards in hand and life for Simulated AI. 2015-02-08 20:38:41 +00:00
Myrd
1963cc94ad Fix simulated AI finding wrong card in hand when simulating and add a test. 2015-02-08 20:21:23 +00:00
Myrd
2dc5d6da09 Consider planeswalkers with more loyalty counters better, so that AI will activate Liliana's discard ability even if opponent has no cards in hand. 2015-02-08 20:03:12 +00:00
Myrd
2afff9c9c0 Make game state save/restore also affect command zone. 2015-02-08 19:58:05 +00:00
Myrd
457636f2e3 Make simulated AI ignore temp power/toughness boosts in certain cases when evaluating. (Initial version - can be made quite a bit smarter based on this later.) 2015-02-08 19:43:40 +00:00
Myrd
2766caec2c Fix simulation of unmorph abilities that don't use the stack, with a test.
Also, disables a test that started to fail for some reason. Will investigate why it's failing after this commit.
2015-02-08 18:08:51 +00:00
Myrd
188ff29384 Remove println. 2015-02-08 17:50:15 +00:00
Myrd
ff18cb74c8 Fix dumping and restoring game state with morphed creatures. 2015-02-08 17:43:09 +00:00
Sloth
0ea7e765a0 - Improved DigAI. 2015-02-08 14:02:47 +00:00
Sloth
b5dd19867a - Cleanup and NPE protection. 2015-02-08 13:36:17 +00:00
Myrd
20bd3e3ea9 Fix formatting. 2015-02-07 19:40:20 +00:00
Myrd
8e1feb1dc6 Make a helper class for evaluating a creature, so that it can be more easily customized through subclassing. 2015-02-07 19:39:40 +00:00
Myrd
8a96a479bb - Fix build that I broke.
- Commit some in-progress stack copying code that doesn't work yet (disabled).
- Throw exception when a GameObject couldn't be mapped from the orig game.
2015-02-07 19:18:37 +00:00
Myrd
859a853499 Add a somewhat hidden option in the UI to turn on simulation via a context menu on the AI radio button on desktop.
This allows choosing the AI mode without recompiling and also allows things like making a non-simulation AI play a simulation AI.
2015-02-07 18:32:02 +00:00
Myrd
4e1706ad22 Remove some assumptions about ordering of players in simulation AI code. 2015-02-07 17:54:43 +00:00
Myrd
8141b0edb2 Limit some debug output. 2015-02-07 17:52:45 +00:00
Myrd
9b40f6559b Fix some spammy output that came from my last commit. 2015-02-07 03:13:52 +00:00
Myrd
cfd38b7111 Fix game copy inconsistency with paid echo cost during simulation. 2015-02-07 02:55:48 +00:00
Myrd
62f790e9fe Add code for debugging simulation copy errors. 2015-02-07 02:31:46 +00:00