🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Pre-Calculated Pathfinding using beacons

Started by
13 comments, last by rrc2soft 22 years, 11 months ago
Just one question : how do you extend the concept to a node based graph, rather than cell based map ?
Nice idea, though
-----------------------------Sancte Isidore ora pro nobis !
Advertisement
>Just one question : how do you extend the concept to a node based graph, rather than cell based map ?
>Nice idea, though

Ahw, i dunno what are you questioning me (''cause my bad english i suppose )
IF you''re questioning me about how i make the beacons + adjacents (they''re like a graph of nodes), first i calculate all the beacons (using a "check corner" algorithm), and next i calculate with bresenhams the adjacent beacons for every beacon (and voilá!, the graph is done )
IF you''re questioning me about extending the "beacons algorithm" to a node based graph... I suppose I can''t extend it, since all the nodes are like "corners", ''cause they discover new ways.

Hoping to be useful
Rodrigo (1/2 RRC²Soft)
RPG game programming and tutorials - Playable demo in Progress!
http://www.rrc2soft.com
My question was your second answer ... I was thinking of what would happen if your method is used in a graph like in Half-Life.
I suppose I could have figured out by reading more carefully
-----------------------------Sancte Isidore ora pro nobis !
quote: Original post by rrc2soft
Beacons are calculated and stored during mapmaking (and also the adjacent beacons for every beacon). So the only thing that it''s calculated in run-time is adjacents for start & end point.

If so, then your applet is very misleading. When I reposition the start and/or end points, and click ''check for beacons'', it shows me a different set of orange squares (which are labelled ''beacons''). There is usually some overlap, but there is almost always a few beacons that weren''t shown before. This implies that the beacons change position every time the start and finish positions are changed.

Oops. I should have written better the docs. For an algorithm independent of the start-end point you must use the "check corners" option. This will check first the corners of the map, so the flooding algorithm is unnecessary. Also, without the "check corners" option checked, there''s some wrong pathfinding cases.
If you discovered a map that causes problems with the "check corners" option, please send it to me (in a 256 colors gif)

Thanks.
RPG game programming and tutorials - Playable demo in Progress!
http://www.rrc2soft.com

This topic is closed to new replies.

Advertisement