Prechádzať zdrojové kódy

Merge branch 'master' of git.mokasz.com:zouyong/team1_nc

wuwangdong 4 rokov pred
rodič
commit
c9af98bdc2

+ 12 - 0
assets/resources/animation/Main.meta

@@ -0,0 +1,12 @@
+{
+  "ver": "1.1.2",
+  "uuid": "8c65ee95-8d1e-4deb-8864-df1c7a01c9ee",
+  "isBundle": false,
+  "bundleName": "",
+  "priority": 1,
+  "compressionType": {},
+  "optimizeHotUpdate": {},
+  "inlineSpriteFrames": {},
+  "isRemoteBundle": {},
+  "subMetas": {}
+}

+ 11 - 15
assets/resources/game/prefab/game.prefab

@@ -1424,7 +1424,7 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "转盘",
+    "_name": "抽奖",
     "_objFlags": 0,
     "_parent": {
       "__id__": 20
@@ -4821,7 +4821,7 @@
     "asset": {
       "__uuid__": "b4dea4a9-29c8-46bc-a50d-5754afa7a2bd"
     },
-    "fileId": "63rziXcyxHFokjCZ0Fr710",
+    "fileId": "f7Yf9h1dRHZLz+lg7WWauy",
     "sync": false
   },
   {
@@ -5033,7 +5033,7 @@
     "asset": {
       "__uuid__": "b4dea4a9-29c8-46bc-a50d-5754afa7a2bd"
     },
-    "fileId": "c4aI5eiWRAGLBexP5VS26j",
+    "fileId": "399EqPMNNBU7h83hYJGVbf",
     "sync": false
   },
   {
@@ -5142,7 +5142,7 @@
     "asset": {
       "__uuid__": "b4dea4a9-29c8-46bc-a50d-5754afa7a2bd"
     },
-    "fileId": "5236VAzQlCxZdTA6AGSdX7",
+    "fileId": "7avS8JYZJAzY57dqfCuapt",
     "sync": false
   },
   {
@@ -9919,29 +9919,25 @@
     },
     "_enabled": true,
     "btn1": {
-      "__id__": 194
+      "__id__": 104
     },
     "btn2": {
-      "__id__": 37
+      "__id__": 104
     },
     "btn3": {
-      "__id__": 53
+      "__id__": 21
     },
     "btn4": {
-      "__id__": 218
+      "__id__": 37
     },
     "btn5": {
-      "__id__": 228
+      "__id__": 129
     },
     "btn6": {
-      "__id__": 238
+      "__id__": 251
     },
     "btn7": {
-      "__id__": 66
-    },
-    "btn8": null,
-    "btn_redeem": {
-      "__id__": 21
+      "__id__": 256
     },
     "_id": ""
   },

+ 2 - 0
assets/script/game/data/GameData.ts

@@ -86,6 +86,8 @@ export class GameData {
     //标志位 生产奖励的任务ui刷新
     public init_productTask = false;
 
+    public init_speedup = false;
+
     /**
      * 初始化游戏数据:网络配置信息,用户信息
      * @returns 

+ 8 - 26
assets/script/game/game/FunBtns.ts

@@ -4,32 +4,27 @@ const { ccclass, property } = cc._decorator;
 
 @ccclass
 export default class FunBtns extends cc.Component {
-    @property({ type: cc.Node, displayName: "互推" })
+    @property({ type: cc.Node, displayName: "农场等级奖励" })
     btn1: cc.Node = null;
-    @property({ type: cc.Node, displayName: "转盘" })
+    @property({ type: cc.Node, displayName: "提现" })
     btn2: cc.Node = null;
-    @property({ type: cc.Node, displayName: "裂变" })
+    @property({ type: cc.Node, displayName: "签到" })
     btn3: cc.Node = null;
-    @property({ type: cc.Node, displayName: "存钱罐" })
+    @property({ type: cc.Node, displayName: "抽奖" })
     btn4: cc.Node = null;
-    @property({ type: cc.Node, displayName: "福袋" })
+    @property({ type: cc.Node, displayName: "任务红包" })
     btn5: cc.Node = null;
-    @property({ type: cc.Node, displayName: "签到" })
+    @property({ type: cc.Node, displayName: "福利" })
     btn6: cc.Node = null;
-    @property({ type: cc.Node, displayName: "常规提现" })
+    @property({ type: cc.Node, displayName: "邀请" })
     btn7: cc.Node = null;
-    @property({ type: cc.Node, displayName: "气泡红包组" })
-    btn8: cc.Node = null;
-    @property({ type: cc.Node, displayName: "福利礼包" })
-    btn_redeem: cc.Node = null;
 
     onLoad() {
         gData.gameData.funBtns = this;
     }
 
     start() {
-
-
+        this.init();
     }
 
     init() {
@@ -40,19 +35,6 @@ export default class FunBtns extends cc.Component {
                 node_btn.active = data[i] == "1";
             }
         }
-        this.updateRedeem();
-    }
-
-    private updateRedeem() {
-        this.btn_redeem.active = gData.redeem.showBtn;
-    }
-
-
-    update() {
-        if (gData.redeem.init_btnChange) {
-            this.updateRedeem();
-            gData.redeem.init_btnChange = false;
-        }
     }
 }
 

+ 9 - 3
assets/script/game/module/speedUpUI/SpeedUpUI.ts

@@ -35,13 +35,18 @@ export default class SpeedUpUI extends cc.Component {
         if (gData.reward.add_redbag_value) {
             this.initCashOutStyle(gData.gameData.playerProp.redMoney + gData.reward.add_redbag_value);
         }
+
+        if (gData.gameData.init_speedup) {
+            gData.gameData.init_speedup = false;
+            this.lbl_remainTimes.string = `今日剩余次数:${gData.gameData.playerProp.speedUpLeftTimes}`;
+        }
     }
 
     /**
      * 底部提现相关样式
      */
     private initCashOutStyle(redMoney: number = 0) {
-        redMoney = redMoney/100;
+        redMoney = redMoney / 100;
         const cash_bar = gData.redBagCash.cash_bar;
         let cash_data = gData.redBagCash.getItemDataByIndex(cash_bar);
         if (!cash_data) return;
@@ -79,13 +84,14 @@ export default class SpeedUpUI extends cc.Component {
         if (gData.gameData.checkCanSpeedUp()) {
             mk.ui.closePanel(this.node.name);
             mk.ad.videoAdType = VideoAdType.video_init_14;
+            let self = this;
             mk.ad.watchAd(async (success) => {
                 if (success) {
                     gData.adData.watchVideo(null);
                     let response = await mk.http.sendData('farmSpeedUp', {});
-                    if (response && response.errcore == 0) {
+                    if (response && response.errcode == 0) {
                         gData.gameData.playerProp.speedUpLeftTimes = response.data.speedUpLeftTimes;
-                        this.lbl_remainTimes.string = `今日剩余次数:${gData.gameData.playerProp.speedUpLeftTimes}`;
+                        gData.gameData.init_speedup = true;
                     }
                     gData.gameData.setHarvest();
                     mk.tip.pop('加速成功!');

+ 4 - 0
assets/script/mk/system/GuideSystem.ts

@@ -11,6 +11,10 @@ export default class GuideSystem {
     public ui: cc.Node;
 
     public open(id) {
+        if (gData.gameData.configs.ServerConfig.NewUserGuide == '0') {
+            return
+        }
+
         this.crtGuideID = gData.gameData.getProp(GameProp.guideID);
         if (this.crtGuideID == undefined) {
             this.crtGuideID = 0;