From e0796caf566e8236d75d9cbee94b112b5aa733bf Mon Sep 17 00:00:00 2001 From: PsiOmega Date: Tue, 28 Oct 2014 18:43:48 +0100 Subject: [PATCH 1/2] Fixes #6871. Fixes #6821. Amended to match the formatting in #6846, to hopefully avoid merge issues. --- code/game/objects/items/weapons/extinguisher.dm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/code/game/objects/items/weapons/extinguisher.dm b/code/game/objects/items/weapons/extinguisher.dm index 652e51e95c..3ca5c0d2ae 100644 --- a/code/game/objects/items/weapons/extinguisher.dm +++ b/code/game/objects/items/weapons/extinguisher.dm @@ -126,7 +126,10 @@ if(!W) return W.reagents.reaction(get_turf(W)) for(var/atom/atm in get_turf(W)) - if(!W) return + if(!W) + return + if(!W.reagents) + break W.reagents.reaction(atm) if(W.loc == my_target) break sleep(2) From aa3e52b1befb0b18a1c232f3190948fcbdf3c364 Mon Sep 17 00:00:00 2001 From: PsiOmega Date: Wed, 29 Oct 2014 08:07:36 +0100 Subject: [PATCH 2/2] Adds sanity check for the mecha fire extingusher as well. Would rather remake it to be based on the standard extinguisher code but that's a dev project. --- code/game/mecha/equipment/tools/tools.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/game/mecha/equipment/tools/tools.dm b/code/game/mecha/equipment/tools/tools.dm index 42f5debc62..3f801db365 100644 --- a/code/game/mecha/equipment/tools/tools.dm +++ b/code/game/mecha/equipment/tools/tools.dm @@ -216,6 +216,8 @@ step_towards(W,my_target) if(!W) return + if(!W.reagents) + break var/turf/W_turf = get_turf(W) W.reagents.reaction(W_turf) for(var/atom/atm in W_turf)