Class ForgeVersion
public class ForgeVersion extends Object
-
Field Summary
-
Constructor Summary
Constructors Constructor Description ForgeVersion()
-
Method Summary
Modifier and Type Method Description static String
getGroup()
Returns the group of the currently running Minecraft Forge implementation.static String
getSpec()
Returns the current specification version of Forge Mod Loader.static net.minecraftforge.fml.VersionChecker.Status
getStatus()
Returns theVersionChecker.Status
for theForge mod
.static String
getTarget()
Returns the more up-to-date version found by theVersionChecker
, or a blank string if none is found.static String
getVersion()
Returns the current implementation version of Minecraft Forge.
-
Field Details
-
MOD_ID
- See Also:
- Constant Field Values
-
-
Constructor Details
-
ForgeVersion
public ForgeVersion()
-
-
Method Details
-
getVersion
Returns the current implementation version of Minecraft Forge.This is retrieved from the
Implementation-Version
from the manifest of the JAR where this class resides in. If that does not exist, then the version is taken from theFORGE_VERSION
System.getenv(String)
environment variable} (If those do not exist, then aRuntimeException
will be thrown).- Returns:
- The implementation version of Minecraft Forge
-
getStatus
public static net.minecraftforge.fml.VersionChecker.Status getStatus()Returns theVersionChecker.Status
for theForge mod
.- Returns:
- The version checker status for the Forge mod
-
getTarget
Returns the more up-to-date version found by theVersionChecker
, or a blank string if none is found.- Returns:
- The more up-to-date remote version, or a blank string
-
getSpec
Returns the current specification version of Forge Mod Loader.This is retrieved from the
Specification-Version
from the manifest of the JAR where this class resides in. If that does not exist, then the version is taken from theFORGE_SPEC
environment variable
(If those do not exist, then aRuntimeException
will be thrown).- Returns:
- The specification version of Minecraft forge
-
getGroup
Returns the group of the currently running Minecraft Forge implementation.This is retrieved from the
Implementation-Title
from the manifest of the JAR where this class resides in. If that does not exist, then the version is taken from theFORGE_GROUP
environment variable
. If those do not exist, then the group will default tonet.minecraftforge
.- Returns:
- The group for the running Minecraft Forge implementation
-