Polymer

Polymer

763k Downloads

Can't get item textures to work

dm432 opened this issue ยท 2 comments

commented

Hi,

I've recently discovered the polymer project and wanted to try it out by adding a simple ruby item. I followed the instructions in the wiki, and the block textures seem to be working fine. However, I can't get the item textures to work.

Am I missing something? If you need more details, feel free to ask.
Thanks in advance!

Item registration:

object LamiaItems {
    val RUBY = register("ruby")

    private fun register(id: String): SimplePolymerItem {
        val itemKey = RegistryKey.of(RegistryKeys.ITEM, Identifier.of(MOD_ID, id))
        return Registry.register(
            Registries.ITEM,
            itemKey.value,
            SimplePolymerItem(Item.Settings().registryKey(itemKey))
        )
    }
}

ruby.json item model:

{
  "parent": "minecraft:item/generated",
  "textures": {
    "layer0": "lamia:item/ruby"
  }
}

Project structure:
Image

Generated (and applied) polymer resource pack structure:
Image

Texture not working:
Image

/polymer client-item output:
Image

commented

Assuming you are on latest MC version, you need to define item model definition file (in assets/lamia/items/ruby.json and so on).
See https://docs.fabricmc.net/develop/items/first-item#creating-the-item-model-description or https://minecraft.wiki/w/Items_model_definition

commented

Totally missed that, thank you!