Custom tools

Discussion in 'Plugin Development' started by BlockBuilder, May 22, 2014.

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



    I am new to eclipse and i had an idea for custem tools and i would like to know how i can do this.
    What i want to create is:

    Hammer: just like in FeedTheBeast, breaking blocks in a 3 by 3 wall shape.

    SuperShovel: when breaking 1 gravel, instantly destroy all gravel attached (dont know if this is possible)
  2. Offline


    What have you tried so far?
  3. Offline


    Haven't tried allot.

    I know how to give some a tool with an command, but i have no idea how i could create this.
  4. Offline


    Create an ItemStack. Then in your BlockBreakEvent, check to see if your event .getItem() is equal to the item stack. Then do your actions from there. And I'm 100% sure that a SuperShovel is possible.
  5. Offline


    You can use my block generation class in the resources section to make the air appear.
  6. Offline



    What teej107 said is correct

    Just check if the players item in hand is the material you want the hammer to be in the block break event and if it's that item you just need to get the 8 surrounding blocks and set them to air.

    If you want them to drop you could drop 8 items using the world.dropItemNaturally method (I am assuming it is called that).

    I think there is a method to set the durability of an item aswell, so you could also make the durability decrease 9 times because the player broke 9 blocks.
  7. Offline


Thread Status:
Not open for further replies.

Share This Page