Represent logged in time in seconds rather than minutes

This simplifies things.  In particular, it gets rid of random rounding
in getcommand(), which created a variation in the nightly build
depending on whether the update starts before or after the deity logs
out.

Replace struct natstr member nat_minused by nat_timeused, and update
cou_ca[] accordingly (this affects xdump nat).  Replace player member
minleft by timeleft, and getminleft() by gettimeleft().  Update
getcommand(), daychange(), player_main(), status() accordingly, taking
care not to change player output.  Change edit country key 'u' to work
in seconds.
This commit is contained in:
Ron Koenderink 2008-10-28 08:48:25 -06:00
parent 436328f641
commit 14319b89ec
10 changed files with 40 additions and 42 deletions

View file

@ -99,7 +99,7 @@ struct natstr {
signed char nat_update; /* Want an update or not. */
unsigned short nat_tgms; /* # of telegrams to be announced */
unsigned short nat_ann; /* # of annos pending */
unsigned short nat_minused; /* number of minutes used today */
int nat_timeused; /* number of seconds used today */
short nat_btu; /* bureaucratic time units */
short nat_access; /* The tick when BTUs were last updated */
long nat_reserve; /* military reserves */