gwnavruntime/queries/utils/bubblearrayqueries.h Source File
Go to the documentation of this file.
9 #ifndef Navigation_BubbleArrayQueries_H
10 #define Navigation_BubbleArrayQueries_H
22 class BubbleArrayQueries
25 BubbleArrayQueries() { m_bubbleArray =
KY_NULL; }
27 void Init(
const BubbleArray* bubbleArray) { m_bubbleArray = bubbleArray; }
29 struct RayCastFromCornerInputOutput
31 RayCastFromCornerInputOutput() : m_startCornerIdx(
KyUInt32MAXVAL), m_dir2d(Vec2f::Zero()),
39 KyUInt32 m_collisionSegmentStartCornerIdx;
40 KyUInt32 m_collisionSegmentEndCornerIdx;
47 Collision_OppositeSide,
48 Collision_StartCorner,
53 void RayCastFromCorner(RayCastFromCornerInputOutput& rayCastFromCornerInputOuput);
55 bool RayCanGoFromCorner(
KyUInt32 cornerIdx,
const Vec3f& dest);
57 void CollectIntersectingBubbles(
KyUInt32 startCornerIdx,
const Vec2f& dir2d,
RotationDirection rotDir, KyArrayPOD<KyUInt32>& intersectingBubbles, ScopedDisplayList* displayList);
60 void CastRayInTheStripForward(RayCastFromCornerInputOutput& rayCastFromBubbleInputOuput,
62 void CastRayInTheStripBackward(RayCastFromCornerInputOutput& rayCastFromBubbleInputOuput,
65 void ResolveWhenRayGoesOnOppositeBubble(RayCastFromCornerInputOutput& rayCastFromBubbleInputOuput,
68 bool IsStartOrEndBubble(
KyUInt32 cornerIdx)
70 BubbleType bubbleType = m_bubbleArray->At(cornerIdx).GetType();
71 return bubbleType == StartBubble || bubbleType == EndBubble;
80 const BubbleArray* m_bubbleArray;
87 #endif //Navigation_BubbleArrayQueries_H
#define KY_NULL
Null value.
Definition: types.h:247
RotationDirection
Defines the 4 possible cases of possibly constrained rotation in the horizontal plane for a given ele...
Definition: rotation.h:20
BubbleType
Defines the type of a bubble accordingly to the place it has in a BubbleArray, a BubbleList, etc.
Definition: bubble.h:26
Definition: gamekitcrowddispersion.h:20
unsigned int KyUInt32
Type used internally to represent an unsigned 32-bit integer.
Definition: types.h:36
#define KyUInt32MAXVAL
The maximum value that can be stored in the KyUInt32 variable type.
Definition: types.h:226