Defines a game currency (gold, gem, XP) with type, code, and decimal places.
currency#
Defines a currency in your game. Each currency is its own page — you don't bundle "gold + gems + tickets" into the same addon. By design, one currency lives on one page.
Why it matters#
Currencies are referenced by many other addons (item prices, skill costs, exchange rates, recipe rewards). Without a dedicated addon, each reference would be a loose string like "gold" — and when you rename the currency to "coins" the whole game breaks. Define it once here and validated references do the rest.
Where it usually lives#
- A page of type
🪙 Economy. Wizard for Gold, Gems, Tickets, etc. - Blank pages when you want to group atypical currencies.
Singleton — 1 currency per page. For multiple currencies, create multiple pages (one per currency).
Schema#
| Campo | Tipo | Padrão | Descrição |
|---|---|---|---|
idYes | string | Internal ID. | |
nameYes | string | Addon name (defaults to the page title). | |
codeYes | string | Short code in UPPER_SNAKE that goes into the exported JSON (e.g. GOLD, GEM). Must be unique in the project. | |
displayNameYes | string | Friendly name shown in the UI (e.g. Gold, Gem). | |
kindYes | "soft" | "premium" | "event" | "other" | soft: earned by playing (gold). premium: purchased (gems). event: limited-time event (Halloween tickets). other: catch-all. | |
decimalsYes | number | Decimal places (0 for integers). Useful for currencies that accept fractions (subscription credits, XP fractions). | |
notes | string | Free notes for the team (balancing rules, history, etc). |
Example#
{
"id": "currency-gold",
"name": "Gold",
"code": "GOLD",
"displayName": "Gold",
"kind": "soft",
"decimals": 0,
"notes": "Main currency. Earned from quests, drops from enemies, sold in shop."
}
Who points to this currency#
economyLink— buy/sell prices on items.skills.SkillCost— when the skill cost type iscurrency.currencyExchange.CurrencyExchangeEntry—fromCurrencyRef/toCurrencyRefpoint to currencies.craftTable.unlock.currency— unlocking recipes/skills via a currency cost.
Wizard#
The 🪙 Economy page type creates this addon empty with a friendly pre-fill:
code: "COINS"(rename as needed)displayName: "Coins"kind: "soft"decimals: 0
Just edit it to reflect the actual currency in your game.