PluginBugs / Issues-ItemsAdder

Repository used to keep track of issues of my plugin ItemsAdder
https://itemsadder.devs.beer
54 stars 21 forks source link

Custom armors with only armor color without itemsadder NBT won't render texture on Optifine or CIT Resewn #3535

Open EpicPlayerA10 opened 7 months ago

EpicPlayerA10 commented 7 months ago

Terms

Discord tag (optional)

epicplayera10

What happened?

Custom armors that have only applied armor color without itemsadder nbt won't show armor texture on Optifine or CIT Resewn. I'm using MMOItems that doesn't add itemsadder NBT.

image

Solution

This bug is caused in CIT configuration because itemsadder matches itemsadder NBT instead of armor color like in vanilla.

I tested various CIT configs and I figured it out that instead of these lines:

nbt.itemsadder.namespace=some_namespace
nbt.itemsadder.id=some_custom_armor

you would replace with this line:

nbt.display.color=11127617

where these numbers converted to hex (11127617 -> A9CB41) is the armor color for texture rendering.

When I change CIT config with these lines above, then the armor renders correctly on both vanilla and optifine and cit resewn.

Steps to reproduce the issue

  1. Setup a custom armor
  2. Join to the server using OptiFine or CIT Resewn mod
  3. Get a leather part (for example leather chestplate) and set only armor color that corresponds to your armor renderer.
  4. Wear it
  5. See that armor texture won't render

Server version

This server is running Paper version git-Paper-464 (MC: 1.20.4) (Implementing API version 1.20.4-R0.1-SNAPSHOT) (Git: e709245)

ItemsAdder Version

ItemsAdder version 3.6.3-beta-13

ProtocolLib Version

ProtocolLib version 5.2.0-SNAPSHOT-679

LoneLibs Version

LoneLibs version 1.0.45

FULL server log

No response

Error (optional)

No response

Problematic items yml configuration file (optional)

No response

Other files, you can drag and drop them here to upload. (optional)

No response

Screenshots/Videos (you can drag and drop files or paste links)

No response

github-actions[bot] commented 7 months ago

Hello, your report will be looked into as soon as possible. Please do not bump this thread and don't post it on multiple platforms.

Thanks a lot for your patience.

LoneDev6 commented 7 months ago

Is this a really necessary change?

EpicPlayerA10 commented 7 months ago

Is this a really necessary change?

Yes, because firstly I use CIT Resewn to show custom armor correctly on shaders, and secondly I use MMOItems for easy management of custom items with skills and Revision ID system.

This change won't break anything because changing it to match armor color will match with the vanilla behaviour. It is not very hard. You can see in my issue a much more detailed and tested solution to this.

umutardafiliz commented 7 months ago

i agree this should be done to make it easier to use with other plugins

Tranquilotl commented 2 weeks ago

Is there a way to handle this issue from clientside? I am experiencing this issue on a server I do not own.