From 448d1e2c7770f20e1e70a815dedbece0673929ee Mon Sep 17 00:00:00 2001 From: Anuken Date: Sun, 20 Jun 2021 09:50:25 -0400 Subject: [PATCH] Cleanup --- core/src/mindustry/content/Blocks.java | 6 +-- core/src/mindustry/editor/MapInfoDialog.java | 1 - core/src/mindustry/editor/WaveInfoDialog.java | 1 - .../entities/abilities/UnitSpawnAbility.java | 1 - .../mindustry/entities/comp/BuilderComp.java | 1 - .../mindustry/entities/comp/EntityComp.java | 1 - .../entities/comp/LaunchCoreComp.java | 1 - .../mindustry/entities/comp/PayloadComp.java | 1 - .../mindustry/graphics/IndexedRenderer.java | 42 ++++++++++--------- core/src/mindustry/graphics/Voronoi.java | 2 +- .../src/mindustry/graphics/g3d/NoiseMesh.java | 2 +- core/src/mindustry/logic/LExecutor.java | 1 - .../maps/generators/PlanetGenerator.java | 2 +- .../maps/planet/ErekirPlanetGenerator.java | 6 +-- .../maps/planet/SerpuloPlanetGenerator.java | 8 ++-- .../maps/planet/TantrosPlanetGenerator.java | 6 +-- core/src/mindustry/mod/Scripts.java | 2 - core/src/mindustry/type/Weapon.java | 2 +- core/src/mindustry/ui/Links.java | 32 +++++++++----- .../ui/dialogs/CustomRulesDialog.java | 2 +- core/src/mindustry/ui/dialogs/JoinDialog.java | 2 +- .../mindustry/ui/dialogs/MapPlayDialog.java | 2 +- .../ui/dialogs/SchematicsDialog.java | 18 +------- .../world/blocks/distribution/Conveyor.java | 1 - .../world/blocks/liquid/Conduit.java | 1 - .../world/blocks/payloads/BlockForge.java | 1 - gradle.properties | 2 +- 27 files changed, 63 insertions(+), 84 deletions(-) diff --git a/core/src/mindustry/content/Blocks.java b/core/src/mindustry/content/Blocks.java index 6ea3167a33..70a946a023 100644 --- a/core/src/mindustry/content/Blocks.java +++ b/core/src/mindustry/content/Blocks.java @@ -39,7 +39,7 @@ public class Blocks implements ContentList{ dacite, rhyolite, rhyoliteCrater, regolith, yellowStone, redIce, redmat, bluemat, stoneWall, dirtWall, sporeWall, iceWall, daciteWall, sporePine, snowPine, pine, shrubs, whiteTree, whiteTreeDead, sporeCluster, - redweed, purbush, coralChunk, glowBlob, yellowCoral, + redweed, purbush, coralChunk, yellowCoral, regolithWall, yellowStoneWall, rhyoliteWall, carbonWall, redIceWall, ferricStoneWall, ferricStone, ferricCraters, graphiticStone, iceSnow, sandWater, darksandWater, duneWall, sandWall, moss, sporeMoss, shale, shaleWall, shaleBoulder, sandBoulder, daciteBoulder, boulder, snowBoulder, basaltBoulder, grass, salt, @@ -451,10 +451,6 @@ public class Blocks implements ContentList{ }}; - //glowBlob = new Prop("glowblob"){{ - // variants = 1; - //}}; - boulder = new Prop("boulder"){{ variants = 2; stone.asFloor().decoration = this; diff --git a/core/src/mindustry/editor/MapInfoDialog.java b/core/src/mindustry/editor/MapInfoDialog.java index 288f7224c3..63b9a053da 100644 --- a/core/src/mindustry/editor/MapInfoDialog.java +++ b/core/src/mindustry/editor/MapInfoDialog.java @@ -3,7 +3,6 @@ package mindustry.editor; import arc.*; import arc.scene.ui.*; import arc.struct.*; -import arc.util.*; import mindustry.*; import mindustry.game.*; import mindustry.io.*; diff --git a/core/src/mindustry/editor/WaveInfoDialog.java b/core/src/mindustry/editor/WaveInfoDialog.java index d83fa11f3e..75c96c238d 100644 --- a/core/src/mindustry/editor/WaveInfoDialog.java +++ b/core/src/mindustry/editor/WaveInfoDialog.java @@ -14,7 +14,6 @@ import mindustry.gen.*; import mindustry.graphics.*; import mindustry.io.*; import mindustry.type.*; -import mindustry.ui.*; import mindustry.ui.dialogs.*; import static mindustry.Vars.*; diff --git a/core/src/mindustry/entities/abilities/UnitSpawnAbility.java b/core/src/mindustry/entities/abilities/UnitSpawnAbility.java index 92d26e59cc..b6f8561056 100644 --- a/core/src/mindustry/entities/abilities/UnitSpawnAbility.java +++ b/core/src/mindustry/entities/abilities/UnitSpawnAbility.java @@ -10,7 +10,6 @@ import mindustry.entities.*; import mindustry.gen.*; import mindustry.graphics.*; import mindustry.type.*; -import mindustry.ui.*; import static mindustry.Vars.*; diff --git a/core/src/mindustry/entities/comp/BuilderComp.java b/core/src/mindustry/entities/comp/BuilderComp.java index 9b456e5602..f92141f2ee 100644 --- a/core/src/mindustry/entities/comp/BuilderComp.java +++ b/core/src/mindustry/entities/comp/BuilderComp.java @@ -20,7 +20,6 @@ import mindustry.type.*; import mindustry.world.*; import mindustry.world.blocks.*; import mindustry.world.blocks.ConstructBlock.*; -import mindustry.world.blocks.storage.CoreBlock.*; import java.util.*; diff --git a/core/src/mindustry/entities/comp/EntityComp.java b/core/src/mindustry/entities/comp/EntityComp.java index d44e5481b4..aaacdc521b 100644 --- a/core/src/mindustry/entities/comp/EntityComp.java +++ b/core/src/mindustry/entities/comp/EntityComp.java @@ -1,6 +1,5 @@ package mindustry.entities.comp; -import arc.func.*; import arc.util.io.*; import mindustry.annotations.Annotations.*; import mindustry.entities.*; diff --git a/core/src/mindustry/entities/comp/LaunchCoreComp.java b/core/src/mindustry/entities/comp/LaunchCoreComp.java index e91e3749fc..b28e3657b8 100644 --- a/core/src/mindustry/entities/comp/LaunchCoreComp.java +++ b/core/src/mindustry/entities/comp/LaunchCoreComp.java @@ -7,7 +7,6 @@ import mindustry.annotations.Annotations.*; import mindustry.content.*; import mindustry.gen.*; import mindustry.graphics.*; -import mindustry.ui.*; import mindustry.world.*; @EntityDef(value = LaunchCorec.class, serialize = false) diff --git a/core/src/mindustry/entities/comp/PayloadComp.java b/core/src/mindustry/entities/comp/PayloadComp.java index 0f02434a92..6ea64825bd 100644 --- a/core/src/mindustry/entities/comp/PayloadComp.java +++ b/core/src/mindustry/entities/comp/PayloadComp.java @@ -13,7 +13,6 @@ import mindustry.entities.*; import mindustry.game.EventType.*; import mindustry.gen.*; import mindustry.type.*; -import mindustry.ui.*; import mindustry.world.*; import mindustry.world.blocks.payloads.*; diff --git a/core/src/mindustry/graphics/IndexedRenderer.java b/core/src/mindustry/graphics/IndexedRenderer.java index 9c02615fbd..4353279355 100644 --- a/core/src/mindustry/graphics/IndexedRenderer.java +++ b/core/src/mindustry/graphics/IndexedRenderer.java @@ -10,27 +10,29 @@ public class IndexedRenderer implements Disposable{ private static final int vsize = 5; private final Shader program = new Shader( - "attribute vec4 a_position;\n" + - "attribute vec4 a_color;\n" + - "attribute vec2 a_texCoord0;\n" + - "uniform mat4 u_projTrans;\n" + - "varying vec4 v_color;\n" + - "varying vec2 v_texCoords;\n" + + """ + attribute vec4 a_position; + attribute vec4 a_color; + attribute vec2 a_texCoord0; + uniform mat4 u_projTrans; + varying vec4 v_color; + varying vec2 v_texCoords; + void main(){ + v_color = a_color; + v_color.a = v_color.a * (255.0/254.0); + v_texCoords = a_texCoord0; + gl_Position = u_projTrans * a_position; + } + """, - "void main(){\n" + - " v_color = a_color;\n" + - " v_color.a = v_color.a * (255.0/254.0);\n" + - " v_texCoords = a_texCoord0;\n" + - " gl_Position = u_projTrans * a_position;\n" + - "}", - - "varying lowp vec4 v_color;\n" + - "varying vec2 v_texCoords;\n" + - "uniform sampler2D u_texture;\n" + - - "void main(){\n" + - " gl_FragColor = v_color * texture2D(u_texture, v_texCoords);\n" + - "}" + """ + varying lowp vec4 v_color; + varying vec2 v_texCoords; + uniform sampler2D u_texture; + void main(){ + gl_FragColor = v_color * texture2D(u_texture, v_texCoords); + } + """ ); private Mesh mesh; private float[] tmpVerts = new float[vsize * 6]; diff --git a/core/src/mindustry/graphics/Voronoi.java b/core/src/mindustry/graphics/Voronoi.java index 7b10e497e2..84065f53b2 100755 --- a/core/src/mindustry/graphics/Voronoi.java +++ b/core/src/mindustry/graphics/Voronoi.java @@ -396,7 +396,7 @@ public class Voronoi{ private void clipLine(Edge e){ float pxmin, pxmax, pymin, pymax; Site s1, s2; - float x1 = 0, x2 = 0, y1 = 0, y2 = 0; + float x1, x2, y1, y2; x1 = e.reg[0].coord.x; x2 = e.reg[1].coord.x; diff --git a/core/src/mindustry/graphics/g3d/NoiseMesh.java b/core/src/mindustry/graphics/g3d/NoiseMesh.java index 143760a551..e04634c981 100644 --- a/core/src/mindustry/graphics/g3d/NoiseMesh.java +++ b/core/src/mindustry/graphics/g3d/NoiseMesh.java @@ -14,7 +14,7 @@ public class NoiseMesh extends HexMesh{ this.mesh = MeshBuilder.buildHex(new HexMesher(){ @Override public float getHeight(Vec3 position){ - return (float)Simplex.noise3d(planet.id + seed, octaves, persistence, scale, 5f + position.x, 5f + position.y, 5f + position.z) * mag; + return Simplex.noise3d(planet.id + seed, octaves, persistence, scale, 5f + position.x, 5f + position.y, 5f + position.z) * mag; } @Override diff --git a/core/src/mindustry/logic/LExecutor.java b/core/src/mindustry/logic/LExecutor.java index b5695d9773..5536874a6e 100644 --- a/core/src/mindustry/logic/LExecutor.java +++ b/core/src/mindustry/logic/LExecutor.java @@ -4,7 +4,6 @@ import arc.*; import arc.math.geom.*; import arc.struct.*; import arc.util.*; -import arc.util.noise.*; import mindustry.*; import mindustry.ai.types.*; import mindustry.content.*; diff --git a/core/src/mindustry/maps/generators/PlanetGenerator.java b/core/src/mindustry/maps/generators/PlanetGenerator.java index 4fe870d3dc..d3596ee82b 100644 --- a/core/src/mindustry/maps/generators/PlanetGenerator.java +++ b/core/src/mindustry/maps/generators/PlanetGenerator.java @@ -115,7 +115,7 @@ public abstract class PlanetGenerator extends BasicGenerator implements HexMeshe @Override protected float noise(float x, float y, double octaves, double falloff, double scl, double mag){ Vec3 v = sector.rect.project(x, y); - return (float)Simplex.noise3d(0, octaves, falloff, 1f / scl, v.x, v.y, v.z) * (float)mag; + return Simplex.noise3d(0, octaves, falloff, 1f / scl, v.x, v.y, v.z) * (float)mag; } /** @return the scaling factor for sector rects. */ diff --git a/core/src/mindustry/maps/planet/ErekirPlanetGenerator.java b/core/src/mindustry/maps/planet/ErekirPlanetGenerator.java index 89f5a99abf..da40752bde 100644 --- a/core/src/mindustry/maps/planet/ErekirPlanetGenerator.java +++ b/core/src/mindustry/maps/planet/ErekirPlanetGenerator.java @@ -48,11 +48,11 @@ public class ErekirPlanetGenerator extends PlanetGenerator{ } float rawHeight(Vec3 position){ - return (float)Simplex.noise3d(seed, octaves, persistence, 1f/heightScl, 10f + position.x, 10f + position.y, 10f + position.z); + return Simplex.noise3d(seed, octaves, persistence, 1f/heightScl, 10f + position.x, 10f + position.y, 10f + position.z); } float rawTemp(Vec3 position){ - return position.dst(0, 0, 1)*2.2f - (float)Simplex.noise3d(seed, 8, 0.54f, 1.4f, 10f + position.x, 10f + position.y, 10f + position.z) * 2.9f; + return position.dst(0, 0, 1)*2.2f - Simplex.noise3d(seed, 8, 0.54f, 1.4f, 10f + position.x, 10f + position.y, 10f + position.z) * 2.9f; } Block getBlock(Vec3 position){ @@ -61,7 +61,7 @@ public class ErekirPlanetGenerator extends PlanetGenerator{ float height = rawHeight(position); Tmp.v31.set(position); position = Tmp.v33.set(position).scl(scl); - float temp = (float)Simplex.noise3d(seed, 8, 0.6, 1f/2f, 10f + position.x, 10f + position.y + 99f, 10f + position.z); + float temp = Simplex.noise3d(seed, 8, 0.6, 1f/2f, 10f + position.x, 10f + position.y + 99f, 10f + position.z); height *= 1.2f; height = Mathf.clamp(height); diff --git a/core/src/mindustry/maps/planet/SerpuloPlanetGenerator.java b/core/src/mindustry/maps/planet/SerpuloPlanetGenerator.java index f69537ef44..a60d8b749a 100644 --- a/core/src/mindustry/maps/planet/SerpuloPlanetGenerator.java +++ b/core/src/mindustry/maps/planet/SerpuloPlanetGenerator.java @@ -57,7 +57,7 @@ public class SerpuloPlanetGenerator extends PlanetGenerator{ float rawHeight(Vec3 position){ position = Tmp.v33.set(position).scl(scl); - return (Mathf.pow((float)Simplex.noise3d(seed, 7, 0.5f, 1f/3f, position.x, position.y, position.z), 2.3f) + waterOffset) / (1f + waterOffset); + return (Mathf.pow(Simplex.noise3d(seed, 7, 0.5f, 1f/3f, position.x, position.y, position.z), 2.3f) + waterOffset) / (1f + waterOffset); } @Override @@ -127,12 +127,12 @@ public class SerpuloPlanetGenerator extends PlanetGenerator{ position = Tmp.v33.set(position).scl(scl); float rad = scl; float temp = Mathf.clamp(Math.abs(position.y * 2f) / (rad)); - float tnoise = (float)Simplex.noise3d(seed, 7, 0.56, 1f/3f, position.x, position.y + 999f, position.z); + float tnoise = Simplex.noise3d(seed, 7, 0.56, 1f/3f, position.x, position.y + 999f, position.z); temp = Mathf.lerp(temp, tnoise, 0.5f); height *= 1.2f; height = Mathf.clamp(height); - float tar = (float)Simplex.noise3d(seed, 4, 0.55f, 1f/2f, position.x, position.y + 999f, position.z) * 0.3f + Tmp.v31.dst(0, 0, 1f) * 0.2f; + float tar = Simplex.noise3d(seed, 4, 0.55f, 1f/2f, position.x, position.y + 999f, position.z) * 0.3f + Tmp.v31.dst(0, 0, 1f) * 0.2f; Block res = arr[Mathf.clamp((int)(temp * arr.length), 0, arr[0].length - 1)][Mathf.clamp((int)(height * arr[0].length), 0, arr[0].length - 1)]; if(tar > 0.5f){ @@ -145,7 +145,7 @@ public class SerpuloPlanetGenerator extends PlanetGenerator{ @Override protected float noise(float x, float y, double octaves, double falloff, double scl, double mag){ Vec3 v = sector.rect.project(x, y).scl(5f); - return (float)Simplex.noise3d(seed, octaves, falloff, 1f / scl, v.x, v.y, v.z) * (float)mag; + return Simplex.noise3d(seed, octaves, falloff, 1f / scl, v.x, v.y, v.z) * (float)mag; } @Override diff --git a/core/src/mindustry/maps/planet/TantrosPlanetGenerator.java b/core/src/mindustry/maps/planet/TantrosPlanetGenerator.java index 897580c6e6..282b9648bc 100644 --- a/core/src/mindustry/maps/planet/TantrosPlanetGenerator.java +++ b/core/src/mindustry/maps/planet/TantrosPlanetGenerator.java @@ -36,7 +36,7 @@ public class TantrosPlanetGenerator extends PlanetGenerator{ @Override public Color getColor(Vec3 position){ - float depth = (float)Simplex.noise3d(seed, 2, 0.56, 1.7f, position.x, position.y, position.z) / 2f; + float depth = Simplex.noise3d(seed, 2, 0.56, 1.7f, position.x, position.y, position.z) / 2f; return c1.write(out).lerp(c2, Mathf.clamp(Mathf.round(depth, 0.15f))).a(0.6f); } @@ -91,14 +91,14 @@ public class TantrosPlanetGenerator extends PlanetGenerator{ } float rawHeight(Vec3 position){ - return (float)Simplex.noise3d(seed, 8, 0.7f, 1f, position.x, position.y, position.z); + return Simplex.noise3d(seed, 8, 0.7f, 1f, position.x, position.y, position.z); } Block getBlock(Vec3 position){ float height = rawHeight(position); Tmp.v31.set(position); position = Tmp.v33.set(position).scl(2f); - float temp = (float)Simplex.noise3d(seed, 8, 0.6, 1f/2f, position.x, position.y + 99f, position.z); + float temp = Simplex.noise3d(seed, 8, 0.6, 1f/2f, position.x, position.y + 99f, position.z); height *= 1.2f; height = Mathf.clamp(height); diff --git a/core/src/mindustry/mod/Scripts.java b/core/src/mindustry/mod/Scripts.java index 1aa69b9ab7..5d19d044ed 100644 --- a/core/src/mindustry/mod/Scripts.java +++ b/core/src/mindustry/mod/Scripts.java @@ -7,7 +7,6 @@ import arc.assets.loaders.SoundLoader.*; import arc.audio.*; import arc.files.*; import arc.func.*; -import arc.struct.*; import arc.util.*; import arc.util.Log.*; import mindustry.*; @@ -18,7 +17,6 @@ import rhino.module.provider.*; import java.io.*; import java.net.*; -import java.util.*; import java.util.regex.*; public class Scripts implements Disposable{ diff --git a/core/src/mindustry/type/Weapon.java b/core/src/mindustry/type/Weapon.java index ca002353bc..7df7a4cece 100644 --- a/core/src/mindustry/type/Weapon.java +++ b/core/src/mindustry/type/Weapon.java @@ -26,7 +26,7 @@ public class Weapon implements Cloneable{ static int sequenceNum = 0; /** displayed weapon region */ - public String name = ""; + public String name; /** bullet shot */ public BulletType bullet = Bullets.standardCopper; /** shell ejection effect */ diff --git a/core/src/mindustry/ui/Links.java b/core/src/mindustry/ui/Links.java index 6c5962d11c..f9c4c734d9 100644 --- a/core/src/mindustry/ui/Links.java +++ b/core/src/mindustry/ui/Links.java @@ -56,17 +56,27 @@ public class Links{ private static String report(){ return "https://github.com/Anuken/Mindustry/issues/new?assignees=&labels=bug&body=" + Strings.encode(Strings.format( - "**Platform**: `@`\n" + - "\n**Build**: `@`\n" + - "\n**Issue**: *Explain your issue in detail.*\n" + - "\n**Steps to reproduce**: *How you happened across the issue, and what exactly you did to make the bug happen.*\n" + - "\n**Link(s) to mod(s) used**: `@`\n" + - "\n**Save file**: *The (zipped) save file you were playing on when the bug happened. THIS IS REQUIRED FOR ANY ISSUE HAPPENING IN-GAME, REGARDLESS OF WHETHER YOU THINK IT HAPPENS EVERYWHERE. DO NOT DELETE OR OMIT THIS LINE UNLESS YOU ARE SURE THAT THE ISSUE DOES NOT HAPPEN IN-GAME.*\n" + - "\n**Crash report**: *The contents of relevant crash report files. REQUIRED if you are reporting a crash.*\n" + - "\n---\n" + - "\n*Place an X (no spaces) between the brackets to confirm that you have read the line below.*" + - "\n- [ ] **I have updated to the latest release (https://github.com/Anuken/Mindustry/releases) to make sure my issue has not been fixed.**" + - "\n- [ ] **I have searched the closed and open issues to make sure that this problem has not already been reported.**", + """ + **Platform**: `@` + + **Build**: `@` + + **Issue**: *Explain your issue in detail.* + + **Steps to reproduce**: *How you happened across the issue, and what exactly you did to make the bug happen.* + + **Link(s) to mod(s) used**: `@` + + **Save file**: *The (zipped) save file you were playing on when the bug happened. THIS IS REQUIRED FOR ANY ISSUE HAPPENING IN-GAME, REGARDLESS OF WHETHER YOU THINK IT HAPPENS EVERYWHERE. DO NOT DELETE OR OMIT THIS LINE UNLESS YOU ARE SURE THAT THE ISSUE DOES NOT HAPPEN IN-GAME.* + + **Crash report**: *The contents of relevant crash report files. REQUIRED if you are reporting a crash.* + + --- + + *Place an X (no spaces) between the brackets to confirm that you have read the line below.* + - [ ] **I have updated to the latest release (https://github.com/Anuken/Mindustry/releases) to make sure my issue has not been fixed.** + - [ ] **I have searched the closed and open issues to make sure that this problem has not already been reported.** + """, OS.isAndroid ? "Android " + Core.app.getVersion() : (System.getProperty("os.name") + (OS.is64Bit ? " x64" : " x32")), Version.combined(), Vars.mods.list().any() ? Vars.mods.list().select(LoadedMod::enabled).map(l -> l.meta.author + "/" + l.name + ":" + l.meta.version) : "none")); diff --git a/core/src/mindustry/ui/dialogs/CustomRulesDialog.java b/core/src/mindustry/ui/dialogs/CustomRulesDialog.java index aa19947d54..7c77c47d75 100644 --- a/core/src/mindustry/ui/dialogs/CustomRulesDialog.java +++ b/core/src/mindustry/ui/dialogs/CustomRulesDialog.java @@ -212,7 +212,7 @@ public class CustomRulesDialog extends BaseDialog{ main.table(t -> { t.left(); t.add(text).left().padRight(5); - t.field((integer ? (int)prov.get() : prov.get()) + "", s -> cons.get(Strings.parseInt(s))) + t.field((integer ? prov.get() : prov.get()) + "", s -> cons.get(Strings.parseInt(s))) .padRight(100f) .valid(f -> Strings.parseInt(f) >= min && Strings.parseInt(f) <= max).width(120f).left().addInputDialog(); }).padTop(0); diff --git a/core/src/mindustry/ui/dialogs/JoinDialog.java b/core/src/mindustry/ui/dialogs/JoinDialog.java index c12970546b..28415c7dc8 100644 --- a/core/src/mindustry/ui/dialogs/JoinDialog.java +++ b/core/src/mindustry/ui/dialogs/JoinDialog.java @@ -497,7 +497,7 @@ public class JoinDialog extends BaseDialog{ void safeConnect(String ip, int port, int version){ if(version != Version.build && Version.build != -1 && version != -1){ - ui.showInfo("[scarlet]" + (version > Version.build ? KickReason.clientOutdated : KickReason.serverOutdated).toString() + "\n[]" + + ui.showInfo("[scarlet]" + (version > Version.build ? KickReason.clientOutdated : KickReason.serverOutdated) + "\n[]" + Core.bundle.format("server.versions", Version.build, version)); }else{ connect(ip, port); diff --git a/core/src/mindustry/ui/dialogs/MapPlayDialog.java b/core/src/mindustry/ui/dialogs/MapPlayDialog.java index 004c990f00..730762932c 100644 --- a/core/src/mindustry/ui/dialogs/MapPlayDialog.java +++ b/core/src/mindustry/ui/dialogs/MapPlayDialog.java @@ -97,7 +97,7 @@ public class MapPlayDialog extends BaseDialog{ table.row(); for(Gamemode mode : Gamemode.values()){ if(mode.hidden) continue; - table.labelWrap("[accent]" + mode.toString() + ":[] [lightgray]" + mode.description()).width(400f); + table.labelWrap("[accent]" + mode + ":[] [lightgray]" + mode.description()).width(400f); table.row(); } diff --git a/core/src/mindustry/ui/dialogs/SchematicsDialog.java b/core/src/mindustry/ui/dialogs/SchematicsDialog.java index a4616af643..0974873e91 100644 --- a/core/src/mindustry/ui/dialogs/SchematicsDialog.java +++ b/core/src/mindustry/ui/dialogs/SchematicsDialog.java @@ -417,23 +417,7 @@ public class SchematicsDialog extends BaseDialog{ int cols = (int)Math.min(20, Core.graphics.getWidth() / 52f); - /* - int i = 0; - for(var key : defaultIcons){ - var value = Icon.icons.get(key); - - t.button(value, Styles.cleari, () -> { - sector.info.icon = key; - sector.info.contentIcon = null; - sector.saveInfo(); - hide(); - updateSelected(); - }).checked(key.equals(sector.info.icon)); - - if(++i % cols == 0) t.row(); - }*/ - - int i = 0; + int i; for(ContentType ctype : defaultContentIcons){ t.row(); diff --git a/core/src/mindustry/world/blocks/distribution/Conveyor.java b/core/src/mindustry/world/blocks/distribution/Conveyor.java index a5608bd1f6..22811f3326 100644 --- a/core/src/mindustry/world/blocks/distribution/Conveyor.java +++ b/core/src/mindustry/world/blocks/distribution/Conveyor.java @@ -14,7 +14,6 @@ import mindustry.gen.*; import mindustry.graphics.*; import mindustry.input.*; import mindustry.type.*; -import mindustry.ui.*; import mindustry.world.*; import mindustry.world.blocks.*; import mindustry.world.meta.*; diff --git a/core/src/mindustry/world/blocks/liquid/Conduit.java b/core/src/mindustry/world/blocks/liquid/Conduit.java index 11a4014df3..393af2e8e5 100644 --- a/core/src/mindustry/world/blocks/liquid/Conduit.java +++ b/core/src/mindustry/world/blocks/liquid/Conduit.java @@ -18,7 +18,6 @@ import mindustry.type.*; import mindustry.world.*; import mindustry.world.blocks.*; import mindustry.world.blocks.distribution.*; -import mindustry.world.meta.*; import static mindustry.Vars.*; diff --git a/core/src/mindustry/world/blocks/payloads/BlockForge.java b/core/src/mindustry/world/blocks/payloads/BlockForge.java index 52827780af..48a4d366a4 100644 --- a/core/src/mindustry/world/blocks/payloads/BlockForge.java +++ b/core/src/mindustry/world/blocks/payloads/BlockForge.java @@ -6,7 +6,6 @@ import arc.scene.ui.layout.*; import arc.util.*; import arc.util.io.*; import mindustry.*; -import mindustry.ui.*; import mindustry.world.*; import mindustry.world.blocks.*; import mindustry.world.meta.*; diff --git a/gradle.properties b/gradle.properties index 70d530c757..1399d52bbd 100644 --- a/gradle.properties +++ b/gradle.properties @@ -10,4 +10,4 @@ kapt.include.compile.classpath=false kotlin.stdlib.default.dependency=false #needed for android compilation android.useAndroidX=true -archash=f9bf8552f839d87fa561adafa3085d83a044be9f +archash=3de7a709fa1c0ba8cb0131f0fc6b02524e18016b