Breakout
written by Mark Overmars

Goal
A classical game. You have to get rid of all the stones by hitting them with the ball. Some stones though have some surprises.

Playing
Move the bat left and right using the mouse. (The mouse must be inside the window!) You can change the direction of the ball by landing it on the right point on the bat.

Levels
The game has a number of levels. Some later levels might have some surprises. Try to add some levels yourself (and mail them to me).

Design
This whole game was written without using any code, although we need sometimes a bit complicated expressions. Almost all action is in the ball object. It takes action when it meets certain objects. The motion of the bat is controlled in the step action of the left_bat. Note that the bat consists of two parts, because it was too long. One simply stays 32 pixels to the right of the other. The right top wall stone has an additional function in checking whether all stones are gone. Note that the horizontal direction is never changed! To make the ball go left we simply give it a negative horizontal speed. This is nomally the best way when you want to control the movement precisely.