Files
Ghom 0b0c5ea91e Unit test material checks are now performed on all crafting recipes by default. All stack recipes now transfer mats to the results (#92620)
## About The Pull Request
Extends the part of the crafting unit test that ensures consistency
between the total mats of the components of a recipe (or rather, the
result of said recipe) and a generic instance of the same type as its
result, previously only implemented on food recipes.

## Why It's Good For The Game
This ensures a degree of consistency with the material composition of
various objects in the game. I couldn't do it in the original PR as that
one was too big already and it took months to get it merged, and have
the relative bugs fixed.

Currently a WIP as I slowly deal with the unit test reports.

## Changelog

🆑
refactor: Follow-up to the crafting/material refactor from months ago.
All objects crafted with stacks now inherit their mat composition (not
necessarily the effects and color) by default, while previously only a
few things like chair, sinks and toilets did. Report any object looking
or behaving weirdly as a result.
fix: The material composition of ammo boxes is no longer a 1/10 of what
it's supposed to be. It was a shitty hack to make it harder to recycle
empty ammo boxes. Instead, they lose materials as they're emptied now.
/🆑
2025-12-02 18:29:01 -05:00

161 lines
4.1 KiB
Plaintext

/datum/crafting_recipe/improv_explosive
name = "Improvised Explosive"
result = /obj/item/grenade/iedcasing/spawned
tool_behaviors = list(TOOL_WELDER, TOOL_SCREWDRIVER)
reqs = list(
/datum/reagent/fuel = 20,
/obj/item/stack/cable_coil = 15,
/obj/item/assembly/timer = 1,
/obj/item/pipe = 1,
)
time = 6 SECONDS
category = CAT_CHEMISTRY
/datum/crafting_recipe/molotov
name = "Molotov"
result = /obj/item/reagent_containers/cup/glass/bottle/molotov
reqs = list(
/obj/item/rag = 1,
/obj/item/reagent_containers/cup/glass/bottle = 1,
)
time = 4 SECONDS
category = CAT_CHEMISTRY
/datum/crafting_recipe/chemical_payload
name = "Chemical Payload (C4)"
result = /obj/item/bombcore/chemical
reqs = list(
/obj/item/stock_parts/matter_bin = 1,
/obj/item/grenade/c4 = 1,
/obj/item/grenade/chem_grenade = 2
)
time = 3 SECONDS
category = CAT_CHEMISTRY
/datum/crafting_recipe/chemical_payload2
name = "Chemical Payload (Gibtonite)"
result = /obj/item/bombcore/chemical
reqs = list(
/obj/item/stock_parts/matter_bin = 1,
/obj/item/gibtonite = 1,
/obj/item/grenade/chem_grenade = 2,
)
time = 5 SECONDS
category = CAT_CHEMISTRY
crafting_flags = parent_type::crafting_flags | CRAFT_SKIP_MATERIALS_PARITY //there are two ways to make a chem bombcore. We go with the first one for mats check
/datum/crafting_recipe/alcohol_burner
name = "Burner (Ethanol)"
result = /obj/item/burner
time = 5 SECONDS
reqs = list(
/obj/item/reagent_containers/cup = 1,
/datum/reagent/consumable/ethanol = 15,
/obj/item/paper = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/oil_burner
name = "Burner (Oil)"
result = /obj/item/burner/oil
time = 5 SECONDS
reqs = list(
/obj/item/reagent_containers/cup = 1,
/datum/reagent/fuel/oil = 15,
/obj/item/paper = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/fuel_burner
name = "Burner (Fuel)"
result = /obj/item/burner/fuel
time = 5 SECONDS
reqs = list(
/obj/item/reagent_containers/cup = 1,
/datum/reagent/fuel = 15,
/obj/item/paper = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/thermometer
name = "Thermometer"
tool_behaviors = list(TOOL_WELDER)
result = /obj/item/thermometer
time = 5 SECONDS
reqs = list(
/datum/reagent/mercury = 5,
/obj/item/stack/sheet/glass = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/thermometer_alt
name = "Thermometer"
result = /obj/item/thermometer/pen
time = 5 SECONDS
reqs = list(
/datum/reagent/mercury = 5,
/obj/item/pen = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/ph_booklet
name = "pH booklet"
result = /obj/item/ph_booklet
time = 5 SECONDS
reqs = list(
/datum/reagent/universal_indicator = 5,
/obj/item/paper = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/dropper //Maybe make a glass pipette icon?
name = "Dropper"
result = /obj/item/reagent_containers/dropper
tool_behaviors = list(TOOL_WELDER)
time = 5 SECONDS
reqs = list(
/obj/item/stack/sheet/glass = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/chem_separator
name = "chemical separator"
result = /obj/structure/chem_separator
tool_behaviors = list(TOOL_WELDER)
time = 5 SECONDS
reqs = list(
/obj/item/stack/sheet/mineral/wood = 1,
/obj/item/stack/sheet/glass = 1,
/obj/item/burner = 1,
/obj/item/thermometer = 1,
)
category = CAT_CHEMISTRY
/datum/crafting_recipe/improvised_chem_heater
name = "Improvised chem heater"
result = /obj/machinery/space_heater/improvised_chem_heater
tool_behaviors = list(TOOL_SCREWDRIVER, TOOL_MULTITOOL, TOOL_WIRECUTTER)
time = 15 SECONDS
reqs = list(
/obj/item/stack/cable_coil = 2,
/obj/item/stack/sheet/glass = 2,
/obj/item/stack/sheet/iron = 2,
/datum/reagent/water = 50,
/obj/item/thermometer = 1,
)
machinery = list(/obj/machinery/space_heater = CRAFTING_MACHINERY_CONSUME)
category = CAT_CHEMISTRY
/datum/crafting_recipe/improvised_coolant
name = "Improvised cooling spray"
tool_behaviors = list(TOOL_SCREWDRIVER, TOOL_WIRECUTTER)
result = /obj/item/extinguisher/crafted
time = 10 SECONDS
reqs = list(
/obj/item/toy/crayon/spraycan = 1,
/datum/reagent/water = 20,
/datum/reagent/consumable/ice = 10,
)
category = CAT_CHEMISTRY