diff options
author | Tor Andersson <tor@ccxvii.net> | 2023-01-17 12:08:13 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-02-18 13:02:39 +0100 |
commit | 1db9608960fb9cf85959948baa677a1262942855 (patch) | |
tree | 62e05280032022daa13920df766890b5858a1d33 /rules.js | |
parent | 13690f493b77cec4bff55472d5a3ad9ec1d4ea4b (diff) | |
download | nevsky-1db9608960fb9cf85959948baa677a1262942855.tar.gz |
Clamp melee hits in storm before totaling.
Diffstat (limited to 'rules.js')
-rw-r--r-- | rules.js | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -7459,8 +7459,8 @@ function goto_strike() { for (let pos of current_strike_positions()) { let lord = get_battle_array(pos) if (lord !== NOBODY) { - let hits = (game.battle.ah[pos] = count_lord_hits(lord)) - let xhits = (game.battle.ahx[pos] = count_lord_xhits(lord)) + let hits = count_lord_hits(lord) + let xhits = count_lord_xhits(lord) // STORM: Max 6 hits per lord in melee (12 since we count half-hits). if (game.battle.storm) { @@ -7468,6 +7468,9 @@ function goto_strike() { hits = 12 } + game.battle.ah[pos] = hits + game.battle.ahx[pos] = xhits + if (xhits > 2) log(`L${lord} ${xhits / 2} crossbow hits`) else if (xhits > 0) |