fp: Add a simplified swarming algorithm
This commit is contained in:
+6
-7
@@ -80,8 +80,14 @@ enum FP_GameDirection
|
||||
FP_GameDirection_Count,
|
||||
};
|
||||
|
||||
enum FP_GameWaypointFlag
|
||||
{
|
||||
FP_GameWaypointFlag_NonInterruptible = 1 << 0,
|
||||
};
|
||||
|
||||
struct FP_GameWaypoint
|
||||
{
|
||||
uint32_t flags;
|
||||
FP_GameWaypointType type;
|
||||
FP_GameDirection type_direction; // Used if type is `FP_GameWaypointType_Side`
|
||||
FP_GameEntityHandle entity; // The entity to move to
|
||||
@@ -122,12 +128,6 @@ struct FP_GameRenderSprite
|
||||
uint64_t started_at_clock_ms;
|
||||
};
|
||||
|
||||
struct FP_GameSwarm
|
||||
{
|
||||
Dqn_FArray<FP_SentinelList<FP_GameEntityHandle>, 8> slots;
|
||||
Dqn_usize slots_active;
|
||||
};
|
||||
|
||||
struct FP_GameEntity
|
||||
{
|
||||
FP_GameEntity *next;
|
||||
@@ -153,7 +153,6 @@ struct FP_GameEntity
|
||||
|
||||
FP_SentinelList<FP_GameWaypoint> waypoints;
|
||||
FP_GameEntityHandle aggro_slot[FP_GameDirection_Count];
|
||||
FP_GameSwarm swarm[FP_GameDirection_Count];
|
||||
|
||||
// NOTE: The entity hit box is positioned at the center of the entity.
|
||||
Dqn_V2 local_hit_box_size;
|
||||
|
||||
Reference in New Issue
Block a user