Sub topic 4
Sinks: where currency leaves the game
This chapter assumes you know what a currency and a source are, and that you can read short Python snippets and do percentage arithmetic. A sink is any mechanism that removes currency from a player's balance and from the game's total supply. It is the counterpart of a source. Sources add currency to the economy, and sinks take it out.
What counts as a sink
Currency leaves the game only when it is destroyed, not when it moves. If one player pays another, the total supply is unchanged. If a player pays the game, the currency disappears, and that is a sink.
The test is simple: after the transaction, is the total supply smaller? If yes, it is a sink. If the currency only changed hands, it is a transfer.
Sinks come in three broad types:
- Purchases of goods. The player buys an item, a cosmetic, or an upgrade.
- Services and fees. The player pays for repairs, fast travel, respec, crafting, or a market listing fee.
- Taxes and decay. The game removes a share of the balance or of a transaction automatically.
Sinks and the flow of currency
A sink works as a rate. A fixed-price sink removes a set amount per use. A proportional sink removes a share of a balance or transaction. These two behave very differently at scale.
The first code example from the plan shows a proportional sink. Each day the player earns a fixed amount, then a percentage of the balance is removed.
def simulate(days, income_per_day, sink_rate, start=0.0):
"""Track one player's balance. Each day they earn a fixed amount,
then a percentage of the balance is removed (for example repair costs or fees)."""
balance = start
history = []
for _ in range(days):
balance += income_per_day
balance -= balance * sink_rate
history.append(round(balance, 2))
return history
print(simulate(60, 100, 0.10)[-1]) # close to 900The balance settles near income * (1 - rate) / rate, which is 900 for these inputs. The sink removes more as the balance grows, so the balance stops growing at the point where daily removal equals daily income. This is a self-correcting sink. A rich player pays more, and a poor player pays less.
A fixed-price sink does not correct itself. If a player earns 100 a day and a sink costs 80 a day, the balance grows by 20 a day without limit. If the sink costs 120 a day, the player cannot sustain it. Fixed prices need tuning against income. Proportional sinks tune themselves but have costs of their own, covered below.
Common sink patterns
Each pattern below removes currency in a different way and creates a different player experience.
| Pattern | How it removes currency | Typical example | Main risk |
|---|---|---|---|
| Consumables | Player buys items that are used up | Potions, ammo, food | Players stockpile when rich |
| Repair and upkeep | Cost recurs with use | Weapon repair, building maintenance | Feels punishing if costs rise faster than income |
| Cosmetics | One-time purchase of status | Skins, housing decor | Only appeals to some players |
| Upgrades | Large price, permanent benefit | Gear tiers, skill levels | Bottlenecks progress if priced badly |
| Fees and taxes | Percentage cut of an action | Market listing fee, transfer tax | Players avoid the action |
| Gambling-style sinks | Random outcome with negative expected value | Loot boxes, enhancement chances | Fairness and regulation concerns |
| Time-saving purchases | Pay to skip waiting | Instant travel, speed-ups | Can make waiting feel designed to frustrate |
Notice that sinks differ in whether they are optional. A cosmetic is optional, so a player who skips it never feels the sink. Repair costs are close to mandatory, so every player feels them. Mandatory sinks give reliable removal but cause the most frustration when mistuned. Optional sinks cause less frustration but remove currency only from players who choose them.
Designing sinks players accept
A sink works only if players keep using it. Players who resent a sink will avoid it, quit, or find a way around it. A few rules help.
- Give the player something in return. A sink that offers a visible benefit feels like a purchase. A sink that takes currency with nothing visible feels like a penalty.
- Make the cost predictable. A repair bill that the player can estimate beforehand is easier to accept than a random loss.
- Scale with wealth where possible. Wealthy players hold most of the surplus. A sink that targets high balances, such as a luxury item or a percentage fee, removes currency where the surplus sits.
- Offer a choice. If players pick which sinks to use, the cost feels like their decision.
- Avoid stacking. Several mandatory sinks on the same action add up. A player who sees four fees on one trade will feel taxed even if each fee is small.
Sinks that scale with the economy
An economy changes over time. Early on, players have small balances, and a 500-unit sink is large. Months later, the same sink is trivial. Two approaches handle this.
- Tiered sinks. Offer items at several price levels so there is always something priced near a player's current balance.
- Percentage-based sinks. Use a share of the balance or of the transaction so the amount grows with wealth.
Percentage sinks have one risk: they punish saving. A player who holds a large balance for a planned purchase loses part of it every period. If that matters to your design, apply the percentage to the transaction, not the balance, or exempt a base amount.
Pricing a sink from pacing
Do not guess the price of a sink. Start from how long the player should have to play to afford it, and from the income rate you measured or planned. The second code example from the plan does this.
def price_for_target(hours_to_earn, income_per_hour):
"""Price an item so a typical player needs about hours_to_earn hours of play to afford it."""
return round(hours_to_earn * income_per_hour)
print(price_for_target(3, 450)) # 1350If a typical player earns 450 per hour and the item should take three hours, the price is 1350. When income changes, the price should be revisited. A sink priced against last season's income may be too cheap or too costly now.
Recording sinks
You cannot tune what you do not measure. Every sink should report how much it removes, labeled by reason. The third code example from the plan routes every balance change through earn and spend with a reason label.
from collections import defaultdict
class Ledger:
def __init__(self):
self.balance = 0
self.earned = defaultdict(int)
self.spent = defaultdict(int)
def earn(self, reason, amount):
if amount <= 0:
raise ValueError("amount must be positive")
self.balance += amount
self.earned[reason] += amount
def spend(self, reason, amount):
if amount <= 0:
raise ValueError("amount must be positive")
if amount > self.balance:
raise ValueError("insufficient funds")
self.balance -= amount
self.spent[reason] += amount
wallet = Ledger()
wallet.earn("quest_reward", 500)
wallet.spend("weapon_repair", 120)
print(wallet.balance, dict(wallet.earned), dict(wallet.spent))The spent dictionary gives you total removal per sink. With it you can see which sinks do the work and which are nearly unused. It also rejects invalid amounts and overdrafts, so a bug cannot create negative spending that acts as hidden income.
Common errors
- Counting transfers as sinks. A player-to-player trade does not reduce supply. Only fees and taxes on the trade do.
- Sinks that only reach active spenders. If only a minority of players use a sink, most of the currency stays in circulation.
- Sinks priced against the wrong player. A price set for the average player may block new players and mean nothing to veterans.
- Ignoring the sink's effect on behavior. A high fee does not just remove currency. It also lowers how often the action happens, which can shrink the removal you expected.
- Fixing inflation with a single large sink. One expensive item removes a lot at first, then dries up once players have bought it. Recurring sinks last longer than one-time sinks.
How sinks fit the larger picture
A sink is only one half of the balance. Whether the economy inflates or deflates depends on the relation between total inflow from sources and total outflow through sinks. Later chapters cover that balance, then how to measure it live. Here the point is narrower: every sink should have a purpose, a price tied to pacing, and a label in your ledger.
Exercise
A player earns 200 coins per day. A proportional sink removes 20% of the balance after each day's income. Roughly what balance does the player settle near, using income * (1 - rate) / rate?
Show answer
200 (1 - 0.2) / 0.2 = 200 0.8 / 0.2 = 800 coins. At that balance, the 20% removal equals the daily income of 200 coins, taken from the balance after income is added.
Exercise
A market charges a 5% fee on each sale, and players start selling items directly to each other outside the market. Does the sink still work, and what should you check?
Show answer
It works only for sales that still go through the market. Check what share of trades use the market and whether the fee is high enough to push players off it. Compare the currency removed by the fee, using the ledger's per-reason totals, with what you expected.
Exercise
You want an item that a typical player affords after 4 hours, and players earn 300 per hour. What price do you set, and what do you do when the average income rises to 400 per hour?
Show answer
The price is 4 * 300 = 1200. When income rises to 400 per hour, the same price takes only 3 hours, so either raise the price to 1600 to keep the pacing, or accept the faster pacing on purpose.