Matchmaking
Overview
AccelByte Gaming Services (AGS) Starter Matchmaking service provides a set of features developers can use to coordinate players into groups to participate in. The groups are based on selected preferences, such as game mode and language, and attributes stored for players, such as MMR, in order to provide well balanced competition.
How It Works
Party:
The Client asks the Session service to create a party. A Party Invitation notification is then relayed from the Session service through the Lobby.
Matchmaking:
The Client asks the Matchmaking service to request a match. The Matchmaking service then asks the Session service to create a session. Whether the session creation succeeds or fails, a notification will be conveyed back to the Client through the Lobby.
Manage Matchmaking in the Admin Portal
Create a Session Template
In the Admin Portal, select your intended game title.
In the left-hand menu, navigate to Game Management, expand New Matchmaking, and select Session Templates.
Select + Add Session Template in the top right-hand corner.
The Add Session Template form will appear.
Fill in the following fields:
- Session Template Name: enter a name for your session template.
- Session Type: select the session type from the dropdown menu.
- Min Players: set the minimum number of players allowed in the session.
- Max Players: set the maximum number of players allowed in the session.
- Invite Timeout: set the time limit (in seconds) before an invite from the session times out.
- Inactive Timeout: set how long (in seconds) the session will wait before timing out a player that has not responded.
- Joinability: select the joinability from the dropdown menu.
- Requested Regions: select the regions this session can be used in from the dropdown menu.
Once the form is completed, click Add to save your session.
Create a Match Ruleset
To learn how to create and configure Match Rules, you can access "Configure Match Rulesets" page, which is included in the preview for the new documentation portal.
Create a Match Pool
To learn how to create and configure Match Rules, you can access "Configure Match Pool" page, which is included in the preview for the new documentation portal.
Integrate Matchmaking into your Game Client
To learn more on how to integrate matchmaking into your game client, you can access "Integrating Matchmaking" page, which is included in the preview for the new documentation portal.
Implement Matchmaking Using the Client SDKs
Party
Create a Party
If the optional request is not filled, it will get the value from the configuration used.
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
FAccelByteModelsV2PartyCreateRequest Request;
Request.ConfigurationName = ConfigurationName; // MANDATORY
Request.Joinability = EAccelByteV2SessionJoinability::INVITE_ONLY; // Optional
Request.Members = {{OtherPartyMemberId}}; // Optional
Request.Attributes.JsonObject = MakeShared<FJsonObject>(); // Optional
Request.Attributes.JsonObject->SetStringField("PartyAttribute", "Attribute1"); // Optional
Request.MaxPlayers = 10; // Optional
Request.MinPlayers = 1; // Optional
Request.InactiveTimeout = 30; // Optional
Request.InviteTimeout = 86400; // Optional
ApiClient->Session.CreateParty(Request, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when create party success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when create party failed / error
}));
SessionV2PartySessionCreateRequest createPartyRequest = new SessionV2PartySessionCreateRequest
{
configurationName = "ConfigurationTemplateName",
joinability = SessionV2Joinability.INVITE_ONLY,
members = new []
{
new SessionV2MemberData()
{
id = otherUserIdToInvite
}
},
attributes = new Dictionary<string, string>()
{
{"partyAttribute", "attribute1"},
{"partyAttribute2", "attribute2"}
}
};
AccelBytePlugin.GetSession().CreateParty(createPartyRequest, result =>
{
if (!result.IsError)
{
// create party success
}
});
Retrieve parties
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.GetMyParties(THandler<FAccelByteModelsV2PaginatedPartyQueryResult>::CreateLambda(
[&](const FAccelByteModelsV2PaginatedPartyQueryResult& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.GetUserParties(result =>
{
if (!result.IsError)
{
// get party details success
}
});
Retrieve Party Details by Party ID
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.GetPartyDetails(PartyId, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.GetPartyDetails(partyId, result =>
{
if (!result.IsError)
{
// get party details success
}
});
Update Party Data
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
FAccelByteModelsV2PartyUpdateRequest Request;
Request.Version = PartyDataVersion; // Mandatory, must be the same version as latest party data
Request.Joinability = EAccelByteV2SessionJoinability::INVITE_ONLY; // Optional
Request.Attributes.JsonObject = MakeShared<FJsonObject>(); // Optional
Request.Attributes.JsonObject->SetStringField("PartyAttribute", "Attribute1"); // Optional
Request.MaxPlayers = 10; // Optional
Request.MinPlayers = 1; // Optional
Request.InactiveTimeout = 30; // Optional
Request.InviteTimeout = 86400; // Optional
ApiClient->Session.UpdateParty(PartyId, Request, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
SessionV2PartySessionUpdateRequest updateRequest = new SessionV2PartySessionUpdateRequest()
{
joinability = SessionV2Joinability.OPEN
};
AccelBytePlugin.GetSession()
.PatchUpdateParty(partyId, updateRequest, result =>
{
if (!result.IsError)
{
// update party success
}
});
Invite Player to Party
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.SendPartyInvite(PartyId, UserIdToInvite, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.InviteUserToParty(partyId, otherUserId, result =>
{
if (!result.IsError)
{
// invite to party success
}
});
Join a party
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.JoinParty(PartyId, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.JoinParty(partyId, result =>
{
if (!result.IsError)
{
// join party success
}
});
Reject a party invite
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.RejectPartyInvite(PartyId, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.RejectPartyInvitation(partyId, result =>
{
if (!result.IsError)
{
// reject party success
}
});
Leave a current party
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.LeaveParty(PartyId, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.LeaveParty(partyId, result =>
{
if (!result.IsError)
{
// leave party success
}
});
Kick a player from party
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.KickUserFromParty(PartyId, UserIdToKick, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.KickUserFromParty(partyId, userIdToKick, result =>
{
if (!result.IsError)
{
// kick user from party success
}
});
Promote member to party leader
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.PromotePartyLeader(PartyId, NewPartyLeaderId, THandler<FAccelByteModelsV2PartySession>::CreateLambda(
[&](const FAccelByteModelsV2PartySession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when get my party failed / error
}));
AccelBytePlugin.GetSession()
.PromoteUserToPartyLeader(partyId, userIdToPromote, result =>
{
if (!result.IsError)
{
// promote to party leader success
}
});
Listen to party notifications
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Lobby.SetV2PartyInvitedNotifDelegate(Api::Lobby::FV2PartyInvitedNotif::CreateLambda(
[&](const FAccelByteModelsV2PartyInvitedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2PartyMembersChangedNotifDelegate(Api::Lobby::FV2PartyMembersChangedNotif::CreateLambda(
[&](const FAccelByteModelsV2PartyMembersChangedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2PartyJoinedNotifDelegate(Api::Lobby::FV2PartyJoinedNotif::CreateLambda(
[&](const FAccelByteModelsV2PartyUserJoinedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2PartyRejectedNotifDelegate(Api::Lobby::FV2PartyRejectedNotif::CreateLambda(
[&](const FAccelByteModelsV2PartyUserRejectedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2PartyKickedNotifDelegate(Api::Lobby::FV2PartyKickedNotif::CreateLambda(
[&](const FAccelByteModelsV2PartyUserKickedEvent& Notif)
{
// Do something when receive notification
}));
AccelBytePlugin.GetLobby().SessionV2PartyUpdated +=
(Result<SessionV2PartySessionUpdatedNotification> notif) =>
{
// do something when party data is updated
};
AccelBytePlugin.GetLobby().SessionV2PartyMemberChanged +=
(Result<SessionV2PartyMembersChangedNotification> notif) =>
{
// do something when party member has changed
};
AccelBytePlugin.GetLobby().SessionV2UserJoinedParty += (Result<SessionV2PartyJoinedNotification> notif) =>
{
// do something when a user joined the party
};
AccelBytePlugin.GetLobby().SessionV2UserRejectedPartyInvitation +=
(Result<SessionV2PartyInvitationRejectedNotification> notif) =>
{
// do something when a user reject a party invitation
};
AccelBytePlugin.GetLobby().SessionV2InvitedUserToParty +=
(Result<SessionV2PartyInvitationNotification> notif) =>
{
// do something when a invited to a game session
};
AccelBytePlugin.GetLobby().SessionV2UserKickedFromParty +=
(Result<SessionV2PartyUserKickedNotification> notif) =>
{
// do something when kicked from the party
};
Game sessions
Create a game session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
FAccelByteModelsV2GameSessionCreateRequest Request;
Request.ConfigurationName = ConfigurationName; // MANDATORY
Request.Joinability = EAccelByteV2SessionJoinability::INVITE_ONLY; // Optional
Request.Type = EAccelByteV2SessionConfigurationServerType::DS; // Optional
Request.ClientVersion = GameServerVersion; // Optional
Request.ServerName = LocalServerName; // Optional
Request.Deployment = Deployment; // Optional
Request.RequestedRegions = {"us-west-1", "us-west2"}; // Optional
// Optional
TArray<FString> TeamA = {TeamAUserId1, TeamAUserId2};
TArray<FString> TeamB = {TeamBUserId1, TeamBUserId2};
TArray<FAccelByteModelsV2GameSessionTeam> Teams;
Teams.Add({TeamA});
Request.Teams = Teams;
// Optional
Request.Attributes.JsonObject = MakeShared<FJsonObject>();
Request.Attributes.JsonObject->SetStringField("PartyAttribute", "Attribute1");
Request.MaxPlayers = 10; // Optional
Request.MinPlayers = 1; // Optional
Request.InactiveTimeout = 30; // Optional
Request.InviteTimeout = 86400; // Optional
ApiClient->Session.CreateGameSession(Request,
THandler<FAccelByteModelsV2GameSession>::CreateLambda(
[&](const FAccelByteModelsV2GameSession& Result)
{
// Do something when operation success
}),
FErrorHandler::CreateLambda(
[&](int32 ErrorCode, const FString& ErrorMessage)
{
// Do something when operation error / failed
}));
SessionV2GameSessionCreateRequest createGameSessionRequest = new SessionV2GameSessionCreateRequest
{
joinability = SessionV2Joinability.OPEN,
configurationName = _configurationTemplateName
};
AccelBytePlugin.GetSession()
.CreateGameSession(createGameSessionRequest, result =>
{
if (!result.IsError)
{
// Creating game session success
}
});
Retrieve game sessions
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.GetMyGameSessions(
THandler<FAccelByteModelsV2PaginatedGameSessionQueryResult>::CreateLambda(
[&](const FAccelByteModelsV2PaginatedGameSessionQueryResult& Result)
{
// Do something when operation success
}),
FErrorHandler::CreateLambda(
[&](int32 ErrorCode, const FString& ErrorMessage)
{
// Do something when operation error / failed
}));
AccelBytePlugin.GetSession()
.GetUserGameSessions(null, null, null, result =>
{
if (!result.IsError)
{
// success get game session details
}
});
Retrieve game session details
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.GetGameSessionDetails( SessionId,
THandler<FAccelByteModelsV2GameSession>::CreateLambda(
[&](const FAccelByteModelsV2GameSession& Result)
{
// Do something when operation success
}),
FErrorHandler::CreateLambda(
[&](int32 ErrorCode, const FString& ErrorMessage)
{
// Do something when operation error / failed
}));
AccelBytePlugin.GetSession()
.GetGameSessionDetailsBySessionId(sessionId, result =>
{
if (!result.IsError)
{
// success get game session details
}
});
Update game session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
FAccelByteModelsV2GameSessionUpdateRequest Request;
Request.Version = PartyDataVersion; // Mandatory, must be the same version as current data in the backend
Request.Joinability = EAccelByteV2SessionJoinability::INVITE_ONLY; // Optional
Request.Attributes.JsonObject = MakeShared<FJsonObject>(); // Optional
Request.Attributes.JsonObject->SetStringField("AttributeName", "Attribute1"); // Optional
Request.MaxPlayers = 10; // Optional
Request.MinPlayers = 1; // Optional
Request.InactiveTimeout = 30; // Optional
Request.InviteTimeout = 86400; // Optional
ApiClient->Session.UpdateGameSession(GameSessionID, Request, THandler<FAccelByteModelsV2GameSession>::CreateLambda(
[&](const FAccelByteModelsV2GameSession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
SessionV2GameSessionUpdateRequest updateRequest = new SessionV2GameSessionUpdateRequest()
{
joinability = SessionV2Joinability.OPEN
};
AccelBytePlugin.GetSession()
.PatchGameSession(sessionId, updateRequest, result =>
{
if (!result.IsError)
{
// Update game session success
}
});
Delete a game session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.DeleteGameSession(SessionId, FVoidHandler::CreateLambda([]
{
// successfully deleted game session
}),
FErrorHandler::CreateLambda([](int32 ErrorCode, const FString& Message)
{
// error deleting game session
}));
AccelBytePlugin.GetSession()
.DeleteGameSession(sessionId, result =>
{
if (!result.IsError)
{
// delete game session success
}
});
Invite player to session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.SendGameSessionInvite(SessionId, UserIdToInvite, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.InviteUserToGameSession(sessionId, userIdToInvite, result =>
{
if (!result.IsError)
{
// invite to game session success
}
});
Join a game session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.JoinGameSession(SessionId, THandler<FAccelByteModelsV2GameSession>::CreateLambda(
[&](const FAccelByteModelsV2GameSession& Result)
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.JoinGameSession(sessionId, result =>
{
if (!result.IsError)
{
// join to game session success
}
});
Reject game session invite
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.RejectGameSessionInvite(GameSessionID, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.RejectGameSessionInvitation(sessionId, result =>
{
if (!result.IsError)
{
// reject to game session success
}
});
Leave a game session
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Session.LeaveGameSession(SessionId, FVoidHandler::CreateLambda(
[&]
{
// do something when success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCode, const FString& Message)
{
// do something when failed / error
}));
AccelBytePlugin.GetSession()
.LeaveGameSession(sessionId, result =>
{
if (!result.IsError)
{
// leave to game session success
}
});
Listen to game session notification
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->Lobby.SetV2GameSessionInvitedNotifDelegate(Api::Lobby::FV2GameSessionInvitedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSessionUserInvitedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2GameSessionMembersChangedNotifDelegate(Api::Lobby::FV2GameSessionMembersChangedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSessionMembersChangedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2GameSessionJoinedNotifDelegate(Api::Lobby::FV2GameSessionJoinedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSessionUserJoinedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2GameSessionRejectedNotifDelegate(Api::Lobby::FV2GameSessionRejectedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSessionUserRejectedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2GameSessionKickedNotifDelegate(Api::Lobby::FV2GameSessionKickedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSessionUserKickedEvent& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2GameSessionUpdatedNotifDelegate(Api::Lobby::FV2GameSessionUpdatedNotif::CreateLambda(
[&](const FAccelByteModelsV2GameSession& Notif)
{
// Do something when receive notification
}));
ApiClient->Lobby.SetV2DSStatusChangedNotifDelegate(Api::Lobby::FV2DSStatusChangedNotif::CreateLambda(
[&](const FAccelByteModelsV2DSStatusChangedNotif& Notif)
{
// Do something when receive notification
}));
AccelBytePlugin.GetLobby().SessionV2GameSessionUpdated += (Result<SessionV2GameSessionUpdatedNotification> notif) =>
{
// do something when a game session is updated
};
AccelBytePlugin.GetLobby().SessionV2GameSessionMemberChanged += (Result<SessionV2GameMembersChangedNotification> notif) =>
{
// do something when a game session member has change
};
AccelBytePlugin.GetLobby().SessionV2UserJoinedGameSession += (Result<SessionV2GameJoinedNotification> notif) =>
{
// do something when a user joined the game session
};
AccelBytePlugin.GetLobby().SessionV2UserKickedFromGameSession += (Result<SessionV2GameUserKickedNotification> notif) =>
{
// do something when kicked from a game session
};
AccelBytePlugin.GetLobby().SessionV2UserRejectedGameSessionInvitation += (Result<SessionV2GameInvitationRejectedNotification> notif) =>
{
// do something when a game session invite is rejected
};
AccelBytePlugin.GetLobby().SessionV2InvitedUserToGameSession += (Result<SessionV2GameInvitationNotification> notif) =>
{
// do something when invited to a game session
};
Matchmaking
Create a match ticket
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
FAccelByteModelsV2MatchTicketOptionalParams Optionals;
Optionals.Attributes.JsonObject = MakeShared<FJsonObject>();
Optionals.Attributes.JsonObject->SetStringField("TestAttribute1", "AttributeValue");
Optionals.Latencies = ApiClient->Qos.GetCachedLatencies();
Optionals.SessionId = PartySessionId;
ApiClient->MatchmakingV2.CreateMatchTicket(MatchPoolName,
THandler<FAccelByteModelsV2MatchmakingCreateTicketResponse>::CreateLambda(
[&](const FAccelByteModelsV2MatchmakingCreateTicketResponse& Result)
{
// Do something when operation success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCodes, const FString& ErrorMessage)
{
// Do something when operation failed
}),
Optionals);
string matchPoolName = "matchpool1";
MatchmakingV2CreateTicketRequestOptionalParams Optionals = new MatchmakingV2CreateTicketRequestOptionalParams();
// optional, use if we want to set attribute for this matchmaking request
Optionals.attributes = new Dictionary<string, object>()
{
{ "attribute1", "attribute1value" },
{ "attribute2", "attribute2value" }
};
// optional, use if we want to matchmake with a party
Optionals.sessionId = "partySessionId";
AccelBytePlugin.GetMatchmakingV2().CreateMatchmakingTicket(matchPoolName, Optionals, result =>
{
if (!result.IsError)
{
// create match ticket success
}
});
Get ticket details
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->MatchmakingV2.GetMatchTicketDetails(TicketID,
THandler<FAccelByteModelsV2MatchmakingGetTicketDetailsResponse>::CreateLambda(
[&](const FAccelByteModelsV2MatchmakingGetTicketDetailsResponse& Result)
{
// Do something when operation success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCodes, const FString& ErrorMessage)
{
// Do something when operation failed
}));
AccelBytePlugin.GetMatchmakingV2().GetMatchmakingTicket(matchmakingTicketId, result =>
{
if (!result.IsError)
{
// success get match ticket details
}
});
Delete match ticket
- Unreal Engine
- Unity
FApiClientPtr ApiClient = FMultiRegistry::GetApiClient();
ApiClient->MatchmakingV2.DeleteMatchTicket(TicketID,
FVoidHandler::CreateLambda([&]
{
// Do something when operation success
}),
FErrorHandler::CreateLambda([&](int32 ErrorCodes, const FString& ErrorMessage)
{
// Do something when operation failed
}));
AccelBytePlugin.GetMatchmakingV2().DeleteMatchmakingTicket(matchmakingTicketId, result =>
{
if (!result.IsError)
{
// success delete ticket
}
});