Add randomInt()

This commit is contained in:
Eryn Wells 2023-02-03 18:02:10 -08:00
parent b8ac3126da
commit a283cae416

View file

@ -319,6 +319,11 @@ class BSPNode {
}
}
function randomInt(n) {
max = Math.floor(n);
return Math.floor(Math.random() * max);
}
let grid;
new p5(p => {