Removed the need of @OPENDUNGEONS_MEDIA_DIR@ + misc things.

I also added the missing octree debug plugin and remove various useless lines.

Part of #367