Skip to content

Commit 2d82560

Browse files
committed
Really fix #5550.
1 parent 771cdb9 commit 2d82560

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

LuaRules/Gadgets/unit_terraform.lua

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,7 @@ local spCreateUnit = Spring.CreateUnit
5959
local spDestroyUnit = Spring.DestroyUnit
6060
local spGetAllyTeamList = Spring.GetAllyTeamList
6161
local spSetUnitLosMask = Spring.SetUnitLosMask
62+
local spSetUnitLosState = Spring.SetUnitLosState
6263
local spGetTeamInfo = Spring.GetTeamInfo
6364
local spGetUnitHealth = Spring.GetUnitHealth
6465
local spSetUnitHealth = Spring.SetUnitHealth
@@ -571,7 +572,8 @@ local function SetInivisbleToEnemy(unitID, team)
571572
for i=1, #allyTeamList do
572573
local allyID = allyTeamList[i]
573574
if allyID ~= unitAllyTeam then
574-
spSetUnitLosMask(unitID, allyID, {los=true, radar=true, prevLos=true, contRadar=true } )
575+
spSetUnitLosState(unitID, allyID, 0)
576+
spSetUnitLosMask(unitID, allyID, 15)
575577
end
576578
end
577579
end

0 commit comments

Comments
 (0)