These week, Michi gives you a comprehensive tour of our largest custom development tool: The World & Material Editor. Meanwhile, Martin reports about the true problems in implementing transponder codes for the ships in PU.
There’s a saying that one of the hardest problems in computer science is naming things. And I suppose there’s a at least some truth to that, because this week it took Michi and myself a considerable amount of time to decide on a numbering scheme for ships.
Here’s the thing: We want to give every ship in the universe a unique identifier that stays with it over its whole life-span no matter what happens to it. So once the ship gets built it is assigned a number and even if its owner changes five times before it dies a fiery death, it will keep that initial number until the end. This number, or transponder code as we like to call it, will shop up publicly wherever you can see ships in the game, for example on system maps.
Because we want this number to be identifiable and easy to type, a number consisting of digits only wouldn’t work: It would end up being too long and it would be hard to remember. We thought about adding recognizable components to the identifier - like a country code - but decided against it because it would add unnecessary complexity for such a small feature due to the distributed nature of the game’s backend systems. So in the end, we settled on a five-character, alpha-numeric identifier prefixed by AVI, which stands for APEX Vessel Identifier.
After I implemented the system to generate and assign the transponder codes, I went on to do more polish, clean-up and bug fixing, so nothing too exciting to call home about.
Last week I wrote about the internal tools we are currently developing to create the game world and parts of the game’s content: the material and world editor. For this week’s devlog I decided to show some screenshots and explain a bit what’s going on there. Keep in mind: These screenshots are part of an internal tool, not the game itself!
As I wrote in the last devlog, the previous iteration of the world editor had some shortcomings concerning its interactivity. So in the new one the workflow of creating the universe is divided into a couple of steps. Let’s start with an empty universe:
As you can see a procedural generator puts out a series of hexes that will become sectors (a cluster of star systems) in the game. Changing the parameters results in a different result:
There is a manual mode where sectors can be added or removed by hand to fine tune the outcome. Let’s stick with the second generated map for now and move onto the next step.
In this step a generator creates all stars and connections between them. It makes sure that each star can be reached via at least one connection. With the parameters on the side we can fine tune how the map looks, e.g. how many stars a sector can have, how far apart they are and a few other things. A seed value is used as input for the procedural generator, so changing this value will (just as in the step before) lead to a totally different result.
The list at the bottom shows the total amount of stars of a certain size. M-type stars are the smallest, O-type the largest. The size (mass) of a star influences how the star system is generated.
In the next generation step we can choose the location of the initial colonies of the different factions. We decided to set the locations manually instead of randomly because there are a few constraints that would be hard to implement in code and it is easier to do it manually. One of these constraints is, for example, that the Exodus Council choose the location of its colony at a single well-located star system along very likely trade routes.
As you can see in the screenshot, the names for the colonies of the Castillo-Ito Mercantile Faction are not decided upon yet. If you have a suggestion join the discussion in the forums!
The last generation step is about creating the planets and their resources. I am currently working on this part:
It consists of three sub-steps:
- Generation of all the planets
- Generation of the initial colonies
- Distribution of the resources
The first two steps are almost complete. For each planet various attributes are generated: orbit, surface type, mass, temperature, atmospheric pressure, gravity and a few more.
Since we cannot rely on the procedural generator the create habitable worlds where we decided that the initial colonies should be, we simply generate one in the habitable zone in that system.
As shown in the screenshot, one can select a star and its planets and their attributes are listed. Just as in the steps before a random seed is used to generate the data and can be adjusted on a per system level to re-generate it.
I hope you liked this little glimpse into the tools we write to make Prosperous Universe happen and if you have questions about it or want to know more about something join us in the forums!