Command to change skin
#4

pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
    if(strcmp(cmdtext, "/changeskin", true, 11) == 0)
    {
        new string[128], skinid;
        if(!cmdtext[11]) return SendClientMessage(playerid, COLOR, "Usage: /changeskin [skinid]");
        skinid = strval(cmdtext[12]);
        switch(skinid)
        {
            case 3, 4, 5, 6, 8, 42, 65, 74, 86, 119, 149, 208, 268, 273, 289: { return SendClientMessage(playerid, COLOR, "Error: invalid skin ID!"); }
            default:
            {
                SetPlayerSkin(playerid, skinid);
                format(string, sizeof(string), "You have successfully changed your skin to %d", skinid);
                SendClientMessage(playerid, COLOR, string);
            }
        }
        return 1;
    }
    return 0;
}
Reply


Messages In This Thread
Command to change skin - by Aram555 - 17.01.2010, 02:48
Re: Command to change skin - by Miguel - 17.01.2010, 03:00
Re: Command to change skin - by Kostas' - 25.09.2011, 13:15
Re: Command to change skin - by dice7 - 25.09.2011, 13:30
Re: Command to change skin - by Kostas' - 25.09.2011, 15:08
Re: Command to change skin - by MA_proking - 25.09.2011, 16:53
Re: Command to change skin - by Kostas' - 25.09.2011, 18:27
Re: Command to change skin - by Kingunit - 25.09.2011, 18:37
Re: Command to change skin - by Kostas' - 25.09.2011, 19:12
Re: Command to change skin - by SantarioLeone - 26.09.2011, 01:31

Forum Jump:


Users browsing this thread: 6 Guest(s)