From c50cac4bed1e4240801676683a37ecf4f4253b3a Mon Sep 17 00:00:00 2001 From: "YZ\\249929363" <249929363@qq.com> Date: Fri, 25 Jul 2025 18:03:03 +0800 Subject: [PATCH] =?UTF-8?q?1.5=E7=89=88=E6=9C=AC=E6=9C=88=E5=8D=A1?= =?UTF-8?q?=E7=89=88=E6=9C=AC=E6=94=B6=E5=B0=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- assets/Script/Block.ts | 3 ++- assets/Script/Map.ts | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/assets/Script/Block.ts b/assets/Script/Block.ts index 90dc71b..55617ed 100644 --- a/assets/Script/Block.ts +++ b/assets/Script/Block.ts @@ -604,7 +604,8 @@ export default class Block extends cc.Component { this.node.active = false; this.node.removeFromParent(); setTimeout(() => { - if (type == true && MapConroler._instance.openWall.length > 0) { + if (type == true && MapConroler._instance.openWall.length > 0 + && !MapConroler._instance.gameOver && MapConroler._instance.gameWin) { let gameover = MapConroler._instance.predict_End(); if (gameover == false) { MapConroler._instance.failLevel("lock"); diff --git a/assets/Script/Map.ts b/assets/Script/Map.ts index 93d4c6c..f742d67 100644 --- a/assets/Script/Map.ts +++ b/assets/Script/Map.ts @@ -2839,6 +2839,9 @@ export default class MapConroler extends cc.Component { predict_End() { //return true; console.log("提前判断游戏结束"); + if (this.gameOver || this.gameWin) { + return true; + } let result = false; for (let i = 0; i < this.blocks.length; i++) { //确保方块是可移动状态下再做判断