From 4737441f9b239f7a248cfc7e3d10c0e4be5c747c Mon Sep 17 00:00:00 2001 From: Daniel Saukel Date: Fri, 29 Apr 2016 15:46:12 +0200 Subject: [PATCH] Use seconds instead of ticks in the config --- .../io/github/dre2n/dungeonsxl/config/MainConfig.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/io/github/dre2n/dungeonsxl/config/MainConfig.java b/src/main/java/io/github/dre2n/dungeonsxl/config/MainConfig.java index d8807083..68028f5d 100644 --- a/src/main/java/io/github/dre2n/dungeonsxl/config/MainConfig.java +++ b/src/main/java/io/github/dre2n/dungeonsxl/config/MainConfig.java @@ -27,7 +27,7 @@ import org.bukkit.configuration.ConfigurationSection; */ public class MainConfig extends BRConfig { - public static final int CONFIG_VERSION = 3; + public static final int CONFIG_VERSION = 4; private String language = "en"; private boolean enableEconomy = false; @@ -43,7 +43,7 @@ public class MainConfig extends BRConfig { /* Secure Mode*/ private boolean secureModeEnabled = false; - private long secureModeCheckInterval = 100; + private double secureModeCheckInterval = 5; private boolean openInventories = false; private boolean dropItems = false; private List editCommandWhitelist = new ArrayList<>(); @@ -134,7 +134,7 @@ public class MainConfig extends BRConfig { * @return the interval for the check task */ public long getSecureModeCheckInterval() { - return secureModeCheckInterval; + return (long) (secureModeCheckInterval * 20); } /** @@ -254,7 +254,7 @@ public class MainConfig extends BRConfig { } if (config.contains("secureMode.checkInterval")) { - secureModeCheckInterval = config.getLong("secureMode.checkInterval"); + secureModeCheckInterval = config.getDouble("secureMode.checkInterval"); } if (config.contains("secureMode.editCommandWhitelist")) {