From 8bee148209325f997bc8dff7d8f6e1b8da0b8644 Mon Sep 17 00:00:00 2001 From: Q Date: Sat, 18 Mar 2023 22:06:48 +0800 Subject: [PATCH] fix random value float --- .../src/main/java/com/cleveroad/audiovisualization/Utils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/src/main/java/com/cleveroad/audiovisualization/Utils.java b/library/src/main/java/com/cleveroad/audiovisualization/Utils.java index a1e3365..320ff2c 100644 --- a/library/src/main/java/com/cleveroad/audiovisualization/Utils.java +++ b/library/src/main/java/com/cleveroad/audiovisualization/Utils.java @@ -99,7 +99,7 @@ public static float quad(float t, float p0, float p1, float p2) { } public static float randomize(float value, Random random) { - float perc = between((random.nextInt(100) + 70) / 100, 0.7f, 1.3f); + float perc = between((random.nextInt(100) + 70) / 100f, 0.7f, 1.3f); return perc * value; }