-
Notifications
You must be signed in to change notification settings - Fork 12
Game Storage Server
The Game Storage Server-Side allows game developers to store information from game-plays. Information to be stored may include:
- player preferences
- game status
- other player saved settings
This storage of information allows developers to load the information back to the game when the user starts a new game play, managing the players' preferences or the status of the game.
Information from game-plays can be stored through POST requests to /api/proxy/gamestorage/storage/<game>. To obtain the stored information for a user, a GET request should be made to /api/proxy/gamestorage/storage/<game>/<user>
All the available routes can be found in the Game Storage Server-Side routes folder. A Game Storage server API is also available.
Currently, the access to the database is not transactional, so developers should take this into account for their information storage.
Next section shows an example of use of the Game Storage, in this case to store and load max scores achieved in a game.
Using the QuizDemo mini-game, we can obtain the max score achieved in the game via a GET request to /api/proxy/gamestorage/storage/quizDemo/maxScore.
This will return the user with the highest score and the score:
{
"maxScore": 100,
"user": "cris"
}For complete information about a user , we can make a GET request to /api/proxy/gamestorage/storage/quizDemo/<user>. For instance, user 'pepe' return the following information:
{
"list": [
{
"score": 45,
"day": "1488471880902"
},
{
"score": 40,
"day": "1488471870902"
},
{
"score": 32,
"day": "1488471880802"
},
{
"score": 15,
"day": "1488471800902"
},
{
"score": 10,
"day": "1488471780902"
}
]
}We can see all the scores obtained by the user as well as the time when those scores were obtained.
When a game is now loaded and a user specified, the game shows the max score obtained by that user:
Figure 1.: Game Storage Server-Side allows to store information about users. For instance, the max score obtained by a user in QuizDemo is stored and loaded when the user access the game.
The game also shows the max scores obtained and allows to obtain information about scores of other users. For instance, user dev has the following scores:
Figure 2.: All scores obtained by a user in QuizDemo are stored so users can obtain them with their time.
- Home
- Game developers Guide
- Analytics developers Guide
- Analytics users Guide
- System Overview
- Tracker
- A2
- Analytics Real-time
- Analytics Front-end
- Analytics Back-end
- Game Storage Server
- Upgrading RAGE Analytics
- Wiki Style Guide