Particles system

This commit is contained in:
Rendo 2025-06-28 02:44:42 +05:00
commit 0e5dee50f7
46 changed files with 643 additions and 200 deletions

View file

@ -0,0 +1,22 @@
using Godot;
public partial class StandardParticles : Node2D
{
private int counter = 0;
private int counterMax = 0;
public override void _Ready()
{
foreach (GpuParticles2D emitter in GetChildren())
{
emitter.Emitting = true;
counterMax += 1;
emitter.Finished += MarkForDestruction;
}
}
public void MarkForDestruction()
{
if (Engine.IsEditorHint()) return;
if (++counter < counterMax) return;
QueueFree();
}
}

View file

@ -0,0 +1 @@
uid://dxcd70o6aa7pr