Convert all traits given by status effects to use TRAIT_STATUS_EFFECT(id) (#89291)

## About The Pull Request

This makes (almost?) all traits given by status effects use
`TRAIT_STATUS_EFFECT(id)` as their source, rather than the previous mix
of `id`, `type`, `REF(src)`, or some bespoke thing.

## Why It's Good For The Game

Consistency is good.

## Changelog

No user-facing changes
This commit is contained in:
Lucy
2025-02-01 21:21:44 +01:00
committed by GitHub
parent 90eccb203e
commit 851c5a5df9
29 changed files with 90 additions and 93 deletions
@@ -32,7 +32,7 @@
/datum/status_effect/shapechange_mob/on_apply()
caster_mob.mind?.transfer_to(owner)
caster_mob.forceMove(owner)
ADD_TRAIT(caster_mob, TRAIT_NO_TRANSFORM, REF(src))
ADD_TRAIT(caster_mob, TRAIT_NO_TRANSFORM, TRAIT_STATUS_EFFECT(id))
caster_mob.apply_status_effect(/datum/status_effect/grouped/stasis, STASIS_SHAPECHANGE_EFFECT)
RegisterSignal(owner, COMSIG_LIVING_PRE_WABBAJACKED, PROC_REF(on_pre_wabbajack))
@@ -86,7 +86,7 @@
UnregisterSignal(owner, list(COMSIG_LIVING_PRE_WABBAJACKED, COMSIG_LIVING_DEATH))
UnregisterSignal(caster_mob, list(COMSIG_QDELETING, COMSIG_LIVING_DEATH))
REMOVE_TRAIT(caster_mob, TRAIT_NO_TRANSFORM, REF(src))
REMOVE_TRAIT(caster_mob, TRAIT_NO_TRANSFORM, TRAIT_STATUS_EFFECT(id))
caster_mob.remove_status_effect(/datum/status_effect/grouped/stasis, STASIS_SHAPECHANGE_EFFECT)
var/atom/former_loc = owner.loc