Fixing a runtime error introduced in r1615.

Note: Checking a null object with istype won't throw up a runtime error but checking a var of a null object will.

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@1616 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
morikou@gmail.com
2011-05-25 00:52:09 +00:00
parent 9b46819b80
commit bbbced8835
+11 -11
View File
@@ -1134,19 +1134,19 @@ proc/isobserver(A)
/mob/proc/drop_item()
var/obj/item/W = equipped()
if(W.twohanded)
if(W.wielded)
if(hand)
var/obj/item/weapon/offhand/O = r_hand
del O
else
var/obj/item/weapon/offhand/O = l_hand
del O
W.wielded = 0 //Kinda crude, but gets the job done with minimal pain -Agouri
W.name = "[initial(W.name)]" //name reset so people don't see world fireaxes with (unwielded) or (wielded) tags
W.update_icon()
if (W)
if(W.twohanded)
if(W.wielded)
if(hand)
var/obj/item/weapon/offhand/O = r_hand
del O
else
var/obj/item/weapon/offhand/O = l_hand
del O
W.wielded = 0 //Kinda crude, but gets the job done with minimal pain -Agouri
W.name = "[initial(W.name)]" //name reset so people don't see world fireaxes with (unwielded) or (wielded) tags
W.update_icon()
u_equip(W)
if (client)
client.screen -= W