understanding how to use leadboards and achievements ?

Hi All,

I was lucky to make Google play game services up and running in my test application :slight_smile: to show leaderboard, achievements and upload score using simple tap button… since this is new to me I have the following questions in my mind that I hope someone can help me with :

the questions are basic knowledge in how to use them …

1- How to use leaderboard normally, I meant how normally players update their scores or read score… is it by button or when they finish certain level and how … by button or automatically …

2- how to use achievements … although I was able view achievement but not really understand how to apply them in my code… what should happen when someone click on achievement. how can I check if player is eligible to view achievement and how to link the achievement with app logic and code.

I know my questions are not fully clear :slight_smile: but because I am lacking basic usage knowledge of the above and how to link them with code … I hope if someone can explain with simple example and walk thru the terminology and logic,

Thanks

Abdul

Most apps I’ve seen work like this.

For high scores:  only submit the high score after the game is over (or after whatever it is you are recording is done).  I personally keep the player’s best 10 scores and show them and then give them a button to the leaderboards to see everyone scores on the game over screen.  I also try to provide another button, perhaps on the main menu to see the leaderboard.

For achievements, as people earn them, you generally unlock them at that point.  The game network should show a brief popup announcing the achievement after its recorded.  I generally provide a button to show achievements as well usually on the main menu.

Rob

i see … how to do you manage the score locally in the device. i meant do you save them locally and what other stuff you need to maintain and save locally other than score.

also how do you manage the icons for each achievement. i noticed some games has lock icon on the achievements and once you achieve that level the icon changes for you. where you track that stuff. in the code of the game or in the gpgs…

thanks

Abdul

That’s the beauty of it.  You can do it however you like.  There is a tutorial we did recently on saving and displaying scores.  I save things like did the user turn the music on or off, did they turn the sound on or off.  If the game has difficulty settings what did they pick.  Score is just one of those things you can save.

For the achievements, there are two ways.  1. let Google (or Apple) do it. You provide the Icon to them when you setup the service and it shows in any dialog they produce.   Or 2.  in addition to #1, you know when something gets unlocked since you have to tell Google to unlock it, so you could have a local display that shows current achievements and ones that are still locked out.

That’s up to you.

Thanks Rob,

Your support is always appreciated, I went the score tutorial and it is has great information.

I am not really clear about the icons part… how can Google handle the locked/unlocked icons since there is one icon for each achievement.?

Regards

Abdul

Google will either only show you unlocked items, or they will have their own way of showing what’s been unlocked.  I forget, maybe they apply a gray fade to it, or they overlay their own lock icon.  I can’t look it up at the moment.

Rob

Most apps I’ve seen work like this.

For high scores:  only submit the high score after the game is over (or after whatever it is you are recording is done).  I personally keep the player’s best 10 scores and show them and then give them a button to the leaderboards to see everyone scores on the game over screen.  I also try to provide another button, perhaps on the main menu to see the leaderboard.

For achievements, as people earn them, you generally unlock them at that point.  The game network should show a brief popup announcing the achievement after its recorded.  I generally provide a button to show achievements as well usually on the main menu.

Rob

i see … how to do you manage the score locally in the device. i meant do you save them locally and what other stuff you need to maintain and save locally other than score.

also how do you manage the icons for each achievement. i noticed some games has lock icon on the achievements and once you achieve that level the icon changes for you. where you track that stuff. in the code of the game or in the gpgs…

thanks

Abdul

That’s the beauty of it.  You can do it however you like.  There is a tutorial we did recently on saving and displaying scores.  I save things like did the user turn the music on or off, did they turn the sound on or off.  If the game has difficulty settings what did they pick.  Score is just one of those things you can save.

For the achievements, there are two ways.  1. let Google (or Apple) do it. You provide the Icon to them when you setup the service and it shows in any dialog they produce.   Or 2.  in addition to #1, you know when something gets unlocked since you have to tell Google to unlock it, so you could have a local display that shows current achievements and ones that are still locked out.

That’s up to you.

Thanks Rob,

Your support is always appreciated, I went the score tutorial and it is has great information.

I am not really clear about the icons part… how can Google handle the locked/unlocked icons since there is one icon for each achievement.?

Regards

Abdul

Google will either only show you unlocked items, or they will have their own way of showing what’s been unlocked.  I forget, maybe they apply a gray fade to it, or they overlay their own lock icon.  I can’t look it up at the moment.

Rob