Sfoglia il codice sorgente

Cacti & Sugar Cane are an exception, because the bottom block is
normally player-placed but the top two are grown naturally.

GJ 12 anni fa
parent
commit
e31b7d5c48

+ 3 - 2
src/main/java/com/gmail/nossr50/skills/herbalism/HerbalismManager.java

@@ -113,11 +113,12 @@ public class HerbalismManager extends SkillManager {
      * @param blockState The {@link BlockState} to check ability activation for
      */
     public void herbalismBlockCheck(BlockState blockState) {
-        if (mcMMO.placeStore.isTrue(blockState)) {
+        Material material = blockState.getType();
+
+        if (mcMMO.placeStore.isTrue(blockState) && (material != Material.CACTUS || material != Material.SUGAR_CANE_BLOCK)) {
             return;
         }
 
-        Material material = blockState.getType();
         HerbalismBlock herbalismBlock = HerbalismBlock.getHerbalismBlock(material);
         ItemStack drop = null;
         int amount = 1;