Navigation
API > API/Plugins > API/Plugins/OnlineSubsystemUtils
A beacon host used for taking reservations for an existing game session
| Name | ASpectatorBeaconHost |
| Type | class |
| Header File | /Engine/Plugins/Online/OnlineSubsystemUtils/Source/OnlineSubsystemUtils/Public/SpectatorBeaconHost.h |
| Include Path | #include "SpectatorBeaconHost.h" |
Syntax
UCLASS (MinimalAPI, Transient, NotPlaceable, Config=Engine)
class ASpectatorBeaconHost : public AOnlineBeaconHostObject
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → AActor → AOnlineBeaconHostObject → ASpectatorBeaconHost
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
ASpectatorBeaconHost
(
const FObjectInitializer& ObjectInitializer |
SpectatorBeaconHost.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ESpectatorReservationResult::Type AddSpectatorReservation
(
const FSpectatorReservation& ReservationRequest |
Attempts to add a spectator reservation to the beacon | SpectatorBeaconHost.h | |
virtual void DumpReservations() |
Output current state of reservations to log | SpectatorBeaconHost.h | |
virtual int32 GetMaxReservations() |
Get the maximum number of reservations allowed inside the beacon | SpectatorBeaconHost.h | |
virtual int32 GetNumConsumedReservations() |
Get the number of reservations actually used/consumed across all parties inside the beacon | SpectatorBeaconHost.h | |
virtual bool GetPlayerValidation
(
const FUniqueNetId& PlayerId, |
Obtain player validation string from spectator reservation entry | SpectatorBeaconHost.h | |
virtual int32 GetReservationCount() |
Get the current reservation count inside the beacon NOTE: This is NOT the same as the number of consumed reservations across all parties, just the total number of reservations! | SpectatorBeaconHost.h | |
USpectatorBeaconState * GetState() |
SpectatorBeaconHost.h | ||
virtual void HandlePlayerLogout
(
const FUniqueNetIdRepl& PlayerId |
Notify the beacon of a player logout | SpectatorBeaconHost.h | |
virtual bool InitFromBeaconState
(
USpectatorBeaconState* PrevState |
Initialize the spectator host beacon from a previous state/configuration all existing reservations and configuration values are preserved | SpectatorBeaconHost.h | |
virtual bool InitHostBeacon
(
int32 InMaxReservations, |
Initialize the spectator host beacon | SpectatorBeaconHost.h | |
FOnCancelationReceived & OnCancelationReceived() |
Delegate fired when a the beacon host cancels a reservation | SpectatorBeaconHost.h | |
FOnSpectatorDuplicateReservation & OnDuplicateReservation() |
Delegate fired when a the beacon detects a duplicate reservation | SpectatorBeaconHost.h | |
FOnNewPlayerAdded & OnNewPlayerAdded() |
Delegate fired when the beacon host adds a new player | SpectatorBeaconHost.h | |
FOnReservationUpdate & OnReservationChanged() |
Delegate fired when a the beacon host detects that all reservations are full | SpectatorBeaconHost.h | |
FOnReservationUpdate & OnReservationsFull() |
Crossplay Delegate fired when a the beacon host detects a reservation addition/removal | SpectatorBeaconHost.h | |
FOnSpectatorValidatePlayers & OnValidatePlayers() |
Delegate called when the beacon gets any request, allowing the owner to validate players at a higher level (bans,etc) | SpectatorBeaconHost.h | |
virtual bool PlayerHasReservation
(
const FUniqueNetId& PlayerId |
Does a given player id have an existing reservation | SpectatorBeaconHost.h | |
virtual void ProcessCancelReservationRequest
(
ASpectatorBeaconClient* Client, |
Handle a reservation cancellation request received from an incoming client | SpectatorBeaconHost.h | |
virtual void ProcessReservationRequest
(
ASpectatorBeaconClient* Client, |
Handle a reservation request received from an incoming client | SpectatorBeaconHost.h | |
void RegisterAuthTicket
(
const FUniqueNetIdRepl& InSpectatorId, |
Register user auth ticket with the reservation system Must have an existing reservation entry | SpectatorBeaconHost.h | |
virtual ESpectatorReservationResult::Type RemoveSpectatorReservation
(
const FUniqueNetIdRepl& Spectator |
Attempts to remove a spectator reservation from the beacon | SpectatorBeaconHost.h |
Overridden from AActor
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void Tick
(
float DeltaTime |
SpectatorBeaconHost.h |
Overridden from UObject
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void PostInitProperties() |
SpectatorBeaconHost.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
bool DoesSessionMatch
(
const FString& SessionId |
Does the session match the one associated with this beacon | SpectatorBeaconHost.h | |
virtual TSubclassOf< USpectatorBeaconState > GetSpectatorBeaconHostClass() |
SpectatorBeaconHost.h | ||
void NewPlayerAdded
(
const FPlayerReservation& NewPlayer |
Handle a newly added player | SpectatorBeaconHost.h | |
void NotifyReservationEventNextFrame
(
FOnReservationUpdate& ReservationEvent |
SpectatorBeaconHost.h | ||
void SendReservationUpdates() |
Update clients with current reservation information | SpectatorBeaconHost.h |