Mob inventory cleanup

This commit is contained in:
Kelenius
2016-03-15 16:39:40 +03:00
parent 5104957ff8
commit afbc235b96
59 changed files with 432 additions and 390 deletions
+2 -2
View File
@@ -172,7 +172,7 @@
if(seed) seed.thrown_at(src,hit_atom)
..()
/obj/item/weapon/reagent_containers/food/snacks/grown/attackby(var/obj/item/weapon/W, var/mob/user)
/obj/item/weapon/reagent_containers/food/snacks/grown/attackby(var/obj/item/weapon/W, var/mob/living/user)
if(seed)
if(seed.get_trait(TRAIT_PRODUCES_POWER) && istype(W, /obj/item/stack/cable_coil))
@@ -181,7 +181,7 @@
//TODO: generalize this.
user << "<span class='notice'>You add some cable to the [src.name] and slide it inside the battery casing.</span>"
var/obj/item/weapon/cell/potato/pocell = new /obj/item/weapon/cell/potato(get_turf(user))
if(src.loc == user && !(user.l_hand && user.r_hand) && istype(user,/mob/living/carbon/human))
if(src.loc == user && istype(user,/mob/living/carbon/human))
user.put_in_hands(pocell)
pocell.maxcharge = src.potency * 10
pocell.charge = pocell.maxcharge
+2 -2
View File
@@ -150,7 +150,7 @@
var/body_coverage = HEAD|FACE|EYES|UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
for(var/obj/item/clothing/clothes in target)
if(target.l_hand == clothes|| target.r_hand == clothes)
if(target.item_is_in_hands(clothes))
continue
body_coverage &= ~(clothes.body_parts_covered)
@@ -182,7 +182,7 @@
continue
var/body_coverage = HEAD|FACE|EYES|UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
for(var/obj/item/clothing/clothes in M)
if(M.l_hand == clothes || M.r_hand == clothes)
if(M.item_is_in_hands(clothes))
continue
body_coverage &= ~(clothes.body_parts_covered)
if(!body_coverage)
+1 -1
View File
@@ -34,7 +34,7 @@
var/obj/item/weapon/paper/P = new /obj/item/weapon/paper(get_turf(src))
P.name = "paper - [form_title]"
P.info = "[last_data]"
if(istype(user,/mob/living/carbon/human) && !(user.l_hand && user.r_hand))
if(istype(user,/mob/living/carbon/human))
user.put_in_hands(P)
user.visible_message("\The [src] spits out a piece of paper.")
return