diff options
author | Tor Andersson <tor@ccxvii.net> | 2023-01-05 00:58:55 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-02-18 13:02:38 +0100 |
commit | 4cca4583503f22b375748f33f5aa2bcfc02a7281 (patch) | |
tree | b8d60651ce8320741b9487615eb08504ac45d45f | |
parent | b032ccd20677a8da17f061f4ded3b7dcae1c85ed (diff) | |
download | nevsky-4cca4583503f22b375748f33f5aa2bcfc02a7281.tar.gz |
Fix Storm reposition when routed.
-rw-r--r-- | rules.js | 8 |
1 files changed, 5 insertions, 3 deletions
@@ -6783,11 +6783,13 @@ states.reposition_storm = { log(`Swapped in L${lord}.`) set_delete(game.battle.reserves, lord) if (game.active === game.battle.attacker) { - set_add(game.battle.reserves, game.battle.array[A2]) + if (game.battle.array[A2] !== NOBODY) + set_add(game.battle.reserves, game.battle.array[A2]) game.battle.array[A2] = lord } else { - set_add(game.battle.reserves, game.battle.array[D2]) - game.battle.array[A2] = lord + if (game.battle.array[D2] !== NOBODY) + set_add(game.battle.reserves, game.battle.array[D2]) + game.battle.array[D2] = lord } end_reposition_storm() }, |