playgameservices / play-games-plugin-for-unity

Google Play Games plugin for Unity
Other
3.43k stars 952 forks source link

Google Play Services doesnt initialize with this in logs: AndroidJavaException: java.lang.ClassNotFoundException: com.google.android.gms.games.Games #3111

Closed DNK-Creator closed 2 years ago

DNK-Creator commented 2 years ago

Hey everyone, I wanted to have a leaderboard in my game, so i set up all the sha keys and client ids, I did basically everything thats needed but nothing was showing up, even Sign in loading UI in my build. I did a lot of research and actually did fix something that was wrong but its still not showing up. I will post screenshots with my script and my logs. Please someone help me with this issue. devenv_T4U6rX1RLM Unity_62xZtY2Gnj

DNK-Creator commented 2 years ago

And when I try to Force Resolve I have this issue - https://github.com/googlesamples/unity-jar-resolver/issues/497

DNK-Creator commented 2 years ago

Someone had this issue before, but when I did what the solution says the error was the same https://www.higithub.com/playgameservices/issue/play-games-plugin-for-unity/3072

DNK-Creator commented 2 years ago

So I fixed it by 1) Creating a custom proguard file 2) Checking Debug and Release in publishing settings 3) Deleting all the files that connected to Google Play services 4) Downloading the plugin from the github again, then force resolving.

YOU CAN SKIP SECOND AND THIRD STEP IF FORCE RESOLVE WORKS FINE FOR YOU