Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

[1.8] Drop item from a vanilla block


Jeerdus
 Share

Recommended Posts

if the block already has an item then you can use HarvestDropsEvent. you first add a chance float then add your item. if the block has no drops or you want the item to drop with any tool (such as allowing obsidian to drop from an iron pciaxe) then you can use BreakEvent and spawn the item in the world.

Link to comment
Share on other sites

if the block has no drops or you want the item to drop with any tool (such as allowing obsidian to drop from an iron pciaxe) then you can use BreakEvent and spawn the item in the world.

This is not the correct approach.

a) If the block does not have drops, HarvestDropsEvent will still fire.

b) To make a block harvestable that was previously not, use PlayerEvent.HarvestCheck.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share



×
×
  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.