Commit Graph

1413 Commits

Author SHA1 Message Date
Agetian
70ffd72556 - A little logic addition. 2017-01-12 17:55:24 +00:00
Agetian
01bcff9a5e - Better logic for Desecration Demon: only sac creatures to it if in critical condition to lose to it and have no active flying/reach blockers that are useful. 2017-01-12 17:54:18 +00:00
Agetian
dfc5fad357 - Some additions to the response sac AI (take persist and undying into account).
- Added some sacrifice prioritizing to Desecration Demon (but still not sure what is best - let the AI deal with a persistent 6/6 flyer or risk pumping it up a bit but keep it in check for a while in presence of several weak creatures, could use improvement).
2017-01-12 17:04:33 +00:00
Agetian
ecf6a38f4f - Moved a comment. 2017-01-12 12:23:47 +00:00
Agetian
196f939eef - Consolidated AIPreferenceParams into a single property, somewhat cleaner and also not so clunky in code. 2017-01-12 12:23:02 +00:00
Agetian
f4dcd7b742 - Adding options to control the AIPreference for creatures based on the AI evaluation level and, if need be, the minimum number of creatures below a certain eval threshold needed to activate a SacCost.
- Adding these options to Prowling Pangolin, along with AIPreference token->creature, to make the AI be more willing to sacrifice weak and useless creatures in response to Prowling Pangolin to counter it.
2017-01-12 11:26:37 +00:00
Agetian
bb7dc5356c - A little update to isUselessCreature. 2017-01-12 07:19:44 +00:00
Agetian
d61fb2a114 - Minor improvements to Necro AI in SpecialCardAi. 2017-01-12 06:17:35 +00:00
Agetian
3315174bfc - MillAi: only use creatures with a tap mill ability during the opponent's end step to also have a chance to use them in combat. 2017-01-12 06:17:17 +00:00
Agetian
b6f6beb2e5 - Moved isUselessCreature to ComputerUtilCard (since it's not Spell Ability AI-related). 2017-01-12 06:01:54 +00:00
Agetian
11796c18b5 - Some more cleanup in SpecialCardAi. 2017-01-11 05:05:20 +00:00
Agetian
3010b7f578 - Imports cleanup. 2017-01-11 05:01:30 +00:00
Agetian
a243e5b201 - Change getOpponent->getOpponents in SpecialCardAi. 2017-01-11 05:01:07 +00:00
Agetian
6902491797 - Added AI for Living Death. Marked Living Death as RemRandomDeck instead of RemAIDeck. AILogic$ LivingDeath can probably be used for other similar cards too, possibly with some adaptation. 2017-01-10 19:17:19 +00:00
Agetian
0a70660ef9 - For now, set up a temporary measure to prevent the AI from abusing the bug with activating Qasali Ambusher from graveyard and possibly other zones for its "ambush" ability (e.g. noticeable when the AI plays Catwoman quest opponent)
- Unfortunately, couldn't find a way to fix this in the MayPlay code without breaking more things, please feel free to update the necessary code when/if possible. For the time being, marked this as a known issue in the card script and CHANGES.txt.
2017-01-10 11:33:42 +00:00
Agetian
5c56eadfd1 - A better location for ControlGainAi fix. 2017-01-10 05:40:04 +00:00
Agetian
c3996d8d4a - Fixed ControlGainAi logic with Defined. 2017-01-10 05:34:05 +00:00
Sol
e3c4386473 - Add Improvise keyword handling first pass 2017-01-10 02:10:32 +00:00
Agetian
e9d81a93b9 - Moved Ugin, the Spirit Dragon hardcoded Planeswalker ability priority handling to SpecialCardAi. 2017-01-09 05:26:44 +00:00
Myrd
3488c9423f [Simulated AI] Support multiple choices from an SA and plumb cost decision choices into simulation AI.
With these changes, both decisions for Crop Rotation (what to sac and what to search for) are taken into account. Also adds a test.
2017-01-09 03:56:47 +00:00
Myrd
ec825413ff [Simulated AI] Print chosen card. 2017-01-09 01:35:20 +00:00
Myrd
fb1ec29141 Add a TODO to modes iterator in simulated AI. 2017-01-08 23:01:52 +00:00
Myrd
88634bb0a0 [Simulated AI] Add support for cards that need multiple targets.
Note: Currently, no special optimizations are made to try to prune decision trees for these, even though they definitely can result in a lot of choices and really slow simulation AI performance.
2017-01-08 21:02:24 +00:00
Hanmac
8849c7d031 CounterMoveEffect: update Effect for cards using multiple Sources or multiple Targets 2017-01-08 19:26:11 +00:00
Myrd
be5b5ac3d2 [Simulated AI] Add tests for mode choosing logic. 2017-01-08 17:42:57 +00:00
Myrd
add8a1d24e [Simulated AI] Fix printing of target string and check in a change I forgot in last commit. 2017-01-08 17:24:29 +00:00
Agetian
f958ec4cc8 - Removed unused import. 2017-01-08 07:44:55 +00:00
Agetian
8dd22c5465 - Moved Chain of Smog logic to SpecialCardAi. 2017-01-08 07:44:05 +00:00
Agetian
5e879b0301 - Added a comment to ChangeZoneAllAi. 2017-01-07 17:29:07 +00:00
Agetian
30e4fbdc74 - Added rudimentary AI logic for Timetwister and promoted it to AI playable.
- This completes the project to get the basic AI logic for the remaining Power Nine cards.
2017-01-07 17:27:23 +00:00
Agetian
7d6b639ed6 - Added a comment back. 2017-01-07 16:52:33 +00:00
Agetian
9aa2fba98e - Removed old version of the code I forgot to take out. 2017-01-07 16:50:47 +00:00
Agetian
922e82e03f - Added rudimentary AI logic for Black Lotus and Lotus Bloom. Promoted both to AI playable. 2017-01-07 16:50:15 +00:00
Agetian
75ae31c071 - A less confusing parameter name for AI PayLife threshold. 2017-01-07 15:16:39 +00:00
Agetian
b3a8fcf7cb - Corrected a couple mistypes. 2017-01-07 14:55:51 +00:00
Agetian
bd0e4fb2bc - Refactored the card-specific AIs implemented so far to its own class SpecialCardAi, will consider moving other card-specific hardcoded logic there later.
- Implemented rudimentary AI logic for Necropotence and Yawgmoth's Bargain, could use improvement but should be fine in typical situations.
- Promoted Necropotence and Yawgmoth's Bargain from RemAIDeck to RemRandomDeck.
- Propagated the SA parameter to checkLifeCost (and closed the previous TODO associated with that), was also necessary to support the Necro AI logic.
2017-01-07 14:11:57 +00:00
Hanmac
fa0b0277e6 PumpAi: refactor it to use better logic for MoveCounter (not complete yet) also refactor Donate Logic to work with multiple Opponents 2017-01-05 19:54:09 +00:00
Agetian
46674dca85 - A generic solution for Donate, now supports potentially donating cards other than Illusions of Grandeur (via SVar DonateMe specifying the donate priority, with 5 being the highest and 1 being the lowest priority). 2017-01-05 19:03:54 +00:00
Agetian
a168875f37 - Added Chain of Smog with basic AI support when the player casts it targeting AI, it will only continue the chain if it ends up having no cards in hand. The AI itself currently does not know when/how to time it properly when casting it from hand (will always cast it), 2017-01-05 16:16:42 +00:00
Agetian
18b465b879 - Removed an unused import. 2017-01-05 14:25:29 +00:00
Agetian
c5d83f177f - Added AI cast preferences to either always cast a card when AI life is under a certain threshold or never to cast it under these circumstances.
- Set Illusions of Grandeur to always be cast if life is at 3 or below (in hope to save the AI's virtual skin via a topdecked/tutor-topdecked/looted Donate).
- Set Bitterblossom to never be cast if life is at 3 or below to avoid dying to it (not sure if maybe it needs to be set higher).
2017-01-05 14:24:58 +00:00
Agetian
880b7664d1 - Somewhat more generic solution for Nykthos, Shrine to Nyx AI. Currently still hard-coded to that card only, but can potentially be reused later for other cards (AILogic is already taken on Nykthos; maybe via a special AI SVar?) 2017-01-05 12:44:09 +00:00
Agetian
b6f21f5492 - More appropriate variable name in ChooseColorAi. 2017-01-05 06:58:59 +00:00
Agetian
1c40bc3215 - A little modification to make the Illusions-Donate AI smarter (currently hardcoded). 2017-01-05 06:04:28 +00:00
Agetian
2853fcc200 - Added AI logic to play a simple Illusions-Donate Trix deck.
- Added a quest opponent The Great and Powerful Trixie 4, a mono blue Trix combo deck with Illusions of Grandeur and Donate and a wide array of permission. It may be a little haphazard and not always very consistent, but it does beat many hard and very hard opponents with a decent chance.
2017-01-04 18:48:56 +00:00
Agetian
70ada910be - Improved mana source detection for Nykthos, Shrine to Nyx AI. 2017-01-04 14:35:18 +00:00
Hanmac
d96a79177b API: add ReplaceSplitDamageEffect its used for Damage splitting like en-Kor 2017-01-03 19:06:48 +00:00
Agetian
e1deb2541d - Removed a debug print line. 2017-01-03 18:48:10 +00:00
Agetian
ba68e337b7 - Added some AI priorities for Cryptic Command to specify a subability that is generally good and a subability that is good under a particular circumstance. Tests show that the AI plays the card rather sensibly with these priorities in mind, on par with other Command cards.
- Marking Cryptic Command as AI playable.
2017-01-03 18:47:34 +00:00
Agetian
a89c37af02 - Removing debug line. 2017-01-03 17:26:15 +00:00