Commit Graph

2432 Commits

Author SHA1 Message Date
Hanmac
20eba0fbd7 GameAction: add PlayerController:confirmMulliganScry 2019-01-13 22:01:22 +01:00
Peter F. Patel-Schneider
087495f5a0 Force AI to accept mulligan scry (otherwise there is a crash) 2019-01-13 10:24:40 -05:00
Hans Mackowiak
2640a509f9 Sunburst: rewrite using ETB counter 2019-01-13 14:10:44 +00:00
Michael Kamensky
7d0dbff8bc Merge branch 'master' into 'master'
Select cards from any Zone that can be shown and do arrangeForScry by popping up library and moving cards (in desktop GUI); Pass min/max card selections through to GUI

See merge request core-developers/forge!1260
2019-01-11 17:08:50 +00:00
Peter F. Patel-Schneider
69502dd97b Pass min/max through choice code so that user can't choose too many cards 2019-01-06 12:07:19 -05:00
Hanmac
4168ef0b0d Morph and Manifest are not to facedown anymore 2018-12-29 15:45:20 +01:00
Agetian
d4476cbd2b - Eliminated a redundant call to canPlay (already tested above). 2018-12-27 13:17:49 +03:00
Agetian
23d67ab0cf - Fixed the AI misplaying with Chamber Sentry. 2018-12-27 08:21:28 +03:00
Hans Mackowiak
af38b9b0e4 Update Trigger ChangesZoneAll
CardZoneTable: for Origin + Destination => CardCollection Tables

GameAction: Refactor

HumanPlay: use executePayment List if able
2018-12-25 18:13:44 +01:00
Agetian
660887794b - AI: Always prefer cheaper Spectacle costs (maybe a better way is possible?)
- AI: Prefer cheaper alternative mana costs in general (e.g. Omniscience).
2018-12-23 18:47:38 +01:00
Hanmac
de2c0aa073 Graft: moved AIGraftPreference 2018-12-23 18:47:38 +01:00
Hanmac
59e3995bae more AI for Counter Remove 2018-12-23 18:47:37 +01:00
Agetian
0123ba7819 - CountersRemoveAi: try to target Adapt creatures when removing +1/+1 counters mandatorily. 2018-12-23 18:47:37 +01:00
Agetian
2a02fd124e - Some work on the AI for new keywords.
- NPE prevention in AI code.
2018-12-23 18:47:37 +01:00
Hanmac
b87f247c09 Keyword: add Riot 2018-12-23 18:47:37 +01:00
Hanmac
dd759352de Keyword: add Adapt 2018-12-23 18:47:37 +01:00
Hans Mackowiak
9b991635fb Sentry exception rework 2018-12-23 17:46:57 +00:00
Agetian
767e13c547 - NPE guard. 2018-12-16 09:50:18 +03:00
Agetian
81c76952ea - Code cleanup. 2018-12-16 09:43:52 +03:00
Agetian
14799ccd62 - Complete the basic implementation of AI optional cost choice, remove getOptionalCosts. 2018-12-16 09:11:54 +03:00
Agetian
7a53a0fb36 - Improve implementation for Entwine AI.
- Fixed an issue which made the SpellAbilityAi#isSorcerySpeed not to work correctly when checking from subabilities.
2018-12-15 22:08:16 +03:00
Agetian
0628ebcb54 - First steps in figuring out the infrastructure for AI chooseOptionalCosts and implementing Entwine. 2018-12-15 20:43:57 +03:00
Agetian
498f7325c9 - Fix the AI logic for Expansion // Explosion (casting for 0, underdrawing). 2018-12-15 11:58:43 +03:00
Agetian
f2e9d5913e - Default settings for holding back X damage spells. 2018-12-15 10:01:29 +03:00
Agetian
c6515bdf4a - Some tweaks to damage chaining.
- Improved Narset Transcendent AI logic for -2.
2018-12-15 09:58:02 +03:00
Agetian
f9cd173405 - Prevent the AI from relying on the ability to play a spell with an optional cost when deciding to do an assault attack with possible non-combat damage (prevents certain silly suicidal chump-attacks) 2018-12-15 09:10:55 +03:00
Agetian
5ff5ce0556 - PumpAI should account for spending a card cast from hand when counting P/T (fixes Inner Calm, Outer Strength AI assumptions). 2018-12-14 13:51:55 +03:00
Agetian
091fe36b2b - Basic logic to try not to be very wasteful with X-based direct damage spells (and the AI properties for it). Currently in Experimental profile. 2018-12-14 13:51:23 +03:00
Agetian
5b7f184053 - A sturdier logic for Doublecast-like card AI. 2018-12-14 08:55:50 +03:00
Agetian
ad5ece5242 - Code simplification/cleanup. 2018-12-13 22:09:46 +03:00
Agetian
7fd2a5fa04 - Code cleanup. 2018-12-13 22:02:17 +03:00
Agetian
36154db24d - A more reliable check for Valid Targeting in damage chaining. 2018-12-13 21:57:01 +03:00
Agetian
3896a79cfa - Improve damage chaining so that the AI doesn't try to chain a spell with restricted targeting to a general use spell (e.g. a spell that targets only attacking creatures to a Lightning Strike outside of combat). 2018-12-13 20:08:01 +03:00
Agetian
f09ec13428 - Restore the "move equipment" functionality for the AI 2018-12-12 21:54:14 +03:00
Agetian
f45bccf71d - chainDmg not null is already ensured on top 2018-12-12 20:40:26 +03:00
Agetian
adec6c720f - Removed a superfluous isAI check, handled inside getDamagingSAToChain (one more). 2018-12-12 20:39:49 +03:00
Agetian
9bcdfad726 - Removed a superfluous isAI check, handled inside getDamagingSAToChain. 2018-12-12 20:37:25 +03:00
Agetian
b718365a39 - getDamagingSAToChain should only work for actual AI players, not when simulating human decisions. 2018-12-12 19:42:28 +03:00
Agetian
7a7b461e0d - Set the damage chaining defaults for the AI profiles. 2018-12-12 14:41:39 +03:00
Agetian
7b6ad78ba2 - Don't use damage chaining for simulated AI. 2018-12-12 12:43:21 +03:00
Agetian
709e04d9ad - Don't try to chain a pump spell to a damage spell targeting a player. 2018-12-12 10:08:00 +03:00
Agetian
4cbb50483a - Renamed a method. 2018-12-12 09:04:46 +03:00
Agetian
1b6b7f8af4 - Move chainDmg closer to where it's used, avoid calling it when not planning to cast the spell for other reasons. 2018-12-12 09:03:41 +03:00
Agetian
3b5015e9b6 - Moved the chain SA prediction routine to DamageDealAi, where it belongs more. 2018-12-12 08:57:23 +03:00
Agetian
789f9eecb4 - Maximize the chance to chain spells to kill threats when in danger (unless the option is disabled). 2018-12-12 08:54:31 +03:00
Agetian
95db50f07b - Renamed a few things for clarity. 2018-12-12 08:47:36 +03:00
Agetian
602226f416 - Removed a commented out line (mana is reserved elsewhere). 2018-12-12 08:14:41 +03:00
Agetian
0c5e5288b8 - Tweaking a method name. 2018-12-12 08:14:41 +03:00
Agetian
96f941aeae - Added an experimental AI property controlling damage chaining. 2018-12-12 08:14:41 +03:00
Agetian
c79ed8b609 - Basic implementation for chaining two damage spells, supports damage+damage or damage+debuff. 2018-12-12 08:14:41 +03:00