Merge remote-tracking branch 'refs/remotes/origin/develop' into bugfix/gem-hunters-dupe

This commit is contained in:
Sam 2017-05-20 17:46:07 +01:00
commit cbb63ba943
3 changed files with 6 additions and 5 deletions

View File

@ -12,7 +12,6 @@ import mineplex.core.common.util.UtilServer;
public class BanwaveAction extends AntiHackAction
{
private final AntiHack _antiHack = Managers.require(AntiHack.class);
private static final int BAN_DELAY_MINIMUM_MINUTES = 30;
private static final int BAN_DELAY_MAXIMUM_MINUTES = (int) TimeUnit.MINUTES.convert(2, TimeUnit.HOURS);
@ -24,6 +23,8 @@ public class BanwaveAction extends AntiHackAction
@Override
public void handle(PlayerViolationEvent event)
{
AntiHack _antiHack = Managers.get(AntiHack.class);
if (event.getViolations() >= (Math.floor(getMinVl() * .9)) && event.getPlayer().getMetadata("GWENEXTREMEPREJUDICE").get(0).asBoolean())
{
_antiHack.doBan(event.getPlayer(), event.getCheckClass(), true, _antiHack.getHoursBanned(event.getPlayer()));

View File

@ -7,8 +7,6 @@ import mineplex.core.antihack.AntiHack;
public class GEPBanAction extends AntiHackAction
{
private final AntiHack _antiHack = Managers.require(AntiHack.class);
public GEPBanAction(int vl)
{
super(vl);
@ -17,6 +15,8 @@ public class GEPBanAction extends AntiHackAction
@Override
public void handle(PlayerViolationEvent event)
{
AntiHack _antiHack = Managers.get(AntiHack.class);
if (event.getViolations() >= this.getMinVl() && event.getPlayer().getMetadata("GWENEXTREMEPREJUDICE").get(0).asBoolean())
{
_antiHack.doBan(event.getPlayer(), event.getCheckClass(), true, _antiHack.getHoursBanned(event.getPlayer()));

View File

@ -7,8 +7,6 @@ import mineplex.core.antihack.AntiHack;
public class ImmediateBanAction extends AntiHackAction
{
private final AntiHack _antiHack = Managers.require(AntiHack.class);
public ImmediateBanAction(int vl)
{
super(vl);
@ -17,6 +15,8 @@ public class ImmediateBanAction extends AntiHackAction
@Override
public void handle(PlayerViolationEvent event)
{
AntiHack _antiHack = Managers.get(AntiHack.class);
if (event.getViolations() >= (Math.floor(getMinVl() * .9)) && event.getPlayer().getMetadata("GWENEXTREMEPREJUDICE").get(0).asBoolean())
{
_antiHack.doBan(event.getPlayer(), event.getCheckClass(), true, _antiHack.getHoursBanned(event.getPlayer()));