future 1 gadu atpakaļ
vecāks
revīzija
d35c005108

+ 4 - 4
assets/resources/prefab/edit_event.prefab

@@ -22397,7 +22397,7 @@
     "_hoverSprite": null,
     "_pressedSprite": null,
     "_disabledSprite": null,
-    "_duration": 0.1,
+    "_duration": 0,
     "_zoomScale": 1.2,
     "_target": {
       "__id__": 947
@@ -22881,7 +22881,7 @@
     "_hoverSprite": null,
     "_pressedSprite": null,
     "_disabledSprite": null,
-    "_duration": 0.1,
+    "_duration": 0,
     "_zoomScale": 1.2,
     "_target": {
       "__id__": 967
@@ -23365,7 +23365,7 @@
     "_hoverSprite": null,
     "_pressedSprite": null,
     "_disabledSprite": null,
-    "_duration": 0.1,
+    "_duration": 0,
     "_zoomScale": 1.2,
     "_target": {
       "__id__": 987
@@ -23849,7 +23849,7 @@
     "_hoverSprite": null,
     "_pressedSprite": null,
     "_disabledSprite": null,
-    "_duration": 0.1,
+    "_duration": 0,
     "_zoomScale": 1.2,
     "_target": {
       "__id__": 1007

+ 18 - 16
assets/script/edit/event/event_switch_scene_event.ts

@@ -104,22 +104,24 @@ export class event_switch_scene_event extends Component {
 
     updateDirectionNodeStatus() {
         this.noCheckedAll()
-        switch (this.m_data.direction) {
-            case config.switch_scene_page_direction.up:
-                this.up_node.getComponent(Toggle).isChecked = true
-                break;
-            case config.switch_scene_page_direction.down:
-                this.down_node.getComponent(Toggle).isChecked = true
-                break;
-            case config.switch_scene_page_direction.left:
-                this.left_node.getComponent(Toggle).isChecked = true
-                break;
-            case config.switch_scene_page_direction.right:
-                this.right_node.getComponent(Toggle).isChecked = true
-                break;
-            default:
-                break;
-        }
+        this.scheduleOnce(()=> {
+            switch (this.m_data.direction) {
+                case config.switch_scene_page_direction.up:
+                    this.up_node.getComponent(Toggle).isChecked = true
+                    break;
+                case config.switch_scene_page_direction.down:
+                    this.down_node.getComponent(Toggle).isChecked = true
+                    break;
+                case config.switch_scene_page_direction.left:
+                    this.left_node.getComponent(Toggle).isChecked = true
+                    break;
+                case config.switch_scene_page_direction.right:
+                    this.right_node.getComponent(Toggle).isChecked = true
+                    break;
+                default:
+                    break;
+            }
+        },0.1)
     }
 
     updateLabStatus() {