Ignore Entity Interaction

Discussion in 'Spigot Plugin Development' started by TheFancyWhale, Jul 7, 2015.

  1. Does anyone know of a way to ignore interactions with an invisible armor stand? I want to make it so if you for example right click where an invisible armor stand is, you click the block behind the armor stand, or if you try to break a block on the other side of the armor stand, you do so. Any ideas?
     
  2. Set NBT tag "Marker" to true. This makes it have a tiny hitbox.
     
    • Informative Informative x 1
  3. Doesn't seem to have made a difference:
    Code (Text):
        public void setEntityNBT(Entity e) {

            net.minecraft.server.v1_8_R1.Entity nmsEntity = ((CraftEntity) e).getHandle();

            NBTTagCompound tag = new NBTTagCompound();

            nmsEntity.c(tag);

            tag.setBoolean("Marker", true);

            EntityLiving el = (EntityLiving) nmsEntity;
            el.a(tag);
        }
     
  4. Since you're making a fake stand that isn't handled by bukkit, you can't just set the NBT tags without sending them to the client manually.