In this chapter we cover the following:
Creating programmer-defined objects
Using setInterval for animation
Drawing images
Accepting and validating form input
Using buttons
Using for loops
Drawing with gradients
Preloading images
Introduction
Animation
, whether at the movies, using a flipbook, or generated in a computer game, involves displaying a sequence of still images fast enough so that we interpret what we see as movement as life. In this chapter, I’ll show you how to produce animated scenes by simulating a ball bouncing in ...