summaryrefslogtreecommitdiff
path: root/play.js
diff options
context:
space:
mode:
Diffstat (limited to 'play.js')
-rw-r--r--play.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/play.js b/play.js
index 61e841f..a98c671 100644
--- a/play.js
+++ b/play.js
@@ -516,9 +516,15 @@ if (!view.is_pwr_struggle) {
document.getElementById("opp_hand_panel").classList.remove("hide")
for (let c of view.opp_hand) {
let card = ui.cards[c]
- //console.log('power_card:', power_card)
document.getElementById("opp_hand").appendChild(card);
card.classList.remove('discard_card')
+ if (!view.is_pwr_struggle) {
+ if (view.valid_cards.includes(c)) {
+ card.classList.add('selected')
+ } else {
+ card.classList.remove('selected')
+ }
+ }
}
} else {
document.getElementById("opp_hand_panel").classList.add("hide")