mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 10:21:11 +00:00
Remove mob references in destroy()
Let's get going on that mob qdeletion
This commit is contained in:
@@ -107,6 +107,7 @@
|
||||
following = null
|
||||
ghostMulti = null
|
||||
canclone = null
|
||||
observers.Remove(src)
|
||||
|
||||
/mob/dead/observer/hasFullAccess()
|
||||
return isAdminGhost(src)
|
||||
|
||||
@@ -17,24 +17,32 @@ var/global/obj/screen/fuckstat/FUCK = new
|
||||
|
||||
/mob/Destroy() // This makes sure that mobs with clients/keys are not just deleted from the game.
|
||||
unset_machine()
|
||||
qdel(hud_used)
|
||||
if(mind && mind.current == src)
|
||||
spellremove(src)
|
||||
if(client)
|
||||
for(var/obj/screen/movable/spell_master/spell_master in spell_masters)
|
||||
returnToPool(spell_master)
|
||||
spell_masters = null
|
||||
spells = null
|
||||
remove_screen_obj_references()
|
||||
for(var/atom/movable/AM in client.screen)
|
||||
var/obj/screen/screenobj = AM
|
||||
if(istype(screenobj) && screenobj.pool_on_reset())
|
||||
if(istype(screenobj))
|
||||
if(screenobj.pool_on_reset())
|
||||
returnToPool(AM)
|
||||
else
|
||||
qdel(AM)
|
||||
client.screen = list()
|
||||
if(mind && mind.current == src)
|
||||
spellremove(src)
|
||||
mob_list.Remove(src)
|
||||
dead_mob_list.Remove(src)
|
||||
living_mob_list.Remove(src)
|
||||
ghostize()
|
||||
//Fuck datums amirite
|
||||
click_delayer = null
|
||||
attack_delayer = null
|
||||
special_delayer = null
|
||||
gui_icons = null
|
||||
qdel(hud_used)
|
||||
..()
|
||||
|
||||
/mob/proc/remove_screen_obj_references()
|
||||
|
||||
Reference in New Issue
Block a user