+2

How to create multiple circle in cavas with animations for each circle?

Please check my canvas code https://code.sololearn.com/WPIj75OHxZRv/?ref=app

3/24/2020 3:11:39 AM

ŚĄŃ

3 Answers

New Answer

+2

Use object-oriented programming. So that each circle has its own position property. Store the circles in an array and loop over the array in each interval. If to edit your code, add this. before the properties in circle() And use new circle to create new circle use push to add new circle to a global array.

0

https://code.sololearn.com/WZ7Ru0JhBJa5/?ref=app