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 04-18-2010, 09:41 PM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default Waypoints are hit and miss

I don't understand why this is happening but things I need to rely on are just not happening all the time and it screws up a system of events that rely on a waypoint being triggered.

I echo'd the npc's waypoints to see what was going on and most of the time it's fine but occasionally it will echo a set of waypoints like 1 2 4 completely ignoring point 3!

Now when I need to depop on point 3 this can become a disaster!

Why is this happening?
Reply With Quote
  #2  
Old 04-19-2010, 07:16 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,498
Default

Check your grid pause time. Might be possible your timing is off. To test waypoints out, in your NPC's script file try this:

Code:
sub EVENT_WAYPOINT_ARRIVE {
  quest::shout("I have arrived at Waypoint $wp.");
}

sub EVENT_WAYPOINT_DEPART {
  quest::shot("I am departing Waypoint $wp.");
}
Also, check that your grid numbers are sequential. It is possible that the entries are not in order.
Reply With Quote
  #3  
Old 04-19-2010, 07:49 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

That's what I mean when echo'ing - it's saying i've reached 1, 2 then 4!

The pause is set to a variety of values from 0 to 200. 0 is ok isn't it?
Reply With Quote
  #4  
Old 04-19-2010, 09:14 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,498
Default

Did you check the grid numbers in the database to ensure there is a 3 on that grid? Is the wander type set to patrol? 0 is fine for the timer, was just saying to check just in case you were trying to stop on a waypoint that was set to 0 or something similar.
Reply With Quote
  #5  
Old 04-19-2010, 09:31 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

I've set them all to 1 but i'm still having the same issue! Yep i'm using patrol with full waits and am on the latest build of eqemu with perl 5.10.

Must.. fix...this!
Reply With Quote
  #6  
Old 04-19-2010, 09:36 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Here's one of the bug ones

Gets to wp 3 fine (which is wp4 i believe in the grid but starts at 0 in perl)

Code:
sub EVENT_WAYPOINT_ARRIVE
{
	quest::say("I have reached waypoint $wp");
	# keep moving till i reach the last waypoint
	if($wp eq 4)
	{
		# Set a qglobal to inform the boat in BB to pop
		quest::say("Setting status 2 as we are at waypoint $wp");
		quest::setglobal("ootboatstatus",2,7,F);
	}
	
	if($wp eq 5)
	{
		# Boat in BB should now be popped, depop me
		quest::say("Depopping as we are at waypoint $wp");
		quest::depop();
	}
}
Reply With Quote
  #7  
Old 04-19-2010, 10:07 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,498
Default

Wait, I'm confused then. Since the $wp starts at 0, and you are looking for 3rd waypoint, then you should be checking if == 2. Maybe show your grids and explain which waypoint you are interested in and I can help better.

EDIT: You should also use == instead of eq. I think I see what you are saying with 3/4. I just compiled 1395 and it doesn't skip any waypoints...
Reply With Quote
  #8  
Old 04-19-2010, 11:08 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Ok i swapped to == and it doesn't make a difference. I expect on this script when the spawn reaches waypoint 5 ($wp == 4) it will record the quest global. then when it reaches waypoint 6 ($wp == 5) it will depop.

At the moment I have that zone as static, i'm in another and I am looking at the quest global table and it has never changed from ootboatstatus '1' to '2' like it should when it his waypoint 5 ($wp == 4).

What's happening!!
Reply With Quote
  #9  
Old 04-19-2010, 11:11 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Code:
"gridid","zoneid","number","x","y","z","heading","pause"
62,69,1,11124.2,446.575,-43,0,300
62,69,2,7583.69,-1344.21,-43,0,1
62,69,3,7445.1,-2111.7,-43,0,100
62,69,4,6250.45,-4585.98,-43,0,1
62,69,5,-9858.39,-4646.89,-43,0,300 - Should set QuestGlobal to 2 here
62,69,6,-10981.2,-4932.77,-20.0084,0,1 - Should depop here
Reply With Quote
  #10  
Old 04-19-2010, 11:19 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,498
Default

Couple of last few questions. Is number 1 on your grid list at (or very near) the spawnpoint? Does the boat have qglobals enabled? Try using "F" instead of F? BTW, I wasn't saying that == would fix it, I was just saying that when using that type of condition check, it should be == instead of the string eq.
Reply With Quote
  #11  
Old 04-19-2010, 11:24 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Yeah the spawn has qglobals enabled. It's definitely translating the F across because a previous script uses it and I can see it in the table. Number 1 is exactly where the spawn is when it pops.
Reply With Quote
  #12  
Old 04-19-2010, 11:39 AM
joligario's Avatar
joligario
Developer
 
Join Date: Mar 2003
Posts: 1,498
Default

Does the boat say "setting status 2..." and/or "Depopping..."? Want to post your most up-to-date code you are using?
Reply With Quote
  #13  
Old 04-19-2010, 11:43 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

It's almost like if I'm not in the static zone with the boat it will not set the qglobal and depop.

Whenever I sit on the 4 hour journey with it across OOT it will happily depop and set the qglobal to 2.

Messed up!
Reply With Quote
  #14  
Old 04-19-2010, 11:48 AM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Eugh!

Quote:
Originally Posted by Angelox View Post
Keep this in mind: Perl will not activate in any given zone if there are not any PC's there.
I probably started the 'Global Watchers' thing. The best method to have a watcher is via 2 point grid on an NPC (grids need a 3-5 second delay on each), another words, you make an NPC, give him to grid points all on the same spawnpoint (preferably invisible). Now, when you enter the zone, the script will activate and continue executing any changes it spots, with each grid movement (EVENT_WAYPONT).
EVENT_SPAWN works if the zone is not static, and only once , Proximity is nice (EVENT_ENTER), but you have to plant 'watchers' all over the zone ( my old method).
EVENT_WAYPOINT is the way to go. if there's no player in the zone, the scripts need not be active anyway.
I've never tried EVENT_ENTERZONE , but I can tell you without even trying it; EVENT_WAYPOINT is better because the script is checked with each grid movement, so long as there is a player in the zone.
I haven't seen any lag problems with this either.
No wonder it's not working - this is a big problem for me as the boat will never make be able to cycle through butcher or freeport with a player being in all 3 zones.
Reply With Quote
  #15  
Old 04-19-2010, 12:00 PM
mixxit
Hill Giant
 
Join Date: Sep 2006
Posts: 155
Default

Wait a minute.. that can't be right at all because when i'm in OOT and set the qglobal 2 to the boat will spawn fine at the other side. So perl is running in the static zones.

I also can confirm that the static zones can update Qglobals because when OOT first boots up an invisible NPC sets a qglobal to 0 which resets the whole process.

I am seeing qglobal == 1 when i check the table so I know that the loop in OOT is seeing qglobal being 0, spawning the boat which itself sets the qglobal to 1 (i'm on my way to freeport).

What the hell is wrong?!
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 08:45 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 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3