FIX - stabilize camera movement and selfie view

This commit is contained in:
Leon.Schmidt
2026-08-16 00:49:24 +02:00
parent 2f70444071
commit b6679a5a7d
6 changed files with 259 additions and 82 deletions
+15 -1
View File
@@ -12,6 +12,7 @@ local active_call_payload = nil
local call_channel = 0
local nui_generation = 0
local activity_suspended = false
local movement_only_input = false
Bridge.Debug("debug", "[sky_phone] Client script initialized.", { always = true })
@@ -301,15 +302,28 @@ local function update_nui_focus()
payphone_focus = payphone_focus,
sim_picker_open = sim_picker_open,
})
SetNuiFocus(focus.focused, focus.focused)
SetNuiFocus(focus.focused, focus.cursor)
SetNuiFocusKeepInput(focus.keep_input)
movement_only_input = focus.movement_only
TriggerEvent("sky_phone:client:cameraFocusApplied", {
active = camera_active,
cursor = focus.cursor,
focused = focus.focused,
gameInput = focus.keep_input,
})
end
CreateThread(function()
while true do
if movement_only_input then
SkyPhoneFocus.ApplyMovementOnlyControls()
Wait(0)
else
Wait(250)
end
end
end)
AddEventHandler("sky_phone:client:setSuspended", function(suspended)
activity_suspended = suspended == true
update_nui_focus()