In Minecraft, I want to testfor if a player is on one team or the other

In Minecraft, I want to testfor if a player is on one team or the other - Sportsmen in red and blue waistcoats chatting on floor of spacious curling arena

I want to testfor if a player is on team 1, but if he is on team 2, then the comparator will still activate. I tried: testfor @p[team=1,team=2]
It only works for team 2 though. Probably because it is at the end. or something. Is it even possible for what I'm doing. Is there a different way maybe?



Best Answer

Use two seperate commandblocks /testfor @p[team=1] and /testfor @p[team=2] ,then connect the comparator outputs




Pictures about "In Minecraft, I want to testfor if a player is on one team or the other"

In Minecraft, I want to testfor if a player is on one team or the other - Group of sitting people spending time in curling arena
In Minecraft, I want to testfor if a player is on one team or the other - From below of crop multiethnic team of professional basketball players gathering and putting hands together while standing on playground before game
In Minecraft, I want to testfor if a player is on one team or the other - Man Catching Soccer Ball on Field



How do you test a specific player in Minecraft?

You can test for a certain target in the game using the /testfor command in Minecraft.

How do you detect what block a player is standing on?

The /testfor command became obsolete in Minecraft 1.13, and has been replaced by the /execute command*. It will do the same as typing /testfor @e {SelectedItem:{id:"<item>"}} and then putting a comparator to the command block with the command, and then running the command which you wanna run.



Detect When A Player Is At A Block/Blocks Minecraft




Sources: Stack Exchange - This article follows the attribution requirements of Stack Exchange and is licensed under CC BY-SA 3.0.

Images: SHVETS production, SHVETS production, Andrea Piacquadio, Pixabay