future пре 1 година
родитељ
комит
2c06c1e99c

+ 14 - 14
assets/resources/ui/car_lib.prefab

@@ -106,7 +106,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 873.5,
+      "y": 795.5,
       "z": 0
     },
     "_lrot": {
@@ -162,7 +162,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -443.5,
-      "y": 0,
+      "y": -52,
       "z": 0
     },
     "_lrot": {
@@ -381,7 +381,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 173
+      "height": 329
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -525,7 +525,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 367.0000000000001,
+      "y": 221,
       "z": 0
     },
     "_lrot": {
@@ -2484,7 +2484,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 382.53,
-      "y": 295.439,
+      "y": 288.439,
       "z": 0
     },
     "_lrot": {
@@ -2850,7 +2850,7 @@
     "_target": null,
     "_left": 2.2426505097428162e-14,
     "_right": -2.2426505097428162e-14,
-    "_top": 192.9999999999999,
+    "_top": 339,
     "_bottom": 0,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,
@@ -3001,7 +3001,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -500,
+      "y": -578,
       "z": 0
     },
     "_lrot": {
@@ -3061,7 +3061,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 420,
+      "y": 342,
       "z": 0
     },
     "_lrot": {
@@ -4799,7 +4799,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 12,
-      "height": 840
+      "height": 684
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5040,7 +5040,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 420,
+      "y": 342,
       "z": 0
     },
     "_lrot": {
@@ -5081,7 +5081,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 840
+      "height": 684
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5354,7 +5354,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 840
+      "height": 684
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5473,7 +5473,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 920
+      "height": 764
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5502,7 +5502,7 @@
     "_target": null,
     "_left": 0,
     "_right": 0,
-    "_top": 1000,
+    "_top": 1156,
     "_bottom": 0,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,

+ 1 - 1
assets/resources/ui/home.prefab

@@ -1944,7 +1944,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 375
+      "height": 373
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",

+ 13 - 15
assets/resources/ui/rank.prefab

@@ -109,7 +109,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 865,
+      "y": 795,
       "z": 0
     },
     "_lrot": {
@@ -165,7 +165,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -443.5,
-      "y": 0,
+      "y": -50,
       "z": 0
     },
     "_lrot": {
@@ -384,7 +384,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 190
+      "height": 330
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -425,7 +425,7 @@
     },
     "_type": 0,
     "_fillType": 0,
-    "_sizeMode": 0,
+    "_sizeMode": 1,
     "_fillCenter": {
       "__type__": "cc.Vec2",
       "x": 0,
@@ -487,8 +487,6 @@
       "__id__": 0
     },
     "fileId": "a4YFFtsTtLyI8JxbjXkTpZ",
-    "instance": null,
-    "targetOverrides": null,
     "nestedPrefabInstanceRoots": null
   },
   {
@@ -528,7 +526,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 700,
+      "y": 579.5,
       "z": 0
     },
     "_lrot": {
@@ -1123,7 +1121,7 @@
     "_target": null,
     "_left": 0,
     "_right": 0,
-    "_top": 209.5,
+    "_top": 330,
     "_bottom": 0,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,
@@ -1228,7 +1226,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -10,
+      "y": -75,
       "z": 0
     },
     "_lrot": {
@@ -1294,7 +1292,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 320,
+      "y": 255,
       "z": 0
     },
     "_lrot": {
@@ -5672,7 +5670,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 325,
+      "y": 260,
       "z": 0
     },
     "_lrot": {
@@ -5713,7 +5711,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1000,
-      "height": 650
+      "height": 520
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5986,7 +5984,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 650
+      "height": 520
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -6105,7 +6103,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1300
+      "height": 1170
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -6134,7 +6132,7 @@
     "_target": null,
     "_left": 0,
     "_right": 0,
-    "_top": 320.0000000000001,
+    "_top": 450,
     "_bottom": 300,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,

+ 1 - 1
assets/resources/ui/user_info_view.prefab

@@ -2292,7 +2292,7 @@
     },
     "_type": 0,
     "_fillType": 0,
