mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-27 10:02:12 +00:00
* Process procs now properly utilize deltatime when implementing rates, timers and probabilities (#52981) * Process procs now properly use deltatime when implementing rates, timers and probabilities * Review fixes * Geiger counters cleanup Made hardsuit geiger code more similar to geiger counter code Geiger counters are more responsive now * Moved SS*_DT defines to subsystems.dm * Rebase fix * Redefined the SS*_DT defines to use the subsystem wait vars * Implemented suggested changes by @AnturK * Commented /datum/proc/process about the deltatime stuff * Send delta_time as a process parameter instead of the defines Also DTfied acid_processing * Dtfied new acid component * Process procs now properly utilize deltatime when implementing rates, timers and probabilities Co-authored-by: Donkie <daniel.cf.hultgren@gmail.com>
640 lines
22 KiB
Plaintext
640 lines
22 KiB
Plaintext
/* First aid storage
|
|
* Contains:
|
|
* First Aid Kits
|
|
* Pill Bottles
|
|
* Dice Pack (in a pill bottle)
|
|
*/
|
|
|
|
/*
|
|
* First Aid Kits
|
|
*/
|
|
/obj/item/storage/firstaid
|
|
name = "first-aid kit"
|
|
desc = "It's an emergency medical kit for those serious boo-boos."
|
|
icon_state = "firstaid"
|
|
lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi'
|
|
righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi'
|
|
throw_speed = 3
|
|
throw_range = 7
|
|
var/empty = FALSE
|
|
var/damagetype_healed //defines damage type of the medkit. General ones stay null. Used for medibot healing bonuses
|
|
|
|
/obj/item/storage/firstaid/regular
|
|
icon_state = "firstaid"
|
|
desc = "A first aid kit with the ability to heal common types of injuries."
|
|
|
|
/obj/item/storage/firstaid/regular/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] begins giving [user.p_them()]self aids with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return BRUTELOSS
|
|
|
|
/obj/item/storage/firstaid/regular/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/stack/medical/gauze = 1,
|
|
/obj/item/stack/medical/suture = 2,
|
|
/obj/item/stack/medical/mesh = 2,
|
|
/obj/item/reagent_containers/hypospray/medipen = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/emergency
|
|
icon_state = "medbriefcase"
|
|
name = "emergency first-aid kit"
|
|
desc = "A very simple first aid kit meant to secure and stabilize serious wounds for later treatment."
|
|
|
|
/obj/item/storage/firstaid/emergency/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/healthanalyzer/wound = 1,
|
|
/obj/item/stack/medical/gauze = 1,
|
|
/obj/item/stack/medical/suture/emergency = 1,
|
|
/obj/item/stack/medical/ointment = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen/ekit = 2,
|
|
/obj/item/storage/pill_bottle/iron = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/medical
|
|
name = "medical aid kit"
|
|
icon_state = "firstaid_surgery"
|
|
inhand_icon_state = "firstaid"
|
|
desc = "A high capacity aid kit for doctors, full of medical supplies and basic surgical equipment"
|
|
|
|
/obj/item/storage/firstaid/medical/ComponentInitialize()
|
|
. = ..()
|
|
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
|
STR.max_w_class = WEIGHT_CLASS_NORMAL //holds the same equipment as a medibelt
|
|
STR.max_items = 12
|
|
STR.max_combined_w_class = 24
|
|
STR.set_holdable(list(
|
|
/obj/item/healthanalyzer,
|
|
/obj/item/dnainjector,
|
|
/obj/item/reagent_containers/dropper,
|
|
/obj/item/reagent_containers/glass/beaker,
|
|
/obj/item/reagent_containers/glass/bottle,
|
|
/obj/item/reagent_containers/pill,
|
|
/obj/item/reagent_containers/syringe,
|
|
/obj/item/reagent_containers/medigel,
|
|
/obj/item/reagent_containers/spray,
|
|
/obj/item/lighter,
|
|
/obj/item/storage/fancy/cigarettes,
|
|
/obj/item/storage/pill_bottle,
|
|
/obj/item/stack/medical,
|
|
/obj/item/flashlight/pen,
|
|
/obj/item/extinguisher/mini,
|
|
/obj/item/reagent_containers/hypospray,
|
|
/obj/item/sensor_device,
|
|
/obj/item/radio,
|
|
/obj/item/clothing/gloves/,
|
|
/obj/item/lazarus_injector,
|
|
/obj/item/bikehorn/rubberducky,
|
|
/obj/item/clothing/mask/surgical,
|
|
/obj/item/clothing/mask/breath,
|
|
/obj/item/clothing/mask/breath/medical,
|
|
/obj/item/surgical_drapes, //for true paramedics
|
|
/obj/item/scalpel,
|
|
/obj/item/circular_saw,
|
|
/obj/item/bonesetter,
|
|
/obj/item/surgicaldrill,
|
|
/obj/item/retractor,
|
|
/obj/item/cautery,
|
|
/obj/item/hemostat,
|
|
/obj/item/blood_filter,
|
|
/obj/item/shears,
|
|
/obj/item/geiger_counter,
|
|
/obj/item/clothing/neck/stethoscope,
|
|
/obj/item/stamp,
|
|
/obj/item/clothing/glasses,
|
|
/obj/item/wrench/medical,
|
|
/obj/item/clothing/mask/muzzle,
|
|
/obj/item/reagent_containers/blood,
|
|
/obj/item/tank/internals/emergency_oxygen,
|
|
/obj/item/gun/syringe/syndicate,
|
|
/obj/item/implantcase,
|
|
/obj/item/implant,
|
|
/obj/item/implanter,
|
|
/obj/item/pinpointer/crew,
|
|
/obj/item/holosign_creator/medical,
|
|
/obj/item/stack/sticky_tape //surgical tape
|
|
))
|
|
|
|
/obj/item/storage/firstaid/medical/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/healthanalyzer = 1,
|
|
/obj/item/stack/medical/gauze/twelve = 1,
|
|
/obj/item/stack/medical/suture = 2,
|
|
/obj/item/stack/medical/mesh = 2,
|
|
/obj/item/reagent_containers/hypospray/medipen = 1,
|
|
/obj/item/surgical_drapes = 1,
|
|
/obj/item/scalpel = 1,
|
|
/obj/item/hemostat = 1,
|
|
/obj/item/cautery = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/ancient
|
|
icon_state = "oldfirstaid"
|
|
desc = "A first aid kit with the ability to heal common types of injuries."
|
|
|
|
/obj/item/storage/firstaid/ancient/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/stack/medical/gauze = 1,
|
|
/obj/item/stack/medical/bruise_pack = 3,
|
|
/obj/item/stack/medical/ointment= 3)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/ancient/heirloom
|
|
desc = "A first aid kit with the ability to heal common types of injuries. You start thinking of the good old days just by looking at it."
|
|
empty = TRUE // long since been ransacked by hungry powergaming assistants breaking into med storage
|
|
|
|
/obj/item/storage/firstaid/fire
|
|
name = "burn treatment kit"
|
|
desc = "A specialized medical kit for when the toxins lab <i>-spontaneously-</i> burns down."
|
|
icon_state = "ointment"
|
|
inhand_icon_state = "firstaid-ointment"
|
|
damagetype_healed = BURN
|
|
|
|
/obj/item/storage/firstaid/fire/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] begins rubbing \the [src] against [user.p_them()]self! It looks like [user.p_theyre()] trying to start a fire!</span>")
|
|
return FIRELOSS
|
|
|
|
/obj/item/storage/firstaid/fire/Initialize(mapload)
|
|
. = ..()
|
|
icon_state = pick("ointment","firefirstaid")
|
|
|
|
/obj/item/storage/firstaid/fire/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/reagent_containers/pill/patch/aiuri = 3,
|
|
/obj/item/reagent_containers/spray/hercuri = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen/oxandrolone = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/toxin
|
|
name = "toxin treatment kit"
|
|
desc = "Used to treat toxic blood content and radiation poisoning."
|
|
icon_state = "antitoxin"
|
|
inhand_icon_state = "firstaid-toxin"
|
|
damagetype_healed = TOX
|
|
|
|
/obj/item/storage/firstaid/toxin/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] begins licking the lead paint off \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return TOXLOSS
|
|
|
|
/obj/item/storage/firstaid/toxin/Initialize(mapload)
|
|
. = ..()
|
|
icon_state = pick("antitoxin","antitoxfirstaid","antitoxfirstaid2")
|
|
|
|
/obj/item/storage/firstaid/toxin/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/storage/pill_bottle/multiver/less = 1,
|
|
/obj/item/reagent_containers/syringe/syriniver = 3,
|
|
/obj/item/storage/pill_bottle/potassiodide = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen/penacid = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/o2
|
|
name = "oxygen deprivation treatment kit"
|
|
desc = "A box full of oxygen goodies."
|
|
icon_state = "o2"
|
|
inhand_icon_state = "firstaid-o2"
|
|
damagetype_healed = OXY
|
|
|
|
/obj/item/storage/firstaid/o2/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] begins hitting [user.p_their()] neck with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return OXYLOSS
|
|
|
|
/obj/item/storage/firstaid/o2/Initialize(mapload)
|
|
. = ..()
|
|
icon_state = pick("o2","o2second")
|
|
|
|
/obj/item/storage/firstaid/o2/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/reagent_containers/syringe/convermol = 3,
|
|
/obj/item/reagent_containers/hypospray/medipen/salbutamol = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen = 1,
|
|
/obj/item/storage/pill_bottle/iron = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/brute
|
|
name = "brute trauma treatment kit"
|
|
desc = "A first aid kit for when you get toolboxed."
|
|
icon_state = "brute"
|
|
inhand_icon_state = "firstaid-brute"
|
|
damagetype_healed = BRUTE
|
|
|
|
/obj/item/storage/firstaid/brute/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] begins beating [user.p_them()]self over the head with \the [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return BRUTELOSS
|
|
|
|
/obj/item/storage/firstaid/brute/Initialize(mapload)
|
|
. = ..()
|
|
icon_state = pick("brute","brute2")
|
|
|
|
/obj/item/storage/firstaid/brute/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/reagent_containers/pill/patch/libital = 3,
|
|
/obj/item/stack/medical/gauze = 1,
|
|
/obj/item/storage/pill_bottle/probital = 1,
|
|
/obj/item/reagent_containers/hypospray/medipen/salacid = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/advanced
|
|
name = "advanced first aid kit"
|
|
desc = "An advanced kit to help deal with advanced wounds."
|
|
icon_state = "radfirstaid"
|
|
inhand_icon_state = "firstaid-rad"
|
|
custom_premium_price = 1100
|
|
damagetype_healed = "all"
|
|
|
|
/obj/item/storage/firstaid/advanced/PopulateContents()
|
|
if(empty)
|
|
return
|
|
var/static/items_inside = list(
|
|
/obj/item/reagent_containers/pill/patch/synthflesh = 3,
|
|
/obj/item/reagent_containers/hypospray/medipen/atropine = 2,
|
|
/obj/item/stack/medical/gauze = 1,
|
|
/obj/item/storage/pill_bottle/penacid = 1)
|
|
generate_items_inside(items_inside,src)
|
|
|
|
/obj/item/storage/firstaid/tactical
|
|
name = "combat medical kit"
|
|
desc = "I hope you've got insurance."
|
|
icon_state = "bezerk"
|
|
damagetype_healed = "all"
|
|
|
|
/obj/item/storage/firstaid/tactical/ComponentInitialize()
|
|
. = ..()
|
|
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
|
STR.max_w_class = WEIGHT_CLASS_NORMAL
|
|
|
|
/obj/item/storage/firstaid/tactical/PopulateContents()
|
|
if(empty)
|
|
return
|
|
new /obj/item/stack/medical/gauze(src)
|
|
new /obj/item/defibrillator/compact/combat/loaded(src)
|
|
new /obj/item/reagent_containers/hypospray/combat(src)
|
|
new /obj/item/reagent_containers/pill/patch/libital(src)
|
|
new /obj/item/reagent_containers/pill/patch/libital(src)
|
|
new /obj/item/reagent_containers/pill/patch/aiuri(src)
|
|
new /obj/item/reagent_containers/pill/patch/aiuri(src)
|
|
new /obj/item/clothing/glasses/hud/health/night(src)
|
|
|
|
//medibot assembly
|
|
/obj/item/storage/firstaid/attackby(obj/item/bodypart/S, mob/user, params)
|
|
if((!istype(S, /obj/item/bodypart/l_arm/robot)) && (!istype(S, /obj/item/bodypart/r_arm/robot)))
|
|
return ..()
|
|
|
|
//Making a medibot!
|
|
if(contents.len >= 1)
|
|
to_chat(user, "<span class='warning'>You need to empty [src] out first!</span>")
|
|
return
|
|
|
|
var/obj/item/bot_assembly/medbot/A = new
|
|
if (istype(src, /obj/item/storage/firstaid/fire))
|
|
A.set_skin("ointment")
|
|
else if (istype(src, /obj/item/storage/firstaid/toxin))
|
|
A.set_skin("tox")
|
|
else if (istype(src, /obj/item/storage/firstaid/o2))
|
|
A.set_skin("o2")
|
|
else if (istype(src, /obj/item/storage/firstaid/brute))
|
|
A.set_skin("brute")
|
|
else if (istype(src, /obj/item/storage/firstaid/advanced))
|
|
A.set_skin("advanced")
|
|
user.put_in_hands(A)
|
|
to_chat(user, "<span class='notice'>You add [S] to [src].</span>")
|
|
A.robot_arm = S.type
|
|
A.firstaid = type
|
|
qdel(S)
|
|
qdel(src)
|
|
|
|
/*
|
|
* Pill Bottles
|
|
*/
|
|
|
|
/obj/item/storage/pill_bottle
|
|
name = "pill bottle"
|
|
desc = "It's an airtight container for storing medication."
|
|
icon_state = "pill_canister"
|
|
icon = 'icons/obj/chemical.dmi'
|
|
inhand_icon_state = "contsolid"
|
|
lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi'
|
|
righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi'
|
|
w_class = WEIGHT_CLASS_SMALL
|
|
|
|
/obj/item/storage/pill_bottle/ComponentInitialize()
|
|
. = ..()
|
|
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
|
STR.allow_quick_gather = TRUE
|
|
STR.click_gather = TRUE
|
|
STR.set_holdable(list(/obj/item/reagent_containers/pill, /obj/item/dice))
|
|
|
|
/obj/item/storage/pill_bottle/suicide_act(mob/user)
|
|
user.visible_message("<span class='suicide'>[user] is trying to get the cap off [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
return (TOXLOSS)
|
|
|
|
/obj/item/storage/pill_bottle/multiver
|
|
name = "bottle of multiver pills"
|
|
desc = "Contains pills used to counter toxins."
|
|
|
|
/obj/item/storage/pill_bottle/multiver/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/multiver(src)
|
|
|
|
/obj/item/storage/pill_bottle/multiver/less
|
|
|
|
/obj/item/storage/pill_bottle/multiver/less/PopulateContents()
|
|
for(var/i in 1 to 3)
|
|
new /obj/item/reagent_containers/pill/multiver(src)
|
|
|
|
/obj/item/storage/pill_bottle/epinephrine
|
|
name = "bottle of epinephrine pills"
|
|
desc = "Contains pills used to stabilize patients."
|
|
|
|
/obj/item/storage/pill_bottle/epinephrine/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/epinephrine(src)
|
|
|
|
/obj/item/storage/pill_bottle/mutadone
|
|
name = "bottle of mutadone pills"
|
|
desc = "Contains pills used to treat genetic abnormalities."
|
|
|
|
/obj/item/storage/pill_bottle/mutadone/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/mutadone(src)
|
|
|
|
/obj/item/storage/pill_bottle/potassiodide
|
|
name = "bottle of potassium iodide pills"
|
|
desc = "Contains pills used to reduce radiation damage."
|
|
|
|
/obj/item/storage/pill_bottle/potassiodide/PopulateContents()
|
|
for(var/i in 1 to 3)
|
|
new /obj/item/reagent_containers/pill/potassiodide(src)
|
|
|
|
/obj/item/storage/pill_bottle/probital
|
|
name = "bottle of probital pills"
|
|
desc = "Contains pills used to treat brute damage.The tag in the bottle states 'Eat before ingesting, may cause fatigue'."
|
|
|
|
/obj/item/storage/pill_bottle/probital/PopulateContents()
|
|
for(var/i in 1 to 4)
|
|
new /obj/item/reagent_containers/pill/probital(src)
|
|
|
|
/obj/item/storage/pill_bottle/iron
|
|
name = "bottle of iron pills"
|
|
desc = "Contains pills used to reduce blood loss slowly.The tag in the bottle states 'Only take one each five minutes'."
|
|
|
|
/obj/item/storage/pill_bottle/iron/PopulateContents()
|
|
for(var/i in 1 to 4)
|
|
new /obj/item/reagent_containers/pill/iron(src)
|
|
|
|
/obj/item/storage/pill_bottle/mannitol
|
|
name = "bottle of mannitol pills"
|
|
desc = "Contains pills used to treat brain damage."
|
|
|
|
/obj/item/storage/pill_bottle/mannitol/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/mannitol(src)
|
|
|
|
//Contains 4 pills instead of 7, and 5u pills instead of 50u (50u pills heal 250 brain damage, 5u pills heal 25)
|
|
/obj/item/storage/pill_bottle/mannitol/braintumor
|
|
desc = "Contains diluted pills used to treat brain tumor symptoms. Take one when feeling lightheaded."
|
|
|
|
/obj/item/storage/pill_bottle/mannitol/braintumor/PopulateContents()
|
|
for(var/i in 1 to 4)
|
|
new /obj/item/reagent_containers/pill/mannitol/braintumor(src)
|
|
|
|
/obj/item/storage/pill_bottle/stimulant
|
|
name = "bottle of stimulant pills"
|
|
desc = "Guaranteed to give you that extra burst of energy during a long shift!"
|
|
|
|
/obj/item/storage/pill_bottle/stimulant/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/stimulant(src)
|
|
|
|
/obj/item/storage/pill_bottle/mining
|
|
name = "bottle of patches"
|
|
desc = "Contains patches used to treat brute and burn damage."
|
|
|
|
/obj/item/storage/pill_bottle/mining/PopulateContents()
|
|
new /obj/item/reagent_containers/pill/patch/aiuri(src)
|
|
for(var/i in 1 to 3)
|
|
new /obj/item/reagent_containers/pill/patch/libital(src)
|
|
|
|
/obj/item/storage/pill_bottle/zoom
|
|
name = "suspicious pill bottle"
|
|
desc = "The label is pretty old and almost unreadable, you recognize some chemical compounds."
|
|
|
|
/obj/item/storage/pill_bottle/zoom/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/zoom(src)
|
|
|
|
/obj/item/storage/pill_bottle/happy
|
|
name = "suspicious pill bottle"
|
|
desc = "There is a smiley on the top."
|
|
|
|
/obj/item/storage/pill_bottle/happy/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/happy(src)
|
|
|
|
/obj/item/storage/pill_bottle/lsd
|
|
name = "suspicious pill bottle"
|
|
desc = "There is a crude drawing which could be either a mushroom, or a deformed moon."
|
|
|
|
/obj/item/storage/pill_bottle/lsd/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/lsd(src)
|
|
|
|
/obj/item/storage/pill_bottle/aranesp
|
|
name = "suspicious pill bottle"
|
|
desc = "The label has 'fuck disablers' hastily scrawled in black marker."
|
|
|
|
/obj/item/storage/pill_bottle/aranesp/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/aranesp(src)
|
|
|
|
/obj/item/storage/pill_bottle/psicodine
|
|
name = "bottle of psicodine pills"
|
|
desc = "Contains pills used to treat mental distress and traumas."
|
|
|
|
/obj/item/storage/pill_bottle/psicodine/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/psicodine(src)
|
|
|
|
/obj/item/storage/pill_bottle/penacid
|
|
name = "bottle of pentetic acid pills"
|
|
desc = "Contains pills to expunge radiation and toxins."
|
|
|
|
/obj/item/storage/pill_bottle/penacid/PopulateContents()
|
|
for(var/i in 1 to 3)
|
|
new /obj/item/reagent_containers/pill/penacid(src)
|
|
|
|
|
|
/obj/item/storage/pill_bottle/neurine
|
|
name = "bottle of neurine pills"
|
|
desc = "Contains pills to treat non-severe mental traumas."
|
|
|
|
/obj/item/storage/pill_bottle/neurine/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/neurine(src)
|
|
|
|
/obj/item/storage/pill_bottle/floorpill
|
|
name = "bottle of floorpills"
|
|
desc = "An old pill bottle. It smells musty."
|
|
|
|
/obj/item/storage/pill_bottle/floorpill/Initialize()
|
|
. = ..()
|
|
var/obj/item/reagent_containers/pill/P = locate() in src
|
|
name = "bottle of [P.name]s"
|
|
|
|
/obj/item/storage/pill_bottle/floorpill/PopulateContents()
|
|
for(var/i in 1 to rand(1,7))
|
|
new /obj/item/reagent_containers/pill/floorpill(src)
|
|
|
|
/obj/item/storage/pill_bottle/floorpill/full/PopulateContents()
|
|
for(var/i in 1 to 7)
|
|
new /obj/item/reagent_containers/pill/floorpill(src)
|
|
|
|
///////////////////////////////////////// Psychologist inventory pillbottles
|
|
/obj/item/storage/pill_bottle/happinesspsych
|
|
name = "happiness pills"
|
|
desc = "Contains pills used as a last resort means to temporarily stabilize depression and anxiety. WARNING: side effects may include slurred speech, drooling, and severe addiction."
|
|
|
|
/obj/item/storage/pill_bottle/happinesspsych/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/happinesspsych(src)
|
|
|
|
/obj/item/storage/pill_bottle/lsdpsych
|
|
name = "mindbreaker toxin pills"
|
|
desc = "!FOR THERAPEUTIC USE ONLY! Contains pills used to alleviate the symptoms of Reality Dissociation Syndrome."
|
|
|
|
/obj/item/storage/pill_bottle/lsdpsych/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/lsdpsych(src)
|
|
|
|
/obj/item/storage/pill_bottle/paxpsych
|
|
name = "pax pills"
|
|
desc = "Contains pills used to temporarily pacify patients that are deemed a harm to themselves or others."
|
|
|
|
/obj/item/storage/pill_bottle/paxpsych/PopulateContents()
|
|
for(var/i in 1 to 5)
|
|
new /obj/item/reagent_containers/pill/paxpsych(src)
|
|
|
|
/obj/item/storage/organbox
|
|
name = "organ transport box"
|
|
desc = "An advanced box with an cooling mechanism that uses cryostylane or other cold reagents to keep the organs or bodyparts inside preserved."
|
|
icon_state = "organbox"
|
|
lefthand_file = 'icons/mob/inhands/equipment/medical_lefthand.dmi'
|
|
righthand_file = 'icons/mob/inhands/equipment/medical_righthand.dmi'
|
|
throw_speed = 3
|
|
throw_range = 7
|
|
custom_premium_price = 1100
|
|
/// var to prevent it freezing the same things over and over
|
|
var/cooling = FALSE
|
|
|
|
/obj/item/storage/organbox/ComponentInitialize()
|
|
. = ..()
|
|
var/datum/component/storage/STR = GetComponent(/datum/component/storage)
|
|
STR.max_w_class = WEIGHT_CLASS_BULKY /// you have to remove it from your bag before opening it but I think that's fine
|
|
STR.max_combined_w_class = 21
|
|
STR.set_holdable(list(
|
|
/obj/item/organ,
|
|
/obj/item/bodypart,
|
|
/obj/item/reagent_containers/food/snacks/icecream
|
|
))
|
|
|
|
/obj/item/storage/organbox/Initialize()
|
|
. = ..()
|
|
create_reagents(100, TRANSPARENT)
|
|
RegisterSignal(src, COMSIG_ATOM_ENTERED, .proc/freeze)
|
|
RegisterSignal(src, COMSIG_TRY_STORAGE_TAKE, .proc/unfreeze)
|
|
START_PROCESSING(SSobj, src)
|
|
|
|
/obj/item/storage/organbox/process(delta_time)
|
|
///if there is enough coolant var
|
|
var/cool = FALSE
|
|
var/amount = min(reagents.get_reagent_amount(/datum/reagent/cryostylane), 0.05 * delta_time)
|
|
if(amount > 0)
|
|
reagents.remove_reagent(/datum/reagent/cryostylane, amount)
|
|
cool = TRUE
|
|
else
|
|
amount = min(reagents.get_reagent_amount(/datum/reagent/consumable/ice), 0.1 * delta_time)
|
|
if(amount > 0)
|
|
reagents.remove_reagent(/datum/reagent/consumable/ice, amount)
|
|
cool = TRUE
|
|
if(!cooling && cool)
|
|
cooling = TRUE
|
|
update_icon()
|
|
for(var/C in contents)
|
|
freeze(C)
|
|
return
|
|
if(cooling && !cool)
|
|
cooling = FALSE
|
|
update_icon()
|
|
for(var/C in contents)
|
|
unfreeze(C)
|
|
|
|
/obj/item/storage/organbox/update_icon()
|
|
. = ..()
|
|
if(cooling)
|
|
icon_state = "organbox-working"
|
|
else
|
|
icon_state = "organbox"
|
|
|
|
///freezes the organ and loops bodyparts like heads
|
|
/obj/item/storage/organbox/proc/freeze(datum/source, obj/item/I)
|
|
if(isorgan(I))
|
|
var/obj/item/organ/organ = I
|
|
organ.organ_flags |= ORGAN_FROZEN
|
|
return
|
|
if(istype(I, /obj/item/bodypart))
|
|
var/obj/item/bodypart/B = I
|
|
for(var/O in B.contents)
|
|
if(isorgan(O))
|
|
var/obj/item/organ/organ = O
|
|
organ.organ_flags |= ORGAN_FROZEN
|
|
|
|
///unfreezes the organ and loops bodyparts like heads
|
|
/obj/item/storage/organbox/proc/unfreeze(datum/source, obj/item/I)
|
|
if(isorgan(I))
|
|
var/obj/item/organ/organ = I
|
|
organ.organ_flags &= ~ORGAN_FROZEN
|
|
return
|
|
if(istype(I, /obj/item/bodypart))
|
|
var/obj/item/bodypart/B = I
|
|
for(var/O in B.contents)
|
|
if(isorgan(O))
|
|
var/obj/item/organ/organ = O
|
|
organ.organ_flags &= ~ORGAN_FROZEN
|
|
|
|
/obj/item/storage/organbox/attackby(obj/item/I, mob/user, params)
|
|
if(istype(I, /obj/item/reagent_containers) && I.is_open_container())
|
|
var/obj/item/reagent_containers/RC = I
|
|
var/units = RC.reagents.trans_to(src, RC.amount_per_transfer_from_this, transfered_by = user)
|
|
if(units)
|
|
to_chat(user, "<span class='notice'>You transfer [units] units of the solution to [src].</span>")
|
|
return
|
|
if(istype(I, /obj/item/plunger))
|
|
to_chat(user, "<span class='notice'>You start furiously plunging [name].</span>")
|
|
if(do_after(user, 10, target = src))
|
|
to_chat(user, "<span class='notice'>You finish plunging the [name].</span>")
|
|
reagents.clear_reagents()
|
|
return
|
|
return ..()
|
|
|
|
/obj/item/storage/organbox/suicide_act(mob/living/carbon/user)
|
|
user.visible_message("<span class='suicide'>[user] is putting [user.p_theyre()] head inside the [src], it looks like [user.p_theyre()] trying to commit suicide!</span>")
|
|
user.adjust_bodytemperature(-300)
|
|
user.apply_status_effect(/datum/status_effect/freon)
|
|
return (OXYLOSS)
|