Adding a command with strcmp?
#1

Do you need to do anything with your script if you are going to add a strcmp command to the script?

for example:
pawn Код:
if (strcmp(cmd, "/yourcmd", true) == 0)
Reply
#2

No you don't.
Reply
#3

Thanks
Reply
#4

Before we call this case solved. Please please please, DO NOT USE strcmp. use Dcmd or zcmd. It will make your life easier and faster trust me!
Reply
#5

I find strcmp easier btw
Reply
#6

It might be easier to you.
But it's inefficient as hell.

Also, it doesn't take that long to grasp the way DCMD/ZCMD/YCMD & SSCANF works. And trust me, you're way better off with those processors.
Reply
#7

Still, I am staying with strcmp
Reply
#8

Alright. Your call.
Anyway, Ontopic: No, as stated before. All you need to do is place it under OnPlayerCommandText(playerid, cmdtext[]).
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)