future il y a 9 mois
Parent
commit
ba0da866eb

+ 42 - 42
assets/scene/game.scene

@@ -178,7 +178,7 @@
     "_priority": 0,
     "_fov": 45,
     "_fovAxis": 0,
-    "_orthoHeight": 959.9999999999999,
+    "_orthoHeight": 960,
     "_near": 0,
     "_far": 1000,
     "_color": {
@@ -347,7 +347,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -651,7 +651,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -1173,7 +1173,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -2022,7 +2022,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -4217,7 +4217,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -4278,7 +4278,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -540,
-      "y": -959.9999999999999,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -4317,7 +4317,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5156,7 +5156,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 819.9999999999999,
+      "y": 820,
       "z": 0
     },
     "_lrot": {
@@ -5538,7 +5538,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -421,
-      "y": 779.9999999999999,
+      "y": 780,
       "z": 0
     },
     "_lrot": {
@@ -9129,7 +9129,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -9714,7 +9714,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -540,
-      "y": -959.9999999999999,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -9753,7 +9753,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -15302,7 +15302,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -15422,7 +15422,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 959.9999999999999,
+      "y": 960,
       "z": 0
     },
     "_lrot": {
@@ -15473,7 +15473,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -959.9999999999999,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -15512,7 +15512,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -15724,7 +15724,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1010,
-      "height": 1395
+      "height": 1395.0000000000002
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -15859,7 +15859,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 261.451,
-      "y": -745.8539999999999,
+      "y": -745.854,
       "z": 0
     },
     "_lrot": {
@@ -16217,7 +16217,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 12,
-      "height": 1359.9999999999998
+      "height": 1360
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -16368,7 +16368,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 697.5000000000001,
+      "y": 697.5,
       "z": 0
     },
     "_lrot": {
@@ -16465,7 +16465,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 960,
-      "height": 1359.9999999999998
+      "height": 1360
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -16596,7 +16596,7 @@
     "_target": null,
     "_left": 0,
     "_right": 0,
-    "_top": -17.500000000000227,
+    "_top": -17.500000000000057,
     "_bottom": 1377.5,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,
@@ -16657,7 +16657,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 960,
-      "height": 1359.9999999999998
+      "height": 1360
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -16767,7 +16767,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -160.60104824676273,
-      "y": 788.9999999999999,
+      "y": 789,
       "z": 0
     },
     "_lrot": {
@@ -17089,7 +17089,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 126,
-      "y": 787.9999999999999,
+      "y": 788,
       "z": 0
     },
     "_lrot": {
@@ -17392,7 +17392,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1234,
-      "height": 1819.9999999999998
+      "height": 1820
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -17706,7 +17706,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": -959.9999999999999,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -17796,7 +17796,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -17902,7 +17902,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -421,
-      "y": 839.9999999999999,
+      "y": 840,
       "z": 0
     },
     "_lrot": {
@@ -18461,7 +18461,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 804.9999999999999,
+      "y": 805,
       "z": 0
     },
     "_lrot": {
@@ -18558,7 +18558,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1020,
-      "height": 1609.9999999999998
+      "height": 1610
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -18690,7 +18690,7 @@
     "_left": 0,
     "_right": 0,
     "_top": 0,
-    "_bottom": 1609.9999999999998,
+    "_bottom": 1610,
     "_horizontalCenter": 0,
     "_verticalCenter": 0,
     "_isAbsLeft": true,
@@ -18750,7 +18750,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1020,
-      "height": 1609.9999999999998
+      "height": 1610
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -18859,7 +18859,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -451.5,
-      "y": -723.4999999999999,
+      "y": -723.5,
       "z": 0
     },
     "_lrot": {
@@ -19062,7 +19062,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -19154,7 +19154,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -28946,7 +28946,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -29039,7 +29039,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -29208,7 +29208,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -29260,7 +29260,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -29384,7 +29384,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1919.9999999999998
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",

+ 2 - 2
assets/script/run/game_list_view/long_story_list.ts

@@ -1,4 +1,4 @@
-import { _decorator, Animation, Component, instantiate, Node, Prefab, ScrollView } from 'cc';
+import { _decorator, Animation, Component, instantiate, Node, Prefab, ScrollView, Size, Sprite, UITransform, Widget } from 'cc';
 import { LevelInfoMessage, LevelItemData, LevelMessage, LongStoryListData, scene_item_data } from '../../../data/data';
 import { config } from '../../config';
 import { SdkUtil } from '../../sdkUtil';
@@ -42,7 +42,7 @@ export class long_story_list extends Component {
         this.btn_back_level.on(Node.EventType.TOUCH_END,()=>{
             this.m_click_back_level_cb && this.m_click_back_level_cb()
         })
-
+        
         this.scrollView.on(ScrollView.EventType.SCROLL_TO_TOP, this.onScrollToTop, this)
         this.scrollView.on(ScrollView.EventType.SCROLL_TO_BOTTOM, this.onScrollToBottom, this)
     }

+ 6 - 5
assets/script/run/game_list_view/long_story_list_item.ts

@@ -1,4 +1,4 @@
-import { _decorator, Color, Component, Label, Node, Size, Sprite, UITransform } from 'cc';
+import { _decorator, Color, Component, Label, Node, Size, Sprite, UITransform, view, Widget } from 'cc';
 import { level_list_data, LevelItemData, LevelMessage } from '../../../data/data';
 import { tools } from '../../tools';
 import { gameManager } from '../gameManager';
@@ -68,10 +68,11 @@ export class long_story_list_item extends Component {
         // console.log('data_list=',data_list)
         this.lab_title.getComponent(Label).string = `第${this.m_page}章节`
 
-        let node_content_size = this.node.getComponent(UITransform).contentSize
-        if(data_list.length<3) {
-            this.node.getComponent(UITransform).setContentSize(new Size(node_content_size.width,1700))
-        }
+        // if(data_list.length<3) {
+        //     let node_content_size = this.node.getComponent(UITransform).contentSize
+        //     let parent_parent_height = this.node.parent.parent.getComponent(UITransform).height
+        //     this.node.getComponent(UITransform).setContentSize(new Size(node_content_size.width,parent_parent_height+10))
+        // }
 
         this.level_bg_1.active = false
         this.level_bg_2.active = false