mirror of
https://github.com/PHIDIAS0303/ExpCluster.git
synced 2025-12-30 04:21:41 +09:00
Update all code styles
This commit is contained in:
@@ -6,24 +6,24 @@
|
||||
local Commands = require("modules.exp_legacy.expcore.commands") --- @dep expcore.commands
|
||||
require("modules.exp_legacy.config.expcore.command_general_parse")
|
||||
|
||||
Commands.new_command('kill-biters', {'expcom-enemy.description-kill'}, 'Kill all biters only')
|
||||
:set_flag('admin_only')
|
||||
:register(function(_, _)
|
||||
game.forces['enemy'].kill_all_units()
|
||||
return Commands.success
|
||||
end)
|
||||
Commands.new_command("kill-biters", { "expcom-enemy.description-kill" }, "Kill all biters only")
|
||||
:set_flag("admin_only")
|
||||
:register(function(_, _)
|
||||
game.forces["enemy"].kill_all_units()
|
||||
return Commands.success
|
||||
end)
|
||||
|
||||
Commands.new_command('remove-biters', {'expcom-enemy.description-remove'}, 'Remove biters and prevent generation')
|
||||
:set_flag('admin_only')
|
||||
:add_param('surface', true, 'surface')
|
||||
:set_defaults{surface=function(player)
|
||||
return player.surface
|
||||
end}
|
||||
:register(function(_, surface)
|
||||
for _, entity in pairs(surface.find_entities_filtered({force='enemy'})) do
|
||||
entity.destroy()
|
||||
end
|
||||
Commands.new_command("remove-biters", { "expcom-enemy.description-remove" }, "Remove biters and prevent generation")
|
||||
:set_flag("admin_only")
|
||||
:add_param("surface", true, "surface")
|
||||
:set_defaults{ surface = function(player)
|
||||
return player.surface
|
||||
end }
|
||||
:register(function(_, surface)
|
||||
for _, entity in pairs(surface.find_entities_filtered{ force = "enemy" }) do
|
||||
entity.destroy()
|
||||
end
|
||||
|
||||
surface.map_gen_settings.autoplace_controls['enemy-base'].size = 'none'
|
||||
return Commands.success
|
||||
end)
|
||||
surface.map_gen_settings.autoplace_controls["enemy-base"].size = "none"
|
||||
return Commands.success
|
||||
end)
|
||||
|
||||
Reference in New Issue
Block a user