forked from Simnation/Main
14 lines
378 B
Lua
14 lines
378 B
Lua
![]() |
RegisterNetEvent('QBCore:Client:OnPlayerLoaded', function()
|
||
|
client.onPlayerLoad(true)
|
||
|
end)
|
||
|
|
||
|
RegisterNetEvent('QBCore:Client:OnPlayerUnload', function()
|
||
|
client.onPlayerLoad(false)
|
||
|
end)
|
||
|
|
||
|
-- Checks if the player is logged in based on local player state
|
||
|
---@return boolean isLoggedIn
|
||
|
function client.IsPlayerLoaded()
|
||
|
return LocalPlayer.state.isLoggedIn
|
||
|
end
|