Core plugin

MCEconomy

MCEconomy is the money system for your Minecraft server. It holds as many currencies as you like, and it keeps a separate wallet for every MCIdentity character a player owns, so each character earns and spends on its own.

Version 1.1.0 Requires MCIdentity 4.0.1 or newer Minecraft 1.20 or newer SpigotMC, PaperMC, FoliaMC

Highlights

One wallet per character. Money belongs to the character a player is currently playing as, never to the player's Minecraft account as a whole.
Any number of currencies. Seven come ready to use, and you can add, rename, or remove them freely. Each one is either tradeable between players or locked to whoever earned it.
Balance window and payments. Players see every balance in a menu of currency heads, and can pay each other in tradeable currencies.
Full audit trail. Every change to a balance is recorded with what caused it, so any transaction can be traced later.
Five places to keep data. A local file out of the box, or MySQL, PostgreSQL, MongoDB, or one central server shared by your whole network.
One download for every server type. The same plugin file runs on SpigotMC, PaperMC, and FoliaMC and works out which one it is on by itself.

How it works

MCEconomy is built on top of MCIdentity, the plugin that lets one player own several characters. Each character is treated as a completely separate person.

A player picks a character

When a player switches to one of their MCIdentity characters, MCEconomy makes sure that character has its own economy account.

Wallets open as needed

The account holds one wallet per currency. A wallet is created the first time the character receives or checks that currency.

Every change is checked

Amounts can never be negative and a wallet can never go below zero. Anything that would overdraw a wallet is refused.

Every change is recorded

Each change is logged as money sent, received, spent, or donated, together with the reason it happened.

Because money follows the character, switching characters also switches wallets. A player's warrior and their merchant never share a balance.

Currencies

Each currency has a short internal name, a display name players see, an optional head picture for the balance window, and a setting that decides whether it can change hands.

CurrencyCan players pay it to each other?
CoinYes
CopperYes
SilverYes
GoldYes
PointNo, it stays with whoever earned it
CreditNo, it stays with whoever earned it
TokenNo, it stays with whoever earned it

These seven are the defaults in a fresh install. Any currency listed in the settings file is created when the plugin starts, and a changed display name or tradeable setting takes effect on the next start. A currency is tradeable unless you say otherwise.

What players can do

Check balances

The balance command opens a menu with one head for each currency, showing how much of it the current character holds. The menu grows by one row for every nine currencies, and when there are more currencies than fit, arrows at the bottom move between pages. Empty spaces are filled with plain black glass. Items in the menu cannot be taken.

Pay another player

The pay command sends money from your current character to the character another player is currently using. You name the player, the currency, and the amount. The payment goes through only when:

  • the other player is online and is not you,
  • the currency exists and is tradeable,
  • the amount is a whole number above zero,
  • both of you have an active character, and
  • you have enough of that currency.

The money leaves one wallet and arrives in the other in a single step, so it can never be lost halfway. Both players get a message confirming the payment. Another plugin on the server may also block a payment, in which case you are told it was blocked.

Both commands are open to every player with no permission needed, and both always act on the character the player is currently using.

Where data is kept

You choose one storage option in the settings file. The local file is the default and needs no setup.

Local file default

A small database file inside the plugin's own folder. Best for a single server.

MySQL or PostgreSQL

A shared database server, reached with its address, database name, and login. Good when several servers should read the same balances.

MongoDB

A document database, reached with its connection address and database name.

Central server

Every game server on your network talks to one MCEconomy central server over the web, using its address and a shared access token. Balances are then the same everywhere a player goes.

Getting started

  1. Install MCIdentity 4.0.1 or newer. MCEconomy will not load without it, and the server always starts MCIdentity first.
  2. Add the MCEconomy plugin file to your server and start it once. This creates the settings file.
  3. Open the settings file and turn on the master switch. A fresh install ships switched off, and MCEconomy shuts itself down until you turn it on.
  4. Pick a storage option and adjust the currency list if you want to.
  5. Restart the server.

The server needs Java 25. Database drivers are downloaded by the server automatically. If MCIdentity is missing or too old, MCEconomy reports it once and leaves character wallets unavailable rather than stopping the server from starting.

For plugin developers

Other plugins, such as shops, jobs, or quests, can use MCEconomy as their money system.

One shared provider. MCEconomy exposes a single provider that can look up currencies, read balances, check whether a wallet holds enough, give, take, set, and transfer money. All of it runs in the background so the server never waits on the database.
A chance to say no. Before a balance changes, an event is announced that any plugin can cancel, for example to stop payouts during a minigame.
A notice afterwards. After a balance changes, a second event announces the new balance so other plugins can react.
Accounts beyond players. An account is identified by a type and an ID, so a clan or guild plugin can keep its own treasury that never collides with player wallets.

The one rule for developers: store money against the character, never against the player's Minecraft account. MCMarket and MCSlayerRewards both follow this rule. The full developer guide lives in the repository.

Modules

MCEconomy is built from these modules. Each page says what the module holds and, for a published one, how to depend on it.

  • API — Pure Java contracts and models for currencies and wallets.
  • Common — MCEconomyProvider, currencies, the ledger and the storage backends.
  • Bukkit — Commands, the balance menu, events, configuration and bridges.
  • Tools — Pure Java MCAgents AI tools.