/removescore
#1

Hello Guys i have make a /givescore Command that works, but i dont know how to make a /removescore Command, here the /givescore Command, with Adminvariable/Adminquery

Код:
COMMAND:givescore(playerid,params[])
 {
    new id;
    new level;
    if(sscanf(params,"dd",id,level)) return SendClientMessage(playerid,COLOR_YELLOW,"Usage: /givescore [id] [score]");
    if(PlayerAdmin[playerid] < 4) return SendClientMessage(playerid,COLOR_RED,"You cannot use this Command!");
    SetPlayerScore(id,GetPlayerScore(id)+level);
    return 1;
      }
Reply
#2

pawn Код:
CMD:removescore(playerid, params[])
{
    new gid, level;
    if(sscanf(params, "ud", gid, level)) return SendClientMessage(playerid, COLOR_YELOW,"Usage: /removescore [id] [score]");
    if(PlayerAdmin[playerid] < 4) return SendClientMessage(playerid,COLOR_RED,"You cannot use this Command!");
    SetPlayerScore(gid, GetPlayerScore(gid)-level);
    return 1;
}
Reply
#3

Work, thx.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)