EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Support::General Support (https://www.eqemulator.org/forums/forumdisplay.php?f=598)
-   -   qglobal help (https://www.eqemulator.org/forums/showthread.php?t=37428)

Furniture 10-25-2013 03:01 PM

qglobal help
 
I'm not sure what I'm doing wrong. For some reason I am having trouble getting my qglobals properly read. I've done it fine in the past so this is bewildering to me.

Heres an example:
Code:

sub EVENT_SPAWN
{
       
        quest::settimer("boatcheck", 5);
}

sub EVENT_TIMER
{

if(!defined $qglobals{bbtest4})
{
        if($timer eq "boatcheck") {
        quest::shout("TEST");
       
        quest::setglobal("bbtest4", 1, 7, "F");

        }
        }

}

Running this script, an npc repeadetly shouts every 5 seconds, yet there is definitely the bbtest4 global variable entered into my databse so it seems the if(!defined $qglobals{bbtest4}) if where the problem lies.

From what I understand, this code should just result in the npc shouting after the first 5 seconds and then stop. Can anyone recognize what i'm doing wrong?

provocating 10-25-2013 03:04 PM

Looks like you many parens?

Nevermind, one was hiding.

Furniture 10-25-2013 03:17 PM

I had forgotten to enable qglobals on npc.. works now


All times are GMT -4. The time now is 07:05 PM.

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