mirror of
https://github.com/magefree/mage.git
synced 2025-12-20 02:30:08 -08:00
AI: improved stability and bug fixes (related to #13290):
- bug's reason: wrong usage of canTarget, add/addTarget, getOpponents, etc; - fixed that it can target dead players in some use cases (close #13507); - fixed that it wrongly choose targets in bad/good effects in some use cases; - fixed that it can't find valid targets in some use cases; - fixed game freezes and errors with some cards;
This commit is contained in:
parent
b915c6590b
commit
3dc606501d
10 changed files with 219 additions and 204 deletions
|
|
@ -391,7 +391,7 @@ public final class SystemUtil {
|
|||
// 3. system commands
|
||||
if (runGroup.isSpecialCommand) {
|
||||
|
||||
Player opponent = game.getPlayer(game.getOpponents(feedbackPlayer.getId()).stream().findFirst().orElse(null));
|
||||
Player opponent = game.getPlayer(game.getOpponents(feedbackPlayer.getId(), true).stream().findFirst().orElse(null));
|
||||
|
||||
String info;
|
||||
switch (runGroup.name) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue