nite
June 12, 2015, 3:14am
21
Installation guide should cover all the steps necessary to finish the integration, can you tell me where did you put the jar files?
If you’re using cocos2d-x from source copy the jar files to:
cocos2d/cocos/platform/android/java/libs
If you’re using cocos2d-js or lua copy the jar files to:
frameworks/cocos2d-x/cocos/platform/android/java/libs
Here is the location:
C:\cocos2d-x-2.2.6\cocos2dx\platform\android\java\src\org\cocos2dx\lib
I don’t think there is a cocos directory in Cocos2dx v2.2.6. The path above is the path closest to the path stated in the installation guide.
Thanks.
I forgot to add in my reply to @nite that my game is done is C++, IDE is Visual Studio 2012 and OS is Windows 8.1, in case these points are relevant.
@DuncanTeckHean We have released a new version, 1.1 and there is better documentation included in this release as well. Can you please take a look and see if this now solves your integration needs? http://www.cocos2d-x.org/sdkbox
Yes, I have downloaded version 1.1 of SDKBox Google Analytics and Vungle. Unfortunately, the installation guide provided still could not solve the problem. I did follow all the steps (except the ones related to iOS and the paths of the libraries since the paths in the guide are a bit different than the ones in my Cocos2d-x). I think I have stated the path in my PC in the comment I made to @nite . This comment is just above your reply.
ok, we need to ask @nite to help.
Let me go ahead and make a complete sample for GA and Vungle, Android using v2.2.6 and get it to you to play with. Give me a day to do this?
Ok, thank you very much, slackmoehrle. I tried to build the Cocos2d-x project using Cygwin after I made the GA and Vungle code additions, but the build was not successful due to some JNI problem. Just in case this info is useful.
I am not even sure that we support cygwin at this point. We haven’t tested under it, for sure. Are you using Cygwin to do this work?
Yes, because Cygwin builds my project so that the proj.android of my game can be run on Eclipse Juno. The MS Visual Studio can build but cannot run the game. Hence, I have to use Eclipse to see how my project is working, visual-wise. But I think that my case is an isolated one, not a general issue. Other users could probably run and debug their project without Cygwin.
ok, let me get a sample sent over to you so you can try it.
cocos2dx - version 3.6
sdkbox google analytics - version 1.1.1
The implementation of the Analytics using the integration sdk.
In iOS, it was successful.
However, than Android is crash.
I leave a record of the crash dump.
I will see whether some of the issues that the?
====================================================================================
Build fingerprint: ‘lge/fx1sk_skt_kr/fx1sk:4.4.2/KOT49I.F260S20h/F260S20h.1425457260:user/release-keys’
pid: 30508, tid: 30526, name: Thread-7529 >>> com.handyapps.slapslap <<<
signal 11 (SIGSEGV), code 1 (SEGV_MAPERR), fault addr 00000000
Stack frame #00 pc 00568dd0 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::PluginGoogleAnalytics::init()+339): Routine sdkbox::PluginGoogleAnalytics::init() at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/plugins/googleanalytics/proj.android/jni/src/PluginGoogleAnalytics.cpp:74
Stack frame #01 pc 00539098 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (CGameManager::initGameManager()+144): Routine CGameManager::initGameManager() at /Users/rudalstb/Documents/cocos2d-x/handyappstudio/slapslap/proj.android/jni/…/…/Classes/CGameManager.cpp:41
Crash dump is completed
IAP integration also crash occurs.
I have a problem to me, but do not know well.
What do you know the problem?
********** Crash dump: **********
Build fingerprint: ‘lge/fx1sk_skt_kr/fx1sk:4.4.2/KOT49I.F260S20h/F260S20h.1425457260:user/release-keys’
pid: 4224, tid: 4246, name: Thread-8092 >>> com.handyapps.slapslap <<<
signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
Stack frame #00 pc 000221dc /system/lib/libc.so (tgkill+12)
Stack frame #01 pc 00013209 /system/lib/libc.so (pthread_kill+48)
Stack frame #02 pc 0001341d /system/lib/libc.so (raise+10)
Stack frame #03 pc 00012153 /system/lib/libc.so
Stack frame #04 pc 00021a90 /system/lib/libc.so (abort+4)
Stack frame #05 pc 00048e03 /system/lib/libdvm.so (dvmAbort+78)
Stack frame #06 pc 0002a840 /system/lib/libdvm.so (IndirectRefTable::get(void*) const+216)
Stack frame #07 pc 0004d6f3 /system/lib/libdvm.so (dvmDecodeIndirectRef(Thread*, _jobject*)+30)
Stack frame #08 pc 000502eb /system/lib/libdvm.so
Stack frame #09 pc 006f8c7b /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (sdkbox::JNIUtils::GetClassObjectFromObject(_jobject*)+18): Routine _JNIEnv::GetObjectClass(_jobject*) at /usr/local/Cellar/android-ndk/r10d/platforms/android-9/arch-arm/usr/include/jni.h:600
Stack frame #10 pc 006f9083 /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (sdkbox::JNIUtils::GetJNIMethodInfo(_jobject*, char const*, char const*)+14): Routine sdkbox::JNIUtils::GetJNIMethodInfo(_jobject*, char const*, char const*) at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/csc/protocols/proj.android/jni/src/bridge.cpp:168
Stack frame #11 pc 00568ccf /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (void sdkbox::JNIInvoke<void, std::string>(_jobject*, char const*, std::string)+22): Routine void sdkbox::JNIInvoke<void, std::string>(_jobject*, char const*, std::string) at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/plugins/iap/proj.android/…/…/core/include/bridge.h:497
Stack frame #12 pc 00568d41 /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (sdkbox::IAPProxy::requestProducts(std::string const&) const+20): Routine sdkbox::IAPProxy::requestProducts(std::string const&) const at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/plugins/iap/proj.android/jni/src/IAPProxy.cpp:39
Stack frame #13 pc 0056765d /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (sdkbox::IAPWrapper::refresh()+264): Routine sdkbox::IAPWrapper::refresh() at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/plugins/iap/proj.android/jni/src/IAPWrapper-android.cpp:93
Stack frame #14 pc 005672e3 /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (sdkbox::IAP::refresh()+6): Routine sdkbox::IAP::refresh() at /private/var/jenkins/.jenkins/jobs/_release_1.1.1/workspace/plugins/iap/proj.android/jni/…/…/share/PluginIAP.cpp:37
Stack frame #15 pc 00554820 /data/app-lib/com.handyapps.slapslap-2/libcocos2dcpp.so (SceneLobby::event_button_shop(cocos2d::Ref*)+1240): Routine SceneLobby::event_button_shop(cocos2d::Ref*) at /Users/rudalstb/Documents/cocos2d-x/handyappstudio/slapslap/proj.android/jni/…/…/Classes/SceneLobby.cpp:154
android studio log
06-22 19:44:55.903 18586-18586/? D/IabHelper﹕ Billing service connected.
06-22 19:44:55.913 18586-18586/? D/IabHelper﹕ Checking for in-app billing 3 support.
06-22 19:44:55.913 18586-18586/? D/IabHelper﹕ In-app billing version 3 supported for com.handyapps.slapslap
06-22 19:44:55.923 18586-18586/? D/IabHelper﹕ Subscriptions AVAILABLE.
06-22 19:44:55.923 18586-18586/? D/IabHelper﹕ Starting async operation: refresh inventory
06-22 19:44:55.933 18586-18660/? D/IabHelper﹕ Querying owned items, item type: inapp
06-22 19:44:55.933 18586-18660/? D/IabHelper﹕ Package name: com.handyapps.slapslap
06-22 19:44:55.933 18586-18660/? D/IabHelper﹕ Calling getPurchases with continuation token: null
06-22 19:44:55.943 18586-18660/? D/IabHelper﹕ Owned items response: 0
06-22 19:44:55.943 18586-18660/? D/IabHelper﹕ Continuation token: null
06-22 19:44:55.943 18586-18660/? D/IabHelper﹕ Querying SKU details.
06-22 19:44:55.943 18586-18660/? D/IabHelper﹕ queryPrices: nothing to do because there are no SKUs.
06-22 19:44:55.943 18586-18660/? D/IabHelper﹕ Querying owned items, item type: subs
06-22 19:44:55.953 18586-18660/? D/IabHelper﹕ Package name: com.handyapps.slapslap
06-22 19:44:55.953 18586-18660/? D/IabHelper﹕ Calling getPurchases with continuation token: null
06-22 19:44:55.963 18586-18660/? D/IabHelper﹕ Owned items response: 0
06-22 19:44:55.963 18586-18660/? D/IabHelper﹕ Continuation token: null
06-22 19:44:55.963 18586-18660/? D/IabHelper﹕ Querying SKU details.
06-22 19:44:55.963 18586-18660/? D/IabHelper﹕ queryPrices: nothing to do because there are no SKUs.
06-22 19:44:55.963 18586-18660/? D/IabHelper﹕ Ending async operation: refresh inventory
nite
June 22, 2015, 5:34pm
34
Is it possible to get a copy of your Cocos2dxActivity.java? That would help reproduce this issue.
Ibon
June 22, 2015, 7:41pm
35
Hi,
could you send us information about device and os version you deploy to ?
for the information we can get from the logs, apparently there’s no plugin reference to get methods for.
Could you please double check that the plugin jar files are being packaged with the application ? We are asking this because the place where the errors fire are core-centric to sdkbox and every plugin should fail at the same point. We’d like to discard this issue first.
Thanks.
I made a sample @DuncanTeckHean , I am uploading to Google Drive and will post the link for you. It does GA and Vungle, Cocos2d-x v2.2.6
Edit, it is now here
Thanks for your answer.
It will attach a Cocos2dxActivity.java file.
Verification please.
I have something to be worried about.
Maybe you, or you can test only in the release version?
Cocos2dxActivity.java.zip (3.8 KB)
********** Crash dump: **********
Build fingerprint: ‘lge/fx1sk_skt_kr/fx1sk:4.4.2/KOT49I.F260S20h/F260S20h.1425457260:user/release-keys’
pid: 20626, tid: 20644, name: Thread-14651 >>> com.handyapps.slapslap <<<
signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
Stack frame #00 pc 000221dc /system/lib/libc.so (tgkill+12)
Stack frame #01 pc 00013209 /system/lib/libc.so (pthread_kill+48)
Stack frame #02 pc 0001341d /system/lib/libc.so (raise+10)
Stack frame #03 pc 00012153 /system/lib/libc.so
Stack frame #04 pc 00021a90 /system/lib/libc.so (abort+4)
Stack frame #05 pc 00048e03 /system/lib/libdvm.so (dvmAbort+78)
Stack frame #06 pc 0002a840 /system/lib/libdvm.so (IndirectRefTable::get(void*) const+216)
Stack frame #07 pc 0004d6f3 /system/lib/libdvm.so (dvmDecodeIndirectRef(Thread*, _jobject*)+30)
Stack frame #08 pc 000502eb /system/lib/libdvm.so
Stack frame #09 pc 006f8f83 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::JNIUtils::GetClassObjectFromObject(_jobject*)+18)
Stack frame #10 pc 006f938b /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::JNIUtils::GetJNIMethodInfo(_jobject*, char const*, char const*)+14)
Stack frame #11 pc 00568fd7 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (ZN6sdkbox9JNIInvokeIvJSsEEET_P8_jobjectPKcDpT0 +22)
Stack frame #12 pc 0056906d /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::IAPProxy::purchase(std::string const&) const+20)
Stack frame #13 pc 00567cdb /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::IAPWrapper::purchase(std::string const&)+194)
Stack frame #14 pc 005675d3 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (sdkbox::IAP::purchase(std::string const&)+10)
Stack frame #15 pc 00554d70 /data/app-lib/com.handyapps.slapslap-1/libcocos2dcpp.so (SceneLobby::event_button_shop_noads(cocos2d::Ref*)+144)
nite
June 25, 2015, 11:31pm
39
Your Cocos2dxActivity.java looks correct, so my guess is that some AndroidManifest.xml are not configured correctly. Most likely google analytics, check the following item
did you add the reference to google-play-service in project.properties
did you add global_tracker.xml
Finally we created a sample project with everything integrated, you can try it out and see what’s the difference with your project
I am sorry.
I Google Analytics, was successful.
It is for Dump log IAP (Google Android).
Googld Android IAP only error occurs.
(IOS IAP is normal.)
IAP or sample there is?
Thanks you.