Commit Graph

31762 Commits

Author SHA1 Message Date
Agetian
643d2a0170 - Corrected a typo in Shrine of the Forsaken Gods. 2017-01-02 04:57:39 +00:00
Agetian
c838b46c17 - Fixed Mesmeric Sliver. 2017-01-02 04:55:49 +00:00
Sol
9eeb7cdb11 Add Ludevic Necro-Alchemist (C16) 2017-01-02 02:52:55 +00:00
Myrd
d45da5f3db [Simulated AI] Move out anon class to make the code more readable. 2017-01-02 00:53:21 +00:00
Myrd
7f068eb87a [Simulated AI] Refactor SpellAbilityChoicesIterator to its own class. 2017-01-02 00:46:37 +00:00
Myrd
0c6a7bbd18 [Simulated AI] Support modal spells where allowRepeat is true. (e.g. C15 confluence cycle) 2017-01-02 00:29:56 +00:00
Sol
939a1b4a53 Add Kynaios and Tiro of Meletis (C16) 2017-01-01 20:27:48 +00:00
Agetian
798cc430b7 - Removed unused imports. 2017-01-01 20:16:04 +00:00
Agetian
699a0b95bc - File correction. 2017-01-01 20:14:58 +00:00
Agetian
cc3a587e42 - Implemented biasing random (simulated) AI vs AI matches towards decks with higher draft rank value.
- Better name for the random decision simulation option.
2017-01-01 20:14:13 +00:00
Hanmac
56cf064e0b fixed Identity Thief 2017-01-01 19:26:08 +00:00
Agetian
98a05bb353 - Added comment to Rhys the Exiled script (for AIPreference SVar). 2017-01-01 17:27:03 +00:00
Agetian
bb8b0d3e4e - Fixed StackOverflowError on Rhys the Exiled when blocking tramplers by adding an explicit AI preference for SacCost. 2017-01-01 16:45:01 +00:00
Agetian
ac2881cc6c - Added a new quest preference "Do Not Play AI Matches" which allows the player to decide the outcome of AI vs. AI matches randomly instead of playing them out and thus simulating them. This is disabled by default, set to "1" to enable.
- Currently determines the outcome of all AI vs. AI matches in a 50-50 fashion. Might be upgraded later to bias the outcome towards a stronger deck judging by the total card draft rating value.
2017-01-01 16:06:28 +00:00
Hanmac
163cb460ab GameEntity moved addCombatDamage from the other classes there. Also add a more generic AddDamage version 2017-01-01 13:47:22 +00:00
Agetian
46a76ce69b - Do not generate quest booster drafts for sets that do not have a booster template available for them and will thus crash. 2017-01-01 10:30:57 +00:00
Agetian
beadf13c30 - Added a TODO entry for now. 2017-01-01 09:01:58 +00:00
Agetian
3a285fcd92 - Reverting r32912 for now, more investigation needed. 2017-01-01 08:29:35 +00:00
Agetian
7797224826 - Simpler solution for Boonweaver Giant + Animate Dead 2017-01-01 08:13:38 +00:00
Agetian
451db2a5db - Removed unused import. 2017-01-01 07:18:22 +00:00
Agetian
8d2cf088a0 - Attempting to fix interaction of Boonweaver Giant with cards that can't legally target it (e.g. Animate Dead) such that those auras trying to enchant the creature do not move (per 303.4i/303.4j) and other similar interactions. 2017-01-01 07:17:48 +00:00
Agetian
e251f88b2f - Fixed Saffi Eriksdotter 2017-01-01 06:56:24 +00:00
Sol
544f72b02d Add Yidris, Maelstrom Wielder (C16) 2016-12-31 19:34:26 +00:00
Myrd
51af35db2e [Simulated AI] Remove SIMULATE_LAND_PLAYS constant since it's enabled by default now. 2016-12-31 18:38:52 +00:00
Myrd
52711b7b33 [Simulated AI] Make game copier copy player mana pools along with a test. 2016-12-31 18:07:36 +00:00
Agetian
4d5fae1c6f - Only add avatars to decks if the Vanguard or Momir Basic variant is applied. 2016-12-31 10:58:29 +00:00
Agetian
f105b3f1c1 - Allow the player to draw cards before the game starts (drawing the initial hand, drawing a new hand after a mulligan), fixes Maralen of the Mornsong Avatar. 2016-12-31 10:55:13 +00:00
Agetian
95ec8b63fa - Do not clear out deck Vanguard avatar on subsequent calls to selectVanguardAvatar (fixes Default Avatar not working).
- Note that Vanguard selection is still partly broken (for desktop Forge), it's impossible to select a particular avatar for each player (the avatar always ends up being the same), fix is welcome.
2016-12-31 10:41:23 +00:00
Agetian
787c8decb7 - Reverting the StaticAbility change for now (PlayerTurn can be used as a type of Defined parameter to define whose turn it should be when the static ability is applied again). 2016-12-31 06:37:05 +00:00
Agetian
cf2b947988 - Updated Gisa and Geralf and Karador, Ghost Chieftain to use Condition$ PlayerTurn 2016-12-31 06:36:20 +00:00
Agetian
fd883c8190 - getDefinedPlayers should use the "Defined" parameter to look for the definition of whose turn it should be, True == You (fixes Gisa and Geralf). 2016-12-31 06:19:02 +00:00
Agetian
8aa946bf86 - Reverting substandard syntax in Gisa and Geralf. 2016-12-31 06:18:29 +00:00
Agetian
3d4f3c1d8a - Updated Gisa and Geralf. 2016-12-31 06:14:19 +00:00
Agetian
ad838df531 - Fixed Elvish Pathcutter. 2016-12-31 04:32:31 +00:00
Sol
6e6dc53927 - Add Treacherous Terrain (C16) 2016-12-31 00:59:28 +00:00
Sol
243c081da7 - Migrate upcoming C16 cards to their normal card folders 2016-12-30 21:58:41 +00:00
Myrd
5046c00566 One more fix for the TrackableTypes changes. 2016-12-30 19:57:31 +00:00
Myrd
a14a370107 Fix NPE from my previous change to TrackableTypes. 2016-12-30 19:43:40 +00:00
Myrd
18ba55ae27 Attempt to fix memory leak with TrackableTypes.
The problem was that TrackableTypes were all global (held in static variables), but kept around state (objLookup maps) that shouldn't be global - e.g. that could contain per game data. Additionally, it seems this state wasn't always getting cleared correctly and thus would cause leaking of memory over multiple games - which would especially be a problem for Simulated AI code which created temporary games for simulation.

