EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Quests::Q&A (https://www.eqemulator.org/forums/forumdisplay.php?f=599)
-   -   Log - Use of uninitialized value... (https://www.eqemulator.org/forums/showthread.php?t=29116)

eqwarrior 08-02-2009 09:26 PM

Log - Use of uninitialized value...
 
I edited most of my quest to do globals the right way, and now I'm getting a new error, just wondering how I can fix it.


Quote:

Use of uninitialized value $qst2700245::qglobals{"qviclevel"} in numeric eq (==) at quests/qrg/Custom_Zones.pl line 139.
Code:

if ($qglobals{qviclevel} == 15 &&  $ulevel == 70)  {
Also I redid one of turn in quest, and getting another error:

Quote:

Use of uninitialized value $qst2700248::itemcount{"99711"} in numeric eq (==) at quests/qrg/Epic_Vendor.pl line 229.
Code:

if ($itemcount{99711} == 1)  {
And I know there are multiple ways of doing item turn ins, but this seemed like the easier and shortest way to do, since I have over 100 possible turn in with elsif with a final else return items.

Any insight how to fix the errors from showing up would be appreciated.

joligario 08-02-2009 10:03 PM

The first one is most likely telling you it is not defined. Before $qglobals, check if defined before checking value.
Code:

if (defined($qglobals{qviclevel}) && $qglobals{qviclevel} == 15 &&  $ulevel == 70)  {
For the second one, it is better to use the plugin.
Code:

if (plugin::check_handin(\%itemcount, 99711 => 1)) {

thepoetwarrior 08-03-2009 05:24 AM

Thanks much !!!


All times are GMT -4. The time now is 09:22 PM.

Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.