Skip to content

Commit

Permalink
IT'S WORKING(maybe)
Browse files Browse the repository at this point in the history
  • Loading branch information
Zert0X committed Jul 4, 2024
1 parent 637ff9e commit 6f3a350
Show file tree
Hide file tree
Showing 32 changed files with 864 additions and 1,134 deletions.
7 changes: 3 additions & 4 deletions baystation12.dme
Original file line number Diff line number Diff line change
Expand Up @@ -144,7 +144,6 @@
#include "code\_global_vars\lists\objects.dm"
#include "code\_global_vars\lists\pipe_dispenser.dm"
#include "code\_global_vars\lists\rcd.dm"
#include "code\_global_vars\lists\reagents.dm"
#include "code\_global_vars\lists\russian.dm"
#include "code\_global_vars\lists\traitor_uplink.dm"
#include "code\_global_vars\lists\wheelcannon.dm"
Expand Down Expand Up @@ -178,7 +177,6 @@
#include "code\_helpers\preferences.dm"
#include "code\_helpers\pronouns.dm"
#include "code\_helpers\radio.dm"
#include "code\_helpers\reagents.dm"
#include "code\_helpers\roundend.dm"
#include "code\_helpers\russian.dm"
#include "code\_helpers\sanitize_values.dm"
Expand Down Expand Up @@ -1843,9 +1841,7 @@
#include "code\modules\cooking\step_defines.dm"
#include "code\modules\cooking\coocking_appliances\appliance_defines.dm"
#include "code\modules\cooking\coocking_appliances\candy.dm"
#include "code\modules\cooking\coocking_appliances\cereal.dm"
#include "code\modules\cooking\coocking_appliances\cooking_circuits.dm"
#include "code\modules\cooking\coocking_appliances\fryer.dm"
#include "code\modules\cooking\coocking_appliances\gibber.dm"
#include "code\modules\cooking\coocking_appliances\grill.dm"
#include "code\modules\cooking\coocking_appliances\icecream.dm"
Expand All @@ -1861,7 +1857,10 @@
#include "code\modules\cooking\recipes\_read_me.dm"
#include "code\modules\cooking\recipes\example_recipes.dm"
#include "code\modules\cooking\recipes\recipe.dm"
#include "code\modules\cooking\recipes\recipe_bread.dm"
#include "code\modules\cooking\recipes\recipe_burgers.dm"
#include "code\modules\cooking\recipes\recipe_donuts.dm"
#include "code\modules\cooking\recipes\recipe_hotdogs.dm"
#include "code\modules\cooking\recipes\recipes_to_covert.dm"
#include "code\modules\cooking\step_types\add_item.dm"
#include "code\modules\cooking\step_types\add_produce.dm"
Expand Down
2 changes: 1 addition & 1 deletion code/__defines/__cooking.dm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
//#define CWJ_DEBUG 1
#define CWJ_DEBUG 1


//Step classifications, for easy reference later.
Expand Down
3 changes: 0 additions & 3 deletions code/_global_vars/lists/reagents.dm

This file was deleted.

27 changes: 0 additions & 27 deletions code/_helpers/reagents.dm

This file was deleted.

3 changes: 1 addition & 2 deletions code/datums/trading/food.dm
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,7 @@
/obj/item/reagent_containers/food/grown = TRADER_BLACKLIST_ALL,
/obj/item/reagent_containers/food/human = TRADER_BLACKLIST_ALL,
/obj/item/reagent_containers/food/sliceable/braincake = TRADER_BLACKLIST,
/obj/item/reagent_containers/food/meat/human = TRADER_BLACKLIST,
/obj/item/reagent_containers/food/variable = TRADER_BLACKLIST_ALL
/obj/item/reagent_containers/food/meat/human = TRADER_BLACKLIST
)

/datum/trader/ship/bakery
Expand Down
4 changes: 4 additions & 0 deletions code/game/objects/items/trash.dm
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,10 @@
var/list/stack = list()
var/max_stack = 5

/obj/item/trash/waffles
name = "waffles"
icon_state = "waffles"

/obj/item/trash/dish/baking_sheet
name = "baking sheet"
icon_state = "baking_sheet"
Expand Down
2 changes: 1 addition & 1 deletion code/game/world.dm
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@ var/server_name = "OnyxBay"
//Emergency Fix
load_mods()
//end-emergency fix

initialize_cooking_recipes()
. = ..()

Master.Initialize(10, FALSE)
Expand Down
40 changes: 0 additions & 40 deletions code/modules/cooking/coocking_appliances/cereal.dm

This file was deleted.

52 changes: 0 additions & 52 deletions code/modules/cooking/coocking_appliances/fryer.dm

This file was deleted.

12 changes: 6 additions & 6 deletions code/modules/cooking/cooking.dm
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ Food quality is calculated based on the steps taken.
QDEL_NULL(product_info) //We don't need this anymore.

