diff options
author | iainp5 <iain.pearce.ip@gmail.com> | 2024-09-20 12:26:52 +0100 |
---|---|---|
committer | iainp5 <iain.pearce.ip@gmail.com> | 2024-09-20 12:26:52 +0100 |
commit | 324c500f25c5c7db38d3ba4e1bf21f351b142e7a (patch) | |
tree | 600d3f4777e6d77e40b26e00a15eb4c6af700d78 /rules.js | |
parent | 15a81bf48a095baa7ca17a2310fb934a5a4e883c (diff) | |
download | 1989-dawn-of-freedom-324c500f25c5c7db38d3ba4e1bf21f351b142e7a.tar.gz |
Fix errors game.playable_cards
Diffstat (limited to 'rules.js')
-rw-r--r-- | rules.js | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -471,7 +471,7 @@ states.choose_card = { game.persistent_events['ligachev'] = false
}
console.log('game.played_card', game.played_card, 'playable', game.playable_cards[game.played_card].playable)
- game.playable_cards[97].playable = 1
+ game.playable_cards[97] = {number: 97, playable: 1}
console.log('game.playable_cards', game.playable_cards)
console.log('game.played_card', game.played_card, 'playable', game.playable_cards[game.played_card].playable)
game.state = 'play_card'
@@ -512,7 +512,7 @@ states.play_card ={ }
// Special check for Reformer Rehabilitated
- if ((game.active === DEM && game.playable_cards[game.played_card] === 2 && (game.dem_tst_position > game.com_tst_position)) || (game.active === COM && game.playable_cards[game.played_card] === 2 && (game.dem_tst_position < game.com_tst_position))) {
+ if ((game.active === DEM && game.playable_cards[game.played_card] === 2 && (game.dem_tst_position > game.com_tst_position)) || (game.active === COM && game.playable_cards[game.played_card].playable === 2 && (game.dem_tst_position < game.com_tst_position))) {
gen_action('event')
}
@@ -2542,7 +2542,7 @@ function do_tst_attempt() { }
// Check whether The Reformer is playable:
if ((game.dem_tst_position !== game.com_tst_position)) {
- game.playable_cards[67] = 2
+ game.playable_cards[67].playable = 2
}
}
@@ -4955,10 +4955,10 @@ function vm_the_tyrant_is_gone() { game.valid_spaces.push(space.space_id)
}
}
- game.playable_cards[10] = 0
- game.playable_cards[41] = 0
- game.playable_cards[101] = 0
- game.playable_cards[107] = 0
+ game.playable_cards[10].playable = 0
+ game.playable_cards[41].playable = 0
+ game.playable_cards[101].playable = 0
+ game.playable_cards[107].playable = 0
game.state = 'vm_the_tyrant_is_gone'
}
|