Class PlayerHudsHolderWrapper

java.lang.Object
dev.lone.itemsadder.api.FontImages.PlayerHudsHolderWrapper

public class PlayerHudsHolderWrapper extends Object
Class representing a container which holds all HUDs of a player.
  • Constructor Details

    • PlayerHudsHolderWrapper

      public PlayerHudsHolderWrapper(org.bukkit.entity.Player player)
  • Method Details

    • getInternal

      @Nullable public @Nullable Object getInternal()
      Gets the internal ItemsAdder object. Should only be used by the plugin developer.
    • exists

      public boolean exists()
      Check if the player HUDs holder is correctly registered in ItemsAdder.
    • getPlayer

      public org.bukkit.entity.Player getPlayer()
      Get owner of this holder.
      Returns:
      Owner of this holder.
    • recalculateOffsets

      public void recalculateOffsets()
      Force the recalculation the offsets if you have shown a new HUD, added/removed new font images to a PlayerCustomHudWrapper HUD.
    • sendUpdate

      public void sendUpdate()
      Forces the HUDs rendering packet to be sent to the player, this is useful if you have high frequency HUDs. Be careful sending this too fast, it may use a lot of bandwidth if you abuse it.