Achievements not showing in Google Play Games App

£可爱£侵袭症+ 提交于 2019-12-02 12:47:36

We found the answer ourselves. We messed up the configuration in the Google Play Developer console and in the Google API console.

Observations:

We noticed that our app had different OAuth2 Client IDs, e.g.:

Google Play Developer Console, Linked apps detail view

121212121212-4k97si3bnwertwertwet78oj571nl81ce3.apps.googleusercontent.com

Google API Console, Credentials, OAuth 2.0 client IDs

121212121212-h25jh8qrps8awertwetertwetweagp3n3t.apps.googleusercontent.com

We also saw that we had a lot of errors coming from the Google Play Games Services when we looked in the Dashboard of the Google API console.

At a closer look, we saw that nearly all of them were client errors (4xx), but we couldn't find out why.

Explanation:

I think at some point during development, we had problems with the SHA1 of our signing certificate and thought, we could create a new OAuth2.0 client manually in the Google API console to update the SHA1.

This is bad according to this Google Developers video which says that an OAuth2.0 client should be created in the Google Play Developer console, because it will automatically create the client ID and associate it with Achievements and Leaderboards. If it is created the other way around in the Google API console, there will be no linkage and it will return a valid login, but doesn't know which Achievements and Leaderboards should be used and will return errors.

Solution:

As Linked Apps in the Google Play Developer console can no longer be deleted after they were published, we renamed them so that they would be listed at the bottom of the linked apps (zz-mygame) and we deleted the OAuth 2.0 clients we created manually in the Google API console as they were not working with the Google Play services anyway.

We then created new linked apps in the Game services section of our game in the Google Play Developer Console, added the correct SHA1 and this generated a new OAuth 2.0 client which is connected with the Play services. We then checked this in the Google API console in the Credentials section and saw that a new OAuth 2.0 client was added and that this client had the same ID (121212121212-34adfasdfsf34343422zzzz3433.apps.googleusercontent.com) as in the linked apps section of the Game services in the Google Play Developer console.

After these changes, Achievements were working fine and already when were testing the game with dev builds and user who had testing access to the Google Play Game Services, the Achievements would now show up in the Google Play Games App and with an own tab listing all Achievements. Also the errors in the Google API console didn't occur any longer.

Thanks alot for your explanation!! I had the same issue. OAuth 2.0 client IDs were different. However, I didn't get any errors in the API console. The SHA1 fingerprint must be identical, and you should be good to go.

I've been adding/deleting/publishing achievements for a couple of days, and Google Play wouldn't display them. I could resolve the issue by setting Google Play back to factory settings on my Galaxy S4 ( cleared data, cache and uninstalled updates ). When I tried to display achievements in my game then, a popup said I needed a newer version of Google Play. Reinstalled it, everything works like a charm now. Hope that helps someone.

(edit) Unlocking achievements works, but there still is no tab for the Achievements nor Leaderboard in the Google Play Games App...waiting for Google to respond

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!