mojira.dev
MC-121780

Score and selector components do not work on signs

The bug

The score and selector text components do not seem to work on signs.

How to reproduce (score)

Use the following commands

/scoreboard objectives add test dummy
/scoreboard players set @s test 1
/setblock ~ ~ ~ standing_sign{Text1:"[\"Test: \",{\"score\":{\"objective\":\"test\",\"name\":\"@p\"}}]",Text2:"[\"\"]",Text3:"[\"\"]",Text4:"[\"\"]"} replace

→ The score is not displayed; inspecting the NBT of the sign shows that the value was set to ""

To verify that the component itself works, use the following command

/give @s written_book{title:"Test book",author:"Test author",pages:["{\"score\":{\"objective\":\"test\",\"name\":\"@s\"}}"]}

How to reproduce (selector)

Use the following command

/setblock ~ ~ ~ standing_sign{Text1:"[\"Test: \",{\"selector\":\"@p\"}]",Text2:"[\"\"]",Text3:"[\"\"]",Text4:"[\"\"]"} replace

Linked issues

Comments 1

Changed to /data merge block, /blockdata is partly removed (and will be fully gone in the next snapshot), hence why you got weird command feedback.

Alexander

(Unassigned)

Confirmed

score, scoreboard, selector, sign, text-component

Minecraft 17w45b

Retrieved