[MDB IGNORE] Refactors drinks and fixes a lot of food problems (#69081)

* Makes condiments their own subtype, fixes geese, prepares for merging

* Fixes geese checking drink type instead of edible foodtype to eat gross food.
* Renames foodtype var on drinks to drink_types to prevent above from happening again because it KEEPS HAPPENING. DRINKS AREN'T FOOD!
* Makes Condiments their own subtype of reagent_containers because they don't make any use of being a subtype of food, at all.
* Starts moving things from food to /food/drink subtype in preparation for merging /food/drink with /drink

* fully removes Food subtype

* /reagent_containers/drinks are now /reagent_containers/cup - This is so it's no longer confused with eachother.
* /food/drinks is now /reagent_containers/cup/drinks, so we can keep their special abilities.
* Fixes a LOT of errors with food, which are STILL checking the reagent_containers, despite ACTUAL food being refactored away from it a long time ago.

This doesn't compile yet, but I do want to make sure my progress is well tracked.

* remove copypaste code, changes soda cans

* Removes most copy paste code between the two drinks, moving most stuff to parent whenever needed.
* Made soda cans their own subtype since they didn't share anything with glass bottles anyways.
* Fixes more problems with food/drinks, especially with geese. Geese really were just broken this whole time and no one said a word...
* Removes a snowflake signal, now that both drink types share a common one.
* Adds everything to the .dme

Currently my goal is to get this all compiling, then remove isGlass var by making glass be all glass ones only.

* Moves all icons into a single drinks dmi

I'm not that great at icon stuff, hopefully I didn't forget/break anything.

* Turns juices into their own subtype

This allows us to let them check for type in molotov, to both get rid of a use of isGlass, and so non-glass non-cartons don't show up as 'carton'.

* fixes compile issues, adds updatepaths

* a better updatepaths

* updates the damn maps now

* properly names the updatepath

* how did that get there

* i suck at handling merge conflicts

* how am i this bad

* code improvement and soda fix

* more fixes

* Don't be a timer

Ports from old food bottles to trans the reagents, rather than add a timer to.

* Merge conflicts and fixes bottle smashing

* Bottle smashing is now consistently functional regardless of how much liquid they have in them, when before it would spill first, then smash on the second hit.

* runs updatepaths again
This commit is contained in:
John Willard
2022-08-12 15:24:14 -04:00
committed by GitHub
parent 4c178553fc
commit 4a274a6e4b
274 changed files with 3360 additions and 3472 deletions
@@ -85,7 +85,7 @@
var/obj/item/reagent_containers/powder_keg = used_item
if(!(powder_keg.reagent_flags & OPENCONTAINER))
return ..()
if(istype(powder_keg, /obj/item/reagent_containers/glass/rag))
if(istype(powder_keg, /obj/item/reagent_containers/cup/rag))
return ..()
if(!powder_keg.reagents.total_volume)
@@ -15,7 +15,7 @@
/obj/item/clothing/accessory/waistcoat = 2,
/obj/item/clothing/head/soft/black = 2,
/obj/item/clothing/shoes/sneakers/black = 2,
/obj/item/reagent_containers/glass/rag = 2,
/obj/item/reagent_containers/cup/rag = 2,
/obj/item/storage/box/beanbag = 1,
/obj/item/clothing/suit/armor/vest/alt = 1,
/obj/item/circuitboard/machine/dish_drive = 1,
@@ -42,7 +42,7 @@
/obj/item/clothing/suit/toggle/chef = 1,
/obj/item/clothing/under/rank/civilian/chef = 1,
/obj/item/clothing/head/chefhat = 1,
/obj/item/reagent_containers/glass/rag = 1)
/obj/item/reagent_containers/cup/rag = 1)
generate_items_inside(items_inside,src)
/obj/structure/closet/jcloset
@@ -13,6 +13,6 @@
/obj/structure/closet/secure_closet/bar/PopulateContents()
..()
for(var/i in 1 to 10)
new /obj/item/reagent_containers/food/drinks/bottle/beer( src )
new /obj/item/reagent_containers/cup/glass/bottle/beer( src )
new /obj/item/etherealballdeployer(src)
new /obj/item/roulette_wheel_beacon(src)
@@ -45,9 +45,9 @@
/obj/structure/closet/secure_closet/freezer/kitchen/PopulateContents()
..()
for(var/i in 1 to 3)
new /obj/item/reagent_containers/food/condiment/flour(src)
new /obj/item/reagent_containers/food/condiment/rice(src)
new /obj/item/reagent_containers/food/condiment/sugar(src)
new /obj/item/reagent_containers/condiment/flour(src)
new /obj/item/reagent_containers/condiment/rice(src)
new /obj/item/reagent_containers/condiment/sugar(src)
/obj/structure/closet/secure_closet/freezer/kitchen/maintenance
name = "maintenance refrigerator"
@@ -57,8 +57,8 @@
/obj/structure/closet/secure_closet/freezer/kitchen/maintenance/PopulateContents()
..()
for(var/i in 1 to 5)
new /obj/item/reagent_containers/food/condiment/milk(src)
new /obj/item/reagent_containers/food/condiment/soymilk(src)
new /obj/item/reagent_containers/condiment/milk(src)
new /obj/item/reagent_containers/condiment/soymilk(src)
for(var/i in 1 to 2)
new /obj/item/storage/fancy/egg_box(src)
@@ -84,7 +84,7 @@
/obj/structure/closet/secure_closet/freezer/gulag_fridge/PopulateContents()
..()
for(var/i in 1 to 3)
new /obj/item/reagent_containers/food/drinks/bottle/beer/light(src)
new /obj/item/reagent_containers/cup/glass/bottle/beer/light(src)
/obj/structure/closet/secure_closet/freezer/fridge
name = "refrigerator"
@@ -93,8 +93,8 @@
/obj/structure/closet/secure_closet/freezer/fridge/PopulateContents()
..()
for(var/i in 1 to 5)
new /obj/item/reagent_containers/food/condiment/milk(src)
new /obj/item/reagent_containers/food/condiment/soymilk(src)
new /obj/item/reagent_containers/condiment/milk(src)
new /obj/item/reagent_containers/condiment/soymilk(src)
for(var/i in 1 to 2)
new /obj/item/storage/fancy/egg_box(src)
@@ -7,14 +7,14 @@
/obj/structure/closet/secure_closet/medical1/PopulateContents()
..()
var/static/items_inside = list(
/obj/item/reagent_containers/glass/beaker = 2,
/obj/item/reagent_containers/cup/beaker = 2,
/obj/item/reagent_containers/dropper = 2,
/obj/item/storage/belt/medical = 1,
/obj/item/storage/box/syringes = 1,
/obj/item/reagent_containers/glass/bottle/toxin = 1,
/obj/item/reagent_containers/glass/bottle/morphine = 2,
/obj/item/reagent_containers/glass/bottle/epinephrine= 3,
/obj/item/reagent_containers/glass/bottle/multiver = 3,
/obj/item/reagent_containers/cup/bottle/toxin = 1,
/obj/item/reagent_containers/cup/bottle/morphine = 2,
/obj/item/reagent_containers/cup/bottle/epinephrine= 3,
/obj/item/reagent_containers/cup/bottle/multiver = 3,
/obj/item/storage/box/rxglasses = 1)
generate_items_inside(items_inside,src)
@@ -119,7 +119,7 @@
new /obj/item/storage/box/medigels(src)
new /obj/item/ph_booklet(src)
new /obj/item/reagent_containers/dropper(src)
new /obj/item/reagent_containers/glass/bottle/acidic_buffer(src) //hopefully they get the hint
new /obj/item/reagent_containers/cup/bottle/acidic_buffer(src) //hopefully they get the hint
/obj/structure/closet/secure_closet/chemical/heisenberg //contains one of each beaker, syringe etc.
name = "advanced chemical closet"
@@ -16,7 +16,7 @@
/obj/structure/closet/crate/wooden/toy/PopulateContents()
. = ..()
new /obj/item/megaphone/clown(src)
new /obj/item/reagent_containers/food/drinks/soda_cans/canned_laughter(src)
new /obj/item/reagent_containers/cup/soda_cans/canned_laughter(src)
new /obj/item/pneumatic_cannon/pie(src)
new /obj/item/food/pie/cream(src)
new /obj/item/storage/crayons(src)
@@ -141,7 +141,7 @@ GLOBAL_LIST_INIT(ore_probability, list(
if(2)
new /obj/item/clothing/glasses/godeye(loc)
if(3)
new /obj/item/reagent_containers/glass/bottle/potion/flight(loc)
new /obj/item/reagent_containers/cup/bottle/potion/flight(loc)
if(4)
new /obj/item/organ/internal/heart/cursed/wizard(loc)
if(5)
@@ -171,7 +171,7 @@ GLOBAL_LIST_INIT(ore_probability, list(
if(16)
new /obj/item/seeds/gatfruit(loc)
if(17)
new /obj/item/reagent_containers/food/drinks/drinkingglass/filled/nuka_cola(loc)
new /obj/item/reagent_containers/cup/glass/drinkingglass/filled/nuka_cola(loc)
if(18)
new /obj/item/soulstone/anybody(loc)
if(19)
+4 -4
View File
@@ -414,14 +414,14 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/sink, (-14))
if(istype(O, /obj/item/stack/medical/gauze))
var/obj/item/stack/medical/gauze/G = O
new /obj/item/reagent_containers/glass/rag(src.loc)
new /obj/item/reagent_containers/cup/rag(src.loc)
to_chat(user, span_notice("You tear off a strip of gauze and make a rag."))
G.use(1)
return
if(istype(O, /obj/item/stack/sheet/cloth))
var/obj/item/stack/sheet/cloth/cloth = O
new /obj/item/reagent_containers/glass/rag(loc)
new /obj/item/reagent_containers/cup/rag(loc)
to_chat(user, span_notice("You tear off a strip of cloth and make a rag."))
cloth.use(1)
return
@@ -634,14 +634,14 @@ MAPPING_DIRECTIONAL_HELPERS(/obj/structure/sink/kitchen, (-16))
if(istype(O, /obj/item/stack/medical/gauze))
var/obj/item/stack/medical/gauze/G = O
new /obj/item/reagent_containers/glass/rag(loc)
new /obj/item/reagent_containers/cup/rag(loc)
to_chat(user, span_notice("You tear off a strip of gauze and make a rag."))
G.use(1)
return
if(istype(O, /obj/item/stack/sheet/cloth))
var/obj/item/stack/sheet/cloth/cloth = O
new /obj/item/reagent_containers/glass/rag(loc)
new /obj/item/reagent_containers/cup/rag(loc)
to_chat(user, span_notice("You tear off a strip of cloth and make a rag."))
cloth.use(1)
return