[MIRROR] Renames delta time to be a more obvious name [MDB IGNORE] (#20507)

* Renames delta time to be a more obvious name

* updates to our code

---------

Co-authored-by: oranges <email@oranges.net.nz>
Co-authored-by: Gandalf <9026500+Gandalf2k15@users.noreply.github.com>
This commit is contained in:
SkyratBot
2023-04-12 21:45:43 +02:00
committed by GitHub
parent 34b66981ce
commit 9a594755f3
540 changed files with 3418 additions and 3424 deletions

View File

@@ -179,25 +179,25 @@
return TRUE
/*
* Deals with lag - allows a reaction to speed up to 3x from delta_time
* Deals with lag - allows a reaction to speed up to 3x from seconds_per_tick
* "Charged" time (time_deficit) discharges by incrementing reactions by doubling them
* If delta_time is greater than 1.5, then we save the extra time for the next ticks
* If seconds_per_tick is greater than 1.5, then we save the extra time for the next ticks
*
* Arguments:
* * delta_time - the time between the last proc in world.time
* * seconds_per_tick - the time between the last proc in world.time
*/
/datum/equilibrium/proc/deal_with_time(delta_time)
if(delta_time > 1)
time_deficit += delta_time - 1
delta_time = 1 //Lets make sure reactions aren't super speedy and blow people up from a big lag spike
/datum/equilibrium/proc/deal_with_time(seconds_per_tick)
if(seconds_per_tick > 1)
time_deficit += seconds_per_tick - 1
seconds_per_tick = 1 //Lets make sure reactions aren't super speedy and blow people up from a big lag spike
else if (time_deficit)
if(time_deficit < 0.25)
delta_time += time_deficit
seconds_per_tick += time_deficit
time_deficit = 0
else
delta_time += 0.25
seconds_per_tick += 0.25
time_deficit -= 0.25
return delta_time
return seconds_per_tick
/*
* Main method of checking for explosive - or failed states
@@ -239,10 +239,10 @@
* Then adds/removes reagents
* Then alters the holder pH and temperature, and calls reaction_step
* Arguments:
* * delta_time - the time displacement between the last call and the current, 1 is a standard step
* * seconds_per_tick - the time displacement between the last call and the current, 1 is a standard step
* * purity_modifier - how much to modify the step's purity by (0 - 1)
*/
/datum/equilibrium/proc/react_timestep(delta_time, purity_modifier = 1)
/datum/equilibrium/proc/react_timestep(seconds_per_tick, purity_modifier = 1)
if(to_delete)
//This occurs when it explodes
return FALSE
@@ -252,7 +252,7 @@
if(!calculate_yield())//So that this can detect if we're missing reagents
to_delete = TRUE
return
delta_time = deal_with_time(delta_time)
seconds_per_tick = deal_with_time(seconds_per_tick)
delta_t = 0 //how far off optimal temp we care
delta_ph = 0 //How far off the pH we are
@@ -319,7 +319,7 @@
purity *= purity_modifier
//Now we calculate how much to add - this is normalised to the rate up limiter
var/delta_chem_factor = (reaction.rate_up_lim*delta_t)*delta_time//add/remove factor
var/delta_chem_factor = (reaction.rate_up_lim*delta_t)*seconds_per_tick//add/remove factor
var/total_step_added = 0
//keep limited
if(delta_chem_factor > step_target_vol)
@@ -362,7 +362,7 @@
if(GLOB.Debug2) //I want my spans for my sanity
message_admins("<span class='green'>Reaction step active for:[reaction.type]</span>")
message_admins("<span class='notice'>|Reaction conditions| Temp: [holder.chem_temp], pH: [holder.ph], reactions: [length(holder.reaction_list)], awaiting reactions: [length(holder.failed_but_capable_reactions)], no. reagents:[length(holder.reagent_list)], no. prev reagents: [length(holder.previous_reagent_list)]</span>")
message_admins("<span class='warning'>Reaction vars: PreReacted:[reacted_vol] of [step_target_vol] of total [target_vol]. delta_t [delta_t], multiplier [multiplier], delta_chem_factor [delta_chem_factor] Pfactor [product_ratio], purity of [purity] from a delta_ph of [delta_ph]. DeltaTime: [delta_time]</span>")
message_admins("<span class='warning'>Reaction vars: PreReacted:[reacted_vol] of [step_target_vol] of total [target_vol]. delta_t [delta_t], multiplier [multiplier], delta_chem_factor [delta_chem_factor] Pfactor [product_ratio], purity of [purity] from a delta_ph of [delta_ph]. DeltaTime: [seconds_per_tick]</span>")
#endif
//Apply thermal output of reaction to beaker

View File

@@ -709,12 +709,12 @@
*
* Arguments:
* * mob/living/carbon/carbon - The mob to metabolize in, if null it uses [/datum/reagents/var/my_atom]
* * delta_time - the time in server seconds between proc calls (when performing normally it will be 2)
* * seconds_per_tick - the time in server seconds between proc calls (when performing normally it will be 2)
* * times_fired - the number of times the owner's life() tick has been called aka The number of times SSmobs has fired
* * can_overdose - Allows overdosing
* * liverless - Stops reagents that aren't set as [/datum/reagent/var/self_consuming] from metabolizing
*/
/datum/reagents/proc/metabolize(mob/living/carbon/owner, delta_time, times_fired, can_overdose = FALSE, liverless = FALSE, dead = FALSE)
/datum/reagents/proc/metabolize(mob/living/carbon/owner, seconds_per_tick, times_fired, can_overdose = FALSE, liverless = FALSE, dead = FALSE)
var/list/cached_reagents = reagent_list
if(owner)
expose_temperature(owner.bodytemperature, 0.25)
@@ -736,10 +736,10 @@
amount += belly.reagents.get_reagent_amount(toxin.type)
if(amount <= liver_tolerance)
owner.reagents.remove_reagent(toxin.type, toxin.metabolization_rate * owner.metabolism_efficiency * delta_time)
owner.reagents.remove_reagent(toxin.type, toxin.metabolization_rate * owner.metabolism_efficiency * seconds_per_tick)
continue
need_mob_update += metabolize_reagent(owner, reagent, delta_time, times_fired, can_overdose, liverless, dead)
need_mob_update += metabolize_reagent(owner, reagent, seconds_per_tick, times_fired, can_overdose, liverless, dead)
if(owner && need_mob_update) //some of the metabolized reagents had effects on the mob that requires some updates.
owner.updatehealth()
@@ -750,12 +750,12 @@
*
* Arguments:
* * mob/living/carbon/owner - The mob to metabolize in, if null it uses [/datum/reagents/var/my_atom]
* * delta_time - the time in server seconds between proc calls (when performing normally it will be 2)
* * seconds_per_tick - the time in server seconds between proc calls (when performing normally it will be 2)
* * times_fired - the number of times the owner's life() tick has been called aka The number of times SSmobs has fired
* * can_overdose - Allows overdosing
* * liverless - Stops reagents that aren't set as [/datum/reagent/var/self_consuming] from metabolizing
*/
/datum/reagents/proc/metabolize_reagent(mob/living/carbon/owner, datum/reagent/reagent, delta_time, times_fired, can_overdose = FALSE, liverless = FALSE, dead = FALSE)
/datum/reagents/proc/metabolize_reagent(mob/living/carbon/owner, datum/reagent/reagent, seconds_per_tick, times_fired, can_overdose = FALSE, liverless = FALSE, dead = FALSE)
var/need_mob_update = FALSE
if(QDELETED(reagent.holder))
return FALSE
@@ -788,7 +788,7 @@
//SKYRAT EDIT ADDITION END
if(owner && reagent && (!dead || (reagent.chemical_flags & REAGENT_DEAD_PROCESS)))
if(owner.reagent_check(reagent, delta_time, times_fired))
if(owner.reagent_check(reagent, seconds_per_tick, times_fired))
return
if(liverless && !reagent.self_consuming) //need to be metabolized
return
@@ -805,11 +805,11 @@
owner.mind?.add_addiction_points(addiction, reagent.addiction_types[addiction] * REAGENTS_METABOLISM)
if(reagent.overdosed)
need_mob_update += reagent.overdose_process(owner, delta_time, times_fired)
need_mob_update += reagent.overdose_process(owner, seconds_per_tick, times_fired)
if(!dead)
need_mob_update += reagent.on_mob_life(owner, delta_time, times_fired)
need_mob_update += reagent.on_mob_life(owner, seconds_per_tick, times_fired)
if(dead)
need_mob_update += reagent.on_mob_dead(owner, delta_time)
need_mob_update += reagent.on_mob_dead(owner, seconds_per_tick)
return need_mob_update
/// Signals that metabolization has stopped, triggering the end of trait-based effects
@@ -855,12 +855,12 @@
return added_volume
///Processes any chems that have the REAGENT_IGNORE_STASIS bitflag ONLY
/datum/reagents/proc/handle_stasis_chems(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagents/proc/handle_stasis_chems(mob/living/carbon/owner, seconds_per_tick, times_fired)
var/need_mob_update = FALSE
for(var/datum/reagent/reagent as anything in reagent_list)
if(!(reagent.chemical_flags & REAGENT_IGNORE_STASIS))
continue
need_mob_update += metabolize_reagent(owner, reagent, delta_time, times_fired, can_overdose = TRUE)
need_mob_update += metabolize_reagent(owner, reagent, seconds_per_tick, times_fired, can_overdose = TRUE)
if(owner && need_mob_update) //some of the metabolized reagents had effects on the mob that requires some updates.
owner.updatehealth()
update_total()
@@ -1025,9 +1025,9 @@
* If any are ended, it displays the reaction message and removes it from the reaction list
* If the list is empty at the end it finishes reacting.
* Arguments:
* * delta_time - the time between each time step
* * seconds_per_tick - the time between each time step
*/
/datum/reagents/process(delta_time)
/datum/reagents/process(seconds_per_tick)
if(!is_reacting)
force_stop_reacting()
stack_trace("[src] | [my_atom] was forced to stop reacting. This might be unintentional.")
@@ -1038,7 +1038,7 @@
var/num_reactions = 0
for(var/datum/equilibrium/equilibrium as anything in reaction_list)
//Continue reacting
equilibrium.react_timestep(delta_time)
equilibrium.react_timestep(seconds_per_tick)
num_reactions++
//if it's been flagged to delete
if(equilibrium.to_delete)
@@ -1048,7 +1048,7 @@
continue
SSblackbox.record_feedback("tally", "chemical_reaction", 1, "[equilibrium.reaction.type] total reaction steps")
if(num_reactions)
SEND_SIGNAL(src, COMSIG_REAGENTS_REACTION_STEP, num_reactions, delta_time)
SEND_SIGNAL(src, COMSIG_REAGENTS_REACTION_STEP, num_reactions, seconds_per_tick)
if(length(mix_message)) //This is only at the end
my_atom.audible_message(span_notice("[icon2html(my_atom, viewers(DEFAULT_MESSAGE_RANGE, src))] [mix_message.Join()]"))

View File

@@ -160,14 +160,14 @@
begin_processing()
/obj/machinery/chem_dispenser/process(delta_time)
/obj/machinery/chem_dispenser/process(seconds_per_tick)
if (recharge_counter >= 8)
var/usedpower = cell.give(recharge_amount)
if(usedpower)
use_power(active_power_usage + recharge_amount)
recharge_counter = 0
return
recharge_counter += delta_time
recharge_counter += seconds_per_tick
/obj/machinery/chem_dispenser/proc/display_beaker()
var/mutable_appearance/b_o = beaker_overlay || mutable_appearance(icon, "disp_beaker")

View File

@@ -99,7 +99,7 @@
if(in_range(user, src) || isobserver(user))
. += span_notice("The status display reads: Heating reagents at <b>[heater_coefficient*1000]%</b> speed.")
/obj/machinery/chem_heater/process(delta_time)
/obj/machinery/chem_heater/process(seconds_per_tick)
..()
//Tutorial logics
if(tutorial_active)
@@ -151,10 +151,10 @@
if(beaker.reagents.is_reacting)//on_reaction_step() handles this
return
//keep constant with the chemical acclimator please
beaker.reagents.adjust_thermal_energy((target_temperature - beaker.reagents.chem_temp) * heater_coefficient * delta_time * SPECIFIC_HEAT_DEFAULT * beaker.reagents.total_volume)
beaker.reagents.adjust_thermal_energy((target_temperature - beaker.reagents.chem_temp) * heater_coefficient * seconds_per_tick * SPECIFIC_HEAT_DEFAULT * beaker.reagents.total_volume)
beaker.reagents.handle_reactions()
use_power(active_power_usage * delta_time)
use_power(active_power_usage * seconds_per_tick)
/obj/machinery/chem_heater/attackby(obj/item/I, mob/user, params)
if(default_deconstruction_screwdriver(user, "mixer0b", "mixer0b", I))
@@ -190,10 +190,10 @@
return ..()
///Forces a UI update every time a reaction step happens inside of the beaker it contains. This is so the UI is in sync with the reaction since it's important that the output matches the current conditions for pH adjustment and temperature.
/obj/machinery/chem_heater/proc/on_reaction_step(datum/reagents/holder, num_reactions, delta_time)
/obj/machinery/chem_heater/proc/on_reaction_step(datum/reagents/holder, num_reactions, seconds_per_tick)
SIGNAL_HANDLER
if(on)
holder.adjust_thermal_energy((target_temperature - beaker.reagents.chem_temp) * heater_coefficient * delta_time * SPECIFIC_HEAT_DEFAULT * beaker.reagents.total_volume * (rand(8,11) * 0.1))//Give it a little wiggle room since we're actively reacting
holder.adjust_thermal_energy((target_temperature - beaker.reagents.chem_temp) * heater_coefficient * seconds_per_tick * SPECIFIC_HEAT_DEFAULT * beaker.reagents.total_volume * (rand(8,11) * 0.1))//Give it a little wiggle room since we're actively reacting
for(var/ui_client in ui_client_list)
var/datum/tgui/ui = ui_client
if(!ui)

View File

@@ -299,7 +299,7 @@ This will not clean any inverted reagents. Inverted reagents will still be corre
/* processing procs */
///Increments time if it's progressing - if it's past time then it purifies and stops processing
/obj/machinery/chem_mass_spec/process(delta_time)
/obj/machinery/chem_mass_spec/process(seconds_per_tick)
. = ..()
if(!is_operational)
return FALSE
@@ -313,7 +313,7 @@ This will not clean any inverted reagents. Inverted reagents will still be corre
end_processing()
update_appearance()
return TRUE
progress_time += delta_time
progress_time += seconds_per_tick
return FALSE
/*

View File

@@ -90,7 +90,7 @@
* The main loop that sets up, creates and displays results from a reaction
* warning: this code is a hot mess
*/
/obj/machinery/chem_recipe_debug/process(delta_time)
/obj/machinery/chem_recipe_debug/process(seconds_per_tick)
if(processing == FALSE)
setup_reactions()
if(should_force_ph)
@@ -98,7 +98,7 @@
if(should_force_temp)
reagents.chem_temp = force_temp
if(reagents.is_reacting == TRUE)
react_time += delta_time
react_time += seconds_per_tick
return
if(reaction_stated == TRUE)
reaction_stated = FALSE

View File

@@ -213,7 +213,7 @@
return FALSE
return TRUE
/obj/structure/chem_separator/process(delta_time)
/obj/structure/chem_separator/process(seconds_per_tick)
var/datum/gas_mixture/air = return_air()
if(!can_process(air))
return stop()
@@ -221,7 +221,7 @@
var/turf/location = loc
location.hotspot_expose(exposed_temperature = 700, exposed_volume = 5)
if(reagents.chem_temp < required_temp)
reagents.adjust_thermal_energy(heating_rate * delta_time * SPECIFIC_HEAT_DEFAULT * reagents.maximum_volume)
reagents.adjust_thermal_energy(heating_rate * seconds_per_tick * SPECIFIC_HEAT_DEFAULT * reagents.maximum_volume)
reagents.chem_temp = min(reagents.chem_temp, required_temp)
update_appearance(UPDATE_ICON)
return
@@ -229,7 +229,7 @@
if(!boiling)
boiling = TRUE
soundloop.start()
var/vapor_amount = distillation_rate * delta_time
var/vapor_amount = distillation_rate * seconds_per_tick
// Vapor to condenser
reagents.trans_id_to(condenser, separating_reagent.type, vapor_amount)
// Cool the vapor down

View File

@@ -156,11 +156,11 @@ GLOBAL_LIST_INIT(name2reagent, build_name2reagent())
return
/// Called from [/datum/reagents/proc/metabolize]
/datum/reagent/proc/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/proc/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
current_cycle++
if(length(reagent_removal_skip_list))
return
holder.remove_reagent(type, metabolization_rate * M.metabolism_efficiency * delta_time) //By default it slowly disappears.
holder.remove_reagent(type, metabolization_rate * M.metabolism_efficiency * seconds_per_tick) //By default it slowly disappears.
/*
Used to run functions before a reagent is transfered. Returning TRUE will block the transfer attempt.
@@ -192,13 +192,13 @@ Primarily used in reagents/reaction_agents
return
/// Called when a reagent is inside of a mob when they are dead
/datum/reagent/proc/on_mob_dead(mob/living/carbon/C, delta_time)
/datum/reagent/proc/on_mob_dead(mob/living/carbon/C, seconds_per_tick)
if(!(chemical_flags & REAGENT_DEAD_PROCESS))
return
current_cycle++
if(length(reagent_removal_skip_list))
return
holder.remove_reagent(type, metabolization_rate * C.metabolism_efficiency * delta_time)
holder.remove_reagent(type, metabolization_rate * C.metabolism_efficiency * seconds_per_tick)
/// Called by [/datum/reagents/proc/conditional_update_move]
/datum/reagent/proc/on_move(mob/M)
@@ -218,7 +218,7 @@ Primarily used in reagents/reaction_agents
return
/// Called if the reagent has passed the overdose threshold and is set to be triggering overdose effects
/datum/reagent/proc/overdose_process(mob/living/M, delta_time, times_fired)
/datum/reagent/proc/overdose_process(mob/living/M, seconds_per_tick, times_fired)
return
/// Called when an overdose starts

View File

@@ -49,7 +49,7 @@
addiction_types = list(/datum/addiction/alcohol = 0.05 * boozepwr)
return ..()
/datum/reagent/consumable/ethanol/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.get_drunk_amount() < volume * boozepwr * ALCOHOL_THRESHOLD_MODIFIER || boozepwr < 0)
var/booze_power = boozepwr
if(HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE)) //we're an accomplished drinker
@@ -57,11 +57,11 @@
if(HAS_TRAIT(drinker, TRAIT_LIGHT_DRINKER))
booze_power *= 2
// Volume, power, and server alcohol rate effect how quickly one gets drunk
drinker.adjust_drunk_effect(sqrt(volume) * booze_power * ALCOHOL_RATE * REM * delta_time)
drinker.adjust_drunk_effect(sqrt(volume) * booze_power * ALCOHOL_RATE * REM * seconds_per_tick)
if(boozepwr > 0)
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
if (istype(liver))
liver.apply_organ_damage(((max(sqrt(volume) * (boozepwr ** ALCOHOL_EXPONENT) * liver.alcohol_tolerance * delta_time, 0))/150))
liver.apply_organ_damage(((max(sqrt(volume) * (boozepwr ** ALCOHOL_EXPONENT) * liver.alcohol_tolerance * seconds_per_tick, 0))/150))
return ..()
/datum/reagent/consumable/ethanol/expose_obj(obj/exposed_obj, reac_volume)
@@ -160,7 +160,7 @@
desc = "A freezing pint of green beer. Festive."
icon_state = "greenbeerglass"
/datum/reagent/consumable/ethanol/beer/green/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/beer/green/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.color != color)
drinker.add_atom_colour(color, TEMPORARY_COLOUR_PRIORITY)
return ..()
@@ -186,10 +186,10 @@
desc = "DAMN, THIS THING LOOKS ROBUST!"
icon_state ="kahluaglass"
/datum/reagent/consumable/ethanol/kahlua/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_dizzy_if_lower(10 SECONDS * REM * delta_time)
drinker.adjust_drowsiness(-6 SECONDS * REM * delta_time)
drinker.AdjustSleeping(-40 * REM * delta_time)
/datum/reagent/consumable/ethanol/kahlua/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_dizzy_if_lower(10 SECONDS * REM * seconds_per_tick)
drinker.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
drinker.AdjustSleeping(-40 * REM * seconds_per_tick)
if(!HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE))
drinker.set_jitter_if_lower(10 SECONDS)
..()
@@ -245,9 +245,9 @@
name = "glass of candy corn liquor"
desc = "Good for your Imagination."
/datum/reagent/consumable/ethanol/whiskey/candycorn/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(5, delta_time))
drinker.adjust_hallucinations(4 SECONDS * REM * delta_time)
/datum/reagent/consumable/ethanol/whiskey/candycorn/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(5, seconds_per_tick))
drinker.adjust_hallucinations(4 SECONDS * REM * seconds_per_tick)
..()
/datum/reagent/consumable/ethanol/thirteenloko
@@ -267,10 +267,10 @@
desc = "This is a glass of Thirteen Loko, it appears to be of the highest quality. The drink, not the glass."
icon_state = "thirteen_loko_glass"
/datum/reagent/consumable/ethanol/thirteenloko/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_drowsiness(-14 SECONDS * REM * delta_time)
drinker.AdjustSleeping(-40 * REM * delta_time)
drinker.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, drinker.get_body_temp_normal())
/datum/reagent/consumable/ethanol/thirteenloko/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_drowsiness(-14 SECONDS * REM * seconds_per_tick)
drinker.AdjustSleeping(-40 * REM * seconds_per_tick)
drinker.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, drinker.get_body_temp_normal())
if(!HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE))
drinker.set_jitter_if_lower(10 SECONDS)
..()
@@ -281,18 +281,18 @@
drinker.set_jitter_if_lower(40 SECONDS)
drinker.Stun(1.5 SECONDS)
/datum/reagent/consumable/ethanol/thirteenloko/overdose_process(mob/living/drinker, delta_time, times_fired)
if(DT_PROB(3.5, delta_time) && iscarbon(drinker))
/datum/reagent/consumable/ethanol/thirteenloko/overdose_process(mob/living/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(3.5, seconds_per_tick) && iscarbon(drinker))
var/obj/item/held_item = drinker.get_active_held_item()
if(held_item)
drinker.dropItemToGround(held_item)
to_chat(drinker, span_notice("Your hands jitter and you drop what you were holding!"))
drinker.set_jitter_if_lower(20 SECONDS)
if(DT_PROB(3.5, delta_time))
if(SPT_PROB(3.5, seconds_per_tick))
to_chat(drinker, span_notice("[pick("You have a really bad headache.", "Your eyes hurt.", "You find it hard to stay still.", "You feel your heart practically beating out of your chest.")]"))
if(DT_PROB(2.5, delta_time) && iscarbon(drinker))
if(SPT_PROB(2.5, seconds_per_tick) && iscarbon(drinker))
var/obj/item/organ/internal/eyes/eyes = drinker.get_organ_slot(ORGAN_SLOT_EYES)
if(drinker.is_blind())
if(istype(eyes))
@@ -306,12 +306,12 @@
eyes.apply_organ_damage(eyes.maxHealth)
drinker.emote("scream")
if(DT_PROB(1.5, delta_time) && iscarbon(drinker))
if(SPT_PROB(1.5, seconds_per_tick) && iscarbon(drinker))
drinker.visible_message(span_danger("[drinker] starts having a seizure!"), span_userdanger("You have a seizure!"))
drinker.Unconscious(10 SECONDS)
drinker.set_jitter_if_lower(700 SECONDS)
if(DT_PROB(0.5, delta_time) && iscarbon(drinker))
if(SPT_PROB(0.5, seconds_per_tick) && iscarbon(drinker))
var/datum/disease/heart_attack = new /datum/disease/heart_failure
drinker.ForceContractDisease(heart_attack)
to_chat(drinker, span_userdanger("You're pretty sure you just felt your heart stop for a second there.."))
@@ -352,8 +352,8 @@
desc = "A brew of milk and beer. For those alcoholics who fear osteoporosis."
icon_state = "glass_brown"
/datum/reagent/consumable/ethanol/bilk/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(drinker.getBruteLoss() && DT_PROB(5, delta_time))
/datum/reagent/consumable/ethanol/bilk/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.getBruteLoss() && SPT_PROB(5, seconds_per_tick))
drinker.heal_bodypart_damage(brute = 1)
. = TRUE
return ..() || .
@@ -375,8 +375,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "threemileislandglass"
/datum/reagent/consumable/ethanol/threemileisland/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_drugginess(100 SECONDS * REM * delta_time)
/datum/reagent/consumable/ethanol/threemileisland/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_drugginess(100 SECONDS * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/ethanol/gin
@@ -571,8 +571,8 @@
desc = "It's as strong as it smells."
icon_state = "absinthe"
/datum/reagent/consumable/ethanol/absinthe/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(5, delta_time) && !HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE))
/datum/reagent/consumable/ethanol/absinthe/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(5, seconds_per_tick) && !HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE))
drinker.adjust_hallucinations(8 SECONDS)
..()
@@ -723,12 +723,12 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "cubalibreglass"
/datum/reagent/consumable/ethanol/cuba_libre/on_mob_life(mob/living/carbon/cubano, delta_time, times_fired)
/datum/reagent/consumable/ethanol/cuba_libre/on_mob_life(mob/living/carbon/cubano, seconds_per_tick, times_fired)
if(cubano.mind && cubano.mind.has_antag_datum(/datum/antagonist/rev)) //Cuba Libre, the traditional drink of revolutions! Heals revolutionaries.
cubano.adjustBruteLoss(-1 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
cubano.adjustFireLoss(-1 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
cubano.adjustToxLoss(-1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
cubano.adjustOxyLoss(-5 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
cubano.adjustBruteLoss(-1 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
cubano.adjustFireLoss(-1 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
cubano.adjustToxLoss(-1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
cubano.adjustOxyLoss(-5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
. = TRUE
return ..() || .
@@ -843,12 +843,12 @@
COMSIG_REAGENTS_REACTED,
))
/datum/reagent/consumable/ethanol/screwdrivercocktail/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/screwdrivercocktail/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
if(HAS_TRAIT(liver, TRAIT_ENGINEER_METABOLISM))
ADD_TRAIT(drinker, TRAIT_HALT_RADIATION_EFFECTS, "[type]")
if (HAS_TRAIT(drinker, TRAIT_IRRADIATED))
drinker.adjustToxLoss(-2 * REM * delta_time, required_biotype = affected_biotype)
drinker.adjustToxLoss(-2 * REM * seconds_per_tick, required_biotype = affected_biotype)
return ..()
@@ -887,9 +887,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "bloodymaryglass"
/datum/reagent/consumable/ethanol/bloody_mary/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/bloody_mary/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.blood_volume < BLOOD_VOLUME_NORMAL)
drinker.blood_volume = min(drinker.blood_volume + (1 * REM * delta_time), BLOOD_VOLUME_NORMAL) //Bloody Mary quickly restores blood loss. // SKYRAT EDIT - Bloodshot is now the go-to drink for bloodloss, not Bloody Mary - ORIGINAL: drinker.blood_volume = min(drinker.blood_volume + (3 * REM * delta_time), BLOOD_VOLUME_NORMAL)
drinker.blood_volume = min(drinker.blood_volume + (1 * REM * seconds_per_tick), BLOOD_VOLUME_NORMAL) //Bloody Mary quickly restores blood loss. // SKYRAT EDIT - Bloodshot is now the go-to drink for bloodloss, not Bloody Mary - ORIGINAL: drinker.blood_volume = min(drinker.blood_volume + (3 * REM * delta_time), BLOOD_VOLUME_NORMAL)
..()
/datum/reagent/consumable/ethanol/brave_bull
@@ -946,7 +946,7 @@
light_holder = new(drinker)
light_holder.set_light(3, 0.7, "#FFCC00") //Tequila Sunrise makes you radiate dim light, like a sunrise!
/datum/reagent/consumable/ethanol/tequila_sunrise/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/tequila_sunrise/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(QDELETED(light_holder))
holder.del_reagent(type) //If we lost our light object somehow, remove the reagent
else if(light_holder.loc != drinker)
@@ -978,8 +978,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "toxinsspecialglass"
/datum/reagent/consumable/ethanol/toxins_special/on_mob_life(mob/living/drinker, delta_time, times_fired)
drinker.adjust_bodytemperature(15 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, drinker.get_body_temp_normal() + 20) //310.15 is the normal bodytemp.
/datum/reagent/consumable/ethanol/toxins_special/on_mob_life(mob/living/drinker, seconds_per_tick, times_fired)
drinker.adjust_bodytemperature(15 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, drinker.get_body_temp_normal() + 20) //310.15 is the normal bodytemp.
return ..()
/datum/reagent/consumable/ethanol/beepsky_smash
@@ -1012,16 +1012,16 @@
drinker.gain_trauma(beepsky_hallucination, TRAUMA_RESILIENCE_ABSOLUTE)
..()
/datum/reagent/consumable/ethanol/beepsky_smash/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/beepsky_smash/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_jitter_if_lower(4 SECONDS)
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
// if you have a liver and that liver is an officer's liver
if(liver && HAS_TRAIT(liver, TRAIT_LAW_ENFORCEMENT_METABOLISM))
. = TRUE
drinker.adjustStaminaLoss(-10 * REM * delta_time, required_biotype = affected_biotype)
if(DT_PROB(10, delta_time))
drinker.adjustStaminaLoss(-10 * REM * seconds_per_tick, required_biotype = affected_biotype)
if(SPT_PROB(10, seconds_per_tick))
drinker.cause_hallucination(get_random_valid_hallucination_subtype(/datum/hallucination/nearby_fake_item), name)
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
drinker.cause_hallucination(/datum/hallucination/stray_bullet, name)
..()
@@ -1077,10 +1077,10 @@
boozepwr = 50 // will still smash but not as much.
dorf_mode = TRUE
/datum/reagent/consumable/ethanol/manly_dorf/on_mob_life(mob/living/carbon/dwarf, delta_time, times_fired)
/datum/reagent/consumable/ethanol/manly_dorf/on_mob_life(mob/living/carbon/dwarf, seconds_per_tick, times_fired)
if(dorf_mode)
dwarf.adjustBruteLoss(-2 * REM * delta_time, required_bodytype = affected_bodytype)
dwarf.adjustFireLoss(-2 * REM * delta_time, required_bodytype = affected_bodytype)
dwarf.adjustBruteLoss(-2 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
dwarf.adjustFireLoss(-2 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
return ..()
/datum/reagent/consumable/ethanol/longislandicedtea
@@ -1220,8 +1220,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "proj_manhattanglass"
/datum/reagent/consumable/ethanol/manhattan_proj/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_drugginess(1 MINUTES * REM * delta_time)
/datum/reagent/consumable/ethanol/manhattan_proj/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_drugginess(1 MINUTES * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/ethanol/whiskeysoda
@@ -1255,8 +1255,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "antifreeze"
/datum/reagent/consumable/ethanol/antifreeze/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_bodytemperature(20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, drinker.get_body_temp_normal() + 20) //310.15 is the normal bodytemp.
/datum/reagent/consumable/ethanol/antifreeze/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_bodytemperature(20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, drinker.get_body_temp_normal() + 20) //310.15 is the normal bodytemp.
return ..()
/datum/reagent/consumable/ethanol/barefoot
@@ -1275,11 +1275,11 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "b&p"
/datum/reagent/consumable/ethanol/barefoot/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/barefoot/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(ishuman(drinker)) //Barefoot causes the imbiber to quickly regenerate brute trauma if they're not wearing shoes.
var/mob/living/carbon/human/unshoed = drinker
if(!unshoed.shoes)
unshoed.adjustBruteLoss(-3 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
unshoed.adjustBruteLoss(-3 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
. = TRUE
return ..() || .
@@ -1458,8 +1458,8 @@
REMOVE_TRAIT(drinker, TRAIT_MADNESS_IMMUNE, type)
drinker.remove_filter("singulo_rays")
/datum/reagent/consumable/ethanol/singulo/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(2.5, delta_time))
/datum/reagent/consumable/ethanol/singulo/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(2.5, seconds_per_tick))
// 20u = 1x1, 45u = 2x2, 80u = 3x3
var/volume_to_radius = FLOOR(sqrt(volume/5), 1) - 1
var/suck_range = clamp(volume_to_radius, 0, 3)
@@ -1492,8 +1492,8 @@
taste_description = "hot and spice"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/ethanol/sbiten/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_bodytemperature(50 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, BODYTEMP_HEAT_DAMAGE_LIMIT) //310.15 is the normal bodytemp.
/datum/reagent/consumable/ethanol/sbiten/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_bodytemperature(50 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, BODYTEMP_HEAT_DAMAGE_LIMIT) //310.15 is the normal bodytemp.
return ..()
/datum/reagent/consumable/ethanol/red_mead
@@ -1543,8 +1543,8 @@
desc = "A beer so frosty, the air around it freezes."
icon_state = "iced_beerglass"
/datum/reagent/consumable/ethanol/iced_beer/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_bodytemperature(-20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, T0C) //310.15 is the normal bodytemp.
/datum/reagent/consumable/ethanol/iced_beer/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_bodytemperature(-20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, T0C) //310.15 is the normal bodytemp.
return ..()
/datum/reagent/consumable/ethanol/grog
@@ -1658,9 +1658,9 @@
icon = 'icons/obj/drinks/soda.dmi'
icon_state = "changelingsting"
/datum/reagent/consumable/ethanol/changelingsting/on_mob_life(mob/living/carbon/target, delta_time, times_fired)
/datum/reagent/consumable/ethanol/changelingsting/on_mob_life(mob/living/carbon/target, seconds_per_tick, times_fired)
var/datum/antagonist/changeling/changeling = target.mind?.has_antag_datum(/datum/antagonist/changeling)
changeling?.adjust_chemicals(metabolization_rate * REM * delta_time)
changeling?.adjust_chemicals(metabolization_rate * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/ethanol/irishcarbomb
@@ -1694,8 +1694,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "syndicatebomb"
/datum/reagent/consumable/ethanol/syndicatebomb/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(2.5, delta_time))
/datum/reagent/consumable/ethanol/syndicatebomb/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(2.5, seconds_per_tick))
playsound(get_turf(drinker), 'sound/effects/explosionfar.ogg', 100, TRUE)
return ..()
@@ -1765,10 +1765,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "bananahonkglass"
/datum/reagent/consumable/ethanol/bananahonk/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/bananahonk/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
if((liver && HAS_TRAIT(liver, TRAIT_COMEDY_METABOLISM)) || ismonkey(drinker))
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
return ..() || .
@@ -1789,10 +1789,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "silencerglass"
/datum/reagent/consumable/ethanol/silencer/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/silencer/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(ishuman(drinker) && HAS_TRAIT(drinker, TRAIT_MIMING))
drinker.set_silence_if_lower(MIMEDRINK_SILENCE_DURATION)
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
return ..() || .
@@ -1863,7 +1863,7 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "fetching_fizz"
/datum/reagent/consumable/ethanol/fetching_fizz/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/fetching_fizz/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
for(var/obj/item/stack/ore/O in orange(3, drinker))
step_towards(O, get_turf(drinker))
return ..()
@@ -1886,13 +1886,13 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "hearty_punch"
/datum/reagent/consumable/ethanol/hearty_punch/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/hearty_punch/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.health <= 0)
drinker.adjustBruteLoss(-3 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-3 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
drinker.adjustCloneLoss(-5 * REM * delta_time, 0)
drinker.adjustOxyLoss(-4 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustToxLoss(-3 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjustBruteLoss(-3 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-3 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
drinker.adjustCloneLoss(-5 * REM * seconds_per_tick, 0)
drinker.adjustOxyLoss(-4 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustToxLoss(-3 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
return ..() || .
@@ -1927,19 +1927,19 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "atomicbombglass"
/datum/reagent/consumable/ethanol/atomicbomb/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_drugginess(100 SECONDS * REM * delta_time)
/datum/reagent/consumable/ethanol/atomicbomb/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_drugginess(100 SECONDS * REM * seconds_per_tick)
if(!HAS_TRAIT(drinker, TRAIT_ALCOHOL_TOLERANCE))
drinker.adjust_confusion(2 SECONDS * REM * delta_time)
drinker.set_dizzy_if_lower(20 SECONDS * REM * delta_time)
drinker.adjust_slurring(6 SECONDS * REM * delta_time)
drinker.adjust_confusion(2 SECONDS * REM * seconds_per_tick)
drinker.set_dizzy_if_lower(20 SECONDS * REM * seconds_per_tick)
drinker.adjust_slurring(6 SECONDS * REM * seconds_per_tick)
switch(current_cycle)
if(51 to 200)
drinker.Sleeping(100 * REM * delta_time)
drinker.Sleeping(100 * REM * seconds_per_tick)
. = TRUE
if(201 to INFINITY)
drinker.AdjustSleeping(40 * REM * delta_time)
drinker.adjustToxLoss(2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.AdjustSleeping(40 * REM * seconds_per_tick)
drinker.adjustToxLoss(2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -1959,19 +1959,19 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "gargleblasterglass"
/datum/reagent/consumable/ethanol/gargle_blaster/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_dizzy(3 SECONDS * REM * delta_time)
/datum/reagent/consumable/ethanol/gargle_blaster/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_dizzy(3 SECONDS * REM * seconds_per_tick)
switch(current_cycle)
if(15 to 45)
drinker.adjust_slurring(3 SECONDS * REM * delta_time)
drinker.adjust_slurring(3 SECONDS * REM * seconds_per_tick)
if(45 to 55)
if(DT_PROB(30, delta_time))
drinker.adjust_confusion(3 SECONDS * REM * delta_time)
if(SPT_PROB(30, seconds_per_tick))
drinker.adjust_confusion(3 SECONDS * REM * seconds_per_tick)
if(55 to 200)
drinker.set_drugginess(110 SECONDS * REM * delta_time)
drinker.set_drugginess(110 SECONDS * REM * seconds_per_tick)
if(200 to INFINITY)
drinker.adjustToxLoss(2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjustToxLoss(2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -1995,22 +1995,22 @@
/datum/reagent/consumable/ethanol/neurotoxin/proc/pick_paralyzed_limb()
return (pick(TRAIT_PARALYSIS_L_ARM,TRAIT_PARALYSIS_R_ARM,TRAIT_PARALYSIS_R_LEG,TRAIT_PARALYSIS_L_LEG))
/datum/reagent/consumable/ethanol/neurotoxin/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_drugginess(100 SECONDS * REM * delta_time)
drinker.adjust_dizzy(4 SECONDS * REM * delta_time)
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1 * REM * delta_time, 150, required_organtype = affected_organtype)
if(DT_PROB(10, delta_time))
/datum/reagent/consumable/ethanol/neurotoxin/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_drugginess(100 SECONDS * REM * seconds_per_tick)
drinker.adjust_dizzy(4 SECONDS * REM * seconds_per_tick)
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1 * REM * seconds_per_tick, 150, required_organtype = affected_organtype)
if(SPT_PROB(10, seconds_per_tick))
drinker.adjustStaminaLoss(10, required_biotype = affected_biotype)
drinker.drop_all_held_items()
to_chat(drinker, span_notice("You cant feel your hands!"))
if(current_cycle > 5)
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
var/paralyzed_limb = pick_paralyzed_limb()
ADD_TRAIT(drinker, paralyzed_limb, type)
drinker.adjustStaminaLoss(10, required_biotype = affected_biotype)
if(current_cycle > 30)
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2 * REM * delta_time, required_organtype = affected_organtype)
if(current_cycle > 50 && DT_PROB(7.5, delta_time))
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2 * REM * seconds_per_tick, required_organtype = affected_organtype)
if(current_cycle > 50 && SPT_PROB(7.5, seconds_per_tick))
if(!drinker.undergoing_cardiac_arrest() && drinker.can_heartattack())
drinker.set_heartattack(TRUE)
if(drinker.stat == CONSCIOUS)
@@ -2044,34 +2044,34 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "hippiesdelightglass"
/datum/reagent/consumable/ethanol/hippies_delight/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.set_slurring_if_lower(1 SECONDS * REM * delta_time)
/datum/reagent/consumable/ethanol/hippies_delight/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.set_slurring_if_lower(1 SECONDS * REM * seconds_per_tick)
switch(current_cycle)
if(1 to 5)
drinker.set_dizzy_if_lower(20 SECONDS * REM * delta_time)
drinker.set_drugginess(1 MINUTES * REM * delta_time)
if(DT_PROB(5, delta_time))
drinker.set_dizzy_if_lower(20 SECONDS * REM * seconds_per_tick)
drinker.set_drugginess(1 MINUTES * REM * seconds_per_tick)
if(SPT_PROB(5, seconds_per_tick))
drinker.emote(pick("twitch","giggle"))
if(5 to 10)
drinker.set_jitter_if_lower(40 SECONDS * REM * delta_time)
drinker.set_dizzy_if_lower(40 SECONDS * REM * delta_time)
drinker.set_drugginess(1.5 MINUTES * REM * delta_time)
if(DT_PROB(10, delta_time))
drinker.set_jitter_if_lower(40 SECONDS * REM * seconds_per_tick)
drinker.set_dizzy_if_lower(40 SECONDS * REM * seconds_per_tick)
drinker.set_drugginess(1.5 MINUTES * REM * seconds_per_tick)
if(SPT_PROB(10, seconds_per_tick))
drinker.emote(pick("twitch","giggle"))
if (10 to 200)
drinker.set_jitter_if_lower(80 SECONDS * REM * delta_time)
drinker.set_dizzy_if_lower(80 SECONDS * REM * delta_time)
drinker.set_drugginess(2 MINUTES * REM * delta_time)
if(DT_PROB(16, delta_time))
drinker.set_jitter_if_lower(80 SECONDS * REM * seconds_per_tick)
drinker.set_dizzy_if_lower(80 SECONDS * REM * seconds_per_tick)
drinker.set_drugginess(2 MINUTES * REM * seconds_per_tick)
if(SPT_PROB(16, seconds_per_tick))
drinker.emote(pick("twitch","giggle"))
if(200 to INFINITY)
drinker.set_jitter_if_lower(120 SECONDS * REM * delta_time)
drinker.set_dizzy_if_lower(120 SECONDS * REM * delta_time)
drinker.set_drugginess(2.5 MINUTES * REM * delta_time)
if(DT_PROB(23, delta_time))
drinker.set_jitter_if_lower(120 SECONDS * REM * seconds_per_tick)
drinker.set_dizzy_if_lower(120 SECONDS * REM * seconds_per_tick)
drinker.set_drugginess(2.5 MINUTES * REM * seconds_per_tick)
if(SPT_PROB(23, seconds_per_tick))
drinker.emote(pick("twitch","giggle"))
if(DT_PROB(16, delta_time))
if(SPT_PROB(16, seconds_per_tick))
drinker.adjustToxLoss(2, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -2116,9 +2116,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "narsour"
/datum/reagent/consumable/ethanol/narsour/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_timed_status_effect(6 SECONDS * REM * delta_time, /datum/status_effect/speech/slurring/cult, max_duration = 6 SECONDS)
drinker.adjust_stutter_up_to(6 SECONDS * REM * delta_time, 6 SECONDS)
/datum/reagent/consumable/ethanol/narsour/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_timed_status_effect(6 SECONDS * REM * seconds_per_tick, /datum/status_effect/speech/slurring/cult, max_duration = 6 SECONDS)
drinker.adjust_stutter_up_to(6 SECONDS * REM * seconds_per_tick, 6 SECONDS)
return ..()
/datum/reagent/consumable/ethanol/triple_sec
@@ -2193,11 +2193,11 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "quadruple_sec"
/datum/reagent/consumable/ethanol/quadruple_sec/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/quadruple_sec/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
//Securidrink in line with the Screwdriver for engineers or Nothing for mimes
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
if(liver && HAS_TRAIT(liver, TRAIT_LAW_ENFORCEMENT_METABOLISM))
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
return ..()
@@ -2217,12 +2217,12 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "quintuple_sec"
/datum/reagent/consumable/ethanol/quintuple_sec/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/quintuple_sec/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
//Securidrink in line with the Screwdriver for engineers or Nothing for mimes but STRONG..
var/obj/item/organ/internal/liver/liver = drinker.get_organ_slot(ORGAN_SLOT_LIVER)
if(liver && HAS_TRAIT(liver, TRAIT_LAW_ENFORCEMENT_METABOLISM))
drinker.heal_bodypart_damage(2 * REM * delta_time, 2 * REM * delta_time)
drinker.adjustStaminaLoss(-2 * REM * delta_time, required_biotype = affected_biotype)
drinker.heal_bodypart_damage(2 * REM * seconds_per_tick, 2 * REM * seconds_per_tick)
drinker.adjustStaminaLoss(-2 * REM * seconds_per_tick, required_biotype = affected_biotype)
. = TRUE
return ..()
@@ -2295,13 +2295,13 @@
if(!drinker.stat && heal_points == 20) //brought us out of softcrit
drinker.visible_message(span_danger("[drinker] lurches to [drinker.p_their()] feet!"), span_boldnotice("Up and at 'em, kid."))
/datum/reagent/consumable/ethanol/bastion_bourbon/on_mob_life(mob/living/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/bastion_bourbon/on_mob_life(mob/living/drinker, seconds_per_tick, times_fired)
if(drinker.health > 0)
drinker.adjustBruteLoss(-1 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-1 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustToxLoss(-0.5 * REM * delta_time, required_biotype = affected_biotype)
drinker.adjustOxyLoss(-3 * REM * delta_time, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustStaminaLoss(-5 * REM * delta_time, required_biotype = affected_biotype)
drinker.adjustBruteLoss(-1 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-1 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
drinker.adjustToxLoss(-0.5 * REM * seconds_per_tick, required_biotype = affected_biotype)
drinker.adjustOxyLoss(-3 * REM * seconds_per_tick, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustStaminaLoss(-5 * REM * seconds_per_tick, required_biotype = affected_biotype)
. = TRUE
..()
@@ -2325,8 +2325,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "squirt_cider"
/datum/reagent/consumable/ethanol/squirt_cider/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.satiety += 5 * REM * delta_time //for context, vitamins give 15 satiety per second
/datum/reagent/consumable/ethanol/squirt_cider/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.satiety += 5 * REM * seconds_per_tick //for context, vitamins give 15 satiety per second
..()
. = TRUE
@@ -2363,8 +2363,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "sugar_rush"
/datum/reagent/consumable/ethanol/sugar_rush/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.satiety -= 10 * REM * delta_time //junky as hell! a whole glass will keep you from being able to eat junk food
/datum/reagent/consumable/ethanol/sugar_rush/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.satiety -= 10 * REM * seconds_per_tick //junky as hell! a whole glass will keep you from being able to eat junk food
..()
. = TRUE
@@ -2418,9 +2418,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "peppermint_patty"
/datum/reagent/consumable/ethanol/peppermint_patty/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/peppermint_patty/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.apply_status_effect(/datum/status_effect/throat_soothed)
drinker.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, drinker.get_body_temp_normal())
drinker.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, drinker.get_body_temp_normal())
..()
@@ -2450,7 +2450,7 @@
to_chat(the_human, span_notice("[the_shield] appears polished, although you don't recall polishing it."))
return TRUE
/datum/reagent/consumable/ethanol/alexander/on_mob_life(mob/living/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/alexander/on_mob_life(mob/living/drinker, seconds_per_tick, times_fired)
..()
if(mighty_shield && !(mighty_shield in drinker.contents)) //If you had a shield and lose it, you lose the reagent as well. Otherwise this is just a normal drink.
holder.remove_reagent(type)
@@ -2511,7 +2511,7 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "between_the_sheets"
/datum/reagent/consumable/ethanol/between_the_sheets/on_mob_life(mob/living/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/between_the_sheets/on_mob_life(mob/living/drinker, seconds_per_tick, times_fired)
..()
var/is_between_the_sheets = FALSE
for(var/obj/item/bedsheet/bedsheet in range(drinker.loc, 0))
@@ -2525,13 +2525,13 @@
if(drinker.getBruteLoss() && drinker.getFireLoss()) //If you are damaged by both types, slightly increased healing but it only heals one. The more the merrier wink wink.
if(prob(50))
drinker.adjustBruteLoss(-0.25 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustBruteLoss(-0.25 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
else
drinker.adjustFireLoss(-0.25 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-0.25 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
else if(drinker.getBruteLoss()) //If you have only one, it still heals but not as well.
drinker.adjustBruteLoss(-0.2 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustBruteLoss(-0.2 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
else if(drinker.getFireLoss())
drinker.adjustFireLoss(-0.2 * REM * delta_time, required_bodytype = affected_bodytype)
drinker.adjustFireLoss(-0.2 * REM * seconds_per_tick, required_bodytype = affected_bodytype)
/datum/reagent/consumable/ethanol/kamikaze
name = "Kamikaze"
@@ -2595,10 +2595,10 @@
name = "glass of fernet"
desc = "A glass of pure Fernet. Only an absolute madman would drink this alone." //Hi Kevum
/datum/reagent/consumable/ethanol/fernet/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/fernet/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.nutrition <= NUTRITION_LEVEL_STARVING)
drinker.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjust_nutrition(-5 * REM * delta_time)
drinker.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
drinker.adjust_nutrition(-5 * REM * seconds_per_tick)
drinker.overeatduration = 0
return ..()
@@ -2618,10 +2618,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "godlyblend"
/datum/reagent/consumable/ethanol/fernet_cola/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/fernet_cola/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.nutrition <= NUTRITION_LEVEL_STARVING)
drinker.adjustToxLoss(0.5 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjust_nutrition(-3 * REM * delta_time)
drinker.adjustToxLoss(0.5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
drinker.adjust_nutrition(-3 * REM * seconds_per_tick)
drinker.overeatduration = 0
return ..()
@@ -2641,8 +2641,8 @@
desc = "A glass of Fanciulli. It's just Manhattan with Fernet."
icon_state = "fanciulli"
/datum/reagent/consumable/ethanol/fanciulli/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_nutrition(-5 * REM * delta_time)
/datum/reagent/consumable/ethanol/fanciulli/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_nutrition(-5 * REM * seconds_per_tick)
drinker.overeatduration = 0
return ..()
@@ -2668,8 +2668,8 @@
desc = "A glass of Branca Menta, perfect for those lazy and hot Sunday summer afternoons." //Get lazy literally by drinking this
icon_state = "minted_fernet"
/datum/reagent/consumable/ethanol/branca_menta/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_bodytemperature(-20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, T0C)
/datum/reagent/consumable/ethanol/branca_menta/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_bodytemperature(-20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, T0C)
return ..()
/datum/reagent/consumable/ethanol/branca_menta/on_mob_metabolize(mob/living/drinker)
@@ -2695,10 +2695,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "blank_paper"
/datum/reagent/consumable/ethanol/blank_paper/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/blank_paper/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(ishuman(drinker) && HAS_TRAIT(drinker, TRAIT_MIMING))
drinker.set_silence_if_lower(MIMEDRINK_SILENCE_DURATION)
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
return ..()
@@ -2846,13 +2846,13 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "wizz_fizz"
/datum/reagent/consumable/ethanol/wizz_fizz/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/wizz_fizz/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
//A healing drink similar to Quadruple Sec, Ling Stings, and Screwdrivers for the Wizznerds; the check is consistent with the changeling sting
if(drinker?.mind?.has_antag_datum(/datum/antagonist/wizard))
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.adjustOxyLoss(-1 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustToxLoss(-1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjustStaminaLoss(-1 * REM * delta_time, required_biotype = affected_biotype)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
drinker.adjustOxyLoss(-1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
drinker.adjustToxLoss(-1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
drinker.adjustStaminaLoss(-1 * REM * seconds_per_tick, required_biotype = affected_biotype)
return ..()
/datum/reagent/consumable/ethanol/bug_spray
@@ -2871,10 +2871,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "bug_spray"
/datum/reagent/consumable/ethanol/bug_spray/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/bug_spray/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
//Bugs should not drink Bug spray.
if(ismoth(drinker) || isflyperson(drinker))
drinker.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
drinker.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
return ..()
/datum/reagent/consumable/ethanol/bug_spray/on_mob_metabolize(mob/living/carbon/drinker)
@@ -2933,10 +2933,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "turbo"
/datum/reagent/consumable/ethanol/turbo/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(2, delta_time))
/datum/reagent/consumable/ethanol/turbo/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(2, seconds_per_tick))
to_chat(drinker, span_notice("[pick("You feel disregard for the rule of law.", "You feel pumped!", "Your head is pounding.", "Your thoughts are racing..")]"))
drinker.adjustStaminaLoss(-0.25 * drinker.get_drunk_amount() * REM * delta_time, required_biotype = affected_biotype)
drinker.adjustStaminaLoss(-0.25 * drinker.get_drunk_amount() * REM * seconds_per_tick, required_biotype = affected_biotype)
return ..()
/datum/reagent/consumable/ethanol/old_timer
@@ -2955,8 +2955,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "old_timer"
/datum/reagent/consumable/ethanol/old_timer/on_mob_life(mob/living/carbon/human/metabolizer, delta_time, times_fired)
if(DT_PROB(10, delta_time) && istype(metabolizer))
/datum/reagent/consumable/ethanol/old_timer/on_mob_life(mob/living/carbon/human/metabolizer, seconds_per_tick, times_fired)
if(SPT_PROB(10, seconds_per_tick) && istype(metabolizer))
metabolizer.age += 1
if(metabolizer.age > 70)
metabolizer.facial_hair_color = "#cccccc"
@@ -3030,11 +3030,11 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "trappistglass"
/datum/reagent/consumable/ethanol/trappist/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/trappist/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.mind?.holy_role)
drinker.adjustFireLoss(-2.5 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
drinker.adjust_jitter(-2 SECONDS * REM * delta_time)
drinker.adjust_stutter(-2 SECONDS * REM * delta_time)
drinker.adjustFireLoss(-2.5 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
drinker.adjust_jitter(-2 SECONDS * REM * seconds_per_tick)
drinker.adjust_stutter(-2 SECONDS * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/ethanol/blazaam
@@ -3052,13 +3052,13 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "blazaamglass"
/datum/reagent/consumable/ethanol/blazaam/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/blazaam/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.get_drunk_amount() > 40)
if(stored_teleports)
do_teleport(drinker, get_turf(drinker), rand(1,3), channel = TELEPORT_CHANNEL_WORMHOLE)
stored_teleports--
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
stored_teleports += rand(2, 6)
if(prob(70))
drinker.vomit(vomit_type = VOMIT_PURPLE)
@@ -3094,10 +3094,10 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "mauna_loa"
/datum/reagent/consumable/ethanol/mauna_loa/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/mauna_loa/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
// Heats the user up while the reagent is in the body. Occasionally makes you burst into flames.
drinker.adjust_bodytemperature(25 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time)
if (DT_PROB(2.5, delta_time))
drinker.adjust_bodytemperature(25 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick)
if (SPT_PROB(2.5, seconds_per_tick))
drinker.adjust_fire_stacks(1)
drinker.ignite_mob()
..()
@@ -3141,10 +3141,10 @@
quality = DRINK_NICE
taste_description = "a horrible emulsion of pineapple and olive oil"
/datum/reagent/consumable/ethanol/pina_olivada/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(8, delta_time))
/datum/reagent/consumable/ethanol/pina_olivada/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(8, seconds_per_tick))
drinker.manual_emote(pick("coughs up some oil", "swallows the lump in [drinker.p_their()] throat", "gags", "chokes up a bit"))
if(DT_PROB(3, delta_time))
if(SPT_PROB(3, seconds_per_tick))
var/static/list/messages = list(
"A horrible aftertaste coats your mouth.",
"You feel like you're going to choke on the oil in your throat.",
@@ -3175,8 +3175,8 @@
desc = "Fermented prison wine made from fruit, sugar, and despair. Security loves to confiscate this, which is the only kind thing Security has ever done."
icon_state = "glass_orange"
/datum/reagent/consumable/ethanol/pruno/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_disgust(5 * REM * delta_time)
/datum/reagent/consumable/ethanol/pruno/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_disgust(5 * REM * seconds_per_tick)
..()
/datum/reagent/consumable/ethanol/ginger_amaretto
@@ -3243,8 +3243,8 @@
desc = "The fermented nectar of the Korta nut, as enjoyed by lizards galaxywide."
icon_state = "kortara_glass"
/datum/reagent/consumable/ethanol/kortara/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(drinker.getBruteLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/ethanol/kortara/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(drinker.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
drinker.heal_bodypart_damage(1,0)
. = TRUE
@@ -3264,7 +3264,7 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "sea_breeze"
/datum/reagent/consumable/ethanol/sea_breeze/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/sea_breeze/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.apply_status_effect(/datum/status_effect/throat_soothed)
..()
@@ -3300,7 +3300,7 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "drunken_espatier"
/datum/reagent/consumable/ethanol/drunken_espatier/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/drunken_espatier/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.add_mood_event("numb", /datum/mood_event/narcotic_medium, name) //comfortably numb
..()
@@ -3329,12 +3329,12 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "protein_blend"
/datum/reagent/consumable/ethanol/protein_blend/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
drinker.adjust_nutrition(2 * REM * delta_time)
/datum/reagent/consumable/ethanol/protein_blend/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
drinker.adjust_nutrition(2 * REM * seconds_per_tick)
if(!islizard(drinker))
drinker.adjust_disgust(5 * REM * delta_time)
drinker.adjust_disgust(5 * REM * seconds_per_tick)
else
drinker.adjust_disgust(2 * REM * delta_time)
drinker.adjust_disgust(2 * REM * seconds_per_tick)
..()
/datum/reagent/consumable/ethanol/mushi_kombucha
@@ -3367,7 +3367,7 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "triumphal_arch"
/datum/reagent/consumable/ethanol/triumphal_arch/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/ethanol/triumphal_arch/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(islizard(drinker))
drinker.add_mood_event("triumph", /datum/mood_event/memories_of_home, name)
..()
@@ -3613,9 +3613,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "helianthus"
/datum/reagent/consumable/ethanol/helianthus/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
if(DT_PROB(5, delta_time))
drinker.adjust_hallucinations_up_to(4 SECONDS * REM * delta_time, 48 SECONDS)
/datum/reagent/consumable/ethanol/helianthus/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(SPT_PROB(5, seconds_per_tick))
drinker.adjust_hallucinations_up_to(4 SECONDS * REM * seconds_per_tick, 48 SECONDS)
..()
@@ -3667,8 +3667,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "gin_garden"
/datum/reagent/consumable/ethanol/gin_garden/on_mob_life(mob/living/carbon/doll, delta_time, times_fired)
doll.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, doll.get_body_temp_normal())
/datum/reagent/consumable/ethanol/gin_garden/on_mob_life(mob/living/carbon/doll, seconds_per_tick, times_fired)
doll.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, doll.get_body_temp_normal())
..()
#undef ALCOHOL_EXPONENT

View File

@@ -51,10 +51,10 @@
breather.SetSleeping(10)
return ..()
/datum/reagent/healium/on_mob_life(mob/living/breather, delta_time, times_fired)
breather.adjustFireLoss(-2 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
breather.adjustToxLoss(-5 * REM * delta_time, FALSE, required_biotype = affected_biotype)
breather.adjustBruteLoss(-2 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
/datum/reagent/healium/on_mob_life(mob/living/breather, seconds_per_tick, times_fired)
breather.adjustFireLoss(-2 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
breather.adjustToxLoss(-5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
breather.adjustBruteLoss(-2 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
return ..()
/datum/reagent/hypernoblium
@@ -66,15 +66,10 @@
taste_description = "searingly cold"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/hypernoblium/on_mob_metabolize(mob/living/breather)
. = ..()
/datum/reagent/hypernoblium/on_mob_life(mob/living/carbon/breather, seconds_per_tick, times_fired)
if(isplasmaman(breather))
ADD_TRAIT(breather, TRAIT_NOFIRE, type)
/datum/reagent/hypernoblium/on_mob_end_metabolize(mob/living/breather)
if(isplasmaman(breather))
REMOVE_TRAIT(breather, TRAIT_NOFIRE, type)
return ..()
breather.set_timed_status_effect(10 SECONDS * REM * seconds_per_tick, /datum/status_effect/hypernob_protection)
..()
/datum/reagent/nitrium_high_metabolization
name = "Nitrosyl plasmide"
@@ -95,9 +90,9 @@
REMOVE_TRAIT(breather, TRAIT_SLEEPIMMUNE, type)
return ..()
/datum/reagent/nitrium_high_metabolization/on_mob_life(mob/living/carbon/breather, delta_time, times_fired)
breather.adjustStaminaLoss(-2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
breather.adjustToxLoss(0.1 * current_cycle * REM * delta_time, FALSE, required_biotype = affected_biotype) // 1 toxin damage per cycle at cycle 10
/datum/reagent/nitrium_high_metabolization/on_mob_life(mob/living/carbon/breather, seconds_per_tick, times_fired)
breather.adjustStaminaLoss(-2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
breather.adjustToxLoss(0.1 * current_cycle * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype) // 1 toxin damage per cycle at cycle 10
return ..()
/datum/reagent/nitrium_low_metabolization
@@ -127,12 +122,12 @@
taste_description = "irradiated air"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/pluoxium/on_mob_life(mob/living/carbon/breather, delta_time, times_fired)
/datum/reagent/pluoxium/on_mob_life(mob/living/carbon/breather, seconds_per_tick, times_fired)
if(!HAS_TRAIT(breather, TRAIT_KNOCKEDOUT))
return ..()
for(var/obj/item/organ/organ_being_healed as anything in breather.organs)
organ_being_healed.apply_organ_damage(-0.5 * REM * delta_time)
organ_being_healed.apply_organ_damage(-0.5 * REM * seconds_per_tick)
return ..()
@@ -147,9 +142,9 @@
affected_biotype = MOB_ORGANIC | MOB_MINERAL | MOB_PLANT // "toxic to all living beings"
affected_respiration_type = ALL
/datum/reagent/zauker/on_mob_life(mob/living/breather, delta_time, times_fired)
breather.adjustBruteLoss(6 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
breather.adjustOxyLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
breather.adjustFireLoss(2 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
breather.adjustToxLoss(2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/zauker/on_mob_life(mob/living/breather, seconds_per_tick, times_fired)
breather.adjustBruteLoss(6 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
breather.adjustOxyLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
breather.adjustFireLoss(2 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
breather.adjustToxLoss(2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
return ..()

View File

@@ -26,7 +26,7 @@
var/reaping = FALSE
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/helbital/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/helbital/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = TRUE
var/death_is_coming = (affected_mob.getToxLoss() + affected_mob.getOxyLoss() + affected_mob.getFireLoss() + affected_mob.getBruteLoss())*normalise_creation_purity()
var/thou_shall_heal = 0
@@ -34,16 +34,16 @@
switch(affected_mob.stat)
if(CONSCIOUS) //bad
thou_shall_heal = death_is_coming/50
affected_mob.adjustOxyLoss(2 * REM * delta_time, TRUE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustOxyLoss(2 * REM * seconds_per_tick, TRUE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
if(SOFT_CRIT) //meh convert
thou_shall_heal = round(death_is_coming/47,0.1)
affected_mob.adjustOxyLoss(1 * REM * delta_time, TRUE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustOxyLoss(1 * REM * seconds_per_tick, TRUE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
else //no convert
thou_shall_heal = round(death_is_coming/45, 0.1)
good_kind_of_healing = TRUE
affected_mob.adjustBruteLoss(-thou_shall_heal * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustBruteLoss(-thou_shall_heal * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
if(good_kind_of_healing && !reaping && DT_PROB(0.00005, delta_time)) //janken with the grim reaper!
if(good_kind_of_healing && !reaping && SPT_PROB(0.00005, seconds_per_tick)) //janken with the grim reaper!
reaping = TRUE
var/list/RockPaperScissors = list("rock" = "paper", "paper" = "scissors", "scissors" = "rock") //choice = loses to
if(affected_mob.apply_status_effect(/datum/status_effect/necropolis_curse, CURSE_BLINDING))
@@ -77,7 +77,7 @@
..()
return
/datum/reagent/medicine/c2/helbital/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/helbital/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!helbent)
affected_mob.apply_necropolis_curse(CURSE_WASTING | CURSE_BLINDING)
helbent = TRUE
@@ -98,9 +98,9 @@
reagent_state = SOLID
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/libital/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.3 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustBruteLoss(-3 * REM * normalise_creation_purity() * delta_time, required_bodytype = affected_bodytype)
/datum/reagent/medicine/c2/libital/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.3 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjustBruteLoss(-3 * REM * normalise_creation_purity() * seconds_per_tick, required_bodytype = affected_bodytype)
..()
return TRUE
@@ -115,8 +115,8 @@
inverse_chem = /datum/reagent/medicine/metafactor //Seems thematically intact
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/probital/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustBruteLoss(-2.25 * REM * normalise_creation_purity() * delta_time, FALSE, required_bodytype = affected_bodytype)
/datum/reagent/medicine/c2/probital/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustBruteLoss(-2.25 * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
var/ooo_youaregettingsleepy = 3.5
switch(round(affected_mob.getStaminaLoss()))
if(10 to 40)
@@ -125,14 +125,14 @@
ooo_youaregettingsleepy = 2.5
if(61 to 200) //you really can only go to 120
ooo_youaregettingsleepy = 2
affected_mob.adjustStaminaLoss(ooo_youaregettingsleepy * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustStaminaLoss(ooo_youaregettingsleepy * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
. = TRUE
/datum/reagent/medicine/c2/probital/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.adjustStaminaLoss(3 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/medicine/c2/probital/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustStaminaLoss(3 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
if(affected_mob.getStaminaLoss() >= 80)
affected_mob.adjust_drowsiness(2 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(2 SECONDS * REM * seconds_per_tick)
if(affected_mob.getStaminaLoss() >= 100)
to_chat(affected_mob,span_warning("You feel more tired than you usually do, perhaps if you rest your eyes for a bit..."))
affected_mob.adjustStaminaLoss(-100, TRUE, required_biotype = affected_biotype)
@@ -161,9 +161,9 @@
var/spammer = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/lenturi/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustFireLoss(-3 * REM * normalise_creation_purity() * delta_time, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_STOMACH, 0.4 * REM * delta_time, required_organtype = affected_organtype)
/datum/reagent/medicine/c2/lenturi/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustFireLoss(-3 * REM * normalise_creation_purity() * seconds_per_tick, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_STOMACH, 0.4 * REM * seconds_per_tick, required_organtype = affected_organtype)
..()
return TRUE
@@ -177,9 +177,9 @@
var/message_cd = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/aiuri/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustFireLoss(-2 * REM * normalise_creation_purity() * delta_time, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_EYES, 0.25 * REM * delta_time, required_organtype = affected_organtype)
/datum/reagent/medicine/c2/aiuri/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustFireLoss(-2 * REM * normalise_creation_purity() * seconds_per_tick, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_EYES, 0.25 * REM * seconds_per_tick, required_organtype = affected_organtype)
..()
return TRUE
@@ -195,17 +195,17 @@
inverse_chem_val = 0.3
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/hercuri/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/hercuri/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getFireLoss() > 50)
affected_mob.adjustFireLoss(-2 * REM * delta_time * normalise_creation_purity(), FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustFireLoss(-2 * REM * seconds_per_tick * normalise_creation_purity(), FALSE, required_bodytype = affected_bodytype)
else
affected_mob.adjustFireLoss(-1.25 * REM * delta_time * normalise_creation_purity(), FALSE, required_bodytype = affected_bodytype)
affected_mob.adjust_bodytemperature(rand(-25,-5) * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 50)
affected_mob.adjustFireLoss(-1.25 * REM * seconds_per_tick * normalise_creation_purity(), FALSE, required_bodytype = affected_bodytype)
affected_mob.adjust_bodytemperature(rand(-25,-5) * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 50)
if(ishuman(affected_mob))
var/mob/living/carbon/human/humi = affected_mob
humi.adjust_coretemperature(rand(-25,-5) * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 50)
affected_mob.reagents?.chem_temp += (-10 * REM * delta_time)
affected_mob.adjust_fire_stacks(-1 * REM * delta_time)
humi.adjust_coretemperature(rand(-25,-5) * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 50)
affected_mob.reagents?.chem_temp += (-10 * REM * seconds_per_tick)
affected_mob.adjust_fire_stacks(-1 * REM * seconds_per_tick)
..()
. = TRUE
@@ -219,11 +219,11 @@
if(reac_volume >= metabolization_rate)
exposed_mob.extinguish_mob()
/datum/reagent/medicine/c2/hercuri/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 50) //chilly chilly
/datum/reagent/medicine/c2/hercuri/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 50) //chilly chilly
if(ishuman(affected_mob))
var/mob/living/carbon/human/humi = affected_mob
humi.adjust_coretemperature(-10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 50)
humi.adjust_coretemperature(-10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 50)
..()
@@ -242,18 +242,18 @@
inverse_chem = /datum/reagent/inverse/healing/convermol
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/convermol/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/convermol/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
var/oxycalc = 2.5 * REM * current_cycle
if(!overdosed)
oxycalc = min(oxycalc, affected_mob.getOxyLoss() + 0.5) //if NOT overdosing, we lower our toxdamage to only the damage we actually healed with a minimum of 0.1*current_cycle. IE if we only heal 10 oxygen damage but we COULD have healed 20, we will only take toxdamage for the 10. We would take the toxdamage for the extra 10 if we were overdosing.
affected_mob.adjustOxyLoss(-oxycalc * delta_time * normalise_creation_purity(), FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustToxLoss(oxycalc * delta_time / CONVERMOL_RATIO, FALSE, required_biotype = affected_biotype)
if(DT_PROB(current_cycle / 2, delta_time) && affected_mob.losebreath)
affected_mob.adjustOxyLoss(-oxycalc * seconds_per_tick * normalise_creation_purity(), FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustToxLoss(oxycalc * seconds_per_tick / CONVERMOL_RATIO, FALSE, required_biotype = affected_biotype)
if(SPT_PROB(current_cycle / 2, seconds_per_tick) && affected_mob.losebreath)
affected_mob.losebreath--
..()
return TRUE
/datum/reagent/medicine/c2/convermol/overdose_process(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/convermol/overdose_process(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
metabolization_rate += 2.5 * REAGENTS_METABOLISM
..()
return TRUE
@@ -272,9 +272,9 @@
/// A cooldown for spacing bursts of stamina damage
COOLDOWN_DECLARE(drowsycd)
/datum/reagent/medicine/c2/tirimol/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
affected_mob.adjustOxyLoss(-3 * REM * delta_time * normalise_creation_purity(), required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustStaminaLoss(2 * REM * delta_time, required_biotype = affected_biotype)
/datum/reagent/medicine/c2/tirimol/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOxyLoss(-3 * REM * seconds_per_tick * normalise_creation_purity(), required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustStaminaLoss(2 * REM * seconds_per_tick, required_biotype = affected_biotype)
if(drowsycd && COOLDOWN_FINISHED(src, drowsycd))
affected_mob.adjust_drowsiness(20 SECONDS)
COOLDOWN_START(src, drowsycd, 45 SECONDS)
@@ -306,19 +306,19 @@
. = ..()
rads_heal_threshold = rand(rads_heal_threshold - 50, rads_heal_threshold + 50) // Basically this means 50K and below will always give the radiation heal, and upto 150K could. Calculated once.
/datum/reagent/medicine/c2/seiver/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/seiver/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
var/chemtemp = min(holder.chem_temp, 1000)
chemtemp = chemtemp ? chemtemp : T0C //why do you have null sweaty
var/healypoints = 0 //5 healypoints = 1 heart damage; 5 rads = 1 tox damage healed for the purpose of healypoints
//you're hot
var/toxcalc = min(round(5 + ((chemtemp-1000)/175), 0.1), 5) * REM * delta_time * normalise_creation_purity() //max 2.5 tox healing per second
var/toxcalc = min(round(5 + ((chemtemp-1000)/175), 0.1), 5) * REM * seconds_per_tick * normalise_creation_purity() //max 2.5 tox healing per second
if(toxcalc > 0)
affected_mob.adjustToxLoss(-toxcalc, required_biotype = affected_biotype)
healypoints += toxcalc
//and you're cold
var/radcalc = round((T0C-chemtemp) / 6, 0.1) * REM * delta_time //max ~45 rad loss unless you've hit below 0K. if so, wow.
var/radcalc = round((T0C-chemtemp) / 6, 0.1) * REM * seconds_per_tick //max ~45 rad loss unless you've hit below 0K. if so, wow.
if(radcalc > 0 && HAS_TRAIT(affected_mob, TRAIT_IRRADIATED))
radcalc *= normalise_creation_purity()
// extra rad healing if you are SUPER cold
@@ -342,7 +342,7 @@
ph = 9.2
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/multiver/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/medicine/c2/multiver/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
var/medibonus = 0 //it will always have itself which makes it REALLY start @ 1
for(var/r in affected_mob.reagents.reagent_list)
var/datum/reagent/the_reagent = r
@@ -350,8 +350,8 @@
medibonus += 1
if(creation_purity >= 1) //Perfectly pure multivers gives a bonus of 2!
medibonus += 1
affected_mob.adjustToxLoss(-0.5 * min(medibonus, 3 * normalise_creation_purity()) * REM * delta_time, required_biotype = affected_biotype) //not great at healing but if you have nothing else it will work
affected_mob.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.5 * REM * delta_time, required_organtype = affected_organtype) //kills at 40u
affected_mob.adjustToxLoss(-0.5 * min(medibonus, 3 * normalise_creation_purity()) * REM * seconds_per_tick, required_biotype = affected_biotype) //not great at healing but if you have nothing else it will work
affected_mob.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.5 * REM * seconds_per_tick, required_organtype = affected_organtype) //kills at 40u
for(var/r2 in affected_mob.reagents.reagent_list)
var/datum/reagent/the_reagent2 = r2
if(the_reagent2 == src)
@@ -359,7 +359,7 @@
var/amount2purge = 3
if(medibonus >= 3 && istype(the_reagent2, /datum/reagent/medicine)) //3 unique meds (2+multiver) | (1 + pure multiver) will make it not purge medicines
continue
affected_mob.reagents.remove_reagent(the_reagent2.type, amount2purge * REM * delta_time)
affected_mob.reagents.remove_reagent(the_reagent2.type, amount2purge * REM * seconds_per_tick)
..()
return TRUE
@@ -397,21 +397,21 @@
C.reagents.add_reagent(/datum/reagent/medicine/c2/musiver, conversion_amount)
..()
/datum/reagent/medicine/c2/syriniver/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.8 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(-1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/medicine/c2/syriniver/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.8 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(-1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
for(var/datum/reagent/R in affected_mob.reagents.reagent_list)
if(issyrinormusc(R))
continue
affected_mob.reagents.remove_reagent(R.type, 0.4 * REM * delta_time)
affected_mob.reagents.remove_reagent(R.type, 0.4 * REM * seconds_per_tick)
..()
. = TRUE
/datum/reagent/medicine/c2/syriniver/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjust_disgust(3 * REM * delta_time)
affected_mob.reagents.add_reagent(/datum/reagent/medicine/c2/musiver, 0.225 * REM * delta_time)
/datum/reagent/medicine/c2/syriniver/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjust_disgust(3 * REM * seconds_per_tick)
affected_mob.reagents.add_reagent(/datum/reagent/medicine/c2/musiver, 0.225 * REM * seconds_per_tick)
..()
. = TRUE
@@ -426,13 +426,13 @@
var/datum/brain_trauma/mild/muscle_weakness/trauma
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/medicine/c2/musiver/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.1 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(-1 * REM * delta_time * normalise_creation_purity(), FALSE, required_biotype = affected_biotype)
/datum/reagent/medicine/c2/musiver/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.1 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(-1 * REM * seconds_per_tick * normalise_creation_purity(), FALSE, required_biotype = affected_biotype)
for(var/datum/reagent/R in affected_mob.reagents.reagent_list)
if(issyrinormusc(R))
continue
affected_mob.reagents.remove_reagent(R.type, 0.2 * REM * delta_time)
affected_mob.reagents.remove_reagent(R.type, 0.2 * REM * seconds_per_tick)
..()
. = TRUE
@@ -446,9 +446,9 @@
QDEL_NULL(trauma)
return ..()
/datum/reagent/medicine/c2/musiver/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjust_disgust(3 * REM * delta_time)
/datum/reagent/medicine/c2/musiver/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjust_disgust(3 * REM * seconds_per_tick)
..()
. = TRUE
@@ -529,24 +529,24 @@
user.throw_alert("penthrite", /atom/movable/screen/alert/penthrite)
user.add_traits(subject_traits, type)
/datum/reagent/medicine/c2/penthrite/on_mob_life(mob/living/carbon/human/H, delta_time, times_fired)
/datum/reagent/medicine/c2/penthrite/on_mob_life(mob/living/carbon/human/H, seconds_per_tick, times_fired)
H.adjustStaminaLoss(-25 * REM) //SKYRAT EDIT ADDITION - COMBAT - makes your heart beat faster, fills you with energy. For miners
H.adjustOrganLoss(ORGAN_SLOT_STOMACH, 0.25 * REM * delta_time, required_organtype = affected_organtype)
H.adjustOrganLoss(ORGAN_SLOT_STOMACH, 0.25 * REM * seconds_per_tick, required_organtype = affected_organtype)
if(H.health <= HEALTH_THRESHOLD_CRIT && H.health > (H.crit_threshold + HEALTH_THRESHOLD_FULLCRIT * (2 * normalise_creation_purity()))) //we cannot save someone below our lowered crit threshold.
H.adjustToxLoss(-2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
H.adjustBruteLoss(-2 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
H.adjustFireLoss(-2 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
H.adjustOxyLoss(-6 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
H.adjustToxLoss(-2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
H.adjustBruteLoss(-2 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
H.adjustFireLoss(-2 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
H.adjustOxyLoss(-6 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
H.losebreath = 0
H.adjustOrganLoss(ORGAN_SLOT_HEART, max(volume/10, 1) * REM * delta_time, required_organtype = affected_organtype) // your heart is barely keeping up!
H.adjustOrganLoss(ORGAN_SLOT_HEART, max(volume/10, 1) * REM * seconds_per_tick, required_organtype = affected_organtype) // your heart is barely keeping up!
H.set_jitter_if_lower(rand(0 SECONDS, 4 SECONDS) * REM * delta_time)
H.set_dizzy_if_lower(rand(0 SECONDS, 4 SECONDS) * REM * delta_time)
H.set_jitter_if_lower(rand(0 SECONDS, 4 SECONDS) * REM * seconds_per_tick)
H.set_dizzy_if_lower(rand(0 SECONDS, 4 SECONDS) * REM * seconds_per_tick)
if(DT_PROB(18, delta_time))
if(SPT_PROB(18, seconds_per_tick))
to_chat(H,span_danger("Your body is trying to give up, but your heart is still beating!"))
if(H.health <= (H.crit_threshold + HEALTH_THRESHOLD_FULLCRIT*(2*normalise_creation_purity()))) //certain death below this threshold
@@ -562,10 +562,10 @@
user.remove_traits(subject_traits, type)
. = ..()
/datum/reagent/medicine/c2/penthrite/overdose_process(mob/living/carbon/human/H, delta_time, times_fired)
/datum/reagent/medicine/c2/penthrite/overdose_process(mob/living/carbon/human/H, seconds_per_tick, times_fired)
REMOVE_TRAIT(H, TRAIT_STABLEHEART, type)
H.adjustStaminaLoss(10 * REM * delta_time, required_biotype = affected_biotype)
H.adjustOrganLoss(ORGAN_SLOT_HEART, 10 * REM * delta_time, required_organtype = affected_organtype)
H.adjustStaminaLoss(10 * REM * seconds_per_tick, required_biotype = affected_biotype)
H.adjustOrganLoss(ORGAN_SLOT_HEART, 10 * REM * seconds_per_tick, required_organtype = affected_organtype)
H.set_heartattack(TRUE)

View File

@@ -27,8 +27,8 @@
icon_state = "orangebox"
drink_type = FRUIT | BREAKFAST
/datum/reagent/consumable/orangejuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getOxyLoss() && DT_PROB(16, delta_time))
/datum/reagent/consumable/orangejuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getOxyLoss() && SPT_PROB(16, seconds_per_tick))
affected_mob.adjustOxyLoss(-1, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
. = TRUE
..()
@@ -47,8 +47,8 @@
desc = "Are you sure this is tomato juice?"
icon_state = "glass_red"
/datum/reagent/consumable/tomatojuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getFireLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/tomatojuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getFireLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(0, 1)
. = TRUE
..()
@@ -68,8 +68,8 @@
desc = "A glass of sweet-sour lime juice."
icon_state = "glass_green"
/datum/reagent/consumable/limejuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getToxLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/limejuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getToxLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.adjustToxLoss(-1, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -87,14 +87,14 @@
desc = "It's just like a carrot but without crunching."
icon_state = "carrotjuice"
/datum/reagent/consumable/carrotjuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_eye_blur(-2 SECONDS * REM * delta_time)
affected_mob.adjust_temp_blindness(-2 SECONDS * REM * delta_time)
/datum/reagent/consumable/carrotjuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_eye_blur(-2 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_temp_blindness(-2 SECONDS * REM * seconds_per_tick)
switch(current_cycle)
if(1 to 20)
//nothing
if(21 to 110)
if(DT_PROB(100 * (1 - (sqrt(110 - current_cycle) / 10)), delta_time))
if(SPT_PROB(100 * (1 - (sqrt(110 - current_cycle) / 10)), seconds_per_tick))
affected_mob.adjustOrganLoss(ORGAN_SLOT_EYES, -2)
if(110 to INFINITY)
affected_mob.adjustOrganLoss(ORGAN_SLOT_EYES, -2)
@@ -140,8 +140,8 @@
desc = "Berry juice. Or maybe it's poison. Who cares?"
icon_state = "poisonberryjuice"
/datum/reagent/consumable/poisonberryjuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/consumable/poisonberryjuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -185,10 +185,10 @@
desc = "The raw essence of a banana. HONK."
icon_state = "banana"
/datum/reagent/consumable/banana/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/banana/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/obj/item/organ/internal/liver/liver = affected_mob.get_organ_slot(ORGAN_SLOT_LIVER)
if((liver && HAS_TRAIT(liver, TRAIT_COMEDY_METABOLISM)) || ismonkey(affected_mob))
affected_mob.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
affected_mob.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
..()
@@ -208,10 +208,10 @@
desc = "Absolutely nothing."
icon_state = "nothing"
/datum/reagent/consumable/nothing/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/nothing/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(ishuman(drinker) && HAS_TRAIT(drinker, TRAIT_MIMING))
drinker.set_silence_if_lower(MIMEDRINK_SILENCE_DURATION)
drinker.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time)
drinker.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick)
. = TRUE
..()
@@ -223,7 +223,7 @@
taste_description = "laughter"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/laughter/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/laughter/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.emote("laugh")
affected_mob.add_mood_event("chemical_laughter", /datum/mood_event/chemical_laughter)
..()
@@ -236,8 +236,8 @@
taste_description = "laughter"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/superlaughter/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(16, delta_time))
/datum/reagent/consumable/superlaughter/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(16, seconds_per_tick))
affected_mob.visible_message(span_danger("[affected_mob] bursts out into a fit of uncontrollable laughter!"), span_userdanger("You burst out in a fit of uncontrollable laughter!"))
affected_mob.Stun(5)
affected_mob.add_mood_event("chemical_laughter", /datum/mood_event/chemical_superlaughter)
@@ -316,12 +316,12 @@
mytray.adjust_waterlevel(round(chems.get_reagent_amount(type) * 0.3))
myseed?.adjust_potency(-chems.get_reagent_amount(type) * 0.5)
/datum/reagent/consumable/milk/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/milk/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1,0)
. = TRUE
if(holder.has_reagent(/datum/reagent/consumable/capsaicin))
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 1 * delta_time)
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 1 * seconds_per_tick)
..()
/datum/reagent/consumable/soymilk
@@ -338,8 +338,8 @@
desc = "White and nutritious soy goodness!"
icon_state = "glass_white"
/datum/reagent/consumable/soymilk/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/soymilk/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1, 0)
. = TRUE
..()
@@ -358,8 +358,8 @@
desc = "Ewwww..."
icon_state = "glass_white"
/datum/reagent/consumable/cream/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/cream/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1, 0)
. = TRUE
..()
@@ -380,18 +380,18 @@
desc = "Don't drop it, or you'll send scalding liquid and glass shards everywhere."
icon_state = "glass_brown"
/datum/reagent/consumable/coffee/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
/datum/reagent/consumable/coffee/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
..()
/datum/reagent/consumable/coffee/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
/datum/reagent/consumable/coffee/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
//310.15 is the normal bodytemp.
affected_mob.adjust_bodytemperature(25 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
affected_mob.adjust_bodytemperature(25 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
if(holder.has_reagent(/datum/reagent/consumable/frostoil))
holder.remove_reagent(/datum/reagent/consumable/frostoil, 5 * REM * delta_time)
holder.remove_reagent(/datum/reagent/consumable/frostoil, 5 * REM * seconds_per_tick)
..()
. = TRUE
@@ -411,14 +411,14 @@
desc = "Drinking it from here would not seem right."
icon_state = "teaglass"
/datum/reagent/consumable/tea/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-4 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-2 SECONDS * REM * delta_time)
affected_mob.adjust_jitter(-6 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-20 * REM * delta_time)
if(affected_mob.getToxLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/tea/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-4 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-2 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_jitter(-6 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-20 * REM * seconds_per_tick)
if(affected_mob.getToxLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.adjustToxLoss(-1, FALSE, required_biotype = affected_biotype)
affected_mob.adjust_bodytemperature(20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
affected_mob.adjust_bodytemperature(20 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
..()
. = TRUE
@@ -454,8 +454,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "arnold_palmer"
/datum/reagent/consumable/tea/arnold_palmer/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(2.5, delta_time))
/datum/reagent/consumable/tea/arnold_palmer/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[pick("You remember to square your shoulders.","You remember to keep your head down.","You can't decide between squaring your shoulders and keeping your head down.","You remember to relax.","You think about how someday you'll get two strokes off your golf game.")]"))
..()
. = TRUE
@@ -475,12 +475,12 @@
icon = 'icons/obj/drinks/coffee.dmi'
icon_state = "icedcoffeeglass"
/datum/reagent/consumable/icecoffee/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
/datum/reagent/consumable/icecoffee/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
..()
. = TRUE
@@ -499,13 +499,13 @@
icon = 'icons/obj/drinks/coffee.dmi'
icon_state = "hoticecoffee"
/datum/reagent/consumable/hot_ice_coffee/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-60 * REM * delta_time)
affected_mob.adjust_bodytemperature(-7 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
affected_mob.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/consumable/hot_ice_coffee/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-60 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-7 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
. = TRUE
@@ -524,13 +524,13 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "icedteaglass"
/datum/reagent/consumable/icetea/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-4 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-2 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
if(affected_mob.getToxLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/icetea/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-4 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-2 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
if(affected_mob.getToxLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.adjustToxLoss(-1, FALSE, required_biotype = affected_biotype)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
. = TRUE
@@ -547,9 +547,9 @@
desc = "A glass of refreshing Space Cola."
icon_state = "spacecola"
/datum/reagent/consumable/space_cola/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_drowsiness(-10 SECONDS * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/space_cola/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_drowsiness(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/roy_rogers
@@ -566,10 +566,10 @@
desc = "90% sugar in a glass."
icon_state = "royrogers"
/datum/reagent/consumable/roy_rogers/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(12 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-10 SECONDS * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/roy_rogers/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(12 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
return ..()
/datum/reagent/consumable/nuka_cola
@@ -595,13 +595,13 @@
affected_mob.remove_movespeed_modifier(/datum/movespeed_modifier/reagent/nuka_cola)
..()
/datum/reagent/consumable/nuka_cola/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(40 SECONDS * REM * delta_time)
affected_mob.set_drugginess(1 MINUTES * REM * delta_time)
affected_mob.adjust_dizzy(3 SECONDS * REM * delta_time)
/datum/reagent/consumable/nuka_cola/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(40 SECONDS * REM * seconds_per_tick)
affected_mob.set_drugginess(1 MINUTES * REM * seconds_per_tick)
affected_mob.adjust_dizzy(3 SECONDS * REM * seconds_per_tick)
affected_mob.remove_status_effect(/datum/status_effect/drowsiness)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
. = TRUE
@@ -631,17 +631,17 @@
affected_mob.adjust_drowsiness(current_cycle * 2 SECONDS)
..()
/datum/reagent/consumable/rootbeer/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/rootbeer/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle >= 3 && !effect_enabled) // takes a few seconds for the bonus to kick in to prevent microdosing
to_chat(affected_mob, span_notice("You feel your trigger finger getting itchy..."))
ADD_TRAIT(affected_mob, TRAIT_DOUBLE_TAP, type)
effect_enabled = TRUE
affected_mob.set_jitter_if_lower(4 SECONDS * REM * delta_time)
affected_mob.set_jitter_if_lower(4 SECONDS * REM * seconds_per_tick)
if(prob(50))
affected_mob.adjust_dizzy(2 SECONDS * REM * delta_time)
affected_mob.adjust_dizzy(2 SECONDS * REM * seconds_per_tick)
if(current_cycle > 10)
affected_mob.adjust_dizzy(3 SECONDS * REM * delta_time)
affected_mob.adjust_dizzy(3 SECONDS * REM * seconds_per_tick)
..()
. = TRUE
@@ -668,12 +668,12 @@
REMOVE_TRAIT(affected_mob, TRAIT_SHOCKIMMUNE, type)
..()
/datum/reagent/consumable/grey_bull/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(40 SECONDS * REM * delta_time)
affected_mob.adjust_dizzy(2 SECONDS * REM * delta_time)
/datum/reagent/consumable/grey_bull/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(40 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_dizzy(2 SECONDS * REM * seconds_per_tick)
affected_mob.remove_status_effect(/datum/status_effect/drowsiness)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/spacemountainwind
@@ -689,11 +689,11 @@
desc = "Space Mountain Wind. As you know, there are no mountains in space, only wind."
icon_state = "Space_mountain_wind_glass"
/datum/reagent/consumable/spacemountainwind/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_drowsiness(-14 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-20 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
/datum/reagent/consumable/spacemountainwind/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_drowsiness(-14 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-20 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
..()
. = TRUE
@@ -710,9 +710,9 @@
desc = "Dr. Gibb. Not as dangerous as the container_name might imply."
icon_state = "dr_gibb_glass"
/datum/reagent/consumable/dr_gibb/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_drowsiness(-12 SECONDS * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/dr_gibb/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_drowsiness(-12 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/space_up
@@ -728,8 +728,8 @@
desc = "Space-up. It helps you keep your cool."
icon_state = "space-up_glass"
/datum/reagent/consumable/space_up/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/space_up/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/lemon_lime
@@ -745,8 +745,8 @@
desc = "You're pretty certain a real fruit has never actually touched this."
icon_state = "lemonlime"
/datum/reagent/consumable/lemon_lime/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/lemon_lime/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/pwr_game
@@ -769,9 +769,9 @@
to_chat(exposed_mob, "<span class='nicegreen'>As you imbibe the Pwr Game, your gamer third eye opens... \
You feel as though a great secret of the universe has been made known to you...</span>")
/datum/reagent/consumable/pwr_game/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
if(DT_PROB(5, delta_time))
/datum/reagent/consumable/pwr_game/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
if(SPT_PROB(5, seconds_per_tick))
affected_mob.mind?.adjust_experience(/datum/skill/gaming, 5)
..()
@@ -788,8 +788,8 @@
desc = "Mmm mm, shambly."
icon_state = "shamblerjuice"
/datum/reagent/consumable/shamblers/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/shamblers/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/sodawater
@@ -814,10 +814,10 @@
mytray.adjust_waterlevel(round(chems.get_reagent_amount(type)))
mytray.adjust_plant_health(round(chems.get_reagent_amount(type) * 0.1))
/datum/reagent/consumable/sodawater/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/sodawater/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/tonic
@@ -833,11 +833,11 @@
desc = "Quinine tastes funny, but at least it'll keep that Space Malaria away."
icon_state = "glass_clearcarb"
/datum/reagent/consumable/tonic/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/tonic/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
. = TRUE
@@ -855,12 +855,12 @@
desc = "You can unleash the ape, but without the pop of the can?"
icon_state = "monkey_energy_glass"
/datum/reagent/consumable/monkey_energy/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(80 SECONDS * REM * delta_time)
affected_mob.adjust_dizzy(2 SECONDS * REM * delta_time)
/datum/reagent/consumable/monkey_energy/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(80 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_dizzy(2 SECONDS * REM * seconds_per_tick)
affected_mob.remove_status_effect(/datum/status_effect/drowsiness)
affected_mob.AdjustSleeping(-40 * REM * delta_time)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
affected_mob.AdjustSleeping(-40 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/monkey_energy/on_mob_metabolize(mob/living/affected_mob)
@@ -872,8 +872,8 @@
affected_mob.remove_movespeed_modifier(/datum/movespeed_modifier/reagent/monkey_energy)
..()
/datum/reagent/consumable/monkey_energy/overdose_process(mob/living/affected_mob, delta_time, times_fired)
if(DT_PROB(7.5, delta_time))
/datum/reagent/consumable/monkey_energy/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(7.5, seconds_per_tick))
affected_mob.say(pick_list_replacements(BOOMER_FILE, "boomer"), forced = /datum/reagent/consumable/monkey_energy)
..()
@@ -892,8 +892,8 @@
desc = "Generally, you're supposed to put something else in there too..."
icon_state = "iceglass"
/datum/reagent/consumable/ice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/ice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/soy_latte
@@ -912,13 +912,13 @@
icon = 'icons/obj/drinks/coffee.dmi'
icon_state = "soy_latte"
/datum/reagent/consumable/soy_latte/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * delta_time)
/datum/reagent/consumable/soy_latte/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-6 SECONDS * REM * seconds_per_tick)
affected_mob.SetSleeping(0)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1,0)
..()
. = TRUE
@@ -939,13 +939,13 @@
icon = 'icons/obj/drinks/coffee.dmi'
icon_state = "cafe_latte"
/datum/reagent/consumable/cafe_latte/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(-12 SECONDS * REM * delta_time)
/datum/reagent/consumable/cafe_latte/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_dizzy(-10 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(-12 SECONDS * REM * seconds_per_tick)
affected_mob.SetSleeping(0)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1, 0)
..()
. = TRUE
@@ -965,16 +965,16 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "doctorsdelightglass"
/datum/reagent/consumable/doctor_delight/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustBruteLoss(-0.5 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustFireLoss(-0.5 * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustToxLoss(-0.5 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOxyLoss(-0.5 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
/datum/reagent/consumable/doctor_delight/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustBruteLoss(-0.5 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustFireLoss(-0.5 * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustToxLoss(-0.5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOxyLoss(-0.5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
if(affected_mob.nutrition && (affected_mob.nutrition - 2 > 0))
var/obj/item/organ/internal/liver/liver = affected_mob.get_organ_slot(ORGAN_SLOT_LIVER)
if(!(HAS_TRAIT(liver, TRAIT_MEDICAL_METABOLISM)))
// Drains the nutrition of the holder. Not medical doctors though, since it's the Doctor's Delight!
affected_mob.adjust_nutrition(-2 * REM * delta_time)
affected_mob.adjust_nutrition(-2 * REM * seconds_per_tick)
..()
. = TRUE
@@ -993,8 +993,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "cinderella"
/datum/reagent/consumable/cinderella/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_disgust(-5 * REM * delta_time)
/datum/reagent/consumable/cinderella/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_disgust(-5 * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/cherryshake
@@ -1187,8 +1187,8 @@
required_drink_type = /datum/reagent/consumable/grape_soda
name = "glass of grape juice"
/datum/reagent/consumable/grape_soda/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/grape_soda/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/milk/chocolate_milk
@@ -1221,13 +1221,13 @@
icon_state = "chocolateglass"
drink_type = SUGAR | DAIRY
/datum/reagent/consumable/hot_coco/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
if(affected_mob.getBruteLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/hot_coco/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
if(affected_mob.getBruteLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.heal_bodypart_damage(1, 0)
. = TRUE
if(holder.has_reagent(/datum/reagent/consumable/capsaicin))
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 2 * REM * delta_time)
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 2 * REM * seconds_per_tick)
..()
/datum/reagent/consumable/italian_coco
@@ -1246,8 +1246,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "italiancoco"
/datum/reagent/consumable/italian_coco/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, 0, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/italian_coco/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, 0, affected_mob.get_body_temp_normal())
return ..()
/datum/reagent/consumable/menthol
@@ -1264,7 +1264,7 @@
desc = "Tastes naturally minty, and imparts a very mild numbing sensation."
icon_state = "glass_green"
/datum/reagent/consumable/menthol/on_mob_life(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/menthol/on_mob_life(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.apply_status_effect(/datum/status_effect/throat_soothed)
..()
@@ -1340,8 +1340,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "cream_soda"
/datum/reagent/consumable/cream_soda/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
/datum/reagent/consumable/cream_soda/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-5 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
..()
/datum/reagent/consumable/sol_dry
@@ -1358,8 +1358,8 @@
desc = "A soothing, mellow drink made from ginger."
icon_state = "soldry"
/datum/reagent/consumable/sol_dry/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_disgust(-5 * REM * delta_time)
/datum/reagent/consumable/sol_dry/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_disgust(-5 * REM * seconds_per_tick)
..()
/datum/reagent/consumable/shirley_temple
@@ -1377,8 +1377,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "shirleytemple"
/datum/reagent/consumable/shirley_temple/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_disgust(-3 * REM * delta_time)
/datum/reagent/consumable/shirley_temple/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_disgust(-3 * REM * seconds_per_tick)
return ..()
/datum/reagent/consumable/red_queen
@@ -1397,8 +1397,8 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "red_queen"
/datum/reagent/consumable/red_queen/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(50, delta_time))
/datum/reagent/consumable/red_queen/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(50, seconds_per_tick))
return ..()
var/newsize = pick(0.5, 0.75, 1, 1.50, 2)
@@ -1406,7 +1406,7 @@
affected_mob.resize = newsize/current_size
current_size = newsize
affected_mob.update_transform()
if(DT_PROB(23, delta_time))
if(SPT_PROB(23, seconds_per_tick))
affected_mob.emote("sneeze")
..()
@@ -1455,8 +1455,8 @@
desc = "A healthy and refreshing juice."
icon_state = "glass_yellow"
/datum/reagent/consumable/aloejuice/on_mob_life(mob/living/affected_mob, delta_time, times_fired)
if(affected_mob.getToxLoss() && DT_PROB(16, delta_time))
/datum/reagent/consumable/aloejuice/on_mob_life(mob/living/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.getToxLoss() && SPT_PROB(16, seconds_per_tick))
affected_mob.adjustToxLoss(-1, FALSE, required_biotype = affected_biotype)
..()
. = TRUE
@@ -1476,9 +1476,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "aguafresca"
/datum/reagent/consumable/agua_fresca/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
if(affected_mob.getToxLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/agua_fresca/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
if(affected_mob.getToxLoss() && SPT_PROB(10, seconds_per_tick))
affected_mob.adjustToxLoss(-0.5, FALSE, required_biotype = affected_biotype)
return ..()
@@ -1496,9 +1496,9 @@
desc = "Oddly savoury for a drink."
icon_state = "mushroom_tea_glass"
/datum/reagent/consumable/mushroom_tea/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/mushroom_tea/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(islizard(affected_mob))
affected_mob.adjustOxyLoss(-0.5 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustOxyLoss(-0.5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
..()
. = TRUE
@@ -1649,9 +1649,9 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "cucumber_lemonade"
/datum/reagent/consumable/cucumberlemonade/on_mob_life(mob/living/carbon/doll, delta_time, times_fired)
doll.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, doll.get_body_temp_normal())
if(doll.getToxLoss() && DT_PROB(10, delta_time))
/datum/reagent/consumable/cucumberlemonade/on_mob_life(mob/living/carbon/doll, seconds_per_tick, times_fired)
doll.adjust_bodytemperature(-8 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, doll.get_body_temp_normal())
if(doll.getToxLoss() && SPT_PROB(10, seconds_per_tick))
doll.adjustToxLoss(-0.5, FALSE, required_biotype = affected_biotype)
return ..()
@@ -1669,14 +1669,14 @@
icon = 'icons/obj/drinks/mixed_drinks.dmi'
icon_state = "mississippiglass"
/datum/reagent/consumable/mississippi_queen/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/consumable/mississippi_queen/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
switch(current_cycle)
if(10 to 20)
drinker.adjust_dizzy(4 SECONDS * REM * delta_time)
drinker.adjust_dizzy(4 SECONDS * REM * seconds_per_tick)
if(20 to 30)
if(DT_PROB(15, delta_time))
drinker.adjust_confusion(4 SECONDS * REM * delta_time)
if(SPT_PROB(15, seconds_per_tick))
drinker.adjust_confusion(4 SECONDS * REM * seconds_per_tick)
if(30 to 200)
drinker.adjust_hallucinations(60 SECONDS * REM * delta_time)
drinker.adjust_hallucinations(60 SECONDS * REM * seconds_per_tick)
return ..()

View File

@@ -17,11 +17,11 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/hallucinogens = 10) //4 per 2 seconds
/datum/reagent/drug/space_drugs/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_drugginess(30 SECONDS * REM * delta_time)
if(isturf(affected_mob.loc) && !isspaceturf(affected_mob.loc) && !HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && DT_PROB(5, delta_time))
/datum/reagent/drug/space_drugs/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_drugginess(30 SECONDS * REM * seconds_per_tick)
if(isturf(affected_mob.loc) && !isspaceturf(affected_mob.loc) && !HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && SPT_PROB(5, seconds_per_tick))
step(affected_mob, pick(GLOB.cardinals))
if(DT_PROB(3.5, delta_time))
if(SPT_PROB(3.5, seconds_per_tick))
affected_mob.emote(pick("twitch","drool","moan","giggle"))
..()
@@ -29,9 +29,9 @@
to_chat(affected_mob, span_userdanger("You start tripping hard!"))
affected_mob.add_mood_event("[type]_overdose", /datum/mood_event/overdose, name)
/datum/reagent/drug/space_drugs/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/drug/space_drugs/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
var/hallucination_duration_in_seconds = (affected_mob.get_timed_status_effect_duration(/datum/status_effect/hallucination) / 10)
if(hallucination_duration_in_seconds < volume && DT_PROB(10, delta_time))
if(hallucination_duration_in_seconds < volume && SPT_PROB(10, seconds_per_tick))
affected_mob.adjust_hallucinations(10 SECONDS)
..()
@@ -44,18 +44,18 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
metabolization_rate = 0.125 * REAGENTS_METABOLISM
/datum/reagent/drug/cannabis/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/cannabis/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.apply_status_effect(/datum/status_effect/stoned)
if(DT_PROB(1, delta_time))
if(SPT_PROB(1, seconds_per_tick))
var/smoke_message = pick("You feel relaxed.","You feel calmed.","Your mouth feels dry.","You could use some water.","Your heart beats quickly.","You feel clumsy.","You crave junk food.","You notice you've been moving more slowly.")
to_chat(affected_mob, "<span class='notice'>[smoke_message]</span>")
if(DT_PROB(2, delta_time))
if(SPT_PROB(2, seconds_per_tick))
affected_mob.emote(pick("smile","laugh","giggle"))
affected_mob.adjust_nutrition(-0.15 * REM * delta_time) //munchies
if(DT_PROB(4, delta_time) && affected_mob.body_position == LYING_DOWN && !affected_mob.IsSleeping()) //chance to fall asleep if lying down
affected_mob.adjust_nutrition(-0.15 * REM * seconds_per_tick) //munchies
if(SPT_PROB(4, seconds_per_tick) && affected_mob.body_position == LYING_DOWN && !affected_mob.IsSleeping()) //chance to fall asleep if lying down
to_chat(affected_mob, "<span class='warning'>You doze off...</span>")
affected_mob.Sleeping(10 SECONDS)
if(DT_PROB(4, delta_time) && affected_mob.buckled && affected_mob.body_position != LYING_DOWN && !affected_mob.IsParalyzed()) //chance to be couchlocked if sitting
if(SPT_PROB(4, seconds_per_tick) && affected_mob.buckled && affected_mob.body_position != LYING_DOWN && !affected_mob.IsParalyzed()) //chance to be couchlocked if sitting
to_chat(affected_mob, "<span class='warning'>It's too comfy to move...</span>")
affected_mob.Paralyze(10 SECONDS)
return ..()
@@ -81,23 +81,23 @@
mytray.adjust_toxic(round(chems.get_reagent_amount(type)))
mytray.adjust_pestlevel(-rand(1, 2))
/datum/reagent/drug/nicotine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(0.5, delta_time))
/datum/reagent/drug/nicotine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(0.5, seconds_per_tick))
var/smoke_message = pick("You feel relaxed.", "You feel calmed.","You feel alert.","You feel rugged.")
to_chat(affected_mob, span_notice("[smoke_message]"))
affected_mob.add_mood_event("smoked", /datum/mood_event/smoked, name)
affected_mob.remove_status_effect(/datum/status_effect/jitter)
affected_mob.AdjustStun(-50 * REM * delta_time)
affected_mob.AdjustKnockdown(-50 * REM * delta_time)
affected_mob.AdjustUnconscious(-50 * REM * delta_time)
affected_mob.AdjustParalyzed(-50 * REM * delta_time)
affected_mob.AdjustImmobilized(-50 * REM * delta_time)
affected_mob.AdjustStun(-50 * REM * seconds_per_tick)
affected_mob.AdjustKnockdown(-50 * REM * seconds_per_tick)
affected_mob.AdjustUnconscious(-50 * REM * seconds_per_tick)
affected_mob.AdjustParalyzed(-50 * REM * seconds_per_tick)
affected_mob.AdjustImmobilized(-50 * REM * seconds_per_tick)
..()
. = TRUE
/datum/reagent/drug/nicotine/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(0.1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOxyLoss(1.1 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
/datum/reagent/drug/nicotine/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(0.1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOxyLoss(1.1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
..()
. = TRUE
@@ -112,9 +112,9 @@
addiction_types = list(/datum/addiction/opioids = 18) //7.2 per 2 seconds
/datum/reagent/drug/krokodil/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/krokodil/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/high_message = pick("You feel calm.", "You feel collected.", "You feel like you need to relax.")
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[high_message]"))
affected_mob.add_mood_event("smacked out", /datum/mood_event/narcotic_heavy, name)
if(current_cycle == 35 && creation_purity <= 0.6)
@@ -128,9 +128,9 @@
affected_mob.adjustBruteLoss(50 * REM, FALSE, required_bodytype = affected_bodytype) // holy shit your skin just FELL THE FUCK OFF
..()
/datum/reagent/drug/krokodil/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.25 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(0.25 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/drug/krokodil/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.25 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(0.25 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
. = TRUE
@@ -170,36 +170,36 @@
L.remove_movespeed_modifier(/datum/movespeed_modifier/reagent/methamphetamine)
..()
/datum/reagent/drug/methamphetamine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/methamphetamine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/high_message = pick("You feel hyper.", "You feel like you need to go faster.", "You feel like you can run the world.")
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[high_message]"))
affected_mob.add_mood_event("tweaking", /datum/mood_event/stimulant_medium, name)
affected_mob.AdjustStun(-40 * REM * delta_time)
affected_mob.AdjustKnockdown(-40 * REM * delta_time)
affected_mob.AdjustUnconscious(-40 * REM * delta_time)
affected_mob.AdjustParalyzed(-40 * REM * delta_time)
affected_mob.AdjustImmobilized(-40 * REM * delta_time)
affected_mob.adjustStaminaLoss(-2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.set_jitter_if_lower(4 SECONDS * REM * delta_time)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, rand(1, 4) * REM * delta_time, required_organtype = affected_organtype)
if(DT_PROB(2.5, delta_time))
affected_mob.AdjustStun(-40 * REM * seconds_per_tick)
affected_mob.AdjustKnockdown(-40 * REM * seconds_per_tick)
affected_mob.AdjustUnconscious(-40 * REM * seconds_per_tick)
affected_mob.AdjustParalyzed(-40 * REM * seconds_per_tick)
affected_mob.AdjustImmobilized(-40 * REM * seconds_per_tick)
affected_mob.adjustStaminaLoss(-2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.set_jitter_if_lower(4 SECONDS * REM * seconds_per_tick)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, rand(1, 4) * REM * seconds_per_tick, required_organtype = affected_organtype)
if(SPT_PROB(2.5, seconds_per_tick))
affected_mob.emote(pick("twitch", "shiver"))
..()
. = TRUE
/datum/reagent/drug/methamphetamine/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/drug/methamphetamine/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
if(!HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && !ismovable(affected_mob.loc))
for(var/i in 1 to round(4 * REM * delta_time, 1))
for(var/i in 1 to round(4 * REM * seconds_per_tick, 1))
step(affected_mob, pick(GLOB.cardinals))
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_mob.emote("laugh")
if(DT_PROB(18, delta_time))
if(SPT_PROB(18, seconds_per_tick))
affected_mob.visible_message(span_danger("[affected_mob]'s hands flip out and flail everywhere!"))
affected_mob.drop_all_held_items()
..()
affected_mob.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, (rand(5, 10) / 10) * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, (rand(5, 10) / 10) * REM * seconds_per_tick, required_organtype = affected_organtype)
. = TRUE
/datum/reagent/drug/bath_salts
@@ -228,28 +228,28 @@
QDEL_NULL(rage)
..()
/datum/reagent/drug/bath_salts/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/bath_salts/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/high_message = pick("You feel amped up.", "You feel ready.", "You feel like you can push it to the limit.")
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[high_message]"))
affected_mob.add_mood_event("salted", /datum/mood_event/stimulant_heavy, name)
affected_mob.adjustStaminaLoss(-5 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 4 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjust_hallucinations(10 SECONDS * REM * delta_time)
affected_mob.adjustStaminaLoss(-5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 4 * REM * seconds_per_tick, required_organtype = affected_organtype)
affected_mob.adjust_hallucinations(10 SECONDS * REM * seconds_per_tick)
if(!HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && !ismovable(affected_mob.loc))
step(affected_mob, pick(GLOB.cardinals))
step(affected_mob, pick(GLOB.cardinals))
..()
. = TRUE
/datum/reagent/drug/bath_salts/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.adjust_hallucinations(10 SECONDS * REM * delta_time)
/datum/reagent/drug/bath_salts/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_hallucinations(10 SECONDS * REM * seconds_per_tick)
if(!HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && !ismovable(affected_mob.loc))
for(var/i in 1 to round(8 * REM * delta_time, 1))
for(var/i in 1 to round(8 * REM * seconds_per_tick, 1))
step(affected_mob, pick(GLOB.cardinals))
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_mob.emote(pick("twitch","drool","moan"))
if(DT_PROB(28, delta_time))
if(SPT_PROB(28, seconds_per_tick))
affected_mob.drop_all_held_items()
..()
@@ -261,13 +261,13 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/stimulants = 8)
/datum/reagent/drug/aranesp/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/aranesp/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/high_message = pick("You feel amped up.", "You feel ready.", "You feel like you can push it to the limit.")
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[high_message]"))
affected_mob.adjustStaminaLoss(-18 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(0.5 * REM * delta_time, FALSE, required_biotype = affected_biotype)
if(DT_PROB(30, delta_time))
affected_mob.adjustStaminaLoss(-18 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(0.5 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
if(SPT_PROB(30, seconds_per_tick))
affected_mob.losebreath++
affected_mob.adjustOxyLoss(1, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
..()
@@ -293,16 +293,16 @@
L.clear_mood_event("happiness_drug")
..()
/datum/reagent/drug/happiness/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/happiness/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.remove_status_effect(/datum/status_effect/jitter)
affected_mob.remove_status_effect(/datum/status_effect/confusion)
affected_mob.disgust = 0
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.2 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.2 * REM * seconds_per_tick, required_organtype = affected_organtype)
..()
. = TRUE
/datum/reagent/drug/happiness/overdose_process(mob/living/affected_mob, delta_time, times_fired)
if(DT_PROB(16, delta_time))
/datum/reagent/drug/happiness/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(16, seconds_per_tick))
var/reaction = rand(1,3)
switch(reaction)
if(1)
@@ -314,7 +314,7 @@
if(3)
affected_mob.emote("frown")
affected_mob.add_mood_event("happiness_drug", /datum/mood_event/happiness_drug_bad_od)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.5 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.5 * REM * seconds_per_tick, required_organtype = affected_organtype)
..()
. = TRUE
@@ -336,12 +336,12 @@
REMOVE_TRAIT(L, TRAIT_BATON_RESISTANCE, type)
..()
/datum/reagent/drug/pumpup/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
/datum/reagent/drug/pumpup/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
to_chat(affected_mob, span_notice("[pick("Go! Go! GO!", "You feel ready...", "You feel invincible...")]"))
if(DT_PROB(7.5, delta_time))
if(SPT_PROB(7.5, seconds_per_tick))
affected_mob.losebreath++
affected_mob.adjustToxLoss(2, FALSE, required_biotype = affected_biotype)
..()
@@ -350,16 +350,16 @@
/datum/reagent/drug/pumpup/overdose_start(mob/living/affected_mob)
to_chat(affected_mob, span_userdanger("You can't stop shaking, your heart beats faster and faster..."))
/datum/reagent/drug/pumpup/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * delta_time)
if(DT_PROB(2.5, delta_time))
/datum/reagent/drug/pumpup/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
if(SPT_PROB(2.5, seconds_per_tick))
affected_mob.drop_all_held_items()
if(DT_PROB(7.5, delta_time))
if(SPT_PROB(7.5, seconds_per_tick))
affected_mob.emote(pick("twitch","drool"))
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_mob.losebreath++
affected_mob.adjustStaminaLoss(4, FALSE, required_biotype = affected_biotype)
if(DT_PROB(7.5, delta_time))
if(SPT_PROB(7.5, seconds_per_tick))
affected_mob.adjustToxLoss(2, FALSE, required_biotype = affected_biotype)
..()
@@ -377,22 +377,22 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/maintenance_drugs = 14)
/datum/reagent/drug/maint/powder/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/powder/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.1 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.1 * REM * seconds_per_tick, required_organtype = affected_organtype)
// 5x if you want to OD, you can potentially go higher, but good luck managing the brain damage.
var/amt = max(round(volume/3, 0.1), 1)
affected_mob?.mind?.experience_multiplier_reasons |= type
affected_mob?.mind?.experience_multiplier_reasons[type] = amt * REM * delta_time
affected_mob?.mind?.experience_multiplier_reasons[type] = amt * REM * seconds_per_tick
/datum/reagent/drug/maint/powder/on_mob_end_metabolize(mob/living/affected_mob)
. = ..()
affected_mob?.mind?.experience_multiplier_reasons[type] = null
affected_mob?.mind?.experience_multiplier_reasons -= type
/datum/reagent/drug/maint/powder/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/powder/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 6 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 6 * REM * seconds_per_tick, required_organtype = affected_organtype)
/datum/reagent/drug/maint/sludge
name = "Maintenance Sludge"
@@ -409,22 +409,22 @@
. = ..()
ADD_TRAIT(L,TRAIT_HARDLY_WOUNDED,type)
/datum/reagent/drug/maint/sludge/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/sludge/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.adjustToxLoss(0.5 * REM * delta_time, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(0.5 * REM * seconds_per_tick, required_biotype = affected_biotype)
/datum/reagent/drug/maint/sludge/on_mob_end_metabolize(mob/living/affected_mob)
. = ..()
REMOVE_TRAIT(affected_mob, TRAIT_HARDLY_WOUNDED,type)
/datum/reagent/drug/maint/sludge/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/sludge/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
. = ..()
if(!iscarbon(affected_mob))
return
var/mob/living/carbon/carbie = affected_mob
//You will be vomiting so the damage is really for a few ticks before you flush it out of your system
carbie.adjustToxLoss(1 * REM * delta_time, required_biotype = affected_biotype)
if(DT_PROB(5, delta_time))
carbie.adjustToxLoss(1 * REM * seconds_per_tick, required_biotype = affected_biotype)
if(SPT_PROB(5, seconds_per_tick))
carbie.adjustToxLoss(5, required_biotype = affected_biotype)
carbie.vomit()
@@ -437,21 +437,21 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/maintenance_drugs = 5)
/datum/reagent/drug/maint/tar/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/tar/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.AdjustStun(-10 * REM * delta_time)
affected_mob.AdjustKnockdown(-10 * REM * delta_time)
affected_mob.AdjustUnconscious(-10 * REM * delta_time)
affected_mob.AdjustParalyzed(-10 * REM * delta_time)
affected_mob.AdjustImmobilized(-10 * REM * delta_time)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.AdjustStun(-10 * REM * seconds_per_tick)
affected_mob.AdjustKnockdown(-10 * REM * seconds_per_tick)
affected_mob.AdjustUnconscious(-10 * REM * seconds_per_tick)
affected_mob.AdjustParalyzed(-10 * REM * seconds_per_tick)
affected_mob.AdjustImmobilized(-10 * REM * seconds_per_tick)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 1.5 * REM * seconds_per_tick, required_organtype = affected_organtype)
/datum/reagent/drug/maint/tar/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/drug/maint/tar/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.adjustToxLoss(5 * REM * delta_time, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 3 * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustToxLoss(5 * REM * seconds_per_tick, required_biotype = affected_biotype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, 3 * REM * seconds_per_tick, required_organtype = affected_organtype)
/datum/reagent/drug/mushroomhallucinogen
name = "Mushroom Hallucinogen"
@@ -464,20 +464,20 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/hallucinogens = 12)
/datum/reagent/drug/mushroomhallucinogen/on_mob_life(mob/living/carbon/psychonaut, delta_time, times_fired)
psychonaut.set_slurring_if_lower(1 SECONDS * REM * delta_time)
/datum/reagent/drug/mushroomhallucinogen/on_mob_life(mob/living/carbon/psychonaut, seconds_per_tick, times_fired)
psychonaut.set_slurring_if_lower(1 SECONDS * REM * seconds_per_tick)
switch(current_cycle)
if(1 to 5)
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
psychonaut.emote(pick("twitch","giggle"))
if(5 to 10)
psychonaut.set_jitter_if_lower(20 SECONDS * REM * delta_time)
if(DT_PROB(10, delta_time))
psychonaut.set_jitter_if_lower(20 SECONDS * REM * seconds_per_tick)
if(SPT_PROB(10, seconds_per_tick))
psychonaut.emote(pick("twitch","giggle"))
if (10 to INFINITY)
psychonaut.set_jitter_if_lower(40 SECONDS * REM * delta_time)
if(DT_PROB(16, delta_time))
psychonaut.set_jitter_if_lower(40 SECONDS * REM * seconds_per_tick)
if(SPT_PROB(16, seconds_per_tick))
psychonaut.emote(pick("twitch","giggle"))
..()
@@ -517,12 +517,12 @@
game_plane_master_controller.remove_filter("rainbow")
game_plane_master_controller.remove_filter("psilocybin_wave")
/datum/reagent/drug/mushroomhallucinogen/overdose_process(mob/living/psychonaut, delta_time, times_fired)
/datum/reagent/drug/mushroomhallucinogen/overdose_process(mob/living/psychonaut, seconds_per_tick, times_fired)
. = ..()
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
psychonaut.emote(pick("twitch","drool","moan"))
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
psychonaut.apply_status_effect(/datum/status_effect/tower_of_babel)
/datum/reagent/drug/blastoff
@@ -589,20 +589,20 @@
game_plane_master_controller.remove_filter("blastoff_wave")
dancer.sound_environment_override = NONE
/datum/reagent/drug/blastoff/on_mob_life(mob/living/carbon/dancer, delta_time, times_fired)
/datum/reagent/drug/blastoff/on_mob_life(mob/living/carbon/dancer, seconds_per_tick, times_fired)
. = ..()
dancer.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.3 * REM * delta_time, required_organtype = affected_organtype)
dancer.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.3 * REM * seconds_per_tick, required_organtype = affected_organtype)
dancer.AdjustKnockdown(-20)
if(DT_PROB(BLASTOFF_DANCE_MOVE_CHANCE_PER_UNIT * volume, delta_time))
if(SPT_PROB(BLASTOFF_DANCE_MOVE_CHANCE_PER_UNIT * volume, seconds_per_tick))
dancer.emote("flip")
/datum/reagent/drug/blastoff/overdose_process(mob/living/dancer, delta_time, times_fired)
/datum/reagent/drug/blastoff/overdose_process(mob/living/dancer, seconds_per_tick, times_fired)
. = ..()
dancer.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.3 * REM * delta_time, required_organtype = affected_organtype)
dancer.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.3 * REM * seconds_per_tick, required_organtype = affected_organtype)
if(DT_PROB(BLASTOFF_DANCE_MOVE_CHANCE_PER_UNIT * volume, delta_time))
if(SPT_PROB(BLASTOFF_DANCE_MOVE_CHANCE_PER_UNIT * volume, seconds_per_tick))
dancer.emote("spin")
///This proc listens to the flip signal and throws the mob every third flip
@@ -661,9 +661,9 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/maintenance_drugs = 20)
/datum/reagent/drug/saturnx/on_mob_life(mob/living/carbon/invisible_man, delta_time, times_fired)
/datum/reagent/drug/saturnx/on_mob_life(mob/living/carbon/invisible_man, seconds_per_tick, times_fired)
. = ..()
invisible_man.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.3 * REM * delta_time, required_organtype = affected_organtype)
invisible_man.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.3 * REM * seconds_per_tick, required_organtype = affected_organtype)
/datum/reagent/drug/saturnx/on_mob_metabolize(mob/living/invisible_man)
. = ..()
@@ -741,13 +741,13 @@
game_plane_master_controller.remove_filter("saturnx_filter")
game_plane_master_controller.remove_filter("saturnx_blur")
/datum/reagent/drug/saturnx/overdose_process(mob/living/invisible_man, delta_time, times_fired)
/datum/reagent/drug/saturnx/overdose_process(mob/living/invisible_man, seconds_per_tick, times_fired)
. = ..()
if(DT_PROB(7.5, delta_time))
if(SPT_PROB(7.5, seconds_per_tick))
invisible_man.emote("giggle")
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
invisible_man.emote("laugh")
invisible_man.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.4 * REM * delta_time, required_organtype = affected_organtype)
invisible_man.adjustOrganLoss(ORGAN_SLOT_LIVER, 0.4 * REM * seconds_per_tick, required_organtype = affected_organtype)
/datum/reagent/drug/saturnx/stable
name = "Stabilized Saturn-X"
@@ -786,13 +786,13 @@
druggo.adjustStaminaLoss(-4 * trans_volume, 0)
//I wish i could give it some kind of bonus when smoked, but we don't have an INHALE method.
/datum/reagent/drug/kronkaine/on_mob_life(mob/living/carbon/kronkaine_fiend, delta_time, times_fired)
/datum/reagent/drug/kronkaine/on_mob_life(mob/living/carbon/kronkaine_fiend, seconds_per_tick, times_fired)
. = ..()
kronkaine_fiend.add_mood_event("tweaking", /datum/mood_event/stimulant_medium, name)
kronkaine_fiend.adjustOrganLoss(ORGAN_SLOT_HEART, 0.4 * REM * delta_time, required_organtype = affected_organtype)
kronkaine_fiend.set_jitter_if_lower(20 SECONDS * REM * delta_time)
kronkaine_fiend.AdjustSleeping(-20 * REM * delta_time)
kronkaine_fiend.adjust_drowsiness(-10 SECONDS * REM * delta_time)
kronkaine_fiend.adjustOrganLoss(ORGAN_SLOT_HEART, 0.4 * REM * seconds_per_tick, required_organtype = affected_organtype)
kronkaine_fiend.set_jitter_if_lower(20 SECONDS * REM * seconds_per_tick)
kronkaine_fiend.AdjustSleeping(-20 * REM * seconds_per_tick)
kronkaine_fiend.adjust_drowsiness(-10 SECONDS * REM * seconds_per_tick)
if(volume < 10)
return
for(var/possible_purger in kronkaine_fiend.reagents.reagent_list)
@@ -800,11 +800,11 @@
kronkaine_fiend.ForceContractDisease(new /datum/disease/adrenal_crisis(), FALSE, TRUE) //We punish players for purging, since unchecked purging would allow players to reap the stamina healing benefits without any drawbacks. This also has the benefit of making haloperidol a counter, like it is supposed to be.
break
/datum/reagent/drug/kronkaine/overdose_process(mob/living/kronkaine_fiend, delta_time, times_fired)
/datum/reagent/drug/kronkaine/overdose_process(mob/living/kronkaine_fiend, seconds_per_tick, times_fired)
. = ..()
kronkaine_fiend.adjustOrganLoss(ORGAN_SLOT_HEART, 1 * REM * delta_time, required_organtype = affected_organtype)
kronkaine_fiend.set_jitter_if_lower(20 SECONDS * REM * delta_time)
if(DT_PROB(10, delta_time))
kronkaine_fiend.adjustOrganLoss(ORGAN_SLOT_HEART, 1 * REM * seconds_per_tick, required_organtype = affected_organtype)
kronkaine_fiend.set_jitter_if_lower(20 SECONDS * REM * seconds_per_tick)
if(SPT_PROB(10, seconds_per_tick))
to_chat(kronkaine_fiend, span_danger(pick("You feel like your heart is going to explode!", "Your ears are ringing!", "You sweat like a pig!", "You clench your jaw and grind your teeth.", "You feel prickles of pain in your chest.")))
///dirty kronkaine, aka gore. far worse overdose effects.

View File

@@ -18,15 +18,15 @@
/// affects mood, typically higher for mixed drinks with more complex recipes'
var/quality = 0
/datum/reagent/consumable/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
current_cycle++
if(ishuman(M))
var/mob/living/carbon/human/H = M
if(!HAS_TRAIT(H, TRAIT_NOHUNGER))
H.adjust_nutrition(nutriment_factor * REM * delta_time)
H.adjust_nutrition(nutriment_factor * REM * seconds_per_tick)
if(length(reagent_removal_skip_list))
return
holder.remove_reagent(type, metabolization_rate * delta_time)
holder.remove_reagent(type, metabolization_rate * seconds_per_tick)
/datum/reagent/consumable/expose_mob(mob/living/exposed_mob, methods=TOUCH, reac_volume)
. = ..()
@@ -70,8 +70,8 @@
mytray.adjust_plant_health(round(chems.get_reagent_amount(type) * 0.2))
/datum/reagent/consumable/nutriment/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
if(DT_PROB(30, delta_time))
/datum/reagent/consumable/nutriment/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(SPT_PROB(30, seconds_per_tick))
M.heal_bodypart_damage(brute = brute_heal, burn = burn_heal, updating_health = FALSE, required_bodytype = BODYTYPE_ORGANIC)
. = TRUE
..()
@@ -125,9 +125,9 @@
brute_heal = 1
burn_heal = 1
/datum/reagent/consumable/nutriment/vitamin/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/nutriment/vitamin/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(M.satiety < MAX_SATIETY)
M.satiety += 30 * REM * delta_time
M.satiety += 30 * REM * seconds_per_tick
. = ..()
/// The basic resource of vat growing.
@@ -154,7 +154,7 @@
///Amount of satiety that will be drained when the cloth_fibers is fully metabolized
var/delayed_satiety_drain = 2 * CLOTHING_NUTRITION_GAIN
/datum/reagent/consumable/nutriment/cloth_fibers/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/nutriment/cloth_fibers/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(M.satiety < MAX_SATIETY)
M.adjust_nutrition(CLOTHING_NUTRITION_GAIN)
delayed_satiety_drain += CLOTHING_NUTRITION_GAIN
@@ -249,8 +249,8 @@
M.AdjustSleeping(600)
. = TRUE
/datum/reagent/consumable/sugar/overdose_process(mob/living/M, delta_time, times_fired)
M.AdjustSleeping(40 * REM * delta_time)
/datum/reagent/consumable/sugar/overdose_process(mob/living/M, seconds_per_tick, times_fired)
M.AdjustSleeping(40 * REM * seconds_per_tick)
..()
. = TRUE
@@ -295,13 +295,13 @@
taste_mult = 1.5
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/capsaicin/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/capsaicin/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
var/heating = 0
switch(current_cycle)
if(1 to 15)
heating = 5
if(holder.has_reagent(/datum/reagent/cryostylane))
holder.remove_reagent(/datum/reagent/cryostylane, 5 * REM * delta_time)
holder.remove_reagent(/datum/reagent/cryostylane, 5 * REM * seconds_per_tick)
if(isslime(M))
heating = rand(5, 20)
if(15 to 25)
@@ -316,7 +316,7 @@
heating = 20
if(isslime(M))
heating = rand(20, 25)
M.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time)
M.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick)
..()
/datum/reagent/consumable/frostoil
@@ -330,13 +330,13 @@
specific_heat = 40
default_container = /obj/item/reagent_containers/cup/bottle/frostoil
/datum/reagent/consumable/frostoil/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/frostoil/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
var/cooling = 0
switch(current_cycle)
if(1 to 15)
cooling = -10
if(holder.has_reagent(/datum/reagent/consumable/capsaicin))
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 5 * REM * delta_time)
holder.remove_reagent(/datum/reagent/consumable/capsaicin, 5 * REM * seconds_per_tick)
if(isslime(M))
cooling = -rand(5, 20)
if(15 to 25)
@@ -355,7 +355,7 @@
M.emote("shiver")
if(isslime(M))
cooling = -rand(20, 25)
M.adjust_bodytemperature(cooling * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 50)
M.adjust_bodytemperature(cooling * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 50)
..()
/datum/reagent/consumable/frostoil/expose_turf(turf/exposed_turf, reac_volume)
@@ -414,9 +414,9 @@
if(prob(5))
victim.vomit()
/datum/reagent/consumable/condensedcapsaicin/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/condensedcapsaicin/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(!holder.has_reagent(/datum/reagent/consumable/milk))
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
M.visible_message(span_warning("[M] [pick("dry heaves!","coughs!","splutters!")]"))
..()
@@ -471,16 +471,16 @@
. = ..()
REMOVE_TRAIT(L, TRAIT_GARLIC_BREATH, type)
/datum/reagent/consumable/garlic/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/garlic/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(isvampire(M)) //incapacitating but not lethal. Unfortunately, vampires cannot vomit.
if(DT_PROB(min(current_cycle/2, 12.5), delta_time))
if(SPT_PROB(min(current_cycle/2, 12.5), seconds_per_tick))
to_chat(M, span_danger("You can't get the scent of garlic out of your nose! You can barely think..."))
M.Paralyze(10)
M.set_jitter_if_lower(20 SECONDS)
else
var/obj/item/organ/internal/liver/liver = M.get_organ_slot(ORGAN_SLOT_LIVER)
if(liver && HAS_TRAIT(liver, TRAIT_CULINARY_METABOLISM))
if(DT_PROB(10, delta_time)) //stays in the system much longer than sprinkles/banana juice, so heals slower to partially compensate
if(SPT_PROB(10, seconds_per_tick)) //stays in the system much longer than sprinkles/banana juice, so heals slower to partially compensate
M.heal_bodypart_damage(brute = 1, burn = 1)
. = TRUE
..()
@@ -512,10 +512,10 @@
taste_description = "childhood whimsy"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/sprinkles/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/sprinkles/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
var/obj/item/organ/internal/liver/liver = M.get_organ_slot(ORGAN_SLOT_LIVER)
if(liver && HAS_TRAIT(liver, TRAIT_LAW_ENFORCEMENT_METABOLISM))
M.heal_bodypart_damage(1 * REM * delta_time, 1 * REM * delta_time, 0)
M.heal_bodypart_damage(1 * REM * seconds_per_tick, 1 * REM * seconds_per_tick, 0)
. = TRUE
..()
@@ -574,8 +574,8 @@
taste_description = "your imprisonment"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/hot_ramen/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
M.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, 0, M.get_body_temp_normal())
/datum/reagent/consumable/hot_ramen/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
M.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, 0, M.get_body_temp_normal())
..()
/datum/reagent/consumable/hell_ramen
@@ -586,8 +586,8 @@
taste_description = "wet and cheap noodles on fire"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/hell_ramen/on_mob_life(mob/living/carbon/target_mob, delta_time, times_fired)
target_mob.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time)
/datum/reagent/consumable/hell_ramen/on_mob_life(mob/living/carbon/target_mob, seconds_per_tick, times_fired)
target_mob.adjust_bodytemperature(10 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick)
..()
/datum/reagent/consumable/flour
@@ -673,8 +673,8 @@
taste_description = "sweet slime"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/corn_syrup/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
holder.add_reagent(/datum/reagent/consumable/sugar, 3 * REM * delta_time)
/datum/reagent/consumable/corn_syrup/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
holder.add_reagent(/datum/reagent/consumable/sugar, 3 * REM * seconds_per_tick)
..()
/datum/reagent/consumable/honey
@@ -698,9 +698,9 @@
mytray.adjust_weedlevel(rand(1,2))
mytray.adjust_pestlevel(rand(1,2))
/datum/reagent/consumable/honey/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
holder.add_reagent(/datum/reagent/consumable/sugar, 3 * REM * delta_time)
if(DT_PROB(33, delta_time))
/datum/reagent/consumable/honey/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
holder.add_reagent(/datum/reagent/consumable/sugar, 3 * REM * seconds_per_tick)
if(SPT_PROB(33, seconds_per_tick))
M.adjustBruteLoss(-1, FALSE, required_bodytype = affected_bodytype)
M.adjustFireLoss(-1, FALSE, required_bodytype = affected_bodytype)
M.adjustOxyLoss(-1, FALSE, required_biotype = affected_biotype)
@@ -746,9 +746,9 @@
color = "#664330" // rgb: 102, 67, 48
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/nutriment/stabilized/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/nutriment/stabilized/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(M.nutrition > NUTRITION_LEVEL_FULL - 25)
M.adjust_nutrition(-3 * REM * nutriment_factor * delta_time)
M.adjust_nutrition(-3 * REM * nutriment_factor * seconds_per_tick)
..()
////Lavaland Flora Reagents////
@@ -762,11 +762,11 @@
ph = 12
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/entpoly/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/entpoly/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(current_cycle >= 10)
M.Unconscious(40 * REM * delta_time, FALSE)
M.Unconscious(40 * REM * seconds_per_tick, FALSE)
. = TRUE
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
M.losebreath += 4
M.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2*REM, 150, affected_biotype)
M.adjustToxLoss(3*REM, FALSE, required_biotype = affected_biotype)
@@ -819,8 +819,8 @@
ph = 10.4
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/vitfro/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
if(DT_PROB(55, delta_time))
/datum/reagent/consumable/vitfro/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(SPT_PROB(55, seconds_per_tick))
M.adjustBruteLoss(-1, FALSE, required_bodytype = affected_bodytype)
M.adjustFireLoss(-1, FALSE, required_bodytype = affected_bodytype)
. = TRUE
@@ -847,10 +847,10 @@
if(istype(stomach))
stomach.adjust_charge(reac_volume * 30)
/datum/reagent/consumable/liquidelectricity/enriched/on_mob_life(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/liquidelectricity/enriched/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired)
if(isethereal(M))
M.blood_volume += 1 * delta_time
else if(DT_PROB(10, delta_time)) //lmao at the newbs who eat energy bars
M.blood_volume += 1 * seconds_per_tick
else if(SPT_PROB(10, seconds_per_tick)) //lmao at the newbs who eat energy bars
M.electrocute_act(rand(5,10), "Liquid Electricity in their body", 1, SHOCK_NOGLOVES) //the shock is coming from inside the house
playsound(M, SFX_SPARKS, 50, TRUE, SHORT_RANGE_SOUND_EXTRARANGE)
return ..()
@@ -867,9 +867,9 @@
overdose_threshold = 17
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/astrotame/overdose_process(mob/living/carbon/M, delta_time, times_fired)
/datum/reagent/consumable/astrotame/overdose_process(mob/living/carbon/M, seconds_per_tick, times_fired)
if(M.disgust < 80)
M.adjust_disgust(10 * REM * delta_time)
M.adjust_disgust(10 * REM * seconds_per_tick)
..()
. = TRUE
@@ -916,8 +916,8 @@
overdose_threshold = 15
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/char/overdose_process(mob/living/M, delta_time, times_fired)
if(DT_PROB(13, delta_time))
/datum/reagent/consumable/char/overdose_process(mob/living/M, seconds_per_tick, times_fired)
if(SPT_PROB(13, seconds_per_tick))
M.say(pick_list_replacements(BOOMER_FILE, "boomer"), forced = /datum/reagent/consumable/char)
..()
return
@@ -1030,10 +1030,10 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
default_container = /obj/item/reagent_containers/condiment/peanut_butter
/datum/reagent/consumable/peanut_butter/on_mob_life(mob/living/carbon/M, delta_time, times_fired) //ET loves peanut butter
/datum/reagent/consumable/peanut_butter/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired) //ET loves peanut butter
if(isabductor(M))
M.add_mood_event("ET_pieces", /datum/mood_event/et_pieces, name)
M.set_drugginess(30 SECONDS * REM * delta_time)
M.set_drugginess(30 SECONDS * REM * seconds_per_tick)
..()
/datum/reagent/consumable/vinegar
@@ -1100,7 +1100,7 @@
taste_description = "mint"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/consumable/mintextract/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/consumable/mintextract/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(HAS_TRAIT(affected_mob, TRAIT_FAT))
affected_mob.investigate_log("has been gibbed by consuming [src] while fat.", INVESTIGATE_DEATHS)
affected_mob.inflate_gib()

View File

@@ -14,12 +14,12 @@
metabolization_rate = 0.1 * REM //default impurity is 0.75, so we get 25% converted. Default metabolisation rate is 0.4, so we're 4 times slower.
var/liver_damage = 0.5
/datum/reagent/impurity/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/impurity/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/obj/item/organ/internal/liver/L = affected_mob.get_organ_slot(ORGAN_SLOT_LIVER)
if(!L)//Though, lets be safe
affected_mob.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)//Incase of no liver!
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)//Incase of no liver!
return ..()
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, liver_damage * REM * delta_time, required_organtype = affected_organtype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LIVER, liver_damage * REM * seconds_per_tick, required_organtype = affected_organtype)
return ..()
//Basically just so people don't forget to adjust metabolization_rate
@@ -34,8 +34,8 @@
var/tox_damage = 1
/datum/reagent/inverse/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(tox_damage * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/inverse/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(tox_damage * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
return ..()
//Failed chems - generally use inverse if you want to use a impure subtype for it
@@ -105,7 +105,7 @@
cryostylane_alert.attached_effect = src //so the alert can reference us, if it needs to
..()
/datum/reagent/inverse/cryostylane/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/inverse/cryostylane/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!cube || affected_mob.loc != cube)
affected_mob.reagents.remove_reagent(type, volume) //remove it all if we're past 60s
if(current_cycle > 60)

View File

@@ -35,7 +35,7 @@
affected_respiration_type = ALL
//Random healing of the 4 main groups
/datum/reagent/impurity/healing/medicine_failure/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/impurity/healing/medicine_failure/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
var/pick = pick("brute", "burn", "tox", "oxy")
switch(pick)
if("brute")
@@ -57,7 +57,7 @@
metabolization_rate = 1*REM //This is fast
tox_damage = 0.25
ph = 14
//Compensates for delta_time lag by spawning multiple hands at the end
//Compensates for seconds_per_tick lag by spawning multiple hands at the end
var/lag_remainder = 0
//Keeps track of the hand timer so we can cleanup on removal
var/list/timer_ids
@@ -71,25 +71,25 @@
//Sends hands after you for your hubris
/*
How it works:
Standard delta_time for a reagent is 2s - and volume consumption is equal to the volume * delta_time.
Standard seconds_per_tick for a reagent is 2s - and volume consumption is equal to the volume * seconds_per_tick.
In this chem, I want to consume 0.5u for 1 hand created (since 1*REM is 0.5) so on a single tick I create a hand and set up a callback for another one in 1s from now. But since delta time can vary, I want to be able to create more hands for when the delay is longer.
Initally I round delta_time to the nearest whole number, and take the part that I am rounding down from (i.e. the decimal numbers) and keep track of them. If the decimilised numbers go over 1, then the number is reduced down and an extra hand is created that tick.
Initally I round seconds_per_tick to the nearest whole number, and take the part that I am rounding down from (i.e. the decimal numbers) and keep track of them. If the decimilised numbers go over 1, then the number is reduced down and an extra hand is created that tick.
Then I attempt to calculate the how many hands to created based off the current delta_time, since I can't know the delay to the next one it assumes the next will be in 2s.
I take the 2s interval period and divide it by the number of hands I want to make (i.e. the current delta_time) and I keep track of how many hands I'm creating (since I always create one on a tick, then I start at 1 hand). For each hand I then use this time value multiplied by the number of hands. Since we're spawning one now, and it checks to see if hands is less than, but not less than or equal to, delta_time, no hands will be created on the next expected tick.
Then I attempt to calculate the how many hands to created based off the current seconds_per_tick, since I can't know the delay to the next one it assumes the next will be in 2s.
I take the 2s interval period and divide it by the number of hands I want to make (i.e. the current seconds_per_tick) and I keep track of how many hands I'm creating (since I always create one on a tick, then I start at 1 hand). For each hand I then use this time value multiplied by the number of hands. Since we're spawning one now, and it checks to see if hands is less than, but not less than or equal to, seconds_per_tick, no hands will be created on the next expected tick.
Basically, we fill the time between now and 2s from now with hands based off the current lag.
*/
/datum/reagent/inverse/helgrasp/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/inverse/helgrasp/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
spawn_hands(owner)
lag_remainder += delta_time - FLOOR(delta_time, 1)
delta_time = FLOOR(delta_time, 1)
lag_remainder += seconds_per_tick - FLOOR(seconds_per_tick, 1)
seconds_per_tick = FLOOR(seconds_per_tick, 1)
if(lag_remainder >= 1)
delta_time += 1
seconds_per_tick += 1
lag_remainder -= 1
var/hands = 1
var/time = 2 / delta_time
while(hands < delta_time) //we already made a hand now so start from 1
var/time = 2 / seconds_per_tick
while(hands < seconds_per_tick) //we already made a hand now so start from 1
LAZYADD(timer_ids, addtimer(CALLBACK(src, PROC_REF(spawn_hands), owner), (time*hands) SECONDS, TIMER_STOPPABLE)) //keep track of all the timers we set up
hands += time
return ..()
@@ -195,9 +195,9 @@ Basically, we fill the time between now and 2s from now with hands based off the
description = "These inhibitory peptides cause cellular damage and cost nutrition to the patient!"
ph = 2.1
/datum/reagent/peptides_failed/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
owner.adjustCloneLoss(0.25 * delta_time)
owner.adjust_nutrition(-5 * REAGENTS_METABOLISM * delta_time)
/datum/reagent/peptides_failed/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
owner.adjustCloneLoss(0.25 * seconds_per_tick)
owner.adjust_nutrition(-5 * REAGENTS_METABOLISM * seconds_per_tick)
. = ..()
//Lenturi
@@ -231,7 +231,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
var/spammer = 0
//Just the removed itching mechanism - omage to it's origins.
/datum/reagent/inverse/ichiyuri/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/inverse/ichiyuri/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
if(prob(resetting_probability) && !(HAS_TRAIT(owner, TRAIT_RESTRAINED) || owner.incapacitated()))
if(spammer < world.time)
to_chat(owner,span_warning("You can't help but itch yourself."))
@@ -240,7 +240,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
owner.adjustBruteLoss(scab*REM)
owner.bleed(scab)
resetting_probability = 0
resetting_probability += (5*(current_cycle/10) * delta_time) // 10 iterations = >51% to itch
resetting_probability += (5*(current_cycle/10) * seconds_per_tick) // 10 iterations = >51% to itch
..()
return TRUE
@@ -277,9 +277,9 @@ Basically, we fill the time between now and 2s from now with hands based off the
taste_description = "heat! Ouch!"
addiction_types = list(/datum/addiction/medicine = 2.5)
/datum/reagent/inverse/hercuri/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/inverse/hercuri/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
. = ..()
var/heating = rand(5, 25) * creation_purity * REM * delta_time
var/heating = rand(5, 25) * creation_purity * REM * seconds_per_tick
owner.reagents?.chem_temp += heating
owner.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT)
if(!ishuman(owner))
@@ -295,10 +295,10 @@ Basically, we fill the time between now and 2s from now with hands based off the
exposed_mob.adjust_bodytemperature(reac_volume * TEMPERATURE_DAMAGE_COEFFICIENT)
exposed_mob.adjust_fire_stacks(reac_volume / 2)
/datum/reagent/inverse/hercuri/overdose_process(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/inverse/hercuri/overdose_process(mob/living/carbon/owner, seconds_per_tick, times_fired)
. = ..()
owner.adjustOrganLoss(ORGAN_SLOT_LIVER, 2 * REM * delta_time, required_organtype = affected_organtype) //Makes it so you can't abuse it with pyroxadone very easily (liver dies from 25u unless it's fully upgraded)
var/heating = 10 * creation_purity * REM * delta_time * TEMPERATURE_DAMAGE_COEFFICIENT
owner.adjustOrganLoss(ORGAN_SLOT_LIVER, 2 * REM * seconds_per_tick, required_organtype = affected_organtype) //Makes it so you can't abuse it with pyroxadone very easily (liver dies from 25u unless it's fully upgraded)
var/heating = 10 * creation_purity * REM * seconds_per_tick * TEMPERATURE_DAMAGE_COEFFICIENT
owner.adjust_bodytemperature(heating) //hot hot
if(ishuman(owner))
var/mob/living/carbon/human/human = owner
@@ -314,7 +314,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
addiction_types = list(/datum/addiction/medicine = 5)
//Makes patients fall asleep, then boosts the purirty of their medicine reagents if they're asleep
/datum/reagent/inverse/healing/tirimol/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
/datum/reagent/inverse/healing/tirimol/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
switch(current_cycle)
if(1 to 10)//same delay as chloral hydrate
if(prob(50))
@@ -436,8 +436,8 @@ Basically, we fill the time between now and 2s from now with hands based off the
var/poison_interval = (9 SECONDS)
/datum/reagent/inverse/technetium/on_mob_life(mob/living/carbon/owner, delta_time, times_fired)
time_until_next_poison -= delta_time * (1 SECONDS)
/datum/reagent/inverse/technetium/on_mob_life(mob/living/carbon/owner, seconds_per_tick, times_fired)
time_until_next_poison -= seconds_per_tick * (1 SECONDS)
if (time_until_next_poison <= 0)
time_until_next_poison = poison_interval
owner.adjustToxLoss(creation_purity * 1, required_biotype = affected_biotype)
@@ -489,11 +489,11 @@ Basically, we fill the time between now and 2s from now with hands based off the
addiction_types = list(/datum/addiction/medicine = 3.5)
//Heals toxins if it's the only thing present - kinda the oposite of multiver! Maybe that's why it's inverse!
/datum/reagent/inverse/healing/monover/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/inverse/healing/monover/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(length(affected_mob.reagents.reagent_list) > 1)
affected_mob.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.5 * delta_time, required_organtype = affected_organtype) //Hey! It's everyone's favourite drawback from multiver!
affected_mob.adjustOrganLoss(ORGAN_SLOT_LUNGS, 0.5 * seconds_per_tick, required_organtype = affected_organtype) //Hey! It's everyone's favourite drawback from multiver!
return ..()
affected_mob.adjustToxLoss(-2 * REM * creation_purity * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(-2 * REM * creation_purity * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
return TRUE
@@ -523,7 +523,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
TRAIT_STABLEHEART,
)
/datum/reagent/inverse/penthrite/on_mob_dead(mob/living/carbon/affected_mob, delta_time)
/datum/reagent/inverse/penthrite/on_mob_dead(mob/living/carbon/affected_mob, seconds_per_tick)
var/obj/item/organ/internal/heart/heart = affected_mob.get_organ_slot(ORGAN_SLOT_HEART)
if(!heart || heart.organ_flags & ORGAN_FAILING)
return ..()
@@ -543,7 +543,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
affected_mob.playsound_local(affected_mob, 'sound/health/fastbeat.ogg', 65)
..()
/datum/reagent/inverse/penthrite/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/inverse/penthrite/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!back_from_the_dead)
return ..()
//Following is for those brought back from the dead only
@@ -551,8 +551,8 @@ Basically, we fill the time between now and 2s from now with hands based off the
REMOVE_TRAIT(affected_mob, TRAIT_KNOCKEDOUT, OXYLOSS_TRAIT)
for(var/datum/wound/iter_wound as anything in affected_mob.all_wounds)
iter_wound.adjust_blood_flow(1-creation_purity)
affected_mob.adjustBruteLoss(5 * (1-creation_purity) * delta_time, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_HEART, (1 + (1-creation_purity)) * delta_time, required_organtype = affected_organtype)
affected_mob.adjustBruteLoss(5 * (1-creation_purity) * seconds_per_tick, required_bodytype = affected_bodytype)
affected_mob.adjustOrganLoss(ORGAN_SLOT_HEART, (1 + (1-creation_purity)) * seconds_per_tick, required_organtype = affected_organtype)
if(affected_mob.health < HEALTH_THRESHOLD_CRIT)
affected_mob.add_movespeed_modifier(/datum/movespeed_modifier/reagent/nooartrium)
if(affected_mob.health < HEALTH_THRESHOLD_FULLCRIT)
@@ -645,11 +645,11 @@ Basically, we fill the time between now and 2s from now with hands based off the
//The temporary trauma passed to the affected mob
var/datum/brain_trauma/temp_trauma
/datum/reagent/inverse/neurine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/inverse/neurine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
.=..()
if(temp_trauma)
return
if(!(DT_PROB(creation_purity*10, delta_time)))
if(!(SPT_PROB(creation_purity*10, seconds_per_tick)))
return
var/traumalist = subtypesof(/datum/brain_trauma)
var/list/forbiddentraumas = list(
@@ -756,9 +756,9 @@ Basically, we fill the time between now and 2s from now with hands based off the
color = "#4C8000"
tox_damage = 0
/datum/reagent/inverse/antihol/on_mob_life(mob/living/carbon/C, delta_time, times_fired)
/datum/reagent/inverse/antihol/on_mob_life(mob/living/carbon/C, seconds_per_tick, times_fired)
for(var/datum/reagent/consumable/ethanol/alcohol in C.reagents.reagent_list)
alcohol.boozepwr += delta_time
alcohol.boozepwr += seconds_per_tick
..()
/datum/reagent/inverse/oculine
@@ -775,10 +775,10 @@ Basically, we fill the time between now and 2s from now with hands based off the
///Did we get a headache?
var/headache = FALSE
/datum/reagent/inverse/oculine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/inverse/oculine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(headache)
return ..()
if(DT_PROB(100 * creation_purity, delta_time))
if(SPT_PROB(100 * creation_purity, seconds_per_tick))
affected_mob.become_blind(IMPURE_OCULINE)
to_chat(affected_mob, span_danger("You suddenly develop a pounding headache as your vision fluxuates."))
headache = TRUE
@@ -803,7 +803,7 @@ Basically, we fill the time between now and 2s from now with hands based off the
///The random span we start hearing in
var/randomSpan
/datum/reagent/impurity/inacusiate/on_mob_metabolize(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/impurity/inacusiate/on_mob_metabolize(mob/living/affected_mob, seconds_per_tick, times_fired)
randomSpan = pick(list("clown", "small", "big", "hypnophrase", "alien", "cult", "alert", "danger", "emote", "yell", "brass", "sans", "papyrus", "robot", "his_grace", "phobia"))
RegisterSignal(affected_mob, COMSIG_MOVABLE_HEAR, PROC_REF(owner_hear))
to_chat(affected_mob, span_warning("Your hearing seems to be a bit off!"))

View File

@@ -28,9 +28,9 @@
ph = 7
liver_damage = 0
/datum/reagent/impurity/methanol/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/impurity/methanol/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/obj/item/organ/internal/eyes/eyes = affected_mob.get_organ_slot(ORGAN_SLOT_EYES)
eyes?.apply_organ_damage(0.5 * REM * delta_time, required_organtype = affected_organtype)
eyes?.apply_organ_damage(0.5 * REM * seconds_per_tick, required_organtype = affected_organtype)
return ..()
//Chloral Hydrate - Impure Version
@@ -42,8 +42,8 @@
ph = 7
liver_damage = 0
/datum/reagent/impurity/chloralax/on_mob_life(mob/living/carbon/owner, delta_time)
owner.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/impurity/chloralax/on_mob_life(mob/living/carbon/owner, seconds_per_tick)
owner.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
@@ -57,13 +57,13 @@
liver_damage = 0
metabolization_rate = 0.5 * REAGENTS_METABOLISM
/datum/reagent/impurity/rosenol/on_mob_life(mob/living/carbon/owner, delta_time)
/datum/reagent/impurity/rosenol/on_mob_life(mob/living/carbon/owner, seconds_per_tick)
var/obj/item/organ/internal/tongue/tongue = owner.get_organ_slot(ORGAN_SLOT_TONGUE)
if(!tongue)
return ..()
if(DT_PROB(4.0, delta_time))
if(SPT_PROB(4.0, seconds_per_tick))
owner.manual_emote("clicks with [owner.p_their()] tongue.")
owner.say("Noice.", forced = /datum/reagent/impurity/rosenol)
if(DT_PROB(2.0, delta_time))
if(SPT_PROB(2.0, seconds_per_tick))
owner.say(pick("Ah! That was a mistake!", "Horrible.", "Watch out everybody, the potato is really hot.", "When I was six I ate a bag of plums.", "And if there is one thing I can't stand it's tomatoes.", "And if there is one thing I love it's tomatoes.", "We had a captain who was so strict, you weren't allowed to breathe in their station.", "The unrobust ones just used to keel over and die, you'd hear them going down behind you."), forced = /datum/reagent/impurity/rosenol)
..()

File diff suppressed because it is too large Load Diff

View File

@@ -279,10 +279,10 @@
#undef WATER_TO_WET_STACKS_FACTOR_VAPOR
/datum/reagent/water/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/water/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
if(affected_mob.blood_volume)
affected_mob.blood_volume += 0.1 * REM * delta_time // water is good for you!
affected_mob.blood_volume += 0.1 * REM * seconds_per_tick // water is good for you!
///For weird backwards situations where water manages to get added to trays nutrients, as opposed to being snowflaked away like usual.
/datum/reagent/water/on_hydroponics_apply(obj/item/seeds/myseed, datum/reagents/chems, obj/machinery/hydroponics/mytray)
@@ -335,23 +335,23 @@
if(IS_CULTIST(exposed_mob))
to_chat(exposed_mob, span_userdanger("A vile holiness begins to spread its shining tendrils through your mind, purging the Geometer of Blood's influence!"))
/datum/reagent/water/holywater/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/water/holywater/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.blood_volume)
affected_mob.blood_volume += 0.1 * REM * delta_time // water is good for you!
affected_mob.blood_volume += 0.1 * REM * seconds_per_tick // water is good for you!
if(!data)
data = list("misc" = 0)
data["misc"] += delta_time SECONDS * REM
affected_mob.adjust_jitter_up_to(4 SECONDS * delta_time, 20 SECONDS)
data["misc"] += seconds_per_tick SECONDS * REM
affected_mob.adjust_jitter_up_to(4 SECONDS * seconds_per_tick, 20 SECONDS)
if(IS_CULTIST(affected_mob))
for(var/datum/action/innate/cult/blood_magic/BM in affected_mob.actions)
to_chat(affected_mob, span_cultlarge("Your blood rites falter as holy water scours your body!"))
for(var/datum/action/innate/cult/blood_spell/BS in BM.spells)
qdel(BS)
if(data["misc"] >= (25 SECONDS)) // 10 units
affected_mob.adjust_stutter_up_to(4 SECONDS * delta_time, 20 SECONDS)
affected_mob.adjust_stutter_up_to(4 SECONDS * seconds_per_tick, 20 SECONDS)
affected_mob.set_dizzy_if_lower(10 SECONDS)
if(IS_CULTIST(affected_mob) && DT_PROB(10, delta_time))
if(IS_CULTIST(affected_mob) && SPT_PROB(10, seconds_per_tick))
affected_mob.say(pick("Av'te Nar'Sie","Pa'lid Mors","INO INO ORA ANA","SAT ANA!","Daim'niodeis Arc'iai Le'eones","R'ge Na'sie","Diabo us Vo'iscum","Eld' Mon Nobis"), forced = "holy water")
if(prob(10))
affected_mob.visible_message(span_danger("[affected_mob] starts having a seizure!"), span_userdanger("You have a seizure!"))
@@ -366,7 +366,7 @@
affected_mob.remove_status_effect(/datum/status_effect/speech/stutter)
holder.remove_reagent(type, volume) // maybe this is a little too perfect and a max() cap on the statuses would be better??
return
holder.remove_reagent(type, 1 * REAGENTS_METABOLISM * delta_time) //fixed consumption to prevent balancing going out of whack
holder.remove_reagent(type, 1 * REAGENTS_METABOLISM * seconds_per_tick) //fixed consumption to prevent balancing going out of whack
/datum/reagent/water/holywater/expose_turf(turf/exposed_turf, reac_volume)
. = ..()
@@ -431,23 +431,23 @@
ph = 6.5
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/fuel/unholywater/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/fuel/unholywater/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(IS_CULTIST(affected_mob))
affected_mob.adjust_drowsiness(-10 SECONDS * REM * delta_time)
affected_mob.AdjustAllImmobility(-40 * REM * delta_time)
affected_mob.adjustStaminaLoss(-10 * REM * delta_time, 0)
affected_mob.adjustToxLoss(-2 * REM * delta_time, 0)
affected_mob.adjustOxyLoss(-2 * REM * delta_time, 0)
affected_mob.adjustBruteLoss(-2 * REM * delta_time, 0)
affected_mob.adjustFireLoss(-2 * REM * delta_time, 0)
affected_mob.adjust_drowsiness(-10 SECONDS * REM * seconds_per_tick)
affected_mob.AdjustAllImmobility(-40 * REM * seconds_per_tick)
affected_mob.adjustStaminaLoss(-10 * REM * seconds_per_tick, 0)
affected_mob.adjustToxLoss(-2 * REM * seconds_per_tick, 0)
affected_mob.adjustOxyLoss(-2 * REM * seconds_per_tick, 0)
affected_mob.adjustBruteLoss(-2 * REM * seconds_per_tick, 0)
affected_mob.adjustFireLoss(-2 * REM * seconds_per_tick, 0)
if(ishuman(affected_mob) && affected_mob.blood_volume < BLOOD_VOLUME_NORMAL)
affected_mob.blood_volume += 3 * REM * delta_time
affected_mob.blood_volume += 3 * REM * seconds_per_tick
else // Will deal about 90 damage when 50 units are thrown
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * delta_time, 150)
affected_mob.adjustToxLoss(1 * REM * delta_time, 0)
affected_mob.adjustFireLoss(1 * REM * delta_time, 0)
affected_mob.adjustOxyLoss(1 * REM * delta_time, 0)
affected_mob.adjustBruteLoss(1 * REM * delta_time, 0)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * seconds_per_tick, 150)
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, 0)
affected_mob.adjustFireLoss(1 * REM * seconds_per_tick, 0)
affected_mob.adjustOxyLoss(1 * REM * seconds_per_tick, 0)
affected_mob.adjustBruteLoss(1 * REM * seconds_per_tick, 0)
..()
/datum/reagent/hellwater //if someone has this in their system they've really pissed off an eldrich god
@@ -457,13 +457,13 @@
ph = 0.1
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/hellwater/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.set_fire_stacks(min(affected_mob.fire_stacks + (1.5 * delta_time), 5))
/datum/reagent/hellwater/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_fire_stacks(min(affected_mob.fire_stacks + (1.5 * seconds_per_tick), 5))
affected_mob.ignite_mob() //Only problem with igniting people is currently the commonly available fire suits make you immune to being on fire
affected_mob.adjustToxLoss(0.5*delta_time, 0)
affected_mob.adjustFireLoss(0.5*delta_time, 0) //Hence the other damages... ain't I a bastard?
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2.5*delta_time, 150)
holder.remove_reagent(type, 0.5*delta_time)
affected_mob.adjustToxLoss(0.5*seconds_per_tick, 0)
affected_mob.adjustFireLoss(0.5*seconds_per_tick, 0) //Hence the other damages... ain't I a bastard?
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2.5*seconds_per_tick, 150)
holder.remove_reagent(type, 0.5*seconds_per_tick)
/datum/reagent/medicine/omnizine/godblood
name = "Godblood"
@@ -568,7 +568,7 @@
to_chat(exposed_mob, span_notice("That tasted horrible."))
/datum/reagent/spraytan/overdose_process(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/spraytan/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
metabolization_rate = 1 * REAGENTS_METABOLISM
if(ishuman(affected_mob))
@@ -585,12 +585,12 @@
else if(MUTCOLORS in affected_human.dna.species.species_traits) //Aliens with custom colors simply get turned orange
affected_human.dna.features["mcolor"] = "#ff8800"
affected_human.update_body(is_creating = TRUE)
if(DT_PROB(3.5, delta_time))
if(SPT_PROB(3.5, seconds_per_tick))
if(affected_human.w_uniform)
affected_mob.visible_message(pick("<b>[affected_mob]</b>'s collar pops up without warning.</span>", "<b>[affected_mob]</b> flexes [affected_mob.p_their()] arms."))
else
affected_mob.visible_message("<b>[affected_mob]</b> flexes [affected_mob.p_their()] arms.")
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
affected_mob.say(pick("Shit was SO cash.", "You are everything bad in the world.", "What sports do you play, other than 'jack off to naked drawn Japanese people?'", "Don???t be a stranger. Just hit me with your best shot.", "My name is John and I hate every single one of you."), forced = /datum/reagent/spraytan)
..()
return
@@ -613,14 +613,14 @@
"You feel as though you're about to change at any moment!" = MUT_MSG_ABOUT2TURN)
var/cycles_to_turn = 20 //the current_cycle threshold / iterations needed before one can transform
/datum/reagent/mutationtoxin/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/mutationtoxin/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
. = TRUE
if(!istype(affected_mob))
return
if(!(affected_mob.dna?.species) || !(affected_mob.mob_biotypes & MOB_ORGANIC))
return
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
var/list/pick_ur_fav = list()
var/filter = NONE
if(current_cycle <= (cycles_to_turn*0.3))
@@ -698,7 +698,7 @@
taste_description = "grandma's gelatin"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/mutationtoxin/jelly/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/mutationtoxin/jelly/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
if(isjellyperson(affected_mob))
to_chat(affected_mob, span_warning("Your jelly shifts and morphs, turning you into another subspecies!"))
var/species_type = pick(subtypesof(/datum/species/jelly))
@@ -803,7 +803,7 @@
taste_description = "slime"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/mulligan/on_mob_life(mob/living/carbon/human/affected_mob, delta_time, times_fired)
/datum/reagent/mulligan/on_mob_life(mob/living/carbon/human/affected_mob, seconds_per_tick, times_fired)
..()
if (!istype(affected_mob))
return
@@ -845,9 +845,9 @@
ph = 10
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/serotrotium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/serotrotium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(ishuman(affected_mob))
if(DT_PROB(3.5, delta_time))
if(SPT_PROB(3.5, seconds_per_tick))
affected_mob.emote(pick("twitch","drool","moan","gasp"))
..()
@@ -925,12 +925,12 @@
taste_mult = 0 // apparently tasteless.
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/mercury/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/mercury/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!HAS_TRAIT(src, TRAIT_IMMOBILIZED) && !isspaceturf(affected_mob.loc))
step(affected_mob, pick(GLOB.cardinals))
if(DT_PROB(3.5, delta_time))
if(SPT_PROB(3.5, seconds_per_tick))
affected_mob.emote(pick("twitch","drool","moan"))
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.5*delta_time)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 0.5*seconds_per_tick)
..()
/datum/reagent/sulfur
@@ -982,8 +982,8 @@
// White Phosphorous + water -> phosphoric acid. That's not a good thing really.
/datum/reagent/chlorine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.take_bodypart_damage(0.5*REM*delta_time, 0)
/datum/reagent/chlorine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.take_bodypart_damage(0.5*REM*seconds_per_tick, 0)
. = TRUE
..()
@@ -1006,8 +1006,8 @@
mytray.adjust_waterlevel(-round(chems.get_reagent_amount(type) * 0.5))
mytray.adjust_weedlevel(-rand(1,4))
/datum/reagent/fluorine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(0.5*REM*delta_time, 0)
/datum/reagent/fluorine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(0.5*REM*seconds_per_tick, 0)
. = TRUE
..()
@@ -1047,10 +1047,10 @@
ph = 11.3
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/lithium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/lithium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!HAS_TRAIT(affected_mob, TRAIT_IMMOBILIZED) && !isspaceturf(affected_mob.loc) && isturf(affected_mob.loc))
step(affected_mob, pick(GLOB.cardinals))
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
affected_mob.emote(pick("twitch","drool","moan"))
..()
@@ -1088,9 +1088,9 @@
color = "#606060" //pure iron? let's make it violet of course
ph = 6
/datum/reagent/iron/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/iron/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.blood_volume < BLOOD_VOLUME_NORMAL)
affected_mob.blood_volume += 0.25 * delta_time
affected_mob.blood_volume += 0.25 * seconds_per_tick
..()
/datum/reagent/gold
@@ -1124,8 +1124,8 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
default_container = /obj/effect/decal/cleanable/greenglow
/datum/reagent/uranium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(tox_damage * delta_time * REM)
/datum/reagent/uranium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(tox_damage * seconds_per_tick * REM)
..()
/datum/reagent/uranium/expose_turf(turf/exposed_turf, reac_volume)
@@ -1184,8 +1184,8 @@
if(methods & (TOUCH|VAPOR))
do_teleport(exposed_mob, get_turf(exposed_mob), (reac_volume / 5), asoundin = 'sound/effects/phasein.ogg', channel = TELEPORT_CHANNEL_BLUESPACE) //4 tiles per crystal
/datum/reagent/bluespace/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(current_cycle > 10 && DT_PROB(7.5, delta_time))
/datum/reagent/bluespace/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle > 10 && SPT_PROB(7.5, seconds_per_tick))
to_chat(affected_mob, span_warning("You feel unstable..."))
affected_mob.set_jitter_if_lower(2 SECONDS)
current_cycle = 1
@@ -1236,8 +1236,8 @@
if(methods & (TOUCH|VAPOR))
exposed_mob.adjust_fire_stacks(reac_volume / 10)
/datum/reagent/fuel/on_mob_life(mob/living/carbon/victim, delta_time, times_fired)
victim.adjustToxLoss(0.5 * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/fuel/on_mob_life(mob/living/carbon/victim, seconds_per_tick, times_fired)
victim.adjustToxLoss(0.5 * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
return TRUE
@@ -1296,10 +1296,10 @@
ph = 2
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/space_cleaner/ez_clean/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustBruteLoss(1.665*delta_time)
affected_mob.adjustFireLoss(1.665*delta_time)
affected_mob.adjustToxLoss(1.665*delta_time)
/datum/reagent/space_cleaner/ez_clean/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustBruteLoss(1.665*seconds_per_tick)
affected_mob.adjustFireLoss(1.665*seconds_per_tick)
affected_mob.adjustToxLoss(1.665*seconds_per_tick)
..()
/datum/reagent/space_cleaner/ez_clean/expose_mob(mob/living/exposed_mob, methods=TOUCH, reac_volume)
@@ -1317,7 +1317,7 @@
ph = 11.9
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/cryptobiolin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/cryptobiolin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.set_dizzy_if_lower(2 SECONDS)
// Cryptobiolin adjusts the mob's confusion down to 20 seconds if it's higher,
@@ -1340,13 +1340,13 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/opioids = 10)
/datum/reagent/impedrezene/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_jitter(-5 SECONDS * delta_time)
if(DT_PROB(55, delta_time))
/datum/reagent/impedrezene/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_jitter(-5 SECONDS * seconds_per_tick)
if(SPT_PROB(55, seconds_per_tick))
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 2)
if(DT_PROB(30, delta_time))
if(SPT_PROB(30, seconds_per_tick))
affected_mob.adjust_drowsiness(6 SECONDS)
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
affected_mob.emote("drool")
..()
@@ -1501,12 +1501,12 @@
var/drowsiness_to_apply = max(round(reac_volume, 1) * 2 SECONDS, 4 SECONDS)
exposed_mob.adjust_drowsiness(drowsiness_to_apply)
/datum/reagent/nitrous_oxide/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_drowsiness(4 SECONDS * REM * delta_time)
/datum/reagent/nitrous_oxide/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_drowsiness(4 SECONDS * REM * seconds_per_tick)
if(ishuman(affected_mob))
var/mob/living/carbon/human/affected_human = affected_mob
affected_human.blood_volume = max(affected_human.blood_volume - (10 * REM * delta_time), 0)
if(DT_PROB(10, delta_time))
affected_human.blood_volume = max(affected_human.blood_volume - (10 * REM * seconds_per_tick), 0)
if(SPT_PROB(10, seconds_per_tick))
affected_mob.losebreath += 2
affected_mob.adjust_confusion_up_to(2 SECONDS, 5 SECONDS)
..()
@@ -1652,8 +1652,8 @@
taste_description = "plant food"
ph = 3
/datum/reagent/plantnutriment/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(tox_prob, delta_time))
/datum/reagent/plantnutriment/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(tox_prob, seconds_per_tick))
affected_mob.adjustToxLoss(1, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -1761,8 +1761,8 @@
ph = 1.5
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/stable_plasma/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustPlasma(10 * REM * delta_time)
/datum/reagent/stable_plasma/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustPlasma(10 * REM * seconds_per_tick)
..()
/datum/reagent/iodine
@@ -1848,20 +1848,20 @@
name = "Royal Carpet?"
description = "For those that break the game and need to make an issue report."
/datum/reagent/carpet/royal/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/carpet/royal/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
var/obj/item/organ/internal/liver/liver = affected_mob.get_organ_slot(ORGAN_SLOT_LIVER)
if(liver)
// Heads of staff and the captain have a "royal metabolism"
if(HAS_TRAIT(liver, TRAIT_ROYAL_METABOLISM))
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
to_chat(affected_mob, "You feel like royalty.")
if(DT_PROB(2.5, delta_time))
if(SPT_PROB(2.5, seconds_per_tick))
affected_mob.say(pick("Peasants..","This carpet is worth more than your contracts!","I could fire you at any time..."), forced = "royal carpet")
// The quartermaster, as a semi-head, has a "pretender royal" metabolism
else if(HAS_TRAIT(liver, TRAIT_PRETENDER_ROYAL_METABOLISM))
if(DT_PROB(8, delta_time))
if(SPT_PROB(8, seconds_per_tick))
to_chat(affected_mob, "You feel like an impostor...")
/datum/reagent/carpet/royal/black
@@ -2095,7 +2095,7 @@
color_callback = null
color = pick(random_color_list)
/datum/reagent/colorful_reagent/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/colorful_reagent/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(can_colour_mobs)
affected_mob.add_atom_colour(pick(random_color_list), WASHABLE_COLOUR_PRIORITY)
return ..()
@@ -2175,7 +2175,7 @@
exposed_human.facial_hairstyle = "Beard (Very Long)"
exposed_human.update_body_parts()
/datum/reagent/concentrated_barbers_aid/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/concentrated_barbers_aid/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
if(current_cycle > 20 / creation_purity)
if(!ishuman(affected_mob))
@@ -2332,8 +2332,8 @@
ph = 3
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/royal_bee_jelly/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(1, delta_time))
/datum/reagent/royal_bee_jelly/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(1, seconds_per_tick))
affected_mob.say(pick("Bzzz...","BZZ BZZ","Bzzzzzzzzzzz..."), forced = "royal bee jelly")
..()
@@ -2366,7 +2366,7 @@
color = "#00f041"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/magillitis/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/magillitis/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
..()
if((ishuman(affected_mob)) && current_cycle >= 10)
affected_mob.gorillize()
@@ -2379,7 +2379,7 @@
taste_description = "bitterness" // apparently what viagra tastes like
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/growthserum/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/growthserum/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/newsize = current_size
switch(volume)
if(0 to 19)
@@ -2487,11 +2487,11 @@
..()
REMOVE_TRAIT(ling, CHANGELING_HIVEMIND_MUTE, type)
/datum/reagent/bz_metabolites/on_mob_life(mob/living/carbon/target, delta_time, times_fired)
/datum/reagent/bz_metabolites/on_mob_life(mob/living/carbon/target, seconds_per_tick, times_fired)
if(target.mind)
var/datum/antagonist/changeling/changeling = target.mind.has_antag_datum(/datum/antagonist/changeling)
if(changeling)
changeling.adjust_chemicals(-4 * REM * delta_time) //SKYRAT EDIT - BZ-BUFF-VS-LING - ORIGINAL: changeling.adjust_chemicals(-2 * REM * delta_time)
changeling.adjust_chemicals(-4 * REM * seconds_per_tick) //SKYRAT EDIT - BZ-BUFF-VS-LING - ORIGINAL: changeling.adjust_chemicals(-2 * REM * delta_time)
return ..()
/datum/reagent/pax/peaceborg
@@ -2507,11 +2507,11 @@
taste_description = "dizziness"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/peaceborg/confuse/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_confusion_up_to(3 SECONDS * REM * delta_time, 5 SECONDS)
affected_mob.adjust_dizzy_up_to(6 SECONDS * REM * delta_time, 12 SECONDS)
/datum/reagent/peaceborg/confuse/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_confusion_up_to(3 SECONDS * REM * seconds_per_tick, 5 SECONDS)
affected_mob.adjust_dizzy_up_to(6 SECONDS * REM * seconds_per_tick, 12 SECONDS)
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
to_chat(affected_mob, "You feel confused and disoriented.")
..()
@@ -2522,11 +2522,11 @@
taste_description = "tiredness"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/peaceborg/tire/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/peaceborg/tire/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/healthcomp = (100 - affected_mob.health) //DOES NOT ACCOUNT FOR ADMINBUS THINGS THAT MAKE YOU HAVE MORE THAN 200/210 HEALTH, OR SOMETHING OTHER THAN A HUMAN PROCESSING THIS.
if(affected_mob.getStaminaLoss() < (45 - healthcomp)) //At 50 health you would have 200 - 150 health meaning 50 compensation. 60 - 50 = 10, so would only do 10-19 stamina.)
affected_mob.adjustStaminaLoss(10 * REM * delta_time)
if(DT_PROB(16, delta_time))
affected_mob.adjustStaminaLoss(10 * REM * seconds_per_tick)
if(SPT_PROB(16, seconds_per_tick))
to_chat(affected_mob, "You should sit down and take a rest...")
..()
@@ -2572,9 +2572,9 @@
#define YUCK_PUKE_CYCLES 3 // every X cycle is a puke
#define YUCK_PUKES_TO_STUN 3 // hit this amount of pukes in a row to start stunning
/datum/reagent/yuck/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/yuck/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!yuck_cycle)
if(DT_PROB(4, delta_time))
if(SPT_PROB(4, seconds_per_tick))
var/dread = pick("Something is moving in your stomach...", \
"A wet growl echoes from your stomach...", \
"For a moment you feel like your surroundings are moving, but it's your stomach...")
@@ -2725,7 +2725,7 @@
affected_mob.remove_status_effect(/datum/status_effect/determined)
..()
/datum/reagent/determination/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/determination/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(!significant && volume >= WOUND_DETERMINATION_SEVERE)
significant = TRUE
affected_mob.apply_status_effect(/datum/status_effect/determined) // in addition to the slight healing, limping cooldowns are divided by 4 during the combat high
@@ -2736,8 +2736,8 @@
var/datum/wound/W = thing
var/obj/item/bodypart/wounded_part = W.limb
if(wounded_part)
wounded_part.heal_damage(0.25 * REM * delta_time, 0.25 * REM * delta_time)
affected_mob.adjustStaminaLoss(-0.25 * REM * delta_time) // the more wounds, the more stamina regen
wounded_part.heal_damage(0.25 * REM * seconds_per_tick, 0.25 * REM * seconds_per_tick)
affected_mob.adjustStaminaLoss(-0.25 * REM * seconds_per_tick) // the more wounds, the more stamina regen
..()
// unholy water, but for heretics.
@@ -2754,23 +2754,23 @@
metabolization_rate = 2.5 * REAGENTS_METABOLISM //0.5u/second
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/eldritch/on_mob_life(mob/living/carbon/drinker, delta_time, times_fired)
/datum/reagent/eldritch/on_mob_life(mob/living/carbon/drinker, seconds_per_tick, times_fired)
if(IS_HERETIC(drinker))
drinker.adjust_drowsiness(-10 * REM * delta_time)
drinker.AdjustAllImmobility(-40 * REM * delta_time)
drinker.adjustStaminaLoss(-10 * REM * delta_time, FALSE)
drinker.adjustToxLoss(-2 * REM * delta_time, FALSE, forced = TRUE)
drinker.adjustOxyLoss(-2 * REM * delta_time, FALSE)
drinker.adjustBruteLoss(-2 * REM * delta_time, FALSE)
drinker.adjustFireLoss(-2 * REM * delta_time, FALSE)
drinker.adjust_drowsiness(-10 * REM * seconds_per_tick)
drinker.AdjustAllImmobility(-40 * REM * seconds_per_tick)
drinker.adjustStaminaLoss(-10 * REM * seconds_per_tick, FALSE)
drinker.adjustToxLoss(-2 * REM * seconds_per_tick, FALSE, forced = TRUE)
drinker.adjustOxyLoss(-2 * REM * seconds_per_tick, FALSE)
drinker.adjustBruteLoss(-2 * REM * seconds_per_tick, FALSE)
drinker.adjustFireLoss(-2 * REM * seconds_per_tick, FALSE)
if(drinker.blood_volume < BLOOD_VOLUME_NORMAL)
drinker.blood_volume += 3 * REM * delta_time
drinker.blood_volume += 3 * REM * seconds_per_tick
else
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * delta_time, 150)
drinker.adjustToxLoss(2 * REM * delta_time, FALSE)
drinker.adjustFireLoss(2 * REM * delta_time, FALSE)
drinker.adjustOxyLoss(2 * REM * delta_time, FALSE)
drinker.adjustBruteLoss(2 * REM * delta_time, FALSE)
drinker.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * seconds_per_tick, 150)
drinker.adjustToxLoss(2 * REM * seconds_per_tick, FALSE)
drinker.adjustFireLoss(2 * REM * seconds_per_tick, FALSE)
drinker.adjustOxyLoss(2 * REM * seconds_per_tick, FALSE)
drinker.adjustBruteLoss(2 * REM * seconds_per_tick, FALSE)
..()
return TRUE
@@ -2817,19 +2817,19 @@
name = "glass of ants"
desc = "Bottoms up...?"
/datum/reagent/ants/on_mob_life(mob/living/carbon/victim, delta_time)
/datum/reagent/ants/on_mob_life(mob/living/carbon/victim, seconds_per_tick)
victim.adjustBruteLoss(max(0.1, round((ant_damage * 0.025),0.1))) //Scales with time. Roughly 32 brute with 100u.
ant_damage++
if(ant_damage < 5) // Makes ant food a little more appetizing, since you won't be screaming as much.
return ..()
if(DT_PROB(5, delta_time))
if(DT_PROB(5, delta_time)) //Super rare statement
if(SPT_PROB(5, seconds_per_tick))
if(SPT_PROB(5, seconds_per_tick)) //Super rare statement
victim.say("AUGH NO NOT THE ANTS! NOT THE ANTS! AAAAUUGH THEY'RE IN MY EYES! MY EYES! AUUGH!!", forced = /datum/reagent/ants)
else
victim.say(pick(ant_screams), forced = /datum/reagent/ants)
if(DT_PROB(15, delta_time))
if(SPT_PROB(15, seconds_per_tick))
victim.emote("scream")
if(DT_PROB(2, delta_time)) // Stuns, but purges ants.
if(SPT_PROB(2, seconds_per_tick)) // Stuns, but purges ants.
victim.vomit(rand(5,10), FALSE, TRUE, 1, TRUE, FALSE, purge_ratio = 1)
return ..()
@@ -2905,9 +2905,9 @@
taste_description = "burning"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/brimdust/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/brimdust/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
affected_mob.adjustFireLoss((ispodperson(affected_mob) ? -1 : 1) * delta_time)
affected_mob.adjustFireLoss((ispodperson(affected_mob) ? -1 : 1) * seconds_per_tick)
/datum/reagent/brimdust/on_hydroponics_apply(obj/item/seeds/myseed, datum/reagents/chems, obj/machinery/hydroponics/mytray, mob/user)
if(!check_tray(chems, mytray))
@@ -2945,11 +2945,11 @@
deleted_from.clear_mood_event(name)
deleted_from.add_mood_event(name, /datum/mood_event/love_reagent, duration_of_moodlet)
/datum/reagent/love/overdose_process(mob/living/metabolizer, delta_time, times_fired)
/datum/reagent/love/overdose_process(mob/living/metabolizer, seconds_per_tick, times_fired)
var/mob/living/carbon/carbon_metabolizer = metabolizer
if(!istype(carbon_metabolizer) || !carbon_metabolizer.can_heartattack() || carbon_metabolizer.undergoing_cardiac_arrest())
metabolizer.reagents.del_reagent(type)
return
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
carbon_metabolizer.set_heartattack(TRUE)

