wuwangdong 4 роки тому
батько
коміт
694e07d7f3

+ 2 - 2
assets/script/game/module/setting/Setting.ts

@@ -82,9 +82,9 @@ export default class Setting extends cc.Component {
     }
 
     async clickMusic() {
-        mk.audio.switchMusicFunc();
         mk.audio.playEffect("button");
-
+        mk.audio.switchMusicFunc();
+    
         let music = "module/setting/texture/" + (mk.audio.getSwitchMusic() ? "on" : "off");
         this.img_music.spriteFrame = await mk.loader.load(music, cc.SpriteFrame);
     }

+ 8 - 4
assets/script/mk/system/AudioSystem.ts

@@ -33,7 +33,9 @@ export default class AudioSystem {
      */
     public async playMusic(audio_name: AUDIO_NAME, loop: boolean = true) {
         if(!this._switchMusic){
-            return;
+            this.setMusicVolume(0);
+        }else{
+            this.setMusicVolume(1);
         }
         if (!this._bg_audio) {
             this._bg_audio = await mk.loader.load(AUDIO_PATH + audio_name, cc.AudioClip);
@@ -72,7 +74,9 @@ export default class AudioSystem {
     public switchEffectFunc() {
         this._switchEffect = !this._switchEffect;
         if (!this._switchEffect) {
-            this.setStopAllEffect();
+            this.setEffectVolume(0);
+        }else{
+            this.setEffectVolume(1);
         }
         cc.sys.localStorage.setItem("switchEffect", this._switchEffect.toString());
     }
@@ -125,9 +129,9 @@ export default class AudioSystem {
     public switchMusicFunc() {
         this._switchMusic = !this._switchMusic;
         if (!this._switchMusic) {
-            this.setPauseMusic();
+            this.setMusicVolume(0);
         } else {
-            this.setResumeMusic();
+            this.setMusicVolume(1);
         }
         cc.sys.localStorage.setItem("switchMusic", this._switchMusic.toString());
     }

+ 1 - 1
build/jsb-link/assets/internal/config.json

@@ -1 +1 @@
-{"paths":{"0":["effects/builtin-2d-graphics",0],"1":["effects/builtin-2d-gray-sprite",0],"2":["effects/builtin-2d-label",0],"3":["effects/builtin-2d-spine",0],"4":["effects/builtin-2d-sprite",0],"5":["effects/builtin-3d-particle",0],"6":["effects/builtin-3d-trail",0],"7":["effects/builtin-clear-stencil",0],"8":["effects/builtin-unlit",0],"9":["materials/builtin-2d-base",1],"10":["materials/builtin-2d-graphics",1],"11":["materials/builtin-2d-gray-sprite",1],"12":["materials/builtin-2d-label",1],"13":["materials/builtin-2d-spine",1],"14":["materials/builtin-2d-sprite",1],"15":["materials/builtin-3d-particle",1],"16":["materials/builtin-3d-trail",1],"17":["materials/builtin-clear-stencil",1],"18":["materials/builtin-unlit",1]},"types":["cc.EffectAsset","cc.Material"],"uuids":["30aC+Hnw1PF4pEcoY3kUYb","14TDKXr2NJ6LjvHPops74o","f1h0LXVtJOta5JLZ1xCzfI","0ek66qC1NOQLjgYmi04HvX","28dPjdQWxEQIG3VVl1Qm6T","82migssElAGb04Ws6NimQX","2afAA24LNP4YmYiaVLiivs","c0BAyVxX9JzZy8EjFrc9DU","6dkeWRTOBGXICfYQ7JUBnG","6fgBCSDDdPMInvyNlggls2","a1U5RdJRFMFL57BdJC9H1X","3ae7efMv1CLq2ilvUY/tQi","e0LYfU5ZlNFoAB4UiRrGUG","7a/QZLET9IDreTiBfRn2PD","ecpdLyjvZBwrvm+cedCcQy","43L6CczwNM/6GGmCYEQIoH","46bU+b5fROqIXVPG6aZWWK","cffgu4qBxEqa150o1DmRAy","2aKWBXJHxKHLvrBUi2yYZQ","60AwGqM1dKELCGhPAR+jK6","02delMVqdBD70a/HSD99FK"],"scenes":{},"redirect":[],"deps":[],"packs":{"0b6c4470e":[20,3,1,4,18,6,0,11,15,16,19,8,9,13,5,10,7,17,12,14,2]},"name":"internal","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":true}
+{"paths":{"0":["effects/builtin-2d-graphics",0],"1":["effects/builtin-2d-gray-sprite",0],"2":["effects/builtin-2d-label",0],"3":["effects/builtin-2d-spine",0],"4":["effects/builtin-2d-sprite",0],"5":["effects/builtin-3d-particle",0],"6":["effects/builtin-3d-trail",0],"7":["effects/builtin-clear-stencil",0],"8":["effects/builtin-unlit",0],"9":["materials/builtin-2d-base",1],"10":["materials/builtin-2d-graphics",1],"11":["materials/builtin-2d-gray-sprite",1],"12":["materials/builtin-2d-label",1],"13":["materials/builtin-2d-spine",1],"14":["materials/builtin-2d-sprite",1],"15":["materials/builtin-3d-particle",1],"16":["materials/builtin-3d-trail",1],"17":["materials/builtin-clear-stencil",1],"18":["materials/builtin-unlit",1]},"types":["cc.EffectAsset","cc.Material"],"uuids":["30aC+Hnw1PF4pEcoY3kUYb","14TDKXr2NJ6LjvHPops74o","f1h0LXVtJOta5JLZ1xCzfI","0ek66qC1NOQLjgYmi04HvX","28dPjdQWxEQIG3VVl1Qm6T","82migssElAGb04Ws6NimQX","2afAA24LNP4YmYiaVLiivs","c0BAyVxX9JzZy8EjFrc9DU","6dkeWRTOBGXICfYQ7JUBnG","6fgBCSDDdPMInvyNlggls2","a1U5RdJRFMFL57BdJC9H1X","3ae7efMv1CLq2ilvUY/tQi","e0LYfU5ZlNFoAB4UiRrGUG","7a/QZLET9IDreTiBfRn2PD","ecpdLyjvZBwrvm+cedCcQy","43L6CczwNM/6GGmCYEQIoH","46bU+b5fROqIXVPG6aZWWK","cffgu4qBxEqa150o1DmRAy","2aKWBXJHxKHLvrBUi2yYZQ","02delMVqdBD70a/HSD99FK","60AwGqM1dKELCGhPAR+jK6"],"scenes":{},"redirect":[],"deps":[],"packs":{"0b6c4470e":[19,3,1,4,18,6,0,11,15,16,20,8,9,13,5,10,7,17,12,14,2]},"name":"internal","importBase":"import","nativeBase":"native","debug":false,"isZip":false,"encrypted":true}

BIN
build/jsb-link/assets/main/index.jsc


Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/config.json


Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/import/39/3985d4e0-463e-412c-946d-dfea97cb75bc.json


Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/import/65/65c9ca7e-c2c7-4b6c-85cb-11c7ebb15e6c.json


Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/import/82/82a16e23-7ade-43a5-af4f-5504bb39b61f.json


+ 0 - 1
build/jsb-link/assets/resources/import/a0/a02ca074-7ccc-458c-af56-59250031200e.json

@@ -1 +0,0 @@
-[1,0,0,["cc.Texture2D"],0,["2,9729,9729,33071,33071,0,0,1",-1],[0],0,[],[],[]]

+ 0 - 1
build/jsb-link/assets/resources/import/a0/a02ca074-7ccc-458c-af56-59250031200e@6c48a.json

@@ -1 +0,0 @@
-[1,["a0LKB0fMxFjK9WWSUAMSAO"],["_textureSetter"],["cc.SpriteFrame"],0,[{"name":"gameFaIn","rect":[0,0,720,1437],"offset":[0,0],"originalSize":[720,1437],"capInsets":[0,0,0,0]}],[0],0,[0],[0],[0]]

Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/import/c2/c24623b9-b557-420c-bf8c-8927ea736fa1.json


Різницю між файлами не показано, бо вона завелика
+ 0 - 0
build/jsb-link/assets/resources/import/e3/e315a4ee-0591-45b7-aac6-949ee3845f4d.json


BIN
build/jsb-link/assets/resources/native/a0/a02ca074-7ccc-458c-af56-59250031200e.jpeg


BIN
build/jsb-link/frameworks/runtime-src/proj.android-studio/.idea/caches/build_file_checksums.ser


+ 33 - 30
build/jsb-link/js backups (useful for debugging)/main.index.js

@@ -3740,7 +3740,7 @@ var o;
 return a(this, function(n) {
 switch (n.label) {
 case 0:
-if (!this._switchMusic) return [ 2 ];
+this._switchMusic ? this.setMusicVolume(1) : this.setMusicVolume(0);
 if (this._bg_audio) return [ 3, 2 ];
 o = this;
 return [ 4, mk.loader.load(r + t, cc.AudioClip) ];
@@ -3784,7 +3784,7 @@ cc.audioEngine.stopEffect(t);
 };
 t.prototype.switchEffectFunc = function() {
 this._switchEffect = !this._switchEffect;
-this._switchEffect || this.setStopAllEffect();
+this._switchEffect ? this.setEffectVolume(1) : this.setEffectVolume(0);
 cc.sys.localStorage.setItem("switchEffect", this._switchEffect.toString());
 };
 t.prototype.getSwitchEffect = function() {
@@ -3809,7 +3809,7 @@ cc.audioEngine.stopAllEffects();
 };
 t.prototype.switchMusicFunc = function() {
 this._switchMusic = !this._switchMusic;
-this._switchMusic ? this.setResumeMusic() : this.setPauseMusic();
+this._switchMusic ? this.setMusicVolume(1) : this.setMusicVolume(0);
 cc.sys.localStorage.setItem("switchMusic", this._switchMusic.toString());
 };
 t.prototype.getSwitchMusic = function() {
@@ -12206,7 +12206,10 @@ i = a.sent();
 mk.console.logSingle("refrehTask=>", i);
 if (0 != i.errcode) return [ 2, !1 ];
 this.playerProp.userFarmTaskInfo = i.data.userFarmTaskInfo;
-this.playerProp.userFarmTaskInfo.completeCount >= this.playerProp.userFarmTaskInfo.taskCount && mk.guide.open(5);
+if (this.playerProp.userFarmTaskInfo.completeCount >= this.playerProp.userFarmTaskInfo.taskCount) {
+mk.ui.closeAllUI();
+mk.guide.open(5);
+}
 t && (gData.gameData.init_task = !0);
 return [ 2, !0 ];
 }
@@ -13848,10 +13851,7 @@ a = n.data.userExp - gData.gameData.playerProp.farmExpValue;
 if (e) gData.gameData.gameStyle.doFlyExpAni(a, e, n.data); else {
 this.changeExp = !0;
 mk.tip.pop("获得" + a + "点等级经验");
-if (gData.gameData.playerProp.gradeLevel < n.data.farmLevel) {
-gData.gameData.playerProp.gradeLevel = n.data.farmLevel;
-gData.gameData.checkGradeUpUnLock();
-}
+gData.gameData.playerProp.gradeLevel < n.data.farmLevel && (gData.gameData.playerProp.gradeLevel = n.data.farmLevel);
 gData.gameData.playerProp.farmExpValue = n.data.userExp;
 gData.gameData.playerProp.farmGradeData = n.data.userFarmGrageRewardInfo;
 gData.gameData.init_red_point = !0;
@@ -23596,6 +23596,7 @@ this.node_task.active = !1;
 this.openBtn_ani.node.active = !1;
 this.lbl_Ani.node.active = !0;
 gData.gameData.init_task = !0;
+this.node_hand.active = !1;
 };
 e.prototype.onEnable = function() {
 mk.ad.showBanner(u.BannerAdType.banner_click_2);
@@ -23682,7 +23683,7 @@ t.lbl_taskProgress.string = e + "/" + o;
 }).start();
 this.lbl_taskNum.string = o.toString();
 var a = this.openBtn_ani.getComponent(p.default);
-a && e < o && a.setGray(!0);
+a && e < o && a.setGray(!0, !0);
 this.isCanCash = e >= o;
 this.node_hand.active = this.isCanCash;
 this.isCanCash && gData.adData.checkShowVideoIcon() ? this.node_videoIcon.active = !0 : this.node_videoIcon.active = !1;
@@ -23744,6 +23745,7 @@ return [ 2, null ];
 gData.gameData.playerProp.userFarmTaskInfo = e.data.userFarmTaskInfo;
 gData.gameData.playerProp.completeFarmTaskTimes = e.data.completeFarmTaskTimes;
 mk.data.setTAEventUser(0, "Cumulative_task", gData.gameData.playerProp.completeFarmTaskTimes);
+gData.gameData.checkGradeUpUnLock();
 gData.gameData.init_task = !0;
 this.maxNum = gData.gameData.playerProp.userFarmTaskInfo.taskCount;
 this.num = 0;
@@ -25282,34 +25284,35 @@ this.labRichArr = this.node.getComponentsInChildren(cc.RichText);
 this.skeArr = this.node.getComponentsInChildren(sp.Skeleton);
 this.setGray(this.grayState);
 };
-e.prototype.setGray = function(t) {
+e.prototype.setGray = function(t, e) {
+void 0 === e && (e = !1);
 if (this.lastState != t) {
 this.lastState = t;
 if (t) {
-for (var e = this.spArr.length, o = 0; o < e; o++) this.spArr[o].setMaterial(0, this.gray);
-for (var n = this.btnArr.length, a = 0; a < n; a++) {
-this.btnArr[a].enableAutoGrayEffect = !0;
-this.btnArr[a].grayMaterial = this.gray;
-this.btnArr[a].interactable = !1;
+for (var o = this.spArr.length, n = 0; n < o; n++) this.spArr[n].setMaterial(0, this.gray);
+if (!e) for (var a = this.btnArr.length, i = 0; i < a; i++) {
+this.btnArr[i].enableAutoGrayEffect = !0;
+this.btnArr[i].grayMaterial = this.gray;
+this.btnArr[i].interactable = !1;
 }
-for (var i = this.labArr.length, r = 0; r < i; r++) {
-this.labArrC[r] = this.labArr[r].node.color;
-this.labArr[r].node.color = this.grayColor;
+for (var r = this.labArr.length, c = 0; c < r; c++) {
+this.labArrC[c] = this.labArr[c].node.color;
+this.labArr[c].node.color = this.grayColor;
 }
-for (var c = this.outLineArr.length, s = 0; s < c; s++) {
-this.outLineArrC[s] = this.outLineArr[s].color;
-this.outLineArr[s].color = this.grayOutLineColor;
+for (var s = this.outLineArr.length, l = 0; l < s; l++) {
+this.outLineArrC[l] = this.outLineArr[l].color;
+this.outLineArr[l].color = this.grayOutLineColor;
 }
-for (var l = this.labRichArr.length, p = 0; p < l; p++) {
-this.labRichArrC[p] = this.labRichArr[p].node.color;
-this.labRichArr[p].node.color = this.grayColor;
+for (var p = this.labRichArr.length, u = 0; u < p; u++) {
+this.labRichArrC[u] = this.labRichArr[u].node.color;
+this.labRichArr[u].node.color = this.grayColor;
 }
 } else {
-for (e = this.spArr.length, o = 0; o < e; o++) this.spArr[o].setMaterial(0, this.normal);
-for (n = this.btnArr.length, a = 0; a < n; a++) this.btnArr[a].interactable = !0;
-for (i = this.labArr.length, r = 0; r < i; r++) this.labArr[r].node.color = this.labArrC[r];
-for (c = this.outLineArr.length, s = 0; s < c; s++) this.outLineArr[s].color = this.outLineArrC[s];
-for (l = this.labRichArr.length, p = 0; p < l; p++) this.labRichArr[p].node.color = this.labRichArrC[p];
+for (o = this.spArr.length, n = 0; n < o; n++) this.spArr[n].setMaterial(0, this.normal);
+if (!e) for (a = this.btnArr.length, i = 0; i < a; i++) this.btnArr[i].interactable = !0;
+for (r = this.labArr.length, c = 0; c < r; c++) this.labArr[c].node.color = this.labArrC[c];
+for (s = this.outLineArr.length, l = 0; l < s; l++) this.outLineArr[l].color = this.outLineArrC[l];
+for (p = this.labRichArr.length, u = 0; u < p; u++) this.labRichArr[u].node.color = this.labRichArrC[u];
 }
 } else console.log("和上次设置相同");
 };
@@ -25571,8 +25574,8 @@ var t, e;
 return c(this, function(o) {
 switch (o.label) {
 case 0:
-mk.audio.switchMusicFunc();
 mk.audio.playEffect("button");
+mk.audio.switchMusicFunc();
 t = "module/setting/texture/" + (mk.audio.getSwitchMusic() ? "on" : "off");
 e = this.img_music;
 return [ 4, mk.loader.load(t, cc.SpriteFrame) ];

+ 2 - 2
packages-hot-update/cfg.json

@@ -9,7 +9,7 @@
         "https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/EasyEliminate/baseRemote/",
         "https://xcx-box.oss-cn-hangzhou.aliyuncs.com/hotgame/kxnlyTest/baseRemote/"
     ],
-    "buildTime": 1631696063850,
-    "genTime": 1631696063850,
+    "buildTime": 1631754630985,
+    "genTime": 1631754630985,
     "genVersion": null
 }

Деякі файли не було показано, через те що забагато файлів було змінено