Forums WoW Modding Support Archives Azerothcore Discord Archives [DiscordArchive] When calculating a creature's distance to a waypoint, should object size be taken into account the w

[DiscordArchive] When calculating a creature's distance to a waypoint, should object size be taken into account the w

[DiscordArchive] When calculating a creature's distance to a waypoint, should object size be taken into account the w

rektbyfaith
Administrator
0
06-08-2025, 11:39 PM
#1
Archived author: Mithria • Posted: 2025-06-08T23:39:35.749000+00:00
Original source

When calculating a creature's distance to a waypoint, should object size be taken into account the way GetDistance() does, or should it be calculated from the direct center of the creatures bounding box?
rektbyfaith
06-08-2025, 11:39 PM #1

Archived author: Mithria • Posted: 2025-06-08T23:39:35.749000+00:00
Original source

When calculating a creature's distance to a waypoint, should object size be taken into account the way GetDistance() does, or should it be calculated from the direct center of the creatures bounding box?

rektbyfaith
Administrator
0
06-08-2025, 11:41 PM
#2
Archived author: Mithria • Posted: 2025-06-08T23:41:07.670000+00:00
Original source

I have a PR open to implement the start_nearest_waypoint smart action, and it works fine, but if multiple waypoints intersect a creatures size, then the first one evaluated is always selected as closest, even if there is a waypoint closer to their origin
rektbyfaith
06-08-2025, 11:41 PM #2

Archived author: Mithria • Posted: 2025-06-08T23:41:07.670000+00:00
Original source

I have a PR open to implement the start_nearest_waypoint smart action, and it works fine, but if multiple waypoints intersect a creatures size, then the first one evaluated is always selected as closest, even if there is a waypoint closer to their origin

rektbyfaith
Administrator
0
06-08-2025, 11:41 PM
#3
Archived author: Mithria • Posted: 2025-06-08T23:41:29.269000+00:00
Original source

Unsure which way is the correct way to implement
rektbyfaith
06-08-2025, 11:41 PM #3

Archived author: Mithria • Posted: 2025-06-08T23:41:29.269000+00:00
Original source

Unsure which way is the correct way to implement

rektbyfaith
Administrator
0
06-08-2025, 11:42 PM
#4
Archived author: Mithria • Posted: 2025-06-08T23:42:24.237000+00:00
Original source

FYI I have it working both ways on 2 of my local branches, just trying to decide which to push
rektbyfaith
06-08-2025, 11:42 PM #4

Archived author: Mithria • Posted: 2025-06-08T23:42:24.237000+00:00
Original source

FYI I have it working both ways on 2 of my local branches, just trying to decide which to push

rektbyfaith
Administrator
0
06-08-2025, 11:45 PM
#5
Archived author: Mithria • Posted: 2025-06-08T23:45:26.790000+00:00
Original source

Intuitively, to me, it would make sense that the _closest_ waypoint gets picked, even in the case where multiple waypoints are within the creatures bounds. The current GetDistance() results in weird behavior and wrong waypoint selection in cases where a group of creatures all spawn less than 1 yard from each other, and attempt to begin separate waypoints from each other
rektbyfaith
06-08-2025, 11:45 PM #5

Archived author: Mithria • Posted: 2025-06-08T23:45:26.790000+00:00
Original source

Intuitively, to me, it would make sense that the _closest_ waypoint gets picked, even in the case where multiple waypoints are within the creatures bounds. The current GetDistance() results in weird behavior and wrong waypoint selection in cases where a group of creatures all spawn less than 1 yard from each other, and attempt to begin separate waypoints from each other

Recently Browsing
 1 Guest(s)
Recently Browsing
 1 Guest(s)