Skip to content

Commit

Permalink
refactor(client): release models
Browse files Browse the repository at this point in the history
  • Loading branch information
solareon authored Jun 24, 2024
1 parent 4ad4a22 commit 1caa786
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions client/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -381,6 +381,7 @@ local function setupGarageZone()
if config.useTarget then
lib.requestModel(`a_m_m_indian_01`)
taxiPed = CreatePed(3, `a_m_m_indian_01`, 894.93, -179.12, 74.7 - 1.0, 237.09, false, true)
SetModelAsNoLongerNeeded(`a_m_m_indian_01`)
SetBlockingOfNonTemporaryEvents(taxiPed, true)
FreezeEntityPosition(taxiPed, true)
SetEntityInvincible(taxiPed, true)
Expand Down Expand Up @@ -501,6 +502,7 @@ RegisterNetEvent('qb-taxi:client:DoTaxiNpc', function()
local model = GetHashKey(config.npcSkins[Gender][PedSkin])
lib.requestModel(model)
NpcData.Npc = CreatePed(3, model, sharedConfig.npcLocations.takeLocations[NpcData.CurrentNpc].x, sharedConfig.npcLocations.takeLocations[NpcData.CurrentNpc].y, sharedConfig.npcLocations.takeLocations[NpcData.CurrentNpc].z - 0.98, sharedConfig.npcLocations.takeLocations[NpcData.CurrentNpc].w, true, true)
SetModelAsNoLongerNeeded(model)
PlaceObjectOnGroundProperly(NpcData.Npc)
FreezeEntityPosition(NpcData.Npc, true)
if NpcData.NpcBlip ~= nil then
Expand Down

0 comments on commit 1caa786

Please sign in to comment.