Help with Compile error
#1

When i complie i get this error:
pawn Код:
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_ServerSettings.inc(31) : warning 201: redefinition of constant/macro (symbol "MAX_HOUSES")
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
here is the line:
pawn Код:
COMMAND:clearchat(playerid,params[])
{
   if( PlayerInfo[ playerid ][ pAdmin ] >= 1 ) return SendClientMessage( playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!" );
{
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
}   return 1;
}
Reply
#2

It means that you don't have the variable "PlayerInfo" defined anywhere in your script, nor, it's defined in a local callback.

Also, you have another error that should be easily fixed by this:
pawn Код:
COMMAND:clearchat(playerid,params[])
{
   if( PlayerInfo[ playerid ][ pAdmin ] < 1 ) return SendClientMessage( playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!" );
else
{
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
}   return 1;
}
Reply
#3

i tryed that look
pawn Код:
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_ServerSettings.inc(31) : warning 201: redefinition of constant/macro (symbol "MAX_HOUSES")
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Reply
#4

Quote:

here is the line:
pawn Код:
COMMAND:clearchat(playerid,params[])
{
   if( PlayerInfo[ playerid ][ pAdmin ] >= 1 ) return SendClientMessage( playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!" );
{
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
}   return 1;
}
Alright,I think you have made mistake in last lines.
Instead of that (Note* this is only 1 part)
Код:
{
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
}   return 1;
}
Try out this part (same part,but with chances)
Код:
   {
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
     return 1;
   }
     
}
So at all it should looks like:
Код:
COMMAND:clearchat(playerid,params[])
{
   if( PlayerInfo[ playerid ][ pAdmin ] >= 1 ) return SendClientMessage( playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!" );
   {
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
     return 1;
   }
     
}
Reply
#5

wait i am counfused can you Script it all in one and ill put it
Reply
#6

Quote:
Originally Posted by Geeboi_Mehdi
Посмотреть сообщение
wait i am counfused can you Script it all in one and ill put it
Alright,I did put same script as you did,but with fixes which I told above.
If you get some error,put here
Reply
#7

Look:
error again
pawn Код:
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_ServerSettings.inc(31) : warning 201: redefinition of constant/macro (symbol "MAX_HOUSES")
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Reply
#8

Did you define PlayerInfo? Show me your defines

Also, here is one, in which I fixed the brackets.

pawn Код:
COMMAND:clearchat(playerid,params[])
{
   if( PlayerInfo[playerid][pAdmin] < 1 ) return SendClientMessage( playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!" );
else
{
     for( new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
     return 1;
}
}
Reply
#9

Again look
pawn Код:
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_ServerSettings.inc(31) : warning 201: redefinition of constant/macro (symbol "MAX_HOUSES")
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Reply
#10

Quote:
Originally Posted by Geeboi_Mehdi
Посмотреть сообщение
Again look
pawn Код:
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_ServerSettings.inc(31) : warning 201: redefinition of constant/macro (symbol "MAX_HOUSES")
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 017: undefined symbol "PlayerInfo"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 001: expected token: ";", but found "]"
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\Trucking Life\pawno\include\PPC_PlayerCommands.inc(5135) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664          Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.
Did you define ''PlayerInfo''? Also it's clearly said,that it's undefined symbol,which means you have to define it
Plus,I think you got some space mistakes overthere
Try out this:
Код:
COMMAND:clearchat(playerid,params[])
{
   if(PlayerInfo[playerid][pAdmin] == 1) return SendClientMessage(playerid, COLOR_RED, "ERROR: You must be level 1 to use this command!");
{
     for(new i = 0; i <= 100; i ++ ) SendClientMessageToAll( -1, "" );
     return 1;
}
}
Tell then if you got some more error.If it give same error again,I think I have one more solution.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)