diff --git a/core/src/mindustry/type/UnitType.java b/core/src/mindustry/type/UnitType.java index 34c3b537df..3408948807 100644 --- a/core/src/mindustry/type/UnitType.java +++ b/core/src/mindustry/type/UnitType.java @@ -1282,9 +1282,9 @@ public class UnitType extends UnlockableContent implements Senseable{ for(int i = 0; i < parts.size; i++){ var part = parts.get(i); - WeaponMount first = unit.mounts.length > part.weaponIndex ? unit.mounts[part.weaponIndex] : null; - if(first != null){ - DrawPart.params.set(first.warmup, first.reload / weapons.first().reload, first.smoothReload, first.heat, first.recoil, first.charge, unit.x, unit.y, unit.rotation); + WeaponMount mount = unit.mounts.length > part.weaponIndex ? unit.mounts[part.weaponIndex] : null; + if(mount != null){ + DrawPart.params.set(mount.warmup, mount.reload / mount.weapon.reload, mount.smoothReload, mount.heat, mount.recoil, mount.charge, unit.x, unit.y, unit.rotation); }else{ DrawPart.params.set(0f, 0f, 0f, 0f, 0f, 0f, unit.x, unit.y, unit.rotation); }