From 1:1 matches to team matches, it is the first real-time PvP service in Korea.
Implement PvP modes you want with various options provided by Backnd.
Even if the number of users increases suddenly due to unforeseen events such as influencers, the server size automatically scales up, unlike other services.
Match users according to various conditions such as 1:1, solo, and team matches.
In addition, you can match without criteria or match users according to their skill levels based on scores or MMR.
Backnd Match is a service that creates a match between users according to set rules to provide a real-time game environment.
Various additional features such as result processing, reconnecting, and in-game chat are provided.
Backnd Match is a service that matches game users based on rules.
Users must have nicknames.
Backnd Match must be activated in the console.
Create a new match in the console.
Connect to a matching server.
// Matching server connection
Backend.Match.JoinMatchMakingServer(out errorInfo);
Backend.Match.OnJoinMatchMakingServer += (args) => {
// Check the success or failure of the matching server connection
};
Create a waiting room for match requests. Whether you request a match alone or with other users, you must create a waiting room.
The user who created the waiting room becomes the moderator.
// Create waiting room
Backend.Match.CreateMatchRoom();
Backend.Match.OnMatchMakingRoomCreate += (args) => {
// Check the success or failure of the waiting room creation
};
You can invite users to the waiting room. If you know their nickname, you can invite them.
//Invite user
Backend.Match.InviteUser(nickName);
Backend.Match.OnMatchMakingRoomInvite += (args) => {
// Check the success or failure of the user invitation
};
If the invited user sends an invitation acceptance message to the server, they will automatically enter the waiting room.
// Invite user
Backend.Match.AcceptInvitation(roomId, roomToken));
Backend.Match.OnMatchMakingRoomInviteResponse += (args) => {
// Check the success or failure of the invitation acceptance
};
Backend.Match.OnMatchMakingRoomUserList += (args) => {
// Receive waiting room information
};
Request a match.
//Matching request
Backend.Match.RequestMatchMaking(
matchType, modeType, inDate);
Backend.Match.OnMatchMakingResponse += (args) => {
// Check the success or failure of the matching request
};
If the server finds users that meet the condition, a match is formed. The information below is then sent to all matched users.
Match success information (matching card inDate)
Whether or not there is a sandbox match
In-game server address to connect to
Information on the game room to access
//Matching success
Backend.Match.OnMatchMakingResponse += (args) => {
// When matching is successful, the event is called once more as a success.
// In-game information to proceed with the game is included in the event when matching is successful.
};
When matching is successful, connect to the in-game server using the received in-game server address and port number.
// In-game server connection
Backend.Match.JoinGameServer(
serverAddress, serverPort, false, out errorInfo);
Backend.Match.OnSessionJoinInServer += (args) => {
// Check the success or failure of the in-game server connection
};
Access the game room using the game room token value received when matching is successful. At this time, the list of users currently participating in the room and the game room connection success messages are received at the same time.
//Access game room
Backend.Match.JoinGameRoom(roomToken);
Backend.Match.OnSessionListInServer += (args) => {
// Receive game room user information
};
Backend.Match.OnMatchInGameAccess += (args) => {
// Receive game room user entry message
};
When all matched users access the game room, a game start message is sent to all clients after the game start waiting time set in the console has passed.
// When all users enter the game room,
// the event below is called after the specified time on the console.
Backend.Match.OnMatchInGameStart() += {
// TODO
};
After receiving the game start message, binary data and chat messages can be sent. Data sent to the server is broadcast to all users in the game room, including the users sent via the server.
// Send binary data
Backend.Match.SendDataToInGameRoom(data);
// Receive binary data
Backend.Match.OnMatchRelay += (args) => {
// Process binary data
};
// Send chat message
Backend.Match.ChatToGameRoom(matchChatModeType, message);
// Receive chat message
Backend.Match.OnMatchChat += (args) => {
// Process chat message
};
If a user exits while the game is in progress or the client is terminated abnormally, the user can reconnect to the game in progress.
// Check if there is a game that can be reconnected
BackendReturnObject bro = Backend.Match.IsGameRoomActivate();
if(bro.IsSuccess())
{
// Check if there is a game room that can be reconnected
}
// Reconnect based on the game room information checked in the above function
if(JoinGameServer(addr, port, true, out errorInfo) == false)
{
// Error check
return;
}
The server aggregates the results based on the result messages and reflects them in the DB after receiving game result messages from each user in the game room.
Once all the game results are aggregated, the game is over. The users are immediately disconnected from the in-game server after the game ends.
// Game result aggregation
Backend.Match.MatchEnd(matchGameResult);
Backend.Match.OnMatchResult += (args) => {
// Check the success or failure of the game result aggregation
};
Contact us now to make a game backend for free!