libgdx - How to prevent old android phones from crashing when accessing GooglePlayServices -


I'm ending my old game in which the Leaderboard feature is available for the user. I'm still using the latest GooglePlayServices available and BaseGameUtils from this source.

It works fine on Android 4.0. +, But I test it on older Android phones eg 2.2.1 This exception denotes java.lang.NoSuchMethodError as you can see below.

This is my main activity and expansion gamehelper.setup (this) :

  @ override protected zero Create (Bundle Saved Instantstate) {Super. NET (Saved Instantstate); Android Application Configuration Config = New Android Application Configuration (); Start (new megam (this), config); Try {if (gameHelper == null) {gameHelper = new GameHelper (this, GameHelper.CLIENT_GAMES); GameHelper.enableDebugLog (true); } GameHelper.setup (this); } Hold (exception e) {e.printStackTrace (); }}  



The logkit is shown in:

  07-27 17:18: 02.111: E / Android Random (1505): Fatal Exception: Main 07-27 17:18 18: 02.111: E / Android Random (1505): Java. Lung Any such method error: java.util.Collections.newSetFromMap 07-27 17:18: 02.111: E / Android Random (1505): at com.google.android.gms.common.api.c & Lt; Init & gt; (Unknown Source) 07-27 17:18 18: 02.111: E / Android Time (1505): at Com.google.android.gms.common.api.GoogleApiClient $ Builder.build (Unknown Source) 07-27 17:18 18: 02.111 : E / AndroidRuntime (1505): at com.google.example.games.basegameutils.GameHelper Setup (GameHelper.java:330) 07-27 17:18 18: 02.111: E / Android Random (1505): at com.test.testgame.android Android Launcher Connet (Android Learner Java 30) 07-27 17:18: 02.111: E / Android Random (1505): Android. App InstrumentationColactivotector (InstrumentationJavaauty 4747) 07-27 17:18 18: 02.111: E / Android TimeTime (1505): Android.AP.ActivateTrade.Perform Launch AC Tivity (ActivityThread.java:2633) 07-27 17:18 18: 02.111 : E / Android Rendime (1505): On Android. Activeivity Handle Launch Activity (ActivityTrad.Java 2685) 07-27 17:18 18: 02.111: E / Android Rendime (1505): Android. App ActiveTrade.Case $ 2300 (activityTrad.JYR626) 07-27 17:18 18: 02.111: E / Android Random (1505): Android. On the App ActivateTrade $ H Hondal Message (ActivityTrad.Java: 2038) 07-27 17:18 18: 02.111: E / Android Rendime (1505): Android.OS Handler Dispose Message (Handler. 99) 07-27 17:18 18: 02.111: E / Android Random (1505): At android.os.Looper.loop (Looper.java:123) 07-27 17:18 18: 02.111: E / AndroidDime (1505): Android.AP.ActivateTrade.Mine (ActivityTrad.Javimer 3333) 07-27 17:18 18: 02.111: E / Android Random (1505): at java.lang.reflect.Method.invokeNative (Basic Method ) 07-27 17: 18: 02.111: E / Android Time (1505): at java.lang.reflect. Method.invoke (Method.java; 21) 07-27 17: 18: 02.111: E / Android time (1505): com.android.internal.os.ZygoteInit $ Method Aller.run at MethodArgsC (ZygoteInit.java:858) 07- 27 17: 18: 02.111: E / Android Random (1505): at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:616) 07-27 17:18 18: 02.111: E / Android Random (1505) : On Dalvik.system.NativeStart.main (Basic Method)  



Is there any work?


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -