23.07.2009, 06:37
i made this script:
but i still get errors i dont know what the script problem somebody can help me?
Код:
if(strcmp(cmd, "/cs", true) == 0) { if(IsPlayerConnected(playerid)) { new index = 0; tmp = strtok(params, index); new skin; if(PlayerInfo[playerid][pAdmin] < 2) { if(!strlen(tmp) || !IsNumeric(tmp) || IsInvalidSkin(skin)) { SendClientMessage(playerid, COLOR_GRAD2, "Correct usage: '/cs [skinid]'"); return 1; } if(skin > 299 || skin < 0) { SendClientMessage(playerid, COLOR_GRAD2, "Pick a skin from 0-299."); return 1; } skin = strval(tmp); SetPlayerSkin(playerid, skin); SendClientMessage(playerid, COLOR_GRAD2, "Skin changed."); return 1; } else { SendClientMessage(playerid, COLOR_GRAD1, " You are not authorized to use that command!"); } return 1; }