[SOLVED]Help with the command
#1

Hello! Please, help. How to make a command like
pawn Код:
if(strcmp(cmd,"/sw list",true) == 0)
?
When I write a that command, it returns me with a "Unknown command".
Reply
#2

Quote:
Originally Posted by E1edge
Hello! Please, help. How to make a command like
pawn Код:
if(strcmp(cmd,"/sw list",true) == 0)
?
When I write a that command, it returns me with a "Unknown command".
You didn't complete the command with a return.
Reply
#3

Quote:
Originally Posted by E1edge
Hello! Please, help. How to make a command like
pawn Код:
if(strcmp(cmd,"/sw list",true) == 0)
?
When I write a that command, it returns me with a "Unknown command".
hmm
ex if u want to make a command like it so u have to do is

if(!strcmp(cmdtext, "/tpzone sw", true))
{
SetPlayerPos(playerid,2262.7290,2035.9547,10.8203) ; //
SendClientMessage(playerid, COLOR_RED, "You have teleported to Death_Itself's Mansion!");
return 1;
}


this example is for ur understanding and u can change the SetPlayerPos
Reply
#4

I suggest you to use strtok or sscanf because this is stupid to do a command including spaces.
Reply
#5

thats easy
try it if it will give you an error so tell me
Reply
#6

Thanks men! It works
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)