summaryrefslogtreecommitdiff
path: root/rules.ts
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2024-04-23 10:52:14 +0200
committerTor Andersson <tor@ccxvii.net>2024-04-23 10:52:14 +0200
commit4edfad996c57a840f5b024200c8da2190a5c8079 (patch)
treebdb6e281b77799420f630d16e4ff11e9065af1e4 /rules.ts
parent73492042826443579b0600bb0885970a2c758bf0 (diff)
downloadplantagenet-4edfad996c57a840f5b024200c8da2190a5c8079.tar.gz
fix can_supply_at again
Diffstat (limited to 'rules.ts')
-rw-r--r--rules.ts10
1 files changed, 5 insertions, 5 deletions
diff --git a/rules.ts b/rules.ts
index 74fafd1..41f27b1 100644
--- a/rules.ts
+++ b/rules.ts
@@ -3635,12 +3635,12 @@ states.command = {
// === 4.5 ACTION: SUPPLY (SEARCH) ===
-function can_supply_at(loc: Locale, ships: number) {
- // if theoretically possible to supply (does not check carts or ships)
- if (is_stronghold(loc) && is_friendly_locale(loc)) {
- if (ships > 0 && (is_seaport(loc) || is_exile_box(loc)))
+function can_supply_at(source: Locale, ships: number) {
+ // if theoretically possible to supply from this source (does not check carts or ships)
+ if (is_stronghold(source) && is_friendly_locale(source)) {
+ if (ships > 0 && is_seaport(source))
return true
- if (!has_exhausted_marker(loc))
+ if (!has_exhausted_marker(source))
return true
}
return false