Multiplay Hosting SDK for Unreal Engine Class Multiplay Game Server Subsystem Reference documentation for the Multiplay Game Server Subsystem class.
Read time 3 minutes
Last updated 3 hours ago Warning
We are winding down our direct support for the Unity Multiplay Game Server Hosting Service . Unity will support the Multiplay Game Server Hosting Service through March 31, 2026 . To ensure continuity for live titles, we are licensing our Multiplay Game Server Hosting software to Rocket Science Group. Learn more about them here .
Subsystem responsible for communicating with the Multiplay SDK daemon.
Include
#include "MultiplayGameServerSubsystem.h"
Syntax
UCLASS() class MULTIPLAYGAMESERVERSDK_API UMultiplayGameServerSubsystem : public UMultiplaySubsystemBase
Inherits from: MultiplaySubsystemBase .
Delegates
FAllocateDelegate
Declaration
DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FAllocateDelegate, FMultiplayAllocation, Allocation)
Return Type
FMultiplayAllocation .
FDeallocateDelegate
Declaration
DECLARE_DYNAMIC_MULTICAST_DELEGATE_OneParam(FDeallocateDelegate, FMultiplayDeallocation, Deallocation)
Return Type
FMultiplayDeallocation .
FReadyServerSuccessDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE(FReadyServerSuccessDelegate)
FReadyServerFailureDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FReadyServerFailureDelegate, FMultiplayErrorResponse, ErrorResponse)
Return Type
FMultiplayErrorResponse .
FUnreadyServerSuccessDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE(FUnreadyServerSuccessDelegate)
FUnreadyServerFailureDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FUnreadyServerFailureDelegate, FMultiplayErrorResponse, ErrorResponse)
Return Type
FMultiplayErrorResponse .
FPayloadAllocationSuccessDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FPayloadAllocationSuccessDelegate, FString, Payload)
Return Type
FString .
FPayloadAllocationFailureDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FPayloadAllocationFailureDelegate, FMultiplayPayloadAllocationErrorResponse, ErrorResponse)
Return Type
FMultiplayPayloadAllocationErrorResponse .
FPayloadTokenSuccessDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FPayloadTokenSuccessDelegate, FMultiplayPayloadTokenResponse, TokenResponse)
Return Type
FMultiplayPayloadTokenResponse .
FPayloadTokenFailureDelegate
Declaration
DECLARE_DYNAMIC_DELEGATE_OneParam(FPayloadTokenFailureDelegate, FMultiplayPayloadTokenResponse, ErrorResponse)
Return Type
FMultiplayPayloadTokenResponse .
Constructors
UMultiplayGameServerSubsystem()
Default constructor for the Authentication subsystem.
Declaration
UMultiplayGameServerSubsystem()
UMultiplayGameServerSubsystem(FVTableHelper&)
Override constructor for forward declaration.
Declaration
UMultiplayGameServerSubsystem(FVTableHelper& Helper)
Parameters
Name Description Helper Helper class to invoke specialized hot-reload constructor.
Destructors
~UMultiplayGameServerSubsystem()
Default destructor for the Authentication subsystem.
Declaration
virtual ~UMultiplayGameServerSubsystem()
Overrides
Initialize(FSubsystemCollectionBase&)
Initialize overrides from USubsystem.
Declaration
virtual void Initialize(FSubsystemCollectionBase& Collection) override
Deinitialize()
Initialize overrides from USubsystem.
Declaration
virtual void Deinitialize() override
Fields
OnAllocate
Delegate that is invoked when this server has been allocated.
Declaration
UPROPERTY(BlueprintAssignable, Category="Multiplay | GameServer") FAllocateDelegate OnAllocate
Blueprint
C++
OnDeallocate
Delegate that is invoked when this server has been deallocated.
Declaration
UPROPERTY(BlueprintAssignable, Category="Multiplay | GameServer") FDeallocateDelegate OnDeallocate
Blueprint
C++
Methods
ReadyServerForPlayers(FReadyServerSuccessDelegate, FReadyServerFailureDelegate)
Marks the server as ready for players. The client invokes this method when it is ready to start accepting connections.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void ReadyServerForPlayers(FReadyServerSuccessDelegate OnSuccess, FReadyServerFailureDelegate OnFailure)
Parameters
UnreadyServer(FUnreadyServerSuccessDelegate, FUnreadyServerFailureDelegate)
Marks the server as not ready for players. The client invokes this method when wants to stop accepting connections.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void UnreadyServer(FUnreadyServerSuccessDelegate OnSuccess, FUnreadyServerFailureDelegate OnFailure)
Parameters
SubscribeToServerEvents()
Establishes a connection to the Multiplay SDK daemon and subscribes to allocation messages.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void SubscribeToServerEvents()
UnsubscribeToServerEvents()
Cleans up connection to the Multiplay SDK daemon and unsubscribe from allocation messages.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void UnsubscribeToServerEvents()
GetPayloadAllocation(FPayloadAllocationSuccessDelegate, FPayloadAllocationFailureDelegate)
Retrieves the allocation payload.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void GetPayloadAllocation(FPayloadAllocationSuccessDelegate OnSuccess, FPayloadAllocationFailureDelegate OnFailure)
Parameters
GetPayloadToken(FPayloadTokenSuccessDelegate, FPayloadTokenFailureDelegate)
Retrieves a JWT token for payloads.
Declaration
UFUNCTION(BlueprintCallable, Category="Multiplay | GameServer") void GetPayloadToken(FPayloadTokenSuccessDelegate OnSuccess, FPayloadTokenFailureDelegate OnFailure)
Parameters