gwnavgeneration/input/inputcellinfogrid.h Source File
Go to the documentation of this file.
19 class GeneratorSystem;
22 class InputCellInfoGrid
27 InputCellInfoGrid() {}
29 void Add(GeneratorSectorBuilder* sectorBuilder,
const CellPos& cellPos, Ptr<BlobHandler<InputCellBlob> > inputCellHandler =
nullptr)
31 InputCellInfoArrayAtPos* inputCellInfoArrayAtPos = m_grid.GetOrCreate(cellPos.x, cellPos.y);
33 InputCellInfo inputCellInfo(sectorBuilder, cellPos, inputCellHandler);
35 KY_ASSERT(inputCellInfoArrayAtPos->DoesContain(inputCellInfo) ==
false);
36 inputCellInfoArrayAtPos->PushBack(inputCellInfo);
39 InputCellInfoArrayAtPos* GetArrayAtPos(
const CellPos& pos) {
return m_grid.Get(pos.x, pos.y); }
40 InputCellInfoArrayAtPos* GetArrayAtPos(
CellCoord x,
CellCoord y) {
return m_grid.Get(x, y); }
42 Ptr<InputCellInfoArrayAtPos>* GetArrayOfArray() {
return m_grid.GetElements(); }
43 KyUInt32 GetArrayOfArrayCount() {
return m_grid.GetElementsCount(); }
46 DenseGridAndArrayOfRefPtr<InputCellInfoArrayAtPos> m_grid;
Vec2i CellPos
A type that represents the position of a cell within a 2D grid.
Definition: navmeshtypes.h:30
std::uint32_t KyUInt32
uint32_t
Definition: types.h:29
#define KY_DEFINE_NEW_DELETE_OPERATORS(MemStat)
This macro defines new and delete operators.
Definition: memory.h:132
The Autodesk Navigation namespace.
Definition: gamekitcrowddispersion.cpp:17
KyInt32 CellCoord
A type that represents the placement of a cell on one axis of a 2D grid.
Definition: navmeshtypes.h:29