🏌️One Player

How one player matches work

One player matches are a great way to get players feeling like their skin is in the game that requires almost no development effort. Galaxy will find a different player with a similar skill level and return their Leaderboard Record. You can display this before ("score to beat") or after ("you won/lost") the game starts depending on your preference. Prizes are not awarded for One Player matches.

We recommend showing the player their competitors avatar to emphasize they're competing with another real human.

Galaxy will find another player with a score close to the current player:

GalaxyClientAPI.FindOpponent(new GalaxySDK.ClientModels.FindOpponentRequest {
    //Required parameter
    LeaderboardId = "leaderboard_id" //Which leaderboard to use for matching
    //Optional parameters
    OnlineOnly = false, //true will only return players currently online
    FriendsOnly = false, //true will only return friends
    FirstBound = -500, //Ranks below the player to consider
    SecondBound = 500, //Ranks above the player to consider
}, result => { 
    var scoreToBeat = result.Record.Score;
    var opponentName = result.Record.PlayerProfile.Nickname;
}, error => { })
Opponent Record Objects


/// User records for the requested user.
public LeaderboardRecord Record;

LeaderboardRecord reference

Display Avatars: See Display Avatar for details

Last updated