diff --git a/code/_helpers/type2type.dm b/code/_helpers/type2type.dm index 18a94a501d..77019ab7b9 100644 --- a/code/_helpers/type2type.dm +++ b/code/_helpers/type2type.dm @@ -281,3 +281,103 @@ return strtype return copytext(strtype, delim_pos) +// Concatenates a list of strings into a single string. A seperator may optionally be provided. +/proc/list2text(list/ls, sep) + if (ls.len <= 1) // Early-out code for empty or singleton lists. + return ls.len ? ls[1] : "" + + var/l = ls.len // Made local for sanic speed. + var/i = 0 // Incremented every time a list index is accessed. + + if (sep != null) + // Macros expand to long argument lists like so: sep, ls[++i], sep, ls[++i], sep, ls[++i], etc... + #define S1 sep, ls[++i] + #define S4 S1, S1, S1, S1 + #define S16 S4, S4, S4, S4 + #define S64 S16, S16, S16, S16 + + . = "[ls[++i]]" // Make sure the initial element is converted to text. + + // Having the small concatenations come before the large ones boosted speed by an average of at least 5%. + if (l-1 & 0x01) // 'i' will always be 1 here. + . = text("[][][]", ., S1) // Append 1 element if the remaining elements are not a multiple of 2. + if (l-i & 0x02) + . = text("[][][][][]", ., S1, S1) // Append 2 elements if the remaining elements are not a multiple of 4. + if (l-i & 0x04) + . = text("[][][][][][][][][]", ., S4) // And so on.... + if (l-i & 0x08) + . = text("[][][][][][][][][][][][][][][][][]", ., S4, S4) + if (l-i & 0x10) + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16) + if (l-i & 0x20) + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16, S16) + if (l-i & 0x40) + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64) + while (l > i) // Chomp through the rest of the list, 128 elements at a time. + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64, S64) + + #undef S64 + #undef S16 + #undef S4 + #undef S1 + else + // Macros expand to long argument lists like so: ls[++i], ls[++i], ls[++i], etc... + #define S1 ls[++i] + #define S4 S1, S1, S1, S1 + #define S16 S4, S4, S4, S4 + #define S64 S16, S16, S16, S16 + + . = "[ls[++i]]" // Make sure the initial element is converted to text. + + if (l-1 & 0x01) // 'i' will always be 1 here. + . += S1 // Append 1 element if the remaining elements are not a multiple of 2. + if (l-i & 0x02) + . = text("[][][]", ., S1, S1) // Append 2 elements if the remaining elements are not a multiple of 4. + if (l-i & 0x04) + . = text("[][][][][]", ., S4) // And so on... + if (l-i & 0x08) + . = text("[][][][][][][][][]", ., S4, S4) + if (l-i & 0x10) + . = text("[][][][][][][][][][][][][][][][][]", ., S16) + if (l-i & 0x20) + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16, S16) + if (l-i & 0x40) + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64) + while (l > i) // Chomp through the rest of the list, 128 elements at a time. + . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ + [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64, S64) + + #undef S64 + #undef S16 + #undef S4 + #undef S1 + +// Converts a string into a list by splitting the string at each delimiter found. (discarding the seperator) +/proc/text2list(text, delimiter="\n") + var/delim_len = length(delimiter) + if (delim_len < 1) + return list(text) + + . = list() + var/last_found = 1 + var/found + + do + found = findtext(text, delimiter, last_found, 0) + . += copytext(text, last_found, found) + last_found = found + delim_len + while (found) diff --git a/code/_helpers/type2type_vr.dm b/code/_helpers/type2type_vr.dm deleted file mode 100644 index e6df531806..0000000000 --- a/code/_helpers/type2type_vr.dm +++ /dev/null @@ -1,107 +0,0 @@ -/* -// Contains VOREStation type2type functions -// list2text - takes delimiter and returns text -// text2list - takes delimiter, and creates list -// -*/ - -// Concatenates a list of strings into a single string. A seperator may optionally be provided. -/proc/list2text(list/ls, sep) - if (ls.len <= 1) // Early-out code for empty or singleton lists. - return ls.len ? ls[1] : "" - - var/l = ls.len // Made local for sanic speed. - var/i = 0 // Incremented every time a list index is accessed. - - if (sep <> null) - // Macros expand to long argument lists like so: sep, ls[++i], sep, ls[++i], sep, ls[++i], etc... - #define S1 sep, ls[++i] - #define S4 S1, S1, S1, S1 - #define S16 S4, S4, S4, S4 - #define S64 S16, S16, S16, S16 - - . = "[ls[++i]]" // Make sure the initial element is converted to text. - - // Having the small concatenations come before the large ones boosted speed by an average of at least 5%. - if (l-1 & 0x01) // 'i' will always be 1 here. - . = text("[][][]", ., S1) // Append 1 element if the remaining elements are not a multiple of 2. - if (l-i & 0x02) - . = text("[][][][][]", ., S1, S1) // Append 2 elements if the remaining elements are not a multiple of 4. - if (l-i & 0x04) - . = text("[][][][][][][][][]", ., S4) // And so on.... - if (l-i & 0x08) - . = text("[][][][][][][][][][][][][][][][][]", ., S4, S4) - if (l-i & 0x10) - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16) - if (l-i & 0x20) - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16, S16) - if (l-i & 0x40) - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64) - while (l > i) // Chomp through the rest of the list, 128 elements at a time. - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64, S64) - - #undef S64 - #undef S16 - #undef S4 - #undef S1 - else - // Macros expand to long argument lists like so: ls[++i], ls[++i], ls[++i], etc... - #define S1 ls[++i] - #define S4 S1, S1, S1, S1 - #define S16 S4, S4, S4, S4 - #define S64 S16, S16, S16, S16 - - . = "[ls[++i]]" // Make sure the initial element is converted to text. - - if (l-1 & 0x01) // 'i' will always be 1 here. - . += S1 // Append 1 element if the remaining elements are not a multiple of 2. - if (l-i & 0x02) - . = text("[][][]", ., S1, S1) // Append 2 elements if the remaining elements are not a multiple of 4. - if (l-i & 0x04) - . = text("[][][][][]", ., S4) // And so on... - if (l-i & 0x08) - . = text("[][][][][][][][][]", ., S4, S4) - if (l-i & 0x10) - . = text("[][][][][][][][][][][][][][][][][]", ., S16) - if (l-i & 0x20) - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S16, S16) - if (l-i & 0x40) - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64) - while (l > i) // Chomp through the rest of the list, 128 elements at a time. - . = text("[][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]\ - [][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][][]", ., S64, S64) - - #undef S64 - #undef S16 - #undef S4 - #undef S1 - -// Converts a string into a list by splitting the string at each delimiter found. (discarding the seperator) -/proc/text2list(text, delimiter="\n") - var/delim_len = length(delimiter) - if (delim_len < 1) - return list(text) - - . = list() - var/last_found = 1 - var/found - - do - found = findtext(text, delimiter, last_found, 0) - . += copytext(text, last_found, found) - last_found = found + delim_len - while (found) diff --git a/code/modules/food/food/snacks.dm b/code/modules/food/food/snacks.dm index 9557434372..d65679f6f7 100644 --- a/code/modules/food/food/snacks.dm +++ b/code/modules/food/food/snacks.dm @@ -157,7 +157,7 @@ . = ..() if(Adjacent(user)) if(coating) - to_chat(user, "It's coated in [coating.name]!") + . += "It's coated in [coating.name]!" if(bitecount==0) return . else if (bitecount==1) @@ -4528,12 +4528,14 @@ filling_color = "#DB0000" center_of_mass = list("x"=16, "y"=16) do_coating_prefix = 0 - New() - . = ..() - reagents.add_reagent("protein", 6) - reagents.add_reagent("batter", 1.7) - reagents.add_reagent("oil", 1.5) - bitesize = 2 + bitesize = 2 + + +/obj/item/weapon/reagent_containers/food/snacks/sausage/battered/Initialize() + . = ..() + reagents.add_reagent("protein", 6) + reagents.add_reagent("batter", 1.7) + reagents.add_reagent("oil", 1.5) /obj/item/weapon/reagent_containers/food/snacks/jalapeno_poppers name = "jalapeno popper" @@ -4558,10 +4560,11 @@ icon = 'icons/obj/food_syn.dmi' icon_state = "ratburger" center_of_mass = list("x"=16, "y"=11) - New() - . = ..() - reagents.add_reagent("protein", 4) - bitesize = 2 + bitesize = 2 + +/obj/item/weapon/reagent_containers/food/snacks/mouseburger/Initialize() + . = ..() + reagents.add_reagent("protein", 4) /obj/item/weapon/reagent_containers/food/snacks/chickenkatsu name = "chicken katsu" @@ -4637,13 +4640,13 @@ nutriment_amt = 25 nutriment_desc = list("fried pizza" = 25) center_of_mass = list("x"=16, "y"=11) + bitesize = 2 - New() - . = ..() - reagents.add_reagent("batter", 6.5) - coating = reagents.get_reagent("batter") - reagents.add_reagent("oil", 4) - bitesize = 2 +/obj/item/weapon/reagent_containers/food/snacks/sliceable/pizza/crunch/Initialize() + . = ..() + reagents.add_reagent("batter", 6.5) + coating = reagents.get_reagent("batter") + reagents.add_reagent("oil", 4) /obj/item/weapon/reagent_containers/food/snacks/pizzacrunchslice name = "pizza crunch" @@ -6032,4 +6035,16 @@ /obj/item/weapon/reagent_containers/food/snacks/cosmicbrowniesslice/filled/Initialize() . = ..() - reagents.add_reagent("protein", 1) \ No newline at end of file + reagents.add_reagent("protein", 1) + +/obj/item/weapon/reagent_containers/food/snacks/lasagna + name = "lasagna" + desc = "Meaty, tomato-y, and ready to eat-y. Favorite of cats." + icon = 'icons/obj/food.dmi' + icon_state = "lasagna" + nutriment_amt = 5 + nutriment_desc = list("tomato" = 4, "meat" = 2) + +/obj/item/weapon/reagent_containers/food/snacks/lasagna/Initialize() + ..() + reagents.add_reagent("protein", 2) //For meaty things. diff --git a/code/modules/food/food/snacks_vr.dm b/code/modules/food/food/snacks_vr.dm index d5633dee75..f881d9e43c 100644 --- a/code/modules/food/food/snacks_vr.dm +++ b/code/modules/food/food/snacks_vr.dm @@ -42,20 +42,6 @@ /obj/item/weapon/reagent_containers/food/snacks/slice/sushi/filled/filled filled = TRUE - -/obj/item/weapon/reagent_containers/food/snacks/lasagna - name = "lasagna" - desc = "Meaty, tomato-y, and ready to eat-y. Favorite of cats." - icon = 'icons/obj/food_vr.dmi' - icon_state = "lasagna" - nutriment_amt = 5 - nutriment_desc = list("tomato" = 4, "meat" = 2) - -/obj/item/weapon/reagent_containers/food/snacks/lasagna/Initialize() - ..() - reagents.add_reagent("protein", 2) //For meaty things. - - /obj/item/weapon/reagent_containers/food/snacks/goulash name = "goulash" desc = "Paprika put to good use, finally, in a soup of meat and vegetables." diff --git a/code/modules/food/kitchen/cooking_machines/_appliance.dm b/code/modules/food/kitchen/cooking_machines/_appliance.dm index 265b0c95bc..61666aacff 100644 --- a/code/modules/food/kitchen/cooking_machines/_appliance.dm +++ b/code/modules/food/kitchen/cooking_machines/_appliance.dm @@ -53,12 +53,10 @@ if (!available_recipes) available_recipes = new - for (var/type in subtypesof(/datum/recipe)) - var/datum/recipe/test = new type - if ((appliancetype & test.appliance)) - available_recipes += test - else - qdel(test) + for(var/type in subtypesof(/datum/recipe)) + var/datum/recipe/test = type + if((appliancetype & initial(test.appliance))) + available_recipes += new test /obj/machinery/appliance/Destroy() for (var/a in cooking_objs) @@ -79,7 +77,7 @@ for (var/a in cooking_objs) var/datum/cooking_item/CI = a string += "-\a [CI.container.label(null, CI.combine_target)], [report_progress(CI)]
" - to_chat(user, string) + return string else to_chat(user, "") @@ -125,14 +123,14 @@ return if (!user.IsAdvancedToolUser()) - to_chat(user, "You lack the dexterity to do that!") + to_chat(user, "You lack the dexterity to do that!") return if (user.stat || user.restrained() || user.incapacitated()) return if (!Adjacent(user) && !issilicon(user)) - to_chat(user, "You can't reach [src] from here.") + to_chat(user, "You can't reach [src] from here!") return if (stat & POWEROFF)//Its turned off @@ -234,10 +232,10 @@ //This function is overridden by cookers that do stuff with containers /obj/machinery/appliance/proc/has_space(var/obj/item/I) - if (cooking_objs.len >= max_contents) + if(cooking_objs.len >= max_contents) return FALSE - else return TRUE + return TRUE /obj/machinery/appliance/attackby(var/obj/item/I, var/mob/user) if(!cook_type || (stat & (BROKEN))) @@ -246,12 +244,9 @@ var/result = can_insert(I, user) if(!result) - if(default_deconstruction_screwdriver(user, I)) - return - else if(default_part_replacement(user, I)) - return - else - return + if(!(default_deconstruction_screwdriver(user, I))) + default_part_replacement(user, I) + return if(result == 2) var/obj/item/weapon/grab/G = I @@ -572,17 +567,17 @@ var/datum/cooking_item/CI = menuoptions[selection] eject(CI, user) update_icon() - return 1 - return 0 + return TRUE + return FALSE /obj/machinery/appliance/proc/can_remove_items(var/mob/user) if (!Adjacent(user)) - return 0 + return FALSE if (isanimal(user)) - return 0 + return FALSE - return 1 + return TRUE /obj/machinery/appliance/proc/eject(var/datum/cooking_item/CI, var/mob/user = null) var/obj/item/thing diff --git a/code/modules/food/kitchen/cooking_machines/_cooker.dm b/code/modules/food/kitchen/cooking_machines/_cooker.dm index 1e7193f166..94b40b44b2 100644 --- a/code/modules/food/kitchen/cooking_machines/_cooker.dm +++ b/code/modules/food/kitchen/cooking_machines/_cooker.dm @@ -19,12 +19,12 @@ if(.) //no need to duplicate adjacency check if(!stat) if (temperature < min_temp) - to_chat(user, "\The [src] is still heating up and is too cold to cook anything yet.") + . += "\The [src] is still heating up and is too cold to cook anything yet." else - to_chat(user, "It is running at [round(get_efficiency(), 0.1)]% efficiency!") - to_chat(user, "Temperature: [round(temperature - T0C, 0.1)]C / [round(optimal_temp - T0C, 0.1)]C") + . += "It is running at [round(get_efficiency(), 0.1)]% efficiency!" + . += "Temperature: [round(temperature - T0C, 0.1)]C / [round(optimal_temp - T0C, 0.1)]C" else - to_chat(user, "It is switched off.") + . += "It is switched off." /obj/machinery/appliance/cooker/list_contents(var/mob/user) if (cooking_objs.len) diff --git a/code/modules/food/kitchen/cooking_machines/_mixer.dm b/code/modules/food/kitchen/cooking_machines/_mixer.dm index 18b75998d9..ce17e55d91 100644 --- a/code/modules/food/kitchen/cooking_machines/_mixer.dm +++ b/code/modules/food/kitchen/cooking_machines/_mixer.dm @@ -17,7 +17,7 @@ fundamental differences /obj/machinery/appliance/mixer/examine(var/mob/user) . = ..() if(Adjacent(user)) - to_chat(user, "It is currently set to make a [selected_option]") + . += "It is currently set to make a [selected_option]" /obj/machinery/appliance/mixer/Initialize() . = ..() @@ -27,7 +27,7 @@ fundamental differences //Mixers cannot-not do combining mode. So the default option is removed from this. A combine target must be chosen /obj/machinery/appliance/mixer/choose_output() - set src in oview(1) + set src in view(1) set name = "Choose output" set category = "Object" @@ -91,7 +91,7 @@ fundamental differences /obj/machinery/appliance/mixer/toggle_power() - set src in view() + set src in view(1) set name = "Toggle Power" set category = "Object" diff --git a/code/modules/food/recipe.dm b/code/modules/food/recipe.dm index e5b5a02eb0..12ada97872 100644 --- a/code/modules/food/recipe.dm +++ b/code/modules/food/recipe.dm @@ -71,31 +71,31 @@ // This is a bitfield, more than one type can be used // Grill is presently unused and not listed -/datum/recipe/proc/check_reagents(var/datum/reagents/avail_reagents) +/datum/recipe/proc/check_reagents(var/datum/reagents/avail_reagents, var/exact = FALSE) if(!reagents || !reagents.len) - return 1 + return TRUE if(!avail_reagents) - return 0 + return FALSE - . = 1 + . = TRUE for(var/r_r in reagents) var/aval_r_amnt = avail_reagents.get_reagent_amount(r_r) if(aval_r_amnt - reagents[r_r] >= 0) - if(aval_r_amnt>reagents[r_r]) - . = 0 + if(aval_r_amnt>(reagents[r_r] && exact)) + . = FALSE else - return -1 + return FALSE if((reagents?(reagents.len):(0)) < avail_reagents.reagent_list.len) - return 0 + return FALSE return . -/datum/recipe/proc/check_fruit(var/obj/container) +/datum/recipe/proc/check_fruit(var/obj/container, var/exact = FALSE) if (!fruit || !fruit.len) - return 1 + return TRUE - . = 1 + . = TRUE if(fruit && fruit.len) var/list/checklist = list() // You should trust Copy(). @@ -107,18 +107,18 @@ checklist[G.seed.kitchen_tag]-- for(var/ktag in checklist) if(!isnull(checklist[ktag])) - if(checklist[ktag] < 0) - . = 0 + if(checklist[ktag] < 0 && exact) + . = FALSE else if(checklist[ktag] > 0) - . = -1 + . = FALSE break return . -/datum/recipe/proc/check_items(var/obj/container as obj) +/datum/recipe/proc/check_items(var/obj/container as obj, var/exact = FALSE) if(!items || !items.len) - return 1 + return TRUE - . = 1 + . = TRUE if(items && items.len) var/list/checklist = list() checklist = items.Copy() // You should really trust Copy @@ -127,50 +127,50 @@ for(var/obj/O in ((machine.contents - machine.component_parts) - machine.circuit)) if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/grown)) continue // Fruit is handled in check_fruit(). - var/found = 0 + var/found = FALSE for(var/i = 1; i < checklist.len+1; i++) var/item_type = checklist[i] if (istype(O,item_type)) checklist.Cut(i, i+1) - found = 1 + found = TRUE break - if(!found) - . = 0 + if(!found && exact) + return FALSE else for(var/obj/O in container.contents) if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/grown)) continue // Fruit is handled in check_fruit(). - var/found = 0 + var/found = FALSE for(var/i = 1; i < checklist.len+1; i++) var/item_type = checklist[i] if (istype(O,item_type)) if(check_coating(O)) checklist.Cut(i, i+1) - found = 1 + found = TRUE break - if (!found) - . = 0 + if (!found && exact) + return FALSE if(checklist.len) - . = -1 + return FALSE return . //This is called on individual items within the container. -/datum/recipe/proc/check_coating(var/obj/O) +/datum/recipe/proc/check_coating(var/obj/O, var/exact = FALSE) if(!istype(O,/obj/item/weapon/reagent_containers/food/snacks)) - return 1//Only snacks can be battered + return TRUE //Only snacks can be battered if (coating == -1) - return 1 //-1 value doesnt care + return TRUE //-1 value doesnt care var/obj/item/weapon/reagent_containers/food/snacks/S = O if (!S.coating) if (!coating) - return 1 - return 0 + return TRUE + return FALSE else if (S.coating.type == coating) - return 1 + return TRUE - return 0 + return FALSE //general version /datum/recipe/proc/make(var/obj/container as obj) @@ -308,7 +308,7 @@ /proc/select_recipe(var/list/datum/recipe/available_recipes, var/obj/obj as obj, var/exact) var/list/datum/recipe/possible_recipes = list() for (var/datum/recipe/recipe in available_recipes) - if((recipe.check_reagents(obj.reagents) < exact) || (recipe.check_items(obj) < exact) || (recipe.check_fruit(obj) < exact)) + if(!recipe.check_reagents(obj.reagents, exact) || !recipe.check_items(obj, exact) || !recipe.check_fruit(obj, exact)) continue possible_recipes |= recipe if (!possible_recipes.len) diff --git a/code/modules/food/recipes_fryer.dm b/code/modules/food/recipes_fryer.dm index b0347d154d..a5a3fee6e7 100644 --- a/code/modules/food/recipes_fryer.dm +++ b/code/modules/food/recipes_fryer.dm @@ -6,6 +6,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/fries /datum/recipe/cheesyfries + appliance = FRYER items = list( /obj/item/weapon/reagent_containers/food/snacks/fries, /obj/item/weapon/reagent_containers/food/snacks/cheesewedge, @@ -100,13 +101,11 @@ ) result = /obj/item/weapon/reagent_containers/food/snacks/donut/poisonberry -/datum/recipe/jellydonut/slime - appliance = FRYER +/datum/recipe/jellydonut/slime // Subtypes of jellydonut, appliance inheritance applies. reagents = list("slimejelly" = 5, "sugar" = 5) result = /obj/item/weapon/reagent_containers/food/snacks/donut/slimejelly -/datum/recipe/jellydonut/cherry - appliance = FRYER +/datum/recipe/jellydonut/cherry // Subtypes of jellydonut, appliance inheritance applies. reagents = list("cherryjelly" = 5, "sugar" = 5) result = /obj/item/weapon/reagent_containers/food/snacks/donut/cherryjelly @@ -177,4 +176,4 @@ /obj/item/weapon/reagent_containers/food/snacks/meat, /obj/item/weapon/reagent_containers/food/snacks/meat ) - result = /obj/item/weapon/storage/box/wings //This is kinda like the donut box. \ No newline at end of file + result = /obj/item/weapon/storage/box/wings //This is kinda like the donut box. diff --git a/code/modules/food/recipes_microwave.dm b/code/modules/food/recipes_microwave.dm index 1245c7e021..22a61e0d37 100644 --- a/code/modules/food/recipes_microwave.dm +++ b/code/modules/food/recipes_microwave.dm @@ -208,10 +208,11 @@ I said no! /datum/recipe/amanitajelly reagents = list("water" = 5, "vodka" = 5, "amatoxin" = 5) result = /obj/item/weapon/reagent_containers/food/snacks/amanitajelly - make_food(var/obj/container as obj) - . = ..(container) - for(var/obj/item/weapon/reagent_containers/food/snacks/amanitajelly/being_cooked in .) - being_cooked.reagents.del_reagent("amatoxin") + +/datum/recipe/amanitajelly/make_food(var/obj/container as obj) + . = ..(container) + for(var/obj/item/weapon/reagent_containers/food/snacks/amanitajelly/being_cooked in .) + being_cooked.reagents.del_reagent("amatoxin") /datum/recipe/meatballsoup fruit = list("carrot" = 1, "potato" = 1) @@ -531,11 +532,11 @@ I said no! fruit = list("potato" = 1, "ambrosia" = 3) items = list(/obj/item/weapon/reagent_containers/food/snacks/meatball) result = /obj/item/weapon/reagent_containers/food/snacks/validsalad - make_food(var/obj/container as obj) - - . = ..(container) - for (var/obj/item/weapon/reagent_containers/food/snacks/validsalad/being_cooked in .) - being_cooked.reagents.del_reagent("toxin") + +/datum/recipe/validsalad/make_food(var/obj/container as obj) + . = ..(container) + for (var/obj/item/weapon/reagent_containers/food/snacks/validsalad/being_cooked in .) + being_cooked.reagents.del_reagent("toxin") /datum/recipe/stuffing reagents = list("water" = 5, "sodiumchloride" = 1, "blackpepper" = 1) @@ -1028,7 +1029,6 @@ I said no! ) result = /obj/item/weapon/reagent_containers/food/snacks/sashimi - /datum/recipe/nugget reagents = list("flour" = 5) items = list( diff --git a/code/modules/food/recipes_oven.dm b/code/modules/food/recipes_oven.dm index 3f89560372..7a477cf943 100644 --- a/code/modules/food/recipes_oven.dm +++ b/code/modules/food/recipes_oven.dm @@ -83,6 +83,7 @@ result = /obj/item/weapon/reagent_containers/food/snacks/flatbread /datum/recipe/tortilla + appliance = OVEN reagents = list("flour" = 5) items = list( /obj/item/weapon/reagent_containers/food/snacks/sliceable/flatdough diff --git a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm index 3aa1e2b5a2..43a3bf269c 100644 --- a/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm +++ b/code/modules/reagents/Chemistry-Reagents/Chemistry-Reagents-Food-Drinks.dm @@ -69,14 +69,14 @@ /datum/reagent/nutriment/coating/affect_ingest(var/mob/living/carbon/M, var/alien, var/removed) //We'll assume that the batter isnt going to be regurgitated and eaten by someone else. Only show this once - if (data["cooked"] != 1) + if(data["cooked"] != 1) if (!messaged) - to_chat(M, "Ugh, this raw [name] tastes disgusting.") + to_chat(M, "Ugh, this raw [name] tastes disgusting.") nutriment_factor *= 0.5 messaged = 1 - //Raw coatings will sometimes cause vomiting - if (prob(1)) + //Raw coatings will sometimes cause vomiting. 75% chance of this happening. + if(prob(75)) M.vomit() ..() diff --git a/code/modules/research/designs/circuits/circuits.dm b/code/modules/research/designs/circuits/circuits.dm index 28e76ceac9..e2479a8e1c 100644 --- a/code/modules/research/designs/circuits/circuits.dm +++ b/code/modules/research/designs/circuits/circuits.dm @@ -626,6 +626,7 @@ CIRCUITS BELOW build_path = /obj/item/weapon/circuitboard/microwave/advanced sort_string = "HACAA" + /datum/design/circuit/shield_generator name = "shield generator" id = "shield_generator" diff --git a/html/changelogs/rykka-stormheart-pr-7344.yml b/html/changelogs/rykka-stormheart-pr-7344.yml new file mode 100644 index 0000000000..e8394c72cb --- /dev/null +++ b/html/changelogs/rykka-stormheart-pr-7344.yml @@ -0,0 +1,43 @@ +################################ +# Example Changelog File +# +# Note: This file, and files beginning with ".", and files that don't end in ".yml" will not be read. If you change this file, you will look really dumb. +# +# Your changelog will be merged with a master changelog. (New stuff added only, and only on the date entry for the day it was merged.) +# When it is, any changes listed below will disappear. +# +# Valid Prefixes: +# bugfix +# wip (For works in progress) +# tweak +# soundadd +# sounddel +# rscadd (general adding of nice things) +# rscdel (general deleting of nice things) +# imageadd +# imagedel +# maptweak +# spellcheck (typo fixes) +# experiment +################################# + +# Your name. +author: Rykka Stormheart + +# Optional: Remove this file after generating master changelog. Useful for PR changelogs that won't get used again. +delete-after: True + +# Any changes you've made. See valid prefix list above. +# INDENT WITH TWO SPACES. NOT TABS. SPACES. +# SCREW THIS UP AND IT WON'T WORK. +# Also, all entries are changed into a single [] after a master changelog generation. Just remove the brackets when you add new entries. +# Please surround your changes in double quotes ("), as certain characters otherwise screws up compiling. The quotes will not show up in the changelog. +changes: + - rscadd: "Ported over Aurora Cooking from AuroraStation and Citadel-RP!" + - rscadd: "Refactored Recipes to be separated per-appliance, and all appliances have a use!" + - rscadd: "Please take note, Chefs, to pre-heat you appliances at the start of your shift." + - rscadd: "Fryer Recipes require batter before they can be made!" + - rscadd: "Fire alarms will go off if you burn food!" + - rscadd: "The largest change - Cooking takes TIME. Around 6 minutes for the largest recipes in the game." + - rscadd: "Too many other changes to list - refer to PR #7344 https://github.com/PolarisSS13/Polaris/pull/7344" + - rscdel: "Removed fun, and any sense of joy in the game." diff --git a/maps/submaps/surface_submaps/wilderness/Manor1.dmm b/maps/submaps/surface_submaps/wilderness/Manor1.dmm index 311e2b7bb1..4d561d5402 100644 --- a/maps/submaps/surface_submaps/wilderness/Manor1.dmm +++ b/maps/submaps/surface_submaps/wilderness/Manor1.dmm @@ -185,4 +185,4 @@ cNaaaaaaaaaaaaaaaaababcwcFcGabcwcJabcKcLabaaaaaaaaaaaaaaaaaaaaaaaaabcMalalagagag cNaaaaaacOaaaaaaaaaaabababababababababababaaaaaaaaaaaaaaaaaaaaaaaaabababababababababababababaaaaaaaaaaaaaacN cNaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaacN cNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcNcN -"} \ No newline at end of file +"} diff --git a/vorestation.dme b/vorestation.dme index d975775d8b..7772b2ebf9 100644 --- a/vorestation.dme +++ b/vorestation.dme @@ -127,7 +127,6 @@ #include "code\_helpers\time.dm" #include "code\_helpers\turfs.dm" #include "code\_helpers\type2type.dm" -#include "code\_helpers\type2type_vr.dm" #include "code\_helpers\unsorted.dm" #include "code\_helpers\unsorted_vr.dm" #include "code\_helpers\view.dm"