Remove random values that have no effect
This commit is contained in:
parent
46b4eaf7c5
commit
e0bc4d4ff9
@ -168,9 +168,6 @@ class GeneratedShape {
|
|||||||
this.radius = random(120, 140);
|
this.radius = random(120, 140);
|
||||||
this.rotAngle = radians(360 / this.edges);
|
this.rotAngle = radians(360 / this.edges);
|
||||||
|
|
||||||
this.randomX = random(-77, 77);
|
|
||||||
this.randomY = random(-77, 77);
|
|
||||||
|
|
||||||
this.destX = random(canvasWidth);
|
this.destX = random(canvasWidth);
|
||||||
this.destY = random(canvasHeight);
|
this.destY = random(canvasHeight);
|
||||||
|
|
||||||
@ -250,9 +247,9 @@ class GeneratedShape {
|
|||||||
|
|
||||||
for (let i = 0; i < this.edges; i++) {
|
for (let i = 0; i < this.edges; i++) {
|
||||||
this.startXs[i] =
|
this.startXs[i] =
|
||||||
this.centerX + cos(radians(this.rotAngle)) * this.radius + this.randomX;
|
this.centerX + cos(radians(this.rotAngle)) * this.radius;
|
||||||
this.startYs[i] =
|
this.startYs[i] =
|
||||||
this.centerY + sin(radians(this.rotAngle)) * this.radius + this.randomY;
|
this.centerY + sin(radians(this.rotAngle)) * this.radius;
|
||||||
this.rotAngle += 360 / this.edges;
|
this.rotAngle += 360 / this.edges;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user