ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Shared functions
  3. getPlayerClothesAll

Function

getPlayerClothesAll

Server and clientClothesTrilogy Hub only

Returns the player's whole outfit set by scripts: a part -> { texture, model, color, name } table.

Syntax

table getPlayerClothesAll(player thePlayer)

Arguments

thePlayerplayer
The player.

Returns

A { [part] = { texture, model, color, name } } table or false.

Example

Saving the player's outfit to the account data.

addEventHandler("onPlayerQuit", root, function()
    local account = getPlayerAccount(source)
    if not isGuestAccount(account) then
        setAccountData(account, "stroj", toJSON(getPlayerClothesAll(source)))
    end
end)

See also