Fonts

Fonts in MythicHUD are sprite-sheets configured to pair a text character with a visual icon. This can be used to transform Unicode textures into icons and images.
MythicHUD currently does not utilize pre-existing fonts in a resource pack, and must have font characters configured in its generation to display them.

Font Config

By default, MythicHUD generates the config for its default fonts in /MythicHUD/assets/font/default-fonts.yml, which use several sprite-sheets located in /MythicHUD/textures/font/default/.
A font configuration includes a provider name, a texture file to reference, the character height of the sheet, and a list of characters mapped to the sheet. Here is a small example custom-font configuration:

custom-font:
  providers:
    # standard space characters unchanged
    spaces:
      type: "space"
      advances:
        " ": 4
        "\u200c": 0
    # remapped unicode characters to icons:
    nonlatin-european:
      type: "bitmap"
      texture: font/custom-font/sprites.png
      height: 8
      chars:
        - "\u00a1\u2030\u00ad\u00b7"
        - "\u20b4\u2260\u00bf\u00d7"
        - "\u00d8\u00de\u04bb\u00f0"
        - "\u00f8\u00fe\u0391\u0392"

This configuration creates a font named custom-font for use in text Assets, uses the sprite sheet provided at /MythicHUD/textures/font/custom-font/sprites.png, and loads 16 characters to change the display of various Unicode characters (such as \u00a1's ¡ character as whatever the first, upper-left icon in the sprite sheet is).

TTF Fonts

A font can also be made from a TrueType font file (.ttf) instead of a hand-drawn sprite sheet.
MythicHUD draws the characters from the font into a sprite sheet itself when the resource pack is built.
This is especially useful for scripts like Chinese, Japanese or Korean, which need far too many characters to draw by hand.

Example

custom-font:
  providers:
    spaces:
      type: "space"
      advances:
        " ": 4
        "\u200c": 0
    chinese:
      type: "ttf"
      file: "chinese.ttf"
      size: 12
      ranges:
        - "4E00-9FFF"
      auto: true
Option Description Default
file The font file to use, see Font File. none (required)
size The font size the characters are drawn at. 8
chars Characters to include, as a single string or a list of strings. none
ranges Unicode ranges to include, like 4E00-9FFF or a single 4E00, with optional 0x/U+ prefix. none
auto Includes every non-ASCII character written in your HUD assets, layouts, pop-ups and language files. false
height The height of the characters on screen. the drawn height
ascent Moves the characters up or down, same as for a bitmap provider. 0
antialias Smooths the edges of the characters, set to false for pixel fonts to keep them crisp. true

At least one of chars, ranges or auto must give the font something to draw.
auto is the easiest way to only include the characters you actually use, and it can be combined with the other two.

Font File

The font file is looked for in this order:

  1. Inside the source pack, at /MythicHUD/source-pack/assets/<namespace>/font/<file>
  2. Directly in the plugin folder, at /MythicHUD/<file>, for a font file you do not want shipped in the resource pack

Limits

  • A single TTF provider can hold up to 4096 characters, and the generated sheet can be at most 4096 pixels in either direction. Characters past that limit are skipped with a warning; split them into several providers if you need more.
  • Characters the font has no design for are skipped with a warning.
  • Characters that draw nothing, like spaces, are left out.
    Specify their widths in a space provider instead.
  • TTF providers only work in MythicHUD font configs, not in fonts imported from another resource pack.

Spritesheet

The sprite sheet for a font is considered a grid of character tiles sized height x height. The above example would be a 32px by 32px sheet made of 8px square characters, for example. Sprite sheet textures do not have to be square, but do have to have exact resolution measurements to be read correctly. If textures load but seem misshapen or offset, it is likely a sprite-sheet resolution issue.

Animation Example

This is a complex example walking through how to utilize a custom MythicHUD font to turn various Unicode characters into image frames for stop-motion animation.
These Unicode frames are being delivered via a PlaceholderAPI placeholder, which is being managed and animated by a third-party software solution.
MythicHUD can display those unicodes as frames of animation through displaying the PAPI text as a custom font.

This is an example /MythicHUD/assets/hud/ animated asset:

anim:
  layers:
    display:
      text: "%icon_sparkle%"
      font: "sparkle"
      outlined: false
      align: center
      offset:
        x: 0
        y: 0

It would utilize the /MythicHUD/assets/font/ custom font:

sparkle:
  providers:
    spaces:
      type: "space"
      advances:
        " ": 4
        "\u200c": 0
    ascii:
      type: "bitmap"
      texture: font/sparkles.png
      height: 12
      chars:
        - "\u8080\u8081\u8082\u8083\u8084"
        - "\u8085\u8086\u8087\u8088\u8089"

This font is sourced from a 60x24px image at /MythicHUD/textures/font/sparkles.png, and displays 10 12px-square sprites in two rows of 5.

The PAPI placeholder %icon_sparkle% is then delivering unicodes \u8080 - \u8089 in sequence to play back those frames as animation.

Updated Oct 24, 2026