summaryrefslogtreecommitdiff
path: root/rules.js
diff options
context:
space:
mode:
authoriainp5 <iain.pearce.ip@gmail.com>2025-01-06 16:29:41 +0000
committeriainp5 <iain.pearce.ip@gmail.com>2025-01-06 16:29:41 +0000
commit46c205101a9923a1bb32af2d54f1b1bbb5dc66f5 (patch)
tree44d0dd1f24a10913f311cde28e0e2c088fae6097 /rules.js
parentb03936419c38da419cc1c9edf261dc872b18d92c (diff)
download1989-dawn-of-freedom-46c205101a9923a1bb32af2d54f1b1bbb5dc66f5.tar.gz
Fix Observer during power struggles
Diffstat (limited to 'rules.js')
-rw-r--r--rules.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/rules.js b/rules.js
index 58548fe..9dc92ec 100644
--- a/rules.js
+++ b/rules.js
@@ -411,12 +411,10 @@ exports.view = function (state, player) {
democrat_power_hand: game.dem_pwr_hand.length,
communist_power_hand: game.com_pwr_hand.length,
ceausescu_cards: game.ceausescu_cards,
- is_pwr_struggle: game.is_pwr_struggle,
times_held: game.times_held,
revolutions: game.revolutions,
hand: [],
- pwr_hand: [],
}
if (game.is_pwr_struggle) {
@@ -424,6 +422,9 @@ exports.view = function (state, player) {
view.played_power_card = game.played_power_card
view.power_card_1 = game.power_card_1
view.power_card_2 = game.power_card_2
+
+ if (player === DEM || player === COM)
+ view.is_pwr_struggle = true
}
view.strategy_discard = game.strategy_discard