Custom items can't be used in commands if their menu category is "none"
When hiding a custom item from the creative inventory and recipe book with the following code, the item is unusable in commands. This does not happen to custom blocks with the same configuration.
{
"format_version": "1.21.10",
"minecraft:item": {
"description": {
"identifier": "example:item",
"menu_category": {
"category": "none"
}
}
}
}
NOTE: This bug also overrides setting "is_hidden_in_commands" to false, making it impossible to have a custom item that isn't in the creative inventory but still valid in commands.
Steps to reproduce:
- Apply the provided behaviour pack to a world (no experiments required)
- Try to use the "example:item" and "example:block" in commands e.g. /give
Observed results:
- As expected, the custom "example:block" block works with commands and appears in autocompletions

- The custom "example:item" item does not appear in command autocompletions and results in an error when the command is executed

Expected results:
- Both the custom item and the custom block are absent from the creative inventory and recipe book (already working correctly for both).
- Both the custom item and the custom block can be used within commands, unless their "is_hidden_in_commands" property in "menu_category" is set to true (only working for custom blocks).
2023-12-27, 10:58 PM
2025-02-11, 09:20 PM
16
9
1161304
1.21.60.21 Preview - 1.21.60
1.21.60.21 Preview, 1.21.40.22 Preview, 1.21.40.21 Preview, 1.21.40.20 Preview, 1.21.20.23 Preview, 1.21.20.22 Preview, 1.21.20.21 Preview, 1.21.0.21 Preview, 1.21.0.20 Preview, 1.20.80.24 Preview, 1.20.60.23 Preview, 1.20.51 Hotfix, 1.20.70, 1.20.71 Hotfix, 1.20.80.22 Preview, 1.20.72 Hotfix, 1.20.73 Hotfix, 1.21.10.22 Preview, 1.20.81 Hotfix, 1.21.30.22 Preview, 1.21.30.21 Preview, 1.21.3 Hotfix (PS4), 1.21.2 Hotfix, 1.21.22 Hotfix, 1.21.23 Hotfix, 1.21.30, 1.21.40.23 Preview, 1.21.50.28 Preview, 1.21.44 Hotfix, 1.21.60.25 Preview, 1.21.60.24 Preview, 1.21.60.28 Preview, 1.21.70.22 Preview, 1.21.70.20 Preview, 1.21.51 Hotfix, 1.21.60
-