Back to mods
Spis UI API project artwork

CurseForge · Minecraft mod

Spis UI API

Library mod that adds easy to use UI elements like Custom Fonts or animated textures

Choose a version Pick your version below, then grab the matching file.

Quick answer

Which Spis UI API release should I use?

Updated 3 months ago
Latest stable file spis_ui_api-1.4-neoforge-1.21.1.jar
Game version 1.21.1
Loader NeoForge

Spis UI API spis_ui_api-1.4-neoforge-1.21.1.jar targets 1.21.1 with NeoForge. The project page does not say whether this file belongs on the client, dedicated server, or both. No extra mods listed for this file.

Where it goes

Is Spis UI API required on the client, server, or both?

The project page does not say whether this file belongs on the client, dedicated server, or both.

Client Source doesn’t say
Dedicated server Source doesn’t say
Loader for this release NeoForge
Required install it here Optional supported, not mandatory Not supported do not install here Source doesn’t say do not assume

The source does not explicitly classify this release as client-only or server-only.

What else does Spis UI API spis_ui_api-1.4-neoforge-1.21.1.jar need?

spis_ui_api-1.4-neoforge-1.21.1.jar. Change the file and its required mods may change too.

No extra mods listed for this file

This file does not list any required mods. Do not add a library just because a different file uses it.

This file does not list any required or optional mods.

Before you install it

Add Spis UI API without breaking your instance.

Built for Spis UI API spis_ui_api-1.4-neoforge-1.21.1.jar. Pick another file and the loader, install side or required mods may change.

  1. 01

    Stick to this file

    Use spis_ui_api-1.4-neoforge-1.21.1.jar. It targets 1.21.1 with NeoForge; another release may have different loader, side or dependency requirements.

  2. 02

    Bring the mods it needs

    This file does not list any required mods. Do not add a library just because a different file uses it.

  3. 03

    Put it on the correct side

    The project page does not say whether this file belongs on the client, dedicated server, or both.

  4. 04

    Pick the file you checked

    Use the “Get this file” button beside spis_ui_api-1.4-neoforge-1.21.1.jar. It opens that exact file at the source.

About this project

What does Spis UI API add?

Who It's For?

This library is mainly for use in my mods, to streamline creating ui/gui interfaces.
However anyone can use this mod as a dependency to use its features.


Why Use It?

Currently the mod does the following;
A new set of drawStrings(), which adds easily accessed custom fonts, aswell as wordwrapping to custom bounding boxes, and setting the alignment to left/center/right.


How Use It?

Imports

import net.spidrone.uiapi.UIAnimationManager;  
import net.spidrone.uiapi.UIGraphicsHelper;  

Animated Graphics

UIAnimationManager.drawGif(GuiGraphics graphics, String imagePath, int x, int y, int frameWidth, int frameHeight, int totalFrames, int fps, float scaleX, float scaleY, float red, float green, float blue)

Custom drawString()

UIGraphicsHelper.drawCustomFont(GuiGraphics graphics, ResourceLocation fontLocation, String message, int x, int y, int color, boolean dropShadow, TextAlign align)

Custom drawString() with bounding boxes/autowrap/line splitting

UIGraphicsHelper.drawCustomFontBound(GuiGraphics graphics, ResourceLocation fontLocation, String message, char splitChar, int x1, int y1, int x2, int y2, int color, boolean dropShadow, TextAlign align)

not including something like the fontLocation will cause it to use the default font
align : LEFT/CENTER/RIGHT

splitChar "$" will cause hi$world to appear on your ui as

hi
world

Registering Fonts

Register your fonts ttf by placing them in your assets folder
assets/modid/font
in the same folder include a .json file

{
  "providers": [
    {
      "type": "ttf",
      "file": "spis_ui_api:boldpixels.ttf",
      "shift": [0.0, 0.0],
      "size": 16.0,
      "oversample": 2.0
    }
  ]
}

Declare the fonts resource location in your ui

public static final ResourceLocation BOLD_PIXELS_FONT = ResourceLocation.fromNamespaceAndPath("spis_ui_api", "boldpixels");

Credits

Bold Pixels : https://yukipixels.itch.io/boldpixels
The font is absolutely perfect for minecraft


Extras

Q: Do you support X version
A: This library is primarily for 1.21.1, but it will be expanded to other versions over time

Project description from CurseForge.

Pick your setup

Spis UI API by Minecraft version and loader

Choose the version and loader you play, then open the matching release.

1 available setups

Check the dependencies, then try the file in a copied instance before changing a world you care about.

Recent files

Spis UI API versions and loaders

4 of 4 releases match

Looking for an older file? The official CurseForge project page is in Resources.