Hi everyone,
I am adding Game Center support and would like to leverage the listener to persist some local state around unlocked achievements if the game center call succeeds. This is to make sure that I don't try to invoke the unlockAchievement a second time for the same achievement. The listener callback seems to be perfect for that, although for some reason it doesn't get invoked.
This is the code I'm currently using:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 | local function requestCallback(event) print "enter requestCallback" if event.type == "unlockAchievement" then if event.data then --do good stuff else end end end gameNetwork.request( "unlockAchievement", { achievement = { identifier="1489002", showsCompletionBanner=true, }, listener=requestCallback }) |
Yes, I have same problem.
http://developer.anscamobile.com/forum/2012/01/24/game-center-offline-functionality-0#comment-82950
[removed]