Permalink
Browse files

use sdkbox.setConfig

  • Loading branch information...
hugohuang1111 committed Feb 11, 2019
1 parent f8f19bf commit 0281f5371239113d79fded7a107a7b3a9b1b4447
Showing with 4 additions and 1 deletion.
  1. +2 −1 assets/Script/HelloWorld.js
  2. +2 −0 build/jsb-link/frameworks/runtime-src/Classes/AppDelegate.cpp
@@ -32,6 +32,7 @@ cc.Class({
return;
}

sdkbox.setConfig(JSON.stringify(sdkbox_config));
const self = this;
sdkbox.IAP.setListener({
onSuccess : function (product) {
@@ -87,7 +88,7 @@ cc.Class({
self.log("onUpdateStorePromotionVisibility:" + error);
},
});
sdkbox.IAP.init(JSON.stringify(sdkbox_config));
sdkbox.IAP.init();
sdkbox.IAP.setDebug(true);
},

@@ -43,6 +43,7 @@ using namespace anysdk::framework;

USING_NS_CC;
#ifdef SDKBOX_ENABLED
#include "SDKBoxJsHelper.h"
#include "PluginIAPJS.hpp"
#include "PluginIAPJSHelper.h"
#endif
@@ -81,6 +82,7 @@ bool AppDelegate::applicationDidFinishLaunching()

jsb_register_all_modules();
#ifdef SDKBOX_ENABLED
se->addRegisterCallback(register_all_SDKBoxJS_helper);
se->addRegisterCallback(register_all_PluginIAPJS);
se->addRegisterCallback(register_all_PluginIAPJS_helper);
#endif

0 comments on commit 0281f53

Please sign in to comment.