1
0
Fork 0
forked from Simnation/Main
This commit is contained in:
Nordi98 2025-08-07 14:38:30 +02:00
parent 88ffeb3375
commit 87623c8379
27 changed files with 2865 additions and 1705 deletions

View file

@ -0,0 +1,20 @@
local AP_RESOURCE_NAME <const> = "AdvancedParking"
if (GetCurrentResourceName() == AP_RESOURCE_NAME) then return end
local IS_CLIENT <const> = not IsDuplicityVersion()
local AP <const> = exports[AP_RESOURCE_NAME]
-- replaces FreezeEntityPosition native on client and server side
local original_FreezeEntityPosition <const> = FreezeEntityPosition
FreezeEntityPosition = function(entity, freeze)
if (not DoesEntityExist(entity)) then return end
if (GetEntityType(entity) ~= 2 or (IS_CLIENT and not NetworkGetEntityIsNetworked(entity)) or GetResourceState(AP_RESOURCE_NAME) ~= "started" or not AP.FreezeVehicle) then
original_FreezeEntityPosition(entity, freeze)
return
end
AP:FreezeVehicle(entity, freeze)
end