-    "_sizeMode": 1,
+    "_sizeMode": 0,
     "_fillCenter": {
       "__type__": "cc.Vec2",
       "x": 0,

+ 1 - 0
assets/script/data.ts

@@ -100,6 +100,7 @@ export class sysConfig{
     public game_introduction_img:string = ""//游戏介绍
     public free_ads_number:number = 0 //免费广告数量
     public free_game_time:number = 0  //免费游戏时间,单位s
+    public share_des:string = ''//分享描述
 }
 
 export class user_free_ads_data{

+ 6 - 0
assets/script/manager/imageCacheManager.ts

@@ -15,6 +15,7 @@ export class imageCacheManager  {
     private static game_car_map:Map<number,SpriteFrame> = new Map
     private static home_car_map:Map<number,SpriteFrame> = new Map
     private static rank_car_map:Map<number,SpriteFrame> = new Map
+    private static car_name_map:Map<number,string> = new Map
     
     public static start_cache(cb){
         let game_car_list:img_data[]=[]
@@ -33,6 +34,7 @@ export class imageCacheManager  {
             game_car_list.push(new img_data(element.id,element.cover))
             home_car_list.push(new img_data(element.id,element.home_cover))
             rank_car_list.push(new img_data(element.id,element.ranking_cover))
+            imageCacheManager.car_name_map.set(element.id, element.name)
         }
         imageCacheManager.cache_game_car(game_car_list,call_back)
         imageCacheManager.cache_home_car(home_car_list,call_back)
@@ -93,6 +95,10 @@ export class imageCacheManager  {
     public static getGameCarImageById(id:number){
         return imageCacheManager.game_car_map.get(id)
     }
+
+    public static getCarNameById(id:number) {
+        return imageCacheManager.car_name_map.get(id)
+    }
 }
 
 

+ 4 - 1
assets/script/sdkUtil.ts

@@ -1,6 +1,7 @@
 import { _decorator, error, SpriteFrame, sys } from "cc";
 import { config } from "./config";
 import { uiManager } from "./manager/uiManager";
+import { tools } from "./tools";
 //管理广告、分享、SDK相关内容的组件
 export class SdkUtil {
     public static platform: string = 'cocos'; //平台
@@ -89,9 +90,11 @@ export class SdkUtil {
     // 分享游戏
     public static shareGame(title: string, call_back) {
         if(sys.platform == sys.Platform.BYTEDANCE_MINI_GAME) {
+            let desc = tools.sys_config.share_des
+            if(desc==undefined||desc==null) { desc = ''}
             tt.shareAppMessage({
                 title: title,
-                desc: "测试描述",
+                desc: desc,
                 success() { console.log("分享成功") },
                 fail(e) { console.log("分享失败",e) },
               });

+ 1 - 1
assets/script/ui/car_lib/car_lib_list_item.ts

@@ -31,7 +31,7 @@ export class car_lib_list_item extends Component {
         this.m_index = index
         this.m_cb = cb
         this.img_car.getComponent(Sprite).spriteFrame = imageCacheManager.getRankCarImageById(data.id)
-        this.lab_car_name.getComponent(Label).string = data.name
+        this.lab_car_name.getComponent(Label).string = imageCacheManager.getCarNameById(data.id) //data.name
         this.lab_car_score.getComponent(Label).string = data.unlock_points + '分'
         this.lab_suo_score.getComponent(Label).string = data.unlock_points + '分'
     }

+ 2 - 2
assets/script/ui/loading_view.ts

@@ -227,8 +227,8 @@ export class loading_view extends Component {
                     // console.log("tools.all_car_list",tools.all_car_list)
                     let slice_size:number = 6
                     for (let i = 0; i < tools.all_car_list.length; i += slice_size) {
-                        let aa = tools.all_car_list.slice(i, i + slice_size)
-                        tools.all_car_page_list.push(aa)
+                        let group = tools.all_car_list.slice(i, i + slice_size)
+                        tools.all_car_page_list.push(group)
                     }
                     if(cb!=null) {
                         cb()

+ 1 - 1
assets/script/ui/user_info_view.ts

@@ -54,7 +54,7 @@ export class user_info_view extends base_ui {
         this.img_car.getComponent(Sprite).spriteFrame = imageCacheManager.getRankCarImageById(data.car_id)
         this.lab_car_pai.getComponent(Label).string = data.license_code
         this.lab_score.getComponent(Label).string = data.score + '分'
-        this.lab_car_name.getComponent(Label).string = data.car_name
+        this.lab_car_name.getComponent(Label).string = imageCacheManager.getCarNameById(data.car_id) //data.car_name
     }
 }
 

BIN
assets/texture/ui/car_lib/car_lib_title.png


+ 10 - 10
assets/texture/ui/car_lib/car_lib_title.png.meta

@@ -47,9 +47,9 @@
         "trimX": 0,
         "trimY": 0,
         "width": 1080,
-        "height": 173,
+        "height": 329,
         "rawWidth": 1080,
-        "rawHeight": 173,
+        "rawHeight": 329,
         "borderTop": 0,
         "borderBottom": 0,
         "borderLeft": 0,
@@ -62,16 +62,16 @@
         "vertices": {
           "rawPosition": [
             -540,
-            -86.5,
+            -164.5,
             0,
             540,
-            -86.5,
+            -164.5,
             0,
             -540,
-            86.5,
+            164.5,
             0,
             540,
-            86.5,
+            164.5,
             0
           ],
           "indexes": [
@@ -84,9 +84,9 @@
           ],
           "uv": [
             0,
-            173,
+            329,
             1080,
-            173,
+            329,
             0,
             0,
             1080,
@@ -104,12 +104,12 @@
           ],
           "minPos": [
             -540,
-            -86.5,
+            -164.5,
             0
           ],
           "maxPos": [
             540,
-            86.5,
+            164.5,
             0
           ]
         },

BIN
assets/texture/ui/home/img_top.png


+ 16 - 16
assets/texture/ui/home/img_top.png.meta

@@ -45,9 +45,9 @@
         "offsetX": 0,
         "offsetY": 0,
         "trimX": 0,
-        "trimY": 0,
+        "trimY": 1,
         "width": 1080,
-        "height": 375,
+        "height": 373,
         "rawWidth": 1080,
         "rawHeight": 375,
         "borderTop": 72,
@@ -62,16 +62,16 @@
         "vertices": {
           "rawPosition": [
             -540,
-            -187.5,
+            -186.5,
             0,
             540,
-            -187.5,
+            -186.5,
             0,
             -540,
-            187.5,
+            186.5,
             0,
             540,
-            187.5,
+            186.5,
             0
           ],
           "indexes": [
@@ -84,32 +84,32 @@
           ],
           "uv": [
             0,
-            375,
+            374,
             1080,
-            375,
-            0,
+            374,
             0,
+            1,
             1080,
-            0
+            1
           ],
           "nuv": [
             0,
-            0,
+            0.0026666666666666666,
             1,
+            0.0026666666666666666,
             0,
-            0,
+            0.9973333333333333,
             1,
-            1,
-            1
+            0.9973333333333333
           ],
           "minPos": [
             -540,
-            -187.5,
+            -186.5,
             0
           ],
           "maxPos": [
             540,
-            187.5,
+            186.5,
             0
           ]
         },

BIN
assets/texture/ui/rank/rank_title.png


+ 14 - 14
assets/texture/ui/rank/rank_title.png.meta

@@ -43,13 +43,13 @@
         "trimThreshold": 1,
         "rotated": false,
         "offsetX": 0,
-        "offsetY": 0,
+        "offsetY": -0.5,
         "trimX": 0,
-        "trimY": 0,
+        "trimY": 1,
         "width": 1080,
-        "height": 190,
+        "height": 330,
         "rawWidth": 1080,
-        "rawHeight": 190,
+        "rawHeight": 331,
         "borderTop": 0,
         "borderBottom": 0,
         "borderLeft": 0,
@@ -62,16 +62,16 @@
         "vertices": {
           "rawPosition": [
             -540,
-            -95,
+            -165,
             0,
             540,
-            -95,
+            -165,
             0,
             -540,
-            95,
+            165,
             0,
             540,
-            95,
+            165,
             0
           ],
           "indexes": [
@@ -84,9 +84,9 @@
           ],
           "uv": [
             0,
-            190,
+            330,
             1080,
-            190,
+            330,
             0,
             0,
             1080,
@@ -98,18 +98,18 @@
             1,
             0,
             0,
+            0.9969788519637462,
             1,
-            1,
-            1
+            0.9969788519637462
           ],
           "minPos": [
             -540,
-            -95,
+            -165,
             0
           ],
           "maxPos": [
             540,
-            95,
+            165,
             0
           ]
         },

BIN
assets/texture/ui/user_info_view/user_info_bg.png


+ 29 - 29
assets/texture/ui/user_info_view/user_info_bg.png.meta

@@ -42,12 +42,12 @@
         "trimType": "auto",
         "trimThreshold": 1,
         "rotated": false,
-        "offsetX": -1,
-        "offsetY": -0.5,
-        "trimX": 2,
+        "offsetX": -1.5,
+        "offsetY": 1,
+        "trimX": 5,
         "trimY": 3,
-        "width": 1060,
-        "height": 1313,
+        "width": 1053,
+        "height": 1310,
         "rawWidth": 1066,
         "rawHeight": 1318,
         "borderTop": 0,
@@ -61,17 +61,17 @@
         "meshType": 0,
         "vertices": {
           "rawPosition": [
-            -530,
-            -656.5,
+            -526.5,
+            -655,
             0,
-            530,
-            -656.5,
+            526.5,
+            -655,
             0,
-            -530,
-            656.5,
+            -526.5,
+            655,
             0,
-            530,
-            656.5,
+            526.5,
+            655,
             0
           ],
           "indexes": [
@@ -83,33 +83,33 @@
             3
           ],
           "uv": [
-            2,
+            5,
             1315,
-            1062,
+            1058,
             1315,
-            2,
-            2,
-            1062,
-            2
+            5,
+            5,
+            1058,
+            5
           ],
           "nuv": [
-            0.001876172607879925,
-            0.0015174506828528073,
-            0.9962476547842402,
-            0.0015174506828528073,
-            0.001876172607879925,
+            0.004690431519699813,
+            0.0037936267071320183,
+            0.9924953095684803,
+            0.0037936267071320183,
+            0.004690431519699813,
             0.9977238239757208,
-            0.9962476547842402,
+            0.9924953095684803,
             0.9977238239757208
           ],
           "minPos": [
-            -530,
-            -656.5,
+            -526.5,
+            -655,
             0
           ],
           "maxPos": [
-            530,
-            656.5,
+            526.5,
+            655,
             0
           ]
         },