summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2022-03-24 19:20:26 +0100
committerTor Andersson <tor@ccxvii.net>2023-02-18 11:54:52 +0100
commitde609d09613cbe4f938138249afc3b182337536b (patch)
tree8b6a246a68974ddc58122a24dee8d22e677cc1ed /rules.js
parent1356d31fd9f4f05981cceddde8d8ffb4acbed1a7 (diff)
downloadwilderness-war-de609d09613cbe4f938138249afc3b182337536b.tar.gz
Fix retroactive foul weather before lone leader retreat.
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/rules.js b/rules.js
index 65f057f..ddf11bd 100644
--- a/rules.js
+++ b/rules.js
@@ -5461,6 +5461,8 @@ function goto_retreat_lone_leader(from, reason) {
set_active_enemy();
game.state = 'retreat_lone_leader';
game.retreat = { from, reason };
+ // Pause for foul weather if necessary
+ goto_retroactive_foul_weather();
}
function pick_unbesieged_leader(s) {
@@ -5525,6 +5527,7 @@ states.retreat_lone_leader = {
function resume_retreat_lone_leader(from) {
let who = pick_unbesieged_leader(from);
if (!who) {
+ flush_summary();
set_active_enemy();
switch (game.retreat.reason) {
case 'indian_alliance':