Epic Warning - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Epic Warning (
/showthread.php?tid=301427)
Epic Warning -
SpiderWalk - 04.12.2011
Hello everybody.I got epic warning but i dont know how to fix them
Code:
pawn Код:
//top of script
new area;
new abb;
//OnGameModeInit
area = CreatePickup(1239, 2, 378.0938,1973.1765,17.6575, 0);
abb = CreatePickup(1239, 2, 364.6389,2529.2292,16.6683, 0);
warning
Код:
C:\Documents and Settings\Korisnik\My Documents\Downloads\samp03dsvr_win32(1)\gamemodes\SpiderWalk.pwn(152) : warning 204: symbol is assigned a value that is never used: "abb"
C:\Documents and Settings\Korisnik\My Documents\Downloads\samp03dsvr_win32(1)\gamemodes\SpiderWalk.pwn(151) : warning 204: symbol is assigned a value that is never used: "area"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
2 Warnings.
Re: Epic Warning -
currencyinstacks - 04.12.2011
Place this under OnGamemodeExit
Код:
DestroyPickup(area);
DestroyPickup(abb);
Re: Epic Warning - [L3th4l] - 04.12.2011
What are you going to do with those pickups? You should use it as so:
pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid)
{
if(pickupid == area) print("Area pickup.");
else if(pickupid == abb) Ban(playerid);
return 1;
}
If you won't use the pickups for anything, just don't make those variables, which will be a waste.
Re: Epic Warning -
SpiderWalk - 04.12.2011
Quote:
Originally Posted by [L3th4l]
What are you going to do with those pickups? You should use it as so:
pawn Код:
public OnPlayerPickUpPickup(playerid, pickupid) { if(pickupid == area) print("Area pickup."); else if(pickupid == abb) Ban(playerid);
return 1; }
If you won't use the pickups for anything, just don't make those variables, which will be a waste.
|
Thanks for all replys
Re: Epic Warning -
Ash. - 04.12.2011
If you're not going to use them (but still want to assign them to variables - though I don't know why you'd do that!) you could just use the #pragma unused directive.
Replace "symbol" with the variable name.