Package com.blamejared.crafttweaker.api
Class CraftTweakerAPI
java.lang.Object
com.blamejared.crafttweaker.api.CraftTweakerAPI
Provides access to the main CraftTweaker API.
- Since:
- 9.1.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidApplies the givenIAction.static IAccessibleElementsProviderProvides access to theIAccessibleElementsProvider, allowing for more internal access.static org.apache.logging.log4j.LoggerObtains a newLoggerfor logging CraftTweaker-specific messages related to the given system.static ILoggerRegistryObtains theILoggerRegistryused to create system-specificLoggerinstances.static ICraftTweakerRegistryProvides access to the main CraftTweaker set of registries.static IScriptRunManagerObtains theIScriptRunManagerused to create and execute script runs.static PathObtains aPathto the defaultscriptsdirectory used by CraftTweaker.
-
Constructor Details
-
CraftTweakerAPI
public CraftTweakerAPI()
-
-
Method Details
-
getAccessibleElementsProvider
Provides access to theIAccessibleElementsProvider, allowing for more internal access.- Returns:
- The
IAccessibleElementsProvider. - Since:
- 9.1.0
-
getRegistry
Provides access to the main CraftTweaker set of registries.- Returns:
- An instance of
ICraftTweakerRegistry. - Since:
- 9.1.0
-
getScriptRunManager
Obtains theIScriptRunManagerused to create and execute script runs.- Returns:
- The script run manager.
- Since:
- 9.1.0
-
getLoggerRegistry
Obtains theILoggerRegistryused to create system-specificLoggerinstances.- Returns:
- The logger registry.
- Since:
- 11.0.0
-
getScriptsDirectory
Obtains aPathto the defaultscriptsdirectory used by CraftTweaker.- Returns:
- The default scripts directory.
- Since:
- 9.1.0
-
apply
Applies the givenIAction.- Parameters:
action- The action to apply.- Since:
- 9.1.0
- See Also:
-
getLogger
Obtains a newLoggerfor logging CraftTweaker-specific messages related to the given system.The given logger is automatically configured to output messages to
crafttweaker.logwith the correct format. It can be therefore used directly.- Parameters:
systemName- The name of the system.- Returns:
- A
Loggerinstance tailored to the given system. - Since:
- 11.0.0
- See Also:
-