From b3df8bf9f18fed0e74b6eaa9146bbfb232f4c02f Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Sun, 15 Nov 2020 21:44:28 +0100 Subject: [PATCH] [MIRROR] Two condiment fixes (#1697) * WHERE'S THE LAMB SAUUUUCE!? (#54937) Lets you use condiments on edible things, which includes the new food and food-based material things, also improves sauce packet feedback * Two condiment fixes Co-authored-by: ArcaneDefence <51932756+ArcaneDefence@users.noreply.github.com> --- code/modules/food_and_drinks/food/condiment.dm | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/code/modules/food_and_drinks/food/condiment.dm b/code/modules/food_and_drinks/food/condiment.dm index d84dffa1bb4..1381eaa7c01 100644 --- a/code/modules/food_and_drinks/food/condiment.dm +++ b/code/modules/food_and_drinks/food/condiment.dm @@ -82,7 +82,7 @@ to_chat(user, "You fill [src] with [trans] units of the contents of [target].") //Something like a glass or a food item. Player probably wants to transfer TO it. - else if(target.is_drainable() || istype(target, /obj/item/reagent_containers/food/snacks)) + else if(target.is_drainable() || IS_EDIBLE(target)) if(!reagents.total_volume) to_chat(user, "[src] is empty!") return @@ -244,12 +244,11 @@ return /obj/item/reagent_containers/food/condiment/pack/afterattack(obj/target, mob/user , proximity) - . = ..() if(!proximity) return //You can tear the bag open above food to put the condiments on it, obviously. - if(istype(target, /obj/item/reagent_containers/food/snacks)) + if(IS_EDIBLE(target)) if(!reagents.total_volume) to_chat(user, "You tear open [src], but there's nothing in it.") qdel(src) @@ -262,6 +261,8 @@ to_chat(user, "You tear open [src] above [target] and the condiments drip onto it.") src.reagents.trans_to(target, amount_per_transfer_from_this, transfered_by = user) qdel(src) + return + . = ..() /obj/item/reagent_containers/food/condiment/pack/on_reagent_change(changetype) if(reagents.reagent_list.len > 0)