fix(accessories): Add event handler for esx:playerLoaded

This commit is contained in:
Linden
2021-07-22 10:27:55 +10:00
parent 72e26d64e7
commit 1c0f806cda
@@ -2,6 +2,12 @@ local HasAlreadyEnteredMarker, isDead = false, false
local LastZone, CurrentAction, CurrentActionMsg
local CurrentActionData = {}
RegisterNetEvent('esx:playerLoaded')
AddEventHandler('esx:playerLoaded', function(xPlayer)
ESX.PlayerData = xPlayer
ESX.PlayerLoaded = true
end)
function OpenAccessoryMenu()
ESX.UI.Menu.Open('default', GetCurrentResourceName(), 'set_unset_accessory', {
title = _U('set_unset'),