Fork me on GitHub
Random Creature Movement behavior
Post: #21
(06-22-2014, 11:48 PM)mityada Wrote: I have noticed that random movement is not truly random on retail. Below are some plotted movement paths of Scarabs from Zul'Farrak:
[Image: RbPwFCGs.png][Image: 3JuHtrys.png][Image: cvFS18Zs.png][Image: NEENHwrs.png][Image: gdVLuI5s.png]
As you can see, sometimes there are some points that occur much more often than others. Sometimes the path "draws" some shapes. What can it be?

At a glance it seems to me like they're plotting random points that are biased, and then guaranteed to give something like 45 to 160 degree turns on random points, also with a maximum range so that the monster always stays within the same general area even if it's moving randomly. Alternatively perhaps before a random move they check the mob's distance from the center point and forcibly redirect it at least 45 to 180 degrees back towards the center so that the mob will either go in a long circle around the middle point or back towards it entirely. Either of those implementations would produce movement similar to that.

It's quite obvious in any case that the random points are oscillating around a center point, so clearly they're not "true" random or the mob's location would diverge significantly from where it was spawned.
Reply
Post: #22
May be it worth implementing something like that in CMaNGOS? RandomMovementGenerator currently selects just a random point, so circle should be filled evenly.
Reply
Post: #23
I believe this discussion is for that reason, to determine how best to implement and try and figure out how Blizz does it.
Reply
Post: #24
(06-23-2014, 10:36 AM)Sirenfal Wrote:
(06-22-2014, 11:48 PM)mityada Wrote: I have noticed that random movement is not truly random on retail. Below are some plotted movement paths of Scarabs from Zul'Farrak:
[Image: RbPwFCGs.png][Image: 3JuHtrys.png][Image: cvFS18Zs.png][Image: NEENHwrs.png][Image: gdVLuI5s.png]
As you can see, sometimes there are some points that occur much more often than others. Sometimes the path "draws" some shapes. What can it be?

At a glance it seems to me like they're plotting random points that are biased, and then guaranteed to give something like 45 to 160 degree turns on random points, also with a maximum range so that the monster always stays within the same general area even if it's moving randomly. Alternatively perhaps before a random move they check the mob's distance from the center point and forcibly redirect it at least 45 to 180 degrees back towards the center so that the mob will either go in a long circle around the middle point or back towards it entirely. Either of those implementations would produce movement similar to that.

It's quite obvious in any case that the random points are oscillating around a center point, so clearly they're not "true" random or the mob's location would diverge significantly from where it was spawned.

Perhaps the apparent bias is just a consequence of a minimum travel distance? For example, if a unit was forced to travel a minimum of 6-yards within a fixed 8-yard radius, wouldn't that result in a triangular pattern similar to that?

All I'm thinking is that this system is probably(/hopefully) very simple, yet in a elegant way.
[-] The following 1 user says Thank You to Efonius for this post:
  â€¢ X-Savior
Reply


Possibly Related Threads...
Thread Author Replies Views Last Post
Question Make creature stop and stay on waypoint stavaren 4 698 03-02-2017, 04:22 PM
Last Post: stavaren
  Help needed to determine correct movement behavior namreeb 0 377 12-02-2016, 07:21 PM
Last Post: namreeb
  Determining NPC Movement and Position in Client Kazadoom 1 554 11-07-2016, 07:16 AM
Last Post: Kazadoom
  purpose of make some movement ack message magiceye 2 1,498 10-16-2015, 01:54 AM
Last Post: magiceye
  check movement position magiceye 0 897 09-12-2015, 07:07 AM
Last Post: magiceye
  Movement sync magiceye 1 1,207 08-18-2015, 07:36 PM
Last Post: namreeb
  Linked Movement - Npc Speed Differences (BUG) X-Savior 0 1,099 04-06-2015, 03:18 AM
Last Post: X-Savior
  NPC Movement and Scripts Trigger By Game Event X-Savior 1 1,606 01-06-2015, 10:27 AM
Last Post: Schmoozerd
  Per creature spell damage modifier? ul1984 2 2,477 10-14-2014, 08:40 AM
Last Post: ul1984
  Creature-Movement Synchronisation fgreinus 5 4,870 03-24-2013, 05:59 AM
Last Post: SADraco

Forum Jump:


Users browsing this thread: 1 Guest(s)

Continued MaNGOS | Return to Top | | Lite (Archive) Mode | RSS Syndication