This commit is contained in:
Marco 2025-02-05 11:33:59 +01:00
commit d60878c94b
10 changed files with 180 additions and 4 deletions

19
Scripts/Actors/Turret.cs Normal file
View file

@ -0,0 +1,19 @@
using Godot;
namespace Cirno.Scripts.Actors;
public partial class Turret : Enemy
{
private AnimatedSprite2D _sprite;
public override void _Ready()
{
base._Ready();
_sprite = GetNode<AnimatedSprite2D>("AnimatedSprite2D");
_sprite.Play("default");
_sprite.SpeedScale = 0;
}
}

View file

@ -113,7 +113,6 @@ public partial class CameraPlayerDetection : PlayerDetection
Node colliderNode = result["collider"].As<Node>();
if (colliderNode is InteractionController interactionController && interactionController == _cachedPlayer)
{
GD.Print("Player detected!");
detected = true;
// Handle detection logic here
}