Wednesday, October 27, 2010

14 – Slowly getting there

I did a massive cleanup round on the code. I am not going to bore you with talking about that, but while reorganizing code, I also found myself reorganizing and sometimes setting in stone for the first time the rules of the world. So, without further a due, here are a few key points:
1.       Climate determines the general rules
Every single map, and thus every single game, will have a single climate that does not change during game play. At first, you will select it from a list, but later I’m hoping in having and over world map generator that allows you to visually pick a sub region to your liking, part of a larger and believable world.
Climate influences the flora, fauna, temperature, water evaporation and other aspects that I’ll determine as things progress. Anyway, maps with different climate should play differently. The biggest change is that you will have access to different sets of plants. Maybe in one climate you will not have any edible plants (except the ones you grow in caves), but you will use them to set up an industry and import other kinds of plants. Or the other way around, having an abundance of food, but nothing that can be used in the industry. Or very rich resources, but full of wild and dangerous mega-cats that will eat you up. Yumm!!!!
2.       There are four seasons
Every climate has four seasons, even if there is little difference between them for some climates. Seasons will change at a fixed date and their effect will be felt instantly. Plants will appear and die govern by these dates. Having dynamic dates for season change is not planned for the near future.
3.       There is a maximum number of plants that will inhabit the world naturally
Think of it as having a hidden variable that governs fertility.  An area that is left untouched by civilization for a long time will be quite a wild place where nature rules, but there is a natural limit.
4.       Plants grow in larger surges
Plants will not appear one by one, but will appear in larger groups. This usually happens at a season change, when the temperature rises and seeds from within the soil give life to new plants. Or if the plants thrive for multiple seasons, they will cause another surge, simulating a surge of multiplication after an extended period of time when conditions where good for supporting life.
Surges are not big enough to reach the plant limit too soon. So if you do massive harvesting operations, leaving the world barren, I will take multiple years for all the plants to multiply and reach the levels you found them. Harvesting small numbers of plants will allow them to grow and maintain a relative balance in their number.
5.       Trees will grow out of tree stumps if available
Trees follow the same rules as the rest of the plants, but they have a much slower growing rate. Cutting them down will leave stumps, and new sprouts can appear from here. Or maybe the trees will appear in other new spots.
This is the first patch of rules that governs flora. This is mostly implemented, but I still need a session or two to give it the last touches. And it sure loves to be touched! Let me add a picture or two to distract you from the block of text. Here are a few tree stumps left by cutting them down:

And here we can see a very ugly bluish effect in winter on plants just after the snow has set. This is supposed to be the snow that has set on the plants:


You may also notice that some trees have changed between the first and the second screenshot. These are deciduous trees:

The split into three packages of the project is also done, so here are the statistics in a new format:
Statistics S30:
DHCore: 1354 lines / 33.3 KiB / 6 files
DH: 2065 lines / 56.4 KiB / 12 files
DHEditor: 518 lines / 13.7 KiB / 11 files
Total: 3937 lines / 103.4 / 29 files

No comments:

Post a Comment