Skip to content

Commit

Permalink
fix(client): load current data (#13)
Browse files Browse the repository at this point in the history
  • Loading branch information
mockdot authored Sep 22, 2023
1 parent aaaaafd commit c2e9b8f
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions client.lua
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,10 @@ RegisterNetEvent("QBCore:Client:OnPlayerLoaded", function()
Wait(2000)
local hudSettings = GetResourceKvpString('hudSettings')
if hudSettings then loadSettings(json.decode(hudSettings)) end
stress = PlayerData.metadata.stress
hunger = PlayerData.metadata.hunger
thirst = PlayerData.metadata.thirst
hp = PlayerData.metadata.health
end)

AddEventHandler('onResourceStart', function(resourceName)
Expand Down

0 comments on commit c2e9b8f

Please sign in to comment.