Build an animation of randomly appearing squares.
Parameters:
-Width of the canvas
-Height of the canvas
-Number of width divisions (frames)
-Number of randomly generated squares before moving to the left
-Limits of square height (minimum height, maximum height)
-Speed of generating new square (aka 1s)
-Colors of squares (palete of 5 colors)
Canvas is horizontal divided into frames. Animation starts by fading randomly high squares on randomly selected frame inside canvas. When certain number of squares is generated the whole frames are moved one frame to the left. First frame from the left is deleted and new frame appears on the right side of the canvas. Then another bunch of squares are generated fitting into random frames (the old frames and the new frame). And the process repeats itself indefinitely. The animation should be smooth no sudden appearance or transitions.
Technology: HTML5 canvas