From ba1bd93560402362401ef61bccd9d0593470b90c Mon Sep 17 00:00:00 2001 From: PJB3005 Date: Wed, 6 Apr 2016 23:54:45 +0200 Subject: [PATCH] Fixes a boutput runtime * Fixes a boutput runtime * whoops --- code/__HELPERS/_macros.dm | 2 ++ goon/code/datums/browserOutput.dm | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/code/__HELPERS/_macros.dm b/code/__HELPERS/_macros.dm index f5ece7fdcaf..05880639093 100644 --- a/code/__HELPERS/_macros.dm +++ b/code/__HELPERS/_macros.dm @@ -107,6 +107,8 @@ #define isclient(A) (istype(A, /client)) +#define isatom(A) (istype(A, /atom)) + //Macros for antags #define isvampire(H) ((H.mind in ticker.mode.vampires) || H.mind.vampire) diff --git a/goon/code/datums/browserOutput.dm b/goon/code/datums/browserOutput.dm index e8cb7ac020a..d4699004169 100644 --- a/goon/code/datums/browserOutput.dm +++ b/goon/code/datums/browserOutput.dm @@ -209,7 +209,8 @@ For the main html chat area //It stands that we PROBABLY don't want to output those to the browser output so just handle them here if (istype(message, /image) || istype(message, /sound) || istype(target, /savefile) || !(ismob(target) || islist(target) || isclient(target) || target == world)) target << message - CRASH("DEBUG: Boutput called with invalid message") + if (!isatom(target)) // Really easy to mix these up, and not having to make sure things are mobs makes the code cleaner. + CRASH("DEBUG: Boutput called with invalid message") return //Otherwise, we're good to throw it at the user