future 1 vuosi sitten
vanhempi
sitoutus
d77844504d

+ 1 - 0
assets/data/data.ts

@@ -347,6 +347,7 @@ export class level_list_item_data {
 export class task_data{  //玩法===任务
     public type:number = config.task_type.da_guai;
     public event_list:event_item[] = [];
+    public is_open_interlude_default_animation:boolean = true; //打开过场默认动画
     public _zhao_xi_jie_data:zhao_xi_jie_data = null;
     public _guo_ju_qing:guo_ju_qing_data = null;
     public _da_guai:da_guai_data = null;

+ 20 - 20
assets/scene/game.scene

@@ -93,7 +93,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 540,
-      "y": 960.0000000000002,
+      "y": 960,
       "z": 0
     },
     "_lrot": {
@@ -178,7 +178,7 @@
     "_priority": 0,
     "_fov": 45,
     "_fovAxis": 0,
-    "_orthoHeight": 960.0000000000001,
+    "_orthoHeight": 960,
     "_near": 0,
     "_far": 1000,
     "_color": {
@@ -347,7 +347,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -651,7 +651,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -1167,7 +1167,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -2016,7 +2016,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -4193,7 +4193,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -4254,7 +4254,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -540,
-      "y": -960.0000000000001,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -4293,7 +4293,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -5132,7 +5132,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": 0,
-      "y": 860.0000000000001,
+      "y": 860,
       "z": 0
     },
     "_lrot": {
@@ -5514,7 +5514,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -421,
-      "y": 818.0000000000001,
+      "y": 818,
       "z": 0
     },
     "_lrot": {
@@ -9103,7 +9103,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -9309,7 +9309,7 @@
     "_lpos": {
       "__type__": "cc.Vec3",
       "x": -540,
-      "y": -960.0000000000001,
+      "y": -960,
       "z": 0
     },
     "_lrot": {
@@ -9348,7 +9348,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -14882,7 +14882,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -24319,7 +24319,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -24412,7 +24412,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -24581,7 +24581,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -24633,7 +24633,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",
@@ -24754,7 +24754,7 @@
     "_contentSize": {
       "__type__": "cc.Size",
       "width": 1080,
-      "height": 1920.0000000000002
+      "height": 1920
     },
     "_anchorPoint": {
       "__type__": "cc.Vec2",

+ 33 - 9
assets/script/run/gameManager.ts

@@ -315,19 +315,43 @@ export class gameManager extends Component {
     }
 
     public nextScene(){
-        this.onLaunch(()=>{
-            this.mCurSceneIndex++;
-            let not_scene = false;
-            if(this.mCurSceneIndex>=this.mGameData.length){
-                not_scene = true;
+        this.mCurSceneIndex++;
+        let not_scene = false;
+        if(this.mCurSceneIndex>=this.mGameData.length){
+            not_scene = true;
+        }
+        if(!not_scene){
+            let task_data = this.mGameData[this.mCurSceneIndex]._task_data
+            if(task_data==null||task_data==undefined) {
+                return tools.showToast('没有任务')
             }
-            if(!not_scene){
+            let call_back =(()=>{
                 this.mGameRun.unInit()
                 this.startLevelGame()
-            }else{
-                // tools.showToast("没有场景了!")
+            })            
+            if(task_data.is_open_interlude_default_animation) {
+                this.onLaunch(()=>{
+                    call_back()
+                })
+            } else {
+                call_back()
             }
-        })
+        }else{
+            // tools.showToast("没有场景了!")
+        }
+        // this.onLaunch(()=>{
+        //     this.mCurSceneIndex++;
+        //     let not_scene = false;
+        //     if(this.mCurSceneIndex>=this.mGameData.length){
+        //         not_scene = true;
+        //     }
+        //     if(!not_scene){
+        //         this.mGameRun.unInit()
+        //         this.startLevelGame()
+        //     }else{
+        //         // tools.showToast("没有场景了!")
+        //     }
+        // })
     }
     public gameOver(){
         ClientEvent.dispatchEvent(config.EventRun.ON_WIN)

+ 3 - 1
assets/script/run/ui/count_down.ts

@@ -81,7 +81,9 @@ export class count_down extends Component {
         },1)
     }
 
-
+    public stopCountDown() {
+        this.unscheduleAllCallbacks()
+    }
 
 }
 

+ 9 - 2
assets/script/run/ui_layer.ts

@@ -154,8 +154,8 @@ export class ui_layer extends Component {
         }else if(event.type===config.event_type.stop_active_event){
             let time_count = this.mCountDownLlist.get(widgetId)
             if(time_count!=null){
-                if(this.mAttCountDown==null){
-                    this.createCountDown(time_count)   
+                if(this.mAttCountDown!=null){
+                    this.stopCountDown()
                 }
             }
         }else if(event.type===config.event_type.hide){
@@ -221,6 +221,13 @@ export class ui_layer extends Component {
         ClientEvent.off(config.EventRun.ON_WIDGET_FINISH_COLLECT_EVENT,this.onCountDownListening.bind(this),this)
     }
 
+    stopCountDown() {
+        this.mAttCountDown.stopCountDown()
+        this.mAttCountDown.node.removeFromParent()
+        this.mAttCountDown = null;
+        ClientEvent.off(config.EventRun.ON_WIDGET_FINISH_COLLECT_EVENT,this.onCountDownListening.bind(this),this)
+    }
+
     initTaskUi(data:task_data){
         this.ui_manifestations.active = false;
         this.content_rule_and_tips.active = false;