Skip navigation

File Link(.exe)


Click Me

The Game


My final is a game that you control a car to dodge obstacles, and the map and obstacles are randomly generated. the control is pretty easy: press “Left” key to make the car move left and go right with “Right”.

The game looks like this:

Capture

Debug Lines


To implement the debug lines, I do the following steps:

1. When the game begins, I create the buffer of debug lines and load the debug line shaders.

2. on each frame before rendering, I clear the debug lines and add new lines to the buffer.

3. Then render the line buffer to display the debug lines.

I added three lines with red,blue and green to indicate x,y,z axis, the lines look like this:

Captur1e

Time estimation


Reading and searching — 1.5 h
Coding / Debugging — 10.5 h
Writing blog — 0.5 h
Total — 12.5 h

Leave a Reply