Help with commands
#1

As an example, If I want to do a /kick command (/kick <id> <reason>) I can do

id = strval(cmdtext[9]);

As for the <reason> param of the command I am unsure. I have tried this (untested). Is the correct way?

pawn Код:
if((pos = strfind(cmdtext, " ", 6)) != -1) return pos = strfind(cmdtext, " ", 6)) != -1);
Then
pawn Код:
if(strval[pos] >= 0) return The number cannot be a number!
Im just using an example. Would that work?
Reply


Messages In This Thread
Help with commands - by lolumadd - 02.10.2009, 00:43
Re: Help with commands - by ded - 02.10.2009, 00:51
Re: Help with commands - by lolumadd - 02.10.2009, 01:26
Re: Help with commands - by ded - 02.10.2009, 01:45
Re: Help with commands - by lolumadd - 02.10.2009, 02:04

Forum Jump:


Users browsing this thread: 4 Guest(s)