diff --git a/linter.yml b/.github/workflows/linter.yml similarity index 100% rename from linter.yml rename to .github/workflows/linter.yml diff --git a/Assets/Scripts/Enemy/EnemySpawner.cs b/Assets/Scripts/Enemy/EnemySpawner.cs index 4116534..fbf0265 100644 --- a/Assets/Scripts/Enemy/EnemySpawner.cs +++ b/Assets/Scripts/Enemy/EnemySpawner.cs @@ -29,20 +29,19 @@ public class EnemySpawner : MonoBehaviour private HashSet blockedCells = new(); IEnumerator Start() -{ - if (maze == null || enemyPrefab == null || player == null) { - Debug.LogError("EnemySpawner not configured correctly"); - yield break; - } - - // WAIT until maze is fully generated - while (!maze.IsReady) - yield return null; + if (maze == null || enemyPrefab == null || player == null) + { + Debug.LogError("EnemySpawner not configured correctly"); + yield break; + } - SpawnEnemies(); -} + // WAIT until maze is fully generated + while (!maze.IsReady) + yield return null; + SpawnEnemies(); + } void SpawnEnemies() { diff --git a/Assets/Scripts/MazeGenerator3D.cs b/Assets/Scripts/MazeGenerator3D.cs index 849c9ea..a3f441b 100644 --- a/Assets/Scripts/MazeGenerator3D.cs +++ b/Assets/Scripts/MazeGenerator3D.cs @@ -164,16 +164,14 @@ public Vector3 GetRandomPathWorldPosition(float y = 1f) Vector2Int cell = pathCells[Random.Range(0, pathCells.Count)]; return new Vector3(cell.x * cellSize, y, cell.y * cellSize); } - public bool IsWall(Vector2Int cell) -{ - if (grid == null) - return true; - - if (cell.x < 0 || cell.y < 0 || cell.x >= width || cell.y >= height) - return true; - - return grid[cell.x, cell.y]; -} + public bool IsWall(Vector2Int cell) + { + if (grid == null) + return true; -} + if (cell.x < 0 || cell.y < 0 || cell.x >= width || cell.y >= height) + return true; + return grid[cell.x, cell.y]; + } +} \ No newline at end of file diff --git a/Assets/Scripts/Player/Bullet.cs b/Assets/Scripts/Player/Bullet.cs index 374a721..37bfb9e 100644 --- a/Assets/Scripts/Player/Bullet.cs +++ b/Assets/Scripts/Player/Bullet.cs @@ -4,7 +4,7 @@ public class Bullet : MonoBehaviour { private void OnCollisionEnter(Collision collision) { - if(collision.collider.TryGetComponent(out var enemy)) + if (collision.collider.TryGetComponent(out var enemy)) { enemy.TakeDamage(10); // Assuming a fixed damage value; adjust as needed }