mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 20:48:56 +01:00
Fixes AI's trying to light up cameras in areas with no cameras (#75302) This check is present throughout cameranet code as chunk camera lists can be empty lists by design, it was just missing for the AI camera light-up proc since that's in a separate area. Co-authored-by: ShizCalev <ShizCalev@users.noreply.github.com>
This commit is contained in:
@@ -783,7 +783,7 @@
|
||||
for (var/datum/camerachunk/chunk as anything in eyeobj.visibleCameraChunks)
|
||||
for (var/z_key in chunk.cameras)
|
||||
for(var/obj/machinery/camera/camera as anything in chunk.cameras[z_key])
|
||||
if (!camera.can_use() || get_dist(camera, eyeobj) > 7 || !camera.internal_light)
|
||||
if (!camera || !camera.can_use() || get_dist(camera, eyeobj) > 7 || !camera.internal_light)
|
||||
continue
|
||||
visible |= camera
|
||||
|
||||
|
||||
Reference in New Issue
Block a user