Turret tile basis

This commit is contained in:
2025-08-30 12:03:26 +08:00
parent 32f96d488d
commit 1c6c03cd41
12 changed files with 155 additions and 4 deletions

View File

@@ -4,6 +4,8 @@ namespace AceFieldNewHorizon.Scripts.Entities;
public partial class Enemy : CharacterBody2D
{
public const string EnemyGroupName = "Enemy";
[Export] public float MoveSpeed = 150.0f;
[Export] public float DetectionRadius = 300.0f;
[Export] public float AttackRange = 50.0f;
@@ -29,6 +31,8 @@ public partial class Enemy : CharacterBody2D
// Connect signals
_detectionArea.BodyEntered += OnBodyEnteredDetection;
_detectionArea.BodyExited += OnBodyExitedDetection;
AddToGroup(EnemyGroupName);
}
public override void _Process(double delta)