Help|Warning
#1

Hello all i`m new here can you help me with this warnings??
PHP код:
D:\щшъ бйъй\pawno\include\dutils.inc(28) : warning 219local variable "string" shadows a variable at a preceding level
D
:\щшъ бйъй\pawno\include\dutils.inc(132) : warning 219local variable "string" shadows a variable at a preceding level
D
:\щшъ бйъй\pawno\include\dutils.inc(172) : warning 219local variable "string" shadows a variable at a preceding level
D
:\щшъ бйъй\pawno\include\dutils.inc(280) : warning 219local variable "string" shadows a variable at a preceding level
D
:\щшъ бйъй\pawno\include\dutils.inc(337) : warning 219local variable "string" shadows a variable at a preceding level
D
:\щшъ бйъй\pawno\include\dutils.inc(379) : warning 219local variable "string" shadows a variable at a preceding level
Pawn compiler 3.2.3664              Copyright 
(c1997-2006ITB CompuPhase


6 Warnings

the lines who markes here are not bound to those warnings
thank you for helping me!!
Reply
#2

you have new string[10]; defined a lot of times like

pawn Код:
public OnPlayerSpawn(playerid) {
 new pName[25];
 GetPlayerName(playerid, pName, sizeof pName);
 new pName[50]; // ooops i used pName again should of changed it :P
 format(pName, sizeof pName, "Your Name Is %s", pName);
 SendClientMessage(playerid, 0x00ff00ff, pName);
 return 1;
}
That wont work ( i think ) its just a example
Reply
#3

Or you did like:
pawn Код:
// At top
new string[256];
And than at each command:
pawn Код:
new string[64];
Reply
#4

any of those didn`t succeed
please help me
Reply
#5

Show the script on pastebin.
Reply
#6

http://pastebin.com/m55f9030
Reply
#7

making to jump
Reply
#8

comment out line 6 of your script
Reply
#9

without line 6
Код:
D:\щшъ бйъй\gamemodes\ODC.pwn(385) : error 017: undefined symbol "string"
D:\щшъ бйъй\gamemodes\ODC.pwn(385) : error 017: undefined symbol "string"
D:\щшъ бйъй\gamemodes\ODC.pwn(385) : error 029: invalid expression, assumed zero
D:\щшъ бйъй\gamemodes\ODC.pwn(385) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Reply
#10

You can do 2 things:
1. Remove it from top and add it everywhere you use a string (i do not advise this)
2. Remove it from everywhere where you use a string and put it in on top of script(saves space)
Reply
#11

settled down
u can lock
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)