View File

@@ -12,8 +12,8 @@
if(reac_volume >= 1)
exposed_turf.AddComponent(/datum/component/thermite, reac_volume)
/datum/reagent/thermite/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustFireLoss(1 * REM * delta_time, 0)
/datum/reagent/thermite/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustFireLoss(1 * REM * seconds_per_tick, 0)
..()
return TRUE
@@ -49,9 +49,9 @@
penetrates_skin = NONE
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/clf3/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_fire_stacks(2 * REM * delta_time)
affected_mob.adjustFireLoss(0.3 * max(affected_mob.fire_stacks, 1) * REM * delta_time, 0)
/datum/reagent/clf3/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_fire_stacks(2 * REM * seconds_per_tick)
affected_mob.adjustFireLoss(0.3 * max(affected_mob.fire_stacks, 1) * REM * seconds_per_tick, 0)
..()
return TRUE
@@ -179,9 +179,9 @@
exposed_mob.adjustFireLoss(burndmg, 0)
exposed_mob.ignite_mob()
/datum/reagent/phlogiston/on_mob_life(mob/living/carbon/metabolizer, delta_time, times_fired)
metabolizer.adjust_fire_stacks(1 * REM * delta_time)
metabolizer.adjustFireLoss(0.3 * max(metabolizer.fire_stacks, 0.15) * REM * delta_time, 0)
/datum/reagent/phlogiston/on_mob_life(mob/living/carbon/metabolizer, seconds_per_tick, times_fired)
metabolizer.adjust_fire_stacks(1 * REM * seconds_per_tick)
metabolizer.adjustFireLoss(0.3 * max(metabolizer.fire_stacks, 0.15) * REM * seconds_per_tick, 0)
..()
return TRUE
@@ -206,8 +206,8 @@
mytray.adjust_weedlevel(-rand(5,9)) //At least give them a small reward if they bother.
/datum/reagent/napalm/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_fire_stacks(1 * REM * delta_time)
/datum/reagent/napalm/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_fire_stacks(1 * REM * seconds_per_tick)
..()
/datum/reagent/napalm/expose_mob(mob/living/exposed_mob, methods=TOUCH, reac_volume)
@@ -249,18 +249,18 @@
affected_mob.color = COLOR_WHITE
//Pauses decay! Does do something, I promise.
/datum/reagent/cryostylane/on_mob_dead(mob/living/carbon/affected_mob, delta_time)
/datum/reagent/cryostylane/on_mob_dead(mob/living/carbon/affected_mob, seconds_per_tick)
. = ..()
metabolization_rate = 0.05 * REM //slower consumption when dead
/datum/reagent/cryostylane/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/cryostylane/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
metabolization_rate = 0.25 * REM//faster consumption when alive
if(affected_mob.reagents.has_reagent(/datum/reagent/oxygen))
affected_mob.reagents.remove_reagent(/datum/reagent/oxygen, 0.5 * REM * delta_time)
affected_mob.adjust_bodytemperature(-15 * REM * delta_time)
affected_mob.reagents.remove_reagent(/datum/reagent/oxygen, 0.5 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-15 * REM * seconds_per_tick)
if(ishuman(affected_mob))
var/mob/living/carbon/human/humi = affected_mob
humi.adjust_coretemperature(-15 * REM * delta_time)
humi.adjust_coretemperature(-15 * REM * seconds_per_tick)
..()
/datum/reagent/cryostylane/expose_turf(turf/exposed_turf, reac_volume)
@@ -284,13 +284,13 @@
burning_volume = 0.05
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/pyrosium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/pyrosium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(holder.has_reagent(/datum/reagent/oxygen))
holder.remove_reagent(/datum/reagent/oxygen, 0.5 * REM * delta_time)
affected_mob.adjust_bodytemperature(15 * REM * delta_time)
holder.remove_reagent(/datum/reagent/oxygen, 0.5 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(15 * REM * seconds_per_tick)
if(ishuman(affected_mob))
var/mob/living/carbon/human/humi = affected_mob
humi.adjust_coretemperature(15 * REM * delta_time)
humi.adjust_coretemperature(15 * REM * seconds_per_tick)
..()
/datum/reagent/pyrosium/burn(datum/reagents/holder)
@@ -310,7 +310,7 @@
var/shock_timer = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/teslium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/teslium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
shock_timer++
if(shock_timer >= rand(5, 30)) //Random shocks are wildly unpredictable
shock_timer = 0
@@ -338,15 +338,15 @@
taste_description = "jelly"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/teslium/energized_jelly/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/teslium/energized_jelly/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(isjellyperson(affected_mob))
shock_timer = 0 //immune to shocks
affected_mob.AdjustAllImmobility(-40 *REM * delta_time)
affected_mob.adjustStaminaLoss(-2 * REM * delta_time, 0)
affected_mob.AdjustAllImmobility(-40 *REM * seconds_per_tick)
affected_mob.adjustStaminaLoss(-2 * REM * seconds_per_tick, 0)
if(is_species(affected_mob, /datum/species/jelly/luminescent))
var/mob/living/carbon/human/affected_human = affected_mob
var/datum/species/jelly/luminescent/slime_species = affected_human.dna.species
slime_species.extract_cooldown = max(slime_species.extract_cooldown - (2 SECONDS * REM * delta_time), 0)
slime_species.extract_cooldown = max(slime_species.extract_cooldown - (2 SECONDS * REM * seconds_per_tick), 0)
..()
/datum/reagent/firefighting_foam

View File

@@ -23,9 +23,9 @@
mytray.adjust_toxic(round(chems.get_reagent_amount(type) * 2))
/datum/reagent/toxin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(toxpwr && affected_mob.health > health_required)
affected_mob.adjustToxLoss(toxpwr * REM * normalise_creation_purity() * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(toxpwr * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -64,8 +64,8 @@
exposed_mob.updateappearance()
exposed_mob.domutcheck()
/datum/reagent/toxin/mutagen/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustToxLoss(0.5 * delta_time * REM, required_biotype = affected_biotype)
/datum/reagent/toxin/mutagen/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustToxLoss(0.5 * seconds_per_tick * REM, required_biotype = affected_biotype)
return ..()
/datum/reagent/toxin/mutagen/on_hydroponics_apply(obj/item/seeds/myseed, datum/reagents/chems, obj/machinery/hydroponics/mytray, mob/user)
@@ -102,10 +102,10 @@
UnregisterSignal(holder, COMSIG_REAGENTS_TEMP_CHANGE)
return ..()
/datum/reagent/toxin/plasma/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/plasma/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(holder.has_reagent(/datum/reagent/medicine/epinephrine))
holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2 * REM * delta_time)
affected_mob.adjustPlasma(20 * REM * delta_time)
holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2 * REM * seconds_per_tick)
affected_mob.adjustPlasma(20 * REM * seconds_per_tick)
return ..()
/datum/reagent/toxin/plasma/on_mob_metabolize(mob/living/carbon/affected_mob)
@@ -156,14 +156,14 @@
material = /datum/material/hot_ice
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/hot_ice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/hot_ice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(holder.has_reagent(/datum/reagent/medicine/epinephrine))
holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2 * REM * delta_time)
affected_mob.adjustPlasma(20 * REM * delta_time)
affected_mob.adjust_bodytemperature(-7 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * delta_time, affected_mob.get_body_temp_normal())
holder.remove_reagent(/datum/reagent/medicine/epinephrine, 2 * REM * seconds_per_tick)
affected_mob.adjustPlasma(20 * REM * seconds_per_tick)
affected_mob.adjust_bodytemperature(-7 * TEMPERATURE_DAMAGE_COEFFICIENT * REM * seconds_per_tick, affected_mob.get_body_temp_normal())
if(ishuman(affected_mob))
var/mob/living/carbon/human/humi = affected_mob
humi.adjust_coretemperature(-7 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * delta_time, affected_mob.get_body_temp_normal())
humi.adjust_coretemperature(-7 * REM * TEMPERATURE_DAMAGE_COEFFICIENT * seconds_per_tick, affected_mob.get_body_temp_normal())
return ..()
/datum/reagent/toxin/hot_ice/on_mob_metabolize(mob/living/carbon/affected_mob)
@@ -184,16 +184,16 @@
ph = 1.2
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/lexorin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/lexorin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = TRUE
if(HAS_TRAIT(affected_mob, TRAIT_NOBREATH))
. = FALSE
if(.)
affected_mob.adjustOxyLoss(5 * REM * normalise_creation_purity() * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.losebreath += 2 * REM * normalise_creation_purity() * delta_time
if(DT_PROB(10, delta_time))
affected_mob.adjustOxyLoss(5 * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.losebreath += 2 * REM * normalise_creation_purity() * seconds_per_tick
if(SPT_PROB(10, seconds_per_tick))
affected_mob.emote("gasp")
..()
@@ -217,12 +217,12 @@
ph = 10
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/slimejelly/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(5, delta_time))
/datum/reagent/toxin/slimejelly/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(5, seconds_per_tick))
to_chat(affected_mob, span_danger("Your insides are burning!"))
affected_mob.adjustToxLoss(rand(20, 60), FALSE, required_biotype = affected_biotype)
. = TRUE
else if(DT_PROB(23, delta_time))
else if(SPT_PROB(23, seconds_per_tick))
affected_mob.heal_bodypart_damage(5)
. = TRUE
..()
@@ -269,17 +269,17 @@
LAZYINITLIST(zombiepowder.data)
zombiepowder.data["method"] |= INGEST
/datum/reagent/toxin/zombiepowder/on_mob_life(mob/living/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/zombiepowder/on_mob_life(mob/living/affected_mob, seconds_per_tick, times_fired)
if(HAS_TRAIT(affected_mob, TRAIT_FAKEDEATH) && HAS_TRAIT(affected_mob, TRAIT_DEATHCOMA))
..()
return TRUE
switch(current_cycle)
if(1 to 5)
affected_mob.adjust_confusion(1 SECONDS * REM * delta_time)
affected_mob.adjust_drowsiness(2 SECONDS * REM * delta_time)
affected_mob.adjust_slurring(6 SECONDS * REM * delta_time)
affected_mob.adjust_confusion(1 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_drowsiness(2 SECONDS * REM * seconds_per_tick)
affected_mob.adjust_slurring(6 SECONDS * REM * seconds_per_tick)
if(5 to 8)
affected_mob.adjustStaminaLoss(40 * REM * delta_time, 0)
affected_mob.adjustStaminaLoss(40 * REM * seconds_per_tick, 0)
if(9 to INFINITY)
affected_mob.fakedeath(type)
..()
@@ -305,8 +305,8 @@
REMOVE_TRAIT(affected_mob, TRAIT_FAKEDEATH, type)
..()
/datum/reagent/toxin/ghoulpowder/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOxyLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
/datum/reagent/toxin/ghoulpowder/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOxyLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
..()
. = TRUE
@@ -332,14 +332,14 @@
. = ..()
REMOVE_TRAIT(metabolizer, TRAIT_RDS_SUPPRESSED, type)
/datum/reagent/toxin/mindbreaker/on_mob_life(mob/living/carbon/metabolizer, delta_time, times_fired)
/datum/reagent/toxin/mindbreaker/on_mob_life(mob/living/carbon/metabolizer, seconds_per_tick, times_fired)
// mindbreaker toxin assuages hallucinations in those plagued with it, mentally
if(metabolizer.has_trauma_type(/datum/brain_trauma/mild/hallucinations))
metabolizer.remove_status_effect(/datum/status_effect/hallucination)
// otherwise it creates hallucinations. truly a miracle medicine.
else
metabolizer.adjust_hallucinations(10 SECONDS * REM * delta_time)
metabolizer.adjust_hallucinations(10 SECONDS * REM * seconds_per_tick)
return ..()
@@ -451,10 +451,10 @@
ph = 11
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/spore/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/spore/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.damageoverlaytemp = 60
affected_mob.update_damage_hud()
affected_mob.set_eye_blur_if_lower(6 SECONDS * REM * delta_time)
affected_mob.set_eye_blur_if_lower(6 SECONDS * REM * seconds_per_tick)
return ..()
/datum/reagent/toxin/spore_burning
@@ -466,8 +466,8 @@
ph = 13
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/spore_burning/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_fire_stacks(2 * REM * delta_time)
/datum/reagent/toxin/spore_burning/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_fire_stacks(2 * REM * seconds_per_tick)
affected_mob.ignite_mob()
return ..()
@@ -485,17 +485,17 @@
inverse_chem = /datum/reagent/impurity/chloralax
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/chloralhydrate/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/chloralhydrate/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
switch(current_cycle)
if(1 to 10)
affected_mob.adjust_confusion(2 SECONDS * REM * normalise_creation_purity() * delta_time)
affected_mob.adjust_drowsiness(4 SECONDS * REM * normalise_creation_purity() * delta_time)
affected_mob.adjust_confusion(2 SECONDS * REM * normalise_creation_purity() * seconds_per_tick)
affected_mob.adjust_drowsiness(4 SECONDS * REM * normalise_creation_purity() * seconds_per_tick)
if(10 to 50)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * delta_time)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * seconds_per_tick)
. = TRUE
if(51 to INFINITY)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * delta_time)
affected_mob.adjustToxLoss(1 * (current_cycle - 50) * REM * normalise_creation_purity() * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * seconds_per_tick)
affected_mob.adjustToxLoss(1 * (current_cycle - 50) * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_biotype = affected_biotype)
. = TRUE
..()
@@ -520,13 +520,13 @@
icon = initial(copy_from.icon)
icon_state = initial(copy_from.icon_state)
/datum/reagent/toxin/fakebeer/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/fakebeer/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
switch(current_cycle)
if(1 to 50)
affected_mob.Sleeping(40 * REM * delta_time)
affected_mob.Sleeping(40 * REM * seconds_per_tick)
if(51 to INFINITY)
affected_mob.Sleeping(40 * REM * delta_time)
affected_mob.adjustToxLoss(1 * (current_cycle - 50) * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.Sleeping(40 * REM * seconds_per_tick)
affected_mob.adjustToxLoss(1 * (current_cycle - 50) * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
return ..()
/datum/reagent/toxin/coffeepowder
@@ -570,9 +570,9 @@
ph = 12.2
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/mutetoxin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/mutetoxin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
// Gain approximately 12 seconds * creation purity seconds of silence every metabolism tick.
affected_mob.set_silence_if_lower(6 SECONDS * REM * normalise_creation_purity() * delta_time)
affected_mob.set_silence_if_lower(6 SECONDS * REM * normalise_creation_purity() * seconds_per_tick)
..()
/datum/reagent/toxin/staminatoxin
@@ -584,8 +584,8 @@
toxpwr = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/staminatoxin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustStaminaLoss(data * REM * delta_time, 0)
/datum/reagent/toxin/staminatoxin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustStaminaLoss(data * REM * seconds_per_tick, 0)
data = max(data - 1, 3)
..()
. = TRUE
@@ -599,11 +599,11 @@
toxpwr = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/polonium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/polonium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if (!HAS_TRAIT(affected_mob, TRAIT_IRRADIATED) && SSradiation.can_irradiate_basic(affected_mob))
affected_mob.AddComponent(/datum/component/irradiated)
else
affected_mob.adjustToxLoss(1 * REM * delta_time, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, required_biotype = affected_biotype)
..()
@@ -618,8 +618,8 @@
toxpwr = 0
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/histamine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(30, delta_time))
/datum/reagent/toxin/histamine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(30, seconds_per_tick))
switch(pick(1, 2, 3, 4))
if(1)
to_chat(affected_mob, span_danger("You can barely see!"))
@@ -635,10 +635,10 @@
. = TRUE
..()
/datum/reagent/toxin/histamine/overdose_process(mob/living/affected_mob, delta_time, times_fired)
affected_mob.adjustOxyLoss(2 * REM * delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustBruteLoss(2 * REM * delta_time, FALSE, FALSE, BODYTYPE_ORGANIC)
affected_mob.adjustToxLoss(2 * REM * delta_time, FALSE, required_biotype = affected_biotype)
/datum/reagent/toxin/histamine/overdose_process(mob/living/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOxyLoss(2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.adjustBruteLoss(2 * REM * seconds_per_tick, FALSE, FALSE, BODYTYPE_ORGANIC)
affected_mob.adjustToxLoss(2 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
..()
. = TRUE
@@ -656,8 +656,8 @@
inverse_chem = /datum/reagent/impurity/methanol
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/formaldehyde/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(2.5, delta_time))
/datum/reagent/toxin/formaldehyde/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(2.5, seconds_per_tick))
holder.add_reagent(/datum/reagent/toxin/histamine, pick(5,15))
holder.remove_reagent(/datum/reagent/toxin/formaldehyde, 1.2)
else
@@ -674,16 +674,16 @@
///Mob Size of the current mob sprite.
var/current_size = RESIZE_DEFAULT_SIZE
/datum/reagent/toxin/venom/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/venom/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/newsize = 1.1 * RESIZE_DEFAULT_SIZE
affected_mob.resize = newsize/current_size
current_size = newsize
affected_mob.update_transform()
toxpwr = 0.1 * volume
affected_mob.adjustBruteLoss((0.3 * volume) * REM * delta_time, FALSE, required_bodytype = affected_bodytype)
affected_mob.adjustBruteLoss((0.3 * volume) * REM * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
. = TRUE
if(DT_PROB(8, delta_time))
if(SPT_PROB(8, seconds_per_tick))
holder.add_reagent(/datum/reagent/toxin/histamine, pick(5, 10))
holder.remove_reagent(/datum/reagent/toxin/venom, 1.1)
else
@@ -708,14 +708,14 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
addiction_types = list(/datum/addiction/opioids = 25)
/datum/reagent/toxin/fentanyl/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * normalise_creation_purity() * delta_time, 150)
/datum/reagent/toxin/fentanyl/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 3 * REM * normalise_creation_purity() * seconds_per_tick, 150)
if(affected_mob.toxloss <= 60)
affected_mob.adjustToxLoss(1 * REM * normalise_creation_purity() * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjustToxLoss(1 * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_biotype = affected_biotype)
if(current_cycle >= 4)
affected_mob.add_mood_event("smacked out", /datum/mood_event/narcotic_heavy, name)
if(current_cycle >= 18)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * delta_time)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * seconds_per_tick)
..()
return TRUE
@@ -731,10 +731,10 @@
ph = 9.3
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/cyanide/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(2.5, delta_time))
/datum/reagent/toxin/cyanide/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(2.5, seconds_per_tick))
affected_mob.losebreath += 1
if(DT_PROB(4, delta_time))
if(SPT_PROB(4, seconds_per_tick))
to_chat(affected_mob, span_danger("You feel horrendously weak!"))
affected_mob.Stun(40)
affected_mob.adjustToxLoss(2*REM * normalise_creation_purity(), FALSE, required_biotype = affected_biotype)
@@ -764,20 +764,20 @@
penetrates_skin = TOUCH|VAPOR
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/itching_powder/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(8, delta_time))
/datum/reagent/toxin/itching_powder/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(8, seconds_per_tick))
to_chat(affected_mob, span_danger("You scratch at your head."))
affected_mob.adjustBruteLoss(0.2*REM, FALSE, required_bodytype = affected_bodytype)
. = TRUE
if(DT_PROB(8, delta_time))
if(SPT_PROB(8, seconds_per_tick))
to_chat(affected_mob, span_danger("You scratch at your leg."))
affected_mob.adjustBruteLoss(0.2*REM, FALSE, required_bodytype = affected_bodytype)
. = TRUE
if(DT_PROB(8, delta_time))
if(SPT_PROB(8, seconds_per_tick))
to_chat(affected_mob, span_danger("You scratch at your arm."))
affected_mob.adjustBruteLoss(0.2*REM, FALSE, required_bodytype = affected_bodytype)
. = TRUE
if(DT_PROB(1.5, delta_time))
if(SPT_PROB(1.5, seconds_per_tick))
holder.add_reagent(/datum/reagent/toxin/histamine,rand(1,3))
holder.remove_reagent(/datum/reagent/toxin/itching_powder,1.2)
return
@@ -793,8 +793,8 @@
toxpwr = 2.5
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/initropidril/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(13, delta_time))
/datum/reagent/toxin/initropidril/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(13, seconds_per_tick))
var/picked_option = rand(1,3)
switch(picked_option)
if(1)
@@ -826,11 +826,11 @@
taste_mult = 0 // undetectable, I guess?
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/pancuronium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/pancuronium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle >= 10)
affected_mob.Stun(40 * REM * delta_time)
affected_mob.Stun(40 * REM * seconds_per_tick)
. = TRUE
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_mob.losebreath += 4
..()
@@ -852,10 +852,10 @@
. = ..()
REMOVE_TRAIT(affected_mob, TRAIT_ANTICONVULSANT, name)
/datum/reagent/toxin/sodium_thiopental/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/sodium_thiopental/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle >= 10)
affected_mob.Sleeping(40 * REM * delta_time)
affected_mob.adjustStaminaLoss(10 * REM * delta_time, 0)
affected_mob.Sleeping(40 * REM * seconds_per_tick)
affected_mob.adjustStaminaLoss(10 * REM * seconds_per_tick, 0)
..()
return TRUE
@@ -872,9 +872,9 @@
ph = 6
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/sulfonal/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/sulfonal/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle >= 22)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * delta_time)
affected_mob.Sleeping(40 * REM * normalise_creation_purity() * seconds_per_tick)
return ..()
/datum/reagent/toxin/amanitin
@@ -888,8 +888,8 @@
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
var/delayed_toxin_damage = 0
/datum/reagent/toxin/amanitin/on_mob_life(mob/living/affected_mob, delta_time, times_fired)
delayed_toxin_damage += (delta_time * 3)
/datum/reagent/toxin/amanitin/on_mob_life(mob/living/affected_mob, seconds_per_tick, times_fired)
delayed_toxin_damage += (seconds_per_tick * 3)
. = ..()
/datum/reagent/toxin/amanitin/on_mob_delete(mob/living/affected_mob)
@@ -912,10 +912,10 @@
inverse_chem = /datum/reagent/impurity/ipecacide
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/lipolicide/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/lipolicide/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.nutrition <= NUTRITION_LEVEL_STARVING)
affected_mob.adjustToxLoss(1 * REM * delta_time, FALSE, required_biotype = affected_biotype)
affected_mob.adjust_nutrition(-3 * REM * normalise_creation_purity() * delta_time) // making the chef more valuable, one meme trap at a time
affected_mob.adjustToxLoss(1 * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
affected_mob.adjust_nutrition(-3 * REM * normalise_creation_purity() * seconds_per_tick) // making the chef more valuable, one meme trap at a time
affected_mob.overeatduration = 0
return ..()
@@ -928,9 +928,9 @@
toxpwr = 1.75
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/coniine/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/coniine/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.losebreath < 5)
affected_mob.losebreath = min(affected_mob.losebreath + 5 * REM * delta_time, 5)
affected_mob.losebreath = min(affected_mob.losebreath + 5 * REM * seconds_per_tick, 5)
return ..()
/datum/reagent/toxin/spewium
@@ -944,17 +944,17 @@
taste_description = "vomit"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/spewium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/spewium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
.=..()
if(current_cycle >= 11 && DT_PROB(min(30, current_cycle), delta_time))
if(current_cycle >= 11 && SPT_PROB(min(30, current_cycle), seconds_per_tick))
affected_mob.vomit(10, prob(10), prob(50), rand(0,4), TRUE)
for(var/datum/reagent/toxin/R in affected_mob.reagents.reagent_list)
if(R != src)
affected_mob.reagents.remove_reagent(R.type,1)
/datum/reagent/toxin/spewium/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/spewium/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
. = ..()
if(current_cycle >= 33 && DT_PROB(7.5, delta_time))
if(current_cycle >= 33 && SPT_PROB(7.5, seconds_per_tick))
affected_mob.spew_organ()
affected_mob.vomit(0, TRUE, TRUE, 4)
to_chat(affected_mob, span_userdanger("You feel something lumpy come up as you vomit."))
@@ -968,10 +968,10 @@
toxpwr = 1
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/curare/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/curare/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle >= 11)
affected_mob.Paralyze(60 * REM * delta_time)
affected_mob.adjustOxyLoss(0.5*REM*delta_time, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
affected_mob.Paralyze(60 * REM * seconds_per_tick)
affected_mob.adjustOxyLoss(0.5*REM*seconds_per_tick, FALSE, required_biotype = affected_biotype, required_respiration_type = affected_respiration_type)
. = TRUE
..()
@@ -1010,7 +1010,7 @@
taste_description = "spinning"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/rotatium/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/rotatium/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(affected_mob.hud_used)
if(current_cycle >= 20 && (current_cycle % 20) == 0)
var/atom/movable/plane_master_controller/pm_controller = affected_mob.hud_used.plane_master_controllers[PLANE_MASTERS_GAME]
@@ -1040,12 +1040,12 @@
ph = 8
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/anacea/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/anacea/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
var/remove_amt = 5
if(holder.has_reagent(/datum/reagent/medicine/calomel) || holder.has_reagent(/datum/reagent/medicine/pen_acid))
remove_amt = 0.5
for(var/datum/reagent/medicine/R in affected_mob.reagents.reagent_list)
affected_mob.reagents.remove_reagent(R.type, remove_amt * REM * normalise_creation_purity() * delta_time)
affected_mob.reagents.remove_reagent(R.type, remove_amt * REM * normalise_creation_purity() * seconds_per_tick)
return ..()
//ACID
@@ -1118,8 +1118,8 @@
mytray.adjust_toxic(round(chems.get_reagent_amount(type) * 3))
mytray.adjust_weedlevel(-rand(1,4))
/datum/reagent/toxin/acid/fluacid/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustFireLoss((current_cycle/15) * REM * normalise_creation_purity() * delta_time, FALSE, required_bodytype = affected_bodytype)
/datum/reagent/toxin/acid/fluacid/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustFireLoss((current_cycle/15) * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_bodytype = affected_bodytype)
. = TRUE
..()
@@ -1134,8 +1134,8 @@
ph = 1.3
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/acid/nitracid/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustFireLoss((volume/10) * REM * normalise_creation_purity() * delta_time, FALSE, required_bodytype = affected_bodytype) //here you go nervar
/datum/reagent/toxin/acid/nitracid/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustFireLoss((volume/10) * REM * normalise_creation_purity() * seconds_per_tick, FALSE, required_bodytype = affected_bodytype) //here you go nervar
. = TRUE
..()
@@ -1150,11 +1150,11 @@
var/delay = 30
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED|REAGENT_NO_RANDOM_RECIPE
/datum/reagent/toxin/delayed/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
/datum/reagent/toxin/delayed/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(current_cycle > delay)
holder.remove_reagent(type, actual_metaboliztion_rate * affected_mob.metabolism_efficiency * delta_time)
affected_mob.adjustToxLoss(actual_toxpwr * REM * delta_time, FALSE, required_biotype = affected_biotype)
if(DT_PROB(5, delta_time))
holder.remove_reagent(type, actual_metaboliztion_rate * affected_mob.metabolism_efficiency * seconds_per_tick)
affected_mob.adjustToxLoss(actual_toxpwr * REM * seconds_per_tick, FALSE, required_biotype = affected_biotype)
if(SPT_PROB(5, seconds_per_tick))
affected_mob.Paralyze(20)
. = TRUE
..()
@@ -1194,9 +1194,9 @@
affected_mob.say("oof ouch my bones", forced = /datum/reagent/toxin/bonehurtingjuice)
return ..()
/datum/reagent/toxin/bonehurtingjuice/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustStaminaLoss(7.5 * REM * delta_time, 0)
if(DT_PROB(10, delta_time))
/datum/reagent/toxin/bonehurtingjuice/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustStaminaLoss(7.5 * REM * seconds_per_tick, 0)
if(SPT_PROB(10, seconds_per_tick))
switch(rand(1, 3))
if(1)
affected_mob.say(pick("oof.", "ouch.", "my bones.", "oof ouch.", "oof ouch my bones."), forced = /datum/reagent/toxin/bonehurtingjuice)
@@ -1206,8 +1206,8 @@
to_chat(affected_mob, span_warning("Your bones hurt!"))
return ..()
/datum/reagent/toxin/bonehurtingjuice/overdose_process(mob/living/carbon/affected_mob, delta_time, times_fired)
if(DT_PROB(2, delta_time) && iscarbon(affected_mob)) //big oof
/datum/reagent/toxin/bonehurtingjuice/overdose_process(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
if(SPT_PROB(2, seconds_per_tick) && iscarbon(affected_mob)) //big oof
var/selected_part = pick(BODY_ZONE_L_ARM, BODY_ZONE_R_ARM, BODY_ZONE_L_LEG, BODY_ZONE_R_LEG) //God help you if the same limb gets picked twice quickly.
var/obj/item/bodypart/BP = affected_mob.get_bodypart(selected_part)
if(BP)
@@ -1230,8 +1230,8 @@
taste_description = "tannin"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/bungotoxin/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_HEART, 3 * REM * delta_time)
/datum/reagent/toxin/bungotoxin/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_HEART, 3 * REM * seconds_per_tick)
// If our mob's currently dizzy from anything else, we will also gain confusion
var/mob_dizziness = affected_mob.get_timed_status_effect_duration(/datum/status_effect/confusion)
@@ -1239,7 +1239,7 @@
// Gain confusion equal to about half the duration of our current dizziness
affected_mob.set_confusion(mob_dizziness / 2)
if(current_cycle >= 12 && DT_PROB(4, delta_time))
if(current_cycle >= 12 && SPT_PROB(4, seconds_per_tick))
var/tox_message = pick("You feel your heart spasm in your chest.", "You feel faint.","You feel you need to catch your breath.","You feel a prickle of pain in your chest.")
to_chat(affected_mob, span_notice("[tox_message]"))
. = TRUE
@@ -1255,10 +1255,10 @@
taste_description = "sugary sweetness"
chemical_flags = REAGENT_CAN_BE_SYNTHESIZED
/datum/reagent/toxin/leadacetate/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_EARS, 1 * REM * delta_time)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1 * REM * delta_time)
if(DT_PROB(0.5, delta_time))
/datum/reagent/toxin/leadacetate/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjustOrganLoss(ORGAN_SLOT_EARS, 1 * REM * seconds_per_tick)
affected_mob.adjustOrganLoss(ORGAN_SLOT_BRAIN, 1 * REM * seconds_per_tick)
if(SPT_PROB(0.5, seconds_per_tick))
to_chat(affected_mob, span_notice("Ah, what was that? You thought you heard something..."))
affected_mob.adjust_confusion(5 SECONDS)
return ..()
@@ -1274,6 +1274,6 @@
description = "An extremely toxic chemical produced by the rare viper spider. Brings their prey to the brink of death and causes hallucinations."
health_required = 10
/datum/reagent/toxin/viperspider/on_mob_life(mob/living/carbon/affected_mob, delta_time, times_fired)
affected_mob.adjust_hallucinations(10 SECONDS * REM * delta_time)
/datum/reagent/toxin/viperspider/on_mob_life(mob/living/carbon/affected_mob, seconds_per_tick, times_fired)
affected_mob.adjust_hallucinations(10 SECONDS * REM * seconds_per_tick)
return ..()

