+ 2
30th Mar 2020, 4:54 PM
rawaha. pool
rawaha. pool - avatar
10 Answers
+ 3
Gordon Why enclosing the whole IIFE in one more function block? Rather assign the anonymous function to the onload event by removing the outer round brackets: ;(function() { /*...*/ })(); would becomes: onload = function() { /*...*/ }
31st Mar 2020, 4:54 AM
visph
visph - avatar
+ 2
TRY THIS and your code very amazing How to learn please tell me? For diffrent color You use in fillStyle --------------- ctx.fillStyle = "hsl("+color+"+100%+50%)"; Color = 360*Math.random(); color++; ---------
1st Apr 2020, 6:31 AM
SAN
SAN - avatar
+ 1
The scripts in JS tab runs before the scripts in HTML tab, so the getElementById("bubble") returns null because at that time the element has not been rendered yet. https://www.sololearn.com/post/90825/?ref=app Enclose your whole IIFE in a window.onload anonymous function code block. https://code.sololearn.com/WY1UbAX3fpJ8/?ref=app
30th Mar 2020, 4:59 PM
Gordon
Gordon - avatar
31st Mar 2020, 3:05 PM
SAN
SAN - avatar
31st Mar 2020, 3:06 PM
SAN
SAN - avatar
+ 1
Hey! Aditya bro let me know if you have any solutions for this. I just want the balls to not merge! And only three ball rotating . All of them should be of different color. :) let me know if you got any solutions for that.. https://code.sololearn.com/Wg5dYODFYJn2/?ref=app
31st Mar 2020, 3:36 PM
rawaha. pool
rawaha. pool - avatar
0
Thank you very much Visph !
31st Mar 2020, 4:57 AM
rawaha. pool
rawaha. pool - avatar
0
visph good way too 👍
31st Mar 2020, 11:34 AM
Gordon
Gordon - avatar
0
Thanks Gordon!
31st Mar 2020, 11:44 AM
rawaha. pool
rawaha. pool - avatar
0
Bro can you please send me the code?
1st Apr 2020, 6:35 AM
rawaha. pool
rawaha. pool - avatar