Plasma Engine  2.0
Loading...
Searching...
No Matches
GridNavmesh_inl.h
1#pragma once
2
3template <class CellData>
5 const plGameGrid<CellData>& grid, CellComparator isSameCellType, void* pPassThrough, CellBlocked isCellBlocked, void* pPassThrough2)
6{
7 m_NodesGrid.CreateGrid(grid.GetGridSizeX(), grid.GetGridSizeY());
8
9 UpdateRegion(plRectU32(grid.GetGridSizeX(), grid.GetGridSizeY()), isSameCellType, pPassThrough, isCellBlocked, pPassThrough2);
10
11 CreateGraphEdges();
12}
plGameGrid is a general purpose 2D grid structure that has several convenience functions which are of...
Definition GameGrid.h:13
plUInt16 GetGridSizeX() const
Returns the number of cells along the X axis.
Definition GameGrid.h:51
plUInt16 GetGridSizeY() const
Returns the number of cells along the Y axis.
Definition GameGrid.h:54
void CreateGrid(plUInt16 uiSizeX, plUInt16 uiSizeY)
Clears all data and reallocates the grid with the given dimensions.
Definition GameGrid_inl.h:18
bool(*)(plUInt32, plUInt32, void *) CellComparator
Callback that determines whether the cell with index uiCell1 and the cell with index uiCell2 represen...
Definition GridNavmesh.h:39
void CreateFromGrid(const plGameGrid< CellData > &grid, CellComparator isSameCellType, void *pPassThroughSame, CellBlocked isCellBlocked, void *pPassThroughBlocked)
Creates the navmesh from the given plGameGrid.
Definition GridNavmesh_inl.h:4
bool(*)(plUInt32, void *) CellBlocked
Callback that determines whether the cell with index uiCell is blocked entirely (for every type of un...
Definition GridNavmesh.h:43