I'm making a costum map which uses comandblocks to teleport players to a spot. The commandblocks are setup under two rooms. (One for team red players and one for team blue players). I need to teleport all players frome one team to a spot (-100 100 -100). and the other team to another spot (100 100 -100).

The problem is that the comand blocks used to teleport team blue are closer to the team red room. This means that I can't just setup the commandblock like this:

tp @a[r=10] 100 100 -100

How can I make shure that one team gets telepoarted to the right area.

Note: This is just an example, there are over 100 commandblocks that need to work. This probebly means that timing it right requires a lot of redstone experiance and is almost inpossibile. The best way would be if there is a command I can just use.

2 Answers 2


Information taken from the wiki:

To teleport players in specific teams, simply add the team=[name] filter onto the @p command, resulting in:

/tp @a[r=10,team=red] 100 100 -100

Just note that everything is CaSe SeNsItIvE (Case sensitive). It means that 'red' is different to 'Red'. Replace the word 'red' with the name of the team.

To set make team, use
/scoreboard teams add [name] [display name... (This can be more than one word)]

And to add a player to the team, use
/scoreboard teams join [team] [player]

  • I do not have setup the teams yet, how do I add players. i'm not good with scoreboards Commented Oct 16, 2014 at 7:29
  • Look at the edit.
    – aytimothy
    Commented Oct 16, 2014 at 7:29
  • so when using comandblocks it will be like this: scoreboard teams join [team] [@p] Commented Oct 16, 2014 at 7:30
  • And by 'player', I mean anyone who's online in the map. You can use @p, @r and @a to do this too. Examples are: /scoreboard teams join red @r and /scoreboard teams join blue somerandomguy
    – aytimothy
    Commented Oct 16, 2014 at 7:30
  • Also, if it is helpful, please don't forget to mark it as an answer. (Tick under the arrows)
    – aytimothy
    Commented Oct 16, 2014 at 7:32
/scoreboard teams join <team name> <player name> (add a player to a team)

/scoreboard teams add <team name> (create a team)

/tp @a[r=RADIUS,team=TEAMNAME] X Y Z
  1. Create the teams
  2. Add the players to their teams
  3. Place a command block and paste the command
  4. Edit the capitalized parts to what applies to you

and you're good to go

  • 2
    I'd recommend expanding this to describe the commands, and how they work in a bit more detail. As is, this might do the trick, but doesn't do a good job of explaining why this solves the problem.
    – Frank
    Commented Oct 16, 2014 at 17:13
  • This answer is a duplicate of aytimothy's answer, only not as well-worded, explained and formatted.
    – MrLemon
    Commented Oct 17, 2014 at 8:59

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .