From 7ca1330749605122166f020e42d46b56b0d42e3d Mon Sep 17 00:00:00 2001 From: Fox-McCloud Date: Tue, 25 Oct 2016 16:46:41 -0400 Subject: [PATCH] further tweaks --- code/datums/recipe.dm | 12 +- code/modules/food_and_drinks/drinks/drinks.dm | 16 +-- .../food_and_drinks/drinks/drinks/bottle.dm | 12 +- .../food_and_drinks/drinks/drinks/cans.dm | 4 +- .../modules/food_and_drinks/food/condiment.dm | 4 +- .../food_and_drinks/food/customizables.dm | 39 ++----- code/modules/food_and_drinks/food/snacks.dm | 76 ++++++------ .../kitchen_machinery/gibber.dm | 16 +-- .../kitchen_machinery/icecream_vat_2.dm | 20 ++-- .../kitchen_machinery/juicer.dm | 18 +-- .../kitchen_machinery/kitchen_machine.dm | 108 +++++++++--------- .../kitchen_machinery/monkeyrecycler.dm | 12 +- .../food_and_drinks/kitchen_machinery/oven.dm | 4 +- .../kitchen_machinery/processor.dm | 24 ++-- .../kitchen_machinery/smartfridge.dm | 20 ++-- .../food_and_drinks/recipes/recipes_candy.dm | 2 +- .../food_and_drinks/recipes/recipes_grill.dm | 2 +- .../recipes/recipes_microwave.dm | 27 +++-- .../food_and_drinks/recipes/recipes_oven.dm | 34 +++--- 19 files changed, 218 insertions(+), 232 deletions(-) diff --git a/code/datums/recipe.dm b/code/datums/recipe.dm index 645af5e8aea..2e953f3ec91 100644 --- a/code/datums/recipe.dm +++ b/code/datums/recipe.dm @@ -42,7 +42,7 @@ var/byproduct // example: = /obj/item/weapon/kitchen/mould // byproduct to return, such as a mould or trash -/datum/recipe/proc/check_reagents(var/datum/reagents/avail_reagents) //1=precisely, 0=insufficiently, -1=superfluous +/datum/recipe/proc/check_reagents(datum/reagents/avail_reagents) //1=precisely, 0=insufficiently, -1=superfluous . = 1 for(var/r_r in reagents) var/aval_r_amnt = avail_reagents.get_reagent_amount(r_r) @@ -55,7 +55,7 @@ return -1 return . -/datum/recipe/proc/check_fruit(var/obj/container) +/datum/recipe/proc/check_fruit(obj/container) . = 1 if(fruit && fruit.len) var/list/checklist = list() @@ -74,7 +74,7 @@ break return . -/datum/recipe/proc/check_items(var/obj/container as obj) +/datum/recipe/proc/check_items(obj/container) . = 1 if(items && items.len) var/list/checklist = list() @@ -96,7 +96,7 @@ return . //general version -/datum/recipe/proc/make(var/obj/container as obj) +/datum/recipe/proc/make(obj/container) var/obj/result_obj = new result(container) for(var/obj/O in (container.contents-result_obj)) O.reagents.trans_to(result_obj, O.reagents.total_volume) @@ -106,7 +106,7 @@ return result_obj // food-related -/datum/recipe/proc/make_food(var/obj/container as obj) +/datum/recipe/proc/make_food(obj/container) var/obj/result_obj = new result(container) for(var/obj/O in (container.contents-result_obj)) if(O.reagents) @@ -118,7 +118,7 @@ score_meals++ return result_obj -/proc/select_recipe(var/list/datum/recipe/avaiable_recipes, var/obj/obj as obj, var/exact = 1 as num) +/proc/select_recipe(list/datum/recipe/avaiable_recipes, obj/obj, exact = 1) if(!exact) exact = -1 var/list/datum/recipe/possible_recipes = new diff --git a/code/modules/food_and_drinks/drinks/drinks.dm b/code/modules/food_and_drinks/drinks/drinks.dm index 15ce27b7d5c..0814bf988f4 100644 --- a/code/modules/food_and_drinks/drinks/drinks.dm +++ b/code/modules/food_and_drinks/drinks/drinks.dm @@ -81,7 +81,7 @@ refill = reagents.get_master_reagent_id() refillName = reagents.get_master_reagent_name() - var/trans = src.reagents.trans_to(target, amount_per_transfer_from_this) + var/trans = reagents.trans_to(target, amount_per_transfer_from_this) to_chat(user, " You transfer [trans] units of the solution to [target].") if(isrobot(user)) //Cyborg modules that include drinks automatically refill themselves, but drain the borg's cell @@ -102,22 +102,22 @@ if(istype(I, /obj/item/clothing/mask/cigarette)) //ciggies are weird return if(is_hot(I)) - if(src.reagents) - src.reagents.chem_temp += 15 + if(reagents) + reagents.chem_temp += 15 to_chat(user, "You heat [src] with [I].") - src.reagents.handle_reactions() + reagents.handle_reactions() /obj/item/weapon/reagent_containers/food/drinks/examine(mob/user) if(!..(user, 1)) return - if(!reagents || reagents.total_volume==0) + if(!reagents || reagents.total_volume == 0) to_chat(user, " \The [src] is empty!") - else if(reagents.total_volume<=src.volume/4) + else if(reagents.total_volume <= volume/4) to_chat(user, " \The [src] is almost empty!") - else if(reagents.total_volume<=src.volume*0.66) + else if(reagents.total_volume <= volume*0.66) to_chat(user, " \The [src] is half full!")// We're all optimistic, right?! - else if(reagents.total_volume<=src.volume*0.90) + else if(reagents.total_volume <= volume*0.90) to_chat(user, " \The [src] is almost full!") else to_chat(user, " \The [src] is full!") diff --git a/code/modules/food_and_drinks/drinks/drinks/bottle.dm b/code/modules/food_and_drinks/drinks/drinks/bottle.dm index 8928c5e8c57..7ee7509d8f1 100644 --- a/code/modules/food_and_drinks/drinks/drinks/bottle.dm +++ b/code/modules/food_and_drinks/drinks/drinks/bottle.dm @@ -22,9 +22,9 @@ else user.drop_item() user.put_in_active_hand(B) - B.icon_state = src.icon_state + B.icon_state = icon_state - var/icon/I = new('icons/obj/drinks.dmi', src.icon_state) + var/icon/I = new('icons/obj/drinks.dmi', icon_state) I.Blend(B.broken_outline, ICON_OVERLAY, rand(5), 1) I.SwapColor(rgb(255, 0, 220, 255), rgb(0, 0, 0, 0)) B.icon = I @@ -99,11 +99,11 @@ //Display an attack message. if(target != user) - target.visible_message("[user] has hit [target][head_attack_message] with a bottle of [src.name]!", \ - "[user] has hit [target][head_attack_message] with a bottle of [src.name]!") + target.visible_message("[user] has hit [target][head_attack_message] with a bottle of [name]!", \ + "[user] has hit [target][head_attack_message] with a bottle of [name]!") else - user.visible_message("[target] hits \himself with a bottle of [src.name][head_attack_message]!", \ - "[target] hits \himself with a bottle of [src.name][head_attack_message]!") + user.visible_message("[target] hits \himself with a bottle of [name][head_attack_message]!", \ + "[target] hits \himself with a bottle of [name][head_attack_message]!") //Attack logs add_logs(user, target, "attacked", src) diff --git a/code/modules/food_and_drinks/drinks/drinks/cans.dm b/code/modules/food_and_drinks/drinks/drinks/cans.dm index 6d72ec2221c..89deed5dedd 100644 --- a/code/modules/food_and_drinks/drinks/drinks/cans.dm +++ b/code/modules/food_and_drinks/drinks/drinks/cans.dm @@ -9,7 +9,7 @@ /obj/item/weapon/reagent_containers/food/drinks/cans/attack_self(mob/user) if(canopened == 0) - playsound(src.loc,'sound/effects/canopen.ogg', rand(10,50), 1) + playsound(loc,'sound/effects/canopen.ogg', rand(10,50), 1) to_chat(user, "You open the drink with an audible pop!") canopened = 1 flags |= OPENCONTAINER @@ -32,7 +32,7 @@ if(canopened == 0) to_chat(user, "You need to open the drink!") return - else if(M == user && !src.reagents.total_volume && user.a_intent == "harm" && user.zone_sel.selecting == "head") + else if(M == user && !reagents.total_volume && user.a_intent == "harm" && user.zone_sel.selecting == "head") user.visible_message("[user] crushes ["\the [src]"] on \his forehead!", "You crush \the [src] on your forehead.") crush(user) return diff --git a/code/modules/food_and_drinks/food/condiment.dm b/code/modules/food_and_drinks/food/condiment.dm index 931e84b892b..d7ffca96843 100644 --- a/code/modules/food_and_drinks/food/condiment.dm +++ b/code/modules/food_and_drinks/food/condiment.dm @@ -82,7 +82,7 @@ if(target.reagents.total_volume >= target.reagents.maximum_volume) to_chat(user, "you can't add anymore to [target]!") return - var/trans = src.reagents.trans_to(target, amount_per_transfer_from_this) + var/trans = reagents.trans_to(target, amount_per_transfer_from_this) to_chat(user, "You transfer [trans] units of the condiment to [target].") /obj/item/weapon/reagent_containers/food/condiment/on_reagent_change() @@ -223,7 +223,7 @@ return else 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) + reagents.trans_to(target, amount_per_transfer_from_this) qdel(src) /obj/item/weapon/reagent_containers/food/condiment/pack/on_reagent_change() diff --git a/code/modules/food_and_drinks/food/customizables.dm b/code/modules/food_and_drinks/food/customizables.dm index 66aee4b2616..77e3f22a1e8 100644 --- a/code/modules/food_and_drinks/food/customizables.dm +++ b/code/modules/food_and_drinks/food/customizables.dm @@ -1,4 +1,4 @@ -/obj/item/weapon/reagent_containers/food/snacks/breadslice/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/weapon/reagent_containers/food/snacks/breadslice/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/sandwich/S = new(get_turf(user)) S.attackby(W,user, params) @@ -6,13 +6,13 @@ else ..() -/obj/item/weapon/reagent_containers/food/snacks/bun/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/weapon/reagent_containers/food/snacks/bun/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/burger/S = new(get_turf(user)) S.attackby(W,user, params) qdel(src) -/obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/pizza/S = new(get_turf(user)) S.attackby(W,user, params) @@ -21,7 +21,7 @@ ..() -/obj/item/weapon/reagent_containers/food/snacks/boiledspagetti/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/weapon/reagent_containers/food/snacks/boiledspagetti/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/pasta/S = new(get_turf(user)) S.attackby(W,user, params) @@ -30,7 +30,7 @@ ..() -/obj/item/trash/plate/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/trash/plate/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/fullycustom/S = new(get_turf(user)) S.attackby(W,user, params) @@ -44,7 +44,7 @@ icon = 'icons/obj/food/food.dmi' icon_state = "soup" -/obj/item/trash/bowl/attackby(obj/item/W as obj, mob/user as mob, params) +/obj/item/trash/bowl/attackby(obj/item/W, mob/user, params) if(istype(W, /obj/item/weapon/reagent_containers/food/snacks) && !(W.flags & NODROP)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/soup/S = new(get_turf(user)) @@ -54,7 +54,6 @@ ..() /obj/item/weapon/reagent_containers/food/snacks/customizable/sandwich - /obj/item/weapon/reagent_containers/food/snacks/customizable name = "sandwich" desc = "A sandwich! A timeless classic." icon_state = "breadslice" @@ -318,7 +317,7 @@ toptype = new /obj/item/weapon/reagent_containers/food/snacks/bun() /obj/item/weapon/reagent_containers/food/snacks/customizable/attackby(obj/item/I, mob/user, params) - if(src.contents.len > sandwich_limit) + if(contents.len > sandwich_limit) to_chat(user, "If you put anything else in or on [src] it's going to make a mess.") return if(!istype(I, /obj/item/weapon/reagent_containers/food/snacks)) @@ -346,7 +345,7 @@ for(var/obj/item/O in ingredients) i++ if(!fullycustom) - var/image/I = new(src.icon, "[baseicon]_filling") + var/image/I = new(icon, "[baseicon]_filling") if(istype(O, /obj/item/weapon/reagent_containers/food/snacks)) var/obj/item/weapon/reagent_containers/food/snacks/food = O if(!food.filling_color == "#FFFFFF") @@ -367,7 +366,7 @@ overlays += O.overlays if(top) - var/image/T = new(src.icon, "[baseicon]_top") + var/image/T = new(icon, "[baseicon]_top") T.pixel_x = pick(list(-1,0,1)) T.pixel_y = (ingredients.len * 2)+1 overlays += T @@ -383,24 +382,6 @@ to_chat(user, " You think you can see [whatsinside] in there.") -/* -/obj/item/weapon/reagent_containers/food/snacks/customizable/attack(mob/M as mob, mob/user as mob, def_zone) //SNOOOOOOOWFLAAAAAAAAAAAAAAAAAKES - - var/obj/item/shard - for(var/obj/item/O in contents) - if(istype(O,/obj/item/weapon/shard)) - shard = O - break - - var/mob/living/H - if(istype(M,/mob/living)) - H = M - - if(H && shard && M == user) //This needs a check for feeding the food to other people, but that could be abusable. - to_chat(H, "\red You lacerate your mouth on a [shard.name] in the sandwich!") - H.adjustBruteLoss(5) //TODO: Target head if human. - ..() -*/ /obj/item/weapon/reagent_containers/food/snacks/customizable/proc/newname() var/unsorteditems[0] @@ -482,7 +463,7 @@ sendback = "[pick(list("absurd","colossal","enormous","ridiculous","massive","oversized","cardiac-arresting","pipe-clogging","edible but sickening","sickening","gargantuan","mega","belly-burster","chest-burster"))] [basename]" return sendback -/obj/item/weapon/reagent_containers/food/snacks/customizable/proc/sortlist(var/list/unsorted, var/highest) +/obj/item/weapon/reagent_containers/food/snacks/customizable/proc/sortlist(list/unsorted, highest) var/sorted[0] for(var/i = 1, i<= highest, i++) for(var/it in unsorted) diff --git a/code/modules/food_and_drinks/food/snacks.dm b/code/modules/food_and_drinks/food/snacks.dm index d11de1b06df..2bc089abaf1 100644 --- a/code/modules/food_and_drinks/food/snacks.dm +++ b/code/modules/food_and_drinks/food/snacks.dm @@ -63,11 +63,11 @@ if(bitecount==0) return else if(bitecount==1) - to_chat(user, "\blue \The [src] was bitten by someone!") + to_chat(user, "[src] was bitten by someone!") else if(bitecount<=3) - to_chat(user, "\blue \The [src] was bitten [bitecount] times!") + to_chat(user, "[src] was bitten [bitecount] times!") else - to_chat(user, "\blue \The [src] was bitten multiple times!") + to_chat(user, "[src] was bitten multiple times!") /obj/item/weapon/reagent_containers/food/snacks/attackby(obj/item/weapon/W, mob/user, params) @@ -92,10 +92,10 @@ "You scoop up some [src] with \the [U]!" \ ) - src.bitecount++ + bitecount++ U.overlays.Cut() var/image/I = new(U.icon, "loadedfood") - I.color = src.filling_color + I.color = filling_color U.overlays += I var/obj/item/weapon/reagent_containers/food/snacks/collected = new type @@ -135,7 +135,7 @@ else if(W.w_class <= 2 && istype(src,/obj/item/weapon/reagent_containers/food/snacks/sliceable)) if(!iscarbon(user)) return 1 - to_chat(user, "\red You slip [W] inside [src].") + to_chat(user, "You slip [W] inside [src].") user.unEquip(W) if((user.client && user.s_active != src)) user.client.screen -= W @@ -146,28 +146,28 @@ else return 1 if( \ - !isturf(src.loc) || \ - !(locate(/obj/structure/table) in src.loc) && \ - !(locate(/obj/machinery/optable) in src.loc) && \ - !(locate(/obj/item/weapon/storage/bag/tray) in src.loc) \ + !isturf(loc) || \ + !(locate(/obj/structure/table) in loc) && \ + !(locate(/obj/machinery/optable) in loc) && \ + !(locate(/obj/item/weapon/storage/bag/tray) in loc) \ ) - to_chat(user, "\red You cannot slice [src] here! You need a table or at least a tray to do it.") + to_chat(user, "You cannot slice [src] here! You need a table or at least a tray to do it.") return 1 var/slices_lost = 0 if(!inaccurate) user.visible_message( \ - "\blue [user] slices \the [src]!", \ - "\blue You slice \the [src]!" \ + "[user] slices [src]!", \ + "You slice [src]!" \ ) else user.visible_message( \ - "\blue [user] crudely slices \the [src] with [W]!", \ - "\blue You crudely slice \the [src] with your [W]!" \ + "[user] crudely slices [src] with [W]!", \ + "You crudely slice [src] with your [W]!" \ ) slices_lost = rand(1,min(1,round(slices_num/2))) var/reagents_per_slice = reagents.total_volume/slices_num for(var/i=1 to (slices_num-slices_lost)) - var/obj/slice = new slice_path (src.loc) + var/obj/slice = new slice_path (loc) reagents.trans_to(slice,reagents_per_slice) qdel(src) @@ -184,19 +184,19 @@ M.changeNext_move(CLICK_CD_MELEE) if(iscorgi(M)) if(bitecount >= 4) - M.visible_message("[M] [pick("burps from enjoyment", "yaps for more", "woofs twice", "looks at the area where \the [src] was")].","You swallow up the last part of \the [src].") - playsound(src.loc,'sound/items/eatfood.ogg', rand(10,50), 1) + M.visible_message("[M] [pick("burps from enjoyment", "yaps for more", "woofs twice", "looks at the area where [src] was")].","You swallow up the last part of [src].") + playsound(loc,'sound/items/eatfood.ogg', rand(10,50), 1) var/mob/living/simple_animal/pet/corgi/C = M C.adjustBruteLoss(-5) C.adjustFireLoss(-5) qdel(src) else - M.visible_message("[M] takes a bite of \the [src].","You take a bite of \the [src].") - playsound(src.loc,'sound/items/eatfood.ogg', rand(10,50), 1) + M.visible_message("[M] takes a bite of [src].","You take a bite of [src].") + playsound(loc,'sound/items/eatfood.ogg', rand(10,50), 1) bitecount++ else if(ismouse(M)) var/mob/living/simple_animal/mouse/N = M - to_chat(N, text("\blue You nibble away at [src].")) + to_chat(N, text("You nibble away at [src].")) if(prob(50)) N.visible_message("[N] nibbles away at [src].", "") //N.emote("nibbles away at the [src]") @@ -752,8 +752,8 @@ /obj/item/weapon/reagent_containers/food/snacks/pie/throw_impact(atom/hit_atom) ..() - new/obj/effect/decal/cleanable/pie_smudge(src.loc) - src.visible_message("\red [src.name] splats.","\red You hear a splat.") + new/obj/effect/decal/cleanable/pie_smudge(loc) + visible_message("[src] splats.","You hear a splat.") qdel(src) /obj/item/weapon/reagent_containers/food/snacks/berryclafoutis @@ -902,7 +902,7 @@ /obj/item/weapon/reagent_containers/food/snacks/popcorn/On_Consume(mob/M, mob/user) if(prob(unpopped)) //lol ...what's the point? - to_chat(user, "\red You bite down on an un-popped kernel!") + to_chat(user, "You bite down on an un-popped kernel!") unpopped = max(0, unpopped-1) ..() @@ -1728,9 +1728,9 @@ if(istype(W,/obj/item/weapon/kitchen/rollingpin)) user.visible_message( \ "[user] flattens the dough with the rolling pin!", \ - "\blue You flatten the dough with your rolling pin!" \ + "You flatten the dough with your rolling pin!" \ ) - new /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough(src.loc) + new /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough(loc) qdel(src) /////////////////////////////////////////////////Sliceable//////////////////////////////////////// @@ -2124,7 +2124,7 @@ "[user] cuts the raw cutlet with the knife!", \ "You cut the raw cutlet with your knife!" \ ) - new /obj/item/weapon/reagent_containers/food/snacks/raw_bacon(src.loc) + new /obj/item/weapon/reagent_containers/food/snacks/raw_bacon(loc) qdel(src) @@ -2264,8 +2264,8 @@ /obj/item/pizzabox/attack_hand(mob/user) if(open && pizza) user.put_in_hands(pizza) - to_chat(user, "\red You take the [src.pizza] out of the [src].") - src.pizza = null + to_chat(user, "You take the [pizza] out of the [src].") + pizza = null update_icon() return @@ -2278,7 +2278,7 @@ boxes -= box user.put_in_hands( box ) - to_chat(user, "\red You remove the topmost [src] from your hand.") + to_chat(user, "You remove the topmost [src] from your hand.") box.update_icon() update_icon() return @@ -2311,16 +2311,16 @@ box.loc = src box.boxes = list() // Clear the box boxes so we don't have boxes inside boxes. - Xzibit - src.boxes.Add( boxestoadd ) + boxes.Add( boxestoadd ) box.update_icon() update_icon() - to_chat(user, "\red You put the [box] ontop of the [src]!") + to_chat(user, "You put the [box] ontop of the [src]!") else - to_chat(user, "\red The stack is too high!") + to_chat(user, "The stack is too high!") else - to_chat(user, "\red Close the [box] first!") + to_chat(user, "Close the [box] first!") return @@ -2329,18 +2329,18 @@ if(open) user.drop_item() I.loc = src - src.pizza = I + pizza = I update_icon() - to_chat(user, "\red You put the [I] in the [src]!") + to_chat(user, "You put the [I] in the [src]!") else - to_chat(user, "\red You try to push the [I] through the lid but it doesn't work!") + to_chat(user, "You try to push the [I] through the lid but it doesn't work!") return if(istype(I, /obj/item/weapon/pen/)) - if( src.open ) + if(open) return var/t = input("Enter what you want to add to the tag:", "Write", null, null) as text diff --git a/code/modules/food_and_drinks/kitchen_machinery/gibber.dm b/code/modules/food_and_drinks/kitchen_machinery/gibber.dm index b71bb0be2d4..b95f85bf03b 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/gibber.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/gibber.dm @@ -126,7 +126,7 @@ return user.visible_message("[user] starts to put [victim] into the gibber!") - src.add_fingerprint(user) + add_fingerprint(user) if(do_after(user, 30, target = victim) && user.Adjacent(src) && victim.Adjacent(user) && !occupant) user.visible_message("[user] stuffs [victim] into the gibber!") @@ -155,7 +155,7 @@ return for(var/obj/O in src) - O.loc = src.loc + O.loc = loc occupant.forceMove(get_turf(src)) occupant = null @@ -212,11 +212,11 @@ /obj/machinery/gibber/proc/startgibbing(var/mob/user, var/UserOverride=0) if(!istype(user) && !UserOverride) - log_debug("Some shit just went down with the gibber at X[x], Y[y], Z[z] with an invalid user. (JMP)") + log_debug("Some shit just went down with the gibber at X[x], Y[y], Z[z] with an invalid user. (JMP)") return if(UserOverride) - msg_admin_attack("[key_name_admin(occupant)] was gibbed by an autogibber (\the [src]) (JMP)") + msg_admin_attack("[key_name_admin(occupant)] was gibbed by an autogibber (\the [src]) (JMP)") if(operating) return @@ -236,7 +236,7 @@ var/slab_name = occupant.name var/slab_count = 3 var/slab_type = /obj/item/weapon/reagent_containers/food/snacks/meat/human //gibber can only gib humans on paracode, no need to check meat type - var/slab_nutrition = src.occupant.nutrition / 15 + var/slab_nutrition = occupant.nutrition / 15 slab_nutrition /= slab_count @@ -367,7 +367,7 @@ if(O.flags & NODROP) qdel(O) //they are already dead by now H.unEquip(O) - O.loc = src.loc + O.loc = loc O.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) sleep(1) @@ -375,7 +375,7 @@ if(C.flags & NODROP) qdel(C) H.unEquip(C) - C.loc = src.loc + C.loc = loc C.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) sleep(1) @@ -385,7 +385,7 @@ var/spats = 0 //keeps track of how many items get spit out. Don't show a message if none are found. for(var/obj/O in src) if(istype(O)) - O.loc = src.loc + O.loc = loc O.throw_at(get_edge_target_turf(src,gib_throw_dir),rand(1,5),15) spats++ sleep(1) diff --git a/code/modules/food_and_drinks/kitchen_machinery/icecream_vat_2.dm b/code/modules/food_and_drinks/kitchen_machinery/icecream_vat_2.dm index f0fb01efad2..ac79371f06e 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/icecream_vat_2.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/icecream_vat_2.dm @@ -99,7 +99,7 @@ var/list/ingredients_source = list( if(ingredients[ICECREAM_VANILLA] > 0) var/flavour_name = get_icecream_flavour_string(dispense_flavour) if(dispense_flavour < 11 && ingredients[dispense_flavour] > 0) - src.visible_message("[bicon(src)] [user] scoops delicious [flavour_name] flavoured icecream into [I].") + visible_message("[bicon(src)] [user] scoops delicious [flavour_name] flavoured icecream into [I].") ingredients[dispense_flavour] -= 1 ingredients[ICECREAM_VANILLA] -= 1 @@ -127,7 +127,7 @@ var/list/ingredients_source = list( else var/obj/item/weapon/reagent_containers/R = O if(R.reagents) - src.visible_message("[user] has emptied all of [R] into [src].") + visible_message("[user] has emptied all of [R] into [src].") for(var/datum/reagent/current_reagent in R.reagents.reagent_list) if(ingredients_source[current_reagent.id]) add(ingredients_source[current_reagent.id], current_reagent.volume / 2) @@ -151,7 +151,7 @@ var/list/ingredients_source = list( ingredients[INGR_FLOUR] -= amount ingredients[INGR_SUGAR] -= amount ingredients[CONE_WAFFLE] += amount - src.visible_message("[user] cooks up some waffle cones.") + visible_message("[user] cooks up some waffle cones.") else to_chat(user, "You require sugar and flour to make waffle cones.") if(CONE_CHOC) @@ -160,7 +160,7 @@ var/list/ingredients_source = list( ingredients[CONE_WAFFLE] -= amount ingredients[FLAVOUR_CHOCOLATE] -= amount ingredients[CONE_CHOC] += amount - src.visible_message("[user] cooks up some chocolate cones.") + visible_message("[user] cooks up some chocolate cones.") else to_chat(user, "You require waffle cones and chocolate flavouring to make chocolate cones.") if(ICECREAM_VANILLA) @@ -169,7 +169,7 @@ var/list/ingredients_source = list( ingredients[INGR_ICE] -= amount ingredients[INGR_MILK] -= amount ingredients[ICECREAM_VANILLA] += amount - src.visible_message("[user] whips up some vanilla icecream.") + visible_message("[user] whips up some vanilla icecream.") else to_chat(user, "You require milk and ice to make vanilla icecream.") updateDialog() @@ -179,7 +179,7 @@ var/list/ingredients_source = list( return if(href_list["dispense"]) dispense_flavour = text2num(href_list["dispense"]) - src.visible_message("\blue[usr] sets [src] to dispense [get_icecream_flavour_string(dispense_flavour)] flavoured icecream.") + visible_message("\blue[usr] sets [src] to dispense [get_icecream_flavour_string(dispense_flavour)] flavoured icecream.") if(href_list["cone"]) var/dispense_cone = text2num(href_list["cone"]) @@ -187,11 +187,11 @@ var/list/ingredients_source = list( var/cone_name = get_icecream_flavour_string(dispense_cone) if(ingredients[dispense_cone] >= 1) ingredients[dispense_cone] -= 1 - var/obj/item/weapon/reagent_containers/food/snacks/icecream/I = new(src.loc) + var/obj/item/weapon/reagent_containers/food/snacks/icecream/I = new(loc) I.cone_type = cone_name I.icon_state = "icecream_cone_[cone_name]" I.desc = "Delicious [cone_name] cone, but no ice cream." - src.visible_message("[usr] dispenses a crunchy [cone_name] cone from [src].") + visible_message("[usr] dispenses a crunchy [cone_name] cone from [src].") else to_chat(usr, "There are no [cone_name] cones left!") updateDialog() @@ -202,7 +202,7 @@ var/list/ingredients_source = list( if(href_list["eject"]) if(held_container) - held_container.forceMove(src.loc) + held_container.forceMove(loc) held_container = null updateDialog() @@ -231,7 +231,7 @@ var/list/ingredients_source = list( /obj/item/weapon/reagent_containers/food/snacks/icecream/proc/add_ice_cream(var/flavour) var/flavour_name = get_icecream_flavour_string(flavour) name = "[flavour_name] icecream" - src.overlays += "icecream_[flavour_name]" + overlays += "icecream_[flavour_name]" desc = "Delicious [cone_type] cone with a dollop of [flavour_name] ice cream." ice_creamed = 1 diff --git a/code/modules/food_and_drinks/kitchen_machinery/juicer.dm b/code/modules/food_and_drinks/kitchen_machinery/juicer.dm index e1cb054690f..ba791d3f28f 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/juicer.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/juicer.dm @@ -46,9 +46,9 @@ return 0 O.forceMove(src) beaker = O - src.verbs += /obj/machinery/juicer/verb/detach + verbs += /obj/machinery/juicer/verb/detach update_icon() - src.updateUsrDialog() + updateUsrDialog() return 0 if(!is_type_in_list(O, allowed_items)) to_chat(user, "It doesn't look like that contains any juice.") @@ -57,7 +57,7 @@ to_chat(user, "\the [O] is stuck to your hand, you cannot put it in \the [src]") return 0 O.forceMove(src) - src.updateUsrDialog() + updateUsrDialog() return 0 /obj/machinery/juicer/attack_ai(mob/user as mob) @@ -74,7 +74,7 @@ var/beaker_contents = "" for(var/i in allowed_items) - for(var/obj/item/O in src.contents) + for(var/obj/item/O in contents) if(!istype(O,i)) continue processing_chamber+= "some [O]
" @@ -119,7 +119,7 @@ if("detach") detach() - src.updateUsrDialog() + updateUsrDialog() return /obj/machinery/juicer/verb/detach() @@ -130,8 +130,8 @@ return if(!beaker) return - src.verbs -= /obj/machinery/juicer/verb/detach - beaker.forceMove(src.loc) + verbs -= /obj/machinery/juicer/verb/detach + beaker.forceMove(loc) beaker = null update_icon() @@ -159,8 +159,8 @@ return if(!beaker || beaker.reagents.total_volume >= beaker.reagents.maximum_volume) return - playsound(src.loc, 'sound/machines/juicer.ogg', 50, 1) - for(var/obj/item/weapon/reagent_containers/food/snacks/O in src.contents) + playsound(loc, 'sound/machines/juicer.ogg', 50, 1) + for(var/obj/item/weapon/reagent_containers/food/snacks/O in contents) var/r_id = get_juice_id(O) beaker.reagents.add_reagent(r_id,get_juice_amount(O)) qdel(O) diff --git a/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm b/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm index 648f228bb54..ed9e1b2117b 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/kitchen_machine.dm @@ -77,8 +77,8 @@ default_deconstruction_crowbar(O) - if(src.broken > 0) - if(src.broken == 2 && istype(O, /obj/item/weapon/screwdriver)) // If it's broken and they're using a screwdriver + if(broken > 0) + if(broken == 2 && istype(O, /obj/item/weapon/screwdriver)) // If it's broken and they're using a screwdriver user.visible_message( \ "[user] starts to fix part of \the [src].", \ "You start to fix part of \the [src]." \ @@ -88,8 +88,8 @@ "[user] fixes part of \the [src].", \ "You have fixed part of \the [src]." \ ) - src.broken = 1 // Fix it a bit - else if(src.broken == 1 && istype(O, /obj/item/weapon/wrench)) // If it's broken and they're doing the wrench + broken = 1 // Fix it a bit + else if(broken == 1 && istype(O, /obj/item/weapon/wrench)) // If it's broken and they're doing the wrench user.visible_message( \ "[user] starts to fix part of \the [src].", \ "You start to fix part of \the [src]." \ @@ -99,14 +99,14 @@ "[user] fixes \the [src].", \ "You have fixed \the [src]." \ ) - src.icon_state = off_icon - src.broken = 0 // Fix it! - src.dirty = 0 // just to be sure - src.flags = OPENCONTAINER + icon_state = off_icon + broken = 0 // Fix it! + dirty = 0 // just to be sure + flags = OPENCONTAINER else to_chat(user, "It's broken!") return 1 - else if(src.dirty==100) // The machine is all dirty so can't be used! + else if(dirty==100) // The machine is all dirty so can't be used! if(istype(O, /obj/item/weapon/reagent_containers/spray/cleaner) || istype(O, /obj/item/weapon/soap)) // If they're trying to clean it then let them user.visible_message( \ "[user] starts to clean \the [src].", \ @@ -117,10 +117,10 @@ "[user] has cleaned \the [src].", \ "You have cleaned \the [src]." \ ) - src.dirty = 0 // It's clean! - src.broken = 0 // just to be sure - src.icon_state = off_icon - src.flags = OPENCONTAINER + dirty = 0 // It's clean! + broken = 0 // just to be sure + icon_state = off_icon + flags = OPENCONTAINER else //Otherwise bad luck!! to_chat(user, "It's dirty!") return 1 @@ -161,7 +161,7 @@ else to_chat(user, "You have no idea what you can cook with this [O].") return 1 - src.updateUsrDialog() + updateUsrDialog() /obj/machinery/kitchen_machine/attack_ai(mob/user as mob) return 0 @@ -178,11 +178,11 @@ if(panel_open || !anchored) return var/dat = "" - if(src.broken > 0) + if(broken > 0) dat = {"Bzzzzttttt"} - else if(src.operating) - dat = {"[pick(src.cook_verbs)] in progress!
Please wait...!
"} - else if(src.dirty==100) + else if(operating) + dat = {"[pick(cook_verbs)] in progress!
Please wait...!
"} + else if(dirty==100) dat = {"This [src] is dirty!
Please clean it before use!
"} else var/list/items_counts = new @@ -237,7 +237,7 @@ var/datum/browser/popup = new(user, name, name, 400, 400) popup.set_content(dat) popup.open(0) - onclose(user, "[src.name]") + onclose(user, "[name]") return @@ -298,7 +298,7 @@ byproduct = recipe.get_byproduct() stop() if(cooked) - cooked.forceMove(src.loc) + cooked.forceMove(loc) for(var/i=1,i\The [src] turns on.
", "You hear \a [src].") - src.operating = 1 - src.icon_state = on_icon - src.updateUsrDialog() + visible_message("\The [src] turns on.", "You hear \a [src].") + operating = 1 + icon_state = on_icon + updateUsrDialog() /obj/machinery/kitchen_machine/proc/abort() - src.operating = 0 // Turn it off again aferwards - src.icon_state = off_icon - src.updateUsrDialog() + operating = 0 // Turn it off again aferwards + icon_state = off_icon + updateUsrDialog() /obj/machinery/kitchen_machine/proc/stop() - playsound(src.loc, 'sound/machines/ding.ogg', 50, 1) - src.operating = 0 // Turn it off again aferwards - src.icon_state = off_icon - src.updateUsrDialog() + playsound(loc, 'sound/machines/ding.ogg', 50, 1) + operating = 0 // Turn it off again aferwards + icon_state = off_icon + updateUsrDialog() /obj/machinery/kitchen_machine/proc/dispose() for(var/obj/O in contents) - O.forceMove(src.loc) - if(src.reagents.total_volume) - src.dirty++ - src.reagents.clear_reagents() + O.forceMove(loc) + if(reagents.total_volume) + dirty++ + reagents.clear_reagents() to_chat(usr, "You dispose of \the [src]'s contents.") - src.updateUsrDialog() + updateUsrDialog() /obj/machinery/kitchen_machine/proc/muck_start() - playsound(src.loc, 'sound/effects/splat.ogg', 50, 1) // Play a splat sound - src.icon_state = dirty_icon // Make it look dirty!! + playsound(loc, 'sound/effects/splat.ogg', 50, 1) // Play a splat sound + icon_state = dirty_icon // Make it look dirty!! /obj/machinery/kitchen_machine/proc/muck_finish() - playsound(src.loc, 'sound/machines/ding.ogg', 50, 1) - src.visible_message("\The [src] gets covered in muck!") - src.dirty = 100 // Make it dirty so it can't be used util cleaned - src.flags = null //So you can't add condiments - src.icon_state = dirty_icon // Make it look dirty too - src.operating = 0 // Turn it off again aferwards - src.updateUsrDialog() + playsound(loc, 'sound/machines/ding.ogg', 50, 1) + visible_message("\The [src] gets covered in muck!") + dirty = 100 // Make it dirty so it can't be used util cleaned + flags = null //So you can't add condiments + icon_state = dirty_icon // Make it look dirty too + operating = 0 // Turn it off again aferwards + updateUsrDialog() /obj/machinery/kitchen_machine/proc/broke() var/datum/effect/system/spark_spread/s = new s.set_up(2, 1, src) s.start() - src.icon_state = broken_icon // Make it look all busted up and shit - src.visible_message("The [src] breaks!") //Let them know they're stupid - src.broken = 2 // Make it broken so it can't be used util fixed - src.flags = null //So you can't add condiments - src.operating = 0 // Turn it off again aferwards - src.updateUsrDialog() + icon_state = broken_icon // Make it look all busted up and shit + visible_message("The [src] breaks!") //Let them know they're stupid + broken = 2 // Make it broken so it can't be used util fixed + flags = null //So you can't add condiments + operating = 0 // Turn it off again aferwards + updateUsrDialog() /obj/machinery/kitchen_machine/proc/fail() var/obj/item/weapon/reagent_containers/food/snacks/badrecipe/ffuu = new(src) @@ -382,7 +382,7 @@ if(id) amount+=O.reagents.get_reagent_amount(id) qdel(O) - src.reagents.clear_reagents() + reagents.clear_reagents() ffuu.reagents.add_reagent("carbon", amount) ffuu.reagents.add_reagent("????", amount/10) ffuu.forceMove(get_turf(src)) @@ -392,8 +392,8 @@ return usr.set_machine(src) - if(src.operating) - src.updateUsrDialog() + if(operating) + updateUsrDialog() return switch(href_list["action"]) diff --git a/code/modules/food_and_drinks/kitchen_machinery/monkeyrecycler.dm b/code/modules/food_and_drinks/kitchen_machinery/monkeyrecycler.dm index dc283e65d6c..edf4963c607 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/monkeyrecycler.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/monkeyrecycler.dm @@ -62,7 +62,7 @@ cycle_through = 0 to_chat(user, "You change the monkeycube type to [initial(cube_type.name)].") - if(src.stat != 0) //NOPOWER etc + if(stat != 0) //NOPOWER etc return if(istype(O, /obj/item/weapon/grab)) var/obj/item/weapon/grab/G = O @@ -76,11 +76,11 @@ user.drop_item() qdel(target) to_chat(user, "You stuff the monkey in the machine.") - playsound(src.loc, 'sound/machines/juicer.ogg', 50, 1) + playsound(loc, 'sound/machines/juicer.ogg', 50, 1) var/offset = prob(50) ? -2 : 2 animate(src, pixel_x = pixel_x + offset, time = 0.2, loop = 200) //start shaking use_power(500) - src.grinded++ + grinded++ sleep(50) pixel_x = initial(pixel_x) to_chat(user, "The machine now has [grinded] monkey\s worth of material stored.") @@ -91,14 +91,14 @@ return /obj/machinery/monkey_recycler/attack_hand(var/mob/user as mob) - if(src.stat != 0) //NOPOWER etc + if(stat != 0) //NOPOWER etc return if(grinded >= required_grind) to_chat(user, "The machine hisses loudly as it condenses the grinded monkey meat. After a moment, it dispenses a brand new monkey cube.") - playsound(src.loc, 'sound/machines/hiss.ogg', 50, 1) + playsound(loc, 'sound/machines/hiss.ogg', 50, 1) grinded -= required_grind for(var/i = 0, i < cube_production, i++) // Forgot to fix this bit the first time through - new cube_type(src.loc) + new cube_type(loc) to_chat(user, "The machine's display flashes that it has [grinded] monkey\s worth of material left.") else // I'm not sure if the \s macro works with a word in between; I'll play it safe to_chat(user, "The machine needs at least [required_grind] monkey\s worth of material to compress [cube_production] monkey\s. It only has [grinded].") diff --git a/code/modules/food_and_drinks/kitchen_machinery/oven.dm b/code/modules/food_and_drinks/kitchen_machinery/oven.dm index 796e8c4bd4b..6a47eb94ff5 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/oven.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/oven.dm @@ -60,7 +60,7 @@ food_choices.Remove(U) for(var/U in subtypesof(/obj/item/weapon/reagent_containers/food/snacks/customizable/cook)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/cook/V = new U - src.food_choices += V + food_choices += V return /obj/machinery/cooking/candy @@ -75,5 +75,5 @@ food_choices.Remove(U) for(var/U in subtypesof(/obj/item/weapon/reagent_containers/food/snacks/customizable/candy)) var/obj/item/weapon/reagent_containers/food/snacks/customizable/candy/V = new U - src.food_choices += V + food_choices += V return diff --git a/code/modules/food_and_drinks/kitchen_machinery/processor.dm b/code/modules/food_and_drinks/kitchen_machinery/processor.dm index d2b810dc7bb..2075524c3d2 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/processor.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/processor.dm @@ -58,9 +58,9 @@ var/time = 40 /datum/food_processor_process/proc/process_food(loc, what, obj/machinery/processor/processor) - if(src.output && loc && processor) + if(output && loc && processor) for(var/i = 0, i < processor.rating_amount, i++) - new src.output(loc) + new output(loc) if(what) qdel(what) @@ -156,7 +156,7 @@ /obj/machinery/processor/attackby(var/obj/item/O as obj, var/mob/user as mob, params) - if(src.processing) + if(processing) to_chat(user, "\the [src] is already processing something!") return 1 @@ -195,21 +195,21 @@ if(stat & (NOPOWER|BROKEN)) //no power or broken return - if(src.processing) + if(processing) to_chat(user, "\the [src] is already processing something!") return 1 - if(src.contents.len == 0) + if(contents.len == 0) to_chat(user, "\the [src] is empty.") return 1 - src.processing = 1 + processing = 1 user.visible_message("[user] turns on [src].", \ "You turn on [src].", \ "You hear a food processor.") - playsound(src.loc, 'sound/machines/blender.ogg', 50, 1) + playsound(loc, 'sound/machines/blender.ogg', 50, 1) use_power(500) var/total_time = 0 - for(var/O in src.contents) + for(var/O in contents) var/datum/food_processor_process/P = select_recipe(O) if(!P) log_debug("The [O] in processor([src]) does not have a suitable recipe, but it was somehow put inside of the processor anyways.") @@ -217,14 +217,14 @@ total_time += P.time sleep(total_time / rating_speed) - for(var/O in src.contents) + for(var/O in contents) var/datum/food_processor_process/P = select_recipe(O) if(!P) log_debug("The [O] in processor([src]) does not have a suitable recipe, but it was somehow put inside of the processor anyways.") continue - P.process_food(src.loc, O, src) - src.processing = 0 + P.process_food(loc, O, src) + processing = 0 - src.visible_message("\the [src] has finished processing.", \ + visible_message("\the [src] has finished processing.", \ "\the [src] has finished processing.", \ "You hear a food processor stopping.") diff --git a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm index c6f7e54a003..0a2a357ea92 100644 --- a/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm +++ b/code/modules/food_and_drinks/kitchen_machinery/smartfridge.dm @@ -170,10 +170,10 @@ /obj/machinery/smartfridge/process() if(stat & (BROKEN|NOPOWER)) return - if(src.seconds_electrified > 0) - src.seconds_electrified-- - if(src.shoot_inventory && prob(2)) - src.throw_item() + if(seconds_electrified > 0) + seconds_electrified-- + if(shoot_inventory && prob(2)) + throw_item() /obj/machinery/smartfridge/power_change() var/old_stat = stat @@ -194,7 +194,7 @@ /obj/machinery/smartfridge/attackby(var/obj/item/O as obj, var/mob/user as mob) if(istype(O, /obj/item/weapon/screwdriver) && anchored) - playsound(src.loc, 'sound/items/Screwdriver.ogg', 50, 1) + playsound(loc, 'sound/items/Screwdriver.ogg', 50, 1) panel_open = !panel_open to_chat(user, "You [panel_open ? "open" : "close"] the maintenance panel.") overlays.Cut() @@ -275,7 +275,7 @@ return 0 /obj/machinery/smartfridge/attack_ghost(mob/user as mob) - return src.attack_hand(user) + return attack_hand(user) /obj/machinery/smartfridge/attack_hand(mob/user as mob) if(stat & (NOPOWER|BROKEN)) @@ -336,7 +336,7 @@ ui = nanomanager.try_update_ui(user, src, ui_key, ui, data, force_open) if(!ui) - ui = new(user, src, ui_key, "smartfridge.tmpl", src.name, 400, 500) + ui = new(user, src, ui_key, "smartfridge.tmpl", name, 400, 500) ui.set_initial_data(data) ui.open() @@ -346,7 +346,7 @@ var/mob/user = usr var/datum/nanoui/ui = nanomanager.get_open_ui(user, src, "main") - src.add_fingerprint(user) + add_fingerprint(user) if(href_list["close"]) user.unset_machine() @@ -387,7 +387,7 @@ item_quants[O]-- for(var/obj/T in contents) if(T.name == O) - T.forceMove(src.loc) + T.forceMove(loc) throw_item = T break break @@ -395,7 +395,7 @@ return 0 spawn(0) throw_item.throw_at(target,16,3,src) - src.visible_message("[src] launches [throw_item.name] at [target.name]!") + visible_message("[src] launches [throw_item.name] at [target.name]!") return 1 /************************ diff --git a/code/modules/food_and_drinks/recipes/recipes_candy.dm b/code/modules/food_and_drinks/recipes/recipes_candy.dm index 55c5df55328..98f969a17ec 100644 --- a/code/modules/food_and_drinks/recipes/recipes_candy.dm +++ b/code/modules/food_and_drinks/recipes/recipes_candy.dm @@ -79,7 +79,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/candy/nougat /datum/recipe/candy/nougat/make_food(obj/container) - var/obj/item/weapon/reagent_containers/food/snacks/candy/nougat/being_cooked = ..(container) + var/obj/item/weapon/reagent_containers/food/snacks/candy/nougat/being_cooked = ..() being_cooked.reagents.del_reagent("egg") return being_cooked diff --git a/code/modules/food_and_drinks/recipes/recipes_grill.dm b/code/modules/food_and_drinks/recipes/recipes_grill.dm index 52be26f37b5..5845e860c9d 100644 --- a/code/modules/food_and_drinks/recipes/recipes_grill.dm +++ b/code/modules/food_and_drinks/recipes/recipes_grill.dm @@ -90,7 +90,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/fishfingers /datum/recipe/grill/fishfingers/make_food(obj/container) - var/obj/item/weapon/reagent_containers/food/snacks/fishfingers/being_cooked = ..(container) + var/obj/item/weapon/reagent_containers/food/snacks/fishfingers/being_cooked = ..() being_cooked.reagents.del_reagent("egg") return being_cooked diff --git a/code/modules/food_and_drinks/recipes/recipes_microwave.dm b/code/modules/food_and_drinks/recipes/recipes_microwave.dm index 0f58955a2bf..5903e191b4e 100644 --- a/code/modules/food_and_drinks/recipes/recipes_microwave.dm +++ b/code/modules/food_and_drinks/recipes/recipes_microwave.dm @@ -205,10 +205,11 @@ reagents = list("water" = 5, "vodka" = 5) fruit = list("amanita" = 3) result = /obj/item/weapon/reagent_containers/food/snacks/amanitajelly - make_food(var/obj/container as obj) - var/obj/item/weapon/reagent_containers/food/snacks/amanitajelly/being_cooked = ..(container) - being_cooked.reagents.del_reagent("amanitin") - return being_cooked + +/datum/recipe/microwave/amanitajelly/make_food(obj/container) + var/obj/item/weapon/reagent_containers/food/snacks/amanitajelly/being_cooked = ..() + being_cooked.reagents.del_reagent("amanitin") + return being_cooked /datum/recipe/microwave/meatballsoup reagents = list("water" = 10) @@ -538,10 +539,11 @@ datum/recipe/microwave/slimesandwich /datum/recipe/microwave/herbsalad fruit = list("ambrosia" = 3, "apple" = 1) result = /obj/item/weapon/reagent_containers/food/snacks/herbsalad - make_food(var/obj/container as obj) - var/obj/item/weapon/reagent_containers/food/snacks/herbsalad/being_cooked = ..(container) - being_cooked.reagents.del_reagent("toxin") - return being_cooked + +/datum/recipe/microwave/herbsalad/make_food(obj/container) + var/obj/item/weapon/reagent_containers/food/snacks/herbsalad/being_cooked = ..() + being_cooked.reagents.del_reagent("toxin") + return being_cooked /datum/recipe/microwave/aesirsalad fruit = list("ambrosiadeus" = 3, "goldapple" = 1) @@ -553,10 +555,11 @@ datum/recipe/microwave/slimesandwich /obj/item/weapon/reagent_containers/food/snacks/meatball, ) result = /obj/item/weapon/reagent_containers/food/snacks/validsalad - make_food(var/obj/container as obj) - var/obj/item/weapon/reagent_containers/food/snacks/validsalad/being_cooked = ..(container) - being_cooked.reagents.del_reagent("toxin") - return being_cooked + +/datum/recipe/microwave/validsalad/make_food(obj/container) + var/obj/item/weapon/reagent_containers/food/snacks/validsalad/being_cooked = ..() + being_cooked.reagents.del_reagent("toxin") + return being_cooked ////////////////////////////FOOD ADDITTIONS/////////////////////////////// diff --git a/code/modules/food_and_drinks/recipes/recipes_oven.dm b/code/modules/food_and_drinks/recipes/recipes_oven.dm index 37af56e8ad4..d20c06e260f 100644 --- a/code/modules/food_and_drinks/recipes/recipes_oven.dm +++ b/code/modules/food_and_drinks/recipes/recipes_oven.dm @@ -176,20 +176,22 @@ /obj/item/weapon/paper, ) result = /obj/item/weapon/reagent_containers/food/snacks/fortunecookie - make_food(var/obj/container as obj) + +/datum/recipe/oven/fortunecookie/make_food(obj/container) + var/obj/item/weapon/paper/paper = locate() in container + paper.loc = null //prevent deletion + var/obj/item/weapon/reagent_containers/food/snacks/fortunecookie/being_cooked = ..() + paper.loc = being_cooked + being_cooked.trash = paper //so the paper is left behind as trash without special-snowflake(TM Nodrak) code ~carn + return being_cooked + +/datum/recipe/oven/fortunecookie/check_items(obj/container) + . = ..() + if(.) var/obj/item/weapon/paper/paper = locate() in container - paper.loc = null //prevent deletion - var/obj/item/weapon/reagent_containers/food/snacks/fortunecookie/being_cooked = ..(container) - paper.loc = being_cooked - being_cooked.trash = paper //so the paper is left behind as trash without special-snowflake(TM Nodrak) code ~carn - return being_cooked - check_items(var/obj/container as obj) - . = ..() - if(.) - var/obj/item/weapon/paper/paper = locate() in container - if(!paper || !paper.info) - return -1 - return . + if(!paper || !paper.info) + return -1 + return . /datum/recipe/oven/pizzamargherita fruit = list("tomato" = 1) @@ -294,7 +296,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/sliceable/bread /datum/recipe/oven/bread/make_food(obj/container) - var/obj/item/weapon/reagent_containers/food/snacks/sliceable/bread/being_cooked = ..(container) + var/obj/item/weapon/reagent_containers/food/snacks/sliceable/bread/being_cooked = ..() being_cooked.reagents.del_reagent("egg") return being_cooked @@ -383,7 +385,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/appletart /datum/recipe/oven/appletart/make_food(obj/container) - var/obj/item/weapon/reagent_containers/food/snacks/appletart/being_cooked = ..(container) + var/obj/item/weapon/reagent_containers/food/snacks/appletart/being_cooked = ..() being_cooked.reagents.del_reagent("egg") return being_cooked @@ -403,7 +405,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/sugarcookie /datum/recipe/oven/sugarcookie/make_food(obj/container) - var/obj/item/weapon/reagent_containers/food/snacks/sugarcookie/being_cooked = ..(container) + var/obj/item/weapon/reagent_containers/food/snacks/sugarcookie/being_cooked = ..() being_cooked.reagents.del_reagent("egg") return being_cooked