From c3f0694bada18e68fc604e61846b537811d6e412 Mon Sep 17 00:00:00 2001
From: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
Date: Sat, 29 Jun 2024 13:54:39 -0400
Subject: [PATCH] Drask Traitor Item - Cryoregenerative Enhancer (#25885)
* Drask Traitor Item - Cryoregenerative Enhancer
* Removed extraneous list
Co-authored-by: CRUNCH <143041327+Fordoxia@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Better Math
Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Excessive spacing
Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Comment fix
Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Cleaner dna logic
Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Better lore
Co-authored-by: CRUNCH <143041327+Fordoxia@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* Better readability on checks
Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
* More noticable alert if empty.
Co-authored-by: CRUNCH <143041327+Fordoxia@users.noreply.github.com>
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
---------
Signed-off-by: PollardTheDragon <144391971+PollardTheDragon@users.noreply.github.com>
Co-authored-by: CRUNCH <143041327+Fordoxia@users.noreply.github.com>
Co-authored-by: Ryan <80364400+Sirryan2002@users.noreply.github.com>
Co-authored-by: 1080pCat <96908085+1080pCat@users.noreply.github.com>
Co-authored-by: DGamerL <108773801+DGamerL@users.noreply.github.com>
---
code/__HELPERS/trait_helpers.dm | 1 +
code/_globalvars/traits.dm | 1 +
code/datums/uplink_items/uplink_traitor.dm | 10 ++++++
.../objects/items/devices/traitordevices.dm | 34 +++++++++++++++++++
.../surgery/organs/organ_datums/lung_datum.dm | 2 ++
5 files changed, 48 insertions(+)
diff --git a/code/__HELPERS/trait_helpers.dm b/code/__HELPERS/trait_helpers.dm
index 3400bda3cc9..7ca2893038c 100644
--- a/code/__HELPERS/trait_helpers.dm
+++ b/code/__HELPERS/trait_helpers.dm
@@ -184,6 +184,7 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai
#define TRAIT_EMOTE_MUTE "emote_mute"
#define TRAIT_HYPOSPRAY_IMMUNE "hypospray_immune" // For making crew-accessable hyposprays not pierce your clothing
#define TRAIT_RSG_IMMUNE "rsgimmune" //prevents RSG syringes from piercing your clothing
+#define TRAIT_DRASK_SUPERCOOL "drask_supercool"
#define TRAIT_NO_BONES "no_bones"
#define TRAIT_STURDY_LIMBS "sturdy_limbs"
diff --git a/code/_globalvars/traits.dm b/code/_globalvars/traits.dm
index 21496f0d32a..3a6f5515078 100644
--- a/code/_globalvars/traits.dm
+++ b/code/_globalvars/traits.dm
@@ -50,6 +50,7 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_MESON_VISION" = TRAIT_MESON_VISION,
"TRAIT_FLASH_PROTECTION" = TRAIT_FLASH_PROTECTION,
"TRAIT_NIGHT_VISION" = TRAIT_NIGHT_VISION,
+ "TRAIT_DRASK_SUPERCOOL" = TRAIT_DRASK_SUPERCOOL,
"TRAIT_NO_BONES" = TRAIT_NO_BONES,
"TRAIT_STURDY_LIMBS" = TRAIT_STURDY_LIMBS,
diff --git a/code/datums/uplink_items/uplink_traitor.dm b/code/datums/uplink_items/uplink_traitor.dm
index 0ddf13c8cc5..55f955aa3f5 100644
--- a/code/datums/uplink_items/uplink_traitor.dm
+++ b/code/datums/uplink_items/uplink_traitor.dm
@@ -396,6 +396,16 @@
cost = 25 /// A fresh start, but a start with nothing. Hard to use as well
species = list("Grey")
+// Drask
+/datum/uplink_item/species_restricted/cryoregenerative_enhancer
+ name = "Cryoregenerative Enhancer"
+ desc = "Specially designed nanomachines that enhance the low-temperature regenerative capabilities of drask. Requires supercooled air in the enviroment or internals to function."
+ reference = "CRE"
+ item = /obj/item/cryoregenerative_enhancer
+ cost = 25
+ species = list("Drask")
+ surplus = 0
+
// -------------------------------------
// ITEMS BLACKLISTED FROM NUCLEAR AGENTS
// -------------------------------------
diff --git a/code/game/objects/items/devices/traitordevices.dm b/code/game/objects/items/devices/traitordevices.dm
index ca8e1e93b05..1d6bca8cf14 100644
--- a/code/game/objects/items/devices/traitordevices.dm
+++ b/code/game/objects/items/devices/traitordevices.dm
@@ -286,6 +286,40 @@
to_chat(user, "You inject yourself with the nanites!")
ADD_TRAIT(user, TRAIT_RESISTHEAT, "fireproof_injector")
+/obj/item/cryoregenerative_enhancer
+ name = "cryoregenerative enhancer"
+ desc = "Specially designed nanomachines that enhance the low-temperature regenerative capabilities of drask. Requires supercooled air in the enviroment or internals to function."
+ icon = 'icons/obj/hypo.dmi'
+ icon_state = "combat_hypo"
+ var/used = FALSE
+
+/obj/item/cryoregenerative_enhancer/examine_more(mob/user)
+ . = ..()
+ . += "Designed by Viim-vaarooomunnm's prestigious polytechnic university, these experimental nanomachines infiltrate the cells of the drask host and integrate into the specialised cryoregenerative organelles that facilitate low-temperature healing and work to boost enzymatic activity, massively improving the efficiency of the associated metabolic processes."
+ . += ""
+ . += "Clinical trials have shown a four times increase in the rate of healing compared to a placebo. Whilst the product is technically not yet available to the public, the right connections with the right people allow interested parties to obtain samples early..."
+
+/obj/item/cryoregenerative_enhancer/attack_self(mob/living/user)
+ if(HAS_TRAIT(user, TRAIT_DRASK_SUPERCOOL))
+ to_chat(user, "Your regeneration is already enhanced!")
+ return
+ if(user.mind && (IS_CHANGELING(user) || user.mind.has_antag_datum(/datum/antagonist/vampire)) || user.dna?.species.name != "Drask")
+ to_chat(user, "The injector is not compatable with your biology!")
+ return
+ if(used)
+ to_chat(user, "The injector is empty!")
+ return
+ var/choice = tgui_alert(user, "The injector is still unused. Do you wish to use it?", "Cryoregenerative enhancer", list("Yes", "No"))
+ if(choice != "Yes")
+ to_chat(user, "You decide against using [src].")
+ return
+ if(used)
+ to_chat(user, "The injector is empty!")
+ return
+ used = TRUE
+ to_chat(user, "You inject yourself with the enhancer!")
+ ADD_TRAIT(user, TRAIT_DRASK_SUPERCOOL, "cryoregenerative_enhancer")
+
/obj/item/batterer
name = "mind batterer"
desc = "A dangerous syndicate device focused on crowd control and escapes. Causes brain damage, confusion, and other nasty effects to those surrounding the user."
diff --git a/code/modules/surgery/organs/organ_datums/lung_datum.dm b/code/modules/surgery/organs/organ_datums/lung_datum.dm
index d02f8095904..1d012cee99f 100644
--- a/code/modules/surgery/organs/organ_datums/lung_datum.dm
+++ b/code/modules/surgery/organs/organ_datums/lung_datum.dm
@@ -249,6 +249,8 @@
TC = cold_level_1_damage
if(TC)
for(var/D in cold_damage_types)
+ if(HAS_TRAIT(H, TRAIT_DRASK_SUPERCOOL))
+ TC *= 4
H.apply_damage_type(TC * CM * cold_damage_types[D], D)
if(breath_temperature < cold_level_1_threshold)
if(prob(20))