summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorteisuru <31881306+teisuru@users.noreply.github.com>2023-10-15 16:21:54 +0200
committerTor Andersson <tor@ccxvii.net>2023-12-10 18:16:55 +0100
commit49a4d6426c5d08f4779ffd608cdc7478f03dd743 (patch)
tree6f739e4d3f355b453ce12f0d0a81db5da67c9a48
parent2660a0a4a78f433ec4b02986ccbc77fc800121e1 (diff)
downloadplantagenet-49a4d6426c5d08f4779ffd608cdc7478f03dd743.tar.gz
Capability L37
-rw-r--r--rules.js16
1 files changed, 16 insertions, 0 deletions
diff --git a/rules.js b/rules.js
index 8a54f64..93e6cb1 100644
--- a/rules.js
+++ b/rules.js
@@ -1433,6 +1433,14 @@ function has_friendly_lord(loc) {
return true
return false
}
+
+function is_adjacent_friendly_port_english_channel(loc) {
+ for (let next of data.locales[loc].adjacent) {
+ if (is_friendly_locale(next) && data.port_2.includes(next))
+ return true
+ }
+}
+
/*
function has_besieged_friendly_lord(loc) {
for (let lord = first_friendly_lord; lord <= last_friendly_lord; ++lord)
@@ -6655,6 +6663,14 @@ function goto_pay() {
log_br()
let n = 0
for (let lord = first_friendly_lord; lord <= last_friendly_lord; ++lord) {
+ let here = get_lord_locale(lord)
+ if (is_lord_on_map(lord) &&
+ !is_lord_on_calendar(lord) &&
+ lord_has_capability(lord, AOW_LANCASTER_MADAME_LA_GRANDE) &&
+ (((is_friendly_locale(data.locales[here])) && data.port_2.includes(here)) ||
+ is_adjacent_friendly_port_english_channel(here))) {
+ add_lord_assets(lord, COIN, 1)
+ }
if (
game.active === LANCASTER &&
is_lord_on_map(lord) &&