PathFinding
This class implements the PathFinding algorithm using A-Star.
TODO: PathFinding Constructors
Methods
PathFinding.GetPath(dst_x, dst_y, ignoremob)
PathFinding.GetPath(dst_x, dst_y, ignoremob)
Compute the path for the given destination and returns a list of Tile (coordinates).
Parameters
dst_xInt32
Destination X.
dst_yInt32
Destination Y.
ignoremobBoolean
Ignores any mobiles with the path calculation.
Return
List[Tile]
List of Tile objects, each holds a .X and .Y coordinates.
PathFinding.Go(r)
PathFinding.Go(r)
Check if a destination is reachable.
Parameters
rPathFinding.Route
A customized Route object.
Return
Boolean
True: if a destination is reachable.
PathFinding.PathFindTo(x, y, z)
PathFinding.PathFindTo(x, y, z)
Go to the given coordinates using Razor pathfinding. Go to the given coordinates using Razor pathfinding.
Parameters
xPoint3D Int32
X map coordinates or Point3D
yInt32
Y map coordinates
zInt32
Z map coordinates
Return
Void
PathFinding.RunPath(path, timeout, debugMessage, useResync)
PathFinding.RunPath(path, timeout, debugMessage, useResync)
Parameters
pathList[Tile] timeoutSingle debugMessageBoolean useResyncBoolean
Return
Boolean
PathFinding.Tile(x, y)
PathFinding.Tile(x, y)
Create a Tile starting from X,Y coordinates (see PathFindig.RunPath)
Parameters
xInt32
X coordinate
yInt32
Y coordinate
Return
Tile
Returns a Tile object
PathFinding.WalkPath(path, timeout, debugMessage, useResync)
PathFinding.WalkPath(path, timeout, debugMessage, useResync)
Parameters
pathList[Tile] timeoutSingle debugMessageBoolean useResyncBoolean
Return
Boolean
PathFinding.runPath(timeout, debugMessage, useResync)
PathFinding.runPath(timeout, debugMessage, useResync)
Parameters
timeoutSingle
Maximum amount of time to run the path. (default: -1, no limit)
debugMessageBoolean
Outputs a debug message.
useResyncBoolean
ReSyncs the path calculation.
Return
Boolean
True: if it finish the path in time. False: otherwise
PathFinding.walkPath(timeout, debugMessage, useResync)
PathFinding.walkPath(timeout, debugMessage, useResync)
Parameters
timeoutSingle debugMessageBoolean useResyncBoolean
Return
Boolean