Empeld
Empeld plugin documentation.
essentials.action.Pathing.WorldPathing Class Reference

World pathing is a helper class to assist in using the pathing job to figure out how to get from point a to point b More...

Public Member Functions

 WorldPathing (Func< Vector3i, Vector3i, IPathingEngine > engine)
 
 WorldPathing (IPathCostEngine costEngine)
 
 WorldPathing (IWorldReadonly world)
 
PathingJob CreatePathingJob (Vector3i start, Vector3i end)
 

Protected Attributes

ITaskScheduler TaskScheduler
 

Detailed Description

World pathing is a helper class to assist in using the pathing job to figure out how to get from point a to point b

Constructor & Destructor Documentation

◆ WorldPathing() [1/3]

essentials.action.Pathing.WorldPathing.WorldPathing ( Func< Vector3i, Vector3i, IPathingEngine engine)
23  {
24  this.InjectDependencies();
25  _initEngine = engine;
26  }

◆ WorldPathing() [2/3]

essentials.action.Pathing.WorldPathing.WorldPathing ( IPathCostEngine  costEngine)
29  {
30  this.InjectDependencies();
31  _initEngine = (start, end) => new AStarEngine(start, end, costEngine, AStarEngine.NEIGHBORS_AXIS_ALIGNED);
32  }
The AStar implementation of 3D path-finding
Definition: AStarEngine.cs:10

◆ WorldPathing() [3/3]

essentials.action.Pathing.WorldPathing.WorldPathing ( IWorldReadonly  world)
35  :this(new DefaultWorldCostEngine(world))
36  { }

Member Function Documentation

◆ CreatePathingJob()

PathingJob essentials.action.Pathing.WorldPathing.CreatePathingJob ( Vector3i  start,
Vector3i  end 
)
39  {
40  var engine = _initEngine(start, end);
41  var job = new PathingJob(engine);
42  this.TaskScheduler.ScheduleTask( job );
43  return job;
44  }
IScheduledTask ScheduleTask(ITask task)
Schedules the task.
ITaskScheduler TaskScheduler
Definition: WorldPathing.cs:20

Member Data Documentation

◆ TaskScheduler

ITaskScheduler essentials.action.Pathing.WorldPathing.TaskScheduler
protected

Attribute: Dependency


The documentation for this class was generated from the following file: