From 466fc559f416acec481580b707f9b78effe5d423 Mon Sep 17 00:00:00 2001 From: Petr Mikheev Date: Thu, 30 Jun 2022 11:25:36 +0200 Subject: [PATCH] Fix move360.lua switching to 3rd person view when it shouldn't --- files/data/scripts/omw/camera/move360.lua | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/files/data/scripts/omw/camera/move360.lua b/files/data/scripts/omw/camera/move360.lua index 5247c03a30..08b0fe29d6 100644 --- a/files/data/scripts/omw/camera/move360.lua +++ b/files/data/scripts/omw/camera/move360.lua @@ -59,7 +59,12 @@ function M.onFrame(dt) end function M.onInputAction(action) - if not active or core.isWorldPaused() then return end + if not active or core.isWorldPaused() or + not input.getControlSwitch(input.CONTROL_SWITCH.ViewMode) or + not input.getControlSwitch(input.CONTROL_SWITCH.Controls) or + not I.Camera.isModeControlEnabled() then + return + end if action == input.ACTION.ZoomIn and camera.getMode() == MODE.Preview and I.Camera.getBaseThirdPersonDistance() == 30 then self.controls.yawChange = camera.getYaw() - self.rotation.z