Transactions Event
R3N3PDE opened this issue ยท 2 comments
Can your add a Transactions Event to Vault?
My Example:
@EventHandler
public void onTransaction(VaultTransactionEvent e){
Player p = e.getPlayer();
int bal = e.getBalance();
int addRemove = e.getAddetOrRemovedBalance();
Plugin p = e.getPluginSender();
if(e.getAction() == VaultTransaction.DEPOSIT){
Bukkit.getLogger().info("Give " + addRemove + " Chips from " + p.getName() + " by Plugin: " + p.getName() + "");
}else if(e.getAction() == VaultTransaction.WITHDRAWAL){
Bukkit.getLogger().info("Take " + addRemove + " Chips from " + p.getName() + " by Plugin: " + p.getName() + "");
}
e.setCancle(false or true);
}
this has already been discussed here: #315