Sign In Register

How can we help you today?

Start a new topic

who's the MatchUpdatedMessage sender?

Hi,

when a player joins or lefts a matchmaking, game sparks sends a MatchUpdatedMessage to others who are in the same matchmaking; I want to know if the player joined the match or left. If I had the message sender id I could make that but the message for the MatchUpdatedMessage doesn't contain such thing and even in cloud code when I use this: 

Spark.getData().who

it returns nothing...!

plz help! :(

1 Comment

Hi Narges,


The MatchUpdatedMessage doesn't have a sender as it isn't sent by a player, it's system generated. You can determine what caused the message to trigger from it's contents - all MatchFoundMessages should have either an 'addedPlayers' or 'removedPlayers' field, which will contain the id(s) of the player/players which joined/left.


Regards,

Vinnie

Login to post a comment