- Installing any Minecraft version
- Launching Minecraft with custom configurations
- Support for all major mod loaders
- Authenticating with Microsoft
- Handling mods, resource packs, datapacks, servers, and worlds
- Handling NBT
- Integration with Modrinth
- Easy-to-use API
Add this to your pom.xml:
<dependencies>
<dependency>
<groupId>net.consler</groupId>
<artifactId>librelauncherlib</artifactId>
<version>1.6</version>
</dependency>
</dependencies>Add this to your build.gradle:
dependencies {
implementation 'net.consler:librelauncherlib:1.6'
}-
Install:
new MinecraftInstaller().install(version, gameDir, ModloaderProfile.VANILLA());
-
Launch:
LaunchProfile launchProfile = new LaunchProfile.Builder(version, gameDir).build(); AuthProfile authProfile = new MicrosoftAuthenticator().login(new NativeWebViewFrame()).join(); ModloaderProfile modloaderProfile = new ModloaderProfile(ModloaderProfile.FABRIC_ID, "0.19.5") new MinecraftLauncher(launchProfile, authProfile, modloaderProfile).launch();
-
Add a local Minecraft JAR patch:
Instance instance = new Instance(gameDir); instance.addJarMod(Path.of("/path/to/OptiFine_MOD.jar"));
At launch, LibreLauncherLib overlays the added JAR's entries onto the vanilla
client.jar, leaving the downloaded client JAR unchanged. Pass the extracted JAR patch produced by OptiFine's installer, not the standalone installer JAR. This Minecraft-JAR patch flow does not require Forge.
Read our wiki!