Hello, I'm looking for someone to code a plugin for me, here is what I need. Name: Barb Wire Command/Permissions: There is no command, To place cobweb down: barbwire.place About: Place a cobweb down and when you walk into it, it takes away two hearts per second. Then right click the web with shears to delete the web and play sound when you delete. Sound: random.break Bypass: Placing the cobwebs in a region defined with world guard, bypass it so you can place it anywhere. Thanks, hope you guys can pull this off, thanks
@Kyleyocats Shears already break cobwebs? Haven't tested this, I'm just writing it here: Code: @EventHandler public void playerTouch(PlayerInteractEvent e) { if (e.getAction().equals(Action.RIGHT_CLICK_BLOCK)) { if (e.getPlayer().getHeldItem() != null && e.getPlayer().getHeldItem().getType() == Material.SHEARS) { e.getBlock().setType(Material.AIR); } } }
I need the cobweb to do 1/2 heart damage for each second and instead of left clicking with shears, i want it right click.. You can always send me the code and I can make the plugin myself. <Merged by sleepy Walshy>
Post the whole code? It's not working. It gives me a few errors. But I also need it when you right click the web with shears it breaks it and plays this sound: random.break I also need it to do 1/2 heart of damage per sec when u go in the web. <Edited by bwfcwalshy: Merged posts, please use the edit button rather than double posting.>
@Kyleyocats I'll put it together when I get a chance. Just use the existing Barbed Wire plugin to hande the damage though
I wont spoonfeed but here's how to do it. 1: Breaking. Check interacation If it's right click Check item in hand and clicked block. Then set the type to air. 2: Damage and sound Check player move event every so often, see if they are in a cobweb. If so damage them and play a sound
I learned how to code it, thanks. Filled <Edited by bwfcwalshy: Merged posts, please use the edit button rather than double posting.>