EQEmulator Forums

EQEmulator Forums (https://www.eqemulator.org/forums/index.php)
-   Development::Development (https://www.eqemulator.org/forums/forumdisplay.php?f=590)
-   -   Experimental Code: Stop mobs hopping when pathing - FindBestZ tweaks (https://www.eqemulator.org/forums/showthread.php?t=23934)

Zandig 11-30-2007 01:02 AM

I've downloaded the latest Win32 release: EQEmu-0.7.0-1065

==11/29/2007
FatherNitwit: (Derision) Fix BestZ pathing cleanup code top stop hopping.
FatherNitwit: (Derision) New fix-z-on-load feature.

and tested a few zones that always drove me mad with the hopping:

fieldofbone
frontiermtns

The mobs are still hopping like mad in these zones.
I'll test out some other zones soon.

Derision 11-30-2007 01:20 AM

Quote:

Originally Posted by Zandig (Post 140689)
I've downloaded the latest Win32 release: EQEmu-0.7.0-1065

and tested a few zones that always drove me mad with the hopping:

fieldofbone
frontiermtns

The mobs are still hopping like mad in these zones.
I'll test out some other zones soon.

Yes, the Win32 release has been compiled with two of the three features disabled, so you will still get hopping between waypoints. You could try
the Zone.exe that Rogean posted a little earlier in this thread, or I will attempt to build a Win32 release with all 3 options enabled in the next few days.

Zandig 11-30-2007 01:27 AM

Quote:

Originally Posted by Derision (Post 140690)
Yes, the Win32 release has been compiled with two of the three features disabled, so you will still get hopping between waypoints. You could try
the Zone.exe that Rogean posted a little earlier in this thread, or I will attempt to build a Win32 release with all 3 options enabled in the next few days.

Thanks Derision,

I will give that a try.

A proper Win32 release with all the options enabled would be greatly appreciated.

fathernitwit 11-30-2007 02:16 AM

OK, by popular demand (aka one dude who cant build), I reworked this stuff to be runtime configurable using the rules system.

Zandig 11-30-2007 03:35 AM

Quote:

Originally Posted by Rogean (Post 140676)
Http://www.rogean.com/Zone-BestZ.exe

Haven't tested it myself. Test it out and let me know how it works out. If it looks good I'll commit to code.

Tested various zones and it looks really good so far.
Hopping is gone.
What a sweet fix!

krusher 12-01-2007 04:05 AM

Pathing Fix
 
I have created a wiki page listing the new rules required for the pathing Z fix.

Krusher

Cripp 12-01-2007 06:13 AM

to make the rules work(or to even compile properly).. need to add them to the rulesys..

Code:

--- ruletypes.h        2007/11/14 06:13:36        1.11
+++ ruletypes.h        2007/12/01 18:11:14        1.12
@@ -84,6 +84,17 @@
 RULE_BOOL (NPC, UseItemBonusesForNonPets, true)
 RULE_CATEGORY_END()
 
+RULE_CATEGORY( Map )
+RULE_BOOL ( Map, FixPathingZAtWaypoints, false )
+RULE_BOOL ( Map, FixPathingZWhenMoving, false )
+RULE_BOOL ( Map, FixPathingZOnSendTo, false )
+RULE_BOOL ( Map, FixPathingZWhenLoading, false )
+RULE_REAL ( Map, FixPathingZMaxDeltaSendTo, 20.0 )
+RULE_REAL ( Map, FixPathingZMaxDeltaLoading, 20.0 )
+RULE_REAL ( Map, FixPathingZMaxDeltaMoving, 20.0 )
+RULE_REAL ( Map, FixPathingZMaxDeltaWaypoint, 20.0 )
+RULE_CATEGORY_END()
+
 #undef RULE_CATEGORY
 #undef RULE_INT
 #undef RULE_REAL

Code:

--- waypoints.cpp        2007/11/30 19:06:27        1.6
+++ waypoints.cpp        2007/12/01 18:11:14        1.7
@@ -31,6 +31,7 @@
 #include "parser.h"
 #include "StringIDs.h"
 #include "../common/MiscFunctions.h"
+#include "../common/rulesys.h"
 #include "features.h"
 
 static inline float ABS(float x) {

Edit:: im not sure if this was already added to the nightly builds or not.. but it wasnt in cvs.

Zandig 12-04-2007 05:32 AM

Quote:

Originally Posted by fathernitwit (Post 140693)
OK, by popular demand (aka one dude who cant build), I reworked this stuff to be runtime configurable using the rules system.


Quote:

Originally Posted by krusher (Post 140717)
I have created a wiki page listing the new rules required for the pathing Z fix.

Krusher

Thanks all.
Tested with 0.7.0-1068 and it works a treat.

moydock 12-04-2007 10:59 AM

Thanks guys, really excited about this new feature.

moydock 12-04-2007 12:42 PM

Working great, only problem i've noticed is when a mob goes up a steep hill or maybe it's just a certain change in his z coordinate, he goes under the world. However he does pop back up after a couple seconds. Still a huge improvement.

I may have not set it up right though, not exactly sure what the 'rule system' is.

Zandig 12-06-2007 05:24 AM

Quote:

Originally Posted by moydock (Post 140771)
I may have not set it up right though, not exactly sure what the 'rule system' is.

It has to be set up in the database.

Here is how I have mine set up (working very well):

rule_sets
http://img216.imageshack.us/img216/6...setsnz6.th.jpg

rule_values
http://img229.imageshack.us/img229/3...lueskj5.th.jpg

Thats all there is to it!

moydock 12-06-2007 05:50 PM

Sweet thanks, got it working, still seeing them go under when climbing steep hills. Not sure if that's fixable. I haven't upgraded to the newest build though, didn't see any fixes in the log. Btw do you know what the Map:FixPathingZatWaypoints is for?

Derision 12-07-2007 10:19 AM

Quote:

Originally Posted by moydock (Post 140803)
still seeing them go under when climbing steep hills. Not sure if that's fixable.


I've seen this happen in Dreadlands where one waypoint is on one side of a large mountain
and the next waypoint is on the other side. The movement code plots a vector between the
two waypoints which goes right through the middle of the mountain (under the world).

The BestZ code as currently implemented takes the mobs current Z position and looks downward to find the ground. If the mob is already under the world, it will either do nothing, or in the worst case, e.g. Dreadlands, which for some reason has an invisible 'floor' under the world at Z=-210, it will push the mob even further down.

I just made a quick hack to the code to make the BestZ code look up instead of down, and in the
case of the particular mob I was looking at in Dreadlands which pathed over a steep hill, it seemed
to have the desired effect of stopping it going under the world, i.e. if it was under the world, it pushed
it back up to the ground level.

The next step is to have the code look up AND down and decide which direction to push the mob.

I don't have a lot of time to play with this much at the moment, but if I find something which seems
to work reliably, I'll post a further patch.

Derision 12-07-2007 02:16 PM

Quote:

Originally Posted by moydock (Post 140803)
still seeing them go under when climbing steep hills. Not sure if that's fixable.

If you're using the PEQ Ykesha DB could you give me some test cases of mobs that path under the world, i.e. which zone they are in, then target them and do #npcstats and #wpinfo and give me the NPCID and Grid number ?

moydock 12-07-2007 06:36 PM

Quote:

Originally Posted by Derision (Post 140818)
If you're using the PEQ Ykesha DB could you give me some test cases of mobs that path under the world, i.e. which zone they are in, then target them and do #npcstats and #wpinfo and give me the NPCID and Grid number ?

I'm actually using a custom db so no help there. But I can tell you this, there seems to be a height which they reach, and they always go through the hill at that height. It also seems to be the height they would normally 'hop' up to before the fix. I'm guessing this point is the z coord of the WP they're headed to.

So what if you forced the z coord of the waypoint a mob is headed to always be the highest point in the zone. Then they wouldn't go through hills and the z-fix already in place would keep them on the ground. Would that work?


All times are GMT -4. The time now is 06:04 AM.

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