question

Carter Thomas avatar image
Carter Thomas asked

AmazonGamesClient.initialize error

Has anyone tried implementing Amazon's GameCircle into their Kindle Fire app? I'm developing in Kindle Fire Emulator. private static AmazonGamesClient agsClient; onCreate: AmazonGamesClient.initialize(getApplication(), new AmazonGamesCallback() { @Override public void onServiceReady(AmazonGamesClient agc) { agsClient = agc; } @Override public void onServiceNotReady(AmazonGamesStatus reason) { Log.e(TAG, ags.toString()); } }, EnumSet.of(AmazonGamesFeature.Leaderboards)); I get these errors when running the game: E/GC_ContentManager(29965): Unable to initialize AGS content. SDK will be unavailable E/GC_ContentManager(29965): java.lang.IllegalArgumentException: Compared version must not be null E/GC_ContentManager(29965): at com.amazon.ags.html5.content.ContentVersion.compareTo(ContentVersion.java:78) E/GC_ContentManager(29965): at com.amazon.ags.html5.content.ContentManager.initializeContent(ContentManager.java:154) E/GC_ContentManager(29965): at com.amazon.ags.api.AmazonGamesClient$1.run(AmazonGamesClient.java:146) E/GC_ContentManager(29965): at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1076) E/GC_ContentManager(29965): at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:569) E/GC_ContentManager(29965): at java.lang.Thread.run(Thread.java:856) CANNOT_AUTHORIZE agsClient is null; Any help will be appreciated. Thank you.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

Sujoy@Amazon avatar image
Sujoy@Amazon answered
Hi Gck, Sorry for the late response. Can you please run following code in the onCreate of your main activity and tell us the result. File aFile = getFilesDir(); File[] files = aFile.listFiles(); for(File f: files) { System.out.println("f.getName() = " + f.getName()); } Thing is we put version information inside apps directory while initializing the GameCircle in the first launch. And the error (in your post) is reported only when the version file is not found in this directory. Some how there is problem in your emulator. GameCircle works in emulator and we have tested that. Please insert above code in your app and launch the app for 2 or 3 times and see what is coming out in the log cat and report us. Thanks.
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.