author | title | description | ms.author | ms.topic | ms.service | ms.date |
---|---|---|---|---|---|---|
ScottMunroMS |
PFLobbyGetOwner |
Gets the current owner of the lobby. |
scmunro |
reference |
playfab |
03/07/2023 |
Gets the current owner of the lobby.
HRESULT PFLobbyGetOwner(
PFLobbyHandle lobby,
const PFEntityKey** owner
)
lobby
PFLobbyHandle
The handle of the lobby.
owner
PFEntityKey**
library-allocated output, may return nullptr
The output owner. This value may be null if the owner has left or disconnected from the lobby while the owner migration policy is PFLobbyOwnerMigrationPolicy::Manual or PFLobbyOwnerMigrationPolicy::None.
Type: HRESULT
S_OK
if the call succeeded or an error code otherwise. The human-readable form of the error code can be retrieved via PFMultiplayerGetErrorMessage().
If this lobby object was created by calling PFMultiplayerJoinLobby(), this method will return an error until PFMultiplayerStartProcessingLobbyStateChanges() provides a PFLobbyUpdatedStateChange with PFLobbyUpdatedStateChange::ownerUpdated set to true. If joining the lobby succeeds, this field is guaranteed to be populated by the time PFMultiplayerStartProcessingLobbyStateChanges() provides a PFLobbyJoinLobbyCompletedStateChange.
If this lobby object was created by calling PFMultiplayerClaimServerLobby(), this method will return an error until PFMultiplayerStartProcessingLobbyStateChanges() provides a PFLobbyUpdatedStateChange with PFLobbyUpdatedStateChange::ownerUpdated set to true. If claiming the lobby succeeds, this field is guaranteed to be populated by the time PFMultiplayerStartProcessingLobbyStateChanges() provides a PFLobbyClaimServerLobbyCompletedStateChange.
Header: PFLobby.h