View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003655 | Dwarf Fortress | World Generation -- Beasts | public | 2010-11-17 10:05 | 2014-03-30 12:24 |
Reporter | rephikul | Assigned To | |||
Priority | low | Severity | minor | Reproducibility | always |
Status | acknowledged | Resolution | open | ||
OS | Windows XP Service Pack 3 | ||||
Product Version | 0.31.18 | ||||
Summary | 0003655: Integer overflow causes Null Pop Num error when creating worlds using very high beast pop cap | ||||
Description | I tried to make worlds with high POPULATION_NUMBER and some creatures are reported to have null pop num, probably because of overflow maybe? The game doesnt crash and legend still report such and such animals populated although the amount is tad random. One example that stuck out: mandrill has pop cap set to 20000:50000, got a "mandrills: Null Pop Num" error but legend report world wide population of 150. An another example is rhesus which got two errors in one single world gen. On the other hand floating guts [POPULATION_NUMBER:250000:500000] didnt show up at all during the tests. The reproducibility of this error on an exact species is random however the chance of it showing up at all during world gen is extremely high. | ||||
Steps To Reproduce | 1) Change [POPULATION_NUMBER:<min>:<max>] of as many creatures as possible to 10000x fold i.e. 20:50 -> 20000:50000 2) Start DF, create a new world 3) Check error log | ||||
Additional Information | Amount of tests run: 7 Reproducibility Result: 7/7 Amount of "null pop num error"s each world gen: handsful | ||||
Tags | No tags attached. | ||||
|
Later testing show that this error only show up if the creature has pop somewhere above 30k. Considering 2^15 = 32768, this is most certainly an overflow related issue. Strangely enough very high popped creatures (250k:500k range) very rarely got this error. |
|
I can confirm (via disassembly) that the min and max values are both 16-bit. |
Date Modified | Username | Field | Change |
---|---|---|---|
2010-11-17 10:05 | rephikul | New Issue | |
2010-12-02 13:50 | rephikul | Note Added: 0014373 | |
2010-12-02 14:43 | Quietust | Note Added: 0014375 | |
2012-03-06 09:30 |
|
Summary | Null Pop Num error on some beasts when creating worlds using very high beast pop cap => Integer overflow causes Null Pop Num error when creating worlds using very high beast pop cap |
2014-03-30 12:24 |
|
Assigned To | => user11 |
2014-03-30 12:24 |
|
Status | new => acknowledged |