SA-MP Forums Archive
Compile Warnings - Need help! - 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: Compile Warnings - Need help! (/showthread.php?tid=521921)



Compile Warnings - Need help! - Wahaj - 25.06.2014

Quote:

D:\New Server\gamemodes\elitedrift.pwn(1372) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(1389) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(1437) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2657) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2689) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2711) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2727) : warning 219: local variable "string" shadows a variable at a preceding level
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


7 Warnings.

This stops some scripts like i have a Fedex job script , when i enter the vehicle and get a Parcel , when i click to chose which type of Parcel i need , i double click and it does nothing but shows "Enjoy Drifting" as i have EliteDriftV2.5 game mode and these warnings are default in the Game mode. There were 9 warnings but when i removed the dialogue "Enjoy Drifting" there are 7 now. I want 0 to want my scripts work , this error is in the Game mode , the FS is compiled 100% fine , i'd like fast help and please be polite..


Re: Compile Warnings - Need help! - RenovanZ - 25.06.2014

change your string to stringz or whatever, its already used.


Re: Compile Warnings - Need help! - Wahaj - 25.06.2014

And i have figured all those dialogues which require clicking on them and choosing are not working like /fuel > /refuel for 10$ is not working , i keep clicking and they keep closing and no action working. Others which require quick actions like /fuel > You've been refueled would work. Whats the problem? Am i missing plugins? I have 4 loaded plugins like sscanf,whirlpool,Streamer and a thirdparty plugin like map_andreas..


Re: Compile Warnings - Need help! - Wahaj - 25.06.2014

Quote:
Originally Posted by RenovanZ
Посмотреть сообщение
change your string to stringz or whatever, its already used.
Quote:

D:\New Server\gamemodes\elitedrift.pwn(1374) : error 017: undefined symbol "string"
D:\New Server\gamemodes\elitedrift.pwn(1375) : error 017: undefined symbol "string"
D:\New Server\gamemodes\elitedrift.pwn(1372) : warning 204: symbol is assigned a value that is never used: "stringz"
D:\New Server\gamemodes\elitedrift.pwn(1389) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(1437) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2657) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2689) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2711) : warning 219: local variable "string" shadows a variable at a preceding level
D:\New Server\gamemodes\elitedrift.pwn(2727) : warning 219: local variable "string" shadows a variable at a preceding level
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


2 Errors.

This is what when i put the string to stringz on line 1372..


Re: Compile Warnings - Need help! - PAF - 25.06.2014

Dewar Wahaj the warning is not a dangerous thing ok


Re: Compile Warnings - Need help! - Threshold - 25.06.2014

Quote:
Originally Posted by PAF
Посмотреть сообщение
Dewar Wahaj the warning is not a dangerous thing ok
Who cares? It can still ruin a script. Get your facts straight.

This just means you have multiple variables named 'string' that have been created several times. This is fixed by either changing the name of the variable to something else that doesn't conflict with another variable.


Re: Compile Warnings - Need help! - Wahaj - 25.06.2014

So lets leave the gamemode. And get on this :-
Quote:

And i have figured all those dialogues which require clicking on them and choosing are not working like /fuel > /refuel for 10$ is not working , i keep clicking and they keep closing and no action working. Others which require quick actions like /fuel > You've been refueled would work. Whats the problem? Am i missing plugins? I have 4 loaded plugins like sscanf,whirlpool,Streamer and a thirdparty plugin like map_andreas..