mirror of
https://github.com/esx-framework/esx_core.git
synced 2026-08-29 01:08:54 +00:00
fix(client/main): Spawning fix with new characters
This commit is contained in:
+3
-3
@@ -118,10 +118,10 @@ if ESX.GetConfig().Multichar then
|
||||
end
|
||||
|
||||
LoadPed = function(isNew)
|
||||
local skin = Characters[Spawned].skin
|
||||
if isNew or not skin or #skin == 1 then
|
||||
local char = Characters[Spawned]
|
||||
if isNew or not char.skin or #char.skin == 1 then
|
||||
local isMale, sex = true, 0
|
||||
if Characters[Spawned].sex == 'Female' then isMale, sex = false, 1 end
|
||||
if char and char.sex == 'Female' then isMale, sex = false, 1 end
|
||||
TriggerEvent('skinchanger:loadDefaultModel', isMale, function()
|
||||
skin = Config.Default
|
||||
skin.sex = sex
|
||||
|
||||
Reference in New Issue
Block a user