From 1282aa6118520cad177dae94be730f5d0d780d2a Mon Sep 17 00:00:00 2001 From: seozzi Date: Mon, 16 Dec 2024 15:32:08 +0900 Subject: [PATCH] =?UTF-8?q?=EC=9D=B4=EC=83=81=ED=98=84=EC=83=81=2022=20?= =?UTF-8?q?=ED=83=80=EC=9D=BC=20=ED=95=9C=20=EB=B2=88=EC=97=90=20=EB=96=A8?= =?UTF-8?q?=EC=96=B4=EC=A7=80=EB=8A=94=20=EC=97=90=EB=9F=AC=20=ED=95=B4?= =?UTF-8?q?=EA=B2=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Anomaly26/fire/Fire.unitypackage.meta | 7 ------- .../Anomaly26/fireEx/fireEx.unitypackage.meta | 7 ------- .../SpecificAnomalyManager/Anomaly22Manager.cs | 16 +++++----------- 3 files changed, 5 insertions(+), 25 deletions(-) delete mode 100644 302/Assets/Course Library/Anomalies/Anomaly26/fire/Fire.unitypackage.meta delete mode 100644 302/Assets/Course Library/Anomalies/Anomaly26/fireEx/fireEx.unitypackage.meta diff --git a/302/Assets/Course Library/Anomalies/Anomaly26/fire/Fire.unitypackage.meta b/302/Assets/Course Library/Anomalies/Anomaly26/fire/Fire.unitypackage.meta deleted file mode 100644 index a819dbb..0000000 --- a/302/Assets/Course Library/Anomalies/Anomaly26/fire/Fire.unitypackage.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: 9e44e6e8c6b4444818d678344091a86d -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/302/Assets/Course Library/Anomalies/Anomaly26/fireEx/fireEx.unitypackage.meta b/302/Assets/Course Library/Anomalies/Anomaly26/fireEx/fireEx.unitypackage.meta deleted file mode 100644 index ac7fa65..0000000 --- a/302/Assets/Course Library/Anomalies/Anomaly26/fireEx/fireEx.unitypackage.meta +++ /dev/null @@ -1,7 +0,0 @@ -fileFormatVersion: 2 -guid: 905a3c281cc5d471d99e87d04d99c4c0 -DefaultImporter: - externalObjects: {} - userData: - assetBundleName: - assetBundleVariant: diff --git a/302/Assets/Scripts/SpecificAnomalyManager/Anomaly22Manager.cs b/302/Assets/Scripts/SpecificAnomalyManager/Anomaly22Manager.cs index e61e066..32339b5 100644 --- a/302/Assets/Scripts/SpecificAnomalyManager/Anomaly22Manager.cs +++ b/302/Assets/Scripts/SpecificAnomalyManager/Anomaly22Manager.cs @@ -7,7 +7,6 @@ public class Anomaly22Manager : MonoBehaviour private GameObject floor; // 모든 타일들의 Parent private GameManager gameManager; private PlayerController playerController; - public float interval = 1f; public float totalSeconds = 30f; private bool isPlayerDead = false; @@ -66,15 +65,8 @@ private IEnumerator TriggerPlatformFall() { if (platformTile != null) { - Anomaly22_tile tileScript = platformTile.GetComponent(); - if (tileScript == null) - { - - tileScript = platformTile.gameObject.AddComponent(); - tileScript.shakeSound = shakeSound; - } else { - - } + Anomaly22_tile tileScript = platformTile.gameObject.AddComponent(); + tileScript.shakeSound = shakeSound; tileScript.TriggerShakeAndFall(); yield return new WaitForSeconds(2f); @@ -145,6 +137,8 @@ private IEnumerator TriggerRandomTileShakeAndFallWithInterval() Transform selectedTile = floorTiles[randomIndex]; Anomaly22_tile tileScript = selectedTile.GetComponent(); + + // 이미 tileScript이 안 붙어 있는 타일만 새로 fall trigger 가능 if (tileScript == null) { tileScript = selectedTile.gameObject.AddComponent(); @@ -153,7 +147,7 @@ private IEnumerator TriggerRandomTileShakeAndFallWithInterval() tileScript.TriggerShakeAndFall(); } - yield return new WaitForSeconds(interval); + yield return new WaitForSeconds(0.5f); } if (!isPlayerDead) // totalSeconds가 다 지날 때까지 생존 시