if(strcmp(cmd, "/setskin", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GOLD, "USAGE: /setskin [playerid/PartOfName] [skin id]");
return 1;
}
new para1;
new level;
para1 = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
level = strval(tmp);
if(level > 299 || level < 1) { SendClientMessage(playerid, COLOR_GROVE, "Wrong ID"); return 1; }
if (PlayerInfo[playerid][pAdmin] >= 1)
{
if(IsPlayerConnected(para1))
{
if(para1 != INVALID_PLAYER_ID)
{
GetPlayerName(para1, giveplayer, sizeof(giveplayer));
GetPlayerName(playerid, sendername, sizeof(sendername));
PlayerInfo[para1][pChar] = level;
format(string, sizeof(string), "Your skin was changed by admin %s", sendername);
SendClientMessage(para1, COLOR_GOLD, string);
format(string, sizeof(string), "You gived %s skin %d.", giveplayer,level);
SendClientMessage(playerid, COLOR_GOLD, string);
SetPlayerSkin(para1, PlayerInfo[para1][pChar]);
}
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " You are not autorized to use this command");
}
}
return 1;
}
if(strcmp(cmdtext, "/skin", true) == 0)
{
ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT, "Skin ID Selection", "Please type the Skin ID [0-299]", "Select", "Cancel");
return 1;
}
You guys got to be fuckin serious can you guys search or just dumb?
https://sampforum.blast.hk/showthread.php?tid=106274 https://sampforum.blast.hk/showthread.php?tid=225082 https://sampforum.blast.hk/showthread.php?tid=225082 |