summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
authorTor Andersson <tor@ccxvii.net>2023-02-03 10:55:58 +0100
committerTor Andersson <tor@ccxvii.net>2023-02-18 13:02:39 +0100
commit7dea27a7ff9d77fa9a32b18526bc262d3651ce81 (patch)
tree0baa913f127bd00798eabc13e0cdc192761e2d4a /rules.js
parentd7cdb35e89496d488c3a1f1a8ef4c81781b6167d (diff)
downloadnevsky-7dea27a7ff9d77fa9a32b18526bc262d3651ce81.tar.gz
Lint fixes.
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js13
1 files changed, 1 insertions, 12 deletions
diff --git a/rules.js b/rules.js
index 889cf0d..f155f6b 100644
--- a/rules.js
+++ b/rules.js
@@ -130,7 +130,6 @@ function find_locale(name) {
}
const lord_name = data.lords.map((lord) => lord.name)
-const vassal_name = data.vassals.map((vassal) => vassal.name)
const lord_count = data.lords.length
const vassal_count = data.vassals.length
@@ -990,10 +989,6 @@ function is_p1_lord(lord) {
return lord >= first_p1_lord && lord <= last_p1_lord
}
-function is_p2_lord(lord) {
- return lord >= first_p2_lord && lord <= last_p2_lord
-}
-
function is_friendly_lord(lord) {
return lord >= first_friendly_lord && lord <= last_friendly_lord
}
@@ -1462,19 +1457,13 @@ function calculate_distance(start, adjacent) {
return distance
}
-for (let loc = 0; loc <= last_locale; ++loc) {
+for (let loc = 0; loc <= last_locale; ++loc)
data.locales[loc].distance = calculate_distance(loc, "adjacent")
- data.locales[loc].distance_by_waterway = calculate_distance(loc, "adjacent_by_waterway")
-}
function locale_distance(from, to) {
return data.locales[from].distance[to]
}
-function locale_distance_by_waterway(from, to) {
- return data.locales[from].distance_by_waterway[to]
-}
-
// === SETUP ===
function muster_lord_forces(lord) {