瀏覽代碼

Fixed Woodcutting accidentally using Mining double drop values.

GJ 12 年之前
父節點
當前提交
716c4d3783

+ 1 - 0
Changelog.txt

@@ -13,6 +13,7 @@ Version 1.4.00-dev
  = Fixed bug where Impact was applied incorrectly due to an inverted method call
  = Fixed bug where Impact improperly determined the defender's armor
  = Fixed ArrayIndexOutOfBoundsException resulting from being unranked in a skill when using FlatFile
+ = Fixed Woodcutting accidentally using Mining double drop values.
  ! Changed how Tree Feller is handled, it should now put less stress on the CPU
  ! Changed Fisherman's Diet and Farmer's Diet to use two seperate config values
 

+ 1 - 1
src/main/java/com/gmail/nossr50/config/AdvancedConfig.java

@@ -101,7 +101,7 @@ public class AdvancedConfig extends ConfigLoader {
     public int getHylianLucksMaxLevel() { return config.getInt("Skills.Herbalism.HylianLuck_MaxBonusLevel", 1000); }
 
     /* MINING */
-    public int getMiningDoubleDropChance() { return config.getInt("Skills.Mining.DoubleDrops_ChanceMax", 100); }
+    public double getMiningDoubleDropChance() { return config.getDouble("Skills.Mining.DoubleDrops_ChanceMax", 100.0D); }
     public int getMiningDoubleDropMaxLevel() { return config.getInt("Skills.Mining.DoubleDrops_MaxBonusLevel", 1000); }
 
     public int getBlastMiningRank1() { return config.getInt("Skills.Mining.BlastMining_Rank1", 125); }

+ 2 - 2
src/main/java/com/gmail/nossr50/skills/gathering/WoodCutting.java

@@ -242,8 +242,8 @@ public class WoodCutting {
      * @param block Block being broken
      */
     private static void woodCuttingProcCheck(Player player, Block block) {
-        final int MAX_CHANCE = ADVANCED_CONFIG.getMiningDoubleDropChance();
-        final int MAX_BONUS_LEVEL = ADVANCED_CONFIG.getMiningDoubleDropMaxLevel();
+        final int MAX_CHANCE = ADVANCED_CONFIG.getWoodcuttingDoubleDropChance();
+        final int MAX_BONUS_LEVEL = ADVANCED_CONFIG.getWoodcuttingDoubleDropMaxLevel();
         byte type = block.getData();
 
         if ((type & 0x4) == 0x4)