mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-18 19:58:00 +00:00
- Fixed mandatory targets not being enforced for the human.
This commit is contained in:
@@ -411,13 +411,19 @@ public class TargetSelection {
|
|||||||
|
|
||||||
// If reached Minimum targets, enable OK button
|
// If reached Minimum targets, enable OK button
|
||||||
if (!tgt.isMinTargetsChosen(sa.getSourceCard(), sa) || tgt.isDividedAsYouChoose()) {
|
if (!tgt.isMinTargetsChosen(sa.getSourceCard(), sa) || tgt.isDividedAsYouChoose()) {
|
||||||
ButtonUtil.enableOnlyCancel();
|
if (mandatory && tgt.hasCandidates(sa, true)) {
|
||||||
|
// Player has to click on a target
|
||||||
|
ButtonUtil.disableAll();
|
||||||
|
} else {
|
||||||
|
ButtonUtil.enableOnlyCancel();
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
ButtonUtil.enableAllFocusOk();
|
if (mandatory && tgt.hasCandidates(sa, true)) {
|
||||||
}
|
// Player has to click on a target or ok
|
||||||
|
ButtonUtil.enableOnlyOk();
|
||||||
if (mandatory && tgt.hasCandidates(sa, true)) {
|
} else {
|
||||||
ButtonUtil.enableOnlyOk();
|
ButtonUtil.enableAllFocusOk();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user