How can i cancel a message sending on the server side? For example on MeatchNotFound Message i want to create my custom match and want to cancel this message sending. So player will send Matchmaking request but will not receive MatchNotFound message.
Best Answer
C
Customer Support
said
over 6 years ago
Hi Ufuk,
Yes this is also possible, In the Cloud Code for the message you want to cancel you can use "Spark.setScriptError("error", "dont show");" to stop the message from being sent. So for example with this in the NewHighScoreMessage, a new high score could be logged to a leaderboard but the user would not receive the message. I hope that helps, if you have any further questions just let me know.
You can turn these off in the message tab in the configurator, if you navigate there and click edit on the MatchNotFoundMessage you can set "Send Via Socket" and "Send As Push" to off to prevent them from being sent.
If you have any further questions just let me know.
Thanks,
Liam
U
Ufuk Coban
said
over 6 years ago
is it possible to cancel it while in cloud code MeatchNotFound ? in some cases i want to cancel it.
Customer Support
said
over 6 years ago
Answer
Hi Ufuk,
Yes this is also possible, In the Cloud Code for the message you want to cancel you can use "Spark.setScriptError("error", "dont show");" to stop the message from being sent. So for example with this in the NewHighScoreMessage, a new high score could be logged to a leaderboard but the user would not receive the message. I hope that helps, if you have any further questions just let me know.
Ufuk Coban
How can i cancel a message sending on the server side? For example on MeatchNotFound Message i want to create my custom match and want to cancel this message sending. So player will send Matchmaking request but will not receive MatchNotFound message.
Hi Ufuk,
Yes this is also possible, In the Cloud Code for the message you want to cancel you can use "Spark.setScriptError("error", "dont show");" to stop the message from being sent. So for example with this in the NewHighScoreMessage, a new high score could be logged to a leaderboard but the user would not receive the message. I hope that helps, if you have any further questions just let me know.
Thanks,
Liam
- Oldest First
- Popular
- Newest First
Sorted by Oldest FirstCustomer Support
Hi Ufuk,
You can turn these off in the message tab in the configurator, if you navigate there and click edit on the MatchNotFoundMessage you can set "Send Via Socket" and "Send As Push" to off to prevent them from being sent.
If you have any further questions just let me know.
Thanks,
Liam
Ufuk Coban
is it possible to cancel it while in cloud code MeatchNotFound ? in some cases i want to cancel it.
Customer Support
Hi Ufuk,
Yes this is also possible, In the Cloud Code for the message you want to cancel you can use "Spark.setScriptError("error", "dont show");" to stop the message from being sent. So for example with this in the NewHighScoreMessage, a new high score could be logged to a leaderboard but the user would not receive the message. I hope that helps, if you have any further questions just let me know.
Thanks,
Liam
-
Documentation Notes
-
Design issues with user events
-
Using NoSQL
-
Runtime Collections vs Metadata Collections
-
Anonymous authentication from browser app
-
Modules
-
Movement With Unity
-
Problem with url parameters for downloadables
-
Querying NoSql GameSparks database
-
Challenge accesType
See all 2487 topics