From 57c642ca06d3f0c4772f960e3a2e06f8f2518b4d Mon Sep 17 00:00:00 2001 From: blue Date: Mon, 19 Nov 2018 11:02:38 +0300 Subject: [PATCH] circle radius randomization fix --- painting/circle.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/painting/circle.js b/painting/circle.js index 85ff14d..09f9ff8 100644 --- a/painting/circle.js +++ b/painting/circle.js @@ -13,7 +13,7 @@ class Circle extends Shape { static randomOptions() { let opts = super.randomOptions(); - opts.r = Math.floor(Math.random() * (this.maxY / 2 - opts.x)); + opts.r = Math.floor(Math.random() * (this.maxY / 2)); return opts; }