Pre-Order the Game!

Desura Digital Distribution

Wednesday, April 6, 2011

Planets and Production

I've implemented population growth/dying processing. How it works is this: It calculates the normal population growth, factoring in remaining space, and current population. It then calculates any extra population growth from food surplus, or negative growth if food supply is lower than population count. It adds both (note, the population growth from food is higher on per-unit basis than normal growth, so starvation can easily outpace population growth), then add the total to population. If population drops below 0.1, the planet has died off and you lose control on the planet.

Now for pollution. If it's above the cleanup efforts, the planet's population capacity (i.e. max population of 100) will drop. You can fix this by increasing the cleanup so it exceeds the pollution. This slider will also act as terraforming when you get appropriate technologies. Pollution don't affect the planet's capacity right now however.

After some deliberating, I've decided to remove the infrastructure part of the planet. All output will be direct from population. So the more people you have, the better. This is similar to Master of Orion 2 where you allocate people to different fields. But there won't be any special buildings to build that enhances your output. There will be technologies that automatically increase your output however. This will make things simpler and less confusing, both on user's end and developer's end.

There's three more items that I would like to see completed before I release the next version. Those are:
Influence maps for computing which planets to migrate to
Migration code (calculating how much people migrate from a planet, and how much will arrive at a planet)
Ship construction UI/code

When the three items are done, then we'll be back at where I started refactoring. The old version had construction and colonization. Then I'll start focusing on research and ship designs :D


  1. Dropping infrastructure? :(

    I've been playing the MoO 1 recently and I've noticed how fast the concept of pollution is pushed out of play. Initially you have to spend 50% of your production on cleaning up the waste. At tech level 5 (construction and planetology, 400 RP each), with reduced waste 80% and improved eco restoration that spending is almost halved, 27%. With enhanced eco restoration (level 13 planetology) and higher tech, pollution becomes negligible. In the MoO 2 pollution is much more serious but, also it's killed by relatively early tech (atmosphere renewer).

    The problem in both cases is that pollution clean up rate is proportional with pollution generation rate. In Zvjezdojedac I had similar issue with mining, more industry per population meant more mining per pop. It was exactly like this: mining per pop = (ind per pop) * (1 + mining rate). To keep mining relevant through whole game, I've separated mining rate from industry. So if you have 10 ind per pop and 5 minerals per pop, you'll need 2 miners per ind worker which is effectively 10/3 ind per pop. If you improve industry and leave mining as is, you'll still have 5 minerals per pop. Asymptotically with X minerals per pop and infinite ind per pop, effectively you'll have at most X ind per pop.

    So, how did you planned to implement pollution?

  2. With pollution, each field (aside from waste management) will generate a set amount of pollution. This will never change. Commerce and Research will generate less pollution than Agriculture and Construction. If you research a technology that increases your construction output, the pollution output will match the output. So for example, if you have 10 units in construction, you generate 10 units of pollution. Researching an improvement increases from 10 to 20 units of construction. But now you also have 20 units of pollution. So now you have to do double the pollution cleanup for the same amount you're putting in for construction.

    So pollution will be a constant factor, and will impact your planet directly if you don't clean it up. It will never be eliminated. You can research improvements to cleanup, but since the other fields will keep increasing output, it won't "go away".

    Infrastructure was getting a bit tricky. If a planet's carrying capacity is reduced through pollution or biological weapons, how much infrastructure should be on it? In MoO 1, you can eliminate pollution, there's no farming, and factories automatically generate income. In this, you can't eliminate pollution, and you have to allocate output to agriculture and commerce. So if you have an expensive fleet, you'll have to allocate more into commerce to pay for maintenance. Plus, the population growth is a bit slower than in MoO 1. I think it all balances out.

  3. What I'm talking about is pollution clean up, not pollution generation. In MoO 1 and 2 pollution cleaned up by unit of population or BC is proportional to production rate of same pop unit/BC. If you improve production rate by 50%, your pollution clean up rate is also improved by 50%.

    For exapmle, in MoO 1 10 factories, by default, produce 10 BC worth production, 10 pollution units and clean up 20 pollution units. By adding another 10 factories, you get 20 BC production, 20 units of pollution and can clean up up to 40 units. Same thing is in MoO 2 after first 10 units of production, for every two hammers, there is one barrel of waste. So if you produce more hammers per pop, you also clean up more barrels per pop.

    My question is, will pollution clean up rate in Beyond Beyaan be proportional with pollution generation rate or not?

  4. No, I thought that was clear. Each field is independent of each other. "Waste Management" is independent of other pollution generating fields. Let's say that 10 units of Waste Management cleans up 10 units of pollution, and we have 10 units in construction generating 10 units of pollution. Both are even, so it's clean.

    But if I research a tech that improves construction output, so that 10 units of construction now outputs 20 "hammers" or whatever, it also outputs 20 pollution. We'll need to increaase our "Waste Management" to 20 units to clean up 20 units of pollution. But if we research a tech that improves waste management so it cleans up 2 units of pollution per 1 unit, we can reduce it back to 10 units.

    So if you research too much improvements without improving waste management, most of your resources would be devoted to waste management. Each field can be improved, but each field is independent of each other. Improved construction output will not improve research output or commerce output.