Nouvelle formation ! Tous les codeurs devraient apprendre l'IA générative !
Essayez une leçon gratuite+ 5
[Solved] Q. Why does the ball stops after moving once.
I want to set up a loop with the ball but its not moving constantly. https://code.sololearn.com/WaDnPDXVt40R/?ref=app
3 Réponses
+ 3
Instantiate the ball outside of the setInterval method.
With your code as is, a new ball is created every 1000/60 ms.
+ 4
Thanks ODLNT 🤗🤩
+ 2
No prob..., keep up the good work! 👍