Hi Everyone! I've been working on a new coding project that would allow for the generation of a completely new geoscape with just a few clicks! It's in an alpha state right now, so it only can generate a new look for the globe, not also a corresponding set of regions, countries, cities, etc. - those things will come with time.
The globe is generated in a method similar to the fractal world generator at
http://donjon.bin.sh/, creating a series of polygons and giving them a texture according to their altitude; the generated globe ruleset file is saved in user/xcom1/geoscapeGeneratorOutput.yml, and can be used directly in a mod if renamed to .rul. If you'd like to try out the code, the source is available at
my GitHub page, or I've attached a .zip file with a self-contained installation of the executable for Windows or Ubuntu 16.04. To install from the archive attached here, unzip it somewhere on your computer, copy the files from the original X-Com into the UFO folder, and then run the executable that applies for your OS.
I'm also looking for some help with this project, as there are a couple issues that I only have half-formed ideas how to solve:
- Some of the polygons around the 0/360 longitude line do not have their vertices ordered properly on output, so they look like a series of triangular lakes.
- Having enough polygons to make a decent looking globe often causes to game to slow down; I'm looking for a way to optimize the number of polygons by combining those that share a texture in contiguous areas without sacrificing the detail along borders between textures.
- I need tectonic and climate models to flesh our how textures are assigned - right now they're assigned by altitude and proximity to poles, but this doesn't work well for making deserts, mountain ranges, archipelagos, fertile regions, etc.
- Defining continents, countries, and cities, with proper borders - I have a few plans for how to do this, but it will take some time.
- Interfaces and designing an editor for globe rulesets. More of a stretch goal, but I think it'd be really cool if it was possible to edit the globe in-game, either just tweaking Earth or doing more complicated things with a generated world.
And now for some examples of globes I've generated using this code!