Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor fixes to twitch #3899

Closed
wants to merge 4 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions monkestation/code/modules/blueshift/reagents/deforest.dm
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@

/datum/reagent/drug/twitch/on_mob_metabolize(mob/living/our_guy)
. = ..()
if(!our_guy.get_organ_slot(ORGAN_SLOT_HEART))
if(!our_guy.get_organ_slot(ORGAN_SLOT_HEART) || !our_guy.needs_heart())

Check failure on line 251 in monkestation/code/modules/blueshift/reagents/deforest.dm

View workflow job for this annotation

GitHub Actions / Run Linters

undefined proc: "needs_heart" on /mob/living

Check failure on line 251 in monkestation/code/modules/blueshift/reagents/deforest.dm

View workflow job for this annotation

GitHub Actions / Run Linters

OD0404: Type /mob/living does not have a proc named "needs_heart"
return

our_guy.add_movespeed_modifier(/datum/movespeed_modifier/reagent/twitch)
Expand Down Expand Up @@ -398,7 +398,7 @@

/datum/reagent/drug/twitch/overdose_process(mob/living/carbon/our_guy, seconds_per_tick, times_fired)
. = ..()
if(!our_guy.get_organ_slot(ORGAN_SLOT_HEART))
if(!our_guy.get_organ_slot(ORGAN_SLOT_HEART) || !our_guy.needs_heart())
return

our_guy.set_jitter_if_lower(10 SECONDS * REM * seconds_per_tick)
Expand All @@ -407,11 +407,13 @@
if((our_guy.mob_biotypes & MOB_ROBOTIC) || HAS_TRAIT(our_guy, TRAIT_STABLEHEART))
var/heating = (mob_heating_muliplier * 2) * REM * seconds_per_tick
our_guy.reagents?.chem_temp += heating
our_guy.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT, max_temp = our_guy.bodytemp_heat_damage_limit - 5)
our_guy.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT, max_temp = our_guy.bodytemp_heat_damage_limit + 10)
our_guy.adjustFireLoss(0.5 * seconds_per_tick)
if(!ishuman(our_guy))
return
var/mob/living/carbon/human/human = our_guy
human.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT, max_temp = our_guy.bodytemp_heat_damage_limit - 5)
human.adjust_bodytemperature(heating * TEMPERATURE_DAMAGE_COEFFICIENT, max_temp = our_guy.bodytemp_heat_damage_limit + 10)
our_guy.adjustFireLoss(0.5 * seconds_per_tick)
else
our_guy.adjustOrganLoss(ORGAN_SLOT_HEART, 1 * REM * seconds_per_tick, required_organtype = affected_organtype)
our_guy.adjustToxLoss(1 * REM * seconds_per_tick, updating_health = FALSE, forced = TRUE, required_biotype = affected_biotype)
Expand Down
Loading