Merge pull request #654 from Citadel-Station-13/upstream-merge-26662

[MIRROR] Status effects are actually deleted/handled when the mob is deleted
This commit is contained in:
LetterJay
2017-05-01 07:59:55 -05:00
committed by GitHub
2 changed files with 12 additions and 3 deletions

View File

@@ -29,6 +29,13 @@
med_hud_set_status()
/mob/living/Destroy()
if(LAZYLEN(status_effects))
for(var/s in status_effects)
var/datum/status_effect/S = s
if(S.on_remove_on_mob_delete) //the status effect calls on_remove when its mob is deleted
qdel(S)
else
S.be_replaced()
if(ranged_ability)
ranged_ability.remove_ranged_ability(src)
if(buckled)