From 377d116fb63d9ab234e6cb872f9e8e029b98b911 Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Thu, 3 Aug 2023 02:01:31 +0200 Subject: Allow Force March to enter/leave capital at zero cost. --- rules.js | 20 +++++++++----------- 1 file changed, 9 insertions(+), 11 deletions(-) diff --git a/rules.js b/rules.js index 3a03bf3..39f1372 100644 --- a/rules.js +++ b/rules.js @@ -671,10 +671,6 @@ function get_tribe_count() { return get_player_count() + 1 } -function can_general_leave_capital(id) { - return is_general_inside_capital(id) && !has_general_battled(id) -} - function can_enter_capital(where) { // No Capital if (is_no_place_governor(where)) @@ -1758,7 +1754,7 @@ function can_select_general(id) { return true // Free Action: Enter/Leave capital if (is_province(where)) - if (can_general_leave_capital(id) || can_enter_capital(where)) + if (is_general_inside_capital(id) || can_enter_capital(where)) return true } return false @@ -3471,13 +3467,15 @@ function play_ambitus() { // CARD: Force March function can_play_force_march() { + for (let i = 0; i < 6; ++i) { + let id = game.current * 6 + i + let where = get_general_location(id) + if (is_region(where)) + if (has_general_battled(id) && !has_general_force_marched(id)) + return game.mip >= 1 || is_general_inside_capital(id) || can_enter_capital(where) + } + if (game.mip >= 1) { - for (let i = 0; i < 6; ++i) { - let id = game.current * 6 + i - if (is_region(get_general_location(id))) - if (has_general_battled(id) && !has_general_force_marched(id)) - return true - } for (let i = 0; i < 12; ++i) { if (has_lone_militia(i) && has_militia_battled(i) && !has_militia_force_marched(i) && is_own_province(i)) return true -- cgit v1.2.3