If option RES_POP is enabled, the power factor is multiplied by a
"research factor" of 1.0 + maxpop / 10000.0, where maxpop is the
maximum population of a mine sector.
Back when this code was written (Chainsaw 3), all sectors had the same
population limit, so using a mine sector was as good as any. Since
then, it has become configurable, and the stock game has both sector
types with lower (mountains, plains) and with higher (cities)
population limits.
Space for people is worth considering for power, but multiplying total
power by a fudge factor based on the most common sector type's maximum
population is silly. Drop it.
Adjusting each sector's value for maximum population would make more
sense, with and without RES_POP. Perhaps later.
Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
(guns / 2.5) + (lcms / 10) + (hcms / 5))
power factor += ((number of sectors * (average sector effic / 100)) * 10)
power factor = ((power factor) * (nation tech level / 500))
-power factor = ((power factor) * (research factor))
.FI
.s1
-The research factor is either 1, if RES_POP is not being used, or 1+(max
-pop in a sector)/10000, if it is being used.
-.s1
.SA "census, nation, Communication, Nations, Diplomacy"
f_ptr++;
}
}
- for (i = 1; i < MAXNOC; i++) {
- struct natstr *np;
- int maxpop;
-
- if (opt_RES_POP) {
- np = getnatp(i);
- maxpop = max_population(np->nat_level[NAT_RLEV], SCT_MINE, 0);
- powbuf[i].p_power *= 1.0 + maxpop / 10000.0;
- }
- }
qsort(&powbuf[1], MAXNOC - 1, sizeof(*powbuf), powcmp);
if (!save)
return;