diff options
Diffstat (limited to 'rules.js')
-rw-r--r-- | rules.js | 26 |
1 files changed, 15 insertions, 11 deletions
@@ -1891,15 +1891,10 @@ states.game_over = { states.general_strike = { inactive: 'discard a card', prompt() { - if (game.played_card === 0) { - view.prompt = 'General Strike: You must discard a card or play a Scoring Card.' - game.communist_hand - for (let card of game.communist_hand) { - gen_action_card(card) - } - } else if (game.played_card > 0) { - view.prompt = 'General Strike: Roll a die.' - gen_action('roll') + view.prompt = 'General Strike: You must discard a card or play a Scoring Card.' + game.communist_hand + for (let card of game.communist_hand) { + gen_action_card(card) } }, card(card) { @@ -1911,12 +1906,21 @@ states.general_strike = { if (scoring_cards.includes(card)) { game.vm_event = card log(`Played C${card} for the event`) - game.return_state = 'general_strike' + game.return_state = 'end_round' goto_vm(game.vm_event) } else { log(`Discarded C${card}`) + game.state = 'general_strike_roll' } }, +} + +states.general_strike_roll = { + inactive: 'discard a card', + prompt() { + view.prompt = 'General Strike: Roll a die.' + gen_action('roll') + }, roll() { clear_undo() let roll = roll_d6() @@ -1924,7 +1928,6 @@ states.general_strike = { logi(`+${game.available_ops} ops`) let total = roll + game.available_ops log(`Modified roll: ${total}`) - if (total > 5) { log('The strike is over') permanently_remove(C_GENERAL_STRIKE) @@ -1936,6 +1939,7 @@ states.general_strike = { }, } + states.honecker = { inactive: 'resolve Honecker', prompt() { |