mojira.dev
MC-124183

LocName fails to change name of items

With the new syntax changes, the display-Name tag works correctly, but display-LocName no longer works to change the item's name.

This command works:

/give @p stone{display:{Name:"{\"text\":\"Rock\"}"}}

However, this command will only give an untampered stone block

/give @p stone{display:{LocName:"{\"text\":\"Rock\"}"}}

Linked issues

Comments

pokechu22

It looks like the recent component changes included deprecating LocName; instead, you should specify a translate component. (There is an upgrade path that will automatically do this for old worlds, but it doesn't change commands).

Note that using LocName with something that isn't a translation string is not the intended use.

If your goal is to make the text not italic, please see MC-123790.

OnePointZero

(Unassigned)

Unconfirmed

Minecraft 18w02a

Retrieved