1// Initializing ESX and PlayerData
2ESX = nil
3playerData = nil
4Citizen.CreateThread(function()
5 while ESX == nil do
6 TriggerEvent('esx:getSharedObject', function(obj) ESX = obj end)
7 Citizen.Wait(0)
8 end
9 playerData = ESX.GetPlayerData()
10end)