game-common / pragma.gameinstance / GameInstancePlugin / handleBackendAddPlayersByMatchmakingRequest /
handleBackendAddPlayersByMatchmakingRequest #
open suspend fun handleBackendAddPlayersByMatchmakingRequest(gameInstanceSnapshot: GameInstance.GameInstance, addedPlayers: List<GameInstance.GamePlayer>)
Called when players are being added to a game instance from matchmaking. The players will already be added to the game instance.
The added players will have their game client’s GameInstanceApi::OnAddedToGameInstance event triggered once this plugin completes, along with any data synced with the player using GameInstance.GameInstance.dataStore or GameInstance.GamePlayer.dataStore.
To prevent the players from being added to the game instance, throw an application error.
Parameters #
gameInstanceSnapshot | The game instance to be created. |
addedPlayers | The players that were added to the game instance from matchmaking. |