Scripting Help
#6

@Rittik it have error:
Код:
error 001: expected token: ")", but found "{"
Error Line :
Код:
CMD:reward(playerid, params[])
{
  if(IsPlayerAdmin(playerid))
    {
      new id,score,cash;
      if(sscanf(params,"iii",id,cash,score)
      //This Line{
        SendClientMessage(playerid,-1,"/reward <id> <cash> <score>");
        return 1;
      }
      else
      {
       if(IsPlayerConnected(id))
       {
       GivePlayerMoney(id,cash);
       SetPlayerScore(id,GetPlayerScore(playerid)+score);
       }
       else
       {
       SendClientMessage(playerid,-1,"Player is not connected");
       return 1;
       }
      }
    }
    else
    {
    SendClientMessage(playerid,-1,"You need to be an Admin to use this command");
    return 1;
    }
    return 1;
}
Reply


Messages In This Thread
/reward command - by kirostar - 20.06.2014, 21:13
Re: Scripting Help - by kirostar - 20.06.2014, 21:46
Re: Scripting Help - by kirostar - 21.06.2014, 04:52
Re: Scripting Help - by RenovanZ - 21.06.2014, 04:57
Re: Scripting Help - by Rittik - 21.06.2014, 05:08
Re: Scripting Help - by kirostar - 21.06.2014, 05:28
Re: Scripting Help - by Rittik - 21.06.2014, 05:31
Re: Scripting Help - by kirostar - 21.06.2014, 05:34
Re: Scripting Help - by Rittik - 21.06.2014, 05:37
Re: Scripting Help - by Cena44 - 21.06.2014, 05:51

Forum Jump:


Users browsing this thread: 1 Guest(s)