This change attempts to fix the issue by moving the storage of objLookup maps to the Tracker object, which corresponds to a single Game. This way, there is no cross-contamination between different games and the state is properly cleaned up when a Game goes away.
2016-12-30 19:34:07 +00:00
Myrd
6f0eda7509 [Simulated AI] Fix inverted logic I accidentally landed earlier. 2016-12-30 18:10:19 +00:00
Myrd
a2e2753429 [Simulated AI] Fix energy counters propagation with a test. 2016-12-30 18:03:58 +00:00
Myrd
ce4ef7a4d7 [Simulated AI] More safety guards around executing a planned decision.
This keeps the index and list size of the available decisions as part of the plan, to be compared with when following through with the plan. Among other things, this ensures that the correct SA is chosen from the list when there are multiple similar SAs (e.g. correctly crewing the 2nd Smuggler's Copter).
2016-12-30 17:50:47 +00:00
Myrd
6ac9182701 [Simulated AI] Fix a NPE in target caching code. 2016-12-30 17:21:51 +00:00
Myrd
503ee37c8a [Simulated AI] Make a SpellAbilityRef helper class.
I plan to expand it in the future, but for now this doesn't introduce any functional changes.
2016-12-30 17:08:34 +00:00
Hanmac
e5dc653b4c GameSimulatorTest: add Testcases for Damage with Lifelink 2016-12-30 15:02:04 +00:00
Hanmac
36dbda7b86 cards: use new DamageLifeThreshold keyword for Worship effect 2016-12-30 14:58:46 +00:00
Hanmac
e1ddd0fc5f Stuffy Doll Avatar is a PreventionEffect 2016-12-30 14:57:23 +00:00
Hanmac
99d2afc748 update Blizzard Specter using new Charm description 2016-12-30 14:56:49 +00:00
Hanmac
2c4c749207 cards: update cards with ReplaceEffect 2016-12-30 14:54:10 +00:00
Hanmac
1738f49798 Big Damage Rewrite Part 2: now use CombatDamageMap everywhere 2016-12-30 14:50:45 +00:00