Hello,
Im trying to do my own script to skinchange. Hair cut is updated but not the color.
If someone know why ill appreciate to get some help. He is my code:
RegisterNUICallback("changeHair", function(data, cb)
cb({})
local playerPed = PlayerPedId()
local hair = data.hair
local hairColor = data.hairColor
print(hairColor)
SetPedComponentVariation(playerPed, 2, tonumber(hair), 0, 2)
SetPedHairColor(playerPed, tonumber(hairColor), tonumber(hairColor))
Citizen.Wait(1)
end)
The only thing done before is to set freemode ped (like online) to player.
Im printing hair and hairColor and values a equals to my ui