Editing
MinecraftCommands
(section)
Jump to navigation
Jump to search
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== spreadplayers === {{/infobox |spreadplayers |op |1.6.1|13w23a }} Teleports entities (players, mobs, items, etc.) to random surface locations within an area. ;Syntax : <code>spreadplayers <''x''> <''z''> <''spreadDistance''> <''maxRange''> <''respectTeams''> <''player β¦''></code> ;Arguments : ''x z'' :: Specifies the center of the region to spread targets to. ''x'' and ''z'' must be between [[World boundary|-30,000,000 and 30,000,000]] (exclusive). May use [[#Tilde notation|tilde notation]] to specify coordinates relative to the command's execution. : ''spreadDistance'' :: Specifies the minimum distance between targets. Must be at least 0.0. : ''maxRange'' :: Specifies the maximum distance on each horizontal axis from the center of the area to spread targets (thus, the area is square, not circular). Must be at least 1.0 greater than ''spreadDistance''. : ''respectTeams'' :: Specifies whether to keep teams together. Must be <code>true</code> or <code>false</code>. If <code>true</code>, targets on the same team will be teleported to the same location. : ''player'' :: Specifies the targets to spread. Must be one or more player names and/or [[#Target selectors|target selectors]] separated by spaces (<code>@e</code> is permitted to target entities other than players). ;Result : Fails if the arguments are not specified correctly, if there are too many targets to satisfy the ''spreadDistance'' requirement within the specified area, or if a target is attempted to be spread to outside the [[world boundary]]. : On success, teleports targets to random surface locations within the specified area. Targets will always be placed on the top block at a location, and never on [[lava]]. ;Examples : To teleport all players by team to random surface locations in a 1,000Γ1,000-block area centered on (0,0), with a minimum distance between teams of 200 blocks: :: <code>spreadplayers 0 0 200 500 true @a</code> : To teleport one random player from each of three teams (Red, Blue, and Green), as well as Alice and Bob, to random surface locations in a 200Γ200-block area centered on (0,0), with a minimum distance between players of 50 blocks: :: <code>spreadplayers 0 0 50 100 false @r[team=Red] @r[team=Blue] @r[team=Green] Alice Bob</code> ;See also : {{cmd|tp}} and {{cmd|teleport}} β different commands that teleport a single player or entity to a specific position (even underground). <!-- please retain double newline above for section differentiation -->
Summary:
Please note that all contributions to Hegemon Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Hegemon Wiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Navigation menu
Personal tools
Not logged in
Talk
Contributions
Log in
Namespaces
Page
Discussion
English
Views
Read
Edit
Edit source
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
What links here
Related changes
Special pages
Page information