lighty-loaders

Mod loader support for Minecraft: Vanilla, Fabric, Quilt, Forge, NeoForge, OptiFine, and custom loaders.

Overview

Version: 0.8.6 Part of: LightyLauncherarrow-up-right

Provides a unified trait-based API for managing different Minecraft mod loaders with smart caching and metadata resolution.

Quick Start

use lighty_launcher::prelude::*;

const QUALIFIER: &str = "com";
const ORGANIZATION: &str = "MyLauncher";
const APPLICATION: &str = "";

#[tokio::main]
async fn main() -> anyhow::Result<()> {
    // Initialize AppState
    let _app = AppState::new(
        QUALIFIER.to_string(),
        ORGANIZATION.to_string(),
        APPLICATION.to_string(),
    )?;

    let launcher_dir = AppState::get_project_dirs();

    // Create instance with Fabric loader
    let mut instance = VersionBuilder::new(
        "my-instance",
        Loader::Fabric,
        "0.16.9",      // Fabric loader version
        "1.21.1",      // Minecraft version
        launcher_dir
    );

    // Get metadata (automatically fetched and cached)
    let metadata = instance.get_metadata().await?;

    trace_info!("Loaded {} with {} libraries", metadata.id, metadata.libraries.len());

    Ok(())
}

Supported Loaders

Loader
Feature Flag
Status
MC Versions

Vanilla

vanilla

Stable

All

Fabric

fabric

Stable

1.14+

Quilt

quilt

Stable

1.14+

NeoForge

neoforge

Stable

1.20.2+

Forge

forge

In Progress

1.13+

Forge Legacy

forge_legacy

In Progress

1.7-1.12

LightyUpdater

lighty_updater

Stable

Custom

OptiFine

(vanilla feature)

Experimental

Most

Features

  • Trait-based system: VersionInfo and LoaderExtensions for extensibility

  • Smart caching: Dual-layer cache (raw + query) with configurable TTL

  • Query system: Flexible metadata queries (full, libraries only, etc.)

  • Event integration: Progress tracking via lighty-event

  • Feature flags: Compile only what you need

Installation

Core Traits

VersionInfo

Defines version information for any instance:

LoaderExtensions

Extension methods for fetching loader metadata:

Exports

In lighty_loaders

In lighty_launcher (re-exports)

Documentation

📚 Complete Documentationarrow-up-right

Guide
Description

Simple guide with practical examples

Architecture and design

VersionInfo and LoaderExtensions explained

How queries work

Caching architecture

LoaderEvent types

All exports and re-exports

Loaders

Pure Minecraft

Lightweight mod loader

Fabric fork

Modern Forge fork

Traditional mod loader

Custom loader system

Graphics optimization

License

MIT

Last updated