[Twinsen] [0.17.75] Tooltip doesn't show an item-with-tags custom_description if it has one set through the prototype
Posted: Tue Nov 05, 2019 2:47 am
When setting a custom description for an item-with-tags through LuaItemStack.custom_description, the description isn't updated if the item already has a description set through the prototype or locale file. This function works normally if there is no description set. Since the placeholder item in vanilla doesn't have a description, I created a small mod to demonstrate the bug. When used on the item with no description, it updates to the custom description.
Thanks.
The mod adds a custom item-with-tags with a description. It also adds recipes to craft both it and the vanilla placeholder item. To recreate the bug, start a new game and craft the custom item with tags. Then set its custom_description to something else, for example by picking up the item and running Code: Select all
/c game.player.cursor_stack.custom_description = "foobar"
Thanks.