HomeJavaModsJustMoney
JustMoney
[​IMG]

JustMoney is an economy plugin for Bukkit that adds just money, and not a ton of features that nobody ever uses. Just upload the plugin to your server, and everything just works out of the box.

Besides the very easy usage, the plugin comes with a handful of other useful features, namely:

Commands
The /money command can also be accessed via /balance or /bal.
The optional <world> argument can only be used if multi-world is enabled in the config. If the argument is left out, the player's current world is used instead.

/money [<world>] – Show your own balance
/money <player> [<world>] – Show the balance of another player
/money send <player> <amount> [<world>] – Send money to another player
/money set <amount> [<world>] – Set your own balance
/money set <player> <amount> [<world>] – Set the balance of another player
/money give <amount> [<world>] – Add money to your own account
/money give <player> <amount> [<world>] – Add money to the account of another player
/money take <amount> [<world>] – Withdraw money from your own account
/money take <player> <amount> [<world>] – Withdraw money from the account of another player
/money help – Show the command usage

Permissions
These should be self-explanatory.

Spoiler: Developer API
Developer API
I highly recommend using Vault to hook into your server's economy, as it provides an API that almost all current economy plugins hook into. If for some reason, you still want to hook directly into JustMoney, it is published on CodeMC's maven repository:

Replace {version} with the respective version
Code (XML):
<repository>
    <id>codemc-repo </id>
    <url>https://repo.codemc.io/repository/maven-public/ </url>
</repository>

<dependency>
    <groupId>de.epiceric.justmoney </groupId>
    <artifactId>justmoney </artifactId>
    <version>{version} </version>
    <scope>provided </scope>
</dependency>
Code (Text):
repositories {
   maven {
       url = "https://repo.codemc.io/repository/maven-public/"
   }
}

dependencies {
   compileOnly 'de.epiceric.justmoney:justmoney:{version}'
}
Example Usage
Any changes to an account's balance done via BankAccount#setBalance(...), BankAccount#withdraw(...) or BankAccount#deposit(...) are automatically stored to the database or file system.

Have a look at the javadoc
Code (Java):
World world = ... ;
OfflinePlayer vendor = ... ;
Player customer = ... ;
double price = ... ;

JustMoney plugin = JavaPlugin. getPlugin (JustMoney. class ) ;
BankManager manager = plugin. getBankManager ( ) ;

BankAccount vendorAccount = manager. getBankAccount (vendor ) ;
BankAccount customerAccount = manager. getBankAccount (customer ) ;

if (customerAccount. getBalance (world ) >= price ) {
   customerAccount. withdraw (price, world ) ;
   vendorAccount. deposit (price, world ) ;
} else {
   customer. sendMessage ( "You don't have enough money!" ) ;
    return ;
}

// or using the server's default world and using try-catch

try {
   customerAccount. withdraw (price ) ;
   vendorAccount. deposit (price ) ;
} catch (NotEnoughMoneyException ex ) {
   customer. sendMessage ( "You don't have enough money!" ) ;
    return ;
}

customer. sendMessage ( "You now have " + customerAccount. formatBalance ( ) + " left on your account!" ) ;

[​IMG]
View the source on GitHub
Get development builds

Commands

Plugin details

Read from the plugin's own plugin.yml.

Quick facts

Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.

JustMoney is a free Minecraft Java mod. Compatible with Minecraft 1.7, 1.8, 1.9, 1.10 and newer. Downloaded 3,933 times (via Spigot). Download it and open it directly in the game.

Explore more