resourcepack.ai
DOCS

Content

Items

An item is a vanilla item wearing a different model. It stacks, it burns in lava, it goes in a hopper, and every other plugin sees a real ItemStack. Nothing about it is a pretend item.

# items/gems.yml
ruby:
  material: DIAMOND        # required: the vanilla item underneath
  name: "&cRuby"
  lore: ["&7Warm to the touch."]
  texture: item/ruby       # defaults to item/<id>
  stack: 16
  glow: true
  unbreakable: true

material is what it is when nothing else is looking — pick it for behaviour. A PAPER ruby is inert; a DIAMOND_SWORD one swings like a sword.

/rp give mypack:ruby puts one in your hand. /rp items lists them.

The texture#

Falls out of the ID. mypack:ruby looks for assets/textures/item/ruby.png with nothing pointing at it, and texture: overrides that if you want two items sharing one picture.

A texture nobody shipped is a build warning naming the path, rather than a purple-and-black square in game with nothing to trace it back to.

3D items#

Point model: at a Blockbench file in assets/models/:

sword:
  material: IRON_SWORD
  model: sword             # assets/models/sword.bbmodel

Both forms work, and the project file is the one to use:

  • sword.bbmodel — what Blockbench saves. Its textures are inside it, so the model is one file you can hand to somebody, and there is no export step to forget.
  • sword.json — what Blockbench exports. Cubes only: no bones and no keyframes, so an animated model must be saved rather than exported.

Source that an item consumed is dropped from the built pack. Source nothing referenced is kept, because it is probably a shared parent something else inherits from.

Borrowing another item's model#

ruby_sword:
  material: IRON_SWORD
  copy-model: mypack:sword

An item that copies generates nothing of its own — the files already exist under the ID it borrowed, and writing them twice would be two definitions fighting over one path. Useful for a set of items that look alike and behave differently.

Permissions#

wand:
  material: STICK
  permission: mypack.wand

Checked when the item is used, not when it is given or held. A permission that stopped somebody holding an item would mean taking it out of their inventory, which is a thing to do to somebody's stuff rather than a decision an engine makes.

Where to go next#