Skip to content
ShadowMC

Configuration

ShadowEconomy

Several currencies, a shop with living prices, and trades nobody can rig.

Free with Premium v1.0.4

Where the files are

plugins/ShadowEconomy/

The plugin creates them on first start and updates them by itself on new versions, keeping your changes.

Applying changes

/eco reload

Reloads the files without restarting the server.

What’s inside

20 files · 364 settings

Start with: config.yml

Settings

The files that decide how the plugin behaves. Start here.

config.yml

General settings
68 settings
plugins/ShadowEconomy/config.yml
File notes

On update, this file (like every other file of the plugin) is moved to the new version automatically: it is rebuilt from the new one and everything you had changed or added is carried into it. The old files are kept in backup/<date>/, and if something needs your attention you will find PORTING-<version>.txt in this folder, saying what to fix.

A wrong value blocks nothing: it is replaced by the factory one and reported in the console at start-up, with the path and what was expected.

Everything here - keys, sections and comments - is English, because it is read by whoever runs the server, wherever in the world that is. The words players see live in lang/, and are English by default; Italian ships too (messages.default-locale below).

config-version1

Licence

With no key the FREE version runs: wallets, /pay, history, leaderboard, the server shop and chest shops, up to 30 players online, 3 chest shops each and one currency.

Keep reading

A signed key switches on the auction house, the rented district, the exchange, mining, tokens, the bank, MySQL and multi-server sync.

The key does NOT usually go here: /eco license claim <code> writes it into license.yml by itself, which is a separate file on purpose - a config gets sent to support, a licence does not.

license4 keys

THE KEY LIVES IN license.yml (same folder as this file), or in the central plugins/ShadowControl/licenses.yml for the whole suite. The 'key' below is only a fallback for deploy systems that generate config.yml: leave it empty.

The key does NOT live here: it lives in license.yml, in this folder, written at first start (or in plugins/ShadowControl/licenses.yml for the whole suite). Leave it empty: it is only for those who prefer to keep everything in one config.

grace-days7

Days of grace when a subscription has just run out, or when the address does not match. It switches nothing off: it warns and counts.

activation-url'https://shadow-licences.riccardobotins.workers.dev'

The suite's activation service. Empty = no /claim, and keys are activated by hand with /eco license activate <key>.

resolve-public-iptrue

Asks the activation service above (activation-url + /ip) how this server looks from outside: it answers with the address it sees, and nothing about the server is sent. Needed when the licence is tied to a domain and the machine only sees internal addresses. Only when a licence is installed: a server without a key asks nobody. false = never ask.

server-ip""

The address this server introduces itself with, when it is not the one it works out by itself. A name or an ip; empty is quite fine.

storage7 keys
storage.mysql7 keys
enabledfalse

false = a local H2 database inside plugins/ShadowEconomy/data/. Nothing to install: the plugin works the moment it is copied in.

host127.0.0.1
port3306
databaseshadoweconomy
usernameroot
password""
parameters"useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=UTC&characterEncoding=utf8"
storage
table-prefix"se_"

The table prefix. Change it and the plugin creates new tables and starts from nothing: useful for two servers on one database.

fallback-to-localtrue

MySQL configured but unreachable: with true the plugin says so in the console and falls back to the local file, so the server still starts.

flush-interval"20s"

How often changed balances reach the database. On shutdown a blocking save always happens, whatever this value says.

storage.h21 key
auto-serverfalse

Lets another process - a web panel, say - open the same H2 file while the server is running. Rarely needed.

Several servers on one database

Only needed for a network - lobby + survival + ... - sharing one MySQL. The servers pass news to each other through the database: no ports to open, no plugin on the proxy.

What travels is the DIFFERENCE, never the total: "add 500", never "the balance is 1500". That way two servers touching the same wallet in the same second arrive at the same number.

storage.sync5 keys
modeAUTO

AUTO = on when MySQL is in use, off on the local database. ON | OFF to decide for yourself.

primarytrue

IMPORTANT: on a network, exactly ONE server has primary: true. That one closes auctions, moves the exchange, collects rent and accrues interest. The others read and display.

server-idauto

The name of this server. "auto" = hostname-port.

poll-interval"1.5s"

How often it checks whether there is anything new.

keep"5m"

News already read is thrown away after this long.

storage.pool5 keys
maximum-pool-size10
minimum-idle2
connection-timeout-ms10000
idle-timeout-ms600000
max-lifetime-ms1800000
messages2 keys
default-localeen_US

The language used when a player's own is not in lang/, and by the console. Ships with en_US and it_IT. Set it_IT here for an Italian server.

follow-client-localetrue

Each player sees the language of their client, when the file exists.

Modules

Switching a module off does not merely hide it: its service is never created, its listeners are never registered and its commands do not exist. A server that only wants wallets pays for wallets only.

modules10 keys
shoptrue

/shop, /sell, /buy, /worth

markettrue

auction house, /ah

chestshoptrue

sign and chest shops

districttrue

the rented shopping district, /market

financetrue

crypto, shares, companies

miningtrue

mining rigs

tokenstrue

event tokens, /token

banktrue

account, interest and loans, /bank

tradetrue

player to player trading, /trade

special-shopstrue

The shops in shops/*.yml: one per file, each with its own command and its own money. Out of the box there is a token one and a crypto one.

Economy

economy8 keys
starting-balance-on-first-jointrue

The starting balance, set per currency in currencies.yml, on a player's first join.

allow-negativefalse

With true a player may go below zero. Not advised: very nearly every economy exploit starts from a negative balance.

block-creative-sellingtrue

In creative, items come out of nothing, so selling them is printing money. With true - which is advised - somebody in creative cannot sell to the shop, list at auction, fill a buy request or cash a token. The permission shadoweconomy.bypass.creative exempts them.

fire-eventstrue

With false, BalanceChangeEvent is not fired. Only switch it off if another plugin hooks it and causes trouble.

compact-format-from1000000

Above this figure numbers are written the short way: 1.23M.

economy.pay6 keys
enabledtrue
minimum1.0
tax-percent0.0

Taken from every /pay. This is the valve against inflation.

tax-account"server"

"server" = the money taken is destroyed. Any other name creates a system account with that name, visible in /eco audit.

cooldown"3s"
confirm-above25000

From this figure up the payment asks first, with two buttons in chat (confirm / cancel): a typo on one zero must not empty an account.

economy.interest6 keys
enabledfalse

Off out of the box: on a server already printing money through mobs and mining, interest only makes the already rich richer.

interval"1h"
percent0.5
currencycoins
max-balance25000

Past this threshold no more interest accrues.

only-onlinetrue
economy.baltop2 keys
refresh"5m"
size100

Integrations

integrations4 keys
vaulttrue

Registers ShadowEconomy as the Vault provider: this is how third party plugins - Jobs, McMMO and the rest - use our money.

suitetrue

Registers EconomyProvider for the rest of the Shadow suite.

placeholderapitrue
regionsAUTO

AUTO -> ShadowRegions, then WorldGuard, then nothing. SHADOWREGIONS | WORLDGUARD | INTERNAL to force a choice.

sounds4 keys
success"entity.experience_orb.pickup"
error"block.note_block.bass"
click"ui.button.click"
big-purchase"entity.player.levelup"

bStats - anonymous usage statistics (https://bstats.org)

What is sent, every 30 minutes: that this server runs ShadowEconomy, the plugin, Minecraft/Paper and Java versions, the operating system, the number of CPU cores, how many players are online (a number, nothing else), a random serverUuid that identifies nothing, and the edition in use (free, premium or creator). No player data leaves the server: no names, no UUIDs, no addresses, no balances or transactions.

metrics1 key
enabledtrue

false switches it off for this plugin only. enabled: false in plugins/bStats/config.yml switches it off for every plugin on this server at once.

debug2 keys
log-tradestrue

Writes every trade into the transaction log. Switching it off loses /transactions and /eco audit, so leave it on.

log-sqlfalse

Prints every query in the console. Only for chasing a problem.

bank.yml

The bank
26 settings
plugins/ShadowEconomy/bank.yml
File notes

The bank gives money somewhere to live that is not a chest.

Three things: - an ACCOUNT that earns interest, at a rate that falls as the balance

rises. The tiers are the whole point: a flat rate on any amount is
a machine for making the already rich richer, and on a server you
see it inside a week.

- TERM DEPOSITS, which pay more in exchange for not touching the

money until a date. Breaking one costs.

- LOANS, with a limit worked out from what the player actually has,

instalments taken automatically, and a default that shuts the door
until they settle up.

A bank balance is NOT a new table: it is an ordinary account with an id derived from the player's. So it is saved, tracked in /eco audit and synchronised between servers by the same code as the wallets, and it stays out of /baltop.

config-version1
bank6 keys
enabledtrue
currencycoins

The bank works in one currency only. Empty = the default one.

min-deposit1
bank.interest3 keys
interval"1d"

How often it accrues, and therefore what the percentages below are worth: with 1d and 0.20 a small account earns 0.20% a day, which is roughly 7% a month. Lowering the interval without lowering the percentage is the quickest way to inflate an economy. The maths is done once, by the primary server, so on a network nobody is paid twice.

only-onlinefalse

With true it only pays players who are online at that moment.

bank.interest.tiers3 keys

The tiers, read from the top: the first step whose "up-to" is >= the balance decides the rate, applied to the whole balance. up-to: 0 means "from here up".

bank.interest.tiers.piccolo2 keys
up-to100000
percent0.20
bank.interest.tiers.medio2 keys
up-to1000000
percent0.10
bank.interest.tiers.grande2 keys
up-to0
percent0.02
bank.term5 keys
enabledtrue
duration"7d"

How long the money stays locked away.

percent5.0

Interest paid at maturity, on the whole amount.

break-penalty-percent25.0

Taken out early: no interest, and this percentage gone as well.

minimum250
bank.loans9 keys
enabledtrue
interest-percent15.0

Total interest on a loan: 15 means somebody borrowing 1000 owes 1150, split across the instalments below.

base-limit1200

Limit = base + (net worth * limit-factor), up to "maximum". Net worth counts wallet, bank, term deposits and investments.

limit-factor0.5
maximum250000

A permission can raise or lower the ceiling for one player: shadoweconomy.bank.limit.<n> (the highest number wins).

instalments7
instalment-interval"24h"
max-missed3

Instalments missed before the loan goes bad. From there on, no new loans until they settle up, or until an admin writes it off.

late-fee-percent5.0

A late fee added to what is owed for every missed instalment.

currencies.yml

Currencies
20 settings
plugins/ShadowEconomy/currencies.yml
File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/currencies.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

The currencies of the server. The one named in "default" is what Vault uses, what every command without an explicit currency uses, and what a shop price means when it does not name one.

The id of a currency is typed by players, so keep it in English. Only "display", "plural" and "symbol" are shown to them, and those are the ones meant to be translated.

decimals: digits after the point. 0 for a "token" style currency. max-balance: 0 means no ceiling. payable: false takes the currency out of /pay (usual for premium ones). baltop: false takes it out of the leaderboard.

config-version1
defaultcoins
currencies2 keys
currencies.coins9 keys
display"Coins"
plural"Coins"
symbol"$"
color"#FFD54F"
decimals2
starting-balance100.0

What a player finds in their pocket the first time they join. At shop prices that is about twenty logs: enough to get going, not enough to skip the beginning.

max-balance1000000000
payabletrue
baltoptrue
currencies.gems9 keys

A premium currency: it only comes from /eco give (or from the store on your website), it cannot be sent between players and it stays out of the leaderboard.

display"Gems"
plural"Gems"
symbol"❖"
color"#4FC3F7"
decimals0
starting-balance0
max-balance0
payablefalse
baltopfalse

district.yml

Districts
14 settings
plugins/ShadowEconomy/district.yml
File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/district.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

The shopping district: the building the server owner puts up, divided into shops that players rent.

How a plot is made:

1. /market admin wand
2. left click one corner, right click the opposite one
3. /market admin create shop-1 shop
4. /market admin panel shop-1  ->  set the door and the visit point

From then on the plot shows up in /market and anybody can rent it.

config-version1
district8 keys
enabledtrue
currencycoins

Which currency rent and showcase purchases are paid in.

grace-period"3d"

How long a tenant has, after the rent runs out, to renew before the plot goes back on the market and their stock is sent back to them.

commission-percent5.0

The district's cut of every sale made at a showcase.

rent-account"server"

Where rent and commission end up. "server" = destroyed, which is deliberate deflation. Any other name creates a system account visible in /eco audit.

confirm-purchase-above1200

Above this figure, buying at a showcase asks for confirmation.

max-plots-per-player2

Plots per player. Raised with shadoweconomy.district.limit.<n>.

hologramstrue

Holographic showcases: the item turning above the counter, with its prices under it.

Tiers

Every plot belongs to a tier, which decides its rent, its length and how many showcases it may put out. This is the economic lever of the district: the dearer the spot, the more stock it can hold.

The tier id is written into the plots, so keep it in English; only "display" is shown to players.

tiers4 keys
tiers.stall5 keys
display"&aStall"
rent125
period"7d"
max-showcases4
iconOAK_TRAPDOOR
3 more entries shaped like stall: shop, store, boutique

finance.yml

Finance
35 settings
plugins/ShadowEconomy/finance.yml
File notes

The exchange: five cryptocurrencies and the companies players found.

Four of the five are the ones everybody has heard of, so a player understands what they are looking at without being taught. The fifth, ShadowCoin, is the server's own and the only one that can also be produced: it comes out of the mining rigs and goes back into the crypto shop, where it is burned.

Prices move with geometric brownian motion - the standard way markets are simulated - plus two things that make it a game and not a

screensaver:
  - player pressure (buying pushes up, selling pushes down)
  - market events, announced in chat.

volatility is annualised: 0.9 is a wild crypto, 0.2 a quiet index. Changing tick-interval does not change the character of an asset.

If you prefer, the four real coins can follow their real price on Binance instead: see finance.real-prices below. Off by default.

config-version2
finance11 keys
enabledtrue
currencycoins

Which currency buying and selling happen in.

tick-interval"5m"

How often prices move and a candle closes.

fee-percent0.5

Fee on every trade: a percentage, with a fixed minimum.

fee-minimum0.25
history-points96

Points kept for the chart inside the GUI.

event-chance0.04

Chance an event starts, per asset and per tick.

event-duration-ticks6
announce-eventstrue
finance.company8 keys
enabledtrue
creation-cost12000

What founding costs, on top of the capital that goes into the treasury.

min-capital2500

Minimum capital to put in: it is what gives the shares their value.

min-shares100
max-shares1000000
dividend-interval"24h"

How often a founder may pay a dividend.

max-dividend-percent25
fair-value-pull0.05

How hard the market price is pulled, every tick, towards the book value (treasury divided by shares). 0 = the market is left alone.

Real prices from Binance (optional, off by default)

When this is on, every asset below that has a "real-symbol" stops being simulated and follows the price it has right now on Binance, the largest crypto exchange. ShadowCoin has no real-symbol: it is the server's own coin and stays simulated whatever you choose here.

Keep reading

Why there is no API key to fill in: Binance publishes its market prices on public, read-only addresses that anybody may use, with no account and no key. A key is only needed to trade or to look at an account, and this plugin does neither. So there is nothing to sign up for and nothing to pay - and never put a Binance key in a config file: it would only be a secret lying around for nothing.

While a coin follows Binance:

- the random movement and the market events do not touch it;
- players' trades do not move it either. A trade on this server is
  far too small to move the real market, and a price that players
  could push up and then sell into would be free money. Everybody
  buys and sells at the real price; fee-percent is the spread;
- min-price and max-price do not apply to it;
- the chart, the day's open, high and low and the % change are
  built from the real prices, like for any other coin. The first
  real price starts a new day, so switching this on does not show
  up as a +50% or -50% day.

Price moves on Binance reach the server once per refresh: a player watching Binance sees them a little earlier, which is why the fee should stay above what a coin moves in one refresh (0.5% is fine).

If Binance cannot be reached the coins keep their last price, the console says so once (and once more when it answers again), and the plugin tries less and less often, up to every 10 minutes. A real-symbol Binance does not know is reported once in the console and that coin goes back to being simulated.

On a network of servers only the primary one asks Binance; the others read the prices from the database as they already do.

finance.real-prices6 keys
enabledfalse
hosts
["https://data-api.binance.vision", "https://api.binance.com"]+1

Tried in this order until one answers; the one that answered is tried first the next time. data-api.binance.vision is Binance's own address for market data only and comes first, because api.binance.com refuses some countries and some hosting providers.

refresh"60s"

How often the prices are read: one request for all the coins. Minimum 10s.

timeout"5s"

How long to wait for an answer before trying the next address.

quoteUSDT

The currency the real-symbols are priced in. USDT is a digital dollar (1 USDT is about 1 US dollar). A real-symbol that does not end with it is reported in the console.

price-multiplier1.0

How much server money 1 USDT is worth, because your economy has its own scale. With 1 a Bitcoin costs what it costs in dollars; with 0.01 it costs a hundredth of that. An asset may also have its own price-multiplier (next to its real-symbol), which is applied on top of this one.

Assets

The id and the symbol are typed by players, so they stay English; only "display" is shown as words.

Keep reading

kind: CRYPTO | STOCK liquidity: how much money it takes to move the price. A low value makes a coin that jumps on very little; a high one makes it move slowly. A trade is settled halfway between the price before it and the price after it, so it pays for its own push: buying and selling straight back never makes money.

assets5 keys

The four everybody knows

Prices start close to the real ones because a player who reads "Bitcoin 62000" immediately understands what it is, and because a big number forces you to buy a fraction of it - which is exactly how it works outside. "liquidity" is how much money it takes to move the price: high on BTC, which moves slowly, low on XRP, which dances.

Keep reading

real-symbol is the Binance pair each one follows when finance.real-prices is on (the name Binance shows, like BTCUSDT). Remove it to keep a coin simulated even then. Next to it you may add price-multiplier: 0.001 to make one coin cheaper than the others.

assets.btc11 keys
kindCRYPTO
symbolBTC
display"Bitcoin"
iconGOLD_INGOT
price62000.0
volatility0.55
drift0.06
liquidity2000000
supply21000
min-price100.0
real-symbolBTCUSDT
4 more entries shaped like btc: eth, sol, xrp, shc

market.yml

The market
34 settings
plugins/ShadowEconomy/market.yml
File notes

Two things in one file, because they are the two ways players sell to each other:

- the auction house (/ah), to sell to anybody without being there;
- chest shops, to sell from your own base.
config-version3
auction18 keys
enabledtrue
listing-fee-percent2.0

Taken when the listing goes up: it is paid even if nothing sells, and it is what discourages listing things at random.

sale-tax-percent5.0

Taken out of the price when the item actually sells.

min-price1
max-price100000000
default-duration"48h"
max-duration"168h"
max-listings5

Listings at once, per player. Raised with the permission shadoweconomy.market.slots.<n> (the highest number wins).

min-bid-increment-percent5.0

Minimum raise, as a percentage of the current bid. It is also the step the house bids by on behalf of anyone who set a maximum: the smaller it is, the harder the auction is fought.

anti sniping

auction
anti-snipe"30s"

A bid in the last "anti-snipe" seconds extends the auction by "anti-snipe-extend". Without it the winner is whoever clicks at the right millisecond, not whoever wanted the item. 0 turns it off.

anti-snipe-extend"30s"
buy-confirm-above2500

Above this figure, "buy now" asks for confirmation. 0 never asks.

auto-relist-limit3

How many times a listing set to auto relist may put itself back up. Every relist pays the fee again. 0 turns the feature off.

sale-history-days14

The window used to tell a seller "this usually goes for X". The price shown is the median of recent sales, not the average: one absurd sale must not move the advice.

watchlist-max10

How many things a player may keep an eye on (/ah watch).

bundles-enabledtrue

Allows selling a whole inventory as a single bundle.

broadcast-above25000

Above this figure the sale is announced in chat to everybody, with a clickable link to the listing. 0 never announces.

blacklist
[BEDROCK, COMMAND_BLOCK, SPAWNER, DEBUG_STICK, STRUCTURE_BLOCK]+2

Materials that cannot be put up for auction.

Direct offers

A buyer names their own price on a listing that is not selling. The money is held straight away, so what reaches the seller is a real offer and not a message: accept or refuse with one click.

offers3 keys
enabledtrue
duration"48h"

How long an offer stands if the seller does not answer.

max-per-player10

Offers open at once, per player. Each one holds money aside, so the number is a safeguard as much as a limit.

Buy requests

The opposite of a listing: somebody puts money down for an item they want, and anybody who has it hands it over and is paid on the spot. Part of a request can be filled on its own.

requests4 keys
enabledtrue
duration"7d"
max-per-player5
fee-percent0.0

Taken when the request is opened. Zero out of the box: the money is already held, and charging for waiting as well discourages the one half of a market that is usually missing.

chestshop7 keys
enabledtrue

A shop is opened with /chestshop create while looking at a SINGLE chest: the chest's own screen then takes the item, the prices and an optional discount, and a hologram over the chest shows them. The classic sign ([Shop] on the first line) still works for those who prefer it.

creation-cost0

What opening a shop costs. 0 = free.

max-shops10

Shops per player. Raised with shadoweconomy.chestshop.limit.<n>.

sign-line"[Shop]"

The first line of the sign that creates the shop.

hologramtrue

The hologram above the chest: the turning item, with name and prices.

protect-blockstrue

Protects chest and sign from breaking, explosions and hoppers. Turning it off leaves the shops to the first passer-by.

max-discount90

The most a shop discount can take off the buy price, in percent (0-90).

Floating showcases (chest shops, district counters)

holograms1 key
spawn-distance32

A native showcase exists only while a player is within this many blocks: further away its entities are removed and put back when somebody comes near. Chest shops go through ShadowEssentials when it is installed, and take its own distance setting instead. 0 = always spawned.

mining.yml

Mining
28 settings
plugins/ShadowEconomy/mining.yml
File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/mining.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

Mining rigs: a block that opens like a case, with a mainboard, a processor, a power supply, cooling and graphics cards inside.

A rig produces crypto, draws power paid for in real currency, gets hot and wears out. It is not free money: the electricity is paid every hour, difficulty rises with the number of rigs running on the server, and what comes out is crypto, which has to be sold on the exchange before it is money.

To give somebody a part:   /rig give <id> [amount] [player]
For the list of parts:     /rig parts
config-version1
mining13 keys
enabledtrue
assetshc

Which asset from finance.yml is produced.

currencycoins

Which currency the electricity is paid in.

tick-interval"5m"
reward-per-mh-hour0.0000185

Units of crypto produced per MH/s, per hour, before difficulty.

Keep reading

The number is set like this: a middling rig - Pro mainboard, 8 core CPU, four 3070s and liquid cooling - does 258 MH/s, draws 1055 W and therefore 0.095 of electricity an hour; at this value it earns about 0.14, which is 50% more than it costs to keep running.

Below 0.0000123 EVERY rig runs at a loss and nobody switches one on again. Far above it, mining becomes the endless source of money that ruins an economy: this is the most delicate multiplier in the plugin.

power-cost-per-kwh0.09

What electricity costs, per kWh.

difficulty-per-active-rig0.01

Every rig running on the server makes the others slightly less profitable.

max-offline-hours8

Hours of production that pile up while the server is down or the player is away. Past this ceiling a rig stops accumulating.

ambient-temp22

Temperatures, in degrees.

throttle-temp80

above this, output drops

damage-temp95

above this, the rig wears out

wear-per-overheat-tick0.5
max-rigs3

Rigs per player. Raised with shadoweconomy.mining.limit.<n>.

Components

Parts have no price here: they are handed out with /rig give and sold however you like - shop, crates, rewards. To price them, the sum to do is the payback: a middling rig earns about 1.10 a day once the power is paid, and one full of 4090s about 5.50. A part costing more than it pays back in a month is a part nobody buys.

Keep reading

The part id is typed in commands, so keep it in English; "display" and the lore are the parts meant to be translated.

type: RIG | MAINBOARD | CPU | GPU | PSU | COOLING
  hashrate   MH/s the part adds
  power      watts drawn
  heat       heat produced
  cooling    heat carried away
  capacity   watts supplied (PSU only)
  gpu-slots  how many graphics cards it holds (MAINBOARD only)
  efficiency multiplier on the total hashrate (MAINBOARD only)
components20 keys

the case you place

components.case_base4 keys
typeRIG
display"Mining Case"
materialFURNACE
lore
["&7Place it and click on it", "&7to fit the parts inside."]+1
17 more entries shaped like case_base: case_pro, mb_base, mb_pro, mb_server, cpu_2, cpu_8, cpu_16, gpu_1060, gpu_3070, gpu_4090, psu_500, psu_1200, psu_2000, cool_fan, cool_tower, cool_liquid, cool_nitro
components.psu_40004 keys

Needed to fill a Server mainboard with graphics cards: seven 4090s ask for 3150 W between them.

typePSU
display"4000W Power Supply"
materialCONDUIT
capacity4000
components.cool_immersion6 keys

The part that makes a full Server mainboard possible: seven 4090s make 361 of heat, and without something this size the rig goes past 95 degrees and wears down until it breaks.

typeCOOLING
display"Immersion Cooling"
materialSEA_LANTERN
cooling300
power160
lore
["&7The whole mainboard under liquid.", "&8Draws as much power as a third of a graphics card."]+1

shop.yml

The shop
17 settings
plugins/ShadowEconomy/shop.yml
File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/shop.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

The server shop, ready to use.

This is not a sample to fill in: fourteen categories, priced against each other, meant for a SkyBlock. Players earn by selling what their islands produce - cobblestone, sugar cane, melons, iron, mob drops - and spend on decorative blocks, gear, and things that cannot be farmed.

THE SCALE IS LOW, AND THAT IS ON PURPOSE

An economy breaks when the shop pays big numbers for things produced by the stack: the first player with an automatic farm makes ten million in a week, and from then on money means nothing to anybody. Here wheat is worth 3.50 and a diamond 10: you earn slowly, and what you earn counts.

The fixed points everything else follows from:

cobblestone       0.50     the generator never runs out
log               2.00     a tree is time spent
wheat             3.50     one plant, one wheat
potato / carrot   1.50     the same plant gives two or three
iron ingot        4.00
diamond          10.00     the dearest of the ordinary things

The wheat-against-potato rule holds for the whole catalogue: it is not the item that is priced, it is the HARVEST. Sugar cane grows and is cut by itself, so 0.50. A melon slice is one ninth of a melon, so 0.25.

THE BUYING PRICE

Not one multiplier. The rarer a thing is, the worse buying it should be compared with going and getting it:

x3      under 1 sell value   cobble, dirt, sand, leaves, seeds
x2.5    up to 4              logs, crops, wool
x6      from 4 up            ingots, glass, machines, tools
x15     valuable             obsidian, pearls, blaze rods
x100    rare                 diamond, emerald, netherite

A log sells for 2 and costs 5. A diamond sells for 10 and costs 1000: the shop buys it off you gladly, but it is not the place to kit yourself out. That is the difference between a shop that serves an economy and one that replaces it.

THE RULE THAT DOES NOT MOVE

Nothing craftable is worth more than the parts it is made of. A piston is worth its three planks, four cobble, one ingot and one redstone, and not a coin more. Without that rule an auto crafter running in a loop prints money and nobody notices.

The deliberate exception is smelting: cobblestone becoming stone is worth double, raw ore smelted into an ingot gains. That is progression, not a hole - it is what makes an island build furnaces.

If you change a price, look at what that item is crafted into. Raising a sell price on its own is the classic way to open a printer inside your own shop.

WHAT YOU CAN CHANGE WITHOUT THINKING

display / description / icon    how a category looks
slot                            where it sits on the screen
limit-buy-per-day               how many a day, per player
permission                      to hide it from those without it

Every entry has:

id                  unique identifier (used by the database and the API)
material            the material, or "item" with a serialised item
buy                 what it costs the player. 0 = cannot be bought
sell                what it pays the player. 0 = cannot be sold
dynamic             true = the price moves with demand (on by default)
limit-buy-per-day   0 = no limit
limit-sell-per-day  0 = no limit
permission          if present, that permission is needed to see it
lore                extra lines in the description

Display names and descriptions are the only text meant for players, so they are the part to translate. Everything else - keys, ids and these comments - is English, because it is read by whoever runs the server, anywhere in the world.

To add or fix an entry without touching this file: /shop edit

config-version3
settings3 keys
require-pristinetrue

Refuse to buy damaged, renamed or enchanted items when the catalogue entry is a plain material. Turning this off means paying for an enchanted sword what a plain sword is worth.

min-margin-percent20

Minimum distance, in percent, between the buy and the sell price. The lowest markup in this catalogue is x2.5, which is a 60% margin.

blacklist
[BEDROCK, COMMAND_BLOCK, CHAIN_COMMAND_BLOCK, REPEATING_COMMAND_BLOCK, STRUCTURE_BLOCK, STRUCTURE_VOID, JIGSAW, BARRIER, LIGHT, SPAWNER, DEBUG_STICK, KNOWLEDGE_BOOK, BUDDING_AMETHYST, REINFORCED_DEEPSLATE]+11

Materials the shop will not touch under any circumstances.

Dynamic prices

Every entry has a factor starting at 1. Buying pushes it up, selling pushes it down, and time pulls it back towards 1. The result is a market that answers the players without ever going off the scale: not even a server selling ten thousand cobblestone drives the price below 35% of what is written here.

dynamic-pricing8 keys
enabledtrue
elasticity0.02

How much a single trade weighs.

reference-volume64

"One unit of trade": a stack.

min-factor0.35
max-factor2.50
recovery-per-hour0.10

How far the price walks back towards its base value every hour.

history-points96

Points kept for the chart: 96 x 15 minutes = 24 hours.

history-interval"15m"

Categories

Slots 10-16 are the first row, 19-25 the second.

categories14 keys

Blocks

categories.blocks5 keys
display"&#B0BEC5&lBlocks"
iconSTONE_BRICKS
slot10
description
["&7Stone, dirt, sand, glass:", "&7everything a build stands on.", "", "&8Cobblestone is what sells"]+3
items
[{ id: cobblestone, material: COBBLESTONE, buy: 1.5, sell: 0.5, lore: […] }, { id: stone, material: STONE, buy: 2.25, sell: 0.75 }, { id: smooth_stone, material: SMOOTH_STONE, buy: 2.5, sell: 0.85 }, { id: stone_bricks, …+74
13 more entries shaped like blocks: ores, wood, nature, farming, livestock, loot, nether, end, ocean, decoration, redstone, food, gear

tokens.yml

Tokens
24 settings
plugins/ShadowEconomy/tokens.yml
File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/tokens.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

A token is money with a body: it has a balance like any currency, and it can leave the account as an item - held in the hand, given away, put in a chest, sold in a shop, and brought back to the counter to become a balance again.

TWO FORMS, and one line picks between them:

currency: coins   -> it is a BANKNOTE of a currency that already
                     exists. Cashing it gives coins back.
currency: none    -> it is a CURRENCY OF ITS OWN. The plugin registers
                     it as one, so /balance, /pay, /baltop, the shop
                     and the auction house understand it with no
                     further configuration.

TWO WAYS OF BEING AN ITEM, and this is the choice that matters:

serialized: false -> TO THE BEARER. It stacks, it is convenient, and

it is copyable in exactly the way a diamond is
copyable. Fine for small change.

serialized: true -> REGISTERED. Every item carries a number that

exists once in the database and is cashed once.
Copying the item copies the number, and the
second one to arrive is refused. Use this for
anything worth anything.

The 3D model is set with item-model - a name, not a number, so two plugins cannot fight over "shadow:banknote". It needs a resource pack that defines that model; without one the item is simply the material you chose, and it works just the same.

The id of a token is typed by players and used by other plugins, so keep it in English. "display", the item name and its lore are the parts meant to be translated.

WHAT SHIPS

One token, and on purpose. A server that starts with four of them has four things nobody has decided what to do with yet, and they all show up in /balance. The one below is the event token: its own currency, earned at events, spent in /tokenshop.

To add another, copy its block and change the two lines that matter - "currency" and "serialized" - as described above. A banknote of coins is currency: coins with serialized: false; a cheque is currency: coins with value: 0 and serialized: true.

config-version2
tokens4 keys
enabledtrue
drop-if-fulltrue

When the inventory is full the token drops on the floor instead of going back into the account. With false, whatever does not fit is credited back.

max-items-per-withdraw576

Ceiling on how many items a single /token withdraw may create.

tokens.list1 key

Event token: a currency all of its own

It is not worth coins, it is worth tokens. Earned at events and spent wherever the server decides - shop, auctions, crates.

tokens.list.event_token14 keys
display"Event Token"
currencynone
symbol"ET"
color"#AB47BC"
decimals0
starting-balance0
max-supply0

0 = no ceiling. With a number the plugin never creates more than that, and the check lives inside the same statement that creates them.

payabletrue
baltopfalse
physicaltrue
serializedfalse
redeem-on-right-clicktrue
redeem-commands[ ]

Commands run from the console when one is cashed in. %player% %uuid% %token% %count% %amount% %formatted%

tokens.list.event_token.item7 keys
materialSUNFLOWER
item-model""
custom-model-data0
name"&#AB47BC&lEvent Token"
lore
["&8&m ", "&7A token from an event.", "&7Right click to put one in your account.", "&7Sneak to put them all in.", "", "&8Spend it with &f/shop&8 and &f/ah&8."]+5
glowtrue
max-stack64

trade.yml

Player trades
21 settings
plugins/ShadowEconomy/trade.yml
File notes

Trading between two players: items, money and experience, in one window that both of them are looking at.

HOW A TRADE IS KEPT HONEST

Every trade scam is the same trick. The thief waits for the other player to read the offer, and swaps something in the moment between the reading and the accepting. Three rules here make that moment not exist, and none of them can be switched off:

1. any change to either side cancels BOTH acceptances, not only the
   acceptance of whoever made the change;
2. once both have accepted the offer FREEZES, and a countdown runs
   during which nothing at all can be altered by anybody;
3. only then do the confirm buttons appear, and each shows the whole
   deal - what leaves, what arrives - in its own tooltip.

On top of that the right hand side of the screen describes every incoming item by what it really is: a renamed block says its real name, a shulker box says whether it is empty, a worn tool says how worn. That is where the rest of the scams live.

WHAT IS WRITTEN DOWN

Every completed trade goes into the database, in words, and is read back with "/trade log <player>". When two players tell two different stories, that row is the answer.

Items being offered have already left their owner's inventory, so they are written down too, and anything a crash leaves behind is handed back at the next login. Nothing is ever dropped on the ground.

config-version1
trade10 keys
shift-right-clicktrue

Shift plus right click on a player sends them an invitation, with no typing. Set to false to leave only /trade <player>.

request-expires60s

How long an invitation stands before it lapses, and how long a player has to wait before sending another one. The cooldown is what stops invitation spam being used to pester somebody.

request-cooldown5s
max-distance12

How far apart the two may be, in blocks. Checked all the way through, not only at the start: walking away in the middle of a trade is a trick, not an accident. 0 removes the check.

same-world-onlytrue
freeze3s

The frozen countdown after both have accepted, in seconds. This is the anti-scam: while it runs the offer cannot be touched by either side, so there is no last instant to swap anything in. Raise it on a server with a young playerbase; it will not go below one second.

session-timeout5m

A trade nobody finishes ends by itself and gives everything back.

allow-in-creativefalse

Creative mode is an infinite item duplicator, and a trade window turns duplicated items into somebody else's real ones. Leave false. A player with shadoweconomy.bypass.creative is allowed either way.

cancel-on-damagetrue

Being hit ends the trade. It closes an old trick that still works wherever it is left open: keep somebody in a screen, where they can neither fight back nor run, while a friend kills them.

announce-above100000

Above this figure of money the console gets one line naming both players, so a large trade is visible in the log without anybody having to go looking. 0 never announces.

money3 keys
enabledtrue
tax-percent0.0

A commission on the money that changes hands, taken from the sender. Where it ends up is decided once for the whole plugin, by economy.pay.tax-account in config.yml. 0 disables it.

max-per-trade0

The most money one player may put into a single trade. 0 = no limit. A rank can be given more with shadoweconomy.trade.limit.<figure>.

experience2 keys
enabledtrue
max-levels0

The most levels one player may put into a single trade. 0 = no limit.

The screen talks in levels because that is what a player reads on their own bar, but underneath it moves points: a level is worth more the higher it sits, and moving levels directly would create or destroy experience on every trade.

items3 keys
enabledtrue
blocked-materials
[BEDROCK, COMMAND_BLOCK, CHAIN_COMMAND_BLOCK, REPEATING_COMMAND_BLOCK, STRUCTURE_BLOCK, BARRIER, DEBUG_STICK]+4

Items that may never be traded. Useful for anything a player is not supposed to be able to pass on: quest items, staff tools, keys tied to one account.

blocked-names[ ]

Items whose name contains one of these words are refused. Matched without case, on the name the player sees.

worlds1 key
blocked[ ]

Worlds where trading is off. An event world or a minigame arena, usually - anywhere the items are handed out rather than earned.

recovery1 key
keep-days30

How long an item left over from an interrupted trade waits for its owner before it is cleared out, in days.

Languages

The texts the plugin shows to players, one file per language.

lang/

Texts and messages
2 files
plugins/ShadowEconomy/lang/
File notes

Colours are written with & codes: &a &c &7, &l for bold, &#FF8800 for an exact colour. <gray> style tags work too if you prefer them: the plugin understands both, everywhere.

Placeholders are written <like-this> and are NOT colours: <amount>, <player>, <prefix>. Leave them as they are. This file is the final fallback: a key missing everywhere else is looked up here, so keep it complete.

A message is always one line. Sound, channel and cooldown are written as neighbouring keys, the same name plus a suffix:

paid: "&aDone."
paid-sound: entity.experience_orb.pickup
paid-channel: ACTION_BAR     # CHAT | ACTION_BAR | TITLE | SUBTITLE | NONE
paid-cooldown: "2s"          # per player anti spam
paid-volume: 0.7
paid-pitch: 0.8

That way the message key stays the message: a translator touches only that, and anyone looking a key up finds it where it is written.

Lists are multi line descriptions (the lore of a GUI item).

Every message the plugin shows to players, one file per language. The keys are not listed one by one: here are the files, how many texts they hold and the placeholders they use.

FileLanguageTexts
lang/en_US.yml reference English 1,333
lang/it_IT.yml Italiano 1,333

Most used placeholders

The plugin replaces them with the right value: leave them written as they are.

  • <prefix>
  • <amount>
  • <player>
  • <item>
  • <price>
  • <count>
  • <plot>
  • <id>
  • <value>
  • <max>
  • <time>
  • <asset>
  • <total>
  • <balance>

Message groups

  • prefix 1
  • common 22
  • command 4
  • input 8
  • balance 5
  • pay 14
  • baltop 10
  • wallet 9
  • history 8
  • interest 1
  • confirm 5
  • eco 100
  • shop 73
  • shops 22
  • market 286
  • chestshop 86
  • district 178
  • finance 125
  • mining 74
  • token 45
  • bank 58
  • license 50
  • trade 149

Other

Ready-made content, examples, imports: the files you copy and edit as a model.

shops/

Shops, one per file
2 files
plugins/ShadowEconomy/shops/

2 files with the same structure. Below, 2 of them in full, one for each different shape; the others are listed by name.

  • crypto.yml
  • token.yml

Example shops/token.yml

File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/shops/token.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

The token shop.

Every file inside shops/ is a shop of its own: its own command, its own screen and its own money. This one is paid in EVENT TOKENS, the currency players earn at events - the "event_token" of tokens.yml, the one with currency: none, which the plugin registers as a real currency.

To make another, copy this file under another name: the whole folder is read, and there is no list anywhere to update.

WHAT IT CAN SELL

Anything, and several things at once in the same entry:

items         ordinary items, or a serialised custom item
permissions   permissions, granted with the command below
commands      commands run from the console
money         money of any currency

A VIP rank is a permission plus an announcement; a kit is items plus a little money; a crate key is a command. The shop does not know what any of them are: it does what the file says.

THE PRICES

Fixed, and in tokens. They do not move with demand the way the main shop's do, and that is deliberate: this is the rewards window, not a market.

Keys and ids are English because they are read by whoever runs the server. "title", "name" and "lore" are what players see, so those are the parts meant to be translated.

config-version1
shop11 keys
enabledtrue
idtoken
command"tokenshop"

The command that opens the screen, and its aliases.

aliases[tshop, tokenstore]
title"&#AB47BC&lToken Shop"
rows5
fillerBLACK_STAINED_GLASS_PANE
permission""

Needed to open it. Empty = everybody.

shop.pay-with1 key

What it is paid in. One of the two, never both:

currency: <id>   a currency from currencies.yml, or a token with
                 currency: none, which is a currency in every sense
asset: <id>      units of an asset on the exchange - see
                 shops/crypto.yml
currencyevent_token
shop
confirm-above50

Above this figure a second click is needed to confirm. Individual entries may override it with "confirm: true" or "confirm: false".

permission-command"lp user %player% permission set %permission% true"

How a permission is granted. There is no standard way: every permissions plugin has its own, and a command is the one thing that works with all of them. Out of the box this is LuckPerms syntax.

%player%  %uuid%  %permission%
The entries

Each one has:

slot                 where it sits. Without one, the first free cell
icon                 the material shown, or "item:" serialised
name / lore          how it presents itself
price                what it costs, in tokens
limit-per-player     how many ever, per player. 0 = no limit
limit-per-day        how many a day, per player. 0 = no limit
stock                how many ever, for the whole server
requires-permission  needed to see it at all
confirm              asks for the second click
give                 what it hands over
items10 keys
items
items.miner_kit7 keys
slot10
iconIRON_PICKAXE
name"&b&lMiner's Kit"
lore
["&7Everything you need to go down:", "&7a pickaxe, torches and something to eat."]+1
price8
limit-per-day2
items.miner_kit.give1 key
items
[{ material: IRON_PICKAXE, amount: 1 }, { material: TORCH, amount: 64 }, { material: COOKED_BEEF, amount: 16 }]+2
7 more entries shaped like miner_kit: shulker_box, ender_chest, coin_pouch, strongbox, extra_homes, repair, temporary_flight
items.chat_colours7 keys

The second row is centred on 20-22: it used to start at 19 and stop at 21, which left it hanging on the left of a row that is seven wide.

slot20
iconNAME_TAG
name"&e&lChat Colours"
lore["&7Write in chat with colour codes."]
price45
limit-per-player1
items.chat_colours.give1 key
permissions[essentials.chat.color]
one entry that puts all four together
items.vip_rank8 keys

Alone in the middle of the third row: it is the headline offer and it costs more than everything above it put together, so it gets its own line instead of trailing off the end of the second one.

slot31
iconNETHER_STAR
name"&#FFB300&lVIP Rank"
lore
["&7The rank, a welcome kit", "&7and five thousand coins.", "", "&8Once per player."]+3
price250
limit-per-player1
confirmtrue
items.vip_rank.give4 keys
permissions[group.vip]
items
[{ material: DIAMOND_PICKAXE, amount: 1 }, { material: GOLDEN_APPLE, amount: 8 }]+1
money[{ currency: coins, amount: 5000 }]
commands["broadcast &#FFB300%player% &7is now &#FFB300…]

Example shops/crypto.yml

File notes

IN ITALIAN: the same file with Italian names and descriptions is in esempi/it_IT/shops/crypto.yml inside this plugin's folder. Copy it over this one to use it: the plugin never reads it on its own.

The shop that is paid in crypto.

Exactly the same machinery as shops/token.yml: one line changes, "pay-with", which here names an ASSET on the exchange instead of a currency. It is paid in ShadowCoin, the one the mining rigs produce.

The circle closes by itself: you mine SHC with rigs, and with SHC you buy the parts to mine faster. The units spent do not go back on the market - they are burned, and the amount in circulation falls - which makes this shop the only brake on the coin's inflation.

ONE THING NOT TO DO

Do not put "money" rewards in here. The price of SHC on the market moves; the shop's does not. The first day SHC falls, buying SHC on the exchange and selling it back here at a fixed price becomes free money, and nobody notices until it is late. In exchange for crypto give items, permissions and commands. Never coins.

config-version1
shop11 keys
enabledtrue
idcrypto
command"cryptoshop"
aliases[shcshop, cryptostore]
title"&#FFB300&lCrypto Shop"
rows5
fillerBLACK_STAINED_GLASS_PANE
permission""
shop.pay-with1 key

Here is the whole difference from the other shop: it is paid in units of an asset from finance.yml, not in a currency. Prices are in SHC.

assetshc
shop
confirm-above5
permission-command"lp user %player% permission set %permission% true"
The entries

Rig parts are handed over with a command and not as items: they are custom items with a mark inside them, and "/rig give" is the way to make one without pasting a serialised item in here.

items8 keys
graphics cards: what a miner spends on
items.gpu_10606 keys
slot10
iconREDSTONE_TORCH
name"&c&lRTX-Redstone 1060"
lore
["&7The card everyone starts with.", "&822 MH/s &8- &8120 W"]+1
price1.5
items.gpu_1060.give1 key
commands["rig give gpu_1060 1 %player%"]
6 more entries shaped like gpu_1060: gpu_3070, gpu_4090, mb_server, psu_4000, cool_immersion, extra_rig_slot
a whole rig, for those who will not buy it piece by piece
items.complete_rig8 keys

21 and 23, not 22 and 24: the row above is three cards, the middle cell empty, three parts. These two straddle the same middle cell, so the two rows share one axis instead of one being pushed to the right.

slot21
iconBLAST_FURNACE
name"&6&lComplete Rig"
lore
["&7Pro case, Pro mainboard, 8 core CPU,", "&7four 3070s, power supply and cooling.", "", "&8Cheaper than buying the parts one by one.", "&8Only one per player."]+4
price26
limit-per-player1
confirmtrue
items.complete_rig.give1 key
commands
["rig give case_pro 1 %player%", "rig give mb_pro 1 %player%", "rig give cpu_8 1 %player%", "rig give gpu_3070 4 %player%", "rig give psu_2000 1 %player%", "rig give cool_liquid 1 %player%"]+5

All the documentation