Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Research major property rebalance #6225

Merged
merged 82 commits into from
May 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
82 commits
Select commit Hold shift + click to select a range
4d1511c
Update Chemistry-Generator.dm
iloveloopers May 1, 2024
e8bf8f6
Update other.dm
iloveloopers May 1, 2024
73e887f
Update other.dm
iloveloopers May 1, 2024
2b60b53
Update other.dm
iloveloopers May 1, 2024
d334f6c
Update prop_negative.dm
iloveloopers May 1, 2024
cc2b222
Update prop_special.dm
iloveloopers May 1, 2024
2bdea43
Update prop_neutral.dm
iloveloopers May 1, 2024
62feeee
Update chem_property.dm
iloveloopers May 1, 2024
04175d1
Update chem_simulator.dm
iloveloopers May 1, 2024
72dac27
Update prop_positive.dm
iloveloopers May 1, 2024
270565a
Update prop_positive.dm
iloveloopers May 1, 2024
44b134e
Update Chemistry-Reagents.dm
iloveloopers May 1, 2024
1a1bf6e
Update prop_positive.dm
iloveloopers May 1, 2024
42e46a2
Merge branch 'cmss13-devs:master' into property_rebalance
iloveloopers May 5, 2024
90fd74c
Update prop_special.dm
iloveloopers May 5, 2024
5d03de2
Merge branch 'master' into property_rebalance
iloveloopers May 13, 2024
08913d0
Update prop_positive.dm
iloveloopers May 18, 2024
a30ff95
Update prop_positive.dm
iloveloopers May 18, 2024
fc5b03a
Update chemsmoke.dm
iloveloopers May 21, 2024
8a10ee5
Update chemsmoke.dm
iloveloopers May 21, 2024
88be7b8
Merge branch 'master' into property_rebalance
iloveloopers May 21, 2024
19e9ff2
slightly better now
iloveloopers May 21, 2024
0a2cbd4
way too punishing
iloveloopers May 21, 2024
39bdf21
why was it like this anyways?
iloveloopers May 22, 2024
eb3ea3b
Update flamer.dm
iloveloopers May 22, 2024
e428ff7
Update prop_special.dm
iloveloopers May 22, 2024
020625d
Update chemsmoke.dm
iloveloopers May 22, 2024
fedf7fa
Update prop_special.dm
iloveloopers May 22, 2024
46b7b2e
Update prop_positive.dm
iloveloopers May 22, 2024
8f528b1
Update Chemistry-Generator.dm
iloveloopers May 22, 2024
e67016b
Update flamer.dm
iloveloopers May 22, 2024
21929fa
Merge branch 'master' into property_rebalance
iloveloopers May 22, 2024
9eecef0
Merge branch 'master' into property_rebalance
iloveloopers May 22, 2024
bc53b3b
Update say.dm
iloveloopers May 22, 2024
eae6d67
Update xeno_verbs.dm
iloveloopers May 22, 2024
f3bb6df
Update prop_positive.dm
iloveloopers May 23, 2024
e493245
Merge branch 'master' into property_rebalance
iloveloopers May 23, 2024
184dba5
Update flamer.dm
iloveloopers May 23, 2024
3a1387d
Merge branch 'cmss13-devs:master' into property_rebalance
iloveloopers May 23, 2024
0682c53
Update XenoProcs.dm
iloveloopers May 23, 2024
7ffdace
Update Xenomorph.dm
iloveloopers May 23, 2024
325ced4
Update life.dm
iloveloopers May 23, 2024
336825e
Update XenoProcs.dm
iloveloopers May 23, 2024
51aae0e
Update life.dm
iloveloopers May 23, 2024
7838616
Update XenoProcs.dm
iloveloopers May 23, 2024
a51c704
Update life.dm
iloveloopers May 23, 2024
e1e1d5f
Update Xenomorph.dm
iloveloopers May 23, 2024
cdea9a2
Update colonialmarines.dme
iloveloopers May 24, 2024
b46d704
Add files via upload
iloveloopers May 24, 2024
f2e3e2f
Update toxin_buildup.dm
iloveloopers May 24, 2024
ef1da7c
Update speed_modifier.dm
iloveloopers May 24, 2024
3f3aa72
Update healing_reduction.dm
iloveloopers May 24, 2024
e2ed294
Update XenoProcs.dm
iloveloopers May 24, 2024
f59bef5
Update XenoProcs.dm
iloveloopers May 24, 2024
20b7835
Update life.dm
iloveloopers May 24, 2024
cb8702f
Update Xenomorph.dm
iloveloopers May 24, 2024
4daf778
Update XenoProcs.dm
iloveloopers May 24, 2024
48d4e5b
Update fruit.dm
iloveloopers May 24, 2024
bd3ac08
Update prop_negative.dm
iloveloopers May 24, 2024
0f1955a
Update prop_positive.dm
iloveloopers May 24, 2024
4445ac8
Update prop_special.dm
iloveloopers May 24, 2024
0cb7ebc
Update pistol.dm
iloveloopers May 24, 2024
b220a54
Update revolver.dm
iloveloopers May 24, 2024
d4826dc
Update rifle.dm
iloveloopers May 24, 2024
feabd1a
Update smg.dm
iloveloopers May 24, 2024
6aeac91
Update prop_positive.dm
iloveloopers May 24, 2024
8999e2e
Merge branch 'master' into property_rebalance
iloveloopers May 24, 2024
33f2003
vsc test
iloveloopers May 24, 2024
1f41ea6
interference component and stuff
iloveloopers May 25, 2024
ac5d94f
Merge remote-tracking branch 'upstream/master' into property_rebalance
iloveloopers May 25, 2024
9062b75
quick fix
iloveloopers May 25, 2024
cc24c32
Apply suggestions from code review
iloveloopers May 25, 2024
5b376bc
test
iloveloopers May 25, 2024
91b6f0d
overwatch fix and interference overflow fix
iloveloopers May 25, 2024
2294031
Reduce awareness spam if immune while getting applied
Drulikar May 25, 2024
39aad11
grace period rework + overwatch fix
iloveloopers May 25, 2024
6f42d04
grace period buff
iloveloopers May 26, 2024
f54ce55
Merge branch 'master' into property_rebalance
iloveloopers May 26, 2024
ece7e03
daze component + some touch ups
iloveloopers May 26, 2024
3f45704
Merge remote-tracking branch 'upstream/master' into property_rebalance
iloveloopers May 26, 2024
be392c6
Update code/modules/mob/living/carbon/xenomorph/XenoOverwatch.dm
iloveloopers May 28, 2024
f50fbd1
true
iloveloopers May 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions code/__DEFINES/dcs/signals/atom/mob/living/signals_xeno.dm
Original file line number Diff line number Diff line change
Expand Up @@ -78,3 +78,6 @@
/// From /mob/living/carbon/xenomorph/proc/hivemind_talk(): (message)
#define COMSIG_XENO_TRY_HIVEMIND_TALK "xeno_try_hivemind_talk"
#define COMPONENT_OVERRIDE_HIVEMIND_TALK (1<<0)

