I wanted to experiment with a 3D version of Breakout. The most interesting problem in a 3D version of a 2D game is how to handle the camera as well as the movement controls. I chose to try a version in which the player can control both the camera and the movement of the platform–the arrow keys move the platform on a 2D plane, the “A” and “D” keys move the camera in a circular path around the play area, and the “W” and “S” keys maneuver the camera up and down while focusing on the middle of the play space. If the ball gets stuck in one spot or you wish to reset, press the “c” key.
The platform has an arrow on the top to show the player which way the platform will move when the up arrow key is pressed. It became evident during testing that it is nearly impossible to remember which direction the platform moves in when the camera is rotated so this visual cue helps to serve as a reminder. The physics and controls are not smooth; more tweaking is necessary before the game is enjoyable to play. It might also be interesting to be able to move the platform up and down; it might be difficult to fit that into the existing controls, however.
To play the game, click on the download link below:
The source code is available here: