kaka 5 anni fa
parent
commit
b4cfb8ea34

+ 1 - 3
assets/resources/game/prefab/coin.prefab

@@ -88,9 +88,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,

+ 1 - 1
assets/resources/module/icon.meta → assets/resources/game/texture/coin.meta

@@ -1,6 +1,6 @@
 {
 {
   "ver": "1.1.2",
   "ver": "1.1.2",
-  "uuid": "7a53db90-09a4-4597-b1b4-2e57f620803b",
+  "uuid": "f7b396a4-06fa-4681-a126-260bce6d8098",
   "isBundle": false,
   "isBundle": false,
   "bundleName": "",
   "bundleName": "",
   "priority": 1,
   "priority": 1,

+ 36 - 0
assets/resources/game/texture/coin/1.png.meta

@@ -0,0 +1,36 @@
+{
+  "ver": "2.3.5",
+  "uuid": "7fcbfa5b-f738-4989-ac5a-e2066a7db637",
+  "type": "sprite",
+  "wrapMode": "clamp",
+  "filterMode": "bilinear",
+  "premultiplyAlpha": false,
+  "genMipmaps": false,
+  "packable": true,
+  "width": 81,
+  "height": 102,
+  "platformSettings": {},
+  "subMetas": {
+    "1": {
+      "ver": "1.0.4",
+      "uuid": "487aa335-4ecc-49fd-a6d9-65ce8e276d0f",
+      "rawTextureUuid": "7fcbfa5b-f738-4989-ac5a-e2066a7db637",
+      "trimType": "auto",
+      "trimThreshold": 1,
+      "rotated": false,
+      "offsetX": 0,
+      "offsetY": 0,
+      "trimX": 0,
+      "trimY": 0,
+      "width": 81,
+      "height": 102,
+      "rawWidth": 81,
+      "rawHeight": 102,
+      "borderTop": 0,
+      "borderBottom": 0,
+      "borderLeft": 0,
+      "borderRight": 0,
+      "subMetas": {}
+    }
+  }
+}

+ 36 - 0
assets/resources/game/texture/coin/2.png.meta

@@ -0,0 +1,36 @@
+{
+  "ver": "2.3.5",
+  "uuid": "998f42c1-485d-4322-9a9e-b55bed6480b7",
+  "type": "sprite",
+  "wrapMode": "clamp",
+  "filterMode": "bilinear",
+  "premultiplyAlpha": false,
+  "genMipmaps": false,
+  "packable": true,
+  "width": 116,
+  "height": 91,
+  "platformSettings": {},
+  "subMetas": {
+    "2": {
+      "ver": "1.0.4",
+      "uuid": "451780cc-ede2-44e3-871d-a643e547484c",
+      "rawTextureUuid": "998f42c1-485d-4322-9a9e-b55bed6480b7",
+      "trimType": "auto",
+      "trimThreshold": 1,
+      "rotated": false,
+      "offsetX": 0,
+      "offsetY": 0,
+      "trimX": 0,
+      "trimY": 0,
+      "width": 116,
+      "height": 91,
+      "rawWidth": 116,
+      "rawHeight": 91,
+      "borderTop": 0,
+      "borderBottom": 0,
+      "borderLeft": 0,
+      "borderRight": 0,
+      "subMetas": {}
+    }
+  }
+}

+ 36 - 0
assets/resources/game/texture/coin/3.png.meta

@@ -0,0 +1,36 @@
+{
+  "ver": "2.3.5",
+  "uuid": "05073b59-66e4-4cf2-b066-d7e9084467d6",
+  "type": "sprite",
+  "wrapMode": "clamp",
+  "filterMode": "bilinear",
+  "premultiplyAlpha": false,
+  "genMipmaps": false,
+  "packable": true,
+  "width": 70,
+  "height": 70,
+  "platformSettings": {},
+  "subMetas": {
+    "3": {
+      "ver": "1.0.4",
+      "uuid": "1042a639-32ff-4fa5-935c-fda10ffbc43a",
+      "rawTextureUuid": "05073b59-66e4-4cf2-b066-d7e9084467d6",
+      "trimType": "auto",
+      "trimThreshold": 1,
+      "rotated": false,
+      "offsetX": 0,
+      "offsetY": 0,
+      "trimX": 0,
+      "trimY": 0,
+      "width": 70,
+      "height": 70,
+      "rawWidth": 70,
+      "rawHeight": 70,
+      "borderTop": 0,
+      "borderBottom": 0,
+      "borderLeft": 0,
+      "borderRight": 0,
+      "subMetas": {}
+    }
+  }
+}

+ 8 - 20
assets/resources/module/redeem/RedeemNode.prefab

@@ -1375,8 +1375,8 @@
     },
     },
     "_contentSize": {
     "_contentSize": {
       "__type__": "cc.Size",
       "__type__": "cc.Size",
-      "width": 91,
-      "height": 91
+      "width": 70,
+      "height": 70
     },
     },
     "_anchorPoint": {
     "_anchorPoint": {
       "__type__": "cc.Vec2",
       "__type__": "cc.Vec2",
@@ -1427,9 +1427,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,
@@ -2204,9 +2202,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,
@@ -2981,9 +2977,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,
@@ -6643,9 +6637,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,
@@ -7420,9 +7412,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,
@@ -8197,9 +8187,7 @@
     ],
     ],
     "_srcBlendFactor": 770,
     "_srcBlendFactor": 770,
     "_dstBlendFactor": 771,
     "_dstBlendFactor": 771,
-    "_spriteFrame": {
-      "__uuid__": "8e888a59-b8e7-4546-b3cb-dbbd43868bee"
-    },
+    "_spriteFrame": null,
     "_type": 0,
     "_type": 0,
     "_sizeMode": 1,
     "_sizeMode": 1,
     "_fillType": 0,
     "_fillType": 0,

+ 1 - 1
assets/script/game/data/AppData.ts

@@ -15,7 +15,7 @@ export class AppData {
     /** api版本 */
     /** api版本 */
     public version: string = '1.0';
     public version: string = '1.0';
 
 
-    public appId: string = 'wxef592f91d2d13355';
+    public appId: string = 'wxcf31f0e54f7fefda';
 
 
     public mac: string = 'c9:01:e2:1c:b2:23,f6:60:e4:1a:b7:27';
     public mac: string = 'c9:01:e2:1c:b2:23,f6:60:e4:1a:b7:27';
 
 

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

@@ -99,6 +99,7 @@ class GData {
         this.moduleData.set(Fun.sign, this.sign);
         this.moduleData.set(Fun.sign, this.sign);
         this.moduleData.set(Fun.cashNormal, this.cashNormal);
         this.moduleData.set(Fun.cashNormal, this.cashNormal);
         this.moduleData.set(Fun.redBagCash, this.redBagCash);
         this.moduleData.set(Fun.redBagCash, this.redBagCash);
+        this.moduleData.set(Fun.redeem, this.redeem);
     }
     }
 }
 }
 
 
