XSeries
XSeries copied to clipboard
[XItemStack] setDisplayName(getDisplayName()) doesn't retain the exact original IChatBaseComponent
Description So basicly the issue is that when i save a itemstack to the config using the XItemStack.serialize() function and deserialize it later it changes the nbt and that causes it not to be the exact item it was when it was put in the config.
Here is my full code if you want to review it: https://github.com/RazerStorm/CustomCrafting
It's not possible for me to fix it. I just use get/setDisplayname(), I don't decide what those methods do. Of course I can modify the CraftBukkit instances directly, but that requires extra reflection code and probably a custom string -> TextComponent translator that I'm not willing to do myself.
Also you didn't say which version of Minecraft you're testing this with. If it's not the latest, see if the latest version has this issue as well.
Oh sorry, i indeed forgot to mention the version. The version is 1.20.1
It's not possible for me to fix it. I just use get/setDisplayname(), I don't decide what those methods do. Of course I can modify the CraftBukkit instances directly, but that requires extra reflection code and probably a custom string -> TextComponent translator that I'm not willing to do myself.
Also you didn't say which version of Minecraft you're testing this with. If it's not the latest, see if the latest version has this issue as well.
I accidently closed it, i am keeping it open in case someone decides to fix this :)