From 9ff6d22ddbd0e5690d5164694c9adf0158da893b Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Fri, 16 Jul 2021 12:16:42 +0200 Subject: crusader: Fix bug with Richard's Sea legs second move. --- rules.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/rules.js b/rules.js index 93df784..ba7a342 100644 --- a/rules.js +++ b/rules.js @@ -502,6 +502,9 @@ function is_contested_field(where) { function is_friendly_or_vacant_field(where) { return is_friendly_field(where) || is_vacant_town(where); } +function is_enemy_or_contested_field(where) { + return (count_enemy_in_field(where) > 0 || is_enemy_kingdom(where)); +} /* Battle field queries exclude castles and reserves. */ function is_contested_battle_field() { @@ -714,7 +717,7 @@ function can_use_richards_sea_legs(who, to) { // English Crusaders may attack by sea. // If combined with another attack, the English must be the Main Attacker. if (is_english_crusader(who)) { - if (is_enemy_field(to)) { + if (is_enemy_or_contested_field(to)) { if (!game.attacker[to]) return true; if (game.attacker[to] === FRANKS) -- cgit v1.2.3