Help!!! !!! !!!
#1

Help With That...


Some Error My gamemodes in pwn file

-----------------------------------------------------------------------------------------------------------------
//------------------------------------------------------------------------------
if(strcmp(cmd, "/announce", true) == 0 && PlayerAdminLevel[playerid] == 1337)|| strcmp(cmd, "/ann", true) == 0 && PlayerAdminLevel[playerid] == 1337)
{
new msg[256], seconds;
seconds = strval(strtok(cmdtext,idx));
if(seconds == 0)
{
SendClientMessage(playerid, CWARN," Server: /ann [time] [text]");
SendClientMessage(playerid, CWARN, " Server: Colors for the text can be viewed at /aacolors");
return 1;
}
msg = strrest(cmdtext,idx);
format(tmp,sizeof(tmp),"~w~%s",msg);
seconds = seconds * 1000;
GameTextForAll(tmp,seconds,0);
ToLog("announces", "%s: %s", PlayerName(playerid), msg);
return 1;
}

if(strcmp(cmd, "/announcep", true) == 0 && PlayerAdminLevel[playerid] == 1337)|| strcmp(cmd, "/annp", true) == 0&& PlayerAdminLevel[playerid] == 1337)
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp)) {
SendClientMessage(playerid, CWARN, " Server: /annp [PlayerID] [time] [text]");
}else{
if(!IsPlayerConnected(strval(tmp))) {
SendClientMessage(playerid, CWARN,"Bad PlayerID");
} else {
new msg[256], seconds;
seconds = strval(strtok(cmdtext,idx));
if(seconds == 0)
{
SendClientMessage(playerid, CWARN," Server: /annp [PlayerID] [time] [text]");
SendClientMessage(playerid, CWARN, " Server: Colors for the text can be viewed at /aacolors");
return 1;
}
msg = strrest(cmdtext,idx);
format(tmp2,sizeof(tmp2),"~w~%s",msg);
seconds = seconds *1000;
GameTextForPlayer(strval(tmp),tmp2,seconds,0);
}
}
return 1;
}

if(strcmp(cmd, "/aacolors", true) == 0 && PlayerAdminLevel[playerid] == 1337)
{
SendClientMessage(playerid, CWARN, "Colors for ann and TB.");
SendClientMessage(playerid, CINFO, "~l~[text] = black.");
SendClientMessage(playerid, CINFO, "~y~[text] = yellow.");
SendClientMessage(playerid, CINFO, "~b~[text] = blue.");
SendClientMessage(playerid, CINFO, "~r~[text] = red.");
SendClientMessage(playerid, CINFO, "~w~[text] = white.");
SendClientMessage(playerid, CINFO, "~p~[text] = pink.");
SendClientMessage(playerid, CINFO, "~g~[text] = green.");
return 1;
}
//------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------------

And That Error

-----------------------------------------------------------------------------------------------------------------
C:\Documents and Settings\Elar\My Documents\ajutine\Server new\Server\gamemodes\RPG.pwn(9805) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Elar\My Documents\ajutine\Server new\Server\gamemodes\RPG.pwn(9805) : warning 215: expression has no effect
C:\Documents and Settings\Elar\My Documents\ajutine\Server new\Server\gamemodes\RPG.pwn(9805) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\Elar\My Documents\ajutine\Server new\Server\gamemodes\RPG.pwn(9805) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Elar\My Documents\ajutine\Server new\Server\gamemodes\RPG.pwn(9805) : fatal error 107: too many error messages on one line

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


4 Errors.
-----------------------------------------------------------------------------------------------------------------

Plz Fix That Problem.
Reply
#2

please give the line number 9805...the statement written on that line
Reply
#3

if you can use " Insert code"
Reply
#4

here is line 9805
Download and watch
Reply
#5

Код:
	if(!strcmp(cmd, "/ann", true) && PlayerAdminLevel[playerid] == 1337)
	{
		new msg[256], seconds;
		seconds = strval(strtok(cmdtext,idx));
		if(seconds == 0)
		{
			SendClientMessage(playerid, CWARN," Server: /announce [time] [text]");
			SendClientMessage(playerid, CWARN, " Server: Colors for the text can be viewed at /aacolors");
			return 1;
		}
		msg = strrest(cmdtext,idx);
		format(tmp,sizeof(tmp),"~w~%s",msg);
		seconds = seconds * 1000;
		GameTextForAll(tmp,seconds,0);
		ToLog("announces", "%s: %s", PlayerName(playerid), msg);
		return 1;
	}

if(!strcmp(cmd, "/announce", true) && PlayerAdminLevel[playerid] == 1337)
	{
		new msg[256], seconds;
		seconds = strval(strtok(cmdtext,idx));
		if(seconds == 0)
		{
			SendClientMessage(playerid, CWARN," Server: /ann [time] [text]");
			SendClientMessage(playerid, CWARN, " Server: Colors for the text can be viewed at /aacolors");
			return 1;
		}
		msg = strrest(cmdtext,idx);
		format(tmp,sizeof(tmp),"~w~%s",msg);
		seconds = seconds * 1000;
		GameTextForAll(tmp,seconds,0);
		ToLog("announces", "%s: %s", PlayerName(playerid), msg);
		return 1;
	}
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)