From 558e4f4dd010dad0215a1a7cdf6dc385905f19b0 Mon Sep 17 00:00:00 2001 From: GJ Date: Thu, 15 Mar 2012 10:24:42 -0400 Subject: [PATCH] Added config option to disable wheat replanting. --- Changelog.txt | 1 + src/main/java/com/gmail/nossr50/config/LoadProperties.java | 5 +++-- src/main/java/com/gmail/nossr50/skills/Herbalism.java | 5 ++++- src/main/resources/config.yml | 1 + 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/Changelog.txt b/Changelog.txt index 9a73cecf6..897a687c9 100644 --- a/Changelog.txt +++ b/Changelog.txt @@ -13,6 +13,7 @@ Version 2.0.00-dev + Added offline user functionality to mmoedit + Added bookshelves to list of blocks that don't trigger abilities. + Added 'mcmmo.skills.repair.arcanebypass' permission node to bypass Arcane Repair and keep your enchantments + + Added config option to disable Herbalism's instant wheat replanting = Fixed Green Terra not awarding Triple Drops = Fixed ClassCastException from Taming preventDamage checks = Fixed issue with Blast Mining not seeing TNT for detonation due to snow diff --git a/src/main/java/com/gmail/nossr50/config/LoadProperties.java b/src/main/java/com/gmail/nossr50/config/LoadProperties.java index 1ef24c587..63637c814 100644 --- a/src/main/java/com/gmail/nossr50/config/LoadProperties.java +++ b/src/main/java/com/gmail/nossr50/config/LoadProperties.java @@ -21,7 +21,7 @@ public class LoadProperties { woodcuttingrequiresaxe, anvilmessages, mayDowngradeEnchants, mayLoseEnchants, fishingDrops, aDisplayNames, pDisplayNames, enableSmoothToMossy, enableDirtToGrass, statsTracking, eventCallback, herbalismHungerBonus, - repairArmor, repairTools, perLevelTools; + repairArmor, repairTools, perLevelTools, wheatRegrowth; public static String MySQLtablePrefix, MySQLuserName, MySQLserverName, MySQLdbName, MySQLdbPass, nWood, nStone, @@ -210,6 +210,7 @@ public class LoadProperties { mlilypad = readInteger("Experience.Herbalism.Lily_Pads", 100); mvines = readInteger("Experience.Herbalism.Vines", 10); herbalismHungerBonus = readBoolean("Skills.Herbalism.Hunger_Bonus", true); + wheatRegrowth = readBoolean("Skills.Herbalism.Instant_Wheat_Regrowth", true); moak = readInteger("Experience.Woodcutting.Oak", 70); mbirch = readInteger("Experience.Woodcutting.Birch", 90); @@ -279,7 +280,7 @@ public class LoadProperties { chimaeraWingEnable = readBoolean("Items.Chimaera_Wing.Enabled", true); dAxe = readInteger("Items.Diamond.Axe", 750); dHoe = readInteger("Items.Diamond.Hoe", 750); - dShovel = readInteger("Items.Diamond.Shovel", 750); + dShovel = readInteger("Items.Diamond.Shovel", 750); dSword = readInteger("Items.Diamond.Sword", 750); dPickaxe = readInteger("Items.Diamond.Pickaxe", 750); gAxe = readInteger("Items.Gold.Axe", 500); diff --git a/src/main/java/com/gmail/nossr50/skills/Herbalism.java b/src/main/java/com/gmail/nossr50/skills/Herbalism.java index eb5872905..7e12ae37e 100644 --- a/src/main/java/com/gmail/nossr50/skills/Herbalism.java +++ b/src/main/java/com/gmail/nossr50/skills/Herbalism.java @@ -149,7 +149,10 @@ public class Herbalism { if (data == CropState.RIPE.getData()) { mat = Material.WHEAT; xp = LoadProperties.mwheat; - greenThumbWheat(block, player, event, plugin); + + if (LoadProperties.wheatRegrowth) { + greenThumbWheat(block, player, event, plugin); + } } break; diff --git a/src/main/resources/config.yml b/src/main/resources/config.yml index 30590855a..54a74517a 100644 --- a/src/main/resources/config.yml +++ b/src/main/resources/config.yml @@ -147,6 +147,7 @@ Skills: SmoothBrick_To_MossyBrick: true Dirt_To_Grass: true Hunger_Bonus: true + Instant_Wheat_Regrowth: true Mining: Level_Cap: 0 Requires_Pickaxe: true