From c949b059f2b65a02a1dbfe4ab92166f327d6f9e6 Mon Sep 17 00:00:00 2001 From: skoglol <33292112+kriskog@users.noreply.github.com> Date: Sat, 26 Oct 2019 01:35:57 +0200 Subject: [PATCH] Fixes pointing at something in darkness/past walls (#47379) * Fixes pointing in darkness/past walls * stray whitespace --- code/modules/mob/dead/observer/observer.dm | 16 ++++++++-------- code/modules/mob/living/living.dm | 2 +- code/modules/mob/mob.dm | 2 +- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index 15326723722..98160769baa 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -601,31 +601,31 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp var/mob/living/target = input("Your new life begins today!", "Possess Mob", null, null) as null|anything in sortNames(possessible) if(!target) - return 0 + return FALSE if(ismegafauna(target)) to_chat(src, "This creature is too powerful for you to possess!") - return 0 + return FALSE if(can_reenter_corpse && mind && mind.current) if(alert(src, "Your soul is still tied to your former life as [mind.current.name], if you go forward there is no going back to that life. Are you sure you wish to continue?", "Move On", "Yes", "No") == "No") - return 0 + return FALSE if(target.key) to_chat(src, "Someone has taken this body while you were choosing!") - return 0 + return FALSE target.key = key target.faction = list("neutral") - return 1 + return TRUE //this is a mob verb instead of atom for performance reasons //see /mob/verb/examinate() in mob.dm for more info //overridden here and in /mob/living for different point span classes and sanity checks -/mob/dead/observer/pointed(atom/A as mob|obj|turf in view()) +/mob/dead/observer/pointed(atom/A as mob|obj|turf in view(client.view, src)) if(!..()) - return 0 + return FALSE usr.visible_message("[src] points to [A].") - return 1 + return TRUE /mob/dead/observer/verb/view_manifest() set name = "View Crew Manifest" diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm index 7faa6904d60..ff0508d1b7e 100644 --- a/code/modules/mob/living/living.dm +++ b/code/modules/mob/living/living.dm @@ -367,7 +367,7 @@ stop_pulling() //same as above -/mob/living/pointed(atom/A as mob|obj|turf in view()) +/mob/living/pointed(atom/A as mob|obj|turf in view(client.view, src)) if(incapacitated()) return FALSE if(HAS_TRAIT(src, TRAIT_DEATHCOMA)) diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm index f401fe5667e..c3abb12a270 100644 --- a/code/modules/mob/mob.dm +++ b/code/modules/mob/mob.dm @@ -439,7 +439,7 @@ set name = "Point To" set category = "Object" - if(!src || !isturf(src.loc) || !(A in view(src.loc))) + if(!src || !isturf(src.loc) || !(A in view(client.view, src))) return FALSE if(istype(A, /obj/effect/temp_visual/point)) return FALSE