How to get the right drops of a block with enchanted tool?

Discussion in 'Plugin Development' started by InflamedSebi, Jun 7, 2013.

Thread Status:
Not open for further replies.
  1. Offline

    InflamedSebi

    Code:java
    1. ArrayList<ItemStack> dropList = new ArrayList<ItemStack>();
    2. dropList.addAll(block.getDrops(tool));


    block.getDrops(tool) seems to ignore enchantements (tested with fortune and also with silktouch).

    Does anyone know how to get the right drop? (that care about enchantements)
     
  2. Offline

    MUG806

    I think you will have to check which enchantments the tool has and manually change the drops based on the tool, the block and the enchantment.
     
  3. Offline

    InflamedSebi

    really? :/ bukkit should create a method for it ...
     
    bennie3211 likes this.
Thread Status:
Not open for further replies.

Share This Page