Problem with errors [+REP]
#1

Код:
D:\games\Скинове О.О\Без гангове\gamemodes\gangwars.pwn(6238) : warning 202: number of arguments does not match definition
D:\games\Скинове О.О\Без гангове\gamemodes\gangwars.pwn(8365) : error 029: invalid expression, assumed zero
D:\games\Скинове О.О\Без гангове\gamemodes\gangwars.pwn(8365) : error 017: undefined symbol "cmd_fmute"
D:\games\Скинове О.О\Без гангове\gamemodes\gangwars.pwn(8365) : error 029: invalid expression, assumed zero
D:\games\Скинове О.О\Без гангове\gamemodes\gangwars.pwn(8365) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
6238
Код:
    SaveAccounts(playerid);
8365 - 8390
Код:
CMD:fmute(playerid, params[])
{
	new gamer;
	if(!IsPlayerAdmin(playerid))
    return SendClientMessage(playerid, red, "Access Denied.");
	if (sscanf(params, "u", gamer)) SendClientMessage(playerid, red, "Използвай: \"/mute <Играч>");
	else if (gamer == INVALID_PLAYER_ID) SendClientMessage(playerid, red, "Играча на е намерен");
	else
	{
		SaveInfo[gamer][fMuted] = 1;
	}
	return 1;
}
CMD:funmute(playerid, params[])
{
	new gamer;
	if(!IsPlayerAdmin(playerid))
    return SendClientMessage(playerid, red, "Access Denied.");
	if (sscanf(params, "u", gamer)) SendClientMessage(playerid, red, "Използвай: \"/unmute <Играч>");
	else if (gamer == INVALID_PLAYER_ID) SendClientMessage(playerid, red, "Играча на е намерен");
	else
	{
		SaveInfo[gamer][fMuted] = 0;
	}
	return 1;
}
Reply
#2

Show us the 'SaveAccounts(playerid)' stock or the public function you have.

And where have you put the 'CMD' lines?
Reply
#3

Quote:

error 017: undefined symbol "cmd_fmute"

That's because you dont have ZCMD included!

Download one and put it into your pawno/includes and then add this to the top of your script:

pawn Код:
#include <zcmd>
Better indentation and some fixes:

pawn Код:
CMD:fmute(playerid, params[])
{
    new gamer;
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, red, "Access Denied.");
    if(sscanf(params, "u", gamer)) return SendClientMessage(playerid, red, "Използвай: \"/mute <Играч>");
    if(gamer == INVALID_PLAYER_ID) return SendClientMessage(playerid, red, "Играча на е намерен");
    SaveInfo[gamer][fMuted] = 1;
    return 1;
}

CMD:funmute(playerid, params[])
{
    new gamer;
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, red, "Access Denied.");
    if(sscanf(params, "u", gamer)) return SendClientMessage(playerid, red, "Използвай: \"/unmute <Играч>");
    if(gamer == INVALID_PLAYER_ID) return SendClientMessage(playerid, red, "Играча на е намерен");
    SaveInfo[gamer][fMuted] = 0;
    return 1;
}
By the way put your ZCMD commands at the bottom of your script. Not under OnPlayerCommandText or something.
Reply
#4

Quote:
Originally Posted by RedJohn
Посмотреть сообщение
That's because you dont have ZCMD included!

Download one and put it into your pawno/includes and then add this to the top of your script:

pawn Код:
#include <zcmd>
Better indentation and some fixes:

pawn Код:
CMD:fmute(playerid, params[])
{
    new gamer;
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, red, "Access Denied.");
    if(sscanf(params, "u", gamer)) return SendClientMessage(playerid, red, "Използвай: \"/mute <Играч>");
    if(gamer == INVALID_PLAYER_ID) return SendClientMessage(playerid, red, "Играча на е намерен");
    SaveInfo[gamer][fMuted] = 1;
    return 1;
}

CMD:funmute(playerid, params[])
{
    new gamer;
    if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, red, "Access Denied.");
    if(sscanf(params, "u", gamer)) return SendClientMessage(playerid, red, "Използвай: \"/unmute <Играч>");
    if(gamer == INVALID_PLAYER_ID) return SendClientMessage(playerid, red, "Играча на е намерен");
    SaveInfo[gamer][fMuted] = 0;
    return 1;
}
By the way put your ZCMD commands at the bottom of your script. Not under OnPlayerCommandText or something.
I have zcmd..Not work..

The command in under the public OnPlayerCommandText(playerid, cmdtext[])
Reply
#5

Help please?
Reply
#6

Remove it from OnPlayerCommandText. Add it at the bottom.
Reply
#7

I give you REP,thanks man!
Reply
#8

No problemo.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)