feat: Cards writings and balancing (M8)
This commit is contained in:
@@ -19,6 +19,8 @@ export function computeFiscal(state, bal) {
|
||||
const e = state.economy;
|
||||
let revenue = e.otherRevenue;
|
||||
for (const id of TAX_IDS) revenue += taxRevenue(id, e.taxes[id], bal);
|
||||
// Receipts follow the cycle: a slump costs revenue, a boom adds some.
|
||||
revenue += (bal.fiscal?.growthSens ?? 0) * (e.growth - state.ref.vars.growth);
|
||||
|
||||
const debtRatio = (e.debt / e.gdp) * 100;
|
||||
const rate = interestRate(debtRatio, bal);
|
||||
@@ -85,4 +87,5 @@ export function setBudget(state, bal, { alloc = {}, taxes = {} } = {}) {
|
||||
|
||||
export function confirmBudget(state) {
|
||||
state.pending.review = false;
|
||||
state.risk.emergency = false;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user