-
Notifications
You must be signed in to change notification settings - Fork 0
/
cl.lua
38 lines (33 loc) · 1.03 KB
/
cl.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
Citizen.CreateThread(function()
local fpsnowpg = false
while true do
Citizen.Wait(10)
DisableControlAction(0, 0, true)
if IsDisabledControlJustReleased(0, 0) and PuFGGs.JUST_2_VIEW_MODE then
if fpsnowpg then
ChangeView(4)
fpsnowpg = false
else
ChangeView(0)
fpsnowpg = true
end
end
if IsPedSittingInAnyVehicle(PlayerPedId()) and PuFGGs.FPS_MODE_DRIVEBY then
if IsPedDoingDriveby(PlayerPedId()) then
ChangeView(4)
fpsnowpg = true
end
end
if PuFGGs.FPS_MODE_ONFOOT then
local aiming, targetPed = GetEntityPlayerIsFreeAimingAt(PlayerId())
if aiming then
ChangeView(4)
fpsnowpg = true
end
end
end
end)
function ChangeView(value)
SetFollowPedCamViewMode(value)
SetFollowVehicleCamViewMode(value)
end