From d6c852a082cb333a023fa9fe968ba4e3618b8f49 Mon Sep 17 00:00:00 2001 From: Skin <62944380+SkinH@users.noreply.github.com> Date: Sun, 14 Feb 2021 16:54:25 +0300 Subject: [PATCH 1/2] remove-pandorum (#4676) Good luck! --- servers_v6.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/servers_v6.json b/servers_v6.json index 0c59a8fc74..b328fd3045 100644 --- a/servers_v6.json +++ b/servers_v6.json @@ -17,7 +17,7 @@ }, { "name": "C.A.M.S.", - "address": ["routerchain.ddns.net", "pandorum.su:8000", "nikochio.ddns.net"] + "address": ["routerchain.ddns.net", "nikochio.ddns.net"] }, { "name": "BE6.RUN", From 7532aadaf8445f1c429b6e81c31e54fb8a90209f Mon Sep 17 00:00:00 2001 From: Joshua Fan Date: Sun, 14 Feb 2021 16:02:28 -0800 Subject: [PATCH 2/2] Add enable building hint, combine building and respawn hints (#4678) --- core/src/mindustry/input/DesktopInput.java | 43 +++++++++------------- 1 file changed, 17 insertions(+), 26 deletions(-) diff --git a/core/src/mindustry/input/DesktopInput.java b/core/src/mindustry/input/DesktopInput.java index 01f9e4b5f5..278eec1a0a 100644 --- a/core/src/mindustry/input/DesktopInput.java +++ b/core/src/mindustry/input/DesktopInput.java @@ -8,7 +8,6 @@ import arc.graphics.g2d.*; import arc.math.*; import arc.math.geom.*; import arc.scene.*; -import arc.scene.event.*; import arc.scene.ui.*; import arc.scene.ui.layout.*; import arc.util.*; @@ -42,38 +41,32 @@ public class DesktopInput extends InputHandler{ /** Selected build request for movement. */ public @Nullable BuildPlan sreq; /** Whether player is currently deleting removal requests. */ - public boolean deleting = false, wasBuilding = true, shouldShoot = false, panning = false; + public boolean deleting = false, shouldShoot = false, panning = false; /** Mouse pan speed. */ public float panScale = 0.005f, panSpeed = 4.5f, panBoostSpeed = 11f; @Override public void buildUI(Group group){ - //respawn hints + //building and respawn hints group.fill(t -> { - t.visible(() -> Core.settings.getBool("hints") && ui.hudfrag.shown && !player.dead() && !player.unit().spawnedByCore() && !(Core.settings.getBool("hints") && lastSchematic != null && !selectRequests.isEmpty())); + t.visible(() -> ui.hudfrag.shown && Core.settings.getBool("hints") && selectRequests.isEmpty() && (!isBuilding && !Core.settings.getBool("buildautopause") || player.unit().isBuilding() || !player.dead() && !player.unit().spawnedByCore())); t.bottom(); t.table(Styles.black6, b -> { b.defaults().left(); - b.label(() -> Core.bundle.format("respawn", Core.keybinds.get(Binding.respawn).key.toString())).style(Styles.outlineLabel); - }).margin(6f); - }); - - //building hints - group.fill(t -> { - t.bottom(); - t.visible(() -> { - t.color.a = Mathf.lerpDelta(t.color.a, player.unit().isBuilding() ? 1f : 0f, 0.15f); - - return ui.hudfrag.shown && Core.settings.getBool("hints") && selectRequests.isEmpty() && t.color.a > 0.01f; - }); - t.touchable(() -> t.color.a < 0.1f ? Touchable.disabled : Touchable.childrenOnly); - t.table(Styles.black6, b -> { - b.defaults().left(); - b.label(() -> Core.bundle.format(!isBuilding ? "resumebuilding" : "pausebuilding", Core.keybinds.get(Binding.pause_building).key.toString())).style(Styles.outlineLabel); - b.row(); - b.label(() -> Core.bundle.format("cancelbuilding", Core.keybinds.get(Binding.clear_building).key.toString())).style(Styles.outlineLabel); - b.row(); - b.label(() -> Core.bundle.format("selectschematic", Core.keybinds.get(Binding.schematic_select).key.toString())).style(Styles.outlineLabel); + b.label(() -> { + String str = ""; + if(!isBuilding && !Core.settings.getBool("buildautopause") && !player.unit().isBuilding()){ + str += Core.bundle.format("enablebuilding", Core.keybinds.get(Binding.pause_building).key.toString()); + }else if(player.unit().isBuilding()){ + str += Core.bundle.format(isBuilding ? "pausebuilding" : "resumebuilding", Core.keybinds.get(Binding.pause_building).key.toString()) + + "\n" + Core.bundle.format("cancelbuilding", Core.keybinds.get(Binding.clear_building).key.toString()) + + "\n" + Core.bundle.format("selectschematic", Core.keybinds.get(Binding.schematic_select).key.toString()); + } + if(!player.dead() && !player.unit().spawnedByCore()){ + str += (!str.isEmpty() ? "\n" : "") + Core.bundle.format("respawn", Core.keybinds.get(Binding.respawn).key.toString()); + } + return str; + }).style(Styles.outlineLabel); }).margin(10f); }); @@ -454,7 +447,6 @@ public class DesktopInput extends InputHandler{ buildWasAutoPaused = false; if(isBuilding){ - wasBuilding = player.unit().isBuilding(); player.shooting = false; } } @@ -562,7 +554,6 @@ public class DesktopInput extends InputHandler{ } mode = none; - wasBuilding = true; } if(Core.input.keyTap(Binding.toggle_block_status)){