AI: fixed that computer can cheat with target selection and choose 1 creature instead multiple required (example: sacrifice, close #13219)

This commit is contained in:
Oleg Agafonov 2025-01-12 14:46:16 +04:00
parent 1f1d1088a1
commit 39872e2625
2 changed files with 99 additions and 1 deletions

View file

@ -204,7 +204,9 @@ public class ComputerPlayer extends PlayerImpl {
for (Permanent permanent : targets) {
if (origTarget.canTarget(abilityControllerId, permanent.getId(), source, game, false) && !target.getTargets().contains(permanent.getId())) {
target.add(permanent.getId(), game);
return true;
if (target.isChosen(game)) {
return true;
}
}
}
return false;