diff --git a/[core]/es_extended/client/modules/actions.lua b/[core]/es_extended/client/modules/actions.lua index 455dcff0..1f495682 100644 --- a/[core]/es_extended/client/modules/actions.lua +++ b/[core]/es_extended/client/modules/actions.lua @@ -145,8 +145,18 @@ function Actions:SlowLoop() end) end +function Actions:PedTrackingLoop() + CreateThread(function() + while ESX.PlayerLoaded do + self:TrackPed() + Wait(0) + end + end) +end + function Actions:Init() self:SlowLoop() + self:PedTrackingLoop() end Actions:Init() diff --git a/[core]/skinchanger/client/main.lua b/[core]/skinchanger/client/main.lua index e28aee17..76d5d4f2 100644 --- a/[core]/skinchanger/client/main.lua +++ b/[core]/skinchanger/client/main.lua @@ -44,7 +44,7 @@ function SkinChanger:DefaultModel(male, cb) local model = self:RequestModel(characterModel) SetPlayerModel(PlayerId(), model) - SetPedDefaultComponentVariation(playerPed) + SetPedDefaultComponentVariation(PlayerPedId()) SetModelAsNoLongerNeeded(model)