Sandbox Matching(AI Matching)
This function is available when sandbox matching is enabled in BACKND Console.
Sandbox matching is a mode where game matching is applied only to the currently matched users if users are not matched until
sandbox matching switch time set in BACKND Console is over.
- For example, if only one user is in the matching server of a 1:1 game and sandbox is enabled, only that user can be matched successfully and enter the in-game server.
- The developer may generate as many AIs as they want to fill the number of users and perform AI matching between users.
- Once the game is finished, you may finish the game by sending its result to the server just like in normal games.
Matching of sandbox games
When matching is in progress in the matching server and the Sandbox matching switch time set in BACKND Console is over, the matching server establishes sandbox matching.
- When sandbox matching is established, for RoomInfo returned from the OnMatchMakingResponse event handler, m_enableSandBox flag is received as true.
Progress of sandbox game
For sandbox-matched users, the event is processed with the same logic for users matched normally.
The creation of AIs to fill the number of users and the processing of AI's logic should be performed by the client.
Send the results of sandbox games to the in-game server
A sandbox-matched user can process the game results just like when being matched normally.
With the exception of the game result of AI created by the client, the game results of all users must be sent to the in-game server to terminate the game normally.
- Regardless of the match mode(random, point, MMR), win/loss, points, and MMR decrease/increase are applied in the same way as normal matching.
- For a 1:1 or team battle game, the player may be processed as a loser.
- For solo battle games, only the ranks of players can be determined.
Example creation of sandbox matching's MatchGameResult
// 1:1. User lost to an AI player
MatchGameResult oneGameResult = new MatchGameResult();
oneGameResult.m_winners = new List<SessionId>();
oneGameResult.m_losers = new List<SessionId>();
// 2:2 team battle. There is one user and one AI player on each team
MatchGameResult teamGameResult = new MatchGameResult();
teamGameResult.m_winners = teamOneList; // In teamOneList, each user has one session ID
teamGameResult.m_losers = teamTwoList; // In teamTwoList, each user has one session ID
// 4-player solo battle. Three of them are human and one is an AI player
MatchGameResult meleeGameResult = new MatchGameResult();
meleeGameResult.m_winners = new List<SessionId>();