1
0
mirror of https://github.com/veden/Rampant.git synced 2024-12-26 20:54:12 +02:00

NA: Killed all units during faction and new enemy removal

This commit is contained in:
Aaron Veden 2023-03-26 14:42:43 -07:00
parent 2c6adbd3c0
commit 0c70b86dcb
No known key found for this signature in database
GPG Key ID: FF5990B1C6DD3F84

View File

@ -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