A single item should be an unnamed compound tag and, for a chest, all items should be contained within the same list as each other called "Items". Compound tags use curly brackets: { }
, and lists use square brackets: [ ]
.
Currently, your problem is that you have each item in its own list, when they should both be in the "Items" list.
You are also using numeric IDs which won't work in future versions.
The correct command should be:
/blockdata 3 56 0 {Items:[{id:command_block,Count:1,Slot:12,tag:{HideFlags:1,Unbreakable:1,display:{Name:"Command Block",Lore:["Write Commands Here!"]},ench:[{id:4,lvl:2}]}},{id:stone_button,Count:1,Slot:13,tag:{HideFlags:1,Unbreakable:1,display:{Name:"Button",Lore:["Activate Commands!"]},ench:[{id:4,lvl:2}]}}]}
Essentially, I've changed:
Items:[{command block item info}],[{button item info}]
To:
Items:[{command block item info},{button item info}]
Syntax for testforblock
is:
/testforblock <x> <y> <z> <TileName> [dataValue] [dataTag]
The problem you are having seems to be caused by the fact you've added the word "replace" between the dataValue and dataTag (likely caused by copying and pasting from a setblock command).
Remove the replace
, and it should work fine:
/testforblock ~ ~2 ~ minecraft:standing_banner 0 {Base:15,Patterns:[{Pattern:ss,Color:1},{Pattern:tr,Color:4}]}
Best Answer
The syntax of
/scoreboard players tag
is:You are missing
add
beforeflowerpot
.SelectedItem
should be a compound tag (curly brackets) rather than a list (square brackets).There's also some other issues with your closing brackets, such as trying to close
Lore:[
with}
rather than]
.The fixed command should be: