diff --git a/src/main/java/me/ryanhamshire/GriefPrevention/DataStore.java b/src/main/java/me/ryanhamshire/GriefPrevention/DataStore.java index a7844ec..a278dde 100644 --- a/src/main/java/me/ryanhamshire/GriefPrevention/DataStore.java +++ b/src/main/java/me/ryanhamshire/GriefPrevention/DataStore.java @@ -1055,7 +1055,7 @@ public abstract class DataStore //start a cooldown for this attacker/defender pair Long now = Calendar.getInstance().getTimeInMillis(); - Long cooldownEnd = now + 1000 * 60 * 60; //one hour from now + Long cooldownEnd = now + 1000 * 60 * GriefPrevention.instance.config_siege_cooldownEndInMinutes; //one hour from now this.siegeCooldownRemaining.put(siegeData.attacker.getName() + "_" + siegeData.defender.getName(), cooldownEnd); //start cooldowns for every attacker/involved claim pair diff --git a/src/main/java/me/ryanhamshire/GriefPrevention/GriefPrevention.java b/src/main/java/me/ryanhamshire/GriefPrevention/GriefPrevention.java index 0c457ff..1e44b13 100644 --- a/src/main/java/me/ryanhamshire/GriefPrevention/GriefPrevention.java +++ b/src/main/java/me/ryanhamshire/GriefPrevention/GriefPrevention.java @@ -136,8 +136,8 @@ public class GriefPrevention extends JavaPlugin public ArrayList config_siege_enabledWorlds; //whether or not /siege is enabled on this server public ArrayList config_siege_blocks; //which blocks will be breakable in siege mode - public int config_siege_doorsOpenSeconds; // how before claim is re-secured after siege win - + public int config_siege_doorsOpenSeconds; // how before claim is re-secured after siege win + public int config_siege_cooldownEndInMinutes; public boolean config_spam_enabled; //whether or not to monitor for spam public int config_spam_loginCooldownSeconds; //how long players must wait between logins. combats login spam. public int config_spam_loginLogoutNotificationsPerMinute; //how many login/logout notifications to show per minute (global, not per player) @@ -757,7 +757,7 @@ public class GriefPrevention extends JavaPlugin } this.config_siege_doorsOpenSeconds = config.getInt("GriefPrevention.Siege.DoorsOpenDelayInSeconds", 5*60); - + this.config_siege_cooldownEndInMinutes = config.getInt("GriefPrevention.Siege.CooldownEndInMinutes", 60); this.config_pvp_noCombatInPlayerLandClaims = config.getBoolean("GriefPrevention.PvP.ProtectPlayersInLandClaims.PlayerOwnedClaims", this.config_siege_enabledWorlds.size() == 0); this.config_pvp_noCombatInAdminLandClaims = config.getBoolean("GriefPrevention.PvP.ProtectPlayersInLandClaims.AdministrativeClaims", this.config_siege_enabledWorlds.size() == 0); this.config_pvp_noCombatInAdminSubdivisions = config.getBoolean("GriefPrevention.PvP.ProtectPlayersInLandClaims.AdministrativeSubdivisions", this.config_siege_enabledWorlds.size() == 0); @@ -888,7 +888,7 @@ public class GriefPrevention extends JavaPlugin outConfig.set("GriefPrevention.Siege.Worlds", siegeEnabledWorldNames); outConfig.set("GriefPrevention.Siege.BreakableBlocks", breakableBlocksList); outConfig.set("GriefPrevention.Siege.DoorsOpenDelayInSeconds", this.config_siege_doorsOpenSeconds); - + outConfig.set("GriefPrevention.Siege.CooldownEndInMinutes", this.config_siege_cooldownEndInMinutes); outConfig.set("GriefPrevention.EndermenMoveBlocks", this.config_endermenMoveBlocks); outConfig.set("GriefPrevention.SilverfishBreakBlocks", this.config_silverfishBreakBlocks); outConfig.set("GriefPrevention.CreaturesTrampleCrops", this.config_creaturesTrampleCrops);