From 1f734582d4a69f8577e01b0f2af58e5bc01a701e Mon Sep 17 00:00:00 2001 From: nossr50 Date: Wed, 10 Apr 2019 04:34:27 -0700 Subject: [PATCH] Add delegates to exploit config --- .../antiexploit/ConfigExploitPrevention.java | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) diff --git a/src/main/java/com/gmail/nossr50/config/hocon/antiexploit/ConfigExploitPrevention.java b/src/main/java/com/gmail/nossr50/config/hocon/antiexploit/ConfigExploitPrevention.java index 4ae27d7bb..b9ea85a0e 100644 --- a/src/main/java/com/gmail/nossr50/config/hocon/antiexploit/ConfigExploitPrevention.java +++ b/src/main/java/com/gmail/nossr50/config/hocon/antiexploit/ConfigExploitPrevention.java @@ -16,6 +16,10 @@ public class ConfigExploitPrevention { @Setting(value = "Skills", comment = "Exploit settings for specific skills") private ConfigSectionExploitSkills configSectionExploitSkills = new ConfigSectionExploitSkills(); + /* + * BOILERPLATE GETTERS + */ + public boolean getEndermenEndermiteFix() { return configSectionGeneral.getEndermenEndermiteFix(); } @@ -47,4 +51,40 @@ public class ConfigExploitPrevention { public ConfigSectionExploitFishing getConfigSectionExploitFishing() { return configSectionExploitSkills.getConfigSectionExploitFishing(); } + + public long getFishingRodSpamMilliseconds() { + return getConfigSectionExploitFishing().getFishingRodSpamMilliseconds(); + } + + public float getOverFishingAreaSize() { + return getConfigSectionExploitFishing().getOverFishingAreaSize(); + } + + public boolean isPreventFishingExploits() { + return getConfigSectionExploitFishing().isPreventFishingExploits(); + } + + public int getOverfishingLimit() { + return getConfigSectionExploitFishing().getOverfishingLimit(); + } + + public boolean isAlertAdminsOnOverFishing() { + return getConfigSectionExploitFishing().isAlertAdminsOnOverFishing(); + } + + public int getRollXPGainCooldownSeconds() { + return getConfigSectionExploitAcrobatics().getRollXPGainCooldownSeconds(); + } + + public int getTeleportCooldownSeconds() { + return getConfigSectionExploitAcrobatics().getTeleportCooldownSeconds(); + } + + public int getAcrobaticLocationLimit() { + return getConfigSectionExploitAcrobatics().getAcrobaticLocationLimit(); + } + + public boolean isPreventAcrobaticsAbuse() { + return getConfigSectionExploitAcrobatics().isPreventAcrobaticsAbuse(); + } }