/// used in /datum/component/status_effect/cleanse()
#define COMSIG_XENO_DEBUFF_CLEANSE "xeno_debuff_cleanse"
5 changes: 5 additions & 0 deletions code/__DEFINES/traits.dm
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,8 @@
// HIVE TRAITS
/// If the Hive is a Xenonid Hive
#define TRAIT_XENONID "t_xenonid"
/// if the xeno's connection to the hivemind is cut
#define TRAIT_HIVEMIND_INTERFERENCE "t_interference"
/// If the hive or xeno can use objects.
#define TRAIT_OPPOSABLE_THUMBS "t_thumbs"
/// If the Hive delays round end (this is overridden for some hives). Does not occur naturally. Must be applied in events.
Expand Down Expand Up @@ -355,6 +357,7 @@ GLOBAL_LIST_INIT(traits_by_type, list(
"TRAIT_ABILITY_NO_PLASMA_TRANSFER" = TRAIT_ABILITY_NO_PLASMA_TRANSFER,
"TRAIT_ABILITY_OVIPOSITOR" = TRAIT_ABILITY_OVIPOSITOR,
"TRAIT_OPPOSABLE_THUMBS" = TRAIT_OPPOSABLE_THUMBS,
"TRAIT_INTERFERENCE" = TRAIT_HIVEMIND_INTERFERENCE,
),
/datum/hive_status = list(
"TRAIT_XENONID" = TRAIT_XENONID,
Expand Down Expand Up @@ -434,6 +437,8 @@ GLOBAL_LIST(trait_name_map)
#define TRAIT_SOURCE_TEMPORARY_MUTE "t_s_temporary_mute"
///Status trait forced by the xeno action charge
#define TRAIT_SOURCE_XENO_ACTION_CHARGE "t_s_xeno_action_charge"
///Status trait coming from hivemind interference
#define TRAIT_SOURCE_HIVEMIND_INTERFERENCE "t_s_hivemind_interference"
///Status trait coming from a xeno nest
#define XENO_NEST_TRAIT "xeno_nest"
///Status trait from a generic throw by xeno abilities
Expand Down
4 changes: 2 additions & 2 deletions code/datums/ammo/bullet/pistol.dm
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@

/datum/ammo/bullet/pistol/ap/toxin/on_hit_mob(mob/M, obj/projectile/P)
. = ..()
M.AddComponent(/datum/component/toxic_buildup, acid_per_hit)
M.AddComponent(/datum/component/status_effect/toxic_buildup, acid_per_hit)

/datum/ammo/bullet/pistol/ap/toxin/on_hit_turf(turf/T, obj/projectile/P)
. = ..()
Expand Down Expand Up @@ -194,7 +194,7 @@

/datum/ammo/bullet/pistol/squash/toxin/on_hit_mob(mob/M, obj/projectile/P)
. = ..()
M.AddComponent(/datum/component/toxic_buildup, acid_per_hit)
M.AddComponent(/datum/component/status_effect/toxic_buildup, acid_per_hit)

/datum/ammo/bullet/pistol/squash/toxin/on_hit_turf(turf/T, obj/projectile/P)
. = ..()
Expand Down
2 changes: 1 addition & 1 deletion code/datums/ammo/bullet/revolver.dm
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@

/datum/ammo/bullet/revolver/marksman/toxin/on_hit_mob(mob/M, obj/projectile/P)
. = ..()
M.AddComponent(/datum/component/toxic_buildup, acid_per_hit)
M.AddComponent(/datum/component/status_effect/toxic_buildup, acid_per_hit)

/datum/ammo/bullet/revolver/marksman/toxin/on_hit_turf(turf/T, obj/projectile/P)
. = ..()
Expand Down
2 changes: 1 addition & 1 deletion code/datums/ammo/bullet/rifle.dm
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@

/datum/ammo/bullet/rifle/ap/toxin/on_hit_mob(mob/M, obj/projectile/P)
. = ..()
M.AddComponent(/datum/component/toxic_buildup, acid_per_hit)
M.AddComponent(/datum/component/status_effect/toxic_buildup, acid_per_hit)

/datum/ammo/bullet/rifle/ap/toxin/on_hit_turf(turf/T, obj/projectile/P)
. = ..()
Expand Down
2 changes: 1 addition & 1 deletion code/datums/ammo/bullet/smg.dm
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@

/datum/ammo/bullet/smg/ap/toxin/on_hit_mob(mob/M, obj/projectile/P)
. = ..()
M.AddComponent(/datum/component/toxic_buildup, acid_per_hit)
M.AddComponent(/datum/component/status_effect/toxic_buildup, acid_per_hit)

/datum/ammo/bullet/smg/ap/toxin/on_hit_turf(turf/T, obj/projectile/P)
. = ..()
Expand Down
2 changes: 1 addition & 1 deletion code/datums/ammo/energy.dm
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@
if(isxeno(hit_mob))
var/mob/living/carbon/xenomorph/xeno = hit_mob
xeno.apply_damage(damage * 0.75, BURN)
xeno.interference = 30
xeno.AddComponent(/datum/component/status_effect/interference, 30, 30)

/datum/ammo/energy/yautja/rifle/bolt/set_bullet_traits()
. = ..()
Expand Down
27 changes: 18 additions & 9 deletions code/datums/components/healing_reduction.dm
Original file line number Diff line number Diff line change
Expand Up @@ -7,21 +7,21 @@ Healing above this strength will be reduced by the strength of the buildup.
Humans will take continuous damage instead.
*/

/datum/component/healing_reduction
/datum/component/status_effect/healing_reduction
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
var/healing_reduction = 0
var/healing_reduction_dissipation = AMOUNT_PER_TIME(1, 5 SECONDS)
var/max_buildup = 50 //up to 50 damage off of healing max by default

/datum/component/healing_reduction/Initialize(healing_reduction, healing_reduction_dissipation = AMOUNT_PER_TIME(1, 2.5 SECONDS), max_buildup = 50)
/datum/component/status_effect/healing_reduction/Initialize(healing_reduction, healing_reduction_dissipation = AMOUNT_PER_TIME(1, 2.5 SECONDS), max_buildup = 50)
if(!isxeno_human(parent))
return COMPONENT_INCOMPATIBLE
. = ..()
src.healing_reduction = healing_reduction
src.healing_reduction_dissipation = healing_reduction_dissipation
src.max_buildup = max_buildup

/datum/component/healing_reduction/InheritComponent(datum/component/healing_reduction/inherit_component, i_am_original, healing_reduction)
/datum/component/status_effect/healing_reduction/InheritComponent(datum/component/status_effect/healing_reduction/inherit_component, i_am_original, healing_reduction)
. = ..()
if(!inherit_component)
src.healing_reduction += healing_reduction
Expand All @@ -30,7 +30,12 @@ Humans will take continuous damage instead.

src.healing_reduction = min(src.healing_reduction, max_buildup)

/datum/component/healing_reduction/process(delta_time)
/datum/component/status_effect/healing_reduction/process(delta_time)
var/atom/parent_atom = parent
if(has_immunity)
parent_atom.remove_filter("healing_reduction")
return ..()

if(!parent)
qdel(src)
return
Expand All @@ -49,18 +54,17 @@ Humans will take continuous damage instead.
var/intensity = healing_reduction/max_buildup
color += num2text(MAX_ALPHA*intensity, 2, 16)

var/atom/parent_atom = parent
parent_atom.add_filter("healing_reduction", 2, list("type" = "outline", "color" = color, "size" = 1))

/datum/component/healing_reduction/RegisterWithParent()
/datum/component/status_effect/healing_reduction/RegisterWithParent()
START_PROCESSING(SSdcs, src)
RegisterSignal(parent, list(
COMSIG_XENO_ON_HEAL,
COMSIG_XENO_ON_HEAL_WOUNDS
), PROC_REF(apply_healing_reduction))
RegisterSignal(parent, COMSIG_XENO_APPEND_TO_STAT, PROC_REF(stat_append))

/datum/component/healing_reduction/UnregisterFromParent()
/datum/component/status_effect/healing_reduction/UnregisterFromParent()
STOP_PROCESSING(SSdcs, src)
UnregisterSignal(parent, list(
COMSIG_XENO_ON_HEAL,
Expand All @@ -70,12 +74,17 @@ Humans will take continuous damage instead.
var/atom/parent_atom = parent
parent_atom.remove_filter("healing_reduction")

/datum/component/healing_reduction/proc/stat_append(mob/target_mob, list/stat_list)
/datum/component/status_effect/healing_reduction/proc/stat_append(mob/target_mob, list/stat_list)
SIGNAL_HANDLER
if(has_immunity)
stat_list += "Healing Reduction Immunity: [grace_period]/[initial(grace_period)]"
return
stat_list += "Healing Reduction: [healing_reduction]/[max_buildup]"

/datum/component/healing_reduction/proc/apply_healing_reduction(mob/living/carbon/xenomorph/xeno, list/healing)
/datum/component/status_effect/healing_reduction/proc/apply_healing_reduction(mob/living/carbon/xenomorph/xeno, list/healing)
SIGNAL_HANDLER
if(has_immunity)
return
healing["healing"] -= healing_reduction

#undef MAX_ALPHA
Expand Down
29 changes: 19 additions & 10 deletions code/datums/components/speed_modifier.dm
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,14 @@

//Adjusts the speed of a xenomorph the component is on. Humans will take or heal stamina damage.

/datum/component/speed_modifier
/datum/component/status_effect/speed_modifier
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
var/speed_modifier = 0
var/speed_modifier_dissipation = AMOUNT_PER_TIME(1, 2.5 SECONDS)
var/max_buildup = 10
var/increase_speed = FALSE

/datum/component/speed_modifier/Initialize(speed_modifier, increase_speed = FALSE, speed_modifier_dissipation = AMOUNT_PER_TIME(1, 2.5 SECONDS), max_buildup = 10)
/datum/component/status_effect/speed_modifier/Initialize(speed_modifier, increase_speed = FALSE, speed_modifier_dissipation = AMOUNT_PER_TIME(1, 2.5 SECONDS), max_buildup = 10)
if(!isxeno_human(parent))
return COMPONENT_INCOMPATIBLE
. = ..()
Expand All @@ -19,7 +19,7 @@
src.max_buildup = max_buildup
src.increase_speed = increase_speed

/datum/component/speed_modifier/InheritComponent(datum/component/speed_modifier/C, i_am_original, speed_modifier)
/datum/component/status_effect/speed_modifier/InheritComponent(datum/component/status_effect/speed_modifier/C, i_am_original, speed_modifier)
. = ..()
if(!C)
src.speed_modifier += speed_modifier
Expand All @@ -28,7 +28,12 @@

src.speed_modifier = min(src.speed_modifier, max_buildup)

/datum/component/speed_modifier/process(delta_time)
/datum/component/status_effect/speed_modifier/process(delta_time)
var/atom/parent_atom = parent
if(has_immunity)
parent_atom.remove_filter("speed_modifier")
return ..()

if(!parent)
qdel(src)
speed_modifier = max(speed_modifier - speed_modifier_dissipation * delta_time, 0)
Expand All @@ -47,15 +52,14 @@
var/intensity = speed_modifier/max_buildup
color += num2text(MAX_ALPHA*intensity, 2, 16)

var/atom/A = parent
A.add_filter("speed_modifier", 2, list("type" = "outline", "color" = color, "size" = 1))
parent_atom.add_filter("speed_modifier", 2, list("type" = "outline", "color" = color, "size" = 1))

/datum/component/speed_modifier/RegisterWithParent()
/datum/component/status_effect/speed_modifier/RegisterWithParent()
START_PROCESSING(SSdcs, src)
RegisterSignal(parent, COMSIG_XENO_MOVEMENT_DELAY, PROC_REF(apply_speed_modifier))
RegisterSignal(parent, COMSIG_XENO_APPEND_TO_STAT, PROC_REF(stat_append))

/datum/component/speed_modifier/UnregisterFromParent()
/datum/component/status_effect/speed_modifier/UnregisterFromParent()
STOP_PROCESSING(SSdcs, src)
UnregisterSignal(parent, list(
COMSIG_XENO_MOVEMENT_DELAY,
Expand All @@ -64,15 +68,20 @@
var/atom/A = parent
A.remove_filter("speed_modifier")

/datum/component/speed_modifier/proc/stat_append(mob/M, list/L)
/datum/component/status_effect/speed_modifier/proc/stat_append(mob/M, list/L)
SIGNAL_HANDLER
if(has_immunity)
L += "Slow immunity: [grace_period]/[initial(grace_period)]"
return
if(!increase_speed)
L += "Slow: [speed_modifier]/[max_buildup]"
else
L += "Speed Boost: [speed_modifier]/[max_buildup]"

/datum/component/speed_modifier/proc/apply_speed_modifier(mob/living/carbon/xenomorph/X, list/speeds)
/datum/component/status_effect/speed_modifier/proc/apply_speed_modifier(mob/living/carbon/xenomorph/X, list/speeds)
SIGNAL_HANDLER
if(has_immunity)
return
if(!increase_speed)
speeds["speed"] += speed_modifier * 0.075
else //increasing speed is more effective than decreasing speed
Expand Down
23 changes: 23 additions & 0 deletions code/datums/components/status_effect_component.dm
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
//exists only to handle immunities for now

/datum/component/status_effect
var/has_immunity = FALSE
var/grace_period = 30

/datum/component/status_effect/InheritComponent(datum/component/C, i_am_original)
if(has_immunity)
grace_period = min(grace_period + 1, initial(grace_period))

/datum/component/status_effect/Initialize()
. = ..()
RegisterSignal(parent, list(COMSIG_XENO_DEBUFF_CLEANSE, COMSIG_LIVING_REJUVENATED), PROC_REF(cleanse))

/datum/component/status_effect/proc/cleanse()
SIGNAL_HANDLER
has_immunity = TRUE

/datum/component/status_effect/process(delta_time)
if(has_immunity)
grace_period -= 1 * delta_time
if(grace_period <= 0)
qdel(src)
30 changes: 20 additions & 10 deletions code/datums/components/toxin_buildup.dm
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/datum/component/toxic_buildup
/datum/component/status_effect/toxic_buildup
dupe_mode = COMPONENT_DUPE_UNIQUE_PASSARGS
var/toxic_buildup = 0
var/toxic_buildup_dissipation = AMOUNT_PER_TIME(5, 10 SECONDS)
Expand All @@ -7,13 +7,14 @@
var/max_alpha = 35
var/glow_color = "#00ff00"

/datum/component/toxic_buildup/Initialize(toxic_buildup, toxic_buildup_dissipation = AMOUNT_PER_TIME(1, 3 SECONDS), max_buildup = 75)
/datum/component/status_effect/toxic_buildup/Initialize(toxic_buildup, toxic_buildup_dissipation = AMOUNT_PER_TIME(1, 3 SECONDS), max_buildup = 75)
. = ..()
src.toxic_buildup = toxic_buildup
src.toxic_buildup_dissipation = toxic_buildup_dissipation
src.max_buildup = max_buildup
to_chat(parent, SPAN_XENOHIGHDANGER("The toxic substance damages our armor!"))

/datum/component/toxic_buildup/InheritComponent(datum/component/toxic_buildup/C, i_am_original, toxic_buildup)
/datum/component/status_effect/toxic_buildup/InheritComponent(datum/component/status_effect/toxic_buildup/C, i_am_original, toxic_buildup)
. = ..()
if(!C)
src.toxic_buildup += toxic_buildup
Expand All @@ -22,7 +23,12 @@

src.toxic_buildup = min(src.toxic_buildup, max_buildup)

/datum/component/toxic_buildup/process(delta_time)
/datum/component/status_effect/toxic_buildup/process(delta_time)
var/atom/parent_atom = parent
if(has_immunity)
parent_atom.remove_filter("toxic_buildup")
return ..()

toxic_buildup = max(toxic_buildup - toxic_buildup_dissipation * delta_time, 0)

if(ishuman(parent))
Expand All @@ -37,18 +43,17 @@
color += num2text(max_alpha*intensity, 2, 16)

if(parent)
var/atom/A = parent
A.add_filter("toxic_buildup", 2, list("type" = "outline", "color" = color, "size" = 1))
parent_atom.add_filter("toxic_buildup", 2, list("type" = "outline", "color" = color, "size" = 1))

/datum/component/toxic_buildup/RegisterWithParent()
/datum/component/status_effect/toxic_buildup/RegisterWithParent()
START_PROCESSING(SSdcs, src)
RegisterSignal(parent, list(
COMSIG_XENO_PRE_CALCULATE_ARMOURED_DAMAGE_PROJECTILE,
COMSIG_XENO_PRE_APPLY_ARMOURED_DAMAGE
), PROC_REF(apply_toxic_buildup))
RegisterSignal(parent, COMSIG_XENO_APPEND_TO_STAT, PROC_REF(stat_append))

/datum/component/toxic_buildup/UnregisterFromParent()
/datum/component/status_effect/toxic_buildup/UnregisterFromParent()
STOP_PROCESSING(SSdcs, src)
UnregisterSignal(parent, list(
COMSIG_XENO_PRE_CALCULATE_ARMOURED_DAMAGE_PROJECTILE,
Expand All @@ -58,10 +63,15 @@
var/atom/A = parent
A.remove_filter("toxic_buildup")

/datum/component/toxic_buildup/proc/stat_append(mob/M, list/L)
/datum/component/status_effect/toxic_buildup/proc/stat_append(mob/M, list/L)
SIGNAL_HANDLER
if(has_immunity)
L += "Toxin Buildup immunity [grace_period]/[initial(grace_period)]"
return
L += "Toxin Buildup: [toxic_buildup]/[max_buildup]"

/datum/component/toxic_buildup/proc/apply_toxic_buildup(mob/living/carbon/xenomorph/X, list/damagedata)
/datum/component/status_effect/toxic_buildup/proc/apply_toxic_buildup(mob/living/carbon/xenomorph/X, list/damagedata)
SIGNAL_HANDLER
if(has_immunity)
return
damagedata["armor"] = max(damagedata["armor"] - toxic_buildup, 0)
Loading
Loading