From c1d45ea42e27d0ed88eafe4d606485c160f848e4 Mon Sep 17 00:00:00 2001 From: "baloh.matevz" Date: Mon, 4 Jun 2012 22:58:39 +0000 Subject: [PATCH] - Only humans can now use the toggle open and toggle lock verbs on closets. git-svn-id: http://tgstation13.googlecode.com/svn/trunk@3742 316c924e-a436-60f5-8080-3fe189b3f50e --- code/game/objects/closets.dm | 5 ++++- code/game/objects/closets/secure/secure_closets.dm | 8 +++++--- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/code/game/objects/closets.dm b/code/game/objects/closets.dm index 54ce1884aa8..f9f267621f6 100644 --- a/code/game/objects/closets.dm +++ b/code/game/objects/closets.dm @@ -227,4 +227,7 @@ if(!usr.canmove || usr.stat || usr.restrained()) return - src.attack_hand(usr) + if(ishuman(usr)) + src.attack_hand(usr) + else + usr << "\red This mob type can't use this verb." diff --git a/code/game/objects/closets/secure/secure_closets.dm b/code/game/objects/closets/secure/secure_closets.dm index 88881d37dee..e17139e147b 100644 --- a/code/game/objects/closets/secure/secure_closets.dm +++ b/code/game/objects/closets/secure/secure_closets.dm @@ -108,6 +108,8 @@ if(!usr.canmove || usr.stat || usr.restrained()) // Don't use it if you're not able to! Checks for stuns, ghost and restrain return - if(!opened) // If we let him lock it while it's open, it will close without the items inside going with it - togglelock(usr) - + if (ishuman(usr)) + if (!opened) + togglelock(usr) + else + usr << "\red This mob type can't use this verb." \ No newline at end of file