Send user properties by match

I wanna send some data about user as match maked. is it possible. i implement now with match state but i think it is better to imatch have some data about player

Hey @ghasem167 sorry I don’t follow – what data are you trying to send about the player and to who?

hi, I develop a shooter game that every player can select one character. I wanna send some data like selected player character. can we send selected character with onrecivedmatchmakermatch event user data?

Yes those properties are accessible in the MatchmakerUser type within the event. For example, here is the interface in C#:

/// <summary>
/// The user with the parameters they sent to the server when asking for opponents.
/// </summary>
public interface IMatchmakerUser
{
    /// <summary>
    /// The numeric properties which this user asked to matchmake with.
    /// </summary>
    IDictionary<string, double> NumericProperties { get; }

    /// <summary>
    /// The presence of the user.
    /// </summary>
    IUserPresence Presence { get; }

    /// <summary>
    /// The string properties which this user asked to matchmake with.
    /// </summary>
    IDictionary<string, string> StringProperties { get; }
}

The properties above get received when the player enters the matchmaking pool with those properties. Here is our documentation showing how you can create a dictionary of string and numeric properties to enter the pool:

1 Like

thnx tis was helpful