BSPMapGen: major cleanup / refactor