fix(cache): ped not triggering update event

This commit is contained in:
Linden
2022-03-02 02:28:10 +00:00
parent 6b8b7990c8
commit cdc7523146

View File

@@ -1,12 +1,5 @@
local cache = {}
function cache:getPed()
local ped = PlayerPedId()
if ped ~= self.ped then
self.ped = ped
end
end
function cache:getVehicle()
local vehicle = GetVehiclePedIsIn(self.ped, false)
if vehicle > 0 then
@@ -51,7 +44,7 @@ end
CreateThread(function()
while true do
cache:getPed()
cache:set('ped', PlayerPedId())
cache:getVehicle()
-- if not cache.vehicle then