Page 1 of 1

Warning: local variable not used

Posted: Thu Mar 20, 2014 9:06 pm
by Zaksmeer
I am getting this error pertaining to .src and .inc files. Any suggestions what I should be looking for?

Re: Warning: local variable not used

Posted: Fri Mar 21, 2014 1:36 am
by qrak
You defined variable inside program or function which is not used.

Re: Warning: local variable not used

Posted: Fri Mar 21, 2014 7:37 am
by Zaksmeer
so do I just delete that out?

If useScissors.src is saying "Warning: local variable 'tool' not used. I could just delete out 'tool' and pray that it is ok?

Re: Warning: local variable not used

Posted: Fri Mar 21, 2014 11:44 am
by qrak
Try and compile, if script compiles then all is legit.

Re: Warning: local variable not used

Posted: Sun Mar 23, 2014 8:12 am
by Tomi
sounds like your code is something like program scissors( who, tool ) and in that case if you remove that tool it wont work because an item use script need 2 parameters

If thats the case just add somewhere in your code tool := tool; and the warning is gone, or let it be if you dont care because it does not stop anything from working, its just reporting that you have a variable hanging there never used