1
Custom Item Help
Hi, I am currently in the process of developing a fabric mod for 1.20, and I was wondering two things:
1. How do I make a model have different texture in gui from the texture in the hand?
2. How do I make a custom item change the position and rotation of the players limbs (specifically the arms and maybe the head)?
1. How do I make a model have different texture in gui from the texture in the hand?
2. How do I make a custom item change the position and rotation of the players limbs (specifically the arms and maybe the head)?
Create an account or sign in to comment.
1
![DD9448's Avatar](https://static.planetminecraft.com/files/avatar/617447_0.jpg)
I'm honestly really bad at rendering and models and stuff, but I do know a few examples off-hand.
For using a different texture in the GUI vs. in an entity's hand, you can mix into ItemRenderer#getHeldItemModel: https://github.com/mrsterner/Malum-Quilt/blob/40c32120ca8447641d9a7127e079a1fd32a4bd3a/src/main/java/dev/sterner/malum/mixin/client/ItemRendererMixin.java
For changing the position and rotation of the player's limbs when holding a particular item, you can mix into PlayerEntityRenderer#getArmPose: https://git.sleeping.town/unascribed-mods/Yttr/src/commit/ab727a2dbea7f0b9b9a5ca8e27df83fdbdcf9064/src/main/java/com/unascribed/yttr/mixin/rifle/client/MixinPlayerEntityRenderer.java
(I'm not sure about changing the rotation / position of the head...)
For using a different texture in the GUI vs. in an entity's hand, you can mix into ItemRenderer#getHeldItemModel: https://github.com/mrsterner/Malum-Quilt/blob/40c32120ca8447641d9a7127e079a1fd32a4bd3a/src/main/java/dev/sterner/malum/mixin/client/ItemRendererMixin.java
For changing the position and rotation of the player's limbs when holding a particular item, you can mix into PlayerEntityRenderer#getArmPose: https://git.sleeping.town/unascribed-mods/Yttr/src/commit/ab727a2dbea7f0b9b9a5ca8e27df83fdbdcf9064/src/main/java/com/unascribed/yttr/mixin/rifle/client/MixinPlayerEntityRenderer.java
(I'm not sure about changing the rotation / position of the head...)