Download Exclusions Lib — Minecraft Mods — MetaMods

Exclusions Lib

Active

Downloads

5

Last update

1 month ago

Versions

1.20.1 — 1.21.6
Server
Fabric
Forge
Neoforge
Quilt
Libraries
Utils
World generators

Exclusions Lib

This library provides additional capabilities for working with vanilla JSON files in Minecraft.

All features are required only on the server side, so you can safely use them when creating your datapacks!

Main Features

New Block Predicate

Added the exclusions_lib:overlaps_structure predicate, which checks for intersection with structures. It takes a block position (with the possibility of offset via an optional offset field, like other predicates), and can also use structures and/or range parameters to refine the check.

Using the structures field, you can specify specific structures to check, and the range parameter (maximum 32) allows checking the area around the specified position.

This tool is perfect for preventing object generation in places that intersect with structures. For example, you can create ore that appears only near certain buildings!

Tag Exclusions

The system allows creating blacklists for tags. Want to create a tag that includes all flowers from #minecraft:small_flowers, except wither roses? While maintaining compatibility with mods that add new flowers? Simply add wither roses with the "excluded": true parameter - and you'll get a "normal flowers" tag!

This feature is very powerful: you can remove problematic items from other mods from your tags while keeping them in common tags, or even remove elements from other mods' tags and vanilla game!

Usage Example

Creating a tag that includes all flowers from #minecraft:small_flowers, except wither roses, plus additional items:


  "values": [
    "#minecraft:small_flowers",
    {
      "id": "minecraft:wither_rose",
      "excluded": true
    },
    "minecraft:apple",
    "minecraft:waxed_exposed_cut_copper_stairs"
  ]
}
Project members
Athebyne

Athebyne

Developer

Created: 25 Sep 2024

ID: 59990