Yes. Try this:
pawn Код:
CMD:wlevel(playerid,params[]) {
if(PlayerInfo[playerid][Level] >= 3) {
new tmp[128], tmp2[128], Index; tmp = strtok(params,Index), tmp2 = strtok(params,Index);
if(isnull(tmp) || isnull(tmp2) || !IsNumeric(tmp2)) return SendClientMessage(playerid, red, "USAGE: /setwanted [playerid] [level]");
new player1 = strval(tmp), wanted = strval(tmp2), string[128];
// if(wanted > 6) return SendClientMessage(playerid, red, "ERROR: Invaild wanted level");
if(PlayerInfo[player1][Level] == ServerInfo[MaxAdminLevel] && PlayerInfo[playerid][Level] != ServerInfo[MaxAdminLevel]) return SendClientMessage(playerid,red,"ERROR: You cannot use this command on this admin");
if(IsPlayerConnected(player1) && player1 != INVALID_PLAYER_ID) {
format(string, sizeof(string), "You have set \"%s's\" wanted level to '%d", pName(player1), wanted); SendClientMessage(playerid,blue,string);
if(player1 != playerid) { format(string,sizeof(string),"Administrator \"%s\" has set your wanted level to '%d'", pName(playerid), wanted); SendClientMessage(player1,blue,string); }
return SetPlayerWantedLevel(player1, wanted);
} else return SendClientMessage(playerid,red,"ERROR: Player is not connected");
} else return SendClientMessage(playerid,red,"ERROR: You are not a high enough level to use this command");
}