From 43e1f040203c5ccd60af51c03a8c5865c5010ebd Mon Sep 17 00:00:00 2001 From: Will <7099514+Willburd@users.noreply.github.com> Date: Sat, 30 May 2026 20:14:33 -0400 Subject: [PATCH] Cleanup A Remote View Proc (#19493) * remove bad arguments * fix that * Fixed order --- code/datums/components/remote_view.dm | 8 ++++---- code/datums/remote_view_config.dm | 3 ++- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/code/datums/components/remote_view.dm b/code/datums/components/remote_view.dm index 3b5594a2c5a..d7e6dad073e 100644 --- a/code/datums/components/remote_view.dm +++ b/code/datums/components/remote_view.dm @@ -114,6 +114,10 @@ if(settings.use_zoom_hud && !host_mob.hud_used.hud_shown) host_mob.toggle_zoom_hud() + // Unregister remaining signals + // to_chat(world, "======================================== ENDED VIEW on: [remote_view_target]") + . = ..() + // Update the mob's vision right away if it still exists if(!QDELETED(host_mob) && host_mob.client) settings.detatch_from_mob(src, host_mob) @@ -123,10 +127,6 @@ host_mob.handle_vision() host_mob.handle_regular_hud_updates() - // Unregister remaining signals - // to_chat(world, "======================================== ENDED VIEW on: [remote_view_target]") - . = ..() - // Finish cleanup QDEL_NULL(settings) host_mob = null diff --git a/code/datums/remote_view_config.dm b/code/datums/remote_view_config.dm index 3da56ab9b19..6d505a8caa9 100644 --- a/code/datums/remote_view_config.dm +++ b/code/datums/remote_view_config.dm @@ -88,8 +88,9 @@ return /// Handles relayed movement during a remote view. Override this in a subtype to handle specialized logic. If it returns true, the mob will not move, allowing you to handle remotely controlled movement. -/datum/remote_view_config/proc/handle_relay_movement(datum/component/remote_view/owner_component, mob/host_mob, datum/coordinator, atom/movable/remote_view_target, direction) +/datum/remote_view_config/proc/handle_relay_movement(datum/component/remote_view/owner_component, mob/host_mob, direction) SIGNAL_HANDLER + var/atom/remote_view_target = owner_component.get_target() return remote_view_target.relaymove(host_mob, direction) /// Handles visual changes to mob's hud or flags when in use, it is fired every life tick.