Navigation
API > API/Plugins > API/Plugins/MassCrowd
Subsystem that tracks mass entities that are wandering on the zone graph. It will create custom runtime lane data to allow branching decisions.
| Name | UMassCrowdSubsystem |
| Type | class |
| Header File | /Engine/Plugins/AI/MassCrowd/Source/MassCrowd/Public/MassCrowdSubsystem.h |
| Include Path | #include "MassCrowdSubsystem.h" |
Syntax
UCLASS (MinimalAPI)
class UMassCrowdSubsystem : public UMassSubsystemBase
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → USubsystem → UWorldSubsystem → UMassSubsystemBase → UMassCrowdSubsystem
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| DebugOnMassCrowdLaneStateChanged | FDebugOnMassCrowdLaneStateChanged | MassCrowdSubsystem.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
int32 AcquireWaitingSlot
(
const FMassEntityHandle Entity, |
Acquires a slot from a specified waiting lane. Nearest vacant slot to EntityPosition is returned. | MassCrowdSubsystem.h | |
const FCrowdBranchingLaneData * GetCrowdBranchingLaneData
(
const FZoneGraphLaneHandle LaneHandle |
Returns the branching data associated to a given zone graph lane. | MassCrowdSubsystem.h | |
const FRegisteredCrowdLaneData * GetCrowdData
(
const FZoneGraphDataHandle DataHandle |
Returns the readonly runtime data associated to a given zone graph. | MassCrowdSubsystem.h | |
TOptional< FZoneGraphCrowdLaneData > GetCrowdLaneData
(
const FZoneGraphLaneHandle LaneHandle |
Returns the readonly runtime data associated to a given zone graph lane. | MassCrowdSubsystem.h | |
const FCrowdTrackingLaneData * GetCrowdTrackingLaneData
(
const FZoneGraphLaneHandle LaneHandle |
Returns the entity tracking runtime data associated to a given zone graph lane. | MassCrowdSubsystem.h | |
const FCrowdWaitAreaData * GetCrowdWaitingAreaData
(
const FZoneGraphLaneHandle LaneHandle |
Returns the waiting area runtime data associated to a given zone graph lane. | MassCrowdSubsystem.h | |
FZoneGraphTagMask GetDensityMask() |
MassCrowdSubsystem.h | ||
float GetDensityWeight
(
const FZoneGraphLaneHandle LaneHandle, |
Returns the weight for lane selection that is associated to the given lane based on its density tag. | MassCrowdSubsystem.h | |
ECrowdLaneState GetLaneState
(
const FZoneGraphLaneHandle LaneHandle |
Return the current state of a lane. | MassCrowdSubsystem.h | |
bool HasCrowdDataForZoneGraph
(
const FZoneGraphDataHandle DataHandle |
MassCrowdSubsystem.h | ||
void OnEntityLaneChanged
(
const FMassEntityHandle Entity, |
Callback from the lane tracker processor to indicates a mass entity changing lane. | MassCrowdSubsystem.h | |
void RebuildLaneData() |
Clears and rebuilds all lane and intersection data for registered zone graphs using the current settings. | MassCrowdSubsystem.h | |
void ReleaseWaitingSlot
(
const FMassEntityHandle Entity, |
Releases previously acquired slot from a specified waiting lane. | MassCrowdSubsystem.h | |
bool SetLaneState
(
const FZoneGraphLaneHandle LaneHandle, |
Changes the state of a lane. | MassCrowdSubsystem.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void BuildLaneData
(
FRegisteredCrowdLaneData& LaneData, |
Populates the crowd lane data array with all existing lane in the zone graph. | MassCrowdSubsystem.h | |
FCrowdBranchingLaneData & CreateBranchingData
(
const int32 LaneIndex, |
Creates dedicated structure to hold data of a branching lane. | MassCrowdSubsystem.h | |
FCrowdTrackingLaneData & CreateTrackingData
(
const int32 LaneIndex, |
Creates and initializes the occupancy data of a lane. | MassCrowdSubsystem.h | |
void CreateWaitSlots
(
const int32 CrossingLaneIndex, |
MassCrowdSubsystem.h | ||
FZoneGraphCrowdLaneData * GetMutableCrowdLaneData
(
const FZoneGraphLaneHandle LaneHandle |
Returns the modifiable runtime data associated to a given zone graph lane. | MassCrowdSubsystem.h | |
void OnEnterTrackedLane
(
const FMassEntityHandle Entity, |
Callback to keep count of entities currently on a given lane. | MassCrowdSubsystem.h | |
void OnExitTrackedLane
(
const FMassEntityHandle Entity, |
Callback to keep count of entities currently on a given lane. | MassCrowdSubsystem.h | |
void PostZoneGraphDataAdded
(
const AZoneGraphData* ZoneGraphData |
MassCrowdSubsystem.h | ||
void PreZoneGraphDataRemoved
(
const AZoneGraphData* ZoneGraphData |
MassCrowdSubsystem.h | ||
void UpdateDensityMask() |
MassCrowdSubsystem.h |
Overridden from UWorldSubsystem
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void PostInitialize() |
MassCrowdSubsystem.h |
Overridden from USubsystem
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void Deinitialize() |
MassCrowdSubsystem.h | ||
virtual void Initialize
(
FSubsystemCollectionBase& Collection |
USubsystem BEGIN. | MassCrowdSubsystem.h |