1.21.1 - ★ Coinsystem ★ Free to use ★ icon

1.21.1 - ★ Coinsystem ★ Free to use ★ -----

API, CoinSystem, Coin, Coins, Money



[​IMG]
[​IMG]

This plugin allows you to integrate an efficient currency system into your system.​

Discord: https://discord.com/invite/FaHcQnunFp
To display coins in scoreboards etc use this placeholder with PlaceholderAPI:

%coinsystem_balance%

Cheap MC Server: Click
[​IMG]

Don't forget to depend my plugin in your plugin.yml, if you want to use my api.

Code (Text):
name: YourPlugin
main: path
version: 1.0
description: Info
depend: [CoinSystem]
Code (Text):


CoinApi.isCacheActive()

CoinApi.getForcedLivePlayerBalance(uuid); //Database coins
CoinApi.getPlayerBalance(uuid); //Cache if active otherwise Database coins
CoinApi.getUUID(playerName);
CoinApi.updatePlayerBalance(uuid, TransactionType.ADD/REMOVE, 5);

CoinPlayer coinPlayer = new CoinPlayer(uuid);

//Get Stats
coinPlayer.getCoinPlayerBalance();
coinPlayer.getForcedLiveBalance();
coinPlayer.getPlayer();
coinPlayer.getDatabaseId();
coinPlayer.getName();
coinPlayer.getUuid();
coinPlayer.isOnline();

//Update Stats
coinPlayer.setCoinPlayerBalance(new_balance);
coinPlayer.updateCoinPlayerBalance(TransactionType.ADD/REMOVE, value);

//Save
coinPlayer.exportPlayerDataToDatabase();
 
[​IMG]
  • /updatecoins <name,uuid> <amount> | system.commands.coins.update
  • /pay <name,uuid> <amount> | system.commands.coins.pay
  • /coins [name,uuid] |
    system.commands.coins.display &&
    system.commands.coins.display.others
  • /coinlog [payments,update_coins] [name or uuid] |
    system.commands.coinlog |
    system.commands.coinlog.cache |
    system.commands.coinlog.payments |
    system.commands.coinlog.update_coins
  • /topcoins |
    system.commands.coins.top
Pros:
  • MySQL
  • JSON Files
  • 1 own Event
  • - PlayerPayPlayerEvent
  • All Commands editable
  • No command registered in the PluginYML
  • Files update automatically when an update is installed by you, if we should change something in the configs.
  • Pay limit ( Permissions )
  • Default Balance editable for newbies
  • Cache

[​IMG]
Code (Text):

@EventHandler
public void onPlayerPayPlayerEvent(PlayerPayPlayerEvent event)
{
    Bukkit.getConsoleSender().sendMessage("PlayerPayPlayerEvent");

    CoinPlayer coinPlayer = event.getCoinPlayer();
    CoinPlayer coinTargetPlayer = event.getCoinTargetPlayer();

    int payedCoins = event.getPayedCoins();

    Bukkit.getConsoleSender().sendMessage("[LOG] " + coinPlayer.getName() + " has payed " + payedCoins + " coins to " + coinTargetPlayer.getName() + ".");
    Bukkit.getConsoleSender().sendMessage("");
    Bukkit.getConsoleSender().sendMessage("Account comparisons:");

    Bukkit.getConsoleSender().sendMessage("Payer old: " + event.getOldCoinBalance());
    Bukkit.getConsoleSender().sendMessage("Payer new: " + event.getNewCoinBalance());
    Bukkit.getConsoleSender().sendMessage("");
    Bukkit.getConsoleSender().sendMessage("Receiver old: " + event.getTargetOldCoinBalance());
    Bukkit.getConsoleSender().sendMessage("Receiver new: " + event.getTargetNewCoinBalance());
}
 
Terms of Service:

You are not allowed to publish my code in any other form.
Errors are not written in a review but can be posted via private message or discussion.
You are not permitted to sell, give or redistribute this plugin
You can't claim this plugin as your own
[​IMG]
Resource Information
Author:
----------
Total Downloads: 4,236
First Release: Jan 23, 2020
Last Update: Feb 2, 2025
Category: ---------------
All-Time Rating:
7 ratings
Find more info at discord.com...
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings