summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2024-12-25 12:25:01 +0100
committerTor Andersson <tor@ccxvii.net>2024-12-25 12:26:13 +0100
commit102f18e2c48e513e8172d85a19145d9a1bd769a4 (patch)
treea0ff59e970142c08fb0b455d2537dd945df21c97
parent051f7763f3b2eec8ab09c429afe8dc8c47b40550 (diff)
downloadmaria-102f18e2c48e513e8172d85a19145d9a1bd769a4.tar.gz
fix retroactive conquest austria/prags
-rw-r--r--rules.js24
1 files changed, 21 insertions, 3 deletions
diff --git a/rules.js b/rules.js
index 65562e7..424aa0b 100644
--- a/rules.js
+++ b/rules.js
@@ -4427,12 +4427,30 @@ function apply_retroactive_conquest(conq, major) {
function goto_retroactive_conquest() {
delete game.combat
let conq = []
- if (is_two_player() && !is_intro() && (game.power === P_PRAGMATIC || game.power === P_AUSTRIA)) {
- apply_retroactive_conquest(conq, P_AUSTRIA)
- apply_retroactive_conquest(conq, P_PRAGMATIC)
+
+ if (!is_intro()) {
+ if (is_two_player()) {
+ if (game.power === P_AUSTRIA) {
+ // combined combat phase
+ apply_retroactive_conquest(conq, P_AUSTRIA)
+ apply_retroactive_conquest(conq, P_PRAGMATIC)
+ } else {
+ apply_retroactive_conquest(conq, game.power)
+ }
+ } else {
+ if (game.power === P_AUSTRIA) {
+ // wait until pragmatic has also finished combat
+ } else if (game.power === P_PRAGMATIC) {
+ apply_retroactive_conquest(conq, P_AUSTRIA)
+ apply_retroactive_conquest(conq, P_PRAGMATIC)
+ } else {
+ apply_retroactive_conquest(conq, game.power)
+ }
+ }
} else {
apply_retroactive_conquest(conq, game.power)
}
+
log_conquest(conq)
next_sequence_of_play()
}