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_xInt32Destination X.
dst_yInt32Destination Y.
ignoremobBooleanIgnores any mobiles with the path calculation.
Return
List[Tile]List of Tile objects, each holds a .X and .Y coordinates.
PathFinding.Go(r)
Check if a destination is reachable.
Parameters
rPathFinding.RouteA customized Route object.
Return
BooleanTrue: 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
xInt32
Point3DX map coordinates or Point3D
yInt32Y map coordinates
zInt32Z map coordinates
PathFinding.RunPath(path, timeout, debugMessage, useResync)
PathFinding.RunPath(path, timeout, debugMessage, useResync)
Parameters
pathList[Tile]
timeoutSingle
debugMessageBoolean
useResyncBoolean
PathFinding.Tile(x, y)
Create a Tile starting from X,Y coordinates (see PathFindig.RunPath)
Parameters
xInt32X coordinate
yInt32Y coordinate
Return
TileReturns a Tile object
PathFinding.WalkPath(path, timeout, debugMessage, useResync)
PathFinding.WalkPath(path, timeout, debugMessage, useResync)
Parameters
pathList[Tile]
timeoutSingle
debugMessageBoolean
useResyncBoolean
PathFinding.runPath(timeout, debugMessage, useResync)
PathFinding.runPath(timeout, debugMessage, useResync)
Parameters
timeoutSingleMaximum amount of time to run the path. (default: -1, no limit)
debugMessageBooleanOutputs a debug message.
useResyncBooleanReSyncs the path calculation.
Return
BooleanTrue: if it finish the path in time. False: otherwise
PathFinding.walkPath(timeout, debugMessage, useResync)
PathFinding.walkPath(timeout, debugMessage, useResync)
Parameters
timeoutSingle
debugMessageBoolean
useResyncBoolean