A simple-to-use A* Pathing implementation [More]
To download this library for your Linux/Mac installation, enter this on your command line:
Want some effective but easy-to-use pathing in your game? Give this a spin.
Features & Functionality:
Warning: Cannot path between multiple maps. This is because there are many possible implementations you can have that would use multiple maps. To work around this, just use Easy AStar to path on the same maps, and then use alternate pathing methods to facilitate movement between maps.
Release Notes:7/7/11 - Several versions released today.
Made the step_towards_astar_path pathing data list into a variable of type tmp so it will not save on your mobs.
Fixed bug in step_towards_astar_path() related to paths of length one being unable to reach destinations 2 distance away if they were not able to be reached via a standard step_towards.
Made demo more robust with a larger interface and runtime compile toggled methods of pathing.
Added support for two more functions:
atom/movable.GetAStarPathTo() works identically to GetAStarPath but does not require the movable atom is passed as the first arg.
Global function step_towards_astar_path() works identically to step_towards except it utilizes astar pathing. The list of turfs is managed automatically.
For improved efficiency, all pathing debug code is now removed at compile time unless you #DEFINE PATHING_DEBUG in your .dme file before the first //BEGIN.
Changed implementation of maximum distance from destination mechanic to utilize a whole list of turfs to check against for pathing success instead of simply attempting to path to the nearest enterable turf from the start.
4/6/10 - v1.2 released. Changed GM debugging command to include less machine-intensive version. Made granting/removing GM verbs easier by moving them to a global proc list. Set pathing process to background to prevent from timing out on extremely long pathing assignments.
3/13/10 - v1.1 released. Commented out some unnecessary variable checks and optimized list handling for even more efficiency.
3/13/10 - v1.0 released. Improved in terms of efficiency, correct pathing accuracy, and features.
To give some credit where it was due: procs from AbyssDragon's Basic Math were utilized to boost efficiency.
Copyright © 2015 BYOND. All rights reserved.