Exports
Every export of the appearance script, with its arguments, return value and an example
11 min read ยท Updated Dec 3, 2026
Customization
startPlayerCustomization
Opens the customization window with the parts you choose.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
callback | function | Yes | Called with the new appearance table when the player saves, or nil when they cancel. |
config | table | Yes | Which parts are shown, see below. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:startPlayerCustomization(function(appearance)
if appearance then
TriggerServerEvent('illenium-appearance:server:saveAppearance', appearance)
end
end, {
ped = false,
headBlend = false,
faceFeatures = false,
headOverlays = true,
components = true,
componentConfig = { masks = true, upperBody = true, lowerBody = true, bags = true, shoes = true,
scarfAndChains = true, bodyArmor = true, shirts = true, decals = true, jackets = true },
props = true,
propConfig = { hats = true, glasses = true, ear = true, watches = true, bracelets = true },
tattoos = false,
enableExit = true,
})
Good to know
- Nothing is charged or saved by itself: save in the callback, as in the example.
enableExit = falsemakes the player finish before leaving.
Fields of config
| Field | Type | Description |
|---|---|---|
ped | boolean | Model selection |
headBlend | boolean | Parents and skin |
faceFeatures | boolean | Face sliders |
headOverlays | boolean | Hair, beard, make up |
components | boolean | Clothes |
componentConfig | table | Which clothes: masks, upperBody, lowerBody, bags, shoes, scarfAndChains, bodyArmor, shirts, decals, jackets |
props | boolean | Accessories |
propConfig | table | Which accessories: hats, glasses, ear, watches, bracelets |
tattoos | boolean | Tattoos |
enableExit | boolean | The player can leave without saving |
Reading the look
getPedModel
Reads the model name of a ped.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
string: for example mp_m_freemode_01. nil when the model is not in the ped list of the config.
How to use it
local model = exports['illenium-appearance']:getPedModel(PlayerPedId())
getPedComponents
Reads the clothing components.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: a list of { component_id, drawable, texture } for the components 0 to 11.
How to use it
for _, part in ipairs(exports['illenium-appearance']:getPedComponents(PlayerPedId())) do
print(part.component_id, part.drawable, part.texture)
end
getPedProps
Reads the props (hat, glasses, ear, watch, bracelet).
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: a list of { prop_id, drawable, texture } for the props 0, 1, 2, 6 and 7. drawable is -1 when nothing is worn.
How to use it
local props = exports['illenium-appearance']:getPedProps(PlayerPedId())
getPedHeadBlend
Reads the parents and face mix.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: { shapeFirst, shapeSecond, shapeThird, skinFirst, skinSecond, skinThird, shapeMix, skinMix, thirdMix }.
How to use it
local blend = exports['illenium-appearance']:getPedHeadBlend(PlayerPedId())
getPedFaceFeatures
Reads the face sliders.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: the 20 features by name (noseWidth, eyesOpening, jawBoneWidth, ...), each a number with one decimal.
How to use it
local features = exports['illenium-appearance']:getPedFaceFeatures(PlayerPedId())
print(features.noseWidth)
getPedHeadOverlays
Reads beard, eyebrows, make up and the other overlays.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: by name (blemishes, beard, eyebrows, ageing, makeUp, blush, complexion, sunDamage, lipstick, moleAndFreckles, chestHair, bodyBlemishes), each { style, opacity, color, secondColor }.
How to use it
local overlays = exports['illenium-appearance']:getPedHeadOverlays(PlayerPedId())
print(overlays.beard.style)
getPedHair
Reads the hair.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: { style, color, highlight, texture }.
How to use it
local hair = exports['illenium-appearance']:getPedHair(PlayerPedId())
getPedAppearance
Reads the whole look, ready to be saved.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
Returns
table: { model, headBlend, faceFeatures, headOverlays, components, props, hair, tattoos, eyeColor }.
How to use it
local appearance = exports['illenium-appearance']:getPedAppearance(PlayerPedId())
Good to know
tattoosare those of the local player, whatever ped you pass.
Changing the look
These change what is on screen only. Nothing is saved to the database.
setPlayerModel
Changes the model of the local player.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
model | string or number | Yes | Model name or hash. |
Returns
number: the new ped entity. When the model does not exist nothing changes.
How to use it
local ped = exports['illenium-appearance']:setPlayerModel('mp_f_freemode_01')
Good to know
- It waits for the model to load, call it from a thread. The old ped handle is no longer valid and the tattoo list is cleared.
setPedHeadBlend
Sets the parents and face mix.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
headBlend | table | Yes | The table of getPedHeadBlend. |
Returns
Nothing.
How to use it
local ped = PlayerPedId()
local blend = exports['illenium-appearance']:getPedHeadBlend(ped)
blend.shapeMix = 0.5
exports['illenium-appearance']:setPedHeadBlend(ped, blend)
Good to know
- Only freemode peds.
setPedFaceFeatures
Sets the face sliders.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
faceFeatures | table | Yes | All 20 features, as returned by getPedFaceFeatures. |
Returns
Nothing.
How to use it
local ped = PlayerPedId()
local features = exports['illenium-appearance']:getPedFaceFeatures(ped)
features.noseWidth = 0.4
exports['illenium-appearance']:setPedFaceFeatures(ped, features)
Good to know
- Send the full table, a missing feature is an error.
setPedHeadOverlays
Sets the overlays.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
headOverlays | table | Yes | All 12 overlays, as returned by getPedHeadOverlays. |
Returns
Nothing.
How to use it
local ped = PlayerPedId()
local overlays = exports['illenium-appearance']:getPedHeadOverlays(ped)
overlays.beard = { style = 3, opacity = 1.0, color = 1, secondColor = 1 }
exports['illenium-appearance']:setPedHeadOverlays(ped, overlays)
Good to know
- Send the full table, a missing overlay is an error.
setPedHair
Sets the hair.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
hair | table | Yes | { style, color, highlight, texture }. |
tattoos | table | No | Tattoos to put back after the change, the current ones without it. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedHair(PlayerPedId(), { style = 5, texture = 0, color = 2, highlight = 4 })
setPedEyeColor
Sets the eye color.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
eyeColor | number | Yes | Index from 0 to 31. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedEyeColor(PlayerPedId(), 3)
setPedComponent
Sets one clothing component.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
component | table | Yes | { component_id, drawable, texture }. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedComponent(PlayerPedId(), { component_id = 11, drawable = 15, texture = 0 })
Good to know
- On freemode peds the components 0 (face) and 2 (hair) are ignored.
setPedComponents
Sets several clothing components.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
components | table | Yes | A list of { component_id, drawable, texture }. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedComponents(PlayerPedId(), {
{ component_id = 8, drawable = 15, texture = 0 },
{ component_id = 11, drawable = 15, texture = 0 },
})
setPedProp
Sets or removes one prop.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
prop | table | Yes | { prop_id, drawable, texture }. drawable = -1 removes it. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedProp(PlayerPedId(), { prop_id = 0, drawable = -1, texture = 0 })
setPedProps
Sets several props.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
props | table | Yes | A list of { prop_id, drawable, texture }. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedProps(PlayerPedId(), savedProps)
setPedTattoos
Replaces the tattoos.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
tattoos | table | Yes | Lists of tattoos by zone, each { name, collection, hashMale, hashFemale, opacity }. {} removes all. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedTattoos(PlayerPedId(), {})
setPedAppearance
Applies a saved look to a ped, without changing its model.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
ped | number | Yes | Ped entity, for the local player PlayerPedId(). |
appearance | table | Yes | The table of getPedAppearance. Missing parts are left as they are. |
Returns
Nothing.
How to use it
exports['illenium-appearance']:setPedAppearance(PlayerPedId(), appearance)
setPlayerAppearance
Changes the model of the local player and applies the whole look.
Side: Client
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
appearance | table | Yes | The table of getPedAppearance, with model. |
Returns
Nothing.
How to use it
-- try a look on for ten seconds
local before = exports['illenium-appearance']:getPedAppearance(PlayerPedId())
exports['illenium-appearance']:setPlayerAppearance(preset)
Wait(10000)
exports['illenium-appearance']:setPlayerAppearance(before)
Good to know
- It waits for the model to load, call it from a thread.
Old skinchanger exports (ESX)
On ESX the script answers the exports of skinchanger, so scripts written for it keep working. You do not need to change them. Use the exports above in new code.
GetSkin
Reads the saved appearance of the player.
Side: Client (ESX)
Arguments
None.
Returns
table: the saved appearance.
How to use it
local skin = exports.skinchanger:GetSkin()
LoadSkin
Applies an appearance.
Side: Client (ESX)
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
skin | table | Yes | An appearance with model. Without model the starting clothes are put on. |
Returns
Nothing.
How to use it
exports.skinchanger:LoadSkin(skin)
LoadClothes
Puts clothes in the old skinchanger format on the player.
Side: Client (ESX)
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
playerSkin | table | Yes | Not read. |
clothesSkin | table | Yes | Clothes in the skinchanger format (tshirt_1, torso_1, ...). |
Returns
Nothing.
How to use it
exports.skinchanger:LoadClothes(skin, { tshirt_1 = 15, tshirt_2 = 0 })