Go Back   EQEmulator Home > EQEmulator Forums > Quests > Quests::Q&A

Quests::Q&A This is the quest support section

Reply
 
Thread Tools Display Modes
  #1  
Old 12-06-2008, 12:49 PM
spider661
Discordant
 
Join Date: Oct 2005
Location: michigain
Posts: 260
Default new quest command relaodquest

how hard would i be to make a new command that reloads the quest though a quest script? i seem to have a problem i have a quest to talk to a flagging npc and here are like 4 of them and for some reason it seems o bug out and flag you for the wrong zone even though the script for that zone are in a completely diff zone and zone folder.. i don't know but the only thing that seems to fix it is reloading quest so i figure if i have a quest command to do so i could just reload the quest when the npc spawns to prevent this from happening.
Reply With Quote
  #2  
Old 12-06-2008, 10:02 PM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,497
Default

Have you tried to clean your variables that you are using to make sure the right flag is going in?
Reply With Quote
  #3  
Old 12-07-2008, 02:49 AM
spider661
Discordant
 
Join Date: Oct 2005
Location: michigain
Posts: 260
Default

im not using any locals just quest

here is a sample script all the scripts look like this for this quest line but the zone name is diff for each

this one for example will unlock chardok then in chardok is the same script bu ikkinz is the one unlocked.. but for example the one before this that should unlock tipt keeps running this one but this on is in tipt no podisease where this one runs from.

Code:
sub EVENT_SAY
{
if ($text =~/Hail/i)
{
if (defined($qglobals{chardok})) {
quest::say("Thank you for freeing me, You already have the flag $name.");
}
else
{
quest::say("Thank you for releasing me. As a reward I will give you access to a place with riches beond your dreams.");
$client->Message(15, "You have received a character flag");
quest::setglobal("chardok", 1, 5, "F");
quest::settimer("bye", 60);
}
}
}
sub EVENT_TIMER
{	
	if($timer eq "bye")
	{
		quest::stoptimer("bye");
		quest::depop(); 
	}
}
Reply With Quote
  #4  
Old 12-07-2008, 05:31 AM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

Are you using the same NPC in multiple zones? And are the all in the same spawn group by chance? If so, that has caused problems for me in the past with quests overlapping through multiple zones. I have no idea why it happens, but the best solution is just to copy that NPC and create a new NPCID for each zone and set them on separate spawn groups.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
Reply With Quote
  #5  
Old 12-07-2008, 09:28 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,497
Default

If your NPC/zone is staying up, have you tried to undefine the globals. Obviously it won't effect the database.

Here is what I have seen before. I had an NPC delete a global, but the global still existed until it was undefined or the zone/NPC was reset. I am thinking that it might be somewhat related.
Reply With Quote
  #6  
Old 12-07-2008, 12:54 PM
spider661
Discordant
 
Join Date: Oct 2005
Location: michigain
Posts: 260
Default

yes they are the same npc sop mabie ill copy him and spawn a diff one in each zone..

how do i undefined the globals?
Reply With Quote
  #7  
Old 12-07-2008, 05:15 PM
trevius's Avatar
trevius
Developer
 
Join Date: Aug 2006
Location: USA
Posts: 5,946
Default

As long as you are writing the globals like this, "$qglobals{chardok}" and not like this, "$chardok", there shouldn't be any need to worry about undefining anything. If you use them without $qglobals{}, it can see them as a variable, which is what causes issues with them being held until undefined or reset. But by doing it the correct way, it has to check the DB each time it is referenced, so it doesn't store any kind of variables that can be used when they aren't supposed to be.
__________________
Trevazar/Trevius Owner of: Storm Haven
Everquest Emulator FAQ (Frequently Asked Questions) - Read It!
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 10:55 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