From d9ea17bacaaa17aefc715f847fd1af24e0c22e07 Mon Sep 17 00:00:00 2001 From: Anuken Date: Tue, 4 Aug 2020 16:49:20 -0400 Subject: [PATCH] Fixed #2311 --- core/src/mindustry/entities/comp/WaterMoveComp.java | 7 +++++++ core/src/mindustry/graphics/Trail.java | 4 ++++ 2 files changed, 11 insertions(+) diff --git a/core/src/mindustry/entities/comp/WaterMoveComp.java b/core/src/mindustry/entities/comp/WaterMoveComp.java index 3cc371eade..176c9dee09 100644 --- a/core/src/mindustry/entities/comp/WaterMoveComp.java +++ b/core/src/mindustry/entities/comp/WaterMoveComp.java @@ -35,6 +35,13 @@ abstract class WaterMoveComp implements Posc, Velc, Hitboxc, Flyingc, Unitc{ } } + @Override + public void add(){ + tleft.clear(); + tright.clear(); + } + + @Override public void draw(){ float z = Draw.z(); diff --git a/core/src/mindustry/graphics/Trail.java b/core/src/mindustry/graphics/Trail.java index e48cdda550..9838e40b63 100644 --- a/core/src/mindustry/graphics/Trail.java +++ b/core/src/mindustry/graphics/Trail.java @@ -18,6 +18,10 @@ public class Trail{ points = new Seq<>(length); } + public void clear(){ + points.clear(); + } + public void draw(Color color, float width){ Draw.color(color);