summaryrefslogtreecommitdiff
path: root/play.js
diff options
context:
space:
mode:
Diffstat (limited to 'play.js')
-rw-r--r--play.js10
1 files changed, 6 insertions, 4 deletions
diff --git a/play.js b/play.js
index 0e15fb6..0471007 100644
--- a/play.js
+++ b/play.js
@@ -509,7 +509,7 @@ function create_ui() {
}
ui.power_cards = []
- for (let c = 1; c <= last_power_card; ++c) {
+ for (let c = 1; c <= last_power_card + 1; ++c) {
const power_card_e = document.createElement("div")
register_action(power_card_e, "power_card", c)
power_card_e.className = "card power_card power_" + c
@@ -848,9 +848,11 @@ function on_update() {
ui.hand.appendChild(ui.cards[c])
ui.power_hand.replaceChildren()
- if (view.power_hand)
- for (let c of view.power_hand)
- ui.power_hand.appendChild(ui.power_cards[c])
+ if (view.is_pwr_struggle)
+ ui.power_hand.appendChild(ui.power_cards[53])
+ if (view.power_hand.length > 0)
+ for (let c of view.power_hand)
+ ui.power_hand.appendChild(ui.power_cards[c])
ui.power_discard.replaceChildren()
if (view.power_struggle_discard)