Files
FOU/Scripts/Elements/Solid.cs
2024-07-14 17:22:37 +02:00

17 lines
456 B
C#

using Godot;
namespace FOU.Scripts.Elements;
public abstract class Solid : Element {
protected Solid(int x, int y, ref Chunk chunk) : base(x, y, chunk) { }
public override bool Update(int currentFrame) {
if (!base.Update(currentFrame)) return false;
if (LastMove + STEPS_UNTIL_INACTIVE < currentFrame) Active = false;
Tick();
return true; // not necessarily end, subclasses could do some more things
}
}