Open EdgarGomez opened 11 months ago
This is still happening. Any ideas?
Hi I tried to change this line of code in GooglePlayGamesPluginDependencies.xml form this
<repository>Packages/com.google.play.games/Editor/m2repository</repository>
to this
<repository>Assets/GooglePlayGames/com.google.play.games/Editor/m2repository</repository>
I hope this help you
I'm using unity 2022.3.4f1 and GooglePlayGamesPlugin-0.11.01 Tried all of the above and nothing worked for me.
I fixed the issue by add this line of code in Plugins/Android/mainTemplate.gradle
dependencies {
implementation "com.google.android.gms:play-services-games-v2:+"
}
unity 2021.3.33, plugin 0.11.01 This is still happening. Does anyone know what an Android project looks like when properly exported? this file: Assets/GooglePlayGames/com.google.play.games/Editor/m2repository/com/google/games/gpgs-plugin-support/0.11.01/gpgs-plugin-support-0.11.01.srcaar if rename and unzip this file, open directory, rename and unzip classes.jar, you will find some class in folder classes - unzip\com\google\games\bridge I don't know what is .srcaar file. But my gut tells me that this file should be exported to an Android project, or unzipped to an Android project.
I'm using unity 2022.3.4f1 and GooglePlayGamesPlugin-0.11.01 Tried all of the above and nothing worked for me.
I fixed the issue by add this line of code in Plugins/Android/mainTemplate.gradle
dependencies { implementation "com.google.android.gms:play-services-games-v2:+" }
This worked for me! Thank you SIR!
I'm using unity 2022.3.4f1 and GooglePlayGamesPlugin-0.11.01 Tried all of the above and nothing worked for me.
I fixed the issue by add this line of code in Plugins/Android/mainTemplate.gradle
dependencies { implementation "com.google.android.gms:play-services-games-v2:+" }
Thank you SO much!!!
You can also disable minify in the Player settings in Android (if you don't care about minifying the Android code)
Describe the bug I've installed latest version of the plugin 0.11.01 and I´m getting this error when executing, once build, the login: Error Unity AndroidJavaException: java.lang.ClassNotFoundException: com.google.android.gms.games.PlayGames
I'm getting the error by connecting my phone and using Android Logcat. Actually the full error is:
AndroidJavaException: java.lang.ClassNotFoundException: com.google.android.gms.games.PlayGames java.lang.ClassNotFoundException: com.google.android.gms.games.PlayGames at java.lang.Class.classForName(Native Method) at java.lang.Class.forName(Class.java:454) at com.unity3d.player.UnityPlayer.nativeRender(Native Method) at com.unity3d.player.UnityPlayer.access$500(Unknown Source:0) at com.unity3d.player.UnityPlayer$e$1.handleMessage(Unknown Source:126) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loopOnce(Looper.java:201) at android.os.Looper.loop(Looper.java:288) at com.unity3d.player.UnityPlayer$e.run(Unknown Source:20) Caused by: java.lang.ClassNotFoundException: com.google.android.gms.games.PlayGames ... 9 more at UnityEngine.AndroidJNISafe.CheckException () [0x00000] in <00000000000000000000000000000000>:0 at UnityEngine.AndroidJNISafe.FindClass (System.String name) [0x00000] in <00000000000000000000000000000000>:0 2
The code I'm using for now is this:
`using UnityEngine; using GooglePlayGames; using GooglePlayGames.BasicApi;
public class GooglePlayServicesManager : MonoBehaviour { public static GooglePlayServicesManager Instance { get; private set; } public bool isConnectedToGPS = false; private SignInStatus status;
} `
I´ve tried everything I've seen about this error and similar ones. Custom Proguard file, fixing the file android dependencies, changing things inside the manifest, using resolve and force resolve, checking debug and release in minification... but none of those are working for me. Also changed the Sha1 from my play console inside developers hub. I'm still getting the error and I don't know what else do or try.
Please help.
Versions
Additional context It's a 2d game with 2d Core installed, Unity ads, another plugin for translations and nothing else. Shouldnt be a conflict with those.