[Breaking] Add exception when players have exceeded their account limit.

This might effect some plugins which hook Essentials for economy without using the API
This commit is contained in:
KHobbits 2014-02-02 16:07:32 +00:00
parent 161862bc53
commit 882ebae257
38 changed files with 151 additions and 83 deletions

View file

@ -21,6 +21,7 @@ import java.math.MathContext;
import java.util.logging.Level;
import java.util.logging.Logger;
import net.ess3.api.IEssentials;
import net.ess3.api.MaxMoneyException;
/**
@ -146,7 +147,14 @@ public class Economy
{
throw new NoLoanPermittedException();
}
user.setMoney(balance);
try
{
user.setMoney(balance);
}
catch (MaxMoneyException ex)
{
//TODO: Update API to show max balance errors
}
}
/**