@@ -114,6 +115,7 @@ export enum Fun {
     sign = 6,       //签到
     sign = 6,       //签到
     cashNormal = 7, //常规提现
     cashNormal = 7, //常规提现
     redBagCash = 8, //红包提现
     redBagCash = 8, //红包提现
+    redeem = 9,     //兑换码
 }
 }
 
 
 declare global {
 declare global {

+ 4 - 0
assets/script/game/data/module/RedeemData.ts

@@ -18,6 +18,10 @@ export default class RedeemData extends Data {
         return this._redeemData;
         return this._redeemData;
     }
     }
 
 
+    init() {
+        this.redeemGetRedemption();
+    }
+
     /**兑换礼包*/
     /**兑换礼包*/
     async redeemExchange(input: string) {
     async redeemExchange(input: string) {
         let data = { code: input };
         let data = { code: input };

+ 2 - 2
assets/script/game/game/Game.ts

@@ -52,8 +52,8 @@ export default class Game extends cc.Component {
 
 
     //测试道具获取效果
     //测试道具获取效果
     private testFly() {
     private testFly() {
-        mk.fly.PlayCoinAnim(10001, 20, cc.v2(0, -300), cc.v2(0, 0));
-        // mk.fly.PlayCoinAnim(10002, 20, cc.v2(0, -300), 'Canvas/界面层/game/功能按钮/右侧按钮/btn2');
+        mk.fly.PlayCoinAnim(1, 20, cc.v2(0, -300), cc.v2(0, 0));
+        // mk.fly.PlayCoinAnim(2, 20, cc.v2(0, -300), 'Canvas/界面层/game/功能按钮/右侧按钮/btn2');
     }
     }
 
 
     update() {
     update() {

+ 1 - 1
assets/script/game/module/module/blessingBag/BlessingBag.ts

@@ -123,7 +123,7 @@ export default class BlessingBag extends cc.Component {
 
 
         if (gData.blessingBag.isPlayAniUpdate) {
         if (gData.blessingBag.isPlayAniUpdate) {
             if (this.lastNum < data.cumulativeAmount) {
             if (this.lastNum < data.cumulativeAmount) {
-                mk.fly.PlayCoinAnim(10001, 10, this.btnAd.getPosition(), this.btnCash.getPosition(), () => {
+                mk.fly.PlayCoinAnim(1, 10, this.btnAd.getPosition(), this.btnCash.getPosition(), () => {
                     this.aniBigAdBtn.setCurrentTime(0);
                     this.aniBigAdBtn.setCurrentTime(0);
                     this.aniBigAdBtn.play();
                     this.aniBigAdBtn.play();
                 });
                 });

+ 1 - 1
assets/script/game/module/module/moreGame/MoreGamePopNode.ts

@@ -71,6 +71,6 @@ export default class MoreGamePopNode extends cc.Component {
         // mk.audio.playEffect('getGold');
         // mk.audio.playEffect('getGold');
         mk.tip.pop('红包币+300');
         mk.tip.pop('红包币+300');
         //     GameM.commonData.updateRedMoney(300, RecordTYPE.online)
         //     GameM.commonData.updateRedMoney(300, RecordTYPE.online)
-        mk.fly.PlayCoinAnim(10001, 20, cc.v2(0, -300), cc.v2(0, 0));
+        mk.fly.PlayCoinAnim(1, 20, cc.v2(0, -300), cc.v2(0, 0));
     }
     }
 }
 }

+ 1 - 1
assets/script/game/module/module/redeem/RedeemNode.ts

@@ -65,7 +65,7 @@ export default class RichHelpPanel extends cc.Component {
         for (let i = 0; i < this.rewardData.length; i++) {
         for (let i = 0; i < this.rewardData.length; i++) {
             this.rds[i].active = true;
             this.rds[i].active = true;
             this.suc_rds[i].active = true;
             this.suc_rds[i].active = true;
-            cc.loader.loadRes("module/icon/reward" + this.rewardData[i].type, cc.SpriteFrame, (err, res) => {
+            cc.loader.loadRes("game/texture/coin/" + this.rewardData[i].type, cc.SpriteFrame, (err, res) => {
                 if (err) { console.log("img load err:" + JSON.stringify(err)); }
                 if (err) { console.log("img load err:" + JSON.stringify(err)); }
                 this.rd_imgs[i].spriteFrame = res;
                 this.rd_imgs[i].spriteFrame = res;
                 this.suc_rd_imgs[i].spriteFrame = res;
                 this.suc_rd_imgs[i].spriteFrame = res;

+ 1 - 1
assets/script/mk/system/FlySystem.ts

@@ -20,7 +20,7 @@ export default class FlySystem extends cc.Component {
     public async PlayCoinAnim(type: number = 0, num: number, pos: cc.Vec2, endpos: cc.Vec2 | string, cb: Function = null) {
     public async PlayCoinAnim(type: number = 0, num: number, pos: cc.Vec2, endpos: cc.Vec2 | string, cb: Function = null) {
         for (let i = 0; i < num; i++) {
         for (let i = 0; i < num; i++) {
             let copyCoin = await mk.pool.getPrefab('game/prefab/coin');
             let copyCoin = await mk.pool.getPrefab('game/prefab/coin');
-            let url = 'module/icon/reward' + type;
+            let url = 'game/texture/coin/' + type;
             let sf = await mk.loader.load(url, cc.SpriteFrame);
             let sf = await mk.loader.load(url, cc.SpriteFrame);
             copyCoin.getComponent(cc.Sprite).spriteFrame = sf;
             copyCoin.getComponent(cc.Sprite).spriteFrame = sf;
             copyCoin.setParent(this.node);
             copyCoin.setParent(this.node);