Skip to content

UAndromedaStationEventSubsystem

Kind: class Source: Source/Andromeda/Station/AndromedaStationEventSubsystem.h Base classes: UWorldSubsystem

Details

World-scoped event source and registry for station-domain gameplay events.

Public Properties

Member Type Summary
OnPawnEnteredStationAccess FAndromedaStationPawnAccessChangedSignature Broadcasts when a station reports that a pawn entered its access volume.
OnPawnExitedStationAccess FAndromedaStationPawnAccessChangedSignature Broadcasts when a station reports that a pawn exited its access volume.

Private Properties

Member Type Summary
RegisteredStations TArray< TWeakObjectPtr< AAndromedaStation > > Active stations are weak because the subsystem observes them but does not own them.

Public Methods

Member Type Summary
RegisterStation void Adds a station to the active station registry.
UnregisterStation void Removes a station from the active station registry.
RefreshPawnStationAccess void Rechecks a pawn against every registered station.
GetStationsContainingPawn TArray< AAndromedaStation * > Returns registered stations that currently contain the pawn in station access.
BroadcastPawnEnteredStationAccess void Announces a station access enter transition.
BroadcastPawnExitedStationAccess void Announces a station access exit transition.

Private Methods

Member Type Summary
CompactRegisteredStations void Removes destroyed station entries from the registry.

Members

OnPawnEnteredStationAccess

FAndromedaStationPawnAccessChangedSignature OnPawnEnteredStationAccess

Broadcasts when a station reports that a pawn entered its access volume.

OnPawnExitedStationAccess

FAndromedaStationPawnAccessChangedSignature OnPawnExitedStationAccess

Broadcasts when a station reports that a pawn exited its access volume.

RegisteredStations

TArray< TWeakObjectPtr< AAndromedaStation > > RegisteredStations

Active stations are weak because the subsystem observes them but does not own them.

RegisterStation

void UAndromedaStationEventSubsystem::RegisterStation(AAndromedaStation *Station)

Adds a station to the active station registry.

Parameters:

Name Type Description
Station AAndromedaStation * Station that can publish access events and participate in refresh queries.

UnregisterStation

void UAndromedaStationEventSubsystem::UnregisterStation(AAndromedaStation *Station)

Removes a station from the active station registry.

Parameters:

Name Type Description
Station AAndromedaStation * Station leaving play.

RefreshPawnStationAccess

void UAndromedaStationEventSubsystem::RefreshPawnStationAccess(APawn *Pawn)

Rechecks a pawn against every registered station.

Parameters:

Name Type Description
Pawn APawn * Pawn whose current station access state should be recomputed.

GetStationsContainingPawn

TArray< AAndromedaStation * > UAndromedaStationEventSubsystem::GetStationsContainingPawn(APawn *Pawn)

Returns registered stations that currently contain the pawn in station access.

Parameters:

Name Type Description
Pawn APawn * Pawn to query.

Returns:

Active stations whose access state includes Pawn.

BroadcastPawnEnteredStationAccess

void UAndromedaStationEventSubsystem::BroadcastPawnEnteredStationAccess(AAndromedaStation *Station, APawn *Pawn)

Announces a station access enter transition.

Parameters:

Name Type Description
Station AAndromedaStation * Station reporting the transition.
Pawn APawn * Pawn that entered access.

BroadcastPawnExitedStationAccess

void UAndromedaStationEventSubsystem::BroadcastPawnExitedStationAccess(AAndromedaStation *Station, APawn *Pawn)

Announces a station access exit transition.

Parameters:

Name Type Description
Station AAndromedaStation * Station reporting the transition.
Pawn APawn * Pawn that exited access.

CompactRegisteredStations

void UAndromedaStationEventSubsystem::CompactRegisteredStations()

Removes destroyed station entries from the registry.