Interface Viewable

All Known Subinterfaces:
Allay, Animal, AreaEffectCloud, Armadillo, ArmorStand, Arrow, Axolotl, Bat, Bee, Blaze, BlockDisplay, Boat, Bogged, Breeze, BreezeWindCharge, Camel, Cat, CaveSpider, ChestBoat, ChestMinecart, Chicken, Cod, CommandBlockMinecart, Cow, Creeper, Display, Dolphin, Donkey, DragonFireball, Drowned, Egg, ElderGuardian, EndCrystal, EnderDragon, Enderman, Endermite, EnderPearl, Entity, Evoker, EvokerFangs, ExperienceBottle, ExperienceOrb, EyeOfEnder, FallingBlock, Fireball, FireworkRocket, FishingBobber, Fox, Frog, FurnaceMinecart, Ghast, Giant, GlowItemFrame, GlowSquid, Goat, Guardian, Hoglin, HopperMinecart, Horse, Husk, Illusioner, Interaction, IronGolem, Item, ItemDisplay, ItemFrame, LeashKnot, LightningBolt, LivingEntity, Llama, LlamaSpit, MagmaCube, Minecart, Mob, Monster, Mooshroom, Mule, Ocelot, OminousItemSpawner, Painting, Panda, Parrot, Phantom, Pig, Piglin, PiglinBrute, Pillager, Player, PolarBear, Potion, Projectile, Pufferfish, Rabbit, Raider, Ravager, Salmon, Scoreboard, Sheep, Shulker, ShulkerBullet, Silverfish, Skeleton, SkeletonHorse, Slime, SmallFireball, Sniffer, Snowball, SnowGolem, SpawnerMinecart, SpectralArrow, Spider, Squid, Stray, Strider, Tadpole, TextDisplay, Tnt, TntMinecart, TraderLlama, Trident, TropicalFish, Turtle, Vex, Villager, Vindicator, WanderingTrader, Warden, WindCharge, Witch, Wither, WitherSkeleton, WitherSkull, Wolf, Zoglin, Zombie, ZombieHorse, ZombieVillager, ZombifiedPiglin

public interface Viewable
Represents an object that is viewable by players.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    addViewer(@NotNull Player player)
    Adds a viewer.
    boolean
    removeViewer(@NotNull Player player)
    Removes a viewer.
    @NotNull Collection<Player>
    Gets the viewers of the object.
  • Method Details

    • viewers

      @NotNull @NotNull Collection<Player> viewers()
      Gets the viewers of the object.
      Returns:
      the viewers
      Since:
      1.0.0
    • addViewer

      boolean addViewer(@NotNull @NotNull Player player)
      Adds a viewer.
      Parameters:
      player - the viewer to add
      Returns:
      whether the viewer was added
      Since:
      1.0.0
    • removeViewer

      boolean removeViewer(@NotNull @NotNull Player player)
      Removes a viewer.
      Parameters:
      player - the viewer to remove
      Returns:
      whether the viewer was removed
      Since:
      1.0.0