Communicating with Players

Introduction

You'll need to be able to communicate to your players for various reasons. Maybe you want to display a daily message, inform a player of a certain promotion, or send a player a token which they can use to retrieve their password.

GameSparks offers you several ways to send messages to your players with incredible ease, flexibility, and customization:

Messages

Messages are used to notify your players with events or information. GameSparks includes many native messages such as earning a new achievement, acquiring a new highscore, or losing a position on a Leaderboard. You can customize these messages or create new ones:

Messages through Cloud Code

Cloud Code is a great way to dynamically change strings/images/values within your game in real-time to communicate with your players. Some examples:

    //Sets the IP Address for the player to retrieve
    Spark.setScriptData("serverIPAddress", "127.0.0.1");
    //Sets message of the day to view in-game, updates realtime
    Spark.setScriptData("dayMessage", "Smile! One day until the weekend!");
    //Sets buildVersion to control who gets to access to multiplayer
    Spark.setScriptData("buildVersion", "1.7");

Using SendGrid to Send E-Mails

GameSparks comes integrated with SendGrid which gives you the ability to send E-mails to your players but make sure to save E-mails against your player for reference. For an example of how to use SendGrid for a password retention process, click here.

More Information! For more information about SendGrid, click here.

Did this page help you? Please enter your feedback below. For questions about using this part of the platform, please contact support here