loader

package
v1.7.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 8, 2026 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Register

func Register(l Loader)

Types

type Downloader

type Downloader func(ctx context.Context, url, dest, sha1 string) error

type InstallRequest

type InstallRequest struct {
	MCVersion     string
	LoaderVersion string
	ProfileDir    string
	LibrariesDir  string
	MinecraftJar  string
	JavaBin       string
	Download      Downloader
}

type InstallResult

type InstallResult struct {
	MainClass string
	JVMArgs   []string
	GameArgs  []string
	Libraries []string
	ClientJar string
}

type Installer

type Installer interface {
	Install(ctx context.Context, req InstallRequest) (*InstallResult, error)
}

type Library

type Library struct {
	Name string
	URL  string
}

type Loader

type Loader interface {
	Name() string
	Versions(ctx context.Context, mcVersion string) ([]string, error)
	Resolve(ctx context.Context, mcVersion, loaderVersion string) (*LoaderProfile, error)
}

func All

func All() []Loader

func Get

func Get(name string) (Loader, bool)

type LoaderProfile

type LoaderProfile struct {
	MainClass string
	Libraries []Library
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL