From: Markus Armbruster Date: Sun, 30 Oct 2011 17:46:24 +0000 (+0100) Subject: Make add always reset the country X-Git-Tag: v4.3.29~33 X-Git-Url: http://git.pond.sub.org/?p=empserver;a=commitdiff_plain;h=6984f9d98271e93c382754ed702c3649e7f15bcf Make add always reset the country Before, add reset the country only when adding a player or a visitor. When adding a deity or deleting a country, it set just nat_cnam, nat_pnam and nat_state. Has always been that way. Because of that, a newly minted deity country could inherit all kinds of crap from a previous user of its country number: origin, realms, relations, telegrams, ... Harmless if the country number has never been used before, which is how add is generally used. When adding a deity country, initial levels (start_education, ...) now apply, relations start NEUTRAL instead of AT_WAR, and the usual initial nation flags are set. Reset on delete as well, just to get rid of the special case. --- diff --git a/src/lib/commands/add.c b/src/lib/commands/add.c index 6bb4fdc6b..eb8a55417 100644 --- a/src/lib/commands/add.c +++ b/src/lib/commands/add.c @@ -112,12 +112,7 @@ add(void) } strcpy(natp->nat_cnam, cntryname); strcpy(natp->nat_pnam, pname); - if (stat == STAT_NEW || stat == STAT_VIS) - nat_reset(natp, stat, 0, 0); - else { - natp->nat_stat = stat; - pr("No special initializations done...\n"); - } + nat_reset(natp, stat, 0, 0); putnat(natp); return 0; }