-
Notifications
You must be signed in to change notification settings - Fork 120
SNS Components tutorial
ChenLin edited this page Sep 16, 2015
·
2 revisions
引入SDK
- 1.
TangIDE支持的游戏SDK地址:*http://www.i5r.com.cn/sdk/scripts/sdk.js*。 -
- 在
选项>项目设置>外部jsURL填入该地址
- 在
放置排行榜组件
-
- 在TangIDE左侧面板找到排行榜组件拖入场景区域
-
- 默认使用
总排行榜即可
- 默认使用
保存分数
GameSDK.getInstance().saveScore((Math.random*(100 - 1) + 1), function(ret) {
console.debug('saveScore return:', JSON.stringify(ret));
});live demo http://www.i5r.com.cn/apprun-wechatoSjbMs7GPu-gH9dZ4tsoo52y4gmo%7C21442379386433.html