Admin Ghostdrop sanity checks

Applies tgstation/-tg-station@2227b7a to admin.dm and observer.dm

Basically, this adds sanity checks, just to prevent runtimes in the odd
case that something happens. For instance, if one of the mobs suddenly
gets deleted, this will prevent it from runtiming. Sanity checks.
This commit is contained in:
Tigercat2000
2015-04-15 07:11:34 -07:00
parent f6d4aae74a
commit b7377185d9
2 changed files with 7 additions and 0 deletions
@@ -489,6 +489,7 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
//this is called when a ghost is drag clicked to something.
/mob/dead/observer/MouseDrop(atom/over)
if(!usr || !over) return
if (isobserver(usr) && usr.client && usr.client.holder && isliving(over))
if (usr.client.holder.cmd_ghost_drag(src,over))
return