Minor cleanup
This commit is contained in:
@@ -2694,6 +2694,9 @@ public class UnitTypes{
|
|||||||
engineSize = 0;
|
engineSize = 0;
|
||||||
payloadCapacity = Mathf.sqr(3f) * tilePayload;
|
payloadCapacity = Mathf.sqr(3f) * tilePayload;
|
||||||
|
|
||||||
|
drawBuildBeam = false;
|
||||||
|
rotateToBuilding = false;
|
||||||
|
|
||||||
float es = 3.8f;
|
float es = 3.8f;
|
||||||
|
|
||||||
setEnginesMirror(
|
setEnginesMirror(
|
||||||
@@ -2717,9 +2720,6 @@ public class UnitTypes{
|
|||||||
shootY = 5.75f;
|
shootY = 5.75f;
|
||||||
recoil = 2f;
|
recoil = 2f;
|
||||||
|
|
||||||
drawBuildBeam = false;
|
|
||||||
rotateToBuilding = false;
|
|
||||||
|
|
||||||
bullet = new BasicBulletType(5f, 17){{
|
bullet = new BasicBulletType(5f, 17){{
|
||||||
width = 7f;
|
width = 7f;
|
||||||
height = 12f;
|
height = 12f;
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ import static mindustry.Vars.*;
|
|||||||
public class BlockRenderer{
|
public class BlockRenderer{
|
||||||
//TODO cracks take up far to much space, so I had to limit it to 7. this means larger blocks won't have cracks - draw tiling mirrored stuff instead?
|
//TODO cracks take up far to much space, so I had to limit it to 7. this means larger blocks won't have cracks - draw tiling mirrored stuff instead?
|
||||||
public static final int crackRegions = 8, maxCrackSize = 7;
|
public static final int crackRegions = 8, maxCrackSize = 7;
|
||||||
|
public static boolean drawQuadtreeDebug = false;
|
||||||
|
|
||||||
private static final int initialRequests = 32 * 32;
|
private static final int initialRequests = 32 * 32;
|
||||||
private static final Color shadowColor = new Color(0, 0, 0, 0.71f), blendShadowColor = Color.white.cpy().lerp(Color.black, shadowColor.a);
|
private static final Color shadowColor = new Color(0, 0, 0, 0.71f), blendShadowColor = Color.white.cpy().lerp(Color.black, shadowColor.a);
|
||||||
@@ -402,15 +403,17 @@ public class BlockRenderer{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//TODO remove
|
if(drawQuadtreeDebug){
|
||||||
Draw.z(Layer.overlayUI);
|
//TODO remove
|
||||||
Lines.stroke(1f, Color.green);
|
Draw.z(Layer.overlayUI);
|
||||||
|
Lines.stroke(1f, Color.green);
|
||||||
|
|
||||||
blockTree.intersect(camera.bounds(Tmp.r1), tile -> {
|
blockTree.intersect(camera.bounds(Tmp.r1), tile -> {
|
||||||
Lines.rect(tile.getHitbox(Tmp.r2));
|
Lines.rect(tile.getHitbox(Tmp.r2));
|
||||||
});
|
});
|
||||||
|
|
||||||
Draw.reset();
|
Draw.reset();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static class BlockQuadtree extends QuadTree<Tile>{
|
static class BlockQuadtree extends QuadTree<Tile>{
|
||||||
|
|||||||
@@ -46,7 +46,6 @@ public class BuildWeapon extends Weapon{
|
|||||||
super.draw(unit, mount);
|
super.draw(unit, mount);
|
||||||
|
|
||||||
if(unit.activelyBuilding()){
|
if(unit.activelyBuilding()){
|
||||||
|
|
||||||
float
|
float
|
||||||
rotation = unit.rotation - 90,
|
rotation = unit.rotation - 90,
|
||||||
weaponRotation = rotation + (rotate ? mount.rotation : 0),
|
weaponRotation = rotation + (rotate ? mount.rotation : 0),
|
||||||
@@ -57,7 +56,5 @@ public class BuildWeapon extends Weapon{
|
|||||||
|
|
||||||
unit.drawBuildingBeam(px, py);
|
unit.drawBuildingBeam(px, py);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user