Performance improvements

This commit is contained in:
ElPumpo
2018-09-20 22:45:00 +02:00
parent c07cdde7c8
commit 810949fe09
3 changed files with 60 additions and 57 deletions
+4 -5
View File
@@ -251,17 +251,16 @@ end)
RegisterServerEvent('esx:updateLoadout')
AddEventHandler('esx:updateLoadout', function(loadout)
local xPlayer = ESX.GetPlayerFromId(source)
xPlayer.loadout = loadout
local xPlayer = ESX.GetPlayerFromId(source)
xPlayer.loadout = loadout
end)
RegisterServerEvent('esx:updateLastPosition')
AddEventHandler('esx:updateLastPosition', function(position)
local xPlayer = ESX.GetPlayerFromId(source)
xPlayer.lastPosition = position
local xPlayer = ESX.GetPlayerFromId(source)
xPlayer.lastPosition = position
end)
RegisterServerEvent('esx:giveInventoryItem')
AddEventHandler('esx:giveInventoryItem', function(target, type, itemName, itemCount)
local _source = source