this is the working terrain generator. It is neither optimized, nor cleaned up.