View File

@@ -27,16 +27,16 @@
if(cell && cell.charge > 0)
. += span_notice("<b>Ctrl+Click</b> to toggle the power.")
/obj/item/reagent_containers/cup/maunamug/process(delta_time)
/obj/item/reagent_containers/cup/maunamug/process(seconds_per_tick)
..()
if(on && (!cell || cell.charge <= 0)) //Check if we ran out of power
change_power_status(FALSE)
return FALSE
cell.use(5 * delta_time) //Basic cell goes for like 200 seconds, bluespace for 8000
cell.use(5 * seconds_per_tick) //Basic cell goes for like 200 seconds, bluespace for 8000
if(!reagents.total_volume)
return FALSE
var/max_temp = min(500 + (500 * (0.2 * cell.rating)), 1000) // 373 to 1000
reagents.adjust_thermal_energy(0.4 * cell.maxcharge * reagents.total_volume * delta_time, max_temp = max_temp) // 4 kelvin every tick on a basic cell. 160k on bluespace
reagents.adjust_thermal_energy(0.4 * cell.maxcharge * reagents.total_volume * seconds_per_tick, max_temp = max_temp) // 4 kelvin every tick on a basic cell. 160k on bluespace
reagents.handle_reactions()
update_appearance()
if(reagents.chem_temp >= max_temp)

