Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Custom

Quests::Custom Custom Quests here

Reply
 
Thread Tools Display Modes
  #1  
Old 05-08-2014, 09:43 PM
Sticz's Avatar
Sticz
Fire Beetle
 
Join Date: Nov 2008
Location: St. Louis, MO
Posts: 14
Default Getting an NPC to notice a global?

I am trying to make a translocator that recognizes a global. I currently have a planar projection that uses this script:

sub EVENT_SAY {
if($text=~/hail/i && !defined($qglobals{Velious}))
{
$client->Message(4,"You are now flagged for Velious!");
quest::setglobal("Velious",1,5,"F");
}
}


I then have a different NPC in a different zone that uses this script:

sub EVENT_SAY {
if(($ulevel <= 45) && !defined($qglobals{Velious})) {
if($text=~/Hail/i){
$client->Message(14,"Greetings, $name. You can travel to old-world zones);
}
}

elsif(($ulevel >= 46) && !defined($qglobals{Velious})) {
if($text=~/Hail/i){
$client->Message(14,"Greetings, $name. You are able to go to the plane of hate.);
}
}

elsif(($ulevel >= 46) && ($qglobals{Velious} == 1)) {
if($text=~/Hail/i){$client->Message(14,"Greetings, $name. You are flagged for Velious and the plane of Hate.);
}
}
}


The problem is that the last script will not run: the NPC does not seem to recognize the global variable. Any thoughts?

Sticz
Reply With Quote
  #2  
Old 05-08-2014, 11:36 PM
lerxst2112
Demi-God
 
Join Date: Aug 2010
Posts: 1,743
Default

Did you set the qglobal flag in npc_types for that npc?
Reply With Quote
  #3  
Old 05-09-2014, 12:52 AM
Sticz's Avatar
Sticz
Fire Beetle
 
Join Date: Nov 2008
Location: St. Louis, MO
Posts: 14
Default

... Never occurred to me. Fixed and is working great now, thanks!

Sticz
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 05:00 AM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3