Wiki 9Minecraft OwO Lib Mod Wiki

OwO Lib Mod — Guide

UI System (owo-ui)

The owo-ui framework is a declarative UI library that allows for the creation of dynamic, high-performance screens using either XML-like layouts or a code-driven builder API. It replaces the traditional, verbose Minecraft screen rendering with a component-based architecture.

Core Components

Component Description
Label Displays text with support for rich formatting and shadows.
Button Interactive clickable element with customizable textures and sizing.
Box A simple colored rectangle used for backgrounds or borders.
Text Box An input field for user text, featuring improved cursor behavior and event streams.
Checkbox A toggleable component for boolean settings.
Slider Allows users to select a value from a range, supporting discrete steps.
Dropdown A collapsible menu for selecting one option from many.
Color Picker A full HSV picker for selecting colors with optional alpha support.
Item Component Renders an ItemStack with full tooltip support.
Entity Component Renders a live entity model within the UI.

Layout Containers

  • Flow Layout: Arranges children horizontally or vertically with support for alignment and spacing.
  • Grid Layout: Positions components in a structured grid of rows and columns.
  • Scroll Container: Provides a scrollable view for content that exceeds the screen size.
  • Collapsible Container: A layout that can be expanded or hidden by the user.
  • Overlay Container: Displays content as a modal popup over the rest of the UI.

Mechanics & Features

Item Group Extensions

OwO Lib enhances the creative inventory by allowing mods to create tabbed item groups. This prevents clutter by grouping related items into sub-tabs within a single main category. These groups support custom buttons, textures, and dynamic item variant handling.

Networking & Endecs

The library includes a networking layer built on Endecs (Encoder/Decoder). This system provides: * Automatic Serialization: Complex data structures are converted to network packets automatically. * Handshaking: Ensures that the client and server have compatible mod versions before connection. * Particle Events: A side-agnostic system for triggering complex particle effects from the server with minimal overhead.

Particle System

OwO Lib provides a wrapper for Minecraft's particle system, making it easier to spawn geometric patterns or random distributions. It includes client-side helpers for composing multi-layered particle effects without manual coordinate math.

Sentinel

owo-sentinel is a specialized sub-mod included within mods that depend on OwO Lib. Its sole purpose is to improve the user experience when the library is missing.

  • Function: If a player launches the game with a mod that requires OwO Lib but the library is not present, Sentinel stops the launch process.
  • User Interface: It opens a custom window explaining the missing dependency.
  • Installation: It provides a one-click button to automatically download and install the correct version of OwO Lib or a button to open the official download page.
  • Safety: It never connects to the internet or modifies files without explicit user consent via a labeled button.

Technical Setup

For developers integrating OwO Lib into their projects, the following configurations are required in the build environment.

Repository Configuration

repositories {
 maven { url '' }
 maven { url '' }
}

Dependency Declaration

Fabric:

dependencies {
 modImplementation "io.wispforest:owo-lib:${project.owo_version}"
 include "io.wispforest:owo-sentinel:${project.owo_version}"
}

NeoForge:

dependencies {
 implementation "io.wispforest:owo-lib-neoforge:${project.owo_version}"
 accessTransformer "io.wispforest:owo-lib-neoforge:${project.owo_version}"
 interfaceInjectionData "io.wispforest:owo-lib-neoforge:${project.owo_version}"
}