diff options
author | Tor Andersson <tor@ccxvii.net> | 2022-05-14 19:02:01 +0200 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-02-18 12:31:29 +0100 |
commit | c61f77d386220839b39db92bf679bda9fc4b182b (patch) | |
tree | cfe591e4c3d0eb39b87707411e5edf4c868e1dcb | |
parent | fc9ca66f2a79ea68047a0ab07296039fc99910a1 (diff) | |
download | pax-pamir-c61f77d386220839b39db92bf679bda9fc4b182b.tar.gz |
Check overthrow when moving tribes with Nationalism.
-rw-r--r-- | rules.js | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -1769,11 +1769,13 @@ states.move = { space(s) { push_undo(); let old = game.pieces[game.selected]; - if (game.selected < 36) + game.pieces[game.selected] = s; + if (game.selected < 36) { logi(`${player.loyalty} army from ${region_names[old]} to ${region_names[s]}.`); - else + } else { logi(`Tribe from ${region_names[old]} to ${region_names[s]}.`); - game.pieces[game.selected] = s; + check_region_overthrow(game.active, old); + } game.selected = -1; if (--game.count === 0) end_action(); |