Fixes runtime with hand labelers

This commit is contained in:
Ravensdale
2015-01-13 09:52:14 -08:00
parent fe376c66aa
commit 759373ac0a
+7 -3
View File
@@ -6,9 +6,13 @@
var/label = null
var/labels_left = 30
var/mode = 0 //off or on.
/obj/item/weapon/hand_labeler/attack()
return
/obj/item/weapon/hand_labeler/afterattack(atom/A, mob/user as mob, proximity)
if(!proximity) return
if(!proximity)
return
if(!mode) //if it's off, give up.
return
if(A == loc) // if placing the labeller into something (e.g. backpack)
@@ -24,10 +28,10 @@
user << "<span class='notice'>Label too big.</span>"
return
if(ishuman(A))
user << "<span class='notice'>You can't label humans.</span>"
user << "<span class='notice'>The label refuses to stick to [A.name].</span>"
return
if(issilicon(A))
user << "<span class='notice'>You can't label cyborgs.</span>"
user << "<span class='notice'>The label refuses to stick to [A.name].</span>"
return
if(istype(A, /obj/item/weapon/reagent_containers/glass))
user << "<span class='notice'>The label can't stick to the [A.name]. (Try using a pen)</span>"