From a3ae6459b23bdd2b461815e765517916a50ccfbe Mon Sep 17 00:00:00 2001
From: Arthri <41360489+Arthri@users.noreply.github.com>
Date: Fri, 1 Mar 2024 19:40:02 +0800
Subject: [PATCH] Add Cranial Hypertrichosis (Hair Grow Symptom) (#23969)
* Add Cranial Hypertrichosis
* Apply suggestions from code review
Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>
* Early return
* Apply suggestions from code review
Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>
* Add stage 2
* Apply suggestions from code review
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
* Don't affect bald species
* Fix formatting
* Revert invalid syntax
---------
Co-authored-by: Arthri <41360489+a@users.noreply.github.com>
Co-authored-by: Henri215 <77684085+Henri215@users.noreply.github.com>
Co-authored-by: Luc <89928798+lewcc@users.noreply.github.com>
---
code/datums/diseases/advance/symptoms/hair.dm | 49 +++++++++++++++++++
paradise.dme | 1 +
2 files changed, 50 insertions(+)
create mode 100644 code/datums/diseases/advance/symptoms/hair.dm
diff --git a/code/datums/diseases/advance/symptoms/hair.dm b/code/datums/diseases/advance/symptoms/hair.dm
new file mode 100644
index 00000000000..60419bd5b25
--- /dev/null
+++ b/code/datums/diseases/advance/symptoms/hair.dm
@@ -0,0 +1,49 @@
+/*
+//////////////////////////////////////
+Cranial Hypertrichosis
+
+ Very very Noticeable.
+ Decreases resistance slightly.
+ Decreases stage speed.
+ Reduced transmittability
+ Intense Level.
+
+BONUS
+ Makes the mob grow massive hair, regardless of gender.
+
+//////////////////////////////////////
+*/
+
+/datum/symptom/hair
+ name = "Cranial Hypertrichosis"
+ stealth = -3
+ resistance = -1
+ stage_speed = -3
+ transmittable = -1
+ level = 4
+ severity = 1
+
+/datum/symptom/hair/Activate(datum/disease/advance/A)
+ ..()
+ if(prob(SYMPTOM_ACTIVATION_PROB))
+ if(!ishuman(A.affected_mob))
+ return
+ var/mob/living/carbon/human/H = A.affected_mob
+ if(H.dna.species.bodyflags & BALD)
+ return
+ var/obj/item/organ/external/head/head_organ = H.get_organ("head")
+ if(!istype(head_organ))
+ return
+ switch(A.stage)
+ if(1, 2, 3)
+ to_chat(H, "Your scalp itches.")
+ head_organ.h_style = random_hair_style(H.gender, head_organ.dna.species.name)
+ else
+ to_chat(H, "Hair bursts forth from your scalp!")
+ var/datum/sprite_accessory/tmp_hair_style = GLOB.hair_styles_full_list["Very Long Hair"]
+
+ if(head_organ.dna.species.name in tmp_hair_style.species_allowed) //If 'Very Long Hair' is a style the person's species can have, give it to them.
+ head_organ.h_style = "Very Long Hair"
+ else //Otherwise, give them a random hair style.
+ head_organ.h_style = random_hair_style(H.gender, head_organ.dna.species.name)
+ H.update_hair()
diff --git a/paradise.dme b/paradise.dme
index 66918f06b5c..10fded4cabf 100644
--- a/paradise.dme
+++ b/paradise.dme
@@ -446,6 +446,7 @@
#include "code\datums\diseases\advance\symptoms\fever.dm"
#include "code\datums\diseases\advance\symptoms\fire.dm"
#include "code\datums\diseases\advance\symptoms\flesh_eating.dm"
+#include "code\datums\diseases\advance\symptoms\hair.dm"
#include "code\datums\diseases\advance\symptoms\hallucigen.dm"
#include "code\datums\diseases\advance\symptoms\headache.dm"
#include "code\datums\diseases\advance\symptoms\heal.dm"