zane 1 month ago
parent
commit
324031e12e

+ 2 - 2
assets/resources/prefab/hall/PagePlay.prefab

@@ -2722,7 +2722,7 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "lbl_name-001",
+    "_name": "lbl_send_portal",
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {
@@ -3183,7 +3183,7 @@
   },
   {
     "__type__": "cc.Node",
-    "_name": "lbl_name-001",
+    "_name": "lbl_reward_portal",
     "_objFlags": 0,
     "__editorExtras__": {},
     "_parent": {

+ 19 - 1
assets/resources/prefab/hall/PagePlay.ts

@@ -4,6 +4,11 @@ import BaseUI from "../../scripts/base/BaseUI";
 import { Layout } from "cc";
 import { instantiate } from "cc";
 import { PlayGameItem } from "../item/PlayGameItem";
+import RankM, { RankDto } from "../../scripts/api/RankM";
+import Utils from "../../scripts/utils/Utils";
+import UserM from "../../scripts/api/UserM";
+import { GoodsId } from "../../scripts/api/GoodsId";
+import { PageRank } from "./PageRank";
 
 const { ccclass, property } = _decorator;
 
@@ -17,7 +22,7 @@ export class PagePlay extends BaseUI {
     this.tpl.active = false;
     this.ui();
   }
-  ui() {
+  async ui() {
     let layout = this.FindNode("games_layout");
     this.tpl.parent = layout;
     this.tpl.active = true;
@@ -29,6 +34,19 @@ export class PagePlay extends BaseUI {
     //   item.active = true;
     //   item.getComponent(PlayGameItem).init((i + 1) * 100);
     // }
+
+    let data: RankDto = await RankM.ins.rankData(PageRank.RankTypeSeason);
+
+    this.setText(
+      "lbl_send_portal",
+      Utils.formatNumber(data.remainPog, 0) +
+        "/" +
+        Utils.formatNumber(data.seasonPog, 0)
+    );
+    this.setText(
+      "lbl_remain_portal",
+      "" + UserM.ins.getGoodsCount(GoodsId.POG)
+    );
   }
 
   public onShow(): void {

+ 3 - 3
assets/resources/prefab/hall/PageRank.prefab

@@ -2634,8 +2634,8 @@
     },
     "_lpos": {
       "__type__": "cc.Vec3",
-      "x": 286.286,
-      "y": -27.431,
+      "x": 279.356,
+      "y": -33.608,
       "z": 0
     },
     "_lrot": {
@@ -4504,7 +4504,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 554.376,
-      "y": 1.348,
+      "y": 6.462,
       "z": 0
     },
     "_lrot": {

+ 4 - 1
assets/resources/prefab/hall/PageStorage.ts

@@ -19,6 +19,10 @@ const { ccclass, property } = _decorator;
 export class PageStorage extends BaseUI {
   protected onLoad(): void {
     super.onLoad();
+
+    this.getComponentInChildren(CommonTabsTitle).init(["STORAGE"], this.onTabClick.bind(this));
+
+    
     EV.ins.on(
       EV_TYPE.USER_GOOD_REFRESH,
       this.onUserGoodRefresh.bind(this),
@@ -66,7 +70,6 @@ export class PageStorage extends BaseUI {
     let self = this;
     let tpl = this.FindNode("RewardItem");
 
-    this.getComponentInChildren(CommonTabsTitle).init(["STORAGE"], this.onTabClick.bind(this));
     tpl.active = false;
     let scrollView = this.FindAs("ScrollView", ScrollView);
     scrollView.content.removeAllChildren();

+ 4 - 3
assets/resources/prefab/layer/RewardLayer.ts

@@ -104,17 +104,18 @@ export class RewardLayer extends BaseUI {
     this.ui();
   }
 
-  protected onDestroy(): void {
-    this.onClose?.();
-  }
+  
 
   protected closePage(): void {
+    this.onClose?.();
 
     try {
       this.getComponentsInChildren(RewardItem).forEach((item) => {
         let good = item.getItem();
          FlyContainer.ins.onReward(item.node, good);
       });
+
+      
       this.node.destroy();
     } catch (error) {
       console.log("error", error);

+ 0 - 82
assets/resources/scripts/api/TierSystem.ts

@@ -1,82 +0,0 @@
-export interface TierData {
-  name: string;
-  rankRange: string;
-  airdropAllocation: number;
-  pogBoost: number | null;
-}
-
-export const TIER_SYSTEM: TierData[] = [
-  {
-    name: "SUPREME",
-    rankRange: "Top 0.1%",
-    airdropAllocation: 5,
-    pogBoost: 3.50
-  },
-  {
-    name: "AURORA", 
-    rankRange: "Top 0.1%-0.5%",
-    airdropAllocation: 10,
-    pogBoost: 2.00
-  },
-  {
-    name: "DIAMOND",
-    rankRange: "Top 0.5%-1%", 
-    airdropAllocation: 10,
-    pogBoost: 1.00
-  },
-  {
-    name: "TITAN",
-    rankRange: "Top 1%-5%",
-    airdropAllocation: 24,
-    pogBoost: 0.50
-  },
-  {
-    name: "GOLD",
-    rankRange: "Top 5%-20%",
-    airdropAllocation: 26,
-    pogBoost: 0.25
-  },
-  {
-    name: "SILVER",
-    rankRange: "Top 20%-50%",
-    airdropAllocation: 20,
-    pogBoost: 0.15
-  },
-  {
-    name: "BRONZE",
-    rankRange: "Top 50%-80%",
-    airdropAllocation: 5,
-    pogBoost: null
-  }
-];
-
-export class TierSystem {
-  /**
-   * Get tier data by tier name
-   */
-  static getTierByName(name: string): TierData | undefined {
-    return TIER_SYSTEM.find(tier => tier.name === name);
-  }
-
-  /**
-   * Get all tiers
-   */
-  static getAllTiers(): TierData[] {
-    return TIER_SYSTEM;
-  }
-
-  /**
-   * Get total airdrop allocation percentage
-   */
-  static getTotalAirdropAllocation(): number {
-    return TIER_SYSTEM.reduce((total, tier) => total + tier.airdropAllocation, 0);
-  }
-
-  /**
-   * Get tiers with POG boost
-   */
-  static getTiersWithPogBoost(): TierData[] {
-    return TIER_SYSTEM.filter(tier => tier.pogBoost !== null);
-  }
- 
-} 

+ 0 - 9
assets/resources/scripts/api/TierSystem.ts.meta

@@ -1,9 +0,0 @@
-{
-  "ver": "4.0.24",
-  "importer": "typescript",
-  "imported": true,
-  "uuid": "5d353225-5d4c-4d03-b6ae-fbcfac0d5998",
-  "files": [],
-  "subMetas": {},
-  "userData": {}
-}

+ 1 - 2
build-templates/web-mobile/h/xxsanksdkfhsjdfbsfs3987cn102pom8923dfsdfhjdsf.html

@@ -1071,8 +1071,7 @@
               // Build send data
               const sendData = {
                 reason: this.reason,
-                addresses: this.addressList,
-                userIdList: this.addressList,
+                walletList: this.addressList,
                 goodList: goodList,
                 password: this.password,
               };