Skip to content

Repository files navigation

Cleanroom

Cleanroom is an ecosystem for Minecraft 1.12.2, built on a continuation of MinecraftForge.

  • Runs on modern Java versions (25+)
  • LWJGL 3 + SDL 3 rendering and input stack
  • Compatible with almost all Forge mods, with edge cases handled by Fugue

If you want to...

Runtime

  • Java 25
  • LWJGL 3, with LWJGLY shim for LWJGL 2 APIs
  • Foundation, powerful LaunchWrapper replacement
  • CleanMix, Mixin fork with proper bootstrapping and more features
  • ImagineBreaker
  • Netty 4.2, Guava 33, Apache HttpClient 5, Jakarta APIs and more

Kirino Engine

Kirino Engine ships as a module of this repository and is wired into the loader lifecycle.

It is a work-in-progress rendering engine that replaces Minecraft's implicit render state with an explicit structure, and gives mod authors a real rendering API instead of another layer of mixins.

Installation

Important

Follow our guide over at our website! It explains steps needed to take to port existing modpacks, and also informs you of the latest and greatest mods to use and to update to.

Client

  • MultiMC-based Launchers (PrismLauncher, PolyMC etc): download the .zip (MMC instance) and import it.
    • Alternatively, unzip and move the patches directory into your existing 1.12 instance (same level as the .minecraft directory).
  • Minecraft Official Launcher: follow instructions when launching the installer jar. Or launch it with cli.
  • Other Launchers (ATLauncher, HMCL etc): install the relauncher, and follow instructions in the pop-up GUI.

Note

Direct downloads can be found in GitHub Actions, Releases & the CleanroomMC Download Page. Action builds require logging into GitHub before downloading.

Server

  • Follow instructions when launching the installer jar. Or launch it with cli.

For Mod Developers

  • The official template is CleanroomModTemplate. A porting guide is in the Cleanroom wiki (WIP).

  • Scala 3 and Kotlin 2 are both usable for mod code, through Scalar and Forgelin-Continuous.

Development & Build System

  1. Clone repository
  2. git submodule update --init
  3. Install a Java 25 JDK
  4. Import build.gradle
  5. ./gradlew setup
  6. ./gradlew build

Run git submodule update every time you fetch upstream.

Directory Contents
module/minecraft Patched Minecraft. Sources are generated by setup and are untracked, only module/minecraft/patches is committed
module/forge Continuation of MinecraftForge
module/cleanroom Cleanroom ecosystem: Boot/Loader/API/Implementations
module/kirino Kirino Engine, WIP rendering backbone of Cleanroom
module/builtin Mods integrated into Cleanroom itself

Patches, ATs and SAS

  • Change vanilla behavior by editing module/minecraft/src/main/java/ only.
  • Run gradlew generateMinecraftDiffs before committing, or the changes will not exist. Patches are written to module/minecraft/patches.
  • Run gradlew applyMinecraftDiffs to rebuild module/minecraft/src from the committed patches.
    • Such as after pulling from upstream, to properly update patched minecraft's sources.
  • Keep patches small:
    • Prefer one or two line calls into a hook class over logic inside Minecraft.
    • Do not import classes, rather fully qualify your references for patches.
  • Access transformers live in module/forge/src/main/resources/forge_at.cfg
  • Side annotation strippers in module/cleanroom/minecraft.sas.
    • Use SAS to strip side annotations rather than patch out a @SideOnly.

Main Tasks

Task Behavior
setup Workspace setup (chain of tasks)
runCleanroomClient Launches the development client with Kirino disabled
runCleanroomServer Launches the server from the development environment
runKirinoClient Launches the development client in run/kirino with Kirino enabled
runVanillaClient/runVanillaServer Launches unmodified Minecraft, to compare behavior
generateMinecraftDiffs Regenerates the patch set from edited Minecraft sources
applyMinecraftDiffs Recreates the Minecraft sources from the committed patch set
build Builds the universal, installer, userdev and MMC pack artifacts
cleanroomInfo Prints the effective CleanroomGradle mode, versions, caches and tools

About

Cleanroom Minecraft.

Topics

Resources

Contributing

Security policy

Stars

619 stars

Watchers

11 watching

Forks

Releases

Packages

Used by

Contributors

Languages