📦LiteItem
LiteItem is a simple JSON-based data model used to describe Minecraft items inside plugins powered by LiteCore.
It allows you to define item properties such as material, display name, lore, custom model data, NBT tags, and more — in a clean and readable format. You can use it to both create items and recognize them during plugin logic.
🛠️ How to get LiteItem data
- Hold the item in your hand.
- Run the command:
/[your_plugin] core data
- The plugin will print a LiteItem model based on the held item — you can copy it and use it in your configs.
📘 LiteItem Structure
There are two formats for LiteItem:
1. Full NBT Encoded
Stores the complete internal NBT data of the item:
{
"lite_item": {
"amount": 1,
"data": "rO0ABXNyABp..."
}
}
This method is exact but not editable by hand.
2. Readable JSON Format
Easier to modify manually and recommended when you only care about certain properties:
{
"lite_item": {
"amount": 64,
"material": "OAK_LOG",
"display_name": "§aMy log",
"lore": [
"Hello!",
"This is my log =)"
],
"head_url": "f2f52f927efffd...",
"custom_model_data": "1001",
"compare": "material,display_name,custom_model_data",
"use_sounds": [
"ENTITY_SHEEP_SHEAR",
"ENTITY_SHEEP_SHEAR:0.5:2"
],
"damage": 10,
"nbt": {
"plugin_name:log_key": "oak_log"
}
}
}
🔍 Field Explanation
Field | Description |
---|---|
| Amount of the item |
| Item material (e.g. |
| Colored name of the item ( |
| List of lore lines |
| Model ID used for resource pack texture binding |
| Base64 texture hash (for heads) |
| Custom NBT tags stored in the item |
| Sounds to play when using this item. Format: |
| Can represent either item damage or amount consumed; supports random range |
| Comma-separated list of fields used to identify the item (see below) |
🧠 Understanding compare
Sometimes players might rename or slightly modify items. To prevent this from breaking plugin logic, you can specify which fields should be used when comparing items.
Example:
{
"lite_item": {
"material": "OAK_LOG",
"display_name": "§aMy log",
"custom_model_data": "1001",
"compare": "material,display_name,custom_model_data"
}
}
- If a player renames the item, and
display_name
is part ofcompare
, the item will no longer match. - To make it more tolerant, reduce the comparison to non-editable fields:
"compare": "custom_model_data"
Now, the plugin identifies any item with the same custom_model_data
, regardless of name or damage.
🎯 Usage Example
Say you create a seed item via GUI:
{
"seed_item": {
"amount": 1,
"material": "WHEAT_SEEDS",
"display_name": "§fトマトの種",
"custom_model_data": "10009"
}
}
To avoid mismatches if the player renames the item, limit the comparison:
{
"seed_item": {
"amount": 1,
"material": "WHEAT_SEEDS",
"display_name": "§fトマトの種",
"custom_model_data": "10009",
"compare": "custom_model_data"
}
}
This way, only the model ID is used for recognition.