Skip to content
This repository was archived by the owner on May 22, 2025. It is now read-only.

Commit 4dfc579

Browse files
authored
Strengthens counterplay vs allergens (#22973)
1 parent c428b4a commit 4dfc579

File tree

5 files changed

+23
-3
lines changed

5 files changed

+23
-3
lines changed

code/datums/traits/negative.dm

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -736,6 +736,15 @@
736736
if(H.stat == DEAD)
737737
return
738738

739+
if(H.reagents.has_reagent(/datum/reagent/medicine/epinephrine))
740+
return
741+
if(H.reagents.has_reagent(/datum/reagent/medicine/atropine))
742+
return
743+
if(H.reagents.has_reagent(/datum/reagent/medicine/diphenhydramine))
744+
return
745+
if(H.reagents.has_reagent(/datum/reagent/medicine/synaphydramine))
746+
return
747+
739748
var/datum/reagent/allergy = GLOB.chemical_reagents_list[reagent_id]
740749

741750
if(H.reagents.has_reagent(reagent_id)) //check if there are chems

code/modules/mob/living/carbon/human/examine.dm

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,9 @@
281281
if(DISGUST_LEVEL_DISGUSTED to INFINITY)
282282
msg += "[t_He] look[p_s()] extremely disgusted.\n"
283283

284+
var/datum/quirk/allergic/allergen = has_quirk(/datum/quirk/allergic)
285+
if((allergen && reagents?.has_reagent(allergen.reagent_id)) || reagents?.has_reagent(/datum/reagent/toxin/histamine))
286+
msg += span_boldwarning("[t_His] face is very swollen!\n")
284287

285288
var/apparent_blood_volume = blood_volume
286289
if(skin_tone == "albino")

code/modules/mob/living/status_procs.dm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@
464464
/mob/living/proc/has_quirk(quirktype)
465465
for(var/datum/quirk/Q in roundstart_quirks)
466466
if(Q.type == quirktype)
467-
return TRUE
467+
return Q
468468
return FALSE
469469

470470
/mob/living/proc/remove_all_quirks()

code/modules/reagents/chemistry/reagents/medicine_reagents.dm

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -891,7 +891,7 @@
891891
M.adjustFireLoss(-0.5*REM, 0)
892892
M.adjustOxyLoss(-0.5*REM, 0)
893893
if(M.losebreath >= 4)
894-
M.losebreath -= 2
894+
M.losebreath = floor(M.losebreath * 0.9)
895895
if(M.losebreath < 0)
896896
M.losebreath = 0
897897
M.adjustStaminaLoss(-0.5*REM, 0)

code/modules/reagents/chemistry/reagents/toxin_reagents.dm

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -472,6 +472,15 @@
472472
toxpwr = 0
473473

474474
/datum/reagent/toxin/histamine/on_mob_life(mob/living/carbon/M)
475+
. = ..()
476+
if(M.reagents.has_reagent(/datum/reagent/medicine/epinephrine))
477+
return
478+
if(M.reagents.has_reagent(/datum/reagent/medicine/atropine))
479+
return
480+
if(M.reagents.has_reagent(/datum/reagent/medicine/diphenhydramine))
481+
return
482+
if(M.reagents.has_reagent(/datum/reagent/medicine/synaphydramine))
483+
return
475484
if(prob(50))
476485
switch(pick(1, 2, 3, 4))
477486
if(1)
@@ -486,7 +495,6 @@
486495
to_chat(M, "You scratch at an itch.")
487496
M.adjustBruteLoss(2*REM, 0)
488497
. = 1
489-
..()
490498

491499
/datum/reagent/toxin/histamine/overdose_process(mob/living/M)
492500
M.adjustOxyLoss(2*REM, 0)

0 commit comments

Comments
 (0)