From 8b6fc7f3acbd6e64430ef77dfb8e3fef3994b6cb Mon Sep 17 00:00:00 2001 From: Anuken Date: Fri, 27 Nov 2020 12:27:56 -0500 Subject: [PATCH] Fixed #3628 --- core/src/mindustry/ui/Bar.java | 3 +++ gradle.properties | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/core/src/mindustry/ui/Bar.java b/core/src/mindustry/ui/Bar.java index 8e3bd511de..8051b67678 100644 --- a/core/src/mindustry/ui/Bar.java +++ b/core/src/mindustry/ui/Bar.java @@ -78,6 +78,9 @@ public class Bar extends Element{ lastValue = computed; } + if(Float.isNaN(computed)) computed = 0; + if(Float.isInfinite(computed)) computed = 1f; + blink = Mathf.lerpDelta(blink, 0f, 0.2f); value = Mathf.lerpDelta(value, computed, 0.15f); diff --git a/gradle.properties b/gradle.properties index e5c7e5fe4d..e7a780230e 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1,3 @@ org.gradle.daemon=true org.gradle.jvmargs=-Xms256m -Xmx1024m -archash=7a2a357f6cfdc3725ce581093a0ced91f4474222 +archash=989a78688268c97cb3baa9e3342c6f44d6738427