Help with block protection

Discussion in 'Plugin Development' started by beatcomet, Oct 26, 2011.

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

    beatcomet

    Hi guys :)
    I need some help here. I made a plugin that's based on sign interaction, but I don't know how to protect the block below the sign and the block that the wall sign is attached to.
     
  2. Offline

    Father Of Time

    I've not worked with signs, but a quick search leads me to believe this would help you:

    Source:
    http://jd.bukkit.org/doxygen/d5/da4/classorg_1_1bukkit_1_1material_1_1Sign.html


    I hope this helps!
     
  3. Offline

    ItsHarry

  4. Offline

    Father Of Time

    Ya, I just began development on a "lite" version of craftbook circuits for our server to cut the fat and was suprized to see that what I would expect to be functions all related to one object is in fact broken up into two different objects, the Block.Sign class and the Material.Sign class. I needed to know what the sign was attached to which is part of the Material.Sign class, but then I needed to know the line content of the sign which is part of the Block.Sign class...

    Just doesn't seem very intuitive... But ehh, it worked...
     
    ItsHarry likes this.
  5. Offline

    beatcomet

    The problem is that I need to check if the destroyed block has a sign attached to it.
     
  6. Offline

    Father Of Time

    Then I would do a blocklister that listens to all block destruction, and on destruction if relative blocks facing north, south, east, west or top (the sides signs can be attached to) are a sign block cancel the event.
     
  7. Offline

    beatcomet

Thread Status:
Not open for further replies.

Share This Page