You can use the /stats
or check the CommandStats
datatag of the ArmorStand
. I highly recommend use of the /stats
command.
Extract the result:
Run these commands once
Note: Anything suffixed with a "_v" can be whatever you want, as long as they're consistent.
/scoreboard objectives add SuccessCount_v dummy
/stats entity @e[type=ArmorStand,name=Lexer] set SuccessCount @e[type=ArmorStand,name=Lexer] SuccessCount_v
This will store the SuccessCount (in case of this command, 0 or 1) in the scoreboard as @e[type=ArmorStand,name=Lexer] SuccessCount_v
, which you can then test and use as you would any other scoreboard value.
Add results together:
I'm not going to go into detail here, since I am unsure exactly you want to add together. I will, however link you to a wiki page where you can find the format of /scoreboard players operation <selector> <objective> <operator> <selector2> <objective2>
, the only method for doing math in command blocks. (Yes, there is a command dedicated to it. It is not impossible.)
Hope this helps and wish you luck!
Best Answer
Yes, change the field where it says CustomName:"Your Text Here" to CustomName:scoreboardnamehere you might have to use quotes CustomName:"scoreboardnamehere" This should work, as it used to in 1.8. Things shouldn't have changed for 1.9.