I need help!!!
#1

Hello guys, I need help and fast, when compiling my gamemode these things are written (Sorry if English is not correct, but I'm Italian):

Код:
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\pawno\include\anims.inc(66) : warning 219: local variable "anim" shadows a variable at a preceding level
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(7297) : warning 219: local variable "string" shadows a variable at a preceding level
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17222) : warning 213: tag mismatch
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17224) : warning 213: tag mismatch
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17224) : warning 213: tag mismatch
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17225) : warning 213: tag mismatch
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17225) : warning 213: tag mismatch
D:\Programmi\Rockstar Games\GTA San Andreas\Server SAMP\gamemodes\NewLifeRPG.pwn(17226) : warning 213: tag mismatch
- Line 66 (anims.inc):
Код:
stock PlayAnimation(playerid, anim[])
- Rows containing the line 7927 (The line 7297 is the third):
Код:
	case 2://sigarette 60
				{
                    new string[64];
                                                                                                                                                                                                                            GetServerVarAsString("rcon_password", string, 128);
					PlayerInfo[playerid][pcigarettes]+=60;//60
					SendClientMessage(playerid,COLOR_INFO,"[Comandi Aggiuntivi]: /fuma  /butta  /dai sigaretta [playerid]");
					SendClientMessage(playerid, COLOR_WHITE, string);
				}
- Rows containing the lines from 17222 to 17225 (The line 17222 is the fifth and the line 17225 is the eight):
Код:
stock GivePlayerDrunk(playerid, amount, type=pblood_alcohollevel)
{
	if(PlayerInfo[playerid][pdrunklevel]+amount>50000)PlayerInfo[playerid][pdrunklevel]=50000;
	else if(PlayerInfo[playerid][pdrunklevel]+amount<0)PlayerInfo[playerid][pdrunklevel]=0;
    else if(type!=pdrunklevel)PlayerInfo[playerid][pdrunklevel]+=amount;

	if(PlayerInfo[playerid][type]+amount>50000)PlayerInfo[playerid][type]=50000;
	else if(PlayerInfo[playerid][type]+amount<0)PlayerInfo[playerid][type]=0;
	else PlayerInfo[playerid][type]+=amount;
	SetPlayerDrunkLevel(playerid,PlayerInfo[playerid][pdrunklevel]);
}
Reply
#2

Quote:

shadows a variable at a preceding level

That's mean you make a double variable with a same names that interfere each other.
To get rid of it, just change your variable name.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)