ENTER_FRAME Event Listener

Adjust the Speed

Theoretically, this thing is moving 24 pixels per second (in actuality, it's not quite that accurate, but it's close enough). You can experiment with different speeds by using Stage properties to modify the Frame Rate:

Don't do that though! Leave the Frame Rate at 24fps, please. If we want to speed up the ball, let's make it move 4 pixels instead of 1:

ball1.y += 4;

Now watch it zip right off the screen:

Content on this page requires a newer version of Adobe Flash Player.

Get Adobe Flash player