>
> I have a question about Game Center: when you click on the Game Center button on the main menu, it opens the Achievements page on Game Center. You did that by adding the "Request achievements" with the Game Center plugin?
>
> Because it doesn't work when I test it, maybe I have to publish it for it to work?
>
Hey DonRIF . I have a couple of parts to the GameCenter functionality.
First I make sure the player is logged in to GameCenter. I do this at the beginning when game is starting up (when the title screen is showing).
So the events are:
Browser is online
Trigger once > CordovaGame login
If the user is already logged in to GameCenter (in the device's settings), they will see a little 'welcome to GameCenter' banner appear in the game when the login action fires. If they are not logged in, a window will display requesting they log in.
Then for the menu button to call up achievements, I just check they are logged in and then use the action 'show achievements'.
So the events are:
On button touched
CordovaGame is logged in > CordovaGame Show Achievements
Im pretty sure you can test GameCenter functionality as an 'Internal Tester' in iTunesConnect.
By the way, I learned a lot from the examples posted by — If you havent already checked his example capx's then you want to grab them, they will definitely help you. In this case, if you look at the one called 'Cocoon Google Play Games (Cordova Game)' that should be useful. While AnreasR is interested more in Cocoon, you can still see how he sets up the capx and then just adapt it to work in XDK.
Andy's Freebies, Store Items, Giveaways and more!
Thank you very much bro, I just figured out that the C2 native plugin Game Center is really weak compared to the cranberrygame one. Everything works fine now, thanks a bunch my friend!
I will release a quiz/trivia game very soon, I'll keep you in touch!
By the way, I only use Phonegap build to export my builds (every platform), I think it's the fastest way and less buggy one (XDK takes too long and Cocoon is just too messy for me), you just have to correctly edit the config.xml with the plugins and everything.