diff --git a/core/src/mindustry/world/blocks/defense/turrets/Turret.java b/core/src/mindustry/world/blocks/defense/turrets/Turret.java index 847ad58f7d..562e84a1e3 100644 --- a/core/src/mindustry/world/blocks/defense/turrets/Turret.java +++ b/core/src/mindustry/world/blocks/defense/turrets/Turret.java @@ -78,6 +78,7 @@ public class Turret extends ReloadTurret{ public @Load(value = "@-base", fallback = "block-@size") TextureRegion baseRegion; public @Load("@-heat") TextureRegion heatRegion; + public float elevation = -1f; public Cons drawer = tile -> Draw.rect(region, tile.x + tr2.x, tile.y + tr2.y, tile.rotation - 90); public Cons heatDrawer = tile -> { @@ -125,6 +126,7 @@ public class Turret extends ReloadTurret{ } if(shootLength < 0) shootLength = size * tilesize / 2f; + if(elevation < 0) elevation = size / 2f; super.init(); } @@ -234,7 +236,7 @@ public class Turret extends ReloadTurret{ tr2.trns(rotation, -recoil); - Drawf.shadow(region, x + tr2.x - (size / 2f), y + tr2.y - (size / 2f), rotation - 90); + Drawf.shadow(region, x + tr2.x - elevation, y + tr2.y - elevation, rotation - 90); drawer.get(this); if(heatRegion != Core.atlas.find("error")){