Use the new Empire clock for generating BTUs:
(natstr): New member nat_access. (cou_ca): New selector access. (grant_btus, accrued_btus): New. (prod_nat, init_nat): Use grant_btus(). BTUs are now made at the update in addition to login, because that lets us get away with a simple ETU stamp (nat_access). (nat_cap): Replaced by grant_btus(), remove.
This commit is contained in:
parent
dd2daaaab3
commit
d3e0597f0e
5 changed files with 107 additions and 47 deletions
|
@ -133,6 +133,8 @@ prod_nat(int etu)
|
|||
struct natstr *cnp;
|
||||
|
||||
for (n = 0; NULL != (np = getnatp(n)); n++) {
|
||||
grant_btus(np, etu_per_update - np->nat_access);
|
||||
np->nat_access = 0;
|
||||
if (np->nat_stat < STAT_ACTIVE)
|
||||
continue;
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue