So, all I did was swap /entitydata for /testfor. What I got after triggering the testfor command was an error message saying that Emmy did not match the required data structure. What am I doing wrong?
The Meaning of Life, the Universe, and Everything.
Location:
Nowhere
Join Date:
3/29/2013
Posts:
68
Minecraft:
MithicalGaming
Member Details
I'm not the most experienced with armor stands either but at a glance I think the issue is indeed with the data structure. It seems like you're passing a bunch of paramters to /testfor that it's not equipped to handle. Start small and then get more specific, see which parameters it's able to receive.
Rollback Post to RevisionRollBack
Check out my Stream-A-Day pledge here where I frequently stream CTM Development!
Follow me on Twitter and subscribe on Youtube for more content!
You need to make sure that tag types match correctly. CustomNameVisible and ShowArms must be 1b or true. When you just enter 1in the entitydata command, it automatically converts them to the right value for you. In the testfor command, it will always test for an exact match, without converting anything, so you must enter exactly the right data yourself.
Rollback Post to RevisionRollBack
To post a comment, please login or register a new account.
So I created an Armor Stand and modified it by using this command:
/entitydata @e[type=ArmorStand,r=3] {CustomNameVisible:1,CustomName:Emmy,ShowArms:1,Equipment:[{},{id:leather_boots,tag:{display:{color:13665433}}},{id:leather_leggings,tag:{display:{color:13665433}}},{id:leather_chestplate,tag:{display:{color:13665433}}},{id:skull,Damage:3,tag:{SkullOwner:"MHF_Alex"}}]}
Everything shows up perfectly fine. The armor is all there. The head is there. The name is visible. Every element of the command works.
Then, in a separate command block, I typed in the following testfor command:
/testfor @e[type=ArmorStand,r=3] {CustomNameVisible:1,CustomName:Emmy,ShowArms:1,Equipment:[{},{id:leather_boots,tag:{display:{color:13665433}}},{id:leather_leggings,tag:{display:{color:13665433}}},{id:leather_chestplate,tag:{display:{color:13665433}}},{id:skull,Damage:3,tag:{SkullOwner:"MHF_Alex"}}]}
So, all I did was swap /entitydata for /testfor. What I got after triggering the testfor command was an error message saying that Emmy did not match the required data structure. What am I doing wrong?
Bah, all my images are too big for this sig. Uh... here, have a Toad.

Check out my adventure map: An Amazing Journey
I think it's the format. The format that works for entitydata doesn't work for testfor. But now I don't know what DOES work for the testfor commands.
EDIT: Okay, so I found out why one part of the testfor command doesn't work.
If I perform an entitydata command, I can use this:
tag:{SkullOwner:"MHF_Alex"}
If I perform a testfor command, I CAN'T use the above and must use this instead:
tag:{SkullOwner:{Name:"MHF_Alex"}}
Why? Don't know. But I suspect it's because "lol meincraft."
EDIT 2: Looks like removing this part also helped:
CustomNameVisible:1,CustomName:Emmy,ShowArms:1
Testfor just doesn't pick up on that stuff, I guess? Or maybe I did it wrong. But the command works without them.
So ultimately, this command worked:
/testfor @e[type=ArmorStand,r=3] {Equipment:[{},{id:minecraft:leather_boots,tag:{display:{color:13665433}}},{id:minecraft:leather_leggings,tag:{display:{color:13665433}}},{id:minecraft:leather_chestplate,tag:{display:{color:13665433}}},{id:minecraft:skull,Count:1b,Damage:3s,tag:{SkullOwner:{Name:"MHF_Alex"}}}]}
Problem solved, more or less!
Bah, all my images are too big for this sig. Uh... here, have a Toad.

Check out my adventure map: An Amazing Journey