PlayerInfo
Summary
| Members | Descriptions |
|---|---|
class URH_PlayerPresence | Player Presence class used to store player presence data. |
class URH_PlayerSessions | Player Sessions class used to store player session membership information. |
class URH_PlayerPlatformInfo | Stores information a specific platform the player has linked to their account. |
class URH_PlayerInfo | Stores and fetchs all the information about a given player. |
class URH_PlayerInfoSubsystem | Subsystem used to track and request information about players. |
struct FRH_PlayerSettingKeySetWrapper | Wrapper to help with setting keys for player settings. |
struct FRH_PlayerAndPlatformInfo | Wrapper to pair a players Unique Player Id and their current logged in Platform Id. |
class URH_PlayerPresence
class URH_PlayerPresence
: public UObject
Player Presence class used to store player presence data.
Summary
| Members | Descriptions |
|---|---|
public bool bInitialized | Tracks if the Presence has been initialized. |
public ERHAPI_OnlineStatus Status | Online status of the player. |
public FString Message | Message set by a player to display on their presence information. |
public FString Platform | Which platform the player is currently playing / last seen on. |
public FString DisplayName | The players display name for their current or last seen platform. |
public TMap< FString, FString > CustomData | Custom data that can be set by the player. |
public FGuid PlayerUuid | Players unique identifier. |
public FDateTime LastUpdated | The last time the players presence data was updated on the client. |
public FString ETag | ETag to track if the presence is stale during requests. |
public FRH_OnPresenceUpdatedMulticastDynamicDelegate BLUEPRINT_OnPresenceUpdatedDelegate | Blueprint delegate to listen for presence updates. |
public FRH_OnPresenceUpdatedMulticastDelegate OnPresenceUpdatedDelegate | Native delegate to listen for presence updates. |
public TArray< FRH_OnRequestPlayerPresenceBlock > TemporaryRequestDelegates | Delegates stored to response to currently active requests. |
public inline virtual void Update(const FRHAPI_PlayerPresence & Other) | Stores the response data from an API presence request. |
public template<> inline void Update(const T & Other) | Stores the response data from an API presence request. |
public inline void MarkUpdated() | Sets the last updated time to now. |
public inline void MarkDirty() | Clears the last updated time to force an update. |
public inline void RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerPresenceBlock Delegate) | Enqueues an update request for the players presence information from the RallyHere API. |
public inline void BLUEPRINT_RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerPresenceDynamicDelegate & Delegate) | |
public class URH_PlayerInfo*GetPlayerInfo() const | Gets the PlayerInfo that owns this Player Presence. |
public void CheckPollStatus(const bool bForceUpdate) | Updates the poll status to be active or inactive based on if it should currently be polling. |
protected FRH_AutoPollerPtr PresencePoller | Poller for the players presence. |
protected inline virtual bool ShouldPoll() const | Gets if the poller should be actively polling, only polls if something cares about it. |
protected void PollPresence(const FRH_PollCompleteFunc & Delegate) | Starts a poll of the players presence. |
protected virtual void ExecuteDelegates(bool bSuccess) | Handles executing any delegate listeners for the players presence. |
typedef GetPresenceType |
Members
public bool bInitialized
Tracks if the Presence has been initialized.
public ERHAPI_OnlineStatus Status
Online status of the player.
public FString Message
Message set by a player to display on their presence information.
public FString Platform
Which platform the player is currently playing / last seen on.
public FString DisplayName
The players display name for their current or last seen platform.
public TMap< FString, FString > CustomData
Custom data that can be set by the player.
public FGuid PlayerUuid
Players unique identifier.
public FDateTime LastUpdated
The last time the players presence data was updated on the client.
public FString ETag
ETag to track if the presence is stale during requests.
public FRH_OnPresenceUpdatedMulticastDynamicDelegate BLUEPRINT_OnPresenceUpdatedDelegate
Blueprint delegate to listen for presence updates.
public FRH_OnPresenceUpdatedMulticastDelegate OnPresenceUpdatedDelegate
Native delegate to listen for presence updates.
public TArray< FRH_OnRequestPlayerPresenceBlock > TemporaryRequestDelegates
Delegates stored to response to currently active requests.
public inline virtual void Update(const FRHAPI_PlayerPresence & Other)
Stores the response data from an API presence request.
Parameters
OtherThe presence data to store.
public template<>
inline void Update(const T & Other)
Stores the response data from an API presence request.
Parameters
OtherThe presence data to store.
public inline void MarkUpdated()
Sets the last updated time to now.
public inline void MarkDirty()
Clears the last updated time to force an update.
public inline void RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerPresenceBlock Delegate)
Enqueues an update request for the players presence information from the RallyHere API.
Parameters
-
bForceUpdateIf true, immediately requests an update rather than waiting for the next poll time. WARNING: Use this sparingly -
DelegateCallback delegate for the request.
public inline void BLUEPRINT_RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerPresenceDynamicDelegate & Delegate)
public class URH_PlayerInfo*GetPlayerInfo() const
Gets the PlayerInfo that owns this Player Presence.
Returns
The PlayerInfo that owns the Presence.
public void CheckPollStatus(const bool bForceUpdate)
Updates the poll status to be active or inactive based on if it should currently be polling.
Parameters
bForceUpdateIf true, immediately requests an update rather than waiting for the next poll time. WARNING: Use this sparingly
protected FRH_AutoPollerPtr PresencePoller
Poller for the players presence.
protected inline virtual bool ShouldPoll() const
Gets if the poller should be actively polling, only polls if something cares about it.
protected void PollPresence(const FRH_PollCompleteFunc & Delegate)
Starts a poll of the players presence.
Parameters
DelegateCallback delegate for the poll.
protected virtual void ExecuteDelegates(bool bSuccess)
Handles executing any delegate listeners for the players presence.
Parameters
bSuccessIf the poll was successful.
typedef GetPresenceType
class URH_PlayerSessions
class URH_PlayerSessions
: public UObject
Player Sessions class used to store player session membership information.
Summary
| Members | Descriptions |
|---|---|
public bool bInitialized | Tracks if the Presence has been initialized. |
public FGuid PlayerUuid | Players unique identifier. |
public FDateTime LastUpdated | The last time the players session data was updated on the client. |
public FString ETag | ETag to track if the session list is stale during requests. |
public FRHAPI_PlayerSessions Sessions | |
public FRH_OnPlayerSessionsUpdatedMulticastDynamicDelegate BLUEPRINT_OnSessionsUpdatedDelegate | Blueprint delegate to listen for sessions updates. |
public FRH_OnPlayerSessionsUpdatedMulticastDelegate OnSessionsUpdatedDelegate | Native delegate to listen for sessions updates. |
public TArray< FRH_OnRequestPlayerSessionsBlock > TemporaryRequestDelegates | Delegates stored to response to currently active requests. |
public inline virtual void Update(const GetSessionsType::Response & Other) | Stores the response data from an API presence request. |
public inline void MarkUpdated() | Sets the last updated time to now. |
public inline void MarkDirty() | Clears the last updated time to force an update. |
public inline void RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerSessionsBlock Delegate) | Enqueues an update request for the players presence information from the RallyHere API. |
public inline void BLUEPRINT_RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerSessionsDynamicDelegate & Delegate) | |
public class URH_PlayerInfo*GetPlayerInfo() const | Gets the PlayerInfo that owns this Player Presence. |
public void CheckPollStatus(const bool bForceUpdate) | Updates the poll status to be active or inactive based on if it should currently be polling. |
protected FRH_AutoPollerPtr SessionsPoller | Poller for the players presence. |
protected inline virtual bool ShouldPoll() const | Gets if the poller should be actively polling, only polls if something cares about it. |
protected void PollSessions(const FRH_PollCompleteFunc & Delegate) | Starts a poll of the players presence. |
protected virtual void ExecuteDelegates(bool bSuccess) | Handles executing any delegate listeners for the players presence. |
typedef GetSessionsType |
Members
public bool bInitialized
Tracks if the Presence has been initialized.
public FGuid PlayerUuid
Players unique identifier.
public FDateTime LastUpdated
The last time the players session data was updated on the client.
public FString ETag
ETag to track if the session list is stale during requests.
public FRHAPI_PlayerSessions Sessions
public FRH_OnPlayerSessionsUpdatedMulticastDynamicDelegate BLUEPRINT_OnSessionsUpdatedDelegate
Blueprint delegate to listen for sessions updates.
public FRH_OnPlayerSessionsUpdatedMulticastDelegate OnSessionsUpdatedDelegate
Native delegate to listen for sessions updates.
public TArray< FRH_OnRequestPlayerSessionsBlock > TemporaryRequestDelegates
Delegates stored to response to currently active requests.
public inline virtual void Update(const GetSessionsType::Response & Other)
Stores the response data from an API presence request.
Parameters
OtherThe presence data to store.
public inline void MarkUpdated()
Sets the last updated time to now.
public inline void MarkDirty()
Clears the last updated time to force an update.
public inline void RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerSessionsBlock Delegate)
Enqueues an update request for the players presence information from the RallyHere API.
Parameters
-
bForceUpdateIf true, immediately requests an update rather than waiting for the next poll time. WARNING: Use this sparingly -
DelegateCallback delegate for the request.
public inline void BLUEPRINT_RequestUpdate(bool bForceUpdate,const FRH_OnRequestPlayerSessionsDynamicDelegate & Delegate)
public class URH_PlayerInfo*GetPlayerInfo() const
Gets the PlayerInfo that owns this Player Presence.
Returns
The PlayerInfo that owns the Presence.
public void CheckPollStatus(const bool bForceUpdate)
Updates the poll status to be active or inactive based on if it should currently be polling.
Parameters
bForceUpdateIf true, immediately requests an update rather than waiting for the next poll time. WARNING: Use this sparingly
protected FRH_AutoPollerPtr SessionsPoller
Poller for the players presence.
protected inline virtual bool ShouldPoll() const
Gets if the poller should be actively polling, only polls if something cares about it.
protected void PollSessions(const FRH_PollCompleteFunc & Delegate)
Starts a poll of the players presence.
Parameters
DelegateCallback delegate for the poll.
protected virtual void ExecuteDelegates(bool bSuccess)
Handles executing any delegate listeners for the players presence.
Parameters
bSuccessIf the poll was successful.
typedef GetSessionsType
class URH_PlayerPlatformInfo
class URH_PlayerPlatformInfo
: public UObject
Stores information a specific platform the player has linked to their account.
Summary
| Members | Descriptions |
|---|---|
public FRH_PlayerPlatformId PlayerPlatformId | Players Platform ID struct. |
public FString DisplayName | Last seen display name for the player on the platform. |
public inline FORCEINLINE FRH_PlayerPlatformId GetPlayerPlatformId() const | Gets the Platform Id struct for the player. |
public inline FORCEINLINE FString GetPlatformUserId() const | Gets the Platform Id for the player. |
public inline FORCEINLINE ERHAPI_Platform GetPlatform() const | Gets the Platform Type for the player. |
public inline FORCEINLINE FString GetLastKnownDisplayName() const | Gets the display name stored the last time this player logged in to the Rally Here server. |
Members
public FRH_PlayerPlatformId PlayerPlatformId
Players Platform ID struct.
public FString DisplayName
Last seen display name for the player on the platform.
public inline FORCEINLINE FRH_PlayerPlatformId GetPlayerPlatformId() const
Gets the Platform Id struct for the player.
Returns
The players Platform Id struct.
public inline FORCEINLINE FString GetPlatformUserId() const
Gets the Platform Id for the player.
Returns
The players Platform Unique Id.
public inline FORCEINLINE ERHAPI_Platform GetPlatform() const
Gets the Platform Type for the player.
Returns
The players Platform Type.
public inline FORCEINLINE FString GetLastKnownDisplayName() const
Gets the display name stored the last time this player logged in to the Rally Here server.
Returns
The players display name for the platform.
class URH_PlayerInfo
class URH_PlayerInfo
: public UObject
Stores and fetchs all the information about a given player.
Summary
| Members | Descriptions |
|---|---|
public FRH_OnPresenceUpdatedMulticastDynamicDelegate BLUEPRINT_OnPresenceUpdatedDelegate | Blueprint delegate to listen for presence updates. |
public FRH_OnPresenceUpdatedMulticastDelegate OnPresenceUpdatedDelegate | Native delegate to listen for presence updates. |
public FRH_OnPlayerSessionsUpdatedMulticastDynamicDelegate BLUEPRINT_OnSessionsUpdatedDelegate | Blueprint delegate to listen for session list updates. |
public FRH_OnPlayerSessionsUpdatedMulticastDelegate OnSessionsUpdatedDelegate | Native delegate to listen for session list updates. |
public inline FORCEINLINE FGuid & GetRHPlayerUuid() | Gets the players Unique player Id. |
public inline FORCEINLINE URH_PlayerPresence*GetPresence() const | Gets The players presence class. |
public inline FORCEINLINE URH_PlayerSessions*GetSessions() const | Gets The players presence class. |
public inline FORCEINLINE TArray< FRH_PlayerPlatformId> &GetPlayerPlatformIds() | Gets the associated platform ids of the player. |
public inline FORCEINLINE const TArray< FRH_PlayerPlatformId> &GetPlayerPlatformIds() const | Gets the associated platform ids of the player. |
public TArray< URH_PlayerPlatformInfo* >GetPlayerPlatforms() const | Gets the associated platforms of the player. |
public URH_PlayerPlatformInfo*GetPlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId) const | Gets a specific platform for the player. |
public inline URH_PlayerInventory*GetPlayerInventory() const | Gets the players Inventory Subsystem. |
public inline URH_PlayerNotifications*GetPlayerNotifications() const | Gets the players Notification Subsystem. |
public void StartStreamingNotifications() | Request to start streaming notifications for this player. |
public void StopStreamingNotifications(bool bClearCache) | Requests to stop streaming notifications. |
public inline const TMap< FString, FRH_PlayerSettingsDataWrapper>GetAllStoredPlayerSettings() const | Gets all the players store settings data. |
public inline const TMap< int32, FRHAPI_PlayerRankResponse> &GetAllStoredPlayerRankings() const | Gets all the players stored ranking data. |
public URH_PlayerInfoSubsystem*GetPlayerInfoSubsystem() const | Gets the players Info Subsystem that the Player Info is on. |
public void InitializeForPlayer(const FGuid & PlayerUuid) | Initialized the player info from a given Player Unique Id. |
public void GetLastKnownDisplayNameAsync(const FTimespan & StaleThreshold,bool bForceRefresh,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate,const class URH_LocalPlayerSubsystem * LocalPlayerSubsystem) | Gets the last known display name for the player, will make required API calls to retrieve the information if needed. |
public inline void BLUEPRINT_GetLastKnownDisplayNameAsync(const class URH_LocalPlayerSubsystem * LocalPlayerSubsystem,const FTimespan & StaleThreshold,bool bForceRefresh,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameDynamicDelegate & Delegate) | |
public bool GetLastKnownDisplayName(FString & OutDisplayName,ERHAPI_Platform PreferredPlatformType) const | Gets the last known display name for the player. |
public inline bool BLUEPRINT_GetLastKnownDisplayName(ERHAPI_Platform PreferredPlatformType,FString & OutDisplayName) const | |
public void GetLinkedPlatformInfo(const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlatformsBlock Delegate) | Gets the players linked platforms via API call. |
public inline void BLUEPRINT_GetLinkedPlatformInfo(const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlatformsDynamicDelegate & Delegate) | |
public void GetPlayerSettings(const FString & SettingTypeId,const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlayerSettingsBlock Delegate) | Gets the players settings information for a given type. |
public inline void BLUEPRINT_GetPlayerSettings(const FString & SettingTypeId,const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlayerSettingsDynamicDelegate & Delegate) | |
public void SetPlayerSettings(const FString & SettingTypeId,FRH_PlayerSettingsDataWrapper & SettingsData,FRH_PlayerInfoSetPlayerSettingsBlock Delegate) | Sets the players settings information for a given type. |
public inline void BLUEPRINT_SetPlayerSettings(const FString & SettingTypeId,FRH_PlayerSettingsDataWrapper SettingsData,const FRH_PlayerInfoSetPlayerSettingsDynamicDelegate & Delegate) | |
public void GetPlayerRankings(const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlayerRankingsBlock Delegate) | Gets the players ranking information for a given type. |
public inline void BLUEPRINT_GetPlayerRankings(const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlayerRankingsDynamicDelegate & Delegate) | |
public void UpdatePlayerRanking(int32 RankId,const FRHAPI_PlayerRankUpdateRequest & RankData,FRH_PlayerInfoGetPlayerRankingsBlock Delegate) | Sets the players settings information for a given type. |
public inline void BLUEPRINT_UpdatePlayerRanking(int32 RankId,const FRHAPI_PlayerRankUpdateRequest & RankData,const FRH_PlayerInfoGetPlayerRankingsDynamicDelegate & Delegate) | |
public FAuthContextPtr GetAuthContext() const | Gets the local Auth Context for making API calls. |
public ERHAPI_Platform GetLoggedInPlatform() const | Gets the local users logged in platform type. |
protected FGuid RHPlayerUuid | The Unique Player Id for the player. |
protected TMap< FString, FRH_PlayerSettingsDataWrapper>PlayerSettingsByTypeId | Cache of Player Settings Data by their settings types. |
protected TMap< FString, FRH_PlayerSettingKeySetWrapper>PendingSettingRequestsByTypeId | When requesting multiple Player Settings Updates at once, this keeps track of pending requests so we know when all requests are completed. |
protected TMap< FString, FRH_PlayerSettingsDataWrapper>SetPlayerSettingResponses | Used when requesting multiple Player Settings Updates to track all their responses. |
protected TArray< FRH_PlayerPlatformId>LinkedPlayerPlatforms | Cache of all platforms the player is linked to. |
protected URH_PlayerPresence*PlayerPresence | The players Presence Information. |
protected URH_PlayerSessions*PlayerSessions | The players Sessions Information. |
protected URH_PlayerInventory*PlayerInventory | The Players Inventory Subsystem. |
protected URH_PlayerNotifications*PlayerNotifications | The Players Inventory Subsystem. |
protected TMap< int32, FRHAPI_PlayerRankResponse>PlayerRankingsByRankingId | List of the player’s rankings. |
protected FDateTime LastRequestPlatforms | Tracks the last time the players linked platforms were requested for checking if the data is stale. |
protected TMap< FString, FDateTime > LastRequestSettingsByTypeId | Tracks the last time each settings type was request for checking if the data is stale. |
protected FDateTime LastRequestRankings | Tracks the last time the player rankings were requested for checking if the data is stale. |
protected virtual void OnGetPlayerLinkedPlatformsForLastKnownDisplayNameResponse(bool bSuccess,const TArray< URH_PlayerPlatformInfo* > & Platforms,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate,const classURH_LocalPlayerSubsystem * LocalPlayerSubsystem) | Handles the response to a Get Linked Platforms For Last Known Display Name call. |
protected virtual void OnDisplayNameSanitized(bool bSuccess,const FString & SanitizedMessage,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate) | Handles the response to sanitizing the players display name. |
protected virtual void OnGetPlayerLinkedPlatformsResponse(const GetPlatforms::Response & Response,FRH_PlayerInfoGetPlatformsBlock Delegate) | Handles the response to a Get Linked Platforms call. |
protected virtual void OnGetPlayerSettingsResponse(const GetSettings::Response & Response,FRH_PlayerInfoGetPlayerSettingsBlock Delegate,const FString SettingTypeId) | Handles the response to a Get Player Settings call. |
protected virtual void OnSetPlayerSettingsResponse(const SetSettings::Response & Response,FRH_PlayerInfoSetPlayerSettingsBlock Delegate,const FString SettingTypeId,const FString SettingKey,FRH_PlayerSettingsDataWrapper SettingsData) | Handles the response to a Set Player Settings call. |
protected virtual void OnGetPlayerRankingsResponse(const GetRankings::Response & Response,FRH_PlayerInfoGetPlayerRankingsBlock Delegate) | Handles the response to a Get Player Rankings call. |
protected virtual void OnUpdatePlayerRankingResponse(const UpdateRanking::Response & Response,FRH_PlayerInfoGetPlayerRankingsBlock Delegate) | Handles the response to a Update Player Ranking call. |
protected inline virtual void OnPresenceUpdated() | Helper to broadcast results from player presences being updated. |
protected inline virtual void OnSessionsUpdated() | Helper to broadcast results from player sessions list being updated. |
typedef GetPlatforms | |
typedef GetSettings | |
typedef SetSettings | |
typedef GetRankings | |
typedef UpdateRanking |
Members
public FRH_OnPresenceUpdatedMulticastDynamicDelegate BLUEPRINT_OnPresenceUpdatedDelegate
Blueprint delegate to listen for presence updates.
public FRH_OnPresenceUpdatedMulticastDelegate OnPresenceUpdatedDelegate
Native delegate to listen for presence updates.
public FRH_OnPlayerSessionsUpdatedMulticastDynamicDelegate BLUEPRINT_OnSessionsUpdatedDelegate
Blueprint delegate to listen for session list updates.
public FRH_OnPlayerSessionsUpdatedMulticastDelegate OnSessionsUpdatedDelegate
Native delegate to listen for session list updates.
public inline FORCEINLINE FGuid & GetRHPlayerUuid()
Gets the players Unique player Id.
Returns
The players Unique Player Id.
public inline FORCEINLINE URH_PlayerPresence*GetPresence() const
Gets The players presence class.
Returns
The players presence class.
public inline FORCEINLINE URH_PlayerSessions*GetSessions() const
Gets The players presence class.
Returns
The players presence class.
public inline FORCEINLINE TArray< FRH_PlayerPlatformId> &GetPlayerPlatformIds()
Gets the associated platform ids of the player.
Returns
The players associated platforms ids.
public inline FORCEINLINE const TArray< FRH_PlayerPlatformId> &GetPlayerPlatformIds() const
Gets the associated platform ids of the player.
Returns
The players associated platforms ids.
public TArray< URH_PlayerPlatformInfo* >GetPlayerPlatforms() const
Gets the associated platforms of the player.
Returns
The players associated platforms.
public URH_PlayerPlatformInfo*GetPlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId) const
Gets a specific platform for the player.
Parameters
PlayerPlatformIdThe Id of the platform being requested.
Returns
The platform requested for the player if it exists.
public inline URH_PlayerInventory*GetPlayerInventory() const
Gets the players Inventory Subsystem.
Returns
The players Inventory Subsystem.
public inline URH_PlayerNotifications*GetPlayerNotifications() const
Gets the players Notification Subsystem.
Returns
The players Notification Subsystem.
public void StartStreamingNotifications()
Request to start streaming notifications for this player.
public void StopStreamingNotifications(bool bClearCache)
Requests to stop streaming notifications.
Parameters
[in[bClearCache If true, the cache of notifications will be cleared.
public inline const TMap< FString, FRH_PlayerSettingsDataWrapper>GetAllStoredPlayerSettings() const
Gets all the players store settings data.
Returns
The players stored settings data.
public inline const TMap< int32, FRHAPI_PlayerRankResponse> &GetAllStoredPlayerRankings() const
Gets all the players stored ranking data.
Returns
The players stored settings data.
public URH_PlayerInfoSubsystem*GetPlayerInfoSubsystem() const
Gets the players Info Subsystem that the Player Info is on.
Returns
The Player Info Subsystem.
public void InitializeForPlayer(const FGuid & PlayerUuid)
Initialized the player info from a given Player Unique Id.
Parameters
PlayerUuidThe Unique Id of the player.
public void GetLastKnownDisplayNameAsync(const FTimespan & StaleThreshold,bool bForceRefresh,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate,const class URH_LocalPlayerSubsystem * LocalPlayerSubsystem)
Gets the last known display name for the player, will make required API calls to retrieve the information if needed.
Parameters
-
LocalPlayerSubsystemThe Local Player Subsystem to sanitizing player names. -
StaleThresholdIf set, will force a re-request of the players information if the last updated time was more than the threshold. -
bForceRefreshIf true, will force a re-request of the players information. -
PreferredPlatformTypeIf set, then that specific platforms display name will be returned if possible, otherwise will use your local platforms, otherwise the first platform found for the player. -
DelegateCallback with the players display name.
public inline void BLUEPRINT_GetLastKnownDisplayNameAsync(const class URH_LocalPlayerSubsystem * LocalPlayerSubsystem,const FTimespan & StaleThreshold,bool bForceRefresh,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameDynamicDelegate & Delegate)
public bool GetLastKnownDisplayName(FString & OutDisplayName,ERHAPI_Platform PreferredPlatformType) const
Gets the last known display name for the player.
Parameters
-
PreferredPlatformTypeIf set, then that specific platforms display name will be returned if possible, otherwise will use your local platforms, otherwise the first platform found for the player. -
OutDisplayNameThe player’s display name.
Returns
If the call successfully found a display name for the player already stored on the client.
public inline bool BLUEPRINT_GetLastKnownDisplayName(ERHAPI_Platform PreferredPlatformType,FString & OutDisplayName) const
public void GetLinkedPlatformInfo(const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlatformsBlock Delegate)
Gets the players linked platforms via API call.
Parameters
-
StaleThresholdIf set, will force a re-request of the players information if the last updated time was more than the threshold. -
bForceRefreshIf true, will force a re-request of the players information. -
DelegateCallback with the players linked platforms.
public inline void BLUEPRINT_GetLinkedPlatformInfo(const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlatformsDynamicDelegate & Delegate)
public void GetPlayerSettings(const FString & SettingTypeId,const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlayerSettingsBlock Delegate)
Gets the players settings information for a given type.
Parameters
-
SettingTypeIdThe setting type requested. -
StaleThresholdIf set, will force a re-request of the players information if the last updated time was more than the threshold. -
bForceRefreshIf true, will force a re-request of the players information. -
DelegateCallback with the players settings for the given type.
public inline void BLUEPRINT_GetPlayerSettings(const FString & SettingTypeId,const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlayerSettingsDynamicDelegate & Delegate)
public void SetPlayerSettings(const FString & SettingTypeId,FRH_PlayerSettingsDataWrapper & SettingsData,FRH_PlayerInfoSetPlayerSettingsBlock Delegate)
Sets the players settings information for a given type.
Parameters
-
SettingTypeIdThe setting type to update. -
SettingsDataData to be stored into the players settings. -
DelegateCallback when the operation is complete with success information.
public inline void BLUEPRINT_SetPlayerSettings(const FString & SettingTypeId,FRH_PlayerSettingsDataWrapper SettingsData,const FRH_PlayerInfoSetPlayerSettingsDynamicDelegate & Delegate)
public void GetPlayerRankings(const FTimespan & StaleThreshold,bool bForceRefresh,FRH_PlayerInfoGetPlayerRankingsBlock Delegate)
Gets the players ranking information for a given type.
Parameters
-
StaleThresholdIf set, will force a re-request of the players information if the last updated time was more than the threshold. -
bForceRefreshIf true, will force a re-request of the players information. -
DelegateCallback with the players ranking for the given type.
public inline void BLUEPRINT_GetPlayerRankings(const FTimespan & StaleThreshold,bool bForceRefresh,const FRH_PlayerInfoGetPlayerRankingsDynamicDelegate & Delegate)
public void UpdatePlayerRanking(int32 RankId,const FRHAPI_PlayerRankUpdateRequest & RankData,FRH_PlayerInfoGetPlayerRankingsBlock Delegate)
Sets the players settings information for a given type.
Parameters
-
SettingTypeIdThe setting type to update. -
SettingsDataData to be stored into the players settings. -
DelegateCallback when the operation is complete with success information.
public inline void BLUEPRINT_UpdatePlayerRanking(int32 RankId,const FRHAPI_PlayerRankUpdateRequest & RankData,const FRH_PlayerInfoGetPlayerRankingsDynamicDelegate & Delegate)
public FAuthContextPtr GetAuthContext() const
Gets the local Auth Context for making API calls.
Returns
Local auth context for the given player or instance
public ERHAPI_Platform GetLoggedInPlatform() const
Gets the local users logged in platform type.
Returns
The Platform type of the local user
protected FGuid RHPlayerUuid
The Unique Player Id for the player.
protected TMap< FString, FRH_PlayerSettingsDataWrapper>PlayerSettingsByTypeId
Cache of Player Settings Data by their settings types.
protected TMap< FString, FRH_PlayerSettingKeySetWrapper>PendingSettingRequestsByTypeId
When requesting multiple Player Settings Updates at once, this keeps track of pending requests so we know when all requests are completed.
protected TMap< FString, FRH_PlayerSettingsDataWrapper>SetPlayerSettingResponses
Used when requesting multiple Player Settings Updates to track all their responses.
protected TArray< FRH_PlayerPlatformId>LinkedPlayerPlatforms
Cache of all platforms the player is linked to.
protected URH_PlayerPresence*PlayerPresence
The players Presence Information.
protected URH_PlayerSessions*PlayerSessions
The players Sessions Information.
protected URH_PlayerInventory*PlayerInventory
The Players Inventory Subsystem.
protected URH_PlayerNotifications*PlayerNotifications
The Players Inventory Subsystem.
protected TMap< int32, FRHAPI_PlayerRankResponse>PlayerRankingsByRankingId
List of the player’s rankings.
protected FDateTime LastRequestPlatforms
Tracks the last time the players linked platforms were requested for checking if the data is stale.
protected TMap< FString, FDateTime > LastRequestSettingsByTypeId
Tracks the last time each settings type was request for checking if the data is stale.
protected FDateTime LastRequestRankings
Tracks the last time the player rankings were requested for checking if the data is stale.
protected virtual void OnGetPlayerLinkedPlatformsForLastKnownDisplayNameResponse(bool bSuccess,const TArray< URH_PlayerPlatformInfo* > & Platforms,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate,const classURH_LocalPlayerSubsystem * LocalPlayerSubsystem)
Handles the response to a Get Linked Platforms For Last Known Display Name call.
Parameters
-
bSuccessIf the call was successful. -
PlatformsList of platforms the player is linked to. -
PreferredPlatformTypeThe preferred platform type to use for the player. -
DelegateDelegate passed in for original call to respond to when call completes. -
LocalPlayerSubsystemThe local player subsystem that made the original call.
protected virtual void OnDisplayNameSanitized(bool bSuccess,const FString & SanitizedMessage,ERHAPI_Platform PreferredPlatformType,const FRH_PlayerInfoGetDisplayNameBlock Delegate)
Handles the response to sanitizing the players display name.
Parameters
-
bSuccessIf the call was successful. -
SanitizedMessageThe sanitized display name. -
PreferredPlatformTypeThe preferred platform type to use for the player. -
DelegateCallback Delegate to return the name.
protected virtual void OnGetPlayerLinkedPlatformsResponse(const GetPlatforms::Response & Response,FRH_PlayerInfoGetPlatformsBlock Delegate)
Handles the response to a Get Linked Platforms call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnGetPlayerSettingsResponse(const GetSettings::Response & Response,FRH_PlayerInfoGetPlayerSettingsBlock Delegate,const FString SettingTypeId)
Handles the response to a Get Player Settings call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes. -
SettinyTypeIdThe type of settings that were requested.
protected virtual void OnSetPlayerSettingsResponse(const SetSettings::Response & Response,FRH_PlayerInfoSetPlayerSettingsBlock Delegate,const FString SettingTypeId,const FString SettingKey,FRH_PlayerSettingsDataWrapper SettingsData)
Handles the response to a Set Player Settings call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes. -
SettinyTypeIdThe type of settings that being updated requested. -
SettingKeyThe key of the setting that was updated. -
SettingsDataThe data of the setting that was updated.
protected virtual void OnGetPlayerRankingsResponse(const GetRankings::Response & Response,FRH_PlayerInfoGetPlayerRankingsBlock Delegate)
Handles the response to a Get Player Rankings call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnUpdatePlayerRankingResponse(const UpdateRanking::Response & Response,FRH_PlayerInfoGetPlayerRankingsBlock Delegate)
Handles the response to a Update Player Ranking call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected inline virtual void OnPresenceUpdated()
Helper to broadcast results from player presences being updated.
protected inline virtual void OnSessionsUpdated()
Helper to broadcast results from player sessions list being updated.
typedef GetPlatforms
typedef GetSettings
typedef SetSettings
typedef GetRankings
typedef UpdateRanking
class URH_PlayerInfoSubsystem
class URH_PlayerInfoSubsystem
: public URH_SandboxedSubsystemPlugin
: public FTickableGameObject
Subsystem used to track and request information about players.
Summary
| Members | Descriptions |
|---|---|
public virtual void Initialize() | Initialize the subsystem. |
public virtual void Deinitialize() | Safely tears down the subsystem. |
public inline const TMap< FGuid, URH_PlayerInfo* > &GetPlayerInfos() const | Gets a map of all the player infos. |
public virtual URH_PlayerInfo*GetOrCreatePlayerInfo(const FGuid & PlayerUuid) | Gets a Player Info object for a given Player Unique Id, creates if needed. |
public virtual URH_PlayerPlatformInfo*GetOrCreatePlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId) | Gets a Player Info object for a given Player Platform Id, creates if needed. |
public URH_PlayerInfo*FindPlayerInfoByPlatformId(const FRH_PlayerPlatformId & PlayerPlatformId) const | Gets a Player Info object for a given Player Platform Id. |
public inline URH_PlayerInfo*GetPlayerInfo(const FGuid & PlayerUuid) const | Gets a Player Info object for a given Unique Player Id. |
public inline URH_PlayerPlatformInfo*GetPlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId) const | Gets the platform info object for a player by the Platform Id. |
public inline void AddPlayerLink(const FRH_PlayerPlatformId & PlayerPlatformId,const FGuid & PlayerUuid) | Adds a platform mapping for a given player. |
public void LookupPlayer(FString PlayerName,FRH_PlayerInfoLookupPlayerBlock Delegate) | Searchs for all players who use the given display name via API Call. |
public inline void BLUEPRINT_LookupPlayer(FString PlayerName,const FRH_PlayerInfoLookupPlayerDynamicDelegate & Delegate) | |
public void LookupPlayerByPlatformUserId(FRH_PlayerPlatformId PlayerPlatformId,FRH_PlayerInfoLookupPlayerBlock Delegate) | Searchs for players associated with the given platform and platform user id via API Call. |
public inline void BLUEPRINT_LookupPlayerByPlatformUserId(FRH_PlayerPlatformId PlayerPlatformId,const FRH_PlayerInfoLookupPlayerDynamicDelegate & Delegate) | |
public URH_PlayerInfo*RemovePlayerInfoFromCache(const FGuid & PlayerUuid) | Remove a specific Player Info from PlayerInfoSubsystem’s cache. |
public virtual void Tick(float DeltaTime) | Unreals basic Tick function. |
public inline virtual bool IsTickable() const | Gets if currently tickable. |
public inline virtual TStatId GetStatId() const | Gets the stat to use for the tick time. |
protected TSubclassOf< URH_PlayerInfo>PlayerInfoClassOverride | Override class for Player Info if extended. |
protected TMap< FGuid, URH_PlayerInfo* >PlayerInfos | Map of Player Infos to their player Uuids. |
protected TMap< FRH_PlayerPlatformId](Common.md#structFRH__PlayerPlatformId), [URH_PlayerPlatformInfo* >PlayerPlatformInfos | Map of Player Platform Infos to their Platform Ids. |
protected TMap< FRH_PlayerPlatformId, FGuid > PlayerPlatformIdToUuidMap | Map of Player Uuid to their Platform Ids. |
protected virtual void ClearPlayerInfoCache() | Clears the cached player infos. |
protected virtual void InitPropertiesWithDefaultValues() | Initializes the subsystem with defaults for its cached data. |
protected virtual void OnLookupPlayerResponse(const TLookupPlayer::Response & Response,FRH_PlayerInfoLookupPlayerBlock Delegate) | Handles the response to a Lookup Player call. |
protected virtual void OnLookupPlayerByPlatformUserIdResponse(const TLookupPlayer::Response & Response,FRH_PlayerInfoLookupPlayerBlock Delegate) | Handles the response to a Lookup Player By Platform User Id call. |
typedef TLookupPlayer |
Members
public virtual void Initialize()
Initialize the subsystem.
public virtual void Deinitialize()
Safely tears down the subsystem.
public inline const TMap< FGuid, URH_PlayerInfo* > &GetPlayerInfos() const
Gets a map of all the player infos.
Returns
Map of player infos by Player Unique Id
public virtual URH_PlayerInfo*GetOrCreatePlayerInfo(const FGuid & PlayerUuid)
Gets a Player Info object for a given Player Unique Id, creates if needed.
Parameters
PlayerUuidUnique Player Id for the given player
Returns
Player Info for the player
public virtual URH_PlayerPlatformInfo*GetOrCreatePlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId)
Gets a Player Info object for a given Player Platform Id, creates if needed.
Parameters
PlayerPlatformIdPlayer Platform Id for the given player
Returns
Player Info for the player
public URH_PlayerInfo*FindPlayerInfoByPlatformId(const FRH_PlayerPlatformId & PlayerPlatformId) const
Gets a Player Info object for a given Player Platform Id.
Parameters
PlayerPlatformIdPlayer Platform Id for the given player
Returns
Player Info for the player if found
public inline URH_PlayerInfo*GetPlayerInfo(const FGuid & PlayerUuid) const
Gets a Player Info object for a given Unique Player Id.
Parameters
PlayerUuidUnique Player Id for the given player
Returns
Player Info for the player if found
public inline URH_PlayerPlatformInfo*GetPlayerPlatformInfo(const FRH_PlayerPlatformId & PlayerPlatformId) const
Gets the platform info object for a player by the Platform Id.
Parameters
PlayerPlatformIdPlayer Platform Id for the given player
Returns
Player Platform Info for the player if found
public inline void AddPlayerLink(const FRH_PlayerPlatformId & PlayerPlatformId,const FGuid & PlayerUuid)
Adds a platform mapping for a given player.
Parameters
-
PlayerUuidUnique Player Id for the given player -
PlayerPlatformIdPlayer Platform Id for the given player
public void LookupPlayer(FString PlayerName,FRH_PlayerInfoLookupPlayerBlock Delegate)
Searchs for all players who use the given display name via API Call.
Parameters
-
PlayerNameThe display name we want to search for -
DelegateCallback with the all PlayerInfos that are found with that display name
public inline void BLUEPRINT_LookupPlayer(FString PlayerName,const FRH_PlayerInfoLookupPlayerDynamicDelegate & Delegate)
public void LookupPlayerByPlatformUserId(FRH_PlayerPlatformId PlayerPlatformId,FRH_PlayerInfoLookupPlayerBlock Delegate)
Searchs for players associated with the given platform and platform user id via API Call.
Parameters
-
PlatformThe platform used for the lookup -
PlatformUserIdThe platform user id used for the lookup -
DelegateCallback with the all PlayerInfos that are found with that display name
public inline void BLUEPRINT_LookupPlayerByPlatformUserId(FRH_PlayerPlatformId PlayerPlatformId,const FRH_PlayerInfoLookupPlayerDynamicDelegate & Delegate)
public URH_PlayerInfo*RemovePlayerInfoFromCache(const FGuid & PlayerUuid)
Remove a specific Player Info from PlayerInfoSubsystem’s cache.
Parameters
PlayerUuidThe UUID of the Player Info to be removed
Returns
The Player Info that got removed
public virtual void Tick(float DeltaTime)
Unreals basic Tick function.
public inline virtual bool IsTickable() const
Gets if currently tickable.
public inline virtual TStatId GetStatId() const
Gets the stat to use for the tick time.
protected TSubclassOf< URH_PlayerInfo>PlayerInfoClassOverride
Override class for Player Info if extended.
protected TMap< FGuid, URH_PlayerInfo* >PlayerInfos
Map of Player Infos to their player Uuids.
protected TMap< FRH_PlayerPlatformId](Common.md#structFRH__PlayerPlatformId), [URH_PlayerPlatformInfo* >PlayerPlatformInfos
Map of Player Platform Infos to their Platform Ids.
protected TMap< FRH_PlayerPlatformId, FGuid > PlayerPlatformIdToUuidMap
Map of Player Uuid to their Platform Ids.
protected virtual void ClearPlayerInfoCache()
Clears the cached player infos.
protected virtual void InitPropertiesWithDefaultValues()
Initializes the subsystem with defaults for its cached data.
protected virtual void OnLookupPlayerResponse(const TLookupPlayer::Response & Response,FRH_PlayerInfoLookupPlayerBlock Delegate)
Handles the response to a Lookup Player call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
protected virtual void OnLookupPlayerByPlatformUserIdResponse(const TLookupPlayer::Response & Response,FRH_PlayerInfoLookupPlayerBlock Delegate)
Handles the response to a Lookup Player By Platform User Id call.
Parameters
-
RespResponse given for the call -
DelegateDelegate passed in for original call to respond to when call completes.
typedef TLookupPlayer
struct FRH_PlayerSettingKeySetWrapper
Wrapper to help with setting keys for player settings.
Summary
| Members | Descriptions |
|---|---|
public TSet< FString > SettingKeySet | Set of keys being set by the settings update. |
public inline FRH_PlayerSettingKeySetWrapper() | Default constructor. |
Members
public TSet< FString > SettingKeySet
Set of keys being set by the settings update.
public inline FRH_PlayerSettingKeySetWrapper()
Default constructor.
struct FRH_PlayerAndPlatformInfo
Wrapper to pair a players Unique Player Id and their current logged in Platform Id.
Summary
| Members | Descriptions |
|---|---|
public FGuid PlayerUuid | The players Unique Player id. |
public FRH_PlayerPlatformId PlayerPlatformId | The players logged in Platform Id. |
public inline FRH_PlayerAndPlatformInfo() | Default Constructor. |
Members
public FGuid PlayerUuid
The players Unique Player id.
public FRH_PlayerPlatformId PlayerPlatformId
The players logged in Platform Id.
public inline FRH_PlayerAndPlatformInfo()
Default Constructor.