+ 9

How can I make those circles animate ?

I want to make these circles appear from top and then going into bottom with in a stipulated time like in this code https://code.sololearn.com/Wm198S0Ra8Xc/?ref=app. How can I acheive it using pure js ?? My try : https://code.sololearn.com/WDlQoQDaOsVz/?ref=app

19th Dec 2018, 12:08 AM
Arushi Singhania
Arushi Singhania - avatar
6 Answers
+ 8
I tried to modify your canvas, added Ball class, initiatiated 100 balls at above screen positions and animate them downwards by using requestAnimationFrame function https://code.sololearn.com/W0Fz9EoQPHt3/?ref=app
19th Dec 2018, 1:50 AM
CalviÕ²
CalviÕ² - avatar
+ 29
By Using Animate Elements !
20th Dec 2018, 10:26 AM
KĶœĶ”É©nÉ¢ćƒ»ļ¾‘ļ½šiļ½ši šŸ–¤
KĶœĶ”É©nÉ¢ćƒ»ļ¾‘ļ½šiļ½ši šŸ–¤ - avatar
+ 7
Thx Toni Isotalo , CalviÕ² and Gordon for Ur answers.
19th Dec 2018, 6:12 PM
Arushi Singhania
Arushi Singhania - avatar
19th Dec 2018, 1:24 AM
Toni Isotalo
Toni Isotalo - avatar
+ 5
It's really good to see you progressing, Arushi. While Calvin's example code specially coded for you is sufficient to solve your problem for one time, I recommend you still go through this step-by-step tutorial by 怌ļ¼Øļ¼”ļ¼°ļ¼°ļ¼¹ ļ¼“ļ¼Æ ļ¼Øļ¼„ļ¼¬ļ¼°ć€for more understanding on loop. https://code.sololearn.com/Wpd4P6GX7jUF/?ref=app
19th Dec 2018, 4:49 AM
Gordon
Gordon - avatar