if(reagent_id)
var/datum/reagent/test_reagent = GLOB.chemical_reagents_list[reagent_id]
var/datum/reagent/test_reagent = reagent_id
if(test_reagent)
if(!name)
name = test_reagent.name
Expand Down Expand Up @@ -136,14 +136,14 @@ Food quality is calculated based on the steps taken.
if(CWJ_ADD_REAGENT)
if(step_list.len < 3)
reason="Bad argument Length for CWJ_ADD_REAGENT"
else if(!is_reagent_with_id_exist(step_list[2]))
else if(!ispath(step_list[2],/datum/reagent))
reason="Bad reagent type for CWJ_ADD_REAGENT at arg 2"
else
create_step_add_reagent(step_list[2], step_list[3], FALSE)
if(CWJ_ADD_REAGENT_OPTIONAL)
if(step_list.len < 3)
reason="Bad argument Length for CWJ_ADD_REAGENT_OPTIONAL"
else if(!is_reagent_with_id_exist(step_list[2]))
else if(!ispath(step_list[2],/datum/reagent))
reason="Bad reagent type for CWJ_ADD_REAGENT_OPTIONAL at arg 2"
else
create_step_add_reagent(step_list[2], step_list[3], TRUE)
Expand Down Expand Up @@ -336,9 +336,9 @@ Food quality is calculated based on the steps taken.
reason="reagent_skip / reagent_skip declared on non add-item / add-reagent recipe step."

if("exclude_reagents" in step_list)
for(var/id in step_list["exclude_reagents"])
if(!is_reagent_with_id_exist(id))
reason="exclude_reagents list has nonexistant reagent id [id]"
for(var/reagent in step_list["exclude_reagents"])
if(istype(reagent, /datum/reagent))
reason="exclude_reagents list has bad type reagent [reagent]"

if(!set_exclude_reagents(step_list["exclude_reagents"]))
reason="exclude_reagents declared on non add-item / add-reagent recipe step."
Expand Down
2 changes: 1 addition & 1 deletion code/modules/cooking/cooking_items/cooking_containers.dm
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@
src.vis_contents.Remove(our_item)

/obj/item/reagent_containers/vessel/cooking_container/plate
icon = 'icons/obj/cooking/eris_kitchen.dmi'
icon = 'icons/obj/cooking/kitchen2.dmi'
name = "serving plate"
shortname = "plate"
desc = "A shitty serving plate. You probably shouldn't be seeing this."
Expand Down
11 changes: 6 additions & 5 deletions code/modules/cooking/cooking_items/dollop.dm
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,18 @@
icon = 'icons/obj/cooking/kitchen.dmi'
icon_state = "dollop"
bitesize = 4
var/reagent_id = "frosting"
var/datum/reagent/reagent = /datum/reagent/organic/sugar/frosting
startswith = list(/datum/reagent/organic/sugar/frosting = 30)

/obj/item/reagent_containers/food/dollop/New(loc, new_reagent_id = "frosting", new_amount = 30)
/obj/item/reagent_containers/food/dollop/New(loc, new_reagent = /datum/reagent/organic/sugar/frosting, new_amount = 30)
. = ..()
if(new_reagent_id)
var/reagent_name = get_reagent_name_by_id(reagent_id)
if(new_reagent)
reagent = new_reagent
var/reagent_name = reagent.name
if(reagent_name)
name = "dollop of [reagent_name]"
desc = "A fresh serving of just [reagent_name] and nothing but [reagent_name]."
startswith = list("[new_reagent_id]" = new_amount)
startswith = list(reagent = new_amount)

/obj/item/reagent_containers/food/dollop/Initialize()
. = ..()
Expand Down
6 changes: 3 additions & 3 deletions code/modules/cooking/recipes/_read_me.dm
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ list(<CWJ_STEP_CLASS><_OPTIONAL>, <REQUIRED_ARGS>, <CUSTOM_ARGS>=value)
The product inherits the item's quality and reagents if able.
<REQUIRED_ARGS>:
type_path - the type path of the item being added.
Example: list(CWJ_ADD_ITEM, /obj/item/reagent_containers/food/breadslice)
Example: list(CWJ_ADD_ITEM, /obj/item/reagent_containers/food/slice/bread)
CWJ_ADD_REAGENT
Add a reagent to the recipe. The resulting reagent is stored in the container's reagent datum.
Expand Down Expand Up @@ -61,7 +61,7 @@ list(<CWJ_STEP_CLASS><_OPTIONAL>, <REQUIRED_ARGS>, <CUSTOM_ARGS>=value)
<_OPTIONAL>
The tag _OPTIONAL can be tacked onto any command to make it an optional step not required to finish the recipe.
Example: list(CWJ_ADD_ITEM_OPTIONAL, /obj/item/reagent_containers/food/breadslice)
Example: list(CWJ_ADD_ITEM_OPTIONAL, /obj/item/reagent_containers/food/slice/bread)
<REQUIRED_ARGS>
The required arguments for a specific class of step to function. They are not labeled and must be in order.
Expand All @@ -70,7 +70,7 @@ list(<CWJ_STEP_CLASS><_OPTIONAL>, <REQUIRED_ARGS>, <CUSTOM_ARGS>=value)
<CUSTOM_ARGS>
All custom arguments are declared in the format key=value. They are used to quickly modify a given step in a recipe.
Example: list(CWJ_ADD_ITEM, /obj/item/reagent_containers/food/breadslice, desc="a custom description")
Example: list(CWJ_ADD_ITEM, /obj/item/reagent_containers/food/slice/bread, desc="a custom description")
Valid options are:
desc
Expand Down
Loading

0 comments on commit 6f3a350

Please sign in to comment.