mirror of
https://github.com/SPLURT-Station/S.P.L.U.R.T-Station-13.git
synced 2025-12-11 10:22:13 +00:00
Merge pull request #32137 from MrStonedOne/patch-441
Remove some unneeded null checks in lighting
This commit is contained in:
committed by
CitadelStationBot
parent
0a32eb3162
commit
8c194d8947
@@ -271,8 +271,6 @@
|
|||||||
source_turf.luminosity = Ceiling(light_range)
|
source_turf.luminosity = Ceiling(light_range)
|
||||||
for(T in view(Ceiling(light_range), source_turf))
|
for(T in view(Ceiling(light_range), source_turf))
|
||||||
for (thing in T.get_corners(source_turf))
|
for (thing in T.get_corners(source_turf))
|
||||||
if(!thing)
|
|
||||||
continue
|
|
||||||
C = thing
|
C = thing
|
||||||
corners[C] = 0
|
corners[C] = 0
|
||||||
turfs += T
|
turfs += T
|
||||||
@@ -294,8 +292,6 @@
|
|||||||
LAZYINITLIST(effect_str)
|
LAZYINITLIST(effect_str)
|
||||||
if (needs_update == LIGHTING_VIS_UPDATE)
|
if (needs_update == LIGHTING_VIS_UPDATE)
|
||||||
for (thing in corners - effect_str) // New corners
|
for (thing in corners - effect_str) // New corners
|
||||||
if(!thing)
|
|
||||||
continue
|
|
||||||
C = thing
|
C = thing
|
||||||
LAZYADD(C.affecting, src)
|
LAZYADD(C.affecting, src)
|
||||||
if (!C.active)
|
if (!C.active)
|
||||||
@@ -305,8 +301,6 @@
|
|||||||
else
|
else
|
||||||
L = corners - effect_str
|
L = corners - effect_str
|
||||||
for (thing in L) // New corners
|
for (thing in L) // New corners
|
||||||
if(!thing)
|
|
||||||
continue
|
|
||||||
C = thing
|
C = thing
|
||||||
LAZYADD(C.affecting, src)
|
LAZYADD(C.affecting, src)
|
||||||
if (!C.active)
|
if (!C.active)
|
||||||
@@ -315,8 +309,6 @@
|
|||||||
APPLY_CORNER(C)
|
APPLY_CORNER(C)
|
||||||
|
|
||||||
for (thing in corners - L) // Existing corners
|
for (thing in corners - L) // Existing corners
|
||||||
if(!thing)
|
|
||||||
continue
|
|
||||||
C = thing
|
C = thing
|
||||||
if (!C.active)
|
if (!C.active)
|
||||||
effect_str[C] = 0
|
effect_str[C] = 0
|
||||||
@@ -325,8 +317,6 @@
|
|||||||
|
|
||||||
L = effect_str - corners
|
L = effect_str - corners
|
||||||
for (thing in L) // Old, now gone, corners.
|
for (thing in L) // Old, now gone, corners.
|
||||||
if(!thing)
|
|
||||||
continue
|
|
||||||
C = thing
|
C = thing
|
||||||
REMOVE_CORNER(C)
|
REMOVE_CORNER(C)
|
||||||
LAZYREMOVE(C.affecting, src)
|
LAZYREMOVE(C.affecting, src)
|
||||||
|
|||||||
Reference in New Issue
Block a user