Command problem
#1

I kind of forgot how to do this:

But at my command:
If you used that the rank is higher then 10 it should return a message that you can't do it higher then 10.

pawn Код:
COMMAND:spr(playerid,params[])
{
    new rank;
    if(PlayerInfo[playerid][pFrank] <9) return SendClientMessage(playerid,COLOR_GREY,"You have to be rank 9+ in a faction to use this command.");
    if(sscanf(params,"ud",id,rank)) return SendClientMessage(playerid,COLOR_GREY,"USAGE: /spr [playerid] [factionrank]");
    if(!IsPlayerConnected(id)) return SendClientMessage(playerid,COLOR_GREY,"This player is not connected");
   
    return 1;
}
I tried like: if(rank) and then I got stuck xD
Reply
#2

pawn Код:
if(rank > 10) return SendClientMessage(playerid,COLOR_GREY,"The rank cannot be higher than 10!");
Reply
#3

Ah yes. Thankyou.
Sorry for this lame questions xD
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)