summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoriainp5 <iain.pearce.ip@gmail.com>2024-10-04 20:17:46 +0100
committeriainp5 <iain.pearce.ip@gmail.com>2024-10-04 20:17:46 +0100
commit7be34db26d75baadbb8a160e30033ac09d8b7664 (patch)
treef041bd7670f3a32934ba37ec91f5048847661b2f
parent8a61efc69243a1cc73f8daa1dd2899fbd5395478 (diff)
download1989-dawn-of-freedom-7be34db26d75baadbb8a160e30033ac09d8b7664.tar.gz
Fix Power Struggle Deck
-rw-r--r--rules.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/rules.js b/rules.js
index 3105c5c..85e184d 100644
--- a/rules.js
+++ b/rules.js
@@ -1036,7 +1036,8 @@ states.draw_power_cards = {
},
draw() {
push_undo()
- game.power_struggle_deck = all_power_cards
+ game.power_struggle_deck = [...all_power_cards]
+ console.log('game.power_struggle_deck.length', game.power_struggle_deck.length)
console.log('called draw cards, country', game.pwr_struggle_in, 'game.active', game.active, 'game.view_opp_hand', game.view_opp_hand)
console.log('test3')
let presence = check_presence(game.pwr_struggle_in)
@@ -2553,7 +2554,7 @@ function valid_spaces_sc() {
function valid_spaces_support_loss() {
let valid_spaces_set = new Set();
for (let i = 1; i < game.demInfl.length; i++) {
- console.log('spaces.length', game.demInfl.length, 'i', i)
+ //console.log('spaces.length', game.demInfl.length, 'i', i)
space = spaces[i]
if (game.active === DEM) {
infl = game.demInfl[i]
@@ -5463,19 +5464,22 @@ function vm_power_struggle() {
console.log('in vm_power_struggle. game.vm_event', game.vm_event, 'game.active', game.active, 'game.view_opp_hand', game.view_opp_hand)
game.is_pwr_struggle = true
+ /* TO DELETE?
//Check if Power Struggle is because of an event
+ */
+
if (game.vm_event > 0) {
console.log('vm_power_struggle, in game.vm_event check')
game.pwr_struggle_in = countries[scoring_cards.indexOf(game.vm_event)]
log_h2(`C${game.vm_event}`)
}
-
+/*
//Otherwise set Power Struggle country normally
else {
console.log('vm_power_struggle, country set normally')
game.pwr_struggle_in = countries[scoring_cards.indexOf(game.played_card)]
log_h2(`C${game.played_card}`)
- }
+ }*/
//Check for Securitate