summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMischa Untaga <99098079+MischaU8@users.noreply.github.com>2023-10-15 10:09:49 +0200
committerMischa Untaga <99098079+MischaU8@users.noreply.github.com>2023-10-15 10:09:49 +0200
commitda60c53e3ac55db88cdbd99fe07cb1663eb25f66 (patch)
tree95353000b1316c20722f2d1c5add4336669e8f41
parent95e891dc71593fdcd28c7ed7ee5e0948945d45b0 (diff)
downloadalgeria-da60c53e3ac55db88cdbd99fe07cb1663eb25f66.tar.gz
remove (police) unit clears neutralized
-rw-r--r--rules.js10
1 files changed, 8 insertions, 2 deletions
diff --git a/rules.js b/rules.js
index 9fd24b1..052f886 100644
--- a/rules.js
+++ b/rules.js
@@ -472,6 +472,13 @@ function eliminate_unit(u) {
game.units[u] = 0
set_unit_loc(u, ELIMINATED)
set_unit_box(u, OC)
+ clear_unit_neutralized(u)
+}
+
+function remove_unit(u) {
+ set_unit_loc(u, DEPLOY)
+ set_unit_box(u, OC)
+ clear_unit_neutralized(u)
}
function evade_unit(u) {
@@ -1790,8 +1797,7 @@ states.gov_reinforcement = {
for (let u of list) {
let loc = unit_loc(u)
log(`>U${u} from A${loc}`)
- set_unit_loc(u, DEPLOY)
- set_unit_box(u, OC)
+ remove_unit(u)
}
},
acquire_air_point() {