From 5af0af2eeee8d8b139f36aa37c59aa24fa35b0ab Mon Sep 17 00:00:00 2001 From: Aranclanos Date: Thu, 25 Jul 2013 22:55:12 -0300 Subject: [PATCH] Runtime fix for buildmode type path inputs, incorrect paths are now rejected. --- code/WorkInProgress/buildmode.dm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/WorkInProgress/buildmode.dm b/code/WorkInProgress/buildmode.dm index 1697cfaff1a..33953434e6d 100644 --- a/code/WorkInProgress/buildmode.dm +++ b/code/WorkInProgress/buildmode.dm @@ -145,10 +145,11 @@ return if(2) objholder = input(usr,"Enter typepath:" ,"Typepath","/obj/structure/closet") + var/P = text2path(objholder) var/list/removed_paths = list("/obj/effect/bhole") - if(objholder in removed_paths) - alert("That path is not allowed.") + if((objholder in removed_paths) || !ispath(P)) objholder = "/obj/structure/closet" + alert("That path is not allowed.") else if (dd_hasprefix(objholder, "/mob") && !check_rights(R_DEBUG,0)) objholder = "/obj/structure/closet" if(3)