sleepers no longer check for crisis (#23623)

This commit is contained in:
HMBGERDO
2024-01-06 22:49:00 +01:00
committed by GitHub
parent 962817a224
commit 83ec42e81a
+1 -13
View File
@@ -15,7 +15,6 @@
dir = WEST
var/mob/living/carbon/human/occupant = null
var/possible_chems = list("ephedrine", "salglu_solution", "salbutamol", "charcoal")
var/emergency_chems = list("ephedrine") // Desnowflaking
var/amounts = list(5, 10)
/// Beaker loaded into the sleeper. Used for dialysis.
var/obj/item/reagent_containers/glass/beaker = null
@@ -23,7 +22,6 @@
var/filtering = FALSE
var/max_chem
var/initial_bin_rating = 1
var/min_health = -25
var/controls_inside = FALSE
var/auto_eject_dead = FALSE
idle_power_consumption = 1250
@@ -86,7 +84,6 @@
E += B.rating
max_chem = E * 20
min_health = -E * 25
/obj/machinery/sleeper/Destroy()
for(var/mob/M in contents)
@@ -171,7 +168,6 @@
data["amounts"] = amounts
data["hasOccupant"] = occupant ? 1 : 0
var/occupantData[0]
var/crisis = 0
if(occupant)
occupantData["name"] = occupant.name
occupantData["stat"] = occupant.stat
@@ -215,7 +211,6 @@
occupantData["btFaren"] = ((occupant.bodytemperature - T0C) * (9.0/5.0))+ 32
crisis = (occupant.health < min_health)
// I'm not sure WHY you'd want to put a simple_animal in a sleeper, but precedent is precedent
// Runtime is aptly named, isn't she?
if(ishuman(occupant) && !(NO_BLOOD in occupant.dna.species.species_traits))
@@ -227,7 +222,6 @@
data["occupant"] = occupantData
data["maxchem"] = max_chem
data["minhealth"] = min_health
data["dialysis"] = filtering
data["auto_eject_dead"] = auto_eject_dead
if(beaker)
@@ -250,8 +244,6 @@
var/injectable = occupant ? 1 : 0
var/overdosing = 0
var/caution = 0 // To make things clear that you're coming close to an overdose
if(crisis && !(temp.id in emergency_chems))
injectable = 0
if(occupant && occupant.reagents)
reagent_amount = occupant.reagents.get_reagent_amount(temp.id)
@@ -290,10 +282,7 @@
var/amount = text2num(params["amount"])
if(!length(chemical) || amount <= 0)
return
if(occupant.health > min_health || (chemical in emergency_chems))
inject_chemical(usr, chemical, amount)
else
to_chat(usr, "<span class='danger'>This person is not in good enough condition for sleepers to be effective! Use another means of treatment, such as cryogenics!</span>")
inject_chemical(usr, chemical, amount)
if("removebeaker")
remove_beaker(ui.user)
if("togglefilter")
@@ -553,7 +542,6 @@
icon_state = "sleeper_s-open"
base_icon = "sleeper_s"
possible_chems = list("epinephrine", "ether", "salbutamol", "styptic_powder", "silver_sulfadiazine")
emergency_chems = list("epinephrine")
controls_inside = TRUE
light_color = LIGHT_COLOR_DARKRED