I'm looking to track wins and losses per player per level. This would best be part of the players data, what would be the best way to track this information?
I'm also looking to track the sum of the populations' wins and losses per level and each unique players total wins and losses globally.
Best Answer
C
Customer Support
said
over 7 years ago
George, you could potentially use currencies for this. Each player has up to 6 different currencies and if you are not using all of them already for game currencies you could in fact use them quite easily for this. The Spark API has credit and debit methods which you can call from Cloud Code to say increment the win currency by 1 whenever the player wins. e.g.
Spark.loadPlayer(toPlayer).credit3(amount);
If you decide to use the currencies to do this, then you could use segments to track by level. Create a segment type called Level. And then move players up levels using setSegmentValue Could also use achievements to track levels but segments may fit better with your reporting requirements.
Hope that makes sense. Let us know if you need to see some sample code.
George, you could potentially use currencies for this. Each player has up to 6 different currencies and if you are not using all of them already for game currencies you could in fact use them quite easily for this. The Spark API has credit and debit methods which you can call from Cloud Code to say increment the win currency by 1 whenever the player wins. e.g.
Spark.loadPlayer(toPlayer).credit3(amount);
If you decide to use the currencies to do this, then you could use segments to track by level. Create a segment type called Level. And then move players up levels using setSegmentValue Could also use achievements to track levels but segments may fit better with your reporting requirements.
Hope that makes sense. Let us know if you need to see some sample code.
Rgds
G
George Vargas
said
over 7 years ago
Oh man, you guys are awesome! I had completely forgotten about the multiple currencies. That's a super easy way to track wins and losses and the segmentation is a god send.
George Vargas
I'm looking to track wins and losses per player per level. This would best be part of the players data, what would be the best way to track this information?
I'm also looking to track the sum of the populations' wins and losses per level and each unique players total wins and losses globally.
George, you could potentially use currencies for this. Each player has up to 6 different currencies and if you are not using all of them already for game currencies you could in fact use them quite easily for this. The Spark API has credit and debit methods which you can call from Cloud Code to say increment the win currency by 1 whenever the player wins. e.g.
Spark.loadPlayer(toPlayer).credit3(amount);
If you decide to use the currencies to do this, then you could use segments to track by level. Create a segment type called Level. And then move players up levels using setSegmentValue Could also use achievements to track levels but segments may fit better with your reporting requirements.
Hope that makes sense. Let us know if you need to see some sample code.
Rgds
- Oldest First
- Popular
- Newest First
Sorted by Oldest FirstCustomer Support
George, you could potentially use currencies for this. Each player has up to 6 different currencies and if you are not using all of them already for game currencies you could in fact use them quite easily for this. The Spark API has credit and debit methods which you can call from Cloud Code to say increment the win currency by 1 whenever the player wins. e.g.
Spark.loadPlayer(toPlayer).credit3(amount);
If you decide to use the currencies to do this, then you could use segments to track by level. Create a segment type called Level. And then move players up levels using setSegmentValue Could also use achievements to track levels but segments may fit better with your reporting requirements.
Hope that makes sense. Let us know if you need to see some sample code.
Rgds
George Vargas
Oh man, you guys are awesome! I had completely forgotten about the multiple currencies. That's a super easy way to track wins and losses and the segmentation is a god send.
Thank you!!
-
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