Skip to content

Exchange and market

Create: Hydraulics edited this page Jul 13, 2026 · 1 revision

Exchange and Market

How Pricing Works

Every material pair has a liquidity pool using a constant product AMM curve, the same mechanism used by decentralized exchanges like Uniswap. This means rates move automatically based on actual supply and demand rather than a hand tuned formula, and large single trades get progressively worse rates as they execute, a property called price impact. This naturally discourages one player from crashing a material's price in a single transaction.

Exchanging Materials

Use /exchange <from> <to> <amount> or open the Exchange GUI with /exchequer exchange. The GUI is strongly recommended over the raw command for anything beyond small trades, since it shows the live rate, the price impact preview (rate before versus after your trade), and the current tax breakdown before you commit.

The Exchange GUI has a material grid on the left for your "from" selection and one on the right for "to." Quick select buttons let you trade 25, 50, or 100 percent of your balance in the selected material without manually typing an amount.

Tax

Every exchange is taxed in two layers.

Macro cycle: a server wide base tax rate that oscillates between a configured minimum and maximum on a set schedule, with small randomized jitter on timing so it can't be perfectly predicted or scripted.

Governance modifier (Towny only): nation leadership can raise or lower their own local tax on top of the global base. Lower local tax draws more trading activity from that nation's residents, which raises GDP, but yields less tax revenue per trade. This is a real tradeoff, not a cosmetic setting.

The tax collected on each trade splits into two destinations, configurable in config.yml: a portion is burned entirely, removed from the economy as the primary inflation control, and a portion routes into the trading player's nation treasury if one exists.

Rate Limiting and Manipulation Detection

On top of the AMM's natural price impact, there is a per player, per material rolling exchange volume cap to prevent single actor market crashes. Exchange patterns that look scripted, particularly repeated trades timed exactly at tax cycle troughs, are flagged and logged, and may be temporarily rate limited depending on your config.yml sensitivity setting.

Price Data

/market price <material> shows the current live spot rate. /market history <material> <window> returns daily open, high, low, and close data for the requested window (1 hour, 1 day, 7 days, or 30 days), not raw point samples, which makes trend reading meaningfully easier than a noisy tick by tick feed.

/market alert <material> above|below <value> sets a one time alert that pings you in chat and clears itself once triggered.

Market GUI

/exchequer market opens a browsable list of every tracked material with its current price and a simple trend indicator comparing the live rate to the last daily close. Clicking a material opens a detail view with recent history and a shortcut into the Exchange GUI with that material pre selected.

Money as a Currency (Vault only)

If Vault is installed, MONEY participates in the exchange system as its own tradeable currency rather than being a flat mirror of your ledger. This matters because it means Vault money minted by other plugins (shops, jobs plugins, and so on) has to pass through the same AMM pricing and tax mechanics as every other material when converted into the economy, rather than freely diluting it. See [Vault Integration](Vault-Integration.md) for details.

Clone this wiki locally