diff --git a/wadsrc/static/zscript/shared/sectoraction.txt b/wadsrc/static/zscript/shared/sectoraction.txt index 32302959a..fb7edfb19 100644 --- a/wadsrc/static/zscript/shared/sectoraction.txt +++ b/wadsrc/static/zscript/shared/sectoraction.txt @@ -37,13 +37,16 @@ class SectorAction : Actor else { Actor probe = CurSector.SecActTarget; - while (probe.tracer != self && probe.tracer != null) + if (null != probe) { - probe = probe.tracer; - } - if (probe.tracer == self) - { - probe.tracer = tracer; + while (probe.tracer != self && probe.tracer != null) + { + probe = probe.tracer; + } + if (probe.tracer == self) + { + probe.tracer = tracer; + } } } }