diff --git a/core/src/mindustry/content/UnitTypes.java b/core/src/mindustry/content/UnitTypes.java index 3db7896d83..fff131aae3 100644 --- a/core/src/mindustry/content/UnitTypes.java +++ b/core/src/mindustry/content/UnitTypes.java @@ -1,6 +1,7 @@ package mindustry.content; import arc.graphics.*; +import arc.math.*; import arc.struct.*; import mindustry.annotations.Annotations.*; import mindustry.ctype.*; @@ -71,30 +72,24 @@ public class UnitTypes implements ContentList{ cix = new UnitType("cix"){{ drag = 0.1f; speed = 0.8f; - hitsize = 11f; + hitsize = 9f; health = 140; legCount = 6; rotateShooting = false; - weapons.add( - new Weapon("missiles-mount"){{ - reload = 20f; - x = 4f; - rotate = true; - mirror = false; - shake = 1f; - bullet = Bullets.missileSwarm; - }}, - new Weapon("missiles-mount"){{ - reload = 20f; - x = -4f; - rotate = true; - mirror = false; - flipSprite = true; - shake = 1f; - bullet = Bullets.missileSwarm; - }}); + for(boolean b : Mathf.booleans){ + weapons.add( + new Weapon("missiles-mount"){{ + reload = 20f; + x = 4f * Mathf.sign(b); + rotate = true; + mirror = false; + flipSprite = !b; + shake = 1f; + bullet = Bullets.missileSwarm; + }}); + } }}; titan = new UnitType("titan"){{ diff --git a/core/src/mindustry/entities/comp/LegsComp.java b/core/src/mindustry/entities/comp/LegsComp.java index b7df8c21e8..cef4485a60 100644 --- a/core/src/mindustry/entities/comp/LegsComp.java +++ b/core/src/mindustry/entities/comp/LegsComp.java @@ -42,7 +42,7 @@ abstract class LegsComp implements Posc, Rotc, Hitboxc, Flyingc, Unitc{ } } - float moveSpeed = 0.1f; + float moveSpeed = type().legSpeed; int div = Math.max(legs.length / 2, 2); float moveSpace = legLength / 1.6f / (div / 2f); @@ -69,7 +69,7 @@ abstract class LegsComp implements Posc, Rotc, Hitboxc, Flyingc, Unitc{ } float movespace = 360f / legs.length / 4f; - float trns = vel().len() * 12.5f * div/1.5f; + float trns = vel().len() * 12.5f * div/1.5f * type().legTrns; Tmp.v4.trns(rotation, trns); diff --git a/core/src/mindustry/type/UnitType.java b/core/src/mindustry/type/UnitType.java index 9861c415eb..28db89f096 100644 --- a/core/src/mindustry/type/UnitType.java +++ b/core/src/mindustry/type/UnitType.java @@ -39,10 +39,11 @@ public class UnitType extends UnlockableContent{ public boolean targetAir = true, targetGround = true; public boolean faceTarget = true, rotateShooting = true, isCounted = true, lowAltitude = false; public boolean canBoost = false; - public int legCount = 4; - public float legLength = 24f; public float sway = 1f; + public int legCount = 4; + public float legLength = 24f, legSpeed = 0.1f, legTrns = 1f; + public int itemCapacity = 30; public int drillTier = -1; public float buildSpeed = 1f, mineSpeed = 1f;