Perf improvements on level generation.

Next step would be to save the results with their difficulty, so we
don't need to regenerate, just parse.