TopoMC: Minecraft Worlds From Real Data

What is TopoMC?

The TopoMC project facilitates the construction of superficially realistic Minecraft worlds leveraging data from the USGS, specifically the NED and NLCD datasets.

This project relies heavily on pymclevel and to a lesser extent on c10t. The accelerated NBT module in pymclevel really makes a difference!

Sample image of Block Island, RI

Recent changes

Showcase

The following examples were selected as representative of various types of region: cities, natural features, water-related regions, and 'exotic' (i.e., outside the contiguous US) locales.

Region Image GetRegion.py Arguments
SanFrancisco--ymax 37.8238 --xmin -122.55 --ymin 37.7003 --xmax -122.344 --sealevel 32 --maxdepth 16
World file
Map link
Boston--ymax 42.3846 --ymin 42.3119 --xmin -71.1032 --xmax -70.9824
World file
Map link
NewYorkCity--ymax 40.8846 --ymin 40.6763 --xmin -74.069 --xmax -73.890
World file
Map link
Yosemite--ymax 37.7597 --ymin 37.7196 --xmin -119.6112 --xmax -119.5445 --scale 15 --vscale 15 --trim 1201 --sealevel 2 --maxdepth 1
World file
Map link
MeteorCrater--ymax 35.0406 --ymin 35.0106 --xmin -111.0353 --xmax -111.0102 --scale 2 --vscale 2 --trim 1562 --sealevel 8 --maxdepth 4
World file
Map link
Yellowstone--ymax 44.634 --ymin 44.331 --xmin -110.995 --xmax -110.652 --trim 2034 --sealevel 4 --maxdepth 2
World file
Map link
LakeTahoe--ymax 39.282 --ymin 38.895 --xmin -120.190 --xmax -119.869 --scale 15 --vscale 15 --trim 1415 --sealevel 2 --maxdepth 1
World file
Map link
CraterLake--ymax 42.9986 --ymin 42.8917 --xmin -122.189 --xmax -122.037 --scale 12 --vscale 12 --trim 1607 --sealevel 16 --maxdepth 8
World file
Map link
BlockIsland--ymax 41.2378 --ymin 41.1415 --xmin -71.6202 --xmax -71.5332
World file
Map link
Arecibo--ymax 18.3495 --ymin 18.3391 --xmin -66.7578 --xmax -66.7462 --scale 3 --vscale 3 --trim 136 --sealevel 16 --maxdepth 8
World file
Map link

Example

Here's how to do it yourself, using Provincetown as an example:

Retrieve the region from the USGS.
./GetRegion.py --name Provincetown --ymax 42.0901 --xmin -70.2611 --ymin 42.0091 --xmax -70.1100
Prepare the region for building.
./PrepRegion.py --name Provincetown
Build the region!
./BuildRegion.py --name Provincetown
(optional) Build a map of the region.
./BuildMaps.py --name Provincetown

Options

Different users have different goals. Whether you want a Minecraft world you can actually play in, or whether you want to re-create a real-world area as accurately as feasible, there are ways to improve your results.

The GetRegion.py command has a number of optional arguments which can be used to improve the quality of results.

Tile size can be changed.
The default tile size is 256x256, but it can be changed. The only requirement is that it be a multiple of 16 (the chunk size). An example would be "--tilesize 64".
Horizontal and vertical scaling can be changed.
The horizontal and vertical scale, both of which default to 6, can be changed independently. The minimum horizontal scale is 1 with a practical maximum of 30. The minimum vertical scale is more complex, and essentially depends on the elevation change between the highest point in the region and sea level. An example scale would be "--scale 1 --vscale 1". Should the requested scale exceed valid parameters, the software will adjust the scale after informing the user.
Sealevel and maximum depth can be changed.
Sometimes the minimum vertical scale is too high. One way to improve this situation is to lower the sealevel from its default of 64 to something lower such as 16 or 8. The maximum depth should also be lowered as well. Keep in mind that this may have unexpected effects on ore distribution! An example sealevel and maximum depth would be "--sealevel 16 --maxdepth 8".
Elevation can be trimmed!
When lowering the sealevel isn't enough to reach your desired vertical scale, excess elevation can be trimmed. Elevation is considered excess if it is between sea level and the lowest point on the region. For example, if a region were selected such that its surface was between 200 and 300 meters above sea level, the 200 meters between sea level and the lowest point on the region could be trimmed. An example trim would be "--trim 200". If the trim value requested exceeds the valid limits, the software will adjust the trim value to the maximum allowed after informing the user.

License

TopoMC is open source under the MIT license and the source can be found at https://github.com/mathuin/TopoMC.


Jack Twilley <mathuin at gmail dot com>