When I tried to make a function, I ran into an issue where if you use multiple tags in a selector, it will only care about the last one, and disregard the others.
Example:
I want to execute the command '/say hi' on each armor stand with the tag 'test1' AND the tag 'test2'.
I use the command:
execute @e[type=armor_stand,tag=test1,tag=test2] ~ ~ ~ /say hi
However, not only the armor stands with both tags say hi, but also the ones with just the tag 'test2'. This is a big problem for people like me who are depending on being able to use multiple tags.
I also tested this in the chat, command blocks and advancements, but they all got the same result.
P.S.: I know this bug has been reported earlier, but that was back in 2015, and has been resolved, but reintroduced since then, and not been reported yet.
Comments 4
OK. Thanks for the help.
PS: If this was a feature, it would be very handy. You can use multiple scoreboards, so I don't see a Reason you can't program it to go for tags and other things like type as well. Would be a nice feature.
Selector parameters are a basic associative arrays, where keys must be unique. Score parameters are not an outlier because they are inherently unique. For example, with the selector:
@a[score_obj1_min=1,score_obj2_min=1]
The keys are "score_obj1_min" and "score_obj2_min", which are both unique.
This is by design and has always been the case.