designate: Drop support for designate costing money

Chainsaw 3 added the designate cost along with extra build cost and
materials, and used both to make fortresses expensive.  Unlike build
cost and materials, the cost to designate didn't pass the test of
time: it was set to zero in Empire 2.  Get rid of it.

sect-chr selector cost and struct dchrstr member d_cost have to stay,
because they're still used to configure whether a sector may be
designated by players (see commit 8d792e1).

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
Markus Armbruster 2016-06-05 19:08:19 +02:00
parent 9d6b3b3520
commit ba2795fbf7
6 changed files with 23 additions and 37 deletions

View file

@ -237,12 +237,12 @@ The \*Qshow\*U command can be used to show special things about sector
types. To check out build costs, you do: types. To check out build costs, you do:
.EX show sect build .EX show sect build
.NF .NF
desig build 100% eff maint build 100% eff maint
sector type $ lcm hcm $ $ sector type lcm hcm $ $
- wilderness 0 0 0 0 0 - wilderness 0 0 0 0
c capital 0 0 0 100 60 c capital 0 0 100 60
f fortress 0 0 100 500 0 f fortress 0 100 500 0
any other 0 0 0 100 0 any other 0 0 100 0
Infrastructure building - adding 1 point of efficiency costs: Infrastructure building - adding 1 point of efficiency costs:
type lcms hcms mobility $$$$ type lcms hcms mobility $$$$
@ -252,8 +252,6 @@ defense factor 1 1 1 1
.FI .FI
.s1 .s1
.in \w'build hcm\0\0'u .in \w'build hcm\0\0'u
.L "desig $"
Cost charged by the designate command.
.L "build lcm" .L "build lcm"
The lcm required to build the sector. The lcm required to build the sector.
.L "build hcm" .L "build hcm"

View file

@ -34,7 +34,7 @@ Note that you cannot re-designate bridge spans.
.s1 .s1
Normally, each point of efficiency added costs you $1. Some sectors Normally, each point of efficiency added costs you $1. Some sectors
may cost more, and some may also require the expenditure of lcms and/or may cost more, and some may also require the expenditure of lcms and/or
hcms from the sector. In addition, some sectors may cost money merely hcms from the sector. See the \*Qshow\*U command and \*Qinfo
to designate. (see the \*Qshow\*U command and \*Qinfo show\*U for details) Sector-types\*U for details.
.s1 .s1
.SA "Sector-types, Sectors" .SA "Sector-types, Sectors"

View file

