I know [r=x] is to make a radius and you can do /tp @a[r=30] x y z to teleport someone everyone 30 blocks away but how can I do it so it excludes me? So let's say that me and two other people are standing 10 blocks away from the command block, how could I make it that it teleports everyone else apart from me?
name=!YOUR NAME to the selector. So if your username is
Chickenator, you should do:
/tp @a[r=30,name=!Chickenator] x y z
! excludes or negates the selection value. You can also exclude teams, using
team=!TEAM, for example if you want to exclude all staff (OP players), you can put them in a team and exclude that team. Another use for the
type=!ENTITY TYPE, for example,
type=!Cow, to exclude cows.