Skip to content

Commit

Permalink
Merge pull request #1453 from esx-framework/1.11-hotfix
Browse files Browse the repository at this point in the history
fix(esx_skin): always use latest Ped Id
  • Loading branch information
Arctos2win authored Nov 11, 2024
2 parents 47a3054 + 7697e14 commit 5d5f14a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
1 change: 0 additions & 1 deletion [core]/es_extended/client/modules/actions.lua
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@ function Actions:TrackPed()
ESX.SetPlayerData("ped", playerPed)

TriggerEvent("esx:playerPedChanged", playerPed)
TriggerServerEvent("esx:playerPedChanged", PedToNet(playerPed))
end
end

Expand Down
4 changes: 1 addition & 3 deletions [core]/es_extended/shared/config/main.lua
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Config = {}

-- for ox inventory, use Config.CustomInventory = "ox", for others, set to "resource_name"
Config.CustomInventory = false

Config.Accounts = {
Expand Down Expand Up @@ -53,9 +54,6 @@ Config.AdminLogging = false -- Logs the usage of certain commands by those with
-- DO NOT CHANGE BELOW THIS LINE UNLESS YOU KNOW WHAT YOU ARE DOING
--------------------------------------------------------------------
Config.EnableDefaultInventory = Config.CustomInventory == false -- Display the default Inventory ( F2 )
if GetResourceState("ox_inventory") ~= "missing" then
Config.CustomInventory = "ox"
end

local txAdminLocale = GetConvar("txAdmin-locale", "en")
local esxLocale = GetConvar("esx:locale", "invalid")
Expand Down
4 changes: 2 additions & 2 deletions [core]/esx_skin/client/modules/camera.lua
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function Camera:PositionLoop()
while self.cam do
self:DisableContols()

local ped = ESX.PlayerData.ped or PlayerPedId()
local ped = PlayerPedId()
local coords = GetEntityCoords(ped)

local pos, posToLook = Skin:CalcuatePosition(coords)
Expand All @@ -59,7 +59,7 @@ function Camera:Create()
return
end

local playerPed = ESX.PlayerData.ped or PlayerPedId()
local playerPed = PlayerPedId()
local playerCoords = GetEntityCoords(playerPed)

self.cam = CreateCam("DEFAULT_SCRIPTED_CAMERA", true)
Expand Down
2 changes: 1 addition & 1 deletion [core]/esx_skin/client/modules/menu.lua
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ function Menu:Restrict()
end

function Menu:InsertElements()
local playerPed = ESX.PlayerData.ped or PlayerPedId()
local playerPed = PlayerPedId()

for i = 1, #self.components, 1 do
local value = self.components[i].value
Expand Down

0 comments on commit 5d5f14a

Please sign in to comment.