USocialManager

Singleton manager at the top of the social framework

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

Party

Header

/Engine/Plugins/Online/OnlineFramework/Source/Party/Public/SocialManager.h

Include

#include "SocialManager.h"

Syntax

[UCLASS](Programming/UnrealArchitecture/Reference/Classes#classdeclaration)(Within=GameInstance, Config=Game)
class USocialManager :
    public UObject,
    public FExec

Remarks

Singleton manager at the top of the social framework

Variables

Name Description

Protected variable

bool

 

bShutdownPending

Set during shutdown, used to early-out of lingering OnlineSubsystem callbacks that are pending.

Public variable

USocialManager:...

 

OnSocialToolkitCreated

Protected variable

TSharedPtr< FRe...

 

RejoinableParty

Info on the persistent party we were in when losing connection to the party service and want to rejoin when it returns

Protected variable

TSubclassOf< US...

 

ToolkitClass

The desired type of SocialToolkit to create for each local player

Constructors

Name Description

Public function

USocialManager()

Functions

Name Description

Public function Static

void

 

AddReferencedObjects

(
    UObject* InThis,
    FReferenceCollector& Collector
)

Protected function Virtual Const

bool

 

CanCreateNewPartyObjects()

Public function

void

 

CreateParty

(
    const FOnlinePartyTypeId& PartyTyp...,
    const FPartyConfiguration& PartyCo...,
    const FOnCreatePartyAttemptComplete...
)

Public function

void

 

CreatePersistentParty

(
    const FOnCreatePartyAttemptComplete...
)

Protected function Virtual Const

void

 

FillOutJoinRequestData

(
    const FOnlinePartyId& TargetParty,
    FOnlinePartyData& OutJoinRequestDa...
)

Gives child classes a chance to append any additional data to a join request that's about to be sent to another party.

Protected function Virtual Const

ECrossplayPr...

 

GetCrossplayPreference()

Up to the game to decide whether it wants to allow crossplay (generally based on a user setting of some kind)

Public function Const

USocialDebug...

 

GetDebugTools()

Public function Static

const TArray...

 

GetDefaultSubsystems()

Public function Const

FUniqueNetId...

 

GetFirstLocalUserId

(
    ESocialSubsystem SubsystemType
)

Public function Const

int32

 

GetFirstLocalUserNum()

Public function Const

USocialToolk...

 

GetFirstLocalUserToolkit()

Protected function Const

const FJoinP...

 

GetJoinAttemptInProgress

(
    const FOnlinePartyTypeId& PartyTyp...
)

Public function Static

FUserPlatfor...

 

GetLocalUserPlatform()

Public function Const

PartyT *

 

GetParty

(
    const FOnlinePartyId& PartyId
)

Public function Const

PartyT *

 

GetParty

(
    const FOnlinePartyTypeId& PartyTyp...
)

Protected function Virtual Const

TSubclassOf<...

 

GetPartyClassForType

(
    const FOnlinePartyTypeId& PartyTyp...
)

Public function Const

PartyT *

 

GetPersistentParty()

Protected function Const

USocialParty...

 

GetPersistentPartyInternal

(
    bool bEvenIfLeaving
)

Public function Static

const TArray...

 

GetRegisteredInteractions()

Protected function Virtual Const

TSubclassOf<...

 

GetSocialDebugToolsClass()

Public function Static

IOnlineSubsy...

 

GetSocialOss

(
    UWorld* World,
    ESocialSubsystem SubsystemType
)

Public function Static

FName

 

GetSocialOssName

(
    ESocialSubsystem SubsystemType
)

Public function Static

FText

 

GetSocialOssPlatformName

(
    ESocialSubsystem SubsystemType
)

Public function Const

USocialToolk...

 

GetSocialToolkit

(
    const ULocalPlayer& LocalPlayer
)

Protected function Const

USocialToolk...

 

GetSocialToolkit

(
    int32 LocalPlayerNum
)

Protected function Const

USocialToolk...

 

GetSocialToolkit

(
    FUniqueNetIdRepl LocalUserId
)

Public function

void

 

HandlePartyDisconnected

(
    USocialParty* LeavingParty
)

Protected function

void

 

HandlePlatformSessionInviteAccepted

(
    const FUniqueNetIdRef& LocalUserId,
    const FOnlineSessionSearchResult& ...
)

Protected function Virtual

void

 

HandleQueryJoinabilityComplete

(
    const FUniqueNetId& LocalUserId,
    const FOnlinePartyId& PartyId,
    const FQueryPartyJoinabilityResult ...,
    FOnlinePartyTypeId PartyTypeId
)

Public function Virtual

void

 

InitSocialManager()

Initializes the manager - call this right after creating the manager object during GameInstance initialization.

Public function Const

bool

 

IsConnectedToPartyService()

Public function Const

bool

 

IsLocalUser

(
    const FUniqueNetIdRepl& LocalUserI...,
    ESocialSubsystem SubsystemType
)

Public function Const

bool

 

IsPartyJoinInProgress

(
    const FOnlinePartyTypeId& TypeId
)

Public function Const

bool

 

IsPersistentPartyJoinInProgress()

Public function Static

bool

 

IsSocialSubsystemEnabled

(
    ESocialSubsystem SubsystemType
)

Protected function

void

 

JoinParty

(
    const USocialUser& UserToJoin,
    const FOnlinePartyTypeId& PartyTyp...,
    const FOnJoinPartyAttemptComplete&...
)

Public function Virtual

void

 

NotifyPartyInitialized

(
    USocialParty& Party
)

Protected function Virtual

void

 

OnJoinPartyAttemptCompleteInternal

(
    const FJoinPartyAttempt& JoinAttem...,
    const FJoinPartyResult& Result
)

Virtual void OnCreatePartyComplete(const TSharedPtr& PartyId, ECreatePartyCompletionResult Result, FOnlinePartyTypeId PartyTypeId) {} virtual void OnQueryJoinabilityComplete(const FOnlinePartyId& PartyId, EJoinPartyCompletionResult Result, int32 DeniedResultCode, FOnlinePartyTypeId PartyTypeId) {}

Public function Const

FOnPartyMemb...

 

OnPartyJoined()

Protected function Virtual

void

 

OnPartyLeftInternal

(
    USocialParty& LeftParty,
    EMemberExitedReason Reason
)

Public function Const

USocialManag...

 

OnSocialToolkitCreated()

Protected function Virtual

void

 

OnToolkitCreatedInternal

(
    USocialToolkit& NewToolkit
)

Protected function

void

 

RefreshCanCreatePartyObjects()

Protected function

void

 

RegisterInteraction()

Public function

void

 

RegisterSecondaryPlayer

(
    int32 LocalPlayerNum,
    const FOnJoinPartyComplete& Delega...
)

Makes an attempt for the target local player to join the primary local player's party

Protected function Virtual

void

 

RegisterSocialInteractions()

Public function

void

 

RestorePartyStateFromPartySystem

(
    const FOnRestorePartyStateFromParty...
)

Protected function Virtual Const

bool

 

ShouldTryRejoiningPersistentParty

(
    const FRejoinableParty& InRejoinab...
)

Public function Virtual

void

 

ShutdownSocialManager()

Protected function Virtual Const

FJoinPartyRe...

 

ValidateJoinAttempt

(
    const FOnlinePartyTypeId& PartyTyp...
)

Validate that we are clear to try joining a party of the given type. If not, gives the reason why.

Public function Virtual Const

FJoinPartyRe...

 

ValidateJoinTarget

(
    const USocialUser& UserToJoin,
    const FOnlinePartyTypeId& PartyTyp...
)

Validates that the target user has valid join info for us to use and that we can join any party of the given type

Overridden from FExec

Name Description

Public function Virtual

bool

 

Exec

(
    UWorld* InWorld,
    const TCHAR* Cmd,
    FOutputDevice& Out
)

FExec.

Classes

Typedefs

Name

Description

FOnCreatePartyAttemptComplete

FOnJoinPartyAttemptComplete

FOnRestorePartyStateFromPartySystemComplete

Attempt to restore our party state from the party system

Constants

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss