Sign In Register

How can we help you today?

Start a new topic

sending custom messages to specific players from matchFound section of cloud code

this is my Cloud Code for MatchFoundMessage :

 

var playerIds = ["57ca48d45e4c9304e6d0aad7", "57dfa343b6a70d04e5aec44a", "57dfb018b6a70d04e5af4b73"];

var msg= Spark.message();

msg.setPlayerIds(playerIds);
msg.setMessageData(

           {"employees":[
                        {"firstName":"John", "lastName":"Doe"},
                        {"firstName":"Anna", "lastName":"Smith"},
                        {"firstName":"Peter", "lastName":"Jones"}
                    ]}
          );
       
        msg.send();

 

but inside my game there is no receiving  confirmation of it.

So i was wondering if i did anything wrong .

I am using unreal engine.


Hi Ahsan,


Have you tried this with the Test Harness? Did you get any errors there?


Kind regards,

 - Steve

One important thing is that if you're using Blueprints, you have to set the Skill in the GSMatchmakingRequest to something other than 0, and then you have to change the match in Cloud Code as well.

Login to post a comment