mirror of
https://github.com/qbcore-fivem/qb-core.git
synced 2026-08-28 17:01:16 +00:00
is logged in
This commit is contained in:
committed by
GitHub
parent
1013a14b37
commit
07b2107898
+3
-3
@@ -1,7 +1,7 @@
|
||||
CreateThread(function()
|
||||
while true do
|
||||
Wait(0)
|
||||
if LocalPlayer.state['isLoggedIn'] then
|
||||
if LocalPlayer.state.isLoggedIn then
|
||||
Wait((1000 * 60) * QBCore.Config.UpdateInterval)
|
||||
TriggerServerEvent('QBCore:UpdatePlayer')
|
||||
end
|
||||
@@ -11,7 +11,7 @@ end)
|
||||
CreateThread(function()
|
||||
while true do
|
||||
Wait(QBCore.Config.StatusInterval)
|
||||
if LocalPlayer.state['isLoggedIn'] then
|
||||
if LocalPlayer.state.isLoggedIn then
|
||||
if QBCore.Functions.GetPlayerData().metadata['hunger'] <= 0 or
|
||||
QBCore.Functions.GetPlayerData().metadata['thirst'] <= 0 then
|
||||
local ped = PlayerPedId()
|
||||
@@ -20,4 +20,4 @@ CreateThread(function()
|
||||
end
|
||||
end
|
||||
end
|
||||
end)
|
||||
end)
|
||||
|
||||
Reference in New Issue
Block a user