mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-30 08:29:57 +01:00
Bugfix batch (Pesticide Edition) (#21556)
Fixes https://github.com/Aurorastation/Aurora.3/issues/18504 Fixes https://github.com/Aurorastation/Aurora.3/issues/21064 Fixes https://github.com/Aurorastation/Aurora.3/issues/21267 Fixes https://github.com/Aurorastation/Aurora.3/issues/21455 Fixes https://github.com/Aurorastation/Aurora.3/issues/21535 Miscellaneous bugfixes, code cleanup, etc. Smaller batches this time. changes: - spellcheck: "Renames 'gibber' to 'autobutcher'." - code_imp: "Cleans up a lot of old autobutcher code." - code_imp: "Simplifies and unifies a lot of circuit board naming code." - code_imp: "Updates various code comments to DMDocs format." - balance: "Slightly increased damage of beating someone with a ladder." - bugfix: "Fixes foreign speech displaying the translated versions in langchat for non-fluent listeners." - bugfix: "Fixes whispered speech langchat; whispers are now correctly italicized." - bugfix: "Fixes shouted speech langchat; shouts are now correctly biggified." - bugfix: "Adds missing Omni Gas Mixer, Gas Meter options from RFD-P." - bugfix: "Adds missing circuit boards for bioballistic delivery system, lysis-isolation centrifuge, and autobutcher to allow for construction and deconstruction." - bugfix: "Fixes empty algae chips bag having description set for its name." - bugfix: "Adds fallback_specific_heat values to several reagents that were missing them." - bugfix: "Fixes antimateriel projectiles being erroneously damage-capped when hitting walls." - bugfix: "Fixes laser beam effects not using the base colors of their beam VFX." - qol: "Added helpful feedback hint to move closer when someone speaks aloud within 4 tiles while you're in vacuum (as features go, this one felt more like a bug to experience)." - qol: "Updated various examine hints." --------- Signed-off-by: Batrachophreno <Batrochophreno@gmail.com>
This commit is contained in:
@@ -3,19 +3,25 @@
|
||||
var/description = "A non-descript chemical."
|
||||
var/taste_description = "old rotten bandaids"
|
||||
var/list/species_taste_description
|
||||
var/taste_mult = 1 //how this taste compares to others. Higher values means it is more noticable
|
||||
/// How this taste compares to others. Higher values means it is more noticable.
|
||||
var/taste_mult = 1
|
||||
var/reagent_state = SOLID
|
||||
var/metabolism = REM // This would be 0.2 normally
|
||||
/// Default value is 0.2.
|
||||
var/metabolism = REM
|
||||
var/ingest_met = 0
|
||||
var/touch_met = 0
|
||||
var/breathe_met = 0
|
||||
var/ingest_mul = 0.5
|
||||
var/touch_mul = 0
|
||||
var/breathe_mul = 0.75
|
||||
var/overdose = 0 // Volume of a chemical required in the blood to meet overdose criteria.
|
||||
var/od_minimum_dose = 5 // Metabolised dose of a chemical required to meet overdose criteria.
|
||||
var/scannable = 0 // Shows up on health analyzers.
|
||||
var/spectro_hidden = FALSE // doesn't show up on basic mass spectrometers, only shows on the advanced variant
|
||||
/// Volume of a chemical required in the blood to meet overdose criteria.
|
||||
var/overdose = 0
|
||||
/// Metabolised dose of a chemical required to meet overdose criteria.
|
||||
var/od_minimum_dose = 5
|
||||
/// Shows up on health analyzers.
|
||||
var/scannable = 0
|
||||
/// Doesn't show up on basic mass spectrometers, only shows on the advanced variant
|
||||
var/spectro_hidden = FALSE
|
||||
var/affects_dead = 0
|
||||
var/glass_icon_state = null
|
||||
var/glass_name = null
|
||||
@@ -28,22 +34,31 @@
|
||||
var/condiment_center_of_mass = null
|
||||
var/color = "#000000"
|
||||
var/color_weight = 1
|
||||
var/unaffected_species = IS_DIONA | IS_MACHINE // Species that aren't affected by this reagent. Does not prevent affect_touch.
|
||||
var/metabolism_min = 0.01 //How much for the medicine to be present in the system to actually have an effect.
|
||||
var/conflicting_reagent //Reagents that conflict with this medicine, and cause adverse effects when in the blood.
|
||||
/// Species that aren't affected by this reagent. Does not prevent affect_touch.
|
||||
var/unaffected_species = IS_DIONA | IS_MACHINE
|
||||
/// How much for the medicine to be present in the system to actually have an effect.
|
||||
var/metabolism_min = 0.01
|
||||
/// Reagents that conflict with this medicine, and cause adverse effects when in the blood.
|
||||
var/conflicting_reagent
|
||||
|
||||
var/default_temperature = T0C + 20 //This is its default spawning temperature, if none is provided.
|
||||
var/specific_heat = -1 //The higher, the more difficult it is to change its temperature. 0 or lower values indicate that the specific heat has yet to be assigned.
|
||||
var/fallback_specific_heat = -1 //Setting this value above 0 will set the specific heat to this value only if the system could not find an appropriate specific heat to assign using the recipe system.
|
||||
//Never ever ever ever change this value for singleton/reagent. This should only be used for massive, yet specific things like drinks or food where it is infeasible to assign a specific heat value.
|
||||
/// This is its default spawning temperature, if none is provided.
|
||||
var/default_temperature = T0C + 20
|
||||
/// The higher, the more difficult it is to change its temperature. 0 or lower values indicate that the specific heat has yet to be assigned.
|
||||
var/specific_heat = -1
|
||||
/// Setting this value above 0 will set the specific heat to this value only if the system could not find an appropriate specific heat to assign using the recipe system.
|
||||
/// Never ever ever ever change this value for singleton/reagent. This should only be used for massive, yet specific things like drinks or food where it is infeasible to assign a specific heat value.
|
||||
var/fallback_specific_heat = -1
|
||||
|
||||
var/germ_adjust = 0 // for makeshift bandages/disinfectant
|
||||
var/carbonated = FALSE // if it's carbonated or not
|
||||
/// For makeshift bandages/disinfectant
|
||||
var/germ_adjust = 0
|
||||
/// If it's carbonated or not.
|
||||
var/carbonated = FALSE
|
||||
|
||||
/// Adds to the value of whatever container's holding it, value * units of reagents
|
||||
var/value = 1
|
||||
|
||||
/singleton/reagent/proc/initialize_data(var/newdata, var/datum/reagents/holder) // Called when the reagent is created.
|
||||
/// Called when the reagent is created.
|
||||
/singleton/reagent/proc/initialize_data(var/newdata, var/datum/reagents/holder)
|
||||
if(!isnull(newdata))
|
||||
return newdata
|
||||
|
||||
@@ -57,7 +72,7 @@
|
||||
else
|
||||
H.vessel.reagent_data[/singleton/reagent/blood]["trace_chem"][type] = amount
|
||||
|
||||
// This doesn't apply to skin contact - this is for, e.g. extinguishers and sprays. The difference is that reagent is not directly on the mob's skin - it might just be on their clothing.
|
||||
/// This doesn't apply to skin contact - this is for, e.g. extinguishers and sprays. The difference is that reagent is not directly on the mob's skin - it might just be on their clothing.
|
||||
/singleton/reagent/proc/touch_mob(var/mob/living/M, var/amount, var/datum/reagents/holder)
|
||||
return
|
||||
|
||||
@@ -78,7 +93,8 @@
|
||||
var/OD_min = get_od_min_dose(M, location, holder)
|
||||
return OD && (REAGENT_VOLUME(holder, type) > OD) && (LAZYACCESS(M.chem_doses, type) > OD_min) && (!location || (location != CHEM_TOUCH)) //OD based on volume in blood, but waits for a small amount of the drug to metabolise before kicking in.
|
||||
|
||||
/singleton/reagent/proc/on_mob_life(var/mob/living/carbon/M, var/alien, var/location, var/datum/reagents/holder) // Currently, on_mob_life is called on carbons. Any interaction with non-carbon mobs (lube) will need to be done in touch_mob.
|
||||
/// Currently, on_mob_life is called on carbons. Any interaction with non-carbon mobs (lube) will need to be done in touch_mob.
|
||||
/singleton/reagent/proc/on_mob_life(var/mob/living/carbon/M, var/alien, var/location, var/datum/reagents/holder)
|
||||
if(!istype(M))
|
||||
return
|
||||
if(!affects_dead && M.stat == DEAD)
|
||||
@@ -96,8 +112,9 @@
|
||||
|
||||
removed = M.get_metabolism(removed)
|
||||
|
||||
// ctual overdose threshold now = overdose + od_minimum_dose. ie. Synaptizine; 5u OD threshold + 1 unit min. metab'd dose = 6u actual OD threshold.
|
||||
if(is_overdosing(M, location, holder))
|
||||
overdose(M, alien, removed, LAZYACCESS(M.chem_doses, type)/get_overdose(M, location, holder), holder) //Actual overdose threshold now = overdose + od_minimum_dose. ie. Synaptizine; 5u OD threshold + 1 unit min. metab'd dose = 6u actual OD threshold.
|
||||
overdose(M, alien, removed, LAZYACCESS(M.chem_doses, type)/get_overdose(M, location, holder), holder)
|
||||
|
||||
if(LAZYACCESS(M.chem_doses, type) <= 0)
|
||||
initial_effect(M,alien, holder)
|
||||
@@ -127,22 +144,22 @@
|
||||
|
||||
remove_self(removed, holder)
|
||||
|
||||
// Called when a beaker is thrown or something is hit with it, AND the beaker doesn't break.
|
||||
/// Called when a beaker is thrown or something is hit with it, AND the beaker doesn't break.
|
||||
/singleton/reagent/proc/apply_force(var/force, var/datum/reagents/holder)
|
||||
return force
|
||||
|
||||
//Initial effect is called once when the reagent first starts affecting a mob.
|
||||
/// Initial effect is called once when the reagent first starts affecting a mob.
|
||||
/singleton/reagent/proc/initial_effect(var/mob/living/carbon/M, var/alien, var/datum/reagents/holder)
|
||||
return
|
||||
|
||||
//Final effect is called once when the reagent finishes affecting a mob.
|
||||
/// Final effect is called once when the reagent finishes affecting a mob.
|
||||
/singleton/reagent/proc/final_effect(var/mob/living/carbon/M, var/datum/reagents/holder)
|
||||
return
|
||||
|
||||
/singleton/reagent/proc/affect_blood(var/mob/living/carbon/M, var/alien, var/removed, var/datum/reagents/holder)
|
||||
return
|
||||
|
||||
// if your chem directly affects other chems, use this to make sure all the chem_effects are applied before the standard chem affect_thing is run
|
||||
/// If your chem directly affects other chems, use this to make sure all the chem_effects are applied before the standard chem affect_thing is run
|
||||
/singleton/reagent/proc/affect_chem_effect(var/mob/living/carbon/M, var/alien, var/removed, var/datum/reagents/holder)
|
||||
if(!istype(M))
|
||||
return FALSE
|
||||
@@ -167,13 +184,15 @@
|
||||
if(breathe_mul)
|
||||
affect_blood(M, alien, removed * breathe_mul, holder)
|
||||
|
||||
/singleton/reagent/proc/overdose(var/mob/living/carbon/M, var/alien, var/removed = 0, var/scale = 1, var/datum/reagents/holder) // Overdose effect. Doesn't happen instantly.
|
||||
/// Overdose effect. Doesn't happen instantly.
|
||||
/singleton/reagent/proc/overdose(var/mob/living/carbon/M, var/alien, var/removed = 0, var/scale = 1, var/datum/reagents/holder)
|
||||
M.adjustToxLoss(REM)
|
||||
|
||||
/singleton/reagent/proc/mix_data(var/newdata, var/newamount, var/datum/reagents/holder) // You have a reagent with data, and new reagent with its own data get added, how do you deal with that?
|
||||
/// You have a reagent with data, and new reagent with its own data get added, how do you deal with that?
|
||||
/singleton/reagent/proc/mix_data(var/newdata, var/newamount, var/datum/reagents/holder)
|
||||
return REAGENT_DATA(holder, type)
|
||||
|
||||
//Check to use when seeing if the person has the minimum dose of the reagent. Useful for stopping minimum transfer rate IV drips from applying chem effects
|
||||
/// Check to use when seeing if the person has the minimum dose of the reagent. Useful for stopping minimum transfer rate IV drips from applying chem effects
|
||||
/singleton/reagent/proc/check_min_dose(var/mob/living/carbon/M, var/min_dose = 1)
|
||||
var/dose = REAGENT_VOLUME(M.reagents, type) >= min_dose
|
||||
var/obj/item/organ/internal/stomach/S = M.internal_organs_by_name[BP_STOMACH]
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
/singleton/reagent/acetone/affect_blood(var/mob/living/carbon/M, var/alien, var/removed, var/datum/reagents/holder)
|
||||
M.adjustToxLoss(removed * 3)
|
||||
|
||||
/singleton/reagent/acetone/touch_obj(var/obj/O, var/amount, var/datum/reagents/holder) //I copied this wholesale from ethanol and could likely be converted into a shared proc. ~Techhead
|
||||
/singleton/reagent/acetone/touch_obj(var/obj/O, var/amount, var/datum/reagents/holder)
|
||||
if(istype(O, /obj/item/paper))
|
||||
var/obj/item/paper/paperaffected = O
|
||||
paperaffected.clearpaper()
|
||||
|
||||
@@ -783,6 +783,7 @@
|
||||
/singleton/reagent/drugs/dionae_stimulant/diet
|
||||
name = "diet Diesel"
|
||||
description = "Diesel produced straight from the Narrows that has been made \"diet\" or decontaminated of radiation, making it safe for distribution around the Orion Spur."
|
||||
fallback_specific_heat = 1
|
||||
|
||||
/singleton/reagent/drugs/dionae_stimulant/diet/initial_effect(mob/living/carbon/M, alien, datum/reagents/holder)
|
||||
return
|
||||
|
||||
+1
@@ -86,6 +86,7 @@
|
||||
taste_description = "sharp tangy cheese"
|
||||
reagent_state = SOLID
|
||||
taste_mult = 3
|
||||
fallback_specific_heat = 1
|
||||
|
||||
/singleton/reagent/nakarka/affect_ingest(var/mob/living/carbon/M, var/alien, var/removed, var/datum/reagents/holder)
|
||||
..()
|
||||
|
||||
+15
-7
@@ -5,12 +5,15 @@
|
||||
taste_mult = 4
|
||||
reagent_state = SOLID
|
||||
metabolism = REM * 2
|
||||
var/nutriment_factor = 8 // Per removed in digest.
|
||||
var/hydration_factor = 0 // Per removed in digest.
|
||||
/// Per removed in digest.
|
||||
var/nutriment_factor = 8
|
||||
/// Per removed in digest.
|
||||
var/hydration_factor = 0
|
||||
var/blood_factor = 2
|
||||
var/regen_factor = 0.8
|
||||
var/injectable = 0
|
||||
var/attrition_factor = -(REM * 4)/BASE_MAX_NUTRITION // Decreases attrition rate.
|
||||
/// Decreases attrition rate.
|
||||
var/attrition_factor = -(REM * 4)/BASE_MAX_NUTRITION
|
||||
color = "#664330"
|
||||
unaffected_species = IS_MACHINE
|
||||
taste_description = "food"
|
||||
@@ -59,6 +62,10 @@
|
||||
M.add_chemical_effect(CE_BLOODRESTORE, blood_factor * removed)
|
||||
M.intoxication -= min(M.intoxication,nutriment_factor*removed*0.05) //Nutrients can absorb alcohol.
|
||||
|
||||
/// Parent singleton. Provides fallback specific heat value to condiments unused in recipes.
|
||||
/singleton/reagent/condiment
|
||||
fallback_specific_heat = 1
|
||||
|
||||
//
|
||||
//Lipozine?
|
||||
//
|
||||
@@ -193,18 +200,19 @@
|
||||
if(amount >= 3)
|
||||
T.wet_floor(WET_TYPE_LUBE,amount)
|
||||
|
||||
//Calculates a scaling factor for scalding damage, based on the temperature of the oil and creature's heat resistance
|
||||
/// Calculates a scaling factor for scalding damage, based on the temperature of the oil and creature's heat resistance
|
||||
/singleton/reagent/nutriment/triglyceride/oil/proc/heatdamage(var/mob/living/carbon/M, var/datum/reagents/holder)
|
||||
var/threshold = 360//Human heatdamage threshold
|
||||
/// Human heatdamage threshold.
|
||||
var/threshold = 360
|
||||
var/datum/species/S = M.get_species(1)
|
||||
if (S && istype(S))
|
||||
threshold = S.heat_level_1
|
||||
|
||||
//If temperature is too low to burn, return a factor of 0. no damage
|
||||
// If temperature is too low to burn, return a factor of 0. no damage.
|
||||
if (holder.get_temperature() < threshold)
|
||||
return 0
|
||||
|
||||
//Step = degrees above heat level 1 for 1.0 multiplier
|
||||
/// Step = degrees above heat level 1 for 1.0 multiplier.
|
||||
var/step = 60
|
||||
if (S && istype(S))
|
||||
step = (S.heat_level_2 - S.heat_level_1)*1.5
|
||||
|
||||
+10
-10
@@ -1,9 +1,9 @@
|
||||
/*
|
||||
Coatings are used in cooking. Dipping food items in a reagent container with a coating in it
|
||||
allows it to be covered in that, which will add a masked overlay to the sprite.
|
||||
|
||||
Coatings have both a raw and a cooked image. Raw coating is generally unhealthy
|
||||
Generally coatings are intended for deep frying foods
|
||||
/**
|
||||
* Coatings are used in cooking. Dipping food items in a reagent container with a coating in it
|
||||
* allows it to be covered in that, which will add a masked overlay to the sprite.
|
||||
*
|
||||
* Coatings have both a raw and a cooked image. Raw coating is generally unhealthy
|
||||
* Generally coatings are intended for deep frying foodsGenerally coatings are intended for deep frying foods
|
||||
*/
|
||||
/singleton/reagent/nutriment/coating
|
||||
nutriment_factor = 4 //Less dense than the food itself, but coatings still add extra calories
|
||||
@@ -29,13 +29,13 @@
|
||||
H.delayed_vomit()
|
||||
. = ..()
|
||||
|
||||
/singleton/reagent/nutriment/coating/initialize_data(var/list/newdata, var/datum/reagents/holder) // Called when the reagent is created.
|
||||
/// Called when the reagent is created.
|
||||
/singleton/reagent/nutriment/coating/initialize_data(var/list/newdata, var/datum/reagents/holder)
|
||||
var/list/data = ..()
|
||||
LAZYSET(data, "cooked", istype(holder?.my_atom,/obj/item/reagent_containers/food/snacks))
|
||||
if(data["cooked"])
|
||||
name = cooked_name
|
||||
return data
|
||||
|
||||
//Batter which is part of objects at compiletime spawns in a cooked state
|
||||
|
||||
/singleton/reagent/nutriment/coating/mix_data(var/list/newdata, var/newamount, var/datum/reagents/holder)
|
||||
@@ -270,8 +270,8 @@
|
||||
condiment_name = "hotsauce"
|
||||
condiment_desc = "Hot sauce. It's in the name."
|
||||
condiment_icon_state = "hotsauce"
|
||||
|
||||
var/agony_dose = 15 // Capsaicin required to proc agony. (3 to 5 chilis.)
|
||||
/// Capsaicin required to proc agony. (3 to 5 chilis.)
|
||||
var/agony_dose = 15
|
||||
var/agony_amount = 1
|
||||
var/discomfort_message = SPAN_DANGER("Your insides feel uncomfortably hot.")
|
||||
var/slime_temp_adj = 10
|
||||
|
||||
@@ -2031,6 +2031,7 @@
|
||||
metabolism = REM*0.0001
|
||||
scannable = TRUE
|
||||
taste_description = "pure death"
|
||||
fallback_specific_heat = 1
|
||||
|
||||
/singleton/reagent/antibodies/affect_blood(mob/living/carbon/M, alien, removed, datum/reagents/holder)
|
||||
. = ..()
|
||||
@@ -2042,7 +2043,8 @@
|
||||
Z.curing = TRUE
|
||||
to_chat(M, SPAN_WARNING("Your [E.name] tightens, pulses, and squirms as \the [Z] fights back against the antibodies!"))
|
||||
|
||||
/singleton/reagent/caffeine // Copied from Hyperzine
|
||||
/// Copied from Hyperzine
|
||||
/singleton/reagent/caffeine
|
||||
name = "Caffeine"
|
||||
description = "Caffeine is a central nervous system stimulant found naturally in many plants. It's used as a mild cognitive enhancer to increase alertness, attentional performance, and improve cardiovascular health."
|
||||
reagent_state = SOLID
|
||||
@@ -2053,6 +2055,7 @@
|
||||
taste_description = "bitter"
|
||||
metabolism_min = REM * 0.025
|
||||
breathe_met = REM * 0.15 * 0.5
|
||||
fallback_specific_heat = 1
|
||||
|
||||
/singleton/reagent/caffeine/initial_effect(mob/living/carbon/M, alien, datum/reagents/holder)
|
||||
. = ..()
|
||||
|
||||
Reference in New Issue
Block a user