Skip to content

UI Timer Lib

A simple UI timer for mod creators, made to be as easy to use a possible.

Fabric
Loaders
Fabric
Downloads on Modrinth
322
Followers on Modrinth
1
version
1
Updated
June 12, 2026Jun 12
Published
in 2026
This is a library — other mods need it, and it adds nothing to the game by itselfRequired by 2 mods. Download it if another mod needs it.
Timer library in use — Timer library in use in my "Random Effects Every Minute " mod · swipe

At a glance

A library: other mods need it — required by 2 mods
Runs on Fabric
For Minecraft 1.21.6–1.21.11
Client only — no need to install it on the server
Latest version — 1.0.0 from June 12, 2026
License MIT — free
Where it's needed
In gamerequiredOn servernot needed

Install in the game only; not needed on the server

Game versions1.21.6–1.21.11

UI Utils

UI Utils is a small Fabric library that makes it easy to display simple HUD elements without having to write your own renderer.

It is designed for mod developers who want a quick and lightweight way to show text and timers on the player's screen.

Here is an example of this library in use.

2026-06-15-11-15-40

Features

  • Display custom text on the HUD
  • Show live countdown timers
  • Change text and background colors easily
  • Show and hide the overlay
  • Lightweight and easy to integrate into other mods

Setting it up

  • Download the latest `ui-utils-.jar` from the Versions tab.

  • Add the JAR to your project dependencies.

  • Add UI Utils as a dependency in your mod.

    fabric.mod.json

    {
    "depends": {
      "fabricloader": "*",
      "minecraft": "1.21.6",
      "ui-utils": "*"
    }
    }
  • Import within your Java file.

    Main.java

    import com.uitutils.UIUtils;

Usage

  • Show a labeled timer
UIUtils.show(String label, int seconds);
  • Hide timer
UIUtils.hide();
  • Set timer value
UIUtils.setTime(int seconds);
  • Set timer color (24-bit RGB hexadecimal integer)
UIUtils.setColor(int rgb);
  • Set background color (24-bit RGB hexadecimal integer)
UIUtils.setBackground(int rgb);

Internal fields

These fields exist for direct access but are not required for normal usage.

  • Query current HUD text string
UIUtils.text;
  • Query countdown value in seconds
UIUtils.secondsRemaining;
  • Query HUD visibility
UIUtils.visible;
  • Query HUD text color
UIUtils.color;
  • Query background color
UIUtils.background;

FAQ

How to install UI Timer Lib?

Install Fabric for your Minecraft version, download UI Timer Lib for the same version and loader, put the file into the mods folder and launch the game with the loader profile.

Which Minecraft versions does UI Timer Lib support?

UI Timer Lib has builds for Minecraft 1.21.6–1.21.11.

Is UI Timer Lib needed on the server?

Client only — no need to install it on the server

License and source
MIT Licensefree to use and share with credit to the author
Original — Modrinth↗Files unchanged, verified with SHA-512Is this your mod? For rights holders

The site uses cookies: the necessary ones for sign-in and the theme, plus the Yandex Metrica and LiveInternet visit counters — they show us how the site is used. We have no advertising cookies. More