summaryrefslogtreecommitdiff
path: root/play.js
diff options
context:
space:
mode:
authorteisuru <31881306+teisuru@users.noreply.github.com>2023-09-04 08:22:40 +0200
committerTor Andersson <tor@ccxvii.net>2023-12-10 18:16:55 +0100
commit1bfc2c07a1e0de29e10ae73173d8e4dd6c70c920 (patch)
tree46f09919853e4bd0ad3c436a5b66fa0ebbbaf441 /play.js
parent7a24fc2dacb39d82a0b922244c8e54a79a4dadeb (diff)
downloadplantagenet-1bfc2c07a1e0de29e10ae73173d8e4dd6c70c920.tar.gz
add exhaustion levy troops
Diffstat (limited to 'play.js')
-rw-r--r--play.js21
1 files changed, 14 insertions, 7 deletions
diff --git a/play.js b/play.js
index 8f31f4c..89990a7 100644
--- a/play.js
+++ b/play.js
@@ -1111,6 +1111,7 @@ function update_locale(loc) {
if (ui.locale_name[loc]) {
ui.locale_name[loc].classList.toggle("action", is_action("locale", loc) || is_action("laden_march", loc))
}
+
ui.locale_markers[loc].replaceChildren()
@@ -1120,14 +1121,20 @@ function update_locale(loc) {
else
ui.locale_markers[loc].appendChild(get_cached_element("marker circle battle"))
- /*if (set_has(view.pieces.exhausted, loc)) {
+
+ if (set_has(view.pieces.depleted, loc)) {
let cn
- if (is_york_locale(loc))
- cn = "marker small exhausted lancaster"
- else
- cn = "marker small exhausted york"
- ui.locale_markers[loc].appendChild(get_cached_element(cn))
- }*/
+ cn = "depleted"
+ ui.locale_markers[loc].classList.add(cn)
+ }
+ if (set_has(view.pieces.exhausted, loc)) {
+ let cn
+ cn = "exhausted"
+ ui.locale_markers[loc].classList.add(cn)
+ cn = "depleted"
+ ui.locale_markers[loc].classList.remove(cn)
+
+ }
}
function update_plan() {