[HELP PLEASE]Multiple commands.
#6

You need to learn to use strcmp.

This is wrong:
if(strcmp("/rules", cmdtext, true, 10) == 0)

The number 10 you have in the function has to be the amount of characters the string (in this case "/rules") has. So, as you can see the number is wrong, because "/rules" has 6 characters.

You need to use:
if(strcmp("/rules", cmdtext, true, 6) == 0)

or:
if(strcmp("/rules", cmdtext, true) == 0)

strcmp in SA-MP wiki
Reply


Messages In This Thread
[HELP PLEASE]Multiple commands. - by [A51]Play3r1337 - 19.07.2009, 08:07
Re: [HELP PLEASE]Multiple commands. - by kc - 19.07.2009, 08:14
Re: [HELP PLEASE]Multiple commands. - by sggassasin - 19.07.2009, 08:26
Re: [HELP PLEASE]Multiple commands. - by kc - 19.07.2009, 08:28
Re: [HELP PLEASE]Multiple commands. - by Anarkien - 19.07.2009, 08:35
Re: [HELP PLEASE]Multiple commands. - by Finn - 19.07.2009, 08:53
Re: [HELP PLEASE]Multiple commands. - by sggassasin - 19.07.2009, 08:56
Re: [HELP PLEASE]Multiple commands. - by [A51]Play3r1337 - 19.07.2009, 09:59
Re: [HELP PLEASE]Multiple commands. - by sggassasin - 19.07.2009, 10:09

Forum Jump:


Users browsing this thread: 5 Guest(s)