Something wrong with zcmd?
#1

Hey again.

I just tried to add a /b command to my script and this is what happened.

Quote:

error 029: invalid expression, assumed zero
error 017: undefined symbol "cmd_b"
error 029: invalid expression, assumed zero
fatal error 107: too many error messages on one line

And all these errors are on the same line, and this is the line:
Quote:

CMD:b(playerid, params[])

Placed underneath:
Quote:

public OnPlayerCommandText(playerid, cmdtext[])
{

I am newbie scripter, so do not expect I know everything and that is why I am asking. As this is a scripting help section, there are no need to tell me to use ******, because I have already used ****** and it says nothing about this problem. Thanks. Maybe it is obviously for you scripts, but not for me as a newbie.

The whole command:
Quote:

CMD:b(playerid, params[])
{
new text[128], string[128];
new name[MAX_PLAYER_NAME];
if(sscanf(params,"s[128]",text)) return SendClientMessage(playerid,-1,"{008000}Usage: /n [message]");
else
{
GetPlayerName(playerid,name,sizeof(name));
strreplace(name, '_', ' ');
format(string,sizeof(string),"(( %s says: %s ))",name,text);
SendNearbyMessage(30.0, playerid, string, COLOR_WHITE, COLOR_WHITE, COLOR_WHITE, COLOR_WHITE, COLOR_WHITE);
}
return 1;
}

Reply


Messages In This Thread
Something wrong with zcmd? [SOLVED] - by Hargrave - 27.07.2013, 11:48
Re: Something wrong with zcmd? - by MellowHammer - 27.07.2013, 11:53
Re: Something wrong with zcmd? - by Hargrave - 27.07.2013, 11:54
Re: Something wrong with zcmd? - by Necip - 27.07.2013, 11:55
Re: Something wrong with zcmd? - by MellowHammer - 27.07.2013, 11:56
Re: Something wrong with zcmd? - by Hargrave - 27.07.2013, 12:09
Re: Something wrong with zcmd? - by Necip - 27.07.2013, 12:12
Re: Something wrong with zcmd? - by Scrillex - 27.07.2013, 12:14
Re: Something wrong with zcmd? - by Hargrave - 27.07.2013, 12:14
Re: Something wrong with zcmd? - by Sublime - 27.07.2013, 12:18

Forum Jump:


Users browsing this thread: 2 Guest(s)