diff --git a/core/src/mindustry/world/draw/DrawPistons.java b/core/src/mindustry/world/draw/DrawPistons.java index 2015cc801f..bdf6faca0b 100644 --- a/core/src/mindustry/world/draw/DrawPistons.java +++ b/core/src/mindustry/world/draw/DrawPistons.java @@ -9,7 +9,7 @@ import mindustry.gen.*; import mindustry.world.*; public class DrawPistons extends DrawBlock{ - public float sinMag = 4f, sinScl = 6f, sinOffset = 50f, sideOffset = 0f, lenOffset = -1f; + public float sinMag = 4f, sinScl = 6f, sinOffset = 50f, sideOffset = 0f, lenOffset = -1f, angleOffset = 0f; public int sides = 4; public String suffix = "-piston"; public TextureRegion region1, region2, regiont; @@ -23,7 +23,7 @@ public class DrawPistons extends DrawBlock{ public void draw(Building build){ for(int i = 0; i < sides; i++){ float len = Mathf.absin(build.totalProgress() + sinOffset + sideOffset * sinScl * i, sinScl, sinMag) + lenOffset; - float angle = i * 360f / sides; + float angle = angleOffset + i * 360f / sides; TextureRegion reg = regiont.found() && (Mathf.equal(angle, 315) || Mathf.equal(angle, 135)) ? regiont : angle >= 135 && angle < 315 ? region2 : region1;