mirror of
https://github.com/magefree/mage.git
synced 2025-12-25 04:52:07 -08:00
AI fixes:
* Gain control abilities - fixed wrong target chooses by AI (selects weakest permanent instead most powerful); * Target of an opponent’s choice abilities - fixed that AI was able to cancel card cast, fixed wrong target chooses (Evangelize, Echo Chamber, Arena, Preacher, etc);
This commit is contained in:
parent
bcb37992cc
commit
bb59cedbd9
12 changed files with 137 additions and 93 deletions
|
|
@ -2512,16 +2512,10 @@ public class ComputerPlayer extends PlayerImpl implements Player {
|
|||
goodList.sort(comparator);
|
||||
badList.sort(comparator);
|
||||
|
||||
// real sort
|
||||
if (outcome.isGood()) {
|
||||
// good effect -- most valueable goes first
|
||||
Collections.reverse(goodList);
|
||||
// Collections.reverse(badList);
|
||||
} else {
|
||||
// bad effect - most weakest goes first, no need in reverse
|
||||
// Collections.reverse(goodList);
|
||||
Collections.reverse(badList);
|
||||
}
|
||||
// most valueable goes first in good list
|
||||
Collections.reverse(goodList);
|
||||
// most weakest goes first in bad list (no need to reverse)
|
||||
//Collections.reverse(badList);
|
||||
|
||||
allList.addAll(goodList);
|
||||
allList.addAll(badList);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue