Package mindustry.graphics
Class Trail
java.lang.Object
mindustry.graphics.Trail
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
copy()
void
draw
(arc.graphics.Color color, float width) void
drawCap
(arc.graphics.Color color, float width) void
shorten()
Removes the last point from the trail at intervals.int
size()
void
update
(float x, float y) Adds a new point to the trail at intervals.void
update
(float x, float y, float width) Adds a new point to the trail at intervals.float
width()
-
Field Details
-
length
public int length -
points
protected arc.struct.FloatSeq points -
lastX
protected float lastX -
lastY
protected float lastY -
lastAngle
protected float lastAngle -
counter
protected float counter -
lastW
protected float lastW
-
-
Constructor Details
-
Trail
public Trail(int length)
-
-
Method Details
-
copy
-
width
public float width() -
clear
public void clear() -
size
public int size() -
drawCap
public void drawCap(arc.graphics.Color color, float width) -
draw
public void draw(arc.graphics.Color color, float width) -
shorten
public void shorten()Removes the last point from the trail at intervals. -
update
public void update(float x, float y) Adds a new point to the trail at intervals. -
update
public void update(float x, float y, float width) Adds a new point to the trail at intervals.
-