Unable to use crafted saddles in 1.9.1

Published by smmmadden on Mon, 12/02/2019 - 03:05
Upvotes: 1
Issue description

I've decided to add craftable saddles including the vanilla saddle.  The vanilla saddle works fine and can be mounted on the horse.  Unfortunately, the same is not true for the 10 colored saddles I created.  They craft fine, but will not interact with the horse and get added/mounted.  Nothing happens. 

Appears like something is missing in the logic to allow it to behave like the vanilla saddle.

Minecraft Version: 1.12.2
Forge build: 2768

Created Item called: BlackSaddle and others of varying colors along with its crafting recipe, achievements and procedures
Created and Imported all textures (16pxx16px)

Creative Inventory: TRANSPORTATION
Max stack size: 1
Enchantability: 0
Max item usage duration: tried 0 and 50
Type of tool: 1
Item damage: 0

When item is crafted/smelted - call BlackSaddleProcedure
  Add achievement to entity: BlackSaddleAch
  Call procedure: AddExperiencePoints

It behaves as if there is missing code to connect the saddle to the horse or other mobs that can be ridden with a saddle.  Am I missing something or is there no API to do this yet?

Thanks -Steve

Issue comments

If you just make item that looks like a saddle, there is no way for it to work like saddy by default. There is no black magic that would guess the purpose of your item.

Thanks Klemen, that's what I thought.  What is it that needs to be included for it to work the same?

There is no way to do this in MCreator with UI editor, but you can alter the code. Search on the internet for the code snippets on how one would do this.

thanks Klemen, been searching and reading code all day and haven't found one yet.  I'm also looking at the vanilla code for saddles/horse entities to see what hooks I can use.  Once I find it, will post for others in case it comes up again.

Donate to MCreator

By donating to developers you can speed up development, as with more resources, we can dedicate more time to MCreator. It is a free project made by developers working on it in their free time.