update scoresaber me/user command to show raw per global
All checks were successful
Deploy to Dokku / docker (ubuntu-latest) (push) Successful in 1m12s

This commit is contained in:
Lee
2024-07-05 20:44:43 +01:00
parent bef2b695f5
commit bb81c098b2
12 changed files with 400 additions and 68 deletions

View File

@ -24,4 +24,28 @@ public final class MathUtils {
).format(number)
);
}
/**
* Clamps a value between a minimum and maximum.
*
* @param value The value to clamp.
* @param min The minimum value.
* @param max The maximum value.
* @return The clamped value.
*/
public static double clamp(double value, double min, double max) {
return Math.max(min, Math.min(max, value));
}
/**
* Linearly interpolates between two values.
*
* @param a The first value.
* @param b The second value.
* @param t The interpolation value.
* @return The interpolated value.
*/
public static double lerp(double a, double b, double t) {
return a + t * (b - a);
}
}