Some warnings
#1

how can i get these warnings awey ?
the dont do anything i can compile and use it
but i want the warnings gone

Код:
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\mapicon.inc(272) : warning 219: local variable "x2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\mapicon.inc(272) : warning 219: local variable "y2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\mapicon.inc(272) : warning 219: local variable "z2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\morphinc.inc(3) : warning 219: local variable "x2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\morphinc.inc(3) : warning 219: local variable "y2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\sa-mp\samp zooi\pawno\include\morphinc.inc(3) : warning 219: local variable "z2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\second life samp server\gamemodes\new(1).pwn(24818) : warning 219: local variable "x2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\second life samp server\gamemodes\new(1).pwn(24818) : warning 219: local variable "y2" shadows a variable at a preceding level
C:\Documents and Settings\Timmie\Bureaublad\second life samp server\gamemodes\new(1).pwn(24818) : warning 219: local variable "z2" shadows a variable at a preceding level
Reply
#2

We'd have to see yoru script to help.
You create the variables "x2, y2"ect in the same callback. Make change them to somethign different, like X2 Y2, x, y, ect, ect.
Or you could just make them global variables. ((put them at top of the script after #include <a_samp> but before main() )
Reply
#3

Quote:
Originally Posted by Swift_
We'd have to see yoru script to help.
this line 272
pawn Код:
forward OnPlayerUnjail(playerid);
and the lines at 24818

pawn Код:
public Float:GetDistanceBetweenPlayers(p1,p2)
{
    new Float:x1,Float:y1,Float:z1,Float:x2,Float:y2,Float:z2;
    if(!IsPlayerConnected(p1) || !IsPlayerConnected(p2))
    {
        return -1.00;
    }
    GetPlayerPos(p1,x1,y1,z1);
    GetPlayerPos(p2,x2,y2,z2);
    return floatsqroot(floatpower(floatabs(floatsub(x2,x1)),2)+floatpower(floatabs(floatsub(y2,y1)),2)+floatpower(floatabs(floatsub(z2,z1)),2));
}
Reply
#4

Dont' listen to my older posts, just saw where the errors came from.
Go into the two includes, and change the varibles there to something else.
Reply
#5

Quote:
Originally Posted by Swift_
Dont' listen to my older posts, just saw where the errors came from.
Go into the two includes, and change the varibles there to something else.
how ?
i dont know what to change there
Reply
#6

In the morphinic include, change the variables "x2, y2" to "XX, YY". Then goto the other include and change "x2, y2" to "XxX, YyY". Or some other name.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)