1.15.2 Sign material

Discussion in 'Spigot Plugin Development' started by Trixxie, Feb 26, 2020.

  1. Hello!

    This is kinda stupid question but I can not wrap my head around this one, so when Mojang decided to push out different types of signs there is now so many different IDs for signs and LEGACY_SIGN will not work anymore as it is deprecated. What material should I use or should I list all them into hash? What is your suggestion?

    I am currently trying to work with event that if player clicks sign => stuff happens
    but I don't want it to work with certain signs only.
  2. SteelPhoenix


    Use Tag#SIGNS and Tag#isTagged()
  3. I assume your using Material.XXXX for what sign currently?

    If you use the actual BlockData, its just called WallSign or Sign.
  4. Tried that but it is crying me that expression is expected.

    Code (Java):
    if(e.getClickedBlock().getBlockData() == Sign || e.getClickedBlock().getBlockData() == WallSign){
  5. drives_a_ford


    You want to use the instanceof operator.