View File

@@ -36,9 +36,9 @@
. = ..()
START_PROCESSING(SSobj, src)
/obj/item/reagent_containers/cup/watering_can/advanced/process(delta_time)
/obj/item/reagent_containers/cup/watering_can/advanced/process(seconds_per_tick)
///How much to refill
var/refill_add = min(volume - reagents.total_volume, refill_rate * delta_time)
var/refill_add = min(volume - reagents.total_volume, refill_rate * seconds_per_tick)
if(refill_add > 0)
reagents.add_reagent(refill_reagent, refill_add)

View File

@@ -55,7 +55,7 @@
end_withdrawal(victim_mind.current)
LAZYREMOVE(victim_mind.active_addictions, type)
/datum/addiction/proc/process_addiction(mob/living/carbon/affected_carbon, delta_time, times_fired)
/datum/addiction/proc/process_addiction(mob/living/carbon/affected_carbon, seconds_per_tick, times_fired)
var/current_addiction_cycle = LAZYACCESS(affected_carbon.mind.active_addictions, type) //If this is null, we're not addicted
var/on_drug_of_this_addiction = FALSE
for(var/datum/reagent/possible_drug as anything in affected_carbon.reagents.reagent_list) //Go through the drugs in our system
@@ -79,7 +79,7 @@
withdrawal_stage = 0
if(!on_drug_of_this_addiction && !HAS_TRAIT(affected_carbon, TRAIT_HOPELESSLY_ADDICTED))
if(affected_carbon.mind.remove_addiction_points(type, addiction_loss_per_stage[withdrawal_stage + 1] * delta_time)) //If true was returned, we lost the addiction!
if(affected_carbon.mind.remove_addiction_points(type, addiction_loss_per_stage[withdrawal_stage + 1] * seconds_per_tick)) //If true was returned, we lost the addiction!
return
if(!current_addiction_cycle) //Dont do the effects if were not on drugs
@@ -96,13 +96,13 @@
///One cycle is 2 seconds
switch(withdrawal_stage)
if(1)
withdrawal_stage_1_process(affected_carbon, delta_time)
withdrawal_stage_1_process(affected_carbon, seconds_per_tick)
if(2)
withdrawal_stage_2_process(affected_carbon, delta_time)
withdrawal_stage_2_process(affected_carbon, seconds_per_tick)
if(3)
withdrawal_stage_3_process(affected_carbon, delta_time)
withdrawal_stage_3_process(affected_carbon, seconds_per_tick)
LAZYADDASSOC(affected_carbon.mind.active_addictions, type, 1 * delta_time) //Next cycle!
LAZYADDASSOC(affected_carbon.mind.active_addictions, type, 1 * seconds_per_tick) //Next cycle!
/// Called when addiction enters stage 1
/datum/addiction/proc/withdrawal_enters_stage_1(mob/living/carbon/affected_carbon)
@@ -121,16 +121,16 @@
affected_carbon.clear_mood_event("[type]_addiction")
/// Called when addiction is in stage 1 every process
/datum/addiction/proc/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, delta_time)
if(DT_PROB(5, delta_time))
/datum/addiction/proc/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
if(SPT_PROB(5, seconds_per_tick))
to_chat(affected_carbon, span_danger("[withdrawal_stage_messages[1]]"))
/// Called when addiction is in stage 2 every process
/datum/addiction/proc/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, delta_time)
if(DT_PROB(10, delta_time) )
/datum/addiction/proc/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, seconds_per_tick)
if(SPT_PROB(10, seconds_per_tick) )
to_chat(affected_carbon, span_danger("[withdrawal_stage_messages[2]]"))
/// Called when addiction is in stage 3 every process
/datum/addiction/proc/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
if(DT_PROB(15, delta_time))
/datum/addiction/proc/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
if(SPT_PROB(15, seconds_per_tick))
to_chat(affected_carbon, span_danger("[withdrawal_stage_messages[3]]"))

