From d9dab6e5886058ce6c74c93e838a0c4de7b7b0bc Mon Sep 17 00:00:00 2001 From: almeizaarvin <13519066@std.stei.itb.ac.id> Date: Sun, 10 Apr 2022 02:56:17 +0700 Subject: [PATCH] Modify wave weight --- Assets/Scripts/Enemy/EnemyMovement.cs | 2 +- Assets/Scripts/Managers/EnemyManager.cs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Assets/Scripts/Enemy/EnemyMovement.cs b/Assets/Scripts/Enemy/EnemyMovement.cs index 2276456..951326a 100644 --- a/Assets/Scripts/Enemy/EnemyMovement.cs +++ b/Assets/Scripts/Enemy/EnemyMovement.cs @@ -21,7 +21,7 @@ public class EnemyMovement : MonoBehaviour { if (enemyHealth == null) { - Debug.Log("EnemyHealt is null"); + Debug.Log("EnemyHealth is null"); } if (playerHealth == null) { diff --git a/Assets/Scripts/Managers/EnemyManager.cs b/Assets/Scripts/Managers/EnemyManager.cs index 4bd396d..6cc4f8c 100644 --- a/Assets/Scripts/Managers/EnemyManager.cs +++ b/Assets/Scripts/Managers/EnemyManager.cs @@ -11,6 +11,7 @@ public class EnemyManager : MonoBehaviour public static int waveLevel; public static int finalLevel = 6; public bool isZenMode = true; + public int weightPerLevel = 10; [SerializeField] MonoBehaviour factory; @@ -65,8 +66,7 @@ public class EnemyManager : MonoBehaviour void SpawnWave() { - - totalWeight = 3 * waveLevel; + totalWeight = weightPerLevel * waveLevel; remainingWeight = totalWeight; while (totalWeight > 0) -- GitLab