mirror of
https://gitlab.com/MaddoScientisto/cirnogodot.git
synced 2026-06-01 11:15:33 +00:00
22 lines
No EOL
544 B
C#
22 lines
No EOL
544 B
C#
using Cirno.Scripts.Resources;
|
|
using Godot;
|
|
|
|
namespace Cirno.Scripts.Actors;
|
|
|
|
public partial class DeathDebris3D : Node3D
|
|
{
|
|
[Export] public EnemyResource EnemyResource { get; private set; }
|
|
[Export] public AnimatedSprite3D Sprite { get; private set; }
|
|
|
|
public void Init(EnemyResource enemyResource)
|
|
{
|
|
EnemyResource = enemyResource;
|
|
|
|
if (EnemyResource.DeathAnimation is not null)
|
|
{
|
|
Sprite.SetSpriteFrames(enemyResource.DeathAnimation);
|
|
}
|
|
|
|
Sprite.Play();
|
|
}
|
|
} |