Class VanillaHudElements

java.lang.Object
net.fabricmc.fabric.api.client.rendering.v1.hud.VanillaHudElements

public final class VanillaHudElements extends Object
A hud element that has an identifier attached for use in HudElementRegistry.

The identifiers in this interface are the vanilla hud layers in the order they are drawn in. The first element is drawn first, which means it is at the bottom. All vanilla layers except SLEEP are in sub drawers and have a render condition attached (GameOptions.hudHidden). Operations relative to any element will generally inherit that element's render condition. There is currently no mechanism to change the render condition of an element.

For common use cases and more details on how this API deals with render condition, see HudElementRegistry.

  • Field Details

    • MISC_OVERLAYS

      public static final Identifier MISC_OVERLAYS
      The identifier for the vanilla miscellaneous overlays (such as vignette, spyglass, and powder snow) element.
    • CROSSHAIR

      public static final Identifier CROSSHAIR
      The identifier for the vanilla crosshair element.
    • SPECTATOR_MENU

      public static final Identifier SPECTATOR_MENU
      The identifier for the vanilla spectator menu.
    • HOTBAR

      public static final Identifier HOTBAR
      The identifier for the vanilla hotbar.
    • ARMOR_BAR

      public static final Identifier ARMOR_BAR
      The identifier for the player armor level bar.
    • HEALTH_BAR

      public static final Identifier HEALTH_BAR
      The identifier for the player health bar.
    • FOOD_BAR

      public static final Identifier FOOD_BAR
      The identifier for the player hunger level bar.
    • AIR_BAR

      public static final Identifier AIR_BAR
      The identifier for the player air level bar.
    • MOUNT_HEALTH

      public static final Identifier MOUNT_HEALTH
      The identifier for the vanilla mount health.
    • INFO_BAR

      public static final Identifier INFO_BAR
      The identifier for the info bar, either empty, experience bar, locator, or jump bar.
    • EXPERIENCE_LEVEL

      public static final Identifier EXPERIENCE_LEVEL
      The identifier for experience level tooltip.
    • HELD_ITEM_TOOLTIP

      public static final Identifier HELD_ITEM_TOOLTIP
      The identifier for held item tooltip.
    • SPECTATOR_TOOLTIP

      public static final Identifier SPECTATOR_TOOLTIP
      The identifier for the vanilla spectator tooltip.
    • STATUS_EFFECTS

      public static final Identifier STATUS_EFFECTS
      The identifier for the vanilla status effects element.
    • BOSS_BAR

      public static final Identifier BOSS_BAR
      The identifier for the vanilla boss bar element.
    • SLEEP

      public static final Identifier SLEEP
      The identifier for the vanilla sleep overlay element.
    • DEMO_TIMER

      public static final Identifier DEMO_TIMER
      The identifier for the vanilla demo timer element.
    • DEBUG

      public static final Identifier DEBUG
      The identifier for the vanilla debug hud element.
    • SCOREBOARD

      public static final Identifier SCOREBOARD
      The identifier for the vanilla scoreboard element.
    • OVERLAY_MESSAGE

      public static final Identifier OVERLAY_MESSAGE
      The identifier for the vanilla overlay message element.
    • TITLE_AND_SUBTITLE

      public static final Identifier TITLE_AND_SUBTITLE
      The identifier for the vanilla title and subtitle element.

      Note that this is not the sound subtitles.

    • CHAT

      public static final Identifier CHAT
      The identifier for the vanilla chat element.
    • PLAYER_LIST

      public static final Identifier PLAYER_LIST
      The identifier for the vanilla player list element.
    • SUBTITLES

      public static final Identifier SUBTITLES
      The identifier for the vanilla sound subtitles element.