Skip to content

Commit

Permalink
Simplify the sim side
Browse files Browse the repository at this point in the history
  • Loading branch information
Garanas committed Sep 25, 2024
1 parent 509465d commit 8faa004
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions lua/selfdestruct.lua
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ local function SelfDestructThread(unit)
end

--- Toggles the destruction of the units
---@param data { owner: number, noDelay: boolean, allUnits: boolean }
---@param data { owner: number, noDelay: boolean }
---@param units Unit[]
function ToggleSelfDestruct(data, units)

Expand All @@ -32,11 +32,6 @@ function ToggleSelfDestruct(data, units)
-- do not allow observers to use this
if data.owner ~= -1 and OkayToMessWithArmy(data.owner) then

-- if we want to destroy all units
if data.allUnits then
units = GetArmyBrain(data.owner):GetListOfUnits(categories.ALLUNITS, false, false)
end

-- just take them all out
if data.noDelay then
for _, unit in units do
Expand Down

0 comments on commit 8faa004

Please sign in to comment.