mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-09-01 21:01:49 +00:00
Freeze object to sync client view
This commit is contained in:
@@ -42,6 +42,7 @@ Citizen.CreateThread(function()
|
||||
for k,v in pairs(objects) do
|
||||
local obj = GetClosestObjectOfType(GetEntityCoords(ped).x, GetEntityCoords(ped).y, GetEntityCoords(ped).z, 3.0, GetHashKey(v), false, true ,true)
|
||||
local dist = GetDistanceBetweenCoords(GetEntityCoords(ped), GetEntityCoords(obj), true)
|
||||
FreezeEntityPosition(obj, false)
|
||||
table.insert(list, {object = obj, distance = dist})
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user