zcmd + sscanf + strcmp + next param.
#4

Try this:

pawn Код:
COMMAND:command(playerid, params[])
{
      if(sscanf(params, "s[20]I(-1)", name, slot)) return // blablablalalala
      if(strcmp(name,"putin",true) == 0)
      {
              if(slot == -1)
                    return YourStuffHere //slot is '-1' , which means it isn't changed from the default value, which again means that player didn't put anything in the second param
              /* Do your stuff */
       }
       else // if 'putin' isn't the first param put
}
Reply


Messages In This Thread
zcmd + sscanf + strcmp + next param. - by GaGlets(R) - 10.10.2010, 14:38
Re: zcmd + sscanf + strcmp + next param. - by LarzI - 10.10.2010, 14:50
Re: zcmd + sscanf + strcmp + next param. - by GaGlets(R) - 10.10.2010, 14:55
Re: zcmd + sscanf + strcmp + next param. - by LarzI - 10.10.2010, 15:00
Re: zcmd + sscanf + strcmp + next param. - by GaGlets(R) - 10.10.2010, 15:02
Re: zcmd + sscanf + strcmp + next param. - by GaGlets(R) - 10.10.2010, 15:23
Re: zcmd + sscanf + strcmp + next param. - by LarzI - 10.10.2010, 19:10

Forum Jump:


Users browsing this thread: 1 Guest(s)