Fork of ChestCommandsX, modernized for 1.21+ minimessage and Components.
API Javadoc for developers: https://ci.codemc.io/job/filoghost/job/ChestCommands/javadoc/index.html?me/filoghost/chestcommands/api/ChestCommandsAPI.html
- Paper, Folia, or a compatible Bukkit implementation based on Minecraft 1.21.x or newer.
- Java 21 or newer.
- Vault is optional and only required for economy features.
- PlaceholderAPI is optional and only required for external placeholders.
gradle buildThe plugin jar is created at plugin/build/libs/chestcommands-plugin-6.0.1.jar.
repositories {
maven { url = uri('https://nmb-court-team.github.io/Maven/repository') }
}dependencies {
compileOnly 'net.astrorbits.plugin:chestcommands-api:6.0.0'
}Kotlin plugins can use the optional chestcommands-kotlin artifact:
dependencies {
compileOnly("net.astrorbits.plugin:chestcommands-kotlin:6.0.1")
}val shop = plugin.menu(Component.text("Shop"), rows = 3) {
icon(row = 1, column = 4, material = Material.DIAMOND) {
name = "<aqua>Diamond"
lore("<gray>Click to buy")
amount = 3
placeholders = true
onClick { view, player ->
player.sendMessage(Component.text("Purchased!"))
view.refresh()
}
}
}Rows, columns, and linear slots are zero-based, like the Java API. The DSL artifact is separate from the plugin jar, so server owners do not need the Kotlin runtime.
- Use modern material names such as
DIAMOND_SWORD,WHITE_WOOL, andREDSTONE_LAMP. - Commands under
menu-settings.commandsare dynamically registered. Usemenu, not/menu, and avoid names already used by other plugins. Sub-commands such asshop 1are supported. - Use
/cc sound <sound> [pitch] [volume]to test available Minecraft sounds in-game. The sound argument supports tab completion. - Folia is declared as supported. Player inventory/menu work is scheduled on the player entity scheduler, while global tasks use Folia's global scheduler. The legacy update checker and bStats scheduler hooks are disabled on Folia.
- Use
DAMAGEfor item damage. Legacy material data values likeWOOL:14are not supported. NBT-DATAis no longer supported. Use supported metadata keys such asCOLOR,SKULL-OWNER,ENCHANTMENTS,CUSTOM-MODEL-DATA,UNBREAKABLE, andITEM-FLAGS.boss-bar:uses the native Bukkit boss bar API. The olddragon-bar:prefix still works as an alias.POSITION-XandPOSITION-Ysupport ranges such as3-4and dynamic integer placeholders.MATERIAL: AIRcan be used for invisible clickable slots, andDRAG: trueallows a slot to accept normal item movement.
Chest Commands is free software/open source, and is distributed under the GPL 3.0 License. It contains third-party code, see the included THIRD-PARTY.txt file for the license information on third-party code.