From 830d5c4d61b37b6a0bb3199ea818c1c1b6f9d46c Mon Sep 17 00:00:00 2001 From: Nemanja <71012671+NeMyOriginal@users.noreply.github.com> Date: Sat, 2 Apr 2022 12:54:25 +0200 Subject: [PATCH] Disabling camera use in car There is bug when you are in car and trying to use camera, whole car moving when you zoom or rotate.. --- client.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/client.lua b/client.lua index bf6f37e..7fd8c23 100644 --- a/client.lua +++ b/client.lua @@ -106,6 +106,9 @@ function HandleZoom(cam) end RegisterNetEvent("wert-camera:client:use-camera", function() + if IsPedInAnyVehicle(PlayerPedId(), false) then + ESX.ShowNotification('You can`t use camera in car!') + else if not active then active = true @@ -181,6 +184,7 @@ RegisterNetEvent("wert-camera:client:use-camera", function() end) else FullClose() + end end end)