mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-29 17:28:53 +00:00
41 lines
860 B
Lua
41 lines
860 B
Lua
function ESX.Streaming.RequestModel(model)
|
|
local modelHash = GetHashKey(model)
|
|
|
|
if not HasModelLoaded(modelHash) then
|
|
RequestModel(modelHash)
|
|
|
|
while not HasModelLoaded(modelHash) do
|
|
Citizen.Wait(1)
|
|
end
|
|
end
|
|
end
|
|
|
|
function ESX.Streaming.RequestStreamedTextureDict(textureDict)
|
|
if not HasStreamedTextureDictLoaded(textureDict) then
|
|
RequestStreamedTextureDict(textureDict)
|
|
|
|
while not HasStreamedTextureDictLoaded(textureDict) do
|
|
Citizen.Wait(1)
|
|
end
|
|
end
|
|
end
|
|
|
|
function ESX.Streaming.RequestAnimSet(animSet)
|
|
if not HasAnimSetLoaded(animSet) then
|
|
RequestAnimSet(animSet)
|
|
|
|
while not HasAnimSetLoaded(animSet) do
|
|
Citizen.Wait(1)
|
|
end
|
|
end
|
|
end
|
|
|
|
function ESX.Streaming.RequestAnimDict(animDict)
|
|
if not HasAnimDictLoaded(animDict) then
|
|
RequestAnimDict(animDict)
|
|
|
|
while not HasAnimDictLoaded(animDict) do
|
|
Citizen.Wait(1)
|
|
end
|
|
end
|
|
end |