[FIXED] SDKBOX IAP Plugin crash

Hello All,

I’m getting error while compiling in android.
i’m using cocos2d-x 3.6
And SDKBOX 1.2.0.1

ERROR:

from jni/…/…/SDHomeScene/SDHomeScene.cpp:9:
jni/…/…/SDShopScene/SDShopScene.h: In static member function ‘static SDShopScene* SDShopScene::create()’:
/CCPlatformMacros.h:44:49: error: cannot allocate an object of abstract type ‘SDShopScene’
TYPE *pRet = new(std::nothrow) TYPE();
^
jni/…/…/Classes/SDUI/SDShopScene/SDShopScene.h:59:5: note: in expansion of macro ‘CREATE_FUNC’
CREATE_FUNC(SDShopScene);
^
In file included from jni/…/…/SDHomeScene/SDHomeScene.cpp:11:0:
jni/…/…/SDShopScene/SDShopScene.h:19:7: note: because the following virtual functions are pure within ‘SDShopScene’:
class SDShopScene : public cocos2d::Layer, sdkbox::IAPListener
^
In file included from jni/…/…/SDShopScene/SDShopScene.h:16:0,
from jni/…/…/SDHomeScene/SDHomeScene.cpp:11:
jni/PluginIAP/PluginIAP.h:55:22: note: virtual void sdkbox::IAPListener::onInitialized(bool)
virtual void onInitialized(bool ok) = 0;
^
At global scope:
cc1plus: warning: unrecognized command line option “-Wno-extern-c-compat” [enabled by default]
cc1plus: warning: unrecognized command line option “-Wno-extern-c-compat” [enabled by default]
make: *** [obj/local/armeabi/objs/cocos2dcpp_shared///SDHomeScene/SDHomeScene.o] Error 1
make: Leaving directory `proj.android’
Ndk build failed!

I am unable to get the issue.
Please help…

Regards
Sriby7

Looks like you need to implement this method.

Thanks nite,
Its working fine now… :blush:

Regards,
Sriby7