Closed AndersonFirmino closed 6 years ago
use the following adb
command to check log,
adb -d logcat godot:V GoogleService:V DEBUG:V AndroidRuntime:V ValidateServiceOp:V *:S
if you are using Firebase add this as well, GodotSQL:V FireBase:V
Thanks for helping me!
I'll try that right now.
I've been working on it for almost two whole nights. LOL
I did not know I had a way to see the app's logs installed.
12-10 03:15:28.620 21401 21401 D GoogleService: Play Service Available.
12-10 03:15:28.640 21401 21401 D GoogleService: Google initialized.
12-10 03:15:28.640 21401 21401 I GoogleService: connecting on start.
12-10 03:15:28.640 21401 21401 D GoogleService: Connecting to google play service
12-10 03:15:28.660 21401 21401 D godot : AdMob: Hide Banner
12-10 03:15:29.080 21401 21401 D GoogleService: google Connection failed.
12-10 03:15:29.100 21401 21401 D GoogleService: google Connection Resolving.
12-10 03:15:31.060 21401 21401 W godot : AdMob: onAdLoaded
12-10 03:15:32.480 21401 21401 W godot : AdMob: onRewardedVideoAdLoaded
12-10 03:15:33.840 21401 21420 I godot : ^_^_^_^_^ resize -286525136, 1080, 1920
12-10 03:15:34.740 21401 21401 D GoogleService: google Connection failed.
This log could at least say why it was not possible to login. π
If I touch any button I've implemented. Leaderboard or Achievement button this log appears
12-10 03:22:38.680 21772 21772 D GoogleService: Connecting to google play service
12-10 03:22:38.680 21772 21772 I GoogleService: PlayGameServices: Google calling connect
12-10 03:22:39.080 21772 21772 D GoogleService: google Connection failed.
OK, can you replace the line in modules/GodotGoogleService/android/PlayService.java
to
Log.d(TAG, "google Connection failed: " + m_result.getErrorMessage());
this should print more details.
and also try to clear Google play service
cache some time the old data can cause these problems.
I'll do it right now. And I'll come back with the details. πͺ
I implemented the code you mentioned above. It returns null as error message
12-10 04:18:47.680 25921 25921 D GoogleService: Play Service Available.
12-10 04:18:47.690 25921 25921 D GoogleService: Google initialized.
12-10 04:18:47.690 25921 25921 I GoogleService: connecting on start.
12-10 04:18:47.700 25921 25921 D GoogleService: Connecting to google play service
12-10 04:18:47.710 25921 25921 D godot : AdMob: Hide Banner
12-10 04:18:47.780 25921 25921 D GoogleService: google Connection failed: null
I cleared the cache too.
After I compile the apk and install the direct apk it connects. This only happens after I download my game from the Google Play Store.
What about after google Connection Resolving.
, is it still null
Yes, it remains null. I saw you commit. I got your last commit and set here using the same library settings as you. version 10.0.1.
In my tests I got to use version 11.6.0
One thing that is not in the tutorial. It is that you have to generate google-services.json. My gradle complained about the missing file and then I ran it on Google's website.
I believe that I have taken all the necessary steps.
Sorry about that, edit file: modules/GodotGoogleService/res/values/ids.xml
and set your app id there. app id needs to be set in AndroidManifest
as well, thought I mentioned that in README. my bad
I put my id in ids.xml Is there any other file that I should put the id?
It's all right. I followed my programmer intuition. LOL π
Using the last commit. Your module now does not work anymore. It starts connecting and fails.
12-10 05:03:00.740 29133 29133 D GoogleService: Play Service Available.
12-10 05:03:00.750 29133 29133 D GoogleService: Google initialized.
12-10 05:03:00.750 29133 29133 I GoogleService: connecting on start.
12-10 05:03:00.750 29133 29133 D GoogleService: Connecting to google play service
12-10 05:03:00.780 29133 29133 D godot : AdMob: Hide Banner
12-10 05:03:01.240 29133 29133 D GoogleService: google Connection failed: null
12-10 05:03:01.250 29133 29133 D GoogleService: google Connection Resolving.
12-10 05:03:03.020 29133 29133 W godot : AdMob: onAdLoaded
12-10 05:03:05.020 29133 29133 W godot : AdMob: onRewardedVideoAdLoaded
12-10 05:03:06.170 29133 29152 I godot : ^_^_^_^_^ resize -286525136, 1080, 1920
12-10 05:03:06.820 29133 29133 D GoogleService: google Connection failed: null
Did everything I could, and returned empty, guess this is time I update my API and SDK.
I'll push the changes as soon as possible.
So. I can only wait. I tested all the existing ones and none worked its was the only one that worked. π
The last version of my game is using the last commit of your module. I recently opened it and Google Play Games has connected. I'll go up to the store and see if it works. Hopefully yes.
I uploaded the game in the store. And gave the same problem. It works when I install the APK locally. But when you download the Google Play store it does not work and the log returns null. π
This thing could be happening because of the SHA-1 certificate, you can give it a try at https://console.developers.google.com under certificate section
I have set the sha1 certificate on this page. https://console.developers.google.com/apis/credentials/oauthclient/
In the details page of the game I had a link that went to the API page and I saw that it had a SHA1 certificate. I searched within the release keystore for this SHA1 key and replaced the value it was before.
I tried to use these modules but neither worked. Not even locally. https://github.com/kloder-games/godot-gpgs https://github.com/ranmaru90/Play-Game-Services-Android-Module-for-Godot
Your module at least locally works.
I'm still trying to figure out what's going on. You quoted that part in the conversation. I do not remember seeing it in any tutorial. And in the Google Play Services documentation they talk to do this.
How would I do this using your module?
app id needs to be set in AndroidManifest as well
That is done using, google_play_app_id
,
Well, I'm pretty much ported the SDK to 11.6.0
. and everything is working as it should.
it maybe the old api's were deprecated.
Wonderful, I'll test right now. I believe Google is rigid with their codes. Probably with this update it has to work.
Have you already committed your upgrade?
It seems the culprit is PLUS_LOGIN
scope just found out. https://developers.google.com/android/reference/com/google/android/gms/common/Scopes
SO we didn't add the Google+ login to the GoogleApiClient
, API was faulty from the start.
Very good, it gives me a happiness to read this. I fought so much with these modules. LOL I'm ready to try a few more times. π°
Done, just pushed the changes, check weather this work when you upload the game to Google Play Store
and a lot of changes will be made like for accessing the user profile (details) and so forth so stay tuned.
Of all the developers who asked for help on this journey. I am immensely grateful for your help. Seriously this is very important to me. π¬
I'll go through the compilation and upload processes in the Google store. As soon as I have the new version working or not, I update it here. I hope the next message is to close the issue. LOL
Again thank you very much for all the effort and help.
πͺ
I ran the gradle build command and this is giving problem with versions 11.6.0 I have a hunch this repository does not have the libraries it needs. https://oss.sonatype.org/content/repositories/snapshots
When you updated did you test with this url?
Here says to switch to https://maven.google.com
If I change here, do you think it could be a problem?
Are you using FireBase module, if so update that as well
I am not using Firebase so just remove the dependency of the firebase that will compile?
All the libraries from Google/FireBase need to be updated to 11.6.0
are you using any other google service related module...! and the compile error could help a lot.
If not everything will work
I'm getting this error
12-11 01:25:43.680 6586 6586 D GoogleService: Play Service Available.
12-11 01:25:43.710 6586 6586 D GoogleService: Google initialized.
12-11 01:25:43.720 6586 6586 D GoogleService: Google not connected
12-11 01:25:43.760 6586 6586 D godot : AdMob: Hide Banner
12-11 01:25:45.880 6586 6586 W GoogleService: signInResult:failed code=12502
12-11 01:25:45.880 6586 6586 W GoogleService: signInResult:failed code=8
I cleared the cache and now only get code 8
12-11 01:31:17.270 7913 7913 I GoogleService: PlayGameServices: Google calling connect
12-11 01:31:19.950 7913 7913 W GoogleService: signInResult:failed code=8
12-11 01:31:19.990 7913 7934 I godot : ^_^_^_^_^ resize -288622288, 1080, 1920
12-11 01:31:26.870 7913 7913 I GoogleService: PlayGameServices: Google not login calling connect
12-11 01:31:29.810 7913 7913 W GoogleService: signInResult:failed code=8
12-11 01:31:29.830 7913 7934 I godot : ^_^_^_^_^ resize -288622288, 1080, 1920
Have you changed the package name in config.py
file
This is my config.py
def can_build(plat):
return (plat == "android")
def configure(env):
if env["platform"] == "android":
env.android_add_maven_repository("url 'https://maven.google.com'")
env.android_add_gradle_classpath("com.google.gms:google-services:3.0.0")
env.android_add_gradle_plugin("com.google.gms.google-services")
env.android_add_dependency("compile 'com.google.android.gms:play-services-auth:11.6.0'")
env.android_add_dependency("compile 'com.google.android.gms:play-services-games:11.6.0'")
env.android_add_dependency("compile 'com.google.firebase:firebase-invites:11.6.0'")
env.android_add_java_dir("android");
env.android_add_res_dir("res");
env.android_add_to_manifest("android/AndroidManifestChunk.xml");
env.android_add_to_permissions("android/AndroidPermissionsChunk.xml");
env.android_add_default_config("applicationId 'org.armic.explosion'")
env.disable_module()
I think we have to update the service google plugin also
https://developers.google.com/android/guides/google-services-plugin#adding_the_json_file
I don't think we need that. can you show the error's from compile
Found what's giving the code=8 error, it's one of the Scope
, it seems I added some scope's that is not enabled in the Google new API librarys.
Yes I can get it here I'll put it in a pastebin because it's pretty big.
Nice, you found the error.
The error log: https://pastebin.com/HERRYUbC
The error is gradle can't find the library's, updated the module, check now and everything will work for sure.
I'll update here with your last commit.
But I still can't figure why this is only searching library's in local only.
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] Searched in the following locations:
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/AppData/Local/Android/Sdk/extras/google/m2repository/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.pom
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/AppData/Local/Android/Sdk/extras/google/m2repository/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.jar
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/Documents/Programacao/DevGames/GameEngines/Godot-Engine/godot2/Versions/my_builds/godot-2.1.4-stable/platform/android/java/sdk-manager/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.jar
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/AppData/Local/Android/Sdk/extras/android/m2repository/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.pom
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/AppData/Local/Android/Sdk/extras/android/m2repository/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.jar
01:07:27.080 [ERROR] [org.gradle.internal.buildevents.BuildExceptionReporter] file:/C:/Users/coderpy/Documents/Programacao/DevGames/GameEngines/Godot-Engine/godot2/Versions/my_builds/godot-2.1.4-stable/platform/android/java/sdk-manager/com/google/android/gms/play-services-games/11.6.0/play-services-games-11.6.0.jar
even when the library's where downloaded.
well. lets hope it will lookup to https://maven.google.com/
Now the game has connected me. But only as a Google user. Not like Google Play Games. And when I click on the icons of my game. Leaderboard and achievements earned these logs below. And also a Google Play Services message has stopped.
12-11 02:42:32.790 21412 21412 D GoogleService: Play Service Available.
12-11 02:42:32.810 21412 21412 D GoogleService: Google initialized.
12-11 02:42:32.810 21412 21412 D GoogleService: Google already connected to an account
12-11 02:42:32.810 21412 21412 D GoogleService: Google signed in.
12-11 02:42:32.870 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:32.870 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:32.870 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:32.890 21412 21412 D godot : AdMob: Hide Banner
12-11 02:42:33.530 21412 21412 D GoogleService: Google signed in.
12-11 02:42:33.530 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:33.530 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:33.530 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:33.560 21412 21436 I godot : ^_^_^_^_^ resize -288360144, 1080, 1920
12-11 02:42:37.020 21412 21412 W godot : AdMob: onAdLoaded
12-11 02:42:38.100 21412 21412 W godot : AdMob: onRewardedVideoAdLoaded
12-11 02:42:38.200 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.200 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.200 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.200 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.200 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.200 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.210 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.210 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.210 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.210 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.210 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.210 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.210 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.210 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.220 21412 21436 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 02:42:38.220 21412 21436 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 02:42:38.250 21412 21436 I godot : Dados carregados.
12-11 02:42:42.350 21412 21412 D godot : AdMob: Show Banner
12-11 02:42:56.100 21412 21412 D GoogleService: Google signed in.
12-11 02:42:56.100 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:56.100 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:56.100 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:42:56.120 21412 21436 I godot : ^_^_^_^_^ resize -288360144, 1080, 1920
12-11 02:43:07.900 21412 21412 W GoogleService: signInResult:failed code=8, Message: null
12-11 02:43:07.920 21412 21436 I godot : ^_^_^_^_^ resize -288360144, 1080, 1920
12-11 02:43:13.980 21412 21412 D GoogleService: Google signed in.
12-11 02:43:13.980 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:13.980 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:13.980 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:14.020 21412 21436 I godot : ^_^_^_^_^ resize -288360144, 1080, 1920
12-11 02:43:14.840 21412 21412 D GoogleService: Google signed in.
12-11 02:43:14.840 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:14.840 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:14.840 21412 21412 I godot : ARGNAME: java.lang.String
12-11 02:43:14.860 21412 21436 I godot : ^_^_^_^_^ resize -288360144, 1080, 1920
12-11 02:43:55.510 21412 21412 W godot : AdMob: onAdFailedToLoad -> ERROR_CODE_NO_FILL
12-11 02:44:18.730 23651 23724 E AndroidRuntime: FATAL EXCEPTION: highpool[3]
12-11 02:44:18.730 23651 23724 E AndroidRuntime: Process: com.google.android.gms, PID: 23651
12-11 02:44:18.730 23651 23724 E AndroidRuntime: java.lang.NullPointerException: Attempt to invoke virtual method 'java.lang.Class java.lang.Object.getClass()' on a null object reference
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at nxh.a(:com.google.android.gms@11951470:127)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at swi.run(:com.google.android.gms@11951470:11)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at mvc.run(:com.google.android.gms@11951470:26)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at nak.run(:com.google.android.gms@11951470)
12-11 02:44:18.730 23651 23724 E AndroidRuntime: at java.lang.Thread.run(Thread.java:818)
try changing the DEFAULT_SIGN_IN
to DEFAULT_GAMES_SIGN_IN
at line 58, in modules/GodotGoogleService/android/PlayService.java
I did the new tests with the code snippet you said. And now call the Google Play Games connection banner. Begins charging, darkens screen. And it disappears without making the connection.
12-11 09:47:17.530 3232 3232 D GoogleService: Play Service Available.
12-11 09:47:17.530 3232 3232 D GoogleService: Google initialized.
12-11 09:47:17.540 3232 3232 D GoogleService: Google not connected
12-11 09:47:17.560 3232 3232 D godot : AdMob: Hide Banner
12-11 09:47:24.780 3232 3232 W godot : AdMob: onAdLoaded
12-11 09:47:26.030 3232 3232 W godot : AdMob: onRewardedVideoAdLoaded
12-11 09:47:28.320 3232 3232 W GoogleService: signInResult:failed code=12502, Message: null
12-11 09:47:28.320 3232 3232 W GoogleService: signInResult:failed code=8, Message: null
12-11 09:47:28.400 3232 3254 I godot : ^_^_^_^_^ resize -288622288, 1080, 1920
12-11 09:47:31.120 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.120 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.120 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.120 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.130 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.130 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.130 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.130 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.130 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.130 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.140 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.140 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.140 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.140 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.140 3232 3254 I godot : WARNING: _png_warn_function: iCCP: known incorrect sRGB profile
12-11 09:47:31.140 3232 3254 I godot : At: drivers\png\image_loader_png.cpp:66.
12-11 09:47:31.150 3232 3254 I godot : Arquivo nβΓΊo existe.
12-11 09:47:35.280 3232 3232 D godot : AdMob: Show Banner
12-11 09:47:39.650 3232 3232 I GoogleService: PlayGameServices: Google not login calling connect
12-11 09:47:42.370 3232 3232 W GoogleService: signInResult:failed code=8, Message: null
Can you send me the logcat
It seems the problem is happening to a lot of people and I'm not receiving any problem here. But I might find some info on the logcat.
adb logcat > logcat
and for the last time can you make sure this is enabled: https://console.developers.google.com/apis/api/games.googleapis.com/overview?project= [project id here]
This is my API page for my game. Created by the Google Play Console. I did not create this manually.
My logcat with the last compilation. https://pastebin.com/XHnCVLF2
I'm not talking about sha-1 I'm talking aboit have you enabled the Games API in library's section.
It says it's activated here.
Ok, just found some thing in your logcat. Its the drive (Cloud). I'll push my changes. That would fix the errors
I was successful using this module. When I install the APK locally. Turning it over USB to my Android the Google Play system logs in normally. When I update my game in the Google Play store. It just does not connect.
Would you help me? π