View File

@@ -3,19 +3,19 @@
name = "opioid"
withdrawal_stage_messages = list("I feel aches in my bodies..", "I need some pain relief...", "It aches all over...I need some opioids!")
/datum/addiction/opioids/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/opioids/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_carbon.emote("yawn")
/datum/addiction/opioids/withdrawal_enters_stage_2(mob/living/carbon/affected_carbon)
. = ..()
affected_carbon.apply_status_effect(/datum/status_effect/high_blood_pressure)
/datum/addiction/opioids/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/opioids/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
if(affected_carbon.disgust < DISGUST_LEVEL_DISGUSTED && DT_PROB(7.5, delta_time))
affected_carbon.adjust_disgust(12.5 * delta_time)
if(affected_carbon.disgust < DISGUST_LEVEL_DISGUSTED && SPT_PROB(7.5, seconds_per_tick))
affected_carbon.adjust_disgust(12.5 * seconds_per_tick)
/datum/addiction/opioids/end_withdrawal(mob/living/carbon/affected_carbon)
. = ..()
@@ -51,20 +51,20 @@
name = "alcohol"
withdrawal_stage_messages = list("I could use a drink...", "Maybe the bar is still open?..", "God I need a drink!")
/datum/addiction/alcohol/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/alcohol/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(10 SECONDS * delta_time)
affected_carbon.set_jitter_if_lower(10 SECONDS * seconds_per_tick)
/datum/addiction/alcohol/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/alcohol/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(20 SECONDS * delta_time)
affected_carbon.set_jitter_if_lower(20 SECONDS * seconds_per_tick)
affected_carbon.set_hallucinations_if_lower(10 SECONDS)
/datum/addiction/alcohol/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/alcohol/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(30 SECONDS * delta_time)
affected_carbon.set_jitter_if_lower(30 SECONDS * seconds_per_tick)
affected_carbon.set_hallucinations_if_lower(10 SECONDS)
if(DT_PROB(4, delta_time) && !HAS_TRAIT(affected_carbon, TRAIT_ANTICONVULSANT))
if(SPT_PROB(4, seconds_per_tick) && !HAS_TRAIT(affected_carbon, TRAIT_ANTICONVULSANT))
affected_carbon.apply_status_effect(/datum/status_effect/seizure)
/datum/addiction/hallucinogens
@@ -97,9 +97,9 @@
. = ..()
affected_carbon.apply_status_effect(/datum/status_effect/grouped/screwy_hud/fake_healthy, type)
/datum/addiction/maintenance_drugs/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/maintenance_drugs/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
if(DT_PROB(7.5, delta_time))
if(SPT_PROB(7.5, seconds_per_tick))
affected_carbon.emote("growls")
/datum/addiction/maintenance_drugs/withdrawal_enters_stage_2(mob/living/carbon/affected_carbon)
@@ -127,7 +127,7 @@
ADD_TRAIT(affected_human, TRAIT_NIGHT_VISION, "maint_drug_addiction")
empowered_eyes?.refresh()
/datum/addiction/maintenance_drugs/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/maintenance_drugs/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
if(!ishuman(affected_carbon))
return
var/mob/living/carbon/human/affected_human = affected_carbon
@@ -136,7 +136,7 @@
if(lums > 0.5)
affected_human.add_mood_event("too_bright", /datum/mood_event/bright_light)
affected_human.adjust_dizzy_up_to(6 SECONDS, 80 SECONDS)
affected_human.adjust_confusion_up_to(0.5 SECONDS * delta_time, 20 SECONDS)
affected_human.adjust_confusion_up_to(0.5 SECONDS * seconds_per_tick, 20 SECONDS)
else
affected_carbon.clear_mood_event("too_bright")
@@ -176,9 +176,9 @@
return
health_doll_ref = WEAKREF(health_doll)
/datum/addiction/medicine/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/medicine/withdrawal_stage_1_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
affected_carbon.emote("cough")
/datum/addiction/medicine/withdrawal_enters_stage_2(mob/living/carbon/affected_carbon)
@@ -209,18 +209,18 @@
return
fake_alert_ref = WEAKREF(fake_alert)
/datum/addiction/medicine/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/medicine/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
var/datum/hallucination/fake_health_doll/hallucination = health_doll_ref?.resolve()
if(QDELETED(hallucination))
health_doll_ref = null
return
if(DT_PROB(10, delta_time))
if(SPT_PROB(10, seconds_per_tick))
hallucination.add_fake_limb(severity = 1)
return
if(DT_PROB(5, delta_time))
if(SPT_PROB(5, seconds_per_tick))
hallucination.increment_fake_damage()
return
@@ -228,18 +228,18 @@
. = ..()
affected_carbon.apply_status_effect(/datum/status_effect/grouped/screwy_hud/fake_crit, type)
/datum/addiction/medicine/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/medicine/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
var/datum/hallucination/fake_health_doll/hallucination = health_doll_ref?.resolve()
if(!QDELETED(hallucination) && DT_PROB(5, delta_time))
if(!QDELETED(hallucination) && SPT_PROB(5, seconds_per_tick))
hallucination.increment_fake_damage()
return
if(DT_PROB(15, delta_time))
if(SPT_PROB(15, seconds_per_tick))
affected_carbon.emote("cough")
return
if(DT_PROB(65, delta_time))
if(SPT_PROB(65, seconds_per_tick))
return
if(affected_carbon.stat >= SOFT_CRIT)
@@ -272,19 +272,19 @@
medium_withdrawal_moodlet = /datum/mood_event/nicotine_withdrawal_moderate
severe_withdrawal_moodlet = /datum/mood_event/nicotine_withdrawal_severe
/datum/addiction/nicotine/withdrawal_enters_stage_1(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/nicotine/withdrawal_enters_stage_1(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(10 SECONDS * delta_time)
affected_carbon.set_jitter_if_lower(10 SECONDS * seconds_per_tick)
/datum/addiction/nicotine/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/nicotine/withdrawal_stage_2_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(20 SECONDS * delta_time)
if(DT_PROB(10, delta_time))
affected_carbon.set_jitter_if_lower(20 SECONDS * seconds_per_tick)
if(SPT_PROB(10, seconds_per_tick))
affected_carbon.emote("cough")
/datum/addiction/nicotine/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, delta_time)
/datum/addiction/nicotine/withdrawal_stage_3_process(mob/living/carbon/affected_carbon, seconds_per_tick)
. = ..()
affected_carbon.set_jitter_if_lower(30 SECONDS * delta_time)
if(DT_PROB(15, delta_time))
affected_carbon.set_jitter_if_lower(30 SECONDS * seconds_per_tick)
if(SPT_PROB(15, seconds_per_tick))
affected_carbon.emote("cough")
*/