MineConomy 1.6

economy api .

  1. Raymart
    MineConomy

    Description

    welcome to my first economy API / library I hope you may help me to improve my code just contact me at spigot .

    Tutorial How to use it

    Firstly get the balance class instance using this code

    Code (Java):
    Balance balance = Balance.Balance();
    Now lets try to use all feautures .
    Firstly make your own insufficient balance using a listener

    You must not forgot to implements listener your class

    Code (Java):
    public YourClass implements Listener
    You must not forgot @EventHandler also
    This is the usage of the Event

    Code (Java):
    @EventHandler
    public void onEvent(InsufficientBalanceEvent e) {

    // set the insufficient balance message error
      e.setInsufficientMessage(String msg);

    }
    You may set the player's balance by doing this

    Code (Java):
    balance.set(Player p, int amount);
    Add amount to player's current balance

    Code (Java):
    balance.add(Player p, int amount);
    Reset player's balance from doing this

    Code (Java):
    balance.reset(Player p);
    Withdraw a balance to player by using this

    // Note you have no need to worried if the player has not enough balance the insufficientbalance event will throws
    Code (Java):
    balance.withdraw(Player p, int amount);
    Transfer player's balance to another player

    Code (Java):
    balance.transfer(Player sender, Player target);
    // the sender is the one who will send the money and the target player will get the sender's money

    Get the player's uuid

    Code (Java):
    balance.getData().getUUID(Player p);

    Get the player's balance (int)

    Code (Java):
    balance.get(Player p);
    You must not forgot this at your onEnable()

    Code (Java):
    if(Bukkit.getServer().getPluginManager().getPlugin("MineConomy") == null) {
    Bukkit.getLogger().severe("Disabled due to no dependancy found");
    Bukkit.getServer().getPluginManager().disablePlugin(this);
    return;
    }
    You must not forgot this at your plugin.yml also

    Code (Java):
    softdepend: [MineConomy]
    // or
    depend: [MineConomy]
    Developer Message

    after using my api as a dependancy :p I hope you may simply do a review and include the link of your plugin .​
    TheWinuXs and Compilable like this.

Recent Updates

  1. Updated
  2. Updated
  3. Gonna change

Recent Reviews

  1. azamp19
    azamp19
    5/5,
    Version: 1.6
    This api is awesome I love It I am adding it to a plugin of mine and can't wait for it to be finished thanks so much for making this.
    1. Raymart
      Author's Response
      thanks I'm waiting for it
  2. Yazio
    Yazio
    5/5,
    Version: 1.3
    Not bad... is it linked with vault??
    1. Raymart
      Author's Response
      lol its like vault :P its my own economy API please read the overview
  3. MaxGenre
    MaxGenre
    5/5,
    Version: 1.2
    I'll use it as api wait for upload , thanks .
    1. Raymart
      Author's Response
      like what I've said input your link also but you are not either starting for your project you may simply discuss this resource with your link .