fixed drawpixel optimization

minor class refactoring
This commit is contained in:
2025-04-27 14:50:23 +02:00
parent abf948a310
commit da3afd22fc
5 changed files with 33 additions and 18 deletions

View File

@@ -5,11 +5,12 @@ namespace FOU.Scripts.Elements;
public abstract class Liquid : Element {
public const int MAX_VERTICAL_SPREAD = 3;
protected Liquid(int x, int y, ref Chunk chunk) : base(x, y, chunk) { }
protected Liquid(int x, int y, ref Chunk chunk) : base(x, y, chunk) {
MarkForUpdate();
}
public override bool Update() {
if (!base.Update()) return false;
if (lastMove + STEPS_UNTIL_INACTIVE < Engine.GetFramesDrawn()) Active = false;
Tick();