capitalism 
Vars | |
| base_account | Account that receives money for orders, vending machines and station goal bounties. |
|---|---|
| completed_goals | Station goals that have already paid out so we don't double-pay them. |
| currentrun | Snapshot of accounts queued for payout this fire. Drained as we process. |
| default_counter | How many salary cycles ended in default. Useful greentext metric. |
| default_status | TRUE while the station can't make payroll. Other systems may key off this (e.g. cargo modifiers). |
| fire_stage | Current stage of the resumable fire(). |
| income_vedromat | Income generated by vending machines this round. |
| payment_account | Account from which salaries are deducted. |
| pending_salary_total | Sum of paychecks for everyone in currentrun, computed during the build stage. |
| total_cargo_bounty | Total credits routed to the cargo account from quest payouts. |
| total_personal_bounty | Total credits paid out as personal/department bounties this round. |
| total_salary_payment | Total credits paid out as salaries this round. |
| total_station_bounty | Total credits routed to the station account from cargo bounty. |
Procs | |
| build_payment_run | Snapshots all accounts that should receive a salary this cycle and sums their paychecks.
Also resolves the default-status transition before any money is moved, so we don't half-pay.
If a previous fire() was interrupted mid-payout (charge failed), currentrun will still
hold the unpaid accounts — we resume that queue instead of rebuilding to avoid double-paying
anyone who already got their salary in the prior cycle. |
| process_payments | Processes the payout queue across as many ticks as needed. Drains currentrun. |
| process_station_goals | Walks the current gamemode's station goals, paying out any that completed since the last fire. |
| smart_bounty_payment | Splits money evenly between every account whose linked job title is in jobs_payment.
Returns FALSE if no eligible accounts were found. |
| smart_department_payment | Splits money evenly between department accounts named in keys_department.
Falls back to crediting the station account if none of the departments resolve. |
| smart_job_payment | Pays a per-job bounty to every active account whose job is in jobs_payment (assoc list: title -> amount). |
Var Details
base_account 
Account that receives money for orders, vending machines and station goal bounties.
completed_goals 
Station goals that have already paid out so we don't double-pay them.
currentrun 
Snapshot of accounts queued for payout this fire. Drained as we process.
default_counter 
How many salary cycles ended in default. Useful greentext metric.
default_status 
TRUE while the station can't make payroll. Other systems may key off this (e.g. cargo modifiers).
fire_stage 
Current stage of the resumable fire().
income_vedromat 
Income generated by vending machines this round.
payment_account 
Account from which salaries are deducted.
pending_salary_total 
Sum of paychecks for everyone in currentrun, computed during the build stage.
total_cargo_bounty 
Total credits routed to the cargo account from quest payouts.
total_personal_bounty 
Total credits paid out as personal/department bounties this round.
total_salary_payment 
Total credits paid out as salaries this round.
total_station_bounty 
Total credits routed to the station account from cargo bounty.
Proc Details
build_payment_run
Snapshots all accounts that should receive a salary this cycle and sums their paychecks.
Also resolves the default-status transition before any money is moved, so we don't half-pay.
If a previous fire() was interrupted mid-payout (charge failed), currentrun will still
hold the unpaid accounts — we resume that queue instead of rebuilding to avoid double-paying
anyone who already got their salary in the prior cycle.
process_payments
Processes the payout queue across as many ticks as needed. Drains currentrun.
process_station_goals
Walks the current gamemode's station goals, paying out any that completed since the last fire.
smart_bounty_payment
Splits money evenly between every account whose linked job title is in jobs_payment.
Returns FALSE if no eligible accounts were found.
smart_department_payment
Splits money evenly between department accounts named in keys_department.
Falls back to crediting the station account if none of the departments resolve.
smart_job_payment
Pays a per-job bounty to every active account whose job is in jobs_payment (assoc list: title -> amount).