diff options
Diffstat (limited to 'rules.js')
-rw-r--r-- | rules.js | 14 |
1 files changed, 7 insertions, 7 deletions
@@ -1983,13 +1983,13 @@ function goto_rally() { function goto_rally_space() { push_summary() + game.cmd.count = rally_count() let p = find_piece(AVAILABLE, game.current, ELITE) - if (rally_count() === 1 && p > -1) { + if (game.cmd.count === 1 && p > -1) { log_summary_place(p) place_piece(p, game.cmd.where) end_rally_space() } else { - game.cmd.count = 0 game.state = "rally_space" } } @@ -2032,18 +2032,18 @@ states.rally_space = { view.prompt = `Rally: No available ${PIECE_FACTION_TYPE_NAME[game.current][ELITE]}.` view.actions.next = 1 } else { - view.prompt = `Rally: Place up to ${format_unit_count(game.current, ELITE, rally_count())}.` + view.prompt = `Rally: Place up to ${format_unit_count(game.current, ELITE, game.cmd.count)}.` view.where = game.cmd.where gen_place_piece(game.current, ELITE) } - - if (game.cmd.count > 0) - view.actions.next = 1 + view.actions.next = 1 }, piece(p) { + push_undo() log_summary_place(p) place_piece(p, game.cmd.where) - if (++game.cmd.count >= rally_count()) + game.cmd.count -= 1 + if (game.cmd.count === 0) end_rally_space() }, next() { |