Track when and how players are active across all platforms in real time.
Basic Presence records session start/end times, automatically computing CCU (concurrent users) and session length. Rich Presence (available to select customers) extends this with developer-defined per-session player statuses (e.g., Main Menu, Level 3) that produce a detailed activity timeline per session — useful for analytics, live-ops, and player support.
See the LootLocker documentation.
◆ FLootLockerPresenceCallbackDelegate
| typedef void(* FLootLockerPresenceCallbackDelegate) (bool, const FString &) |
Delegate for handling presence connection process callbacks.
◆ FLootLockerPresenceConnectionDelegate
| typedef void(* FLootLockerPresenceConnectionDelegate) (const FString &, ELootLockerPresenceConnectionState, ELootLockerPresenceConnectionState, const FString &) |
Delegate for presence connection state changes.
◆ ForceStartPresenceConnection()
Force start the Presence WebSocket connection manually.
This will override the automatic presence management and manually establish a connection. Use this when you need precise control over presence connections, otherwise let the SDK auto-manage.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| OnComplete | Callback indicating whether the connection and authentication succeeded |
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
◆ ForceStopAllPresenceConnections()
| static void ULootLockerSDKManager::ForceStopAllPresenceConnections |
( |
| ) |
|
|
static |
Force stop all Presence WebSocket connections manually.
This will override the automatic presence management and disconnect all active connections. Use this when you need to immediately disconnect all presence connections.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
◆ ForceStopPresenceConnection()
Force stop the Presence WebSocket connection manually.
This will override the automatic presence management and manually disconnect. Use this when you need precise control over presence connections, otherwise let the SDK auto-manage.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| OnComplete | Optional callback indicating whether the disconnection succeeded |
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
◆ GetCurrentPresenceStatus()
| static FString ULootLockerSDKManager::GetCurrentPresenceStatus |
( |
const FString & |
ForPlayerWithUlid = TEXT("") | ) |
|
|
static |
Get the last status that was sent for a specific player.
NOTE: To use this the rich presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
- Returns
- The last sent status string, or empty if no client is found or no status has been sent
◆ GetPresenceConnectionState()
| static ELootLockerPresenceConnectionState ULootLockerSDKManager::GetPresenceConnectionState |
( |
const FString & |
ForPlayerWithUlid = TEXT("") | ) |
|
|
static |
Get the current Presence connection state for a specific player.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
- Returns
- The current connection state
◆ GetPresenceConnectionStats()
| static FLootLockerPresenceConnectionStats ULootLockerSDKManager::GetPresenceConnectionStats |
( |
const FString & |
ForPlayerWithUlid = TEXT("") | ) |
|
|
static |
Get statistics about the Presence connection for a specific player.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
- Returns
- Connection statistics
◆ IsPresenceAutoConnectEnabled()
| static bool ULootLockerSDKManager::IsPresenceAutoConnectEnabled |
( |
| ) |
|
|
static |
Check if automatic presence connections are enabled.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Returns
- True if auto-connect is enabled, false otherwise
◆ IsPresenceAutoDisconnectOnFocusChangeEnabled()
| static bool ULootLockerSDKManager::IsPresenceAutoDisconnectOnFocusChangeEnabled |
( |
| ) |
|
|
static |
Check if automatic presence disconnection on focus change is enabled.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Returns
- True if auto-disconnect on focus change is enabled, false otherwise
◆ IsPresenceConnected()
| static bool ULootLockerSDKManager::IsPresenceConnected |
( |
const FString & |
ForPlayerWithUlid = TEXT("") | ) |
|
|
static |
Check if Presence is connected and authenticated for a specific player.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |
- Returns
- True if connected and active, false otherwise
◆ IsPresenceEnabled()
| static bool ULootLockerSDKManager::IsPresenceEnabled |
( |
| ) |
|
|
static |
Check if presence system is currently enabled.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Returns
- True if enabled, false otherwise
◆ ListPresenceConnections()
| static TArray< FString > ULootLockerSDKManager::ListPresenceConnections |
( |
| ) |
|
|
static |
Get a list of player ULIDs that currently have active Presence connections.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Returns
- Array of player ULIDs that have active presence connections
◆ SetPresenceAutoConnectEnabled()
| static void ULootLockerSDKManager::SetPresenceAutoConnectEnabled |
( |
bool |
bEnabled | ) |
|
|
static |
Enable or disable automatic presence connection when sessions start.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| bEnabled | Whether to auto-connect presence |
◆ SetPresenceAutoDisconnectOnFocusChangeEnabled()
| static void ULootLockerSDKManager::SetPresenceAutoDisconnectOnFocusChangeEnabled |
( |
bool |
bEnabled | ) |
|
|
static |
Enable or disable automatic presence disconnection when the application loses focus or is paused.
When enabled, presence connections will automatically disconnect when the app goes to background and reconnect when it returns to foreground. Useful for saving battery on mobile or managing resources.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| bEnabled | True to enable auto-disconnect on focus change, false to disable |
◆ SetPresenceEnabled()
| static void ULootLockerSDKManager::SetPresenceEnabled |
( |
bool |
bEnabled | ) |
|
|
static |
Enable or disable the entire Presence system.
NOTE: To use this the presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| bEnabled | Whether to enable presence |
◆ UpdatePresenceStatus()
| static void ULootLockerSDKManager::UpdatePresenceStatus |
( |
const FString & |
Status, |
|
|
const TMap< FString, FString > & |
Metadata, |
|
|
const FLootLockerPresenceCallbackDelegate & |
OnComplete, |
|
|
const FString & |
ForPlayerWithUlid = TEXT("") |
|
) |
| |
|
static |
Update the player's presence status.
NOTE: To use this the rich presence feature must be enabled for your game. Contact LootLocker support if you need assistance.
- Parameters
-
| Status | The status to set (e.g., "online", "in_game", "away") |
| Metadata | Optional metadata to include with the status |
| OnComplete | Callback for the result of the operation |
| ForPlayerWithUlid | Optional: Execute the request for the specified player. If not supplied, the default player will be used. |