cWorld: Rewritten spawn preparation.

It now supports pregeneration distance of any size and runs in two threads in parallel (generator / lighting).
Fixes #1597.
The Java conventions are strange to me.