note Help Needed
This wiki is the result of an ongoing community effort — thank you all for helping!
If you want to provide changes to this page then please click here.
GetPlayerSkin
Description
Returns the class of the players skin
Name | Description |
---|---|
playerid | The player you want to get the skin from |
Returns
The skin id.
0 if invalid.
Examples
public OnPlayerCommandText(playerid, cmdtext[])
{
if (!strcmp(cmdtext, "/myskin", true))
{
new string[32];
new playerSkin = GetPlayerSkin(playerid);
format(string, sizeof(string), "Your skin id: %d", playerSkin);
SendClientMessage(playerid, -1, string);
return 1;
}
return 0;
}
Notes
tip
Returns the new skin after SetSpawnInfo is called but before the player actually respawns to get the new skin. Returns the old skin if the player was spawned through SpawnPlayer function.
Related Functions
- SetPlayerSkin: Set a player's skin.