Started by
Pickle's Modding
on
Topic category: Help with Minecraft modding (Java Edition)
I'm making a mod in MCreator 2025.3 Neoforge that adds one new item, Ink, and a few new mobs.
I want Ink to be used to swap the texture of the new mobs when pressing a button in the mob's inventory.
Ink would be placed into an input slot, then when the player clicks from a selection of buttons, the mob's texture will swap.
Example: I put ink into the input slot, press the third button, and the Texture3 Model Layer will display.
How would I code this? Thank you for reading and replying.
add synced data to the entity, for example a string called "type" which you set to for example "ModelLayer1" on standard, then for the buttons you make procedures that change the entity data string to "ModelLayer2" etc, whatever you want to call them, then in entity model layers you create a single logic procedure for every layer that is:
[return [get entity data string of entity (entity) name: (string name)] = [text:"ModelLayer1"]]
you have to change the things inside of " ". and the things inside of ( ), and of course ModelLayerX to your name
Thank you so much for the help!