loadTemporaryWorldWithGenerator
public static World loadTemporaryWorldWithGenerator(String worldName, World.Environment environment, ChunkGenerator generator)
Loads a temporary world using a caller-supplied ChunkGenerator instead of the built-in void generator. Post-load settings mirror loadVoidTemporaryWorld: spawn not kept in memory, difficulty HARD. The world folder is expected to already exist on disk (the caller is responsible for copying a template if needed) — matching the existing void-world contract.
Return
the loaded World, or null on failure
Parameters
worldName
unique world folder name under getWorldContainer
environment
nether / end / normal
generator
the ChunkGenerator responsible for producing surface blocks