Minecraft

Minecraft itself can be used as a relation in AddonScript manifests. This way addons MAY define, with which versions of Minecraft they are compatible. Instances MUST be based on a Minecraft version. Instance addons MAY apply patches to the Minecraft version of the instance. The version of Minecraft, which will be used, MUST be defined by the instance addon by using the required relational flag with either an exact version or a version range, in which case the user SHOULD be asked to select a version, which fulfills all version restrictions in the instance. There is no AddonScript manifest for Minecraft, AddonScript implementations MUST know the ID and namespace of Minecraft and how to handle it as specified below.

ID and Namespace

The addon ID of Minecraft, which will be used for relations is minecraft and the namespace is net.minecraft.

Versions

The AddonScript version number of a Minecraft version is equal to the version ID from the piston-meta API of Mojang and the official version manifests used by the Minecraft launcher, except for the difference that characters, which are invalid in AddonScript versioning (whitespace and non-ASCII characters), will be replaced with an underscore (_).

Release

Release versions of Minecraft are SemVer compatible. Addons, which only use release versions as relations SHOULD use SemVer version ranges instead of Maven version ranges. Release versions are correctly ordered according to both, SemVer and Maven.

Alpha and Beta

Alpha and beta versions are all Minecraft versions before the initial release 1.0. They are not SemVer compatible. Most alpha and beta versions are correctly ordered according to Maven, except for some early alpha versions. AddonScript implementations SHOULD be careful when ordering alpha versions and SHOULD rather trust the information from piston-meta than the Maven order.

Snapshot

Snapshot versions are mostly neither SemVer compatible nor do they fit into Maven version ordering. AddonScript implementations SHOULD use piston-meta to order snapshot versions. When installing an addon into an instace, which is based on a snapshot version, AddonScript implementations SHOULD NOT trust the version range for Minecraft of that addon, as it might be incorrect due to version ordering. Instead the user SHOULD be asked, if the installation should be proceeded, and warned about possible incompatibilities.

Launch configuration

AddonScript implementations, which are meant to install or launch AddonScript instances MUST know the launch configuration for Minecraft itself. For the server side, the launch configuration only consists of the server jar as the main jar, which already includes the required libraries and a manifest with the main class. For the client side the launch configuration SHOULD be retrieved from the piston-meta API in form of the version manifest. This manifest includes information about the main jar, the main class, all required libraries and launch arguments. In contrast to patches done by instance addons, arguments in the version manifest can include variables, which MUST be replaced with the correct values when launching the game and both, libraries and arguments, can be operating system or architecture specific, which MUST also be considered by implementations. Moreover it also provides an asset index, which SHOULD be used by implementations to retrieve game assets (if they are not already cached).