diff --git a/code/modules/admin/topic.dm b/code/modules/admin/topic.dm index 35b8b4dc4ac..fd347bc9d52 100644 --- a/code/modules/admin/topic.dm +++ b/code/modules/admin/topic.dm @@ -1722,20 +1722,24 @@ show_player_panel(M) else if(href_list["adminplayerobservefollow"]) + if(isnewplayer(usr)) + to_chat(usr, "You cannot follow anyone from the lobby!") + return + var/client/C = usr.client if(!isobserver(usr)) - if(!check_rights(R_ADMIN|R_MOD)) // Need to be mod or admin to aghost + if(!check_rights(R_ADMIN|R_MOD, show_msg=FALSE)) // Need to be mod or admin to aghost + to_chat(usr, "You must be an observer to follow someone!") return C.admin_ghost() - var/mob/M = locateUID(href_list["adminplayerobservefollow"]) - if(!ismob(M)) + var/mob/target = locateUID(href_list["adminplayerobservefollow"]) + if(!ismob(target)) to_chat(usr, "This can only be used on instances of type /mob") return - var/mob/dead/observer/A = C.mob - sleep(2) - A.ManualFollow(M) + var/mob/dead/observer/ghost = C.mob + ghost.ManualFollow(target) else if(href_list["check_antagonist"]) check_antagonists() diff --git a/code/modules/mob/dead/observer/observer_base.dm b/code/modules/mob/dead/observer/observer_base.dm index 13f5400772b..ce88be67df6 100644 --- a/code/modules/mob/dead/observer/observer_base.dm +++ b/code/modules/mob/dead/observer/observer_base.dm @@ -540,8 +540,8 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp set desc = "Orbits the specified movable atom." set category = null - // this usr check is apparently necessary for security - if(!isobserver(usr)) + // this check is apparently necessary for security + if(!isobserver(src)) return return do_manual_follow(target)