I installed this GitHub - playgameservices/play-games-plugin-for-unity: Google Play Games plugin for Unity to show a leaderboard in my game. When I run the game on a device,during authentication the following message is throwm at adb console. For me it sounded like the android complaining about googleplay-service package is missing. But, i can definitely say it is there under sdk/extras/google. And what is that " NullReferenceException: Object reference not set to an instance of an object" in the stacktrace? What has gone wrong? Anyone has any ideas? Thanks in advance.
AndroidJavaException: java.lang.ClassNotFoundException: com.google.example.games.basegameutils.GameHelper
at UnityEngine.AndroidJNISafe.CheckException () [0x00000] in :0
at UnityEngine.AndroidJNISafe.CallStaticObjectMethod (IntPtr clazz, IntPtr methodID, UnityEngine.jvalue[ ] args) [0x00000] in :0
at UnityEngine.AndroidJavaObject._CallStatic[AndroidJavaObject] (System.String methodName, System.Object[ ] args) [0x00000] in :0
at UnityEngine.AndroidJavaObject.CallStatic[AndroidJavaObject] (System.String methodName, System.Object[ ] args) [0x00000] in :0
at UnityEngine.AndroidJavaObject.FindClass (System.String name) [0x00000] in :0
at UnityEngine.AndroidJavaObject._AndroidJavaObject (System.String className, System.Object[ ] args) [0x00000] in :0
at UnityEngine.AndroidJavaObject…ctor (System.String className, System.Object[ ] args) [0x00000] in :0
at GooglePlayGames.A
NullReferenceException: Object reference not set to an instance of an object
at GooglePlayGames.Android.AndroidClient+c__AnonStorey1.<>m__1 () [0x00000] in :0
at UnityEngine.AndroidJavaRunnableProxy.run () [0x00000] in :0
at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[ ] parameters, System.Globalization.CultureInfo culture) [0x00000] in :0
Rethrow as TargetInvocationException: UnityEngine.AndroidJavaRunnableProxy.run()
at UnityEngine.AndroidJavaProxy.Invoke (System.String methodName, System.Object[ ] args) [0x00000] in :0
at UnityEngine.AndroidJavaProxy.Invoke (System.String methodName, UnityEngine.AndroidJavaObject[ ] javaArgs) [0x00000] in :0
at UnityEngine._AndroidJNIHelper.InvokeJavaProxyMethod (UnityEngine.AndroidJavaProxy proxy, IntPtr jmethodName, IntPtr jargs) [0x00000] in :0
Update:
I found out that missing class is basically provided by the plugin. Therefore, I downloaded the source and ran everything in the ADT. Still it was giving the same error. Now I have started to doubt my sanity. IMy brain cell must be dying.