Bladeren bron

We need to preserve block data with our double drops for silk touch. Fixes #2625

t00thpick1 10 jaren geleden
bovenliggende
commit
eff53d90ab
2 gewijzigde bestanden met toevoegingen van 3 en 1 verwijderingen
  1. 1 0
      Changelog.txt
  2. 2 1
      src/main/java/com/gmail/nossr50/skills/mining/Mining.java

+ 1 - 0
Changelog.txt

@@ -9,6 +9,7 @@ Key:
 
 Version 1.5.04-SNAPSHOT
  = Fixed bug where absorption hearts could be attacked by allied players
+ = Fixed bug where new forms of stone would drop the wrong type when mined with Silk Touch
 
 Version 1.5.03
  = Fixed bug where blocks would not get tracked correctly when using sticky pistons and slime blocks in certain situations

+ 2 - 1
src/main/java/com/gmail/nossr50/skills/mining/Mining.java

@@ -64,7 +64,8 @@ public class Mining {
             case QUARTZ_ORE:
             case REDSTONE_ORE:
             case STONE:
-                Misc.dropItem(blockState.getLocation(), new ItemStack(blockType));
+            case PRISMARINE:
+                Misc.dropItem(blockState.getLocation(), blockState.getData().toItemStack(1));
                 return;
 
             default: