diff --git a/assets/Script/module/Config/GameConfig.ts b/assets/Script/module/Config/GameConfig.ts index 46cec90..1d23268 100644 --- a/assets/Script/module/Config/GameConfig.ts +++ b/assets/Script/module/Config/GameConfig.ts @@ -309,7 +309,7 @@ export class GameConfig { vibrateOpen: true, //震动 coinnum: 0, //每局的金币数 paid_user: false, //是否是付费用户 - version: "1.9.99", //版本号 + version: "2.0.01", //版本号 shushu_DistinctId: "", //数数访客ID shushu_AccountId: "", //数数账号ID uid: "", //用户和后端唯一id diff --git a/assets/Script/module/Tool/GameTool.ts b/assets/Script/module/Tool/GameTool.ts index 8c4127e..d809a17 100644 --- a/assets/Script/module/Tool/GameTool.ts +++ b/assets/Script/module/Tool/GameTool.ts @@ -2490,6 +2490,7 @@ var GameTool = { //比较版本号大小方法 compareVersion(v1: string, v2: string): number { + console.log("比较版本号", v1, v2); let result = 0; let v1Array = v1.split("."); let v2Array = v2.split("."); diff --git a/assets/shop/script/passCheck.ts b/assets/shop/script/passCheck.ts index f66f80d..7d116aa 100644 --- a/assets/shop/script/passCheck.ts +++ b/assets/shop/script/passCheck.ts @@ -749,26 +749,20 @@ export default class passCheck extends cc.Component { this.activateBtn.node.active = false; } cc.fx.GameConfig.GM_INFO.passCheckActivate = true; + // 获取passCheckMgr实例并更新激活状态 if (this.passCheckMgr && typeof this.passCheckMgr.refreshPassCheckItems === 'function') { this.passCheckMgr.refreshPassCheckItems(); } this.setbarNodePosX(); - - } setbarNodePosX() { let activate = cc.fx.GameConfig.GM_INFO.passCheckActivate; - let centralNode = this.node && this.node.getChildByName("centralNode"); - let barNode = centralNode && centralNode.getChildByName("barNode"); - if (barNode) { - if (activate || cc.fx.GameConfig.GM_INFO.getItemType == 1) { - barNode.x = 0; - } else { - barNode.x = -253; - } + let barNode = this.node.getChildByName("centralNode").getChildByName("barNode") + if (activate || cc.fx.GameConfig.GM_INFO.getItemType == 1) { + barNode.x = 0; } else { - console.warn("setbarNodePosX: centralNode 或 barNode 不存在,跳过位置更新"); + barNode.x = -253; } } diff --git a/assets/shop/script/passCheckMgr.ts b/assets/shop/script/passCheckMgr.ts index ff44bdd..e41c99c 100644 --- a/assets/shop/script/passCheckMgr.ts +++ b/assets/shop/script/passCheckMgr.ts @@ -413,15 +413,14 @@ export default class passCheckMgr extends cc.Component { if (canvasTemp) { JiaZai = canvasTemp.getComponent("JiaZai"); } - console.log("处理奖励", rewards); + // 处理每个奖励 for (const reward of rewards) { - // 上报战令奖励领取:itemIndex 从 0 开始,埋点等级从 1 开始;右侧为付费档位 + cc.fx.GameTool.getPassCheckPorp(reward.itemId, reward.itemNum, false); cc.fx.GameTool.shushu_Track("get_battle_pass", { cur_bp_level: reward.itemIndex + 1, is_paid_bp_usr: !reward.isLeftReward, }); - cc.fx.GameTool.getPassCheckPorp(reward.itemId, reward.itemNum, false); if (JiaZai) { switch (reward.itemId) { case 1001: // 金币 @@ -607,4 +606,4 @@ export default class passCheckMgr extends cc.Component { this.list = null; this.passCheckItem = null; } -} +} \ No newline at end of file