Metternich Engine
Posted: Thu Oct 06, 2022 8:53 pm
Hello! I am working on an open-source engine to develop games in the style of Imperialism. This is engine is called Metternich, and I am creating this post to share the progress as I develop it.
The engine is written in C++, with Qt being used for the UI. It is still in the very early stages.
Right now I am working on converting (public domain) geodata into game maps, in order to create the first scenario. This allows for maps based on the real world to be created efficiently, and then they can be touched up manually as necessary.
I have already implemented support for using geodata to create province maps for the game. The area of the world represented by the map is completely configurable:
I am using a 1024x512 Earth map, which allows as much detail for Europe as in Imperialism, but with the rest of the world also being represented on the map. But if we wanted to have a smaller map, or one representing only a smaller portion of the globe, then we could simply change those fields and the province map would be generated accordingly (for example, if we wanted to have a smaller map covering only Europe as in the original Imperialism scenarios). The map projection can be changed as well.
Here is the province map I have so far:
I added province geodata for the Low Countries, as well as much of Central Europe. And for some other parts of the world as well. Then, I did some minor manual touch-ups to the output, to remove province pixels which were only connected diagonally, and to ensure that all provinces have contiguous territories.
This is still a bit rough - German provinces are too large in some cases, for instance (the geodata I had available for it was mostly only for the modern states). But overall, this is much more efficient than manually creating the entire map from scratch.
The Metternich engine is fully open-source. Here is a link to its repository. And here is the repository for the game data.
The engine is written in C++, with Qt being used for the UI. It is still in the very early stages.
Right now I am working on converting (public domain) geodata into game maps, in order to create the first scenario. This allows for maps based on the real world to be created efficiently, and then they can be touched up manually as necessary.
I have already implemented support for using geodata to create province maps for the game. The area of the world represented by the map is completely configurable:
Code: Select all
earth = {
name = "Earth"
size = { 1024 512 }
world = earth
map_projection = mercator
min_longitude = -180
max_longitude = 180
min_latitude = -60
max_latitude = 71.675
province_image_filepath = "earth/provinces.png"
}
Here is the province map I have so far:
I added province geodata for the Low Countries, as well as much of Central Europe. And for some other parts of the world as well. Then, I did some minor manual touch-ups to the output, to remove province pixels which were only connected diagonally, and to ensure that all provinces have contiguous territories.
This is still a bit rough - German provinces are too large in some cases, for instance (the geodata I had available for it was mostly only for the modern states). But overall, this is much more efficient than manually creating the entire map from scratch.
The Metternich engine is fully open-source. Here is a link to its repository. And here is the repository for the game data.