Merge branch 'main' of https://git.sparkus.cn/yangzhao/cb
This commit is contained in:
commit
a7cc1e5475
|
@ -16731,10 +16731,12 @@
|
||||||
"setUi": {
|
"setUi": {
|
||||||
"__id__": 96
|
"__id__": 96
|
||||||
},
|
},
|
||||||
"monthCardBtn": null,
|
"getcard": {
|
||||||
"monthCardBtn2": null,
|
"__id__": 322
|
||||||
"monthCardTime": null,
|
},
|
||||||
"monthCard": null,
|
"cardTime": {
|
||||||
|
"__id__": 341
|
||||||
|
},
|
||||||
"_id": "0dna+7W/NMp6RyIrSQLx5u"
|
"_id": "0dna+7W/NMp6RyIrSQLx5u"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
|
|
|
@ -63,15 +63,20 @@ export default class JiaZai extends cc.Component {
|
||||||
@property(cc.Node)
|
@property(cc.Node)
|
||||||
setUi: cc.Node = null;
|
setUi: cc.Node = null;
|
||||||
scheduleCallback2: any;
|
scheduleCallback2: any;
|
||||||
//月卡
|
// //月卡
|
||||||
|
// @property(cc.Node)
|
||||||
|
// monthCardBtn: cc.Node = null;
|
||||||
|
// @property(cc.Node)
|
||||||
|
// monthCardBtn2: cc.Node = null;
|
||||||
|
// @property(cc.Node)
|
||||||
|
// monthCardTime: cc.Node = null;
|
||||||
|
// @property(cc.Node)
|
||||||
|
// monthCard: cc.Node = null;
|
||||||
|
//月卡领取
|
||||||
@property(cc.Node)
|
@property(cc.Node)
|
||||||
monthCardBtn: cc.Node = null;
|
getcard: cc.Node = null;
|
||||||
@property(cc.Node)
|
@property(cc.Node)
|
||||||
monthCardBtn2: cc.Node = null;
|
cardTime: cc.Node = null;
|
||||||
@property(cc.Node)
|
|
||||||
monthCardTime: cc.Node = null;
|
|
||||||
@property(cc.Node)
|
|
||||||
monthCard: cc.Node = null;
|
|
||||||
// LIFE-CYCLE CALLBACKS:
|
// LIFE-CYCLE CALLBACKS:
|
||||||
|
|
||||||
onLoad() {
|
onLoad() {
|
||||||
|
@ -849,22 +854,8 @@ export default class JiaZai extends cc.Component {
|
||||||
console.log("未到期已领取");
|
console.log("未到期已领取");
|
||||||
}
|
}
|
||||||
if (data.code == 1) {
|
if (data.code == 1) {
|
||||||
cc.fx.GameTool.changeCoin(500);
|
this.getcard.active = true;
|
||||||
this.updateCoin();
|
NumberToImage.numberToImageNodes(cc.fx.GameConfig.GM_INFO.monthTime, 40, 20, "month_", this.cardTime, true)
|
||||||
|
|
||||||
let rewardData = [
|
|
||||||
{ type: "coin", count: 500 },
|
|
||||||
]
|
|
||||||
setTimeout(() => {
|
|
||||||
this.openRewardWindow(rewardData);
|
|
||||||
}, 500);
|
|
||||||
const dataTemp = {
|
|
||||||
change_reason: "month",
|
|
||||||
id: "1001",
|
|
||||||
num: 500,
|
|
||||||
compensate: false
|
|
||||||
}
|
|
||||||
cc.fx.GameTool.shushu_Track("resource_get", dataTemp);
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -970,6 +961,17 @@ export default class JiaZai extends cc.Component {
|
||||||
MiniGameSdk.API.shushu_SetSuperProperties(time, false);
|
MiniGameSdk.API.shushu_SetSuperProperties(time, false);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
onCardReward() {
|
||||||
|
cc.fx.GameTool.changeCoin(500);
|
||||||
|
this.updateCoin();
|
||||||
|
const dataTemp = {
|
||||||
|
change_reason: "month",
|
||||||
|
id: "1001",
|
||||||
|
num: 500,
|
||||||
|
compensate: false
|
||||||
|
}
|
||||||
|
cc.fx.GameTool.shushu_Track("resource_get", dataTemp);
|
||||||
|
}
|
||||||
|
|
||||||
// update (dt) {}
|
// update (dt) {}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user