From 4b525018355589dd783abc9ed8c4f771c08eec4f Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Sun, 28 Apr 2024 18:44:24 +0200 Subject: warden of the marches - improve prompts --- rules.ts | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/rules.ts b/rules.ts index 1bf9150..42f4244 100644 --- a/rules.ts +++ b/rules.ts @@ -8136,14 +8136,21 @@ states.warden_of_the_marches = { inactive: "Warden of the Marches", prompt() { if (game.where === NOWHERE) { - view.prompt = "Warden of the Marches: Move routed Lancastrians to a friendly stronghold in the North." + view.prompt = "Warden of the Marches: Choose a friendly stronghold in the North." for (let loc of all_locales) if (is_north(loc) && loc !== game.battle.where && is_friendly_locale(loc) && !has_enemy_lord(loc)) gen_action_locale(loc) } else { - for (let lord of game.battle.routed) - if (is_move_allowed(lord, game.where)) + view.prompt = `Warden of the Marches: Move routed Lancastrians to ${locale_name[game.where]}.` + let done = true + for (let lord of game.battle.routed) { + if (is_move_allowed(lord, game.where)) { gen_action_lord(lord) + done = false + } + } + if (done) + view.prompt = "Warden of the Marches: All done." view.actions.done = 1 } }, -- cgit v1.2.3