imrpvoed water behavior

This commit is contained in:
2025-05-05 20:10:02 +02:00
parent 9a36418d23
commit 7458d5749c
2 changed files with 4 additions and 7 deletions

View File

@@ -29,10 +29,10 @@ public abstract class Liquid : Element {
else if (Chunk.IsEmpty(Position + randomDirection * VERTICAL_OPPOSITE))
Chunk.Swap(this, Position + randomDirection * VERTICAL_OPPOSITE);
else if (Chunk.IsEmpty(Position + randomDirection))
Chunk.Swap(this, Position + Vector2I.Right + randomDirection);
else if (Chunk.IsEmpty(Position - randomDirection))
Chunk.Swap(this, Position + Vector2I.Right + randomDirection * VERTICAL_OPPOSITE);
else if (Chunk.IsEmpty(Position + 2 * randomDirection))
Chunk.Swap(this, Position + 2 * randomDirection);
else if (Chunk.IsEmpty(Position - 2 * randomDirection * VERTICAL_OPPOSITE))
Chunk.Swap(this, Position - 2 * randomDirection * VERTICAL_OPPOSITE);
}
public override void ActivateNeighbors() {