Skip to content

Commit

Permalink
Analgesia trait fixes (#3583)
Browse files Browse the repository at this point in the history
<!-- Write **BELOW** The Headers and **ABOVE** The comments else it may
not be viewable. -->
<!-- You can view Contributing.MD for a detailed description of the pull
request process. -->

## About The Pull Request

Analgesia is now incompatible with self-aware
Embeds and EMPs no longer give people with analgesia big warning
messages

<!-- Describe The Pull Request. Please be sure every change is
documented or this can delay review and even discourage maintainers from
merging your PR! -->

## Why It's Good For The Game
code good
<!-- Please add a short description of why you think these changes would
benefit the game. If you can't justify it in words, it might not be
worth adding. -->

## Changelog

:cl:
fix: Analgesia can no longer be taken with self-aware
fix: Few edge cases for analgesiacs getting pain
/:cl:

<!-- Both :cl:'s are required for the changelog to work! You can put
your name to the right of the first :cl: if you want to overwrite your
GitHub username as author ingame. -->
<!-- You can use multiple of the same prefix (they're only used for the
icon ingame) and delete the unneeded ones. Despite some of the tags,
changelogs should generally represent how a player might be affected by
the changes rather than a summary of the PR's contents. -->

---------

Signed-off-by: Erika Fox <[email protected]>
Co-authored-by: Bjarl <[email protected]>
Co-authored-by: FalloutFalcon <[email protected]>
  • Loading branch information
3 people authored Oct 22, 2024
1 parent ffbf7cf commit 0c8f4c6
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
4 changes: 3 additions & 1 deletion code/controllers/subsystem/processing/quirks.dm
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
list("Ageusia","Vegetarian","Deviant Tastes"), \
list("Ananas Affinity","Ananas Aversion"), \
list("Alcohol Tolerance","Light Drinker"), \
list("Bad Touch", "Friendly"))
list("Bad Touch", "Friendly"), \
list("Self-Aware", "Congenital Analgesia")
)

species_blacklist = list("Blood Deficiency" = list(SPECIES_IPC, SPECIES_JELLYPERSON, SPECIES_PLASMAMAN, SPECIES_VAMPIRE))

Expand Down
5 changes: 4 additions & 1 deletion code/datums/components/embedded.dm
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,10 @@
if(harmful && prob(chance))
var/damage = weapon.w_class * jostle_pain_mult
limb.receive_damage(brute=(1-pain_stam_pct) * damage, stamina=pain_stam_pct * damage)
to_chat(victim, "<span class='userdanger'>[weapon] embedded in your [limb.name] jostles and stings!</span>")
if(HAS_TRAIT(victim, TRAIT_ANALGESIA))
to_chat(victim, span_notice("[weapon] embedded in your [limb.name] shifts around."))
return
to_chat(victim, span_userdanger("[weapon] embedded in your [limb.name] jostles and stings!"))


/// Called when then item randomly falls out of a carbon. This handles the damage and descriptors, then calls safe_remove()
Expand Down
4 changes: 2 additions & 2 deletions code/modules/mob/living/carbon/human/human_defense.dm
Original file line number Diff line number Diff line change
Expand Up @@ -522,8 +522,8 @@
var/informed = FALSE
for(var/obj/item/bodypart/L as anything in bodyparts)
if(!IS_ORGANIC_LIMB(L))
if(!informed)
to_chat(src, "<span class='userdanger'>You feel a sharp pain as your robotic limbs overload.</span>")
if(!informed && !HAS_TRAIT(src, TRAIT_ANALGESIA))
to_chat(src, span_userdanger("You feel a sharp pain as your robotic limbs overload."))
informed = TRUE
switch(severity)
if(1)
Expand Down

0 comments on commit 0c8f4c6

Please sign in to comment.