From 0c70b86dcb7bbc833950ac9276b66f2852e38bef Mon Sep 17 00:00:00 2001 From: Aaron Veden Date: Sun, 26 Mar 2023 14:42:43 -0700 Subject: [PATCH] NA: Killed all units during faction and new enemy removal --- control.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/control.lua b/control.lua index a3ecfbd..d736537 100644 --- a/control.lua +++ b/control.lua @@ -1080,6 +1080,7 @@ remote.add_interface("rampantTests", local function removeNewEnemies() game.print({"description.rampant--removeNewEnemies"}) Universe.NEW_ENEMIES = false + game.forces.enemy.kill_all_units() for _,map in pairs(Universe.maps) do local surface = map.surface if surface.valid then @@ -1142,6 +1143,7 @@ local function removeFaction(cmd) game.print({"description.rampant--removeFactionNames"}) return end + game.forces.enemy.kill_all_units() factionNames = split(factionNames) for _,factionName in pairs(factionNames) do local found = false