This wiki has been moved to into the mediawiki branch.

Collision test app

From SuperTux
Jump to: navigation, search

You can download the example application here:

For compilation you need to have SDL and SDL_gfx installed.

It demonstrates point-rectangle-, rectangle-rectangle-, point-polygon-, and rectangle-polygon-sweep-tests. You can set start and end-points with the left and right mouse button. With q you can change the shape we collide with from polygon to rectangle. With p you switch to point-tests, with r to rectangle tests. The startpoint is marked green, the endpoint blue and an eventual collision point white.