fix bug and further cmts
This commit is contained in:
parent
0c3d97fb78
commit
9c8424d67c
|
@ -14,15 +14,18 @@ function preload() {
|
||||||
function setup() {
|
function setup() {
|
||||||
setVRBackgroundColor(200, 200, 200);
|
setVRBackgroundColor(200, 200, 200);
|
||||||
noStroke();
|
noStroke();
|
||||||
|
|
||||||
|
//calculate random positions for trees
|
||||||
for(let i=0; i<iteration; ++i) {
|
for(let i=0; i<iteration; ++i) {
|
||||||
randomX[i] = random(-175, 175);
|
randomX[i] = random(-175, 175);
|
||||||
randomY[i] = random(-175, 175);
|
randomY[i] = random(-175, 175);
|
||||||
randomS[i] = random(15, 20);
|
randomS[i] = random(15, 20);
|
||||||
}
|
}
|
||||||
createTree();
|
|
||||||
angleMode(DEGREES)
|
|
||||||
rn = random(1,1000)
|
|
||||||
|
|
||||||
|
angleMode(DEGREES)
|
||||||
|
|
||||||
|
//random seed for each respawn
|
||||||
|
rn = random(1,1000)
|
||||||
}
|
}
|
||||||
|
|
||||||
function draw() {
|
function draw() {
|
||||||
|
|
Loading…
Reference in New Issue