diff options
-rw-r--r-- | play.js | 1 | ||||
-rw-r--r-- | rules.js | 8 |
2 files changed, 7 insertions, 2 deletions
@@ -540,6 +540,7 @@ function on_update() { confirm_action_button("end_turn_pass", "End turn", "Are you sure you want to END TURN while you still have actions?") action_button("end_turn", "End turn") + action_button("cancel", "Cancel") action_button("undo", "Undo") ui.favored1.className = view.favored @@ -821,7 +821,7 @@ states.bribe = { if (player.events.courtly_manners) gen_action('courtly_manners') if (game.undo.length === 0) - gen_action('refuse') + gen_action('cancel') }, courtly_manners() { log(`Did not pay bribe.`) @@ -841,6 +841,10 @@ states.bribe = { set_active(p) }, refuse() { + // for old replays + states.bribe.cancel() + }, + cancel() { game.card = 0 game.where = 0 resume_actions() @@ -3161,7 +3165,7 @@ exports.action = function (state, current, action, arg) { load_game(state) let S = states[game.state] if (action in S) { - S[action](arg, current) + S[action](arg) } else { if (action === 'undo' && game.undo && game.undo.length > 0) pop_undo() |