12.03.2015, 18:20
That's pretty bad practice to do.
Best solution is to figure out if you actually need to use the z variable.
If not, then remove it from the script/function.
If you do, then ignore the warning until you actually have finished writing the code that actually utilizes the variable.
This would be the solution, if you aren't going to need the z variable, which you most likely wont considering its a 2D function.
Best solution is to figure out if you actually need to use the z variable.
If not, then remove it from the script/function.
If you do, then ignore the warning until you actually have finished writing the code that actually utilizes the variable.
pawn Code:
stock Get2DZoneFromCoordinates(Float:x, Float:y, zone[], len = sizeof(zone))
{
for(new i = 0; i != sizeof(gSAZones); i++ )
{
if(x >= gSAZones[i][SAZONE_AREA][0] && x <= gSAZones[i][SAZONE_AREA][3] && y >= gSAZones[i][SAZONE_AREA][1] && y <= gSAZones[i][SAZONE_AREA][4])
{
return format(zone, len, gSAZones[i][SAZONE_NAME], 0);
}
}
}
return 0;