CIT Base

Note that features marked in italics are unique to CIT Resewn.

All CIT types, while having different effects, originate from CIT Base. Think of it as a parent for all other types and every type inherits its properties, sometimes overriding their behavior.

When a property is not specified, its default value is used instead, meaning all properties are optional by default.

Some property keys have aliases, these were added for legacy support. Hover over keys to see if they have aliases, try not to use them when possible.

Hover over the properties' types to see example values.

CITs are split into 2 parts: Conditions which determine how items are selected and Effects that change something about the item. All conditions must match for the CIT to apply.


Key Value Type                    Description Default
weight Integer When multiple CITs match the same item, the CIT with the higher weight is chosen.
When multiple matching CITs have the same weight, the CIT file name/path is the tie breaker.
items List of items Requires that the item is either of the ones listed.
Separated by spaces.
Namespaces (minecraft:) are optional.
If not declared and the cit file name is a valid item id, it is used instead.
stackSize Positive integer or a range Requires that the item matches a specific amount.
Supports open ended ranges.
damage Positive integer or a range Requires that the item matches a specific damage.
Supports open ended ranges.
Supports percentages using %.
damageMask Integer Applies a binary mask on the item's damage prior to checking damage (does damage match item damage & damageMask).
Useless with modern items, added just for legacy support.
hand Literal Requires that the item is in a specific hand.
Either: main / off for mainhand or offhand
enchantments List of enchantments Requires that the item has at least one of the enchantments listed.
Separated by spaces.
Namespaces (minecraft:) are optional.
enchantmentLevels List of levels/ranges Requires that one of the item's enchantments matches one of the levels listed.
When enchantments is declared, requires that either one of enchantments matches the levels.
Separated by spaces.
nbt.  path   NBT Match Requires that the item matches the specified NBT predicate.
Multiple nbt conditions are allowed.
Accepts literal, pattern and regex checks, along with ignore-case alternatives.
When path is display.Name or display.Lore.__, the nbt is json evaluated when the match value is not a json.
See NBT Path and NBT Match for more info.


Key Value Type Description Default
type Literal Which type to apply on this CIT.
Either: item / armor / elytra / enchantment
Other mods may add different options.

NBT Path

The nbt property cannot be declared by itself, there must be a unique nbt tag path to target for every nbt condition.

The path starts from the item's tag root and is separated by dots. For example:


will match the nbt for {tag:{CustomModelData:53}}.

nbt.display.Name={"text":"Some Item's Name"}

will match the nbt for {tag:{display:{Name:"{\"text\":\"Some Item's Name\"}"}}}.

When a path crosses an nbt list, the next part of the path is the index. Paths also support wildcards using * for both nbt lists and compounds.

So to match the first lore line you'd use:

nbt.display.Lore.0=The first line of the lore

And to match any lore line you'd use:

nbt.display.Lore.*=Any line in the lore

NBT Match

There are multiple options for how you could do this. Either by literal values, matching patterns or by matching regex. Pattern and regex matching also provide case-insensitive options.

To match literally, the value is used normally. So to match the item name "Some Name", you'd write:

nbt.display.Name=Some Name

To match a pattern, add the pattern: prefix or the ipattern: prefix for case-insensitivity.
Patterns allow for both wild cards and wild characters, declared using * and ? respectively.
To match a name before "'s Sword", you'd write:

nbt.display.Name=pattern:*'s Sword

To match any one character after "Part", you'd write:

nbt.display.Name=pattern:Part ?

Multiple wild cards and characters are allowed.

To match regex, add the regex: prefix or the iregex: prefix for case-insensitivity.
For example, to match any of the following: "First Item" / "Second Item" / "Third Item", you'd write:

nbt.display.Name=regex:^(First|Second|Third) Item$

Matching json

When matching either nbt.display.Name or nbt.display.Lore.___, the match part can be either a json or not. When not matching a json, the json in the item is evaluated into its plain text representation. For example {"text":"Some Item's Name"} is evaluated and matches correctly against Some Item's Name.

This means that to match an item that's been named: "Some Item's Name", you can either do:

nbt.display.Name={"text":"Some Item's Name"}


nbt.display.Name=Some Item's Name

Note that this is supported for both patterns and regex as well by prefixing before the json if present.

Asset Resolution

Most effects use the Asset type to find files. CITs will find assets in their own resourcepack through either an absolute or a relative declared path.

Assets are type specific, meaning that the file extension is optional in the properties declaration but required for the file name. For example the texture property will only look for textures, so both example and example.png would work when texture is looking for example.png.

While not required, you can force a path to be relative by prefixing it with ./ like so:

# minecraft/citresewn/cit/sticks/
# ↓
# minecraft/citresewn/cit/sticks/my_textures/stick_texture.png

# forced relative texture

# assumed relative texture

Relative paths also support going up directories with .. like so:

# minecraft/citresewn/cit/sticks/properties/
# ↓
# minecraft/citresewn/cit/sticks/my_textures/stick_texture.png

# go back one level and into textures

Absolute paths can start from multiple roots, examples:

# Full resourcepack path:
# ↓
# assets/minecraft/citresewn/cit/item_textures/texture.png

# Namespaced full path:
# ↓
# assets/minecraft/citresewn/cit/item_textures/texture.png

# Relative namespace full path:
# ↓ (when the CIT is in the minecraft namespace)
# assets/minecraft/citresewn/cit/item_textures/texture.png

# Namespaced typed directories:
# ↓
# assets/minecraft/textures/item/texture.png

# Relative namespace typed directories:
# ↓ (when the CIT is in the minecraft namespace)
# assets/minecraft/textures/item/texture.png

# The typed directories are:
#    .png → textures/
#    .json → models/

When an asset is not declared, some properties will also try to find assets with similar names as their CITs' in the same directory. For Example:

# assets/minecraft/citresewn/cit/stuff/

# because no texture/model were declared, the item CIT will search for either:
# model=assets/minecraft/citresewn/cit/stuff/my_cool_stick.json
# or
# texture=assets/minecraft/citresewn/cit/stuff/my_cool_stick.png
# with models having more priority than textures.