Move Jolly and Depression into mood handling (#56580)

The Jolly and Depression quirks are much more active. You can expect the positive/negative moodlets to affect you around 50% of the time.

Previously, the probability of the Jolly/Depression moodlet firing was so low, you only have a less than 1/3 chance of seeing the 2 minute moodlet in an hour of play. Now they will be far more active.
Depression's hardcore point value has increased, since it is far more negative now.

The quirks now just add the TRAIT_JOLLY and TRAIT_DEPRESSION, which is then used by the mood component to have a chance of triggering the corresponding mood episode.

Gonbolas now have an always on positive mood message, rather than applying a do nothing TRAIT_JOLLY trait.

To demonstrate how the mood traits are independent of the quirks, There is now a "jolly grey cap", which gives you TRAIT_JOLLY while it is being worn.
This commit is contained in:
coiax
2021-02-11 01:26:50 -03:00
committed by GitHub
parent 774baa6f2c
commit 36c7d2c110
6 changed files with 31 additions and 16 deletions
+9
View File
@@ -194,6 +194,15 @@
setSanity(sanity+0.6*delta_time, SANITY_NEUTRAL, SANITY_MAXIMUM)
HandleNutrition()
// 0.416% is 15 successes / 3600 seconds. Calculated with 2 minute
// mood runtime, so 50% average uptime across the hour.
if(HAS_TRAIT(parent, TRAIT_DEPRESSION) && DT_PROB(0.416, delta_time))
add_event(null, "depression_mild", /datum/mood_event/depression_mild)
if(HAS_TRAIT(parent, TRAIT_JOLLY) && DT_PROB(0.416, delta_time))
add_event(null, "jolly", /datum/mood_event/jolly)
///Sets sanity to the specified amount and applies effects.
/datum/component/mood/proc/setSanity(amount, minimum=SANITY_INSANE, maximum=SANITY_GREAT, override = FALSE)
// If we're out of the acceptable minimum-maximum range move back towards it in steps of 0.7
@@ -224,6 +224,10 @@
mood_change = 3
timeout = 90 SECONDS
/datum/mood_event/gondola
description = "<span class='nicegreen'>I feel at peace and feel no need to make any sudden or rash actions.</span>\n"
mood_change = 6
/datum/mood_event/kiss
description = "<span class='nicegreen'>Someone blew a kiss at me, I must be a real catch!</span>\n"
mood_change = 1.5
-4
View File
@@ -126,10 +126,6 @@
mood_quirk = TRUE
medical_record_text = "Patient demonstrates constant euthymia irregular for environment. It's a bit much, to be honest."
/datum/quirk/jolly/on_process(delta_time)
if(DT_PROB(0.05, delta_time))
SEND_SIGNAL(quirk_holder, COMSIG_ADD_MOOD_EVENT, "jolly", /datum/mood_event/jolly)
/datum/quirk/light_step
name = "Light Step"
desc = "You walk with a gentle step; footsteps and stepping on sharp objects is quieter and less painful."
+1 -5
View File
@@ -116,11 +116,7 @@
lose_text = "<span class='notice'>You no longer feel depressed.</span>" //if only it were that easy!
medical_record_text = "Patient has a mild mood disorder causing them to experience acute episodes of depression."
mood_quirk = TRUE
hardcore_value = 1
/datum/quirk/depression/on_process(delta_time)
if(DT_PROB(0.05, delta_time))
SEND_SIGNAL(quirk_holder, COMSIG_ADD_MOOD_EVENT, "depression_mild", /datum/mood_event/depression_mild)
hardcore_value = 2
/datum/quirk/family_heirloom
name = "Family Heirloom"
+8 -7
View File
@@ -634,16 +634,17 @@
alert_type = null
/datum/status_effect/gonbola_pacify/on_apply()
ADD_TRAIT(owner, TRAIT_PACIFISM, "gonbolaPacify")
ADD_TRAIT(owner, TRAIT_MUTE, "gonbolaMute")
ADD_TRAIT(owner, TRAIT_JOLLY, "gonbolaJolly")
. = ..()
ADD_TRAIT(owner, TRAIT_PACIFISM, type)
ADD_TRAIT(owner, TRAIT_MUTE, type)
SEND_SIGNAL(owner, COMSIG_ADD_MOOD_EVENT, type, /datum/mood_event/gondola)
to_chat(owner, "<span class='notice'>You suddenly feel at peace and feel no need to make any sudden or rash actions...</span>")
return ..()
/datum/status_effect/gonbola_pacify/on_remove()
REMOVE_TRAIT(owner, TRAIT_PACIFISM, "gonbolaPacify")
REMOVE_TRAIT(owner, TRAIT_MUTE, "gonbolaMute")
REMOVE_TRAIT(owner, TRAIT_JOLLY, "gonbolaJolly")
REMOVE_TRAIT(owner, TRAIT_PACIFISM, type)
REMOVE_TRAIT(owner, TRAIT_MUTE, type)
SEND_SIGNAL(owner, COMSIG_CLEAR_MOOD_EVENT, type)
return ..()
/datum/status_effect/trance
id = "trance"
+9
View File
@@ -77,6 +77,15 @@
soft_type = "grey"
dog_fashion = null
/* A grey baseball cap that grants TRAIT_JOLLY when it's on your head.
* Used for testing that gaining and losing the JOLLY trait behaves properly.
* Also a perfectly valid weird admin reward.
*/
/obj/item/clothing/head/soft/grey/jolly
name = "jolly grey cap"
desc = "It's a baseball hat in a sublime grey colour. Why, wearing this alone would boost a person's spirits!"
clothing_traits = list(TRAIT_JOLLY)
/obj/item/clothing/head/soft/orange
name = "orange cap"
desc = "It's a baseball hat in a tasteless orange colour."