mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-11 10:11:09 +00:00
Fix some things assuming lighting corners existed (#28511)
This commit is contained in:
@@ -270,6 +270,8 @@
|
||||
source_turf.luminosity = Ceiling(light_range)
|
||||
for(T in view(Ceiling(light_range), source_turf))
|
||||
for (thing in T.get_corners(source_turf))
|
||||
if(!thing)
|
||||
continue
|
||||
C = thing
|
||||
corners[C] = 0
|
||||
turfs += T
|
||||
@@ -291,6 +293,8 @@
|
||||
LAZYINITLIST(effect_str)
|
||||
if (needs_update == LIGHTING_VIS_UPDATE)
|
||||
for (thing in corners - effect_str) // New corners
|
||||
if(!thing)
|
||||
continue
|
||||
C = thing
|
||||
LAZYADD(C.affecting, src)
|
||||
if (!C.active)
|
||||
@@ -300,6 +304,8 @@
|
||||
else
|
||||
L = corners - effect_str
|
||||
for (thing in L) // New corners
|
||||
if(!thing)
|
||||
continue
|
||||
C = thing
|
||||
LAZYADD(C.affecting, src)
|
||||
if (!C.active)
|
||||
@@ -308,6 +314,8 @@
|
||||
APPLY_CORNER(C)
|
||||
|
||||
for (thing in corners - L) // Existing corners
|
||||
if(!thing)
|
||||
continue
|
||||
C = thing
|
||||
if (!C.active)
|
||||
effect_str[C] = 0
|
||||
@@ -316,6 +324,8 @@
|
||||
|
||||
L = effect_str - corners
|
||||
for (thing in L) // Old, now gone, corners.
|
||||
if(!thing)
|
||||
continue
|
||||
C = thing
|
||||
REMOVE_CORNER(C)
|
||||
LAZYREMOVE(C.affecting, src)
|
||||
|
||||
Reference in New Issue
Block a user