using Godot; public partial class Enemy : Node { public void OnHit(Variant body) { if (body.Obj is Projectile) { GD.Print("Hit"); QueueFree(); } } }