For the complete documentation index, see llms.txt. This page is also available as Markdown.

Client

All client-side events, triggers, and exports for rcore_clothing.


Events

onClothingShopOpened

Fires before the clothing shop UI opens.

AddEventHandler('rcore_clothing:onClothingShopOpened', function()
    -- do something before shop opens
end)
onClothingShopClosed

Fires after the clothing shop UI closes.

AddEventHandler('rcore_clothing:onClothingShopClosed', function()
    -- do something after shop closes
end)
afterSkinLoaded

Fires when the player's skin is applied - on spawn or after /reloadskin.

AddEventHandler('rcore_clothing:afterSkinLoaded', function()
    -- do something after skin is loaded
end)
charcreator:done

Fires when the player completes the character creator.

AddEventHandler('rcore_clothing:charcreator:done', function()
    -- do something after character creator is finished
end)
onItemPurchase

Fires when a player buys a clothing item.


Triggers

reapplyDecorations

Re-applies clothing decorations. The script already preserves non-clothing decorations when clearing, so this is rarely needed.

reloadSkin

Reloads the player's skin from the database.

saveCurrentSkin

Saves the player's current skin to the database.

openChangingRoom

Shows the player's purchased clothes and saved outfits.

openClothingShopWithEverythingAndFree

Opens a shop with all items available for free. Intended for admins.

openShop

Opens a specific clothing shop for the player.

openJobChangingRoom

Opens a job changing room. Outfits must be created first using the Outfit Editor.


Exports

getSkinByIdentifier

Returns the saved skin data for a player identifier.

getPlayerSkin

Returns the player's current skin. Set includeCharacter to true to include face, hair, etc.

setPlayerSkin

Applies a skin to the player. Set forceReload to true to respawn the ped.

setPedSkin

Applies a skin to any ped.

fixArms

Attempts to set the correct arm model for the player's current top. Not 100% accurate, but handles most cases.

getPlayerClothing

Returns only clothing data (no character features). The result can be passed to setPedSkin.

Last updated