heroiclabs / nakama-godot

Godot client for Nakama server written in GDScript.
Apache License 2.0
593 stars 69 forks source link

Metadata is supported for relayed matches, but I can't create a new match with metadata, only joining is possible. #205

Closed Suero152 closed 5 months ago

Suero152 commented 5 months ago

Apparently, I can pass metadata to join a match, but not to create a new one, is this correct?

# Create a multiplayer match on the server.
# @param p_name - Optional name to use when creating the match.
# Returns a task to represent the asynchronous operation.
func create_match_async(p_name : String = ''):
    return await _send_async(NakamaRTMessage.MatchCreate.new(p_name), NakamaRTAPI.Match).completed
# Join a multiplayer match by ID.
# @param p_match_id - The ID of the match to attempt to join.
# @param p_metadata - An optional set of key-value metadata pairs to be passed to the match handler.
# Returns a task which resolves to a multiplayer match.
func join_match_async(p_match_id : String, p_metadata = null):
    var msg := NakamaRTMessage.MatchJoin.new()
    msg.match_id = p_match_id
    msg.metadata = p_metadata
    return await _send_async(msg, NakamaRTAPI.Match).completed

An heroic labs dev/support guy said me that "Metadata is supported for relayed matches so this must be a limitation in the Godot SDK, please consider opening an issue in its repository."

More info here: https://forum.heroiclabs.com/t/listing-client-relayed-multiplayer-matches-w-labels-and-passwords/4827/7?u=suero

sesposito commented 5 months ago

Will close this as the implementation is correct, more info in the linked thread.