From 96e7df4c28dd4e557c30fcb970f7d46227028ea7 Mon Sep 17 00:00:00 2001 From: Ben10Omintrix <138636438+Ben10Omintrix@users.noreply.github.com> Date: Fri, 20 Sep 2024 00:33:02 +0300 Subject: [PATCH] fixes advanced proximity sensors field calculations (#86735) ## About The Pull Request setting full_recalc to false would delete the entire field. setting it to true would double what it was meant to be ## Why It's Good For The Game fixes advanced proximity sensors field calculations ## Changelog :cl: /:cl: --- code/datums/proximity_monitor/field.dm | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/code/datums/proximity_monitor/field.dm b/code/datums/proximity_monitor/field.dm index e3f0ade5e7d..3ba3017bed0 100644 --- a/code/datums/proximity_monitor/field.dm +++ b/code/datums/proximity_monitor/field.dm @@ -40,7 +40,7 @@ var/list/old_edge_turfs = edge_turfs field_turfs = new_turfs[FIELD_TURFS_KEY] edge_turfs = new_turfs[EDGE_TURFS_KEY] - if(!full_recalc) + if(full_recalc) field_turfs = list() edge_turfs = list() @@ -62,12 +62,11 @@ for(var/turf/new_turf as anything in field_turfs - old_field_turfs) if(QDELETED(src)) return - field_turfs += new_turf setup_field_turf(new_turf) + for(var/turf/new_turf as anything in edge_turfs - old_edge_turfs) if(QDELETED(src)) return - edge_turfs += new_turf setup_edge_turf(new_turf) /datum/proximity_monitor/advanced/on_initialized(turf/location, atom/created, init_flags)