mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-22 04:30:44 +01:00
## About The Pull Request This PR adds the fearful component which acts as a unified handler for terror effects. This currently includes nyctophobia and claustrophobia quirks, terrified status effect from nightmare's spell, and the monophobia brain trauma. The component processes terror handler datums which act both as terror sources and effects - jittering, stuttering, vomiting, panic attacks, etc. This means that nyctophobia and claustrophobia now act more like terrified status/monophobia - causing jitters, stuttering, periodic panic attacks, etc, and their effects stack (i.e. being in a closet in the dark will increase your fear much quicker). Closes #37492 Closes #57121 Closes #69684 ## Why It's Good For The Game Terrified status is very immersive and its effects perfectly fit nycto/claustrophobia quirks, enough to be impactful to owner's gameplay, but not roleplaying for them, which is what we want quirks to be. It also makes them share their stress, which is how you'd expect them to act. (I would also love to see monophobia moved from a brain trauma to a quirk, as it perfectly fits latter instead of former, and acts as a great incentive to interact with other people instead of doing autism projects by yourself.) I haven't moved phobias to this system yet, but it could be done in the future without too many issues - should make phobias less painful to deal with, and maybe make people actually interested in playing around them instead of rushing a lobotomy because of how debilitating they are (currently only interaction is getting hugged by someone you're afraid of, which will increase your terror) ## Changelog 🆑 add: Nyctophobia and Claustrophobia quirks now have proper terror effects instead of making you walk/suffocate. Immersion! refactor: All sources of "terror"/"fear" now use a common component, meaning they share their counters. /🆑
33 lines
1.4 KiB
Plaintext
33 lines
1.4 KiB
Plaintext
/// How much terror is applied upon first cast of Terrify
|
|
#define TERROR_INITIAL_AMOUNT 100
|
|
/// Amount of terror caused by subsequent casting of the Terrify spell.
|
|
#define STACK_TERROR_AMOUNT 135
|
|
|
|
/datum/status_effect/terrified
|
|
id = "terrified"
|
|
status_type = STATUS_EFFECT_REFRESH
|
|
remove_on_fullheal = TRUE
|
|
alert_type = /atom/movable/screen/alert/status_effect/terrified
|
|
|
|
/datum/status_effect/terrified/on_apply()
|
|
to_chat(owner, span_alert("The darkness closes in around you, shadows dance around the corners of your vision... It feels like something is watching you!"))
|
|
owner.emote("scream")
|
|
owner.AddComponentFrom("terrified", /datum/component/fearful, list(/datum/terror_handler/simple_source/nyctophobia/terrified), TERROR_INITIAL_AMOUNT)
|
|
return TRUE
|
|
|
|
/datum/status_effect/terrified/on_remove()
|
|
owner.RemoveComponentSource("terrified", /datum/component/fearful)
|
|
|
|
/datum/status_effect/terrified/refresh(effect, ...)
|
|
// Jank way of adding terror to the existing component
|
|
owner.AddComponentFrom("terrified", /datum/component/fearful, null, STACK_TERROR_AMOUNT)
|
|
|
|
/// The status effect popup for the terror status effect
|
|
/atom/movable/screen/alert/status_effect/terrified
|
|
name = "Terrified!"
|
|
desc = "You feel a supernatural darkness settle in around you, overwhelming you with panic! Get into the light!"
|
|
icon_state = "terrified"
|
|
|
|
#undef TERROR_INITIAL_AMOUNT
|
|
#undef STACK_TERROR_AMOUNT
|