mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-10 02:09:41 +00:00
Move almost everything food related into the kitchen module.
This commit is contained in:
175
code/modules/food/glass/bottle.dm
Normal file
175
code/modules/food/glass/bottle.dm
Normal file
@@ -0,0 +1,175 @@
|
||||
|
||||
//Not to be confused with /obj/item/weapon/reagent_containers/food/drinks/bottle
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle
|
||||
name = "bottle"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = null
|
||||
item_state = "atoxinbottle"
|
||||
amount_per_transfer_from_this = 10
|
||||
possible_transfer_amounts = list(5,10,15,25,30,60)
|
||||
flags = 0
|
||||
volume = 60
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/on_reagent_change()
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/pickup(mob/user)
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/dropped(mob/user)
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/attack_hand()
|
||||
..()
|
||||
update_icon()
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/New()
|
||||
..()
|
||||
if(!icon_state)
|
||||
icon_state = "bottle-[rand(1,4)]"
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/update_icon()
|
||||
overlays.Cut()
|
||||
|
||||
if(reagents.total_volume && (icon_state == "bottle-1" || icon_state == "bottle-2" || icon_state == "bottle-3" || icon_state == "bottle-4"))
|
||||
var/image/filling = image('icons/obj/reagentfillings.dmi', src, "[icon_state]10")
|
||||
|
||||
var/percent = round((reagents.total_volume / volume) * 100)
|
||||
switch(percent)
|
||||
if(0 to 9) filling.icon_state = "[icon_state]--10"
|
||||
if(10 to 24) filling.icon_state = "[icon_state]-10"
|
||||
if(25 to 49) filling.icon_state = "[icon_state]-25"
|
||||
if(50 to 74) filling.icon_state = "[icon_state]-50"
|
||||
if(75 to 79) filling.icon_state = "[icon_state]-75"
|
||||
if(80 to 90) filling.icon_state = "[icon_state]-80"
|
||||
if(91 to INFINITY) filling.icon_state = "[icon_state]-100"
|
||||
|
||||
filling.color = reagents.get_color()
|
||||
overlays += filling
|
||||
|
||||
if (!is_open_container())
|
||||
var/image/lid = image(icon, src, "lid_bottle")
|
||||
overlays += lid
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/inaprovaline
|
||||
name = "inaprovaline bottle"
|
||||
desc = "A small bottle. Contains inaprovaline - used to stabilize patients."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("inaprovaline" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/toxin
|
||||
name = "toxin bottle"
|
||||
desc = "A small bottle of toxins. Do not drink, it is poisonous."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-3"
|
||||
prefill = list("toxin" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/cyanide
|
||||
name = "cyanide bottle"
|
||||
desc = "A small bottle of cyanide. Bitter almonds?"
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-3"
|
||||
prefill = list("cyanide" = 30) //volume changed to match chloral
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/stoxin
|
||||
name = "soporific bottle"
|
||||
desc = "A small bottle of soporific. Just the fumes make you sleepy."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-3"
|
||||
prefill = list("stoxin" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/chloralhydrate
|
||||
name = "chloral hydrate bottle"
|
||||
desc = "A small bottle of Choral Hydrate. Mickey's Favorite!"
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-3"
|
||||
prefill = list("chloralhydrate" = 30) //Intentionally low since it is so strong. Still enough to knock someone out.
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/antitoxin
|
||||
name = "dylovene bottle"
|
||||
desc = "A small bottle of dylovene. Counters poisons, and repairs damage. A wonder drug."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("anti_toxin" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/mutagen
|
||||
name = "unstable mutagen bottle"
|
||||
desc = "A small bottle of unstable mutagen. Randomly changes the DNA structure of whoever comes in contact."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-1"
|
||||
prefill = list("mutagen" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/ammonia
|
||||
name = "ammonia bottle"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-1"
|
||||
prefill = list("ammonia" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/eznutrient
|
||||
name = "\improper EZ NUtrient bottle"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("eznutrient" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/left4zed
|
||||
name = "\improper Left-4-Zed bottle"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("left4zed" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/robustharvest
|
||||
name = "\improper Robust Harvest"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("robustharvest" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/diethylamine
|
||||
name = "diethylamine bottle"
|
||||
desc = "A small bottle."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("diethylamine" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/pacid
|
||||
name = "polytrinic acid bottle"
|
||||
desc = "A small bottle. Contains a small amount of Polytrinic Acid"
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("pacid" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/adminordrazine
|
||||
name = "adminordrazine bottle"
|
||||
desc = "A small bottle. Contains the liquid essence of the gods."
|
||||
icon = 'icons/obj/drinks.dmi'
|
||||
icon_state = "holyflask"
|
||||
prefill = list("adminordrazine" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/capsaicin
|
||||
name = "capsaicin bottle"
|
||||
desc = "A small bottle. Contains hot sauce."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("capsaicin" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/frostoil
|
||||
name = "frost oil bottle"
|
||||
desc = "A small bottle. Contains cold sauce."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
prefill = list("frostoil" = 60)
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/biomass
|
||||
name = "biomass bottle"
|
||||
desc = "A bottle of raw biomass! Gross!"
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-3"
|
||||
prefill = list("biomass" = 60)
|
||||
25
code/modules/food/glass/bottle/robot.dm
Normal file
25
code/modules/food/glass/bottle/robot.dm
Normal file
@@ -0,0 +1,25 @@
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/robot
|
||||
amount_per_transfer_from_this = 10
|
||||
possible_transfer_amounts = list(5,10,15,25,30,50,100)
|
||||
flags = OPENCONTAINER
|
||||
volume = 60
|
||||
var/reagent = ""
|
||||
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/robot/inaprovaline
|
||||
name = "internal inaprovaline bottle"
|
||||
desc = "A small bottle. Contains inaprovaline - used to stabilize patients."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
reagent = "inaprovaline"
|
||||
prefill = list("inaprovaline" = 60)
|
||||
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/bottle/robot/antitoxin
|
||||
name = "internal anti-toxin bottle"
|
||||
desc = "A small bottle of Anti-toxins. Counters poisons, and repairs damage, a wonder drug."
|
||||
icon = 'icons/obj/chemical.dmi'
|
||||
icon_state = "bottle-4"
|
||||
reagent = "anti_toxin"
|
||||
prefill = list("anti_toxin" = 60)
|
||||
Reference in New Issue
Block a user