This library mod provides modifier keys for Minecraft keybindings as well as some related keybinding utilities
If you're not a modder you're probably looking for Amecs.
If you are a modder then you can use Amecs with the following in your build.gradle:
repositories {
maven {
url "https://maven.siphalor.de/"
name "Siphalor's Maven"
}
}
// VERSION: Check the badge above for the latest version
// MINECRAFT_VERSION: The major Minecraft version you're developing for (e.g. 1.15 for 1.15.2)
dependencies {
include(modImplementation("de.siphalor:amecsapi-MINECRAFT_VERSION:VERSION"))
}
If you want to see some example of how to use this library, you can take a look at the testmod.
Modifier keys can be set by the user for all keybindings, including Vanilla ones.
If you want to define a keybinding that uses modifier keys for its default value, you can extend the AmecsKeyBinding
class.
If you want to further integrate this library, check the KeyBindingUtils
class.
Priority keybindings are keybindings that are executed before all other keybindings and are allowed to cancel further evaluation.
This has various use cases, for example:
- Keybindings that work when not in-game
- Keybindings that work regardless if the chat or a GUI is open
You can make use of priority keybindings by implementing the PriorityKeyBinding
interface.
Please always carefully check if your priority keybinding takes action in the right context.
For example, you oftentimes don't want to execute your priority keybinding when the chat is open.
Keybinding descriptions are a way to provide a description for a keybinding that are shown as a tooltip when hovering over the keybinding in the controls menu.
You can add descriptions by defining translations for the keybinding's translation key with the suffix .amecsapi.description
.
This mod is licensed under the Apache 2.0 license.