*** Terrible Title Removed
#1

i made cmd
Код:
if (strcmp(cmd, "/admins", true)  ==  0)
{
     SendClientMessage(playerid, COLOR_WHITE, " You cant see the admin list.");
     return 1;
}
AND WHEN I GO INGAME AND TYPE /admins nothing happens :S can some1 tell me how to fix it ? when player type /admins to say You cant see the admin list ?
Reply
#2

@ Faisal_Khan: So what is he doing now? Posting a junk reply won't help.


Код:
if (strcmp("/admins", cmdtext, true, 7) == 0)
	{
		SendClientMessage(playerid, COLOR_WHITE, " You cant see the admin list.");
		return 1;
	}
Reply
#3

Quote:
Originally Posted by gtakillerIV
Посмотреть сообщение
@ Faisal_Khan: So what is he doing now? Posting a junk reply won't help.


Код:
if (strcmp("/admins", cmdtext, true, 7) == 0)
	{
		SendClientMessage(playerid, COLOR_WHITE, " You cant see the admin list.");
		return 1;
	}
what? i dont understand what u saying

edit true, 7 wtf
Reply
#4

refresh
Reply
#5

First of all tell us which admin system you are using, and second your command will show everyone who type /admins - "You cant see the admin list"
Reply
#6

if (strcmp("/admins", cmdtext, true, 7) == 0)

Here we are comparing two strings with each other using strcmp.

"/admins" = What to look for.

"cmdtext" = The command that the player typed if it is /admins it will return our /admins command.

"true" = If they match.

"7" = The character length of "/admins" which is 7.


Here is more info:

https://sampwiki.blast.hk/wiki/Using_strcmp()
Reply
#7

Dude, you compiled?lol
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)