summaryrefslogtreecommitdiff
path: root/play.js
diff options
context:
space:
mode:
authoriainp5 <iain.pearce.ip@gmail.com>2024-11-03 08:10:13 +0000
committeriainp5 <iain.pearce.ip@gmail.com>2024-11-03 08:10:13 +0000
commit3b1f1fcecea5f891131ae891299a5884fc12db0c (patch)
tree8dd59fce057f8d92b1a4f483f2f297e4c8318e5b /play.js
parent677818d36c8491ea9f6978e547f1e5428e280628 (diff)
download1989-dawn-of-freedom-3b1f1fcecea5f891131ae891299a5884fc12db0c.tar.gz
Auto show discard for events
Diffstat (limited to 'play.js')
-rw-r--r--play.js5
1 files changed, 4 insertions, 1 deletions
diff --git a/play.js b/play.js
index 8672373..3517802 100644
--- a/play.js
+++ b/play.js
@@ -667,7 +667,6 @@ function on_update() {
ui.hand.replaceChildren()
for (let c of view.hand)
ui.hand.appendChild(ui.cards[c])
- console.log('ui.hand', ui.hand)
ui.power_hand.replaceChildren()
if (view.power_hand)
@@ -695,6 +694,10 @@ function on_update() {
ui.discard.replaceChildren()
for (let c of view.strategy_discard)
ui.discard.appendChild(ui.cards[c])
+ if (view.discard)
+ document.getElementById("discard_panel").classList.remove("hide")
+ else
+ document.getElementById("discard_panel").classList.add("hide")
ui.removed.replaceChildren()
for (let c of view.strategy_removed)