fix: off-by-one

This commit is contained in:
cha0s 2019-05-26 14:55:24 -05:00
parent b336a33727
commit fb781dc955

View File

@ -18,7 +18,7 @@ export class Globals {
}
randomNumber(min, max, floor = true) {
let mag = Math.random() * (max - min);
let mag = Math.random() * ((max - min) + 1);
return min + (floor ? Math.floor(mag) : mag);
}