vanilla

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jun 30, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DownloadURL

func DownloadURL(gameVersion string) (string, error)

DownloadURL returns the download URL for the Minecraft vanilla server JAR for a given game version.

Parameters:

  • gameVersion: the Minecraft version string (e.g., "1.16.5", "15w14a", "1.18-pre2").

Returns:

  • string: the direct download URL for the server JAR file.
  • error: an error if the version is not found or if any HTTP or JSON decoding issues occur.

func Versions

func Versions(latestFirst bool) ([]string, error)

Versions fetches the list of all Minecraft vanilla versions from the official Mojang API version manifest.

Parameters:

  • latestFirst: if true, returns the versions with higher versions first. If false, returns the versions with lower versions first.

Returns:

  • []string: a slice of Minecraft versions (e.g., "1.16.5", "15w14a", "1.18-pre2").
  • error: an error if any HTTP or JSON decoding issues occur.

Types

This section is empty.

Jump to

Keyboard shortcuts

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