Achievements Awarded Multiple Times
allornothing
Member, PRO Posts: 126
*** SORRY, GS Forum Spluttered and posted twice - mods please delete the dupe! ***]
Hi folks
The GS Cookbook states:
"Once an achievement is unlocked and awarded via Game Center it cannot be awarded again. Even if you continue to update an achievement past 100% it will be ignored by Game Center so there is no need to add extra SAVE logic for the achievement itself."
However in my app I update an achievement at the end of each game, tallying the amount of games played. An Achievement is awarded when this value gets to 10. The progress was working fine (i.e. 4 games = 40%), and on hitting 10, the achievement popped. However, now it is awarded at the end of every game after 10 plays - every single game! Is this just a bug in the Ad Hoc builds with Sandbox mode or is this something I'm doing wrong?
Hi folks
The GS Cookbook states:
"Once an achievement is unlocked and awarded via Game Center it cannot be awarded again. Even if you continue to update an achievement past 100% it will be ignored by Game Center so there is no need to add extra SAVE logic for the achievement itself."
However in my app I update an achievement at the end of each game, tallying the amount of games played. An Achievement is awarded when this value gets to 10. The progress was working fine (i.e. 4 games = 40%), and on hitting 10, the achievement popped. However, now it is awarded at the end of every game after 10 plays - every single game! Is this just a bug in the Ad Hoc builds with Sandbox mode or is this something I'm doing wrong?
Comments
It's a terrible bug.
EDIT:
Also some of my testers are reporting that if they don't sign in with GameCenter, the app crashes when it should be posting scores etc. This is on a change of scene, but all posting is handled on an actor spawned after the scene is loading (as per best practice I read somewhere)
Any ideas?
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
I thought this was from Dev Team? The Spawned Actor I read somewhere else, which I now can't find but I'm pretty sure it was an official source.
Also, various sources say you shouldn't post multiple leader boards/achievements at the same time - is the solution just to delay each with a timer? If so, what kind of timing would be required? My game has several progress achievements based on accumulative attributes that need to be updated at the end of each game.
I've been on GS for years and I've never seen or heard that though official documents. It may be one of those wives tales that gets passed around. I would never rely on a spawned actor to report important data as spawning is unreliable as to timing.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS
A slightly related question if you don't mind - I'm storing a lot of the progression values in a 'save file' table, but am I right in saying that you can't access tablecellvalue from achievement/leader board behaviors like 'Post Attribute' in GC Post Score? It has to be an attribute only/no expression?
Currently I'm having to change a local attribute to match the saved table value, then post that local attribute to gamecenter instead - seems convoluted to me, I'd much rather my achievements just referred directly to the table row/col and cut down a bunch of middle-men-behaviours...
I have an update achievement that posts a percentage (10% every game played). The progress updates correctly every game, and on 100%, the achievement pops correctly. Then every game afterwards, it pops again as if I just made 100%.
I've read that gamecenter handles the pop ups and gifting of achievements and can't gift the same achievement twice, so I can't see how this is my code. Is it a bug with Ad Hoc? Has anyone else ever had this?
I literally have a test button that gifts an achievement when pressed, as basic a rule as possible, and I can hit that over and over again with the same result. That shouldn't be happening!
Perhaps somethings for @codewizard and his team to look into.
This is the main reason Flip Runner! doesn't have achievements even though I spent days putting in over 30 of them, each with custom icons.
I was going to set up a table that stored whether or not the achievement has been achieved and skip sending an update if it has but then that would mean that if they were offline when achieving it, it'll never get updated in Game Centre.
I suppose I could set it that if it's over 101 or 102% stop sending it to Game Centre and hope that the player would have been online before then for it to register properly.
I was going to send my game over to Apple this week too >.<
Edit: Closing the game completely on the phone and re-opening seems to have stopped the continuous alert. It was only the one achievement repeating, it wasn't repeating all of them. I might stick to the plan and send it over to Apple this week.
Fingers crossed it's only a sandbox issue, along with the other issue I'm seeing where only some of them are showing an icon/image, even though on iTunes Connect they've all got the same image loaded. Might mention the image problem to Apple when I submit the binary, if there's a place to do so.
Guru Video Channel | Lost Oasis Games | FRYING BACON STUDIOS