From 4932d11d7b491d52aa3a7a5a470a6bb59155d1f6 Mon Sep 17 00:00:00 2001 From: Anuken Date: Thu, 3 Jun 2021 18:24:54 -0400 Subject: [PATCH] Misc cleanup --- core/src/mindustry/ai/types/LogicAI.java | 2 +- core/src/mindustry/input/InputHandler.java | 8 ++------ core/src/mindustry/world/blocks/power/PowerGraph.java | 2 +- gradle.properties | 2 +- 4 files changed, 5 insertions(+), 9 deletions(-) diff --git a/core/src/mindustry/ai/types/LogicAI.java b/core/src/mindustry/ai/types/LogicAI.java index 8c1128c7e0..b87a22e217 100644 --- a/core/src/mindustry/ai/types/LogicAI.java +++ b/core/src/mindustry/ai/types/LogicAI.java @@ -15,7 +15,7 @@ import static mindustry.Vars.*; public class LogicAI extends AIController{ /** Minimum delay between item transfers. */ - public static final float transferDelay = 60f * 2f; + public static final float transferDelay = 60f * 1.5f; /** Time after which the unit resets its controlled and reverts to a normal unit. */ public static final float logicControlTimeout = 10f * 60f; diff --git a/core/src/mindustry/input/InputHandler.java b/core/src/mindustry/input/InputHandler.java index f1762ad3fe..cb4ebad970 100644 --- a/core/src/mindustry/input/InputHandler.java +++ b/core/src/mindustry/input/InputHandler.java @@ -448,10 +448,6 @@ public abstract class InputHandler implements InputProcessor, GestureListener{ return !selectRequests.isEmpty(); } - public OverlayFragment getFrag(){ - return frag; - } - public void update(){ player.typing = ui.chatfrag.shown(); @@ -466,8 +462,8 @@ public abstract class InputHandler implements InputProcessor, GestureListener{ wasShooting = player.shooting; //only reset the controlled type and control a unit after the timer runs out - //essentially, this means the client waits for 1 second after controlling something before trying to control something else automatically - if(!player.dead() && (recentRespawnTimer -= Time.delta / 60f) <= 0f && player.justSwitchFrom != player.unit()){ + //essentially, this means the client waits for ~1 second after controlling something before trying to control something else automatically + if(!player.dead() && (recentRespawnTimer -= Time.delta / 70f) <= 0f && player.justSwitchFrom != player.unit()){ controlledType = player.unit().type; } diff --git a/core/src/mindustry/world/blocks/power/PowerGraph.java b/core/src/mindustry/world/blocks/power/PowerGraph.java index bc3b6e2fd8..b510ef2285 100644 --- a/core/src/mindustry/world/blocks/power/PowerGraph.java +++ b/core/src/mindustry/world/blocks/power/PowerGraph.java @@ -49,7 +49,7 @@ public class PowerGraph{ } public float getPowerBalance(){ - return powerBalance.mean(); + return powerBalance.rawMean(); } public float getLastPowerNeeded(){ diff --git a/gradle.properties b/gradle.properties index 13dd3dad98..15c25c41b4 100644 --- a/gradle.properties +++ b/gradle.properties @@ -9,4 +9,4 @@ kapt.use.worker.api=true kapt.include.compile.classpath=false # I don't need to use the kotlin stdlib yet, so remove it to prevent extra bloat & method count issues kotlin.stdlib.default.dependency=false -archash=ef9b29a8978e8f5e2fcba770bfebd210f4bc8117 +archash=ebc24e24e7b60c10a85dff648bd9f592838d40ec