diff options
-rw-r--r-- | rules.js | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -1325,6 +1325,7 @@ function next_attack_cavalry_step() { log_br() log(`${faction_flags[game.cmd.attacker]} scores ${game.cmd.a_hit} hits.`) log(`${faction_flags[game.cmd.target]} scores ${game.cmd.d_hit} hits.`) + log_br() goto_attack_casualties() } } @@ -1407,6 +1408,7 @@ function get_attack_victor() { function goto_attack_casualties() { let curr + game.dice = [0, 0, 0, 0, 0, 0] if (game.cmd.step === 2) { curr = game.cmd.target game.cmd.count = game.cmd.a_hit @@ -1422,6 +1424,7 @@ function goto_attack_casualties() { } else { game.current = curr if (game.cmd.count > 0) { + push_summary() game.state = "attack_casualties" } else end_attack_casualties() @@ -1456,6 +1459,10 @@ states.attack_casualties = { }, piece(p) { push_undo() + if (piece_space(p) === game.cmd.where) + log_summary_remove(p) + else + log_summary_remove_from(p) remove_piece(p) set_delete(game.cmd.selected, p) game.cmd.count -= 1 @@ -1466,6 +1473,8 @@ states.attack_casualties = { } function end_attack_casualties() { + if (game.summary) + upop_summary() clear_undo() if (game.cmd.step === 2) { game.cmd.step += 1 @@ -1476,7 +1485,6 @@ function end_attack_casualties() { } function goto_attack_resolution() { - game.dice = [0, 0, 0, 0, 0, 0] if (is_rebel_faction(game.cmd.target) && is_rebel_faction(game.cmd.attacker)) attack_influence_shift() else if (game.cmd.attacker === MI && !is_timurid()) { |