Skip to content

Hiding and Adding Index Stacks

Emily Rose Ploszaj edited this page Jul 7, 2023 · 2 revisions

Index Stacks

The sidebar showing "every" item in the game in EMI is called the index. While it is possible to add or remove stacks from this index in code trivially, it is also possible to use data packs or resource packs to modify the index. There are 2 ways to achieve this.

Tag based/data pack removal

EMI abides by the #c:hidden_from_recipe_viewers block, item, and fluid tags. Anything in this tag will be removed from the index.

Resource pack removal/addition

For more complex use cases, you can also add and remove stacks to/from the index using resource packs. Any json file in assets/emi/index/stacks/ will be loaded for this purpose.

Key Value
added Stacks to be added, optionally after some other stack.
removed Stacks to be removed.
filters Filters to apply on stack IDs, matches will use regex if the string starts and ends with /.
disable Whether to "disable" removed/filtered stacks, hiding all recipes that use them as well. false by default.

Added stacks are objects in the following format.

Key Value
stack The stack to be added.
after Optionally, the point in the index to add stack after.

Example

The following adds stone after water in the index, removes gold ingots, diamonds, and also removes any stacks who ids contain minecraft:stone like stone, stone bricks, stone slabs, etc.

{
  "added": [
    {
      "stack": "item:minecraft:stone",
      "after": "fluid:minecraft:water"
    }
  ],
  "removed": [
    "item:minecraft:gold_ingot"
  ],
  "filters": [
    "minecraft:diamond",
    "/minecraft:stone/"
  ]
}