@ -28,7 +28,7 @@
* *
* Known contributors to this file: * Known contributors to this file:
* Steve McClure, 1998-2000 * Steve McClure, 1998-2000
* Markus Armbruster, 2004-2009 * Markus Armbruster, 2004-2016
*/ */
#include <config.h> #include <config.h>
@ -109,15 +109,6 @@ desi(void)
if (sect.sct_type == SCT_SANCT && !player->god) if (sect.sct_type == SCT_SANCT && !player->god)
continue; continue;
n = sect.sct_type; n = sect.sct_type;
if ((sect.sct_newtype != des) && (sect.sct_type != des)
&& dchr[des].d_cost > 0) {
if (natp->nat_money < player->dolcost + dchr[des].d_cost) {
pr("You can't afford a %s!\n", dchr[des].d_name);
rc = RET_FAIL;
break;
}
player->dolcost += dchr[des].d_cost;
}
if (sect.sct_type != des && (sect.sct_effic < 5 || player->god)) { if (sect.sct_type != des && (sect.sct_effic < 5 || player->god)) {
if (player->god) if (player->god)
set_coastal(&sect, sect.sct_type, des); set_coastal(&sect, sect.sct_type, des);

View file

@ -52,7 +52,8 @@
# column cost, and only to something with the same terrain. All # column cost, and only to something with the same terrain. All
# sectors with the same terrain and non-negative cost should have the # sectors with the same terrain and non-negative cost should have the
# same population limit (column maxpop), or else players can abuse # same population limit (column maxpop), or else players can abuse
# redesignation to mass-murder people. # redesignation to mass-murder people. Other than that, cost has no
# purpose anymore.
# A sector with urban packing (urba in column pkg) is a big city. # A sector with urban packing (urba in column pkg) is a big city.
# Column maxpop applies at 0% efficiency. The limit at 100% is ten # Column maxpop applies at 0% efficiency. The limit at 100% is ten

View file

@ -402,29 +402,25 @@ show_sect_build(int foo)
{ {
int i, first; int i, first;
pr(" desig build 100%% eff maint\n" pr(" build 100%% eff maint\n"
"sector type $ lcm hcm $ $\n"); "sector type lcm hcm $ $\n");
for (i = 0; dchr[i].d_name; i++) { for (i = 0; dchr[i].d_name; i++) {
if (dchr[i].d_mnem == 0) if (dchr[i].d_mnem == 0)
continue; continue;
if (dchr[i].d_mob0 < 0) if (dchr[i].d_mob0 < 0)
continue; continue;
if (dchr[i].d_cost <= 0 && dchr[i].d_build == 1 if (dchr[i].d_build == 1
&& dchr[i].d_lcms == 0 && dchr[i].d_hcms == 0 && dchr[i].d_lcms == 0 && dchr[i].d_hcms == 0
&& dchr[i].d_maint == 0) && dchr[i].d_maint == 0)
continue; /* the usual, skip */ continue; /* the usual, skip */
pr("%c %-21.21s", dchr[i].d_mnem, dchr[i].d_name); pr("%c %-21.21s %5d%5d %5d %5d\n",
if (dchr[i].d_cost < 0) dchr[i].d_mnem, dchr[i].d_name,
pr(" can't");
else
pr(" %5d", dchr[i].d_cost);
pr(" %5d%5d %5d %5d\n",
100 * dchr[i].d_lcms, 100 * dchr[i].d_lcms,
100 * dchr[i].d_hcms, 100 * dchr[i].d_hcms,
100 * dchr[i].d_build, 100 * dchr[i].d_build,
dchr[i].d_maint * etu_per_update); dchr[i].d_maint * etu_per_update);
} }
pr("any other 0 0 0 100 0\n"); pr("any other 0 0 100 0\n");
first = 1; first = 1;
for (i = 0; intrchr[i].in_name; i++) { for (i = 0; intrchr[i].in_name; i++) {

View file

@ -109,12 +109,12 @@
Play#0 input show sect b Play#0 input show sect b
Play#0 command show Play#0 command show
Play#0 output Play#0 1 Printing for tech level '1000' Play#0 output Play#0 1 Printing for tech level '1000'
Play#0 output Play#0 1 desig build 100% eff maint Play#0 output Play#0 1 build 100% eff maint
Play#0 output Play#0 1 sector type $ lcm hcm $ $ Play#0 output Play#0 1 sector type lcm hcm $ $
Play#0 output Play#0 1 - wilderness 0 0 0 0 0 Play#0 output Play#0 1 - wilderness 0 0 0 0
Play#0 output Play#0 1 c capital 0 0 0 100 60 Play#0 output Play#0 1 c capital 0 0 100 60
Play#0 output Play#0 1 f fortress 0 0 100 500 0 Play#0 output Play#0 1 f fortress 0 100 500 0
Play#0 output Play#0 1 any other 0 0 0 100 0 Play#0 output Play#0 1 any other 0 0 100 0
Play#0 output Play#0 1 Play#0 output Play#0 1
Play#0 output Play#0 1 Infrastructure building - adding 1 point of efficiency costs: Play#0 output Play#0 1 Infrastructure building - adding 1 point of efficiency costs:
Play#0 output Play#0 1 type lcms hcms mobility $$$$ Play#0 output Play#0 1 type lcms hcms mobility $$$$