[HELP] How to lock a certain skin id to a player's name?
#1

As the title says. I've been looking around for this but I can't find anything.

Thanks!
Reply
#2

When the player tries to request a skin, run a loop through all online players to see if somebody else is using that skin.
Reply
#3

Give this a try, change my name to your name or someone elses name

pawn Код:
public OnPlayerRequestSpawn(playerid)
{
    new skin = GetPlayerSkin(playerid);
   
    new name[24];
    GetPlayerName(playerid,name,24);
   
    if(skin == 294) // if they request to spawn with skin 294 (woozie)
    {
        if(strcmp(name, "grandTheftOtto", true) == 1) // checking if grandTheftOtto is the name
        {
            return SendClientMessage(playerid,-1,"Welcome Back grandTheftOtto, Enjoy Your Skin!");
        }
        else // if the name isn't grandTheftOtto , the spawn will fail
        {
            return SendClientMessage(playerid,-1,"Spawn Failed. This Skin Is Reserved For grandTheftOtto!");
        }
    }
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)