From 1d1305a6689804beef8db9025bf6764f640066d6 Mon Sep 17 00:00:00 2001 From: Armored-Dragon Date: Fri, 15 Sep 2023 14:40:50 -0500 Subject: [PATCH] Fix away-enabled causing unsynchronised behavior --- scripts/system/controllers/mouseLook.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/system/controllers/mouseLook.js b/scripts/system/controllers/mouseLook.js index 7b867bb336..6d1b2d4367 100644 --- a/scripts/system/controllers/mouseLook.js +++ b/scripts/system/controllers/mouseLook.js @@ -191,6 +191,12 @@ by rampa3 (https://github.com/rampa3) and vegaslon (https://github.com/vegaslon) } } + Messages.messageReceived.connect(onMessageReceived); + function onMessageReceived(channel, message, sender, localOnly) { + if (channel === "Hifi-Away-Enable") + if (message === 'enable') mouseLookOn(); + } + Script.scriptEnding.connect(onScriptEnding); function onScriptEnding() {