godot-sdk-integrations / godot-play-game-services

A Godot 4.x plugin for integration with Google Play Game Services
MIT License
138 stars 10 forks source link

Signing In doesn't complete #31

Closed PrabhTonicbits closed 4 months ago

PrabhTonicbits commented 4 months ago

Hi Jacob, Thank you so much for creating this plugin for Godot 4.2. I'm trying to implement the sign in and have followed the steps to configure the Pay services in Google play console and added my credentials. After trying to call the log in function, it pops up with my google accounts and when I try and sign in, it just loads for a little bit and doesn't sign me in. Not sure what exactly the issue could be. If you have any idea of what could be causing it that would be much appreciated. Thank you

Update: Fixed by giving the correct SHA fingerprint key to the google cloud platform (No fault in the plugin)

rogerlopz commented 4 months ago

Hi, can you open android studio and filter the logcat logs by package:com.jacobibanez.godot.test.game package:com.google.android.gms and see whats the error? I want to see if it's the same as mine where I only see a spinner but nothing loads after

Update: Fixed my issue by going to Play Games Services and publishing (after filling all details requested by google).

Iakobs commented 4 months ago

Hi @PrabhTonicbits sorry for the delay, I was taking some days off!

I'm not sure what do you mean when you say "it pops up with my google accounts". The V2 of google play games API doesn't open a screen for logging in as far as I remember. You have to log in in your Google Play Games app and then once you enter your game and call the plugin method for logging in, it just logs in automatically.

Can you verify that you are logged in with your account in the Google Play app first? Let me know how it goes!


Hi @rogerlopz I'm glad you fixed the issue! Publishing any changes in the Google Dev Console, under the Play Games section, is, in fact, necessary to see the changes in the game.

PrabhTonicbits commented 4 months ago

Hi Lakobs, Thanks for your reply! Sorry for getting back so late, I managed to fix the issue which was caused by me giving the wrong SHA fingerprint key to the Google Cloud Platform. Sorry for not closing the issue. The V2 Google Play games does have a screen at the start with all the locally stored accounts the very first time, once you sign in with one, it automatically signs in with the last account each time. I was able to get the account list to show but the sign in wouldn't validate (due to my fault of course lol) Thank you so much for all your work on the plugin!

Classified154 commented 1 day ago

Hello, I have this same exact problem. Ive already added SHA key (all 3) and debug key is the same as my game one. My still cant successfully sign in. How do you check if the game is published? I already hit "Publish" button.. its been a day

Iakobs commented 1 day ago

Hi @Classified154 you have to publish the play games services configurations, separately from the app itself, which is very confusing to be honest. Have you published the app or the configurations? There's a couple of screenshots in the README of the plugin :)

Also, if you published both the app and the configuration, remember that the SHA1 from the app in the play store is a special one that you only can obtain through the play console. There's also a section in the README about how many credentials you need and how to configure them, but for what you say you already have that part under control!

Classified154 commented 1 day ago

Thank you for the answer, so quick :O

I have checked and it says my google account need to be verified first, maybe that's why the publishing isn't done yet. I've already completed the configuration, so I'll wait and see for now

Classified154 commented 1 day ago

Hey @Iakobs

so my account is verified and sign in working! the question is how does SignInClient.request_server_side_access works? for some reason it isnt triggering the signal the client ID is the android debug client ID in credential right? or is it google provided one? or something else?

Iakobs commented 13 hours ago

Hi @Classified154 !

The client id in this case refers to the client id registered for the game server in Google cloud, please take a look at this implementation guide from Google.

Basically you need to create new credentials of type Web in order to authorise your server.

Hope that helps!

Classified154 commented 12 hours ago

Thank you.. I have it working!!

but now is it possible to get id_token? !'m sending request to "https://oauth2.googleapis.com/token" and it only gives access_token with the auth_code provided