STRTOK issue
#2

You Most To Do every commands the var commands like tmp!
you cannot do this Globlay!

and i suggest you to do your Command like this:

Код:
if(strcmp(cmd, "/Kick", true) == 0)
{
  new tmp[256];
  tmp = strtok(cmdtext, idx);
  
   if(!strlen(tmp)) return SendClientMessage(playerid,COLOR_RED,"Usage: /Kick [playerid]!");

  new id;
  id = strval(tmp);
  
  if(!IsPlayerConnected(id)) return SendClientMessage(playerid,COLOR_RED,"Invaild id!");
  
  Kick(id);
  return 1;
}
Hope I Help you! =]
Reply


Messages In This Thread
STRTOK issue - by Paladin - 21.03.2009, 17:15
Re: STRTOK issue - by [LorD]bAr[Sp] - 21.03.2009, 17:34
Re: STRTOK issue - by Paladin - 22.03.2009, 11:26
Re: STRTOK issue - by MenaceX^ - 22.03.2009, 11:35
Re: STRTOK issue - by MenaceX^ - 22.03.2009, 11:50
Re: STRTOK issue - by MenaceX^ - 22.03.2009, 11:57
Re: STRTOK issue - by Paladin - 22.03.2009, 12:52
Re: STRTOK issue - by MenaceX^ - 22.03.2009, 12:55

Forum Jump:


Users browsing this thread: 3 Guest(s)