+ static getRandomFloat(max, min = 0) {
+ return Math.random() < 0.5 ? (1 - Math.random()) * (max - min) + min : Math.random() * (max - min) + min;
+ }
+
+ static getRandomInt(max, min = 0) {
+ if (min) {
+ return Math.floor(Math.random() * (max - min + 1) + min);
+ }
+ return Math.floor(Math.random() * max + 1);
+ }
+
+ static roundTo(number, scale) {
+ return Utils.convertToFloat(number.toFixed(scale));
+ }
+
+ static getRandomFloatRounded(max, min = 0, scale = 2) {