These commands control the world border.
SyntaxThe command has eight variations, each with different arguments:
worldborder add <distance> [time]
(increases the world border diameter)
worldborder center <x> <z>
(recenters the world boundary)
worldborder damage amount <damagePerBlock>
(specifies the world border damage rate)
worldborder damage buffer <distance>
(specifies the world border damage buffer distance)
worldborder get
(returns the world border diameter)worldborder set <distance> [time]
(sets the world border diameter)
worldborder warning distance <distance>
(specifies the world border warning distance)
worldborder warning time <time>
(specifies the world border warning time)
Arguments: distance (add
, damage buffer
, set
and warning distance
modes only) Specifies a distance in blocks:
add
– Specifies the number of blocks to add to the world border diameter.damage buffer
– Specifies the distance outside the world buffer a player must be before they start taking damage. Must be at least 0.0. Initially set to 5.0.set
– Specifies the new diameter for the world border. Must be between 1.0 and 60,000,000 (inclusive, without the commas).warning distance
– Specifies the distance from the world border at which players will begin to see a visual warning of the world border's proximity. Must be at least 0. Initially set to 5.
add
, set
and warning time
modes only)Specifies a time in seconds:add
– Specifies the number of seconds it should take for the world border to move from its current diameter to the new diameter. Must be at least 0. If not specified, defaults to 0.set
– Specifies the number of seconds it should take for the world border to move from its current diameter to the new diameter. Must be at least 0. If not specified, defaults to 0.warning time
– Specifies the number of seconds that a player will begin to see a visual warning before a moving world border passes their position. Must be at least 0. Initially set to 15.
center
mode only)Specifies the horizontal coordinates of the world border's center. Must be between -30,000,000 and 30,000,000 (inclusive, without the commas). May use tilde notation to specify coordinates relative to the command's execution.damagePerBlock (damage amount
mode only)Specifies the damage a player takes per second per block past the world border buffer. For example, if damagePerBlock is 0.1, a player 5 blocks outside the world border buffer will take 0.5 damage per second (damage less than half a heart might not change the visual health display, but will still accumulate). Must be at least 0.0. Initially set to 0.2.ResultFails if the arguments are not specified correctly, or if the new world diameter will be less than 1.0 or greater than 60,000,000.On success:add
– The world border begins changing its diameter by the specified amount. If distance is positive, the world border will turn green and start increasing; if negative, the world border will turn red and start decreasing. If time is 0 or unspecified, the change occurs immediately; otherwise the change proceeds at a rate of (distance/2)/time blocks per second.
center
– The center of the world border immediately moves to the specified coordinates.
damage amount
– Sets the world border damage amount to the specified value. Any player outside the world border buffer will take this amount of damage per second per block past the world border buffer distance.
damage buffer
– Sets the world border buffer distance to the specified value. Players won't take damage until they move past this distance from the world border.
get
– Shows the current world border diameter in the chat.
set
– The world border begins changing its diameter to the specified value. If distance is bigger than the current diameter, the world border will turn green and start increasing; if smaller, the world border will turn red and start decreasing. If time is 0 or unspecified, the change occurs immediately; otherwise the change proceeds at a rate of ((distance-<current diameter>)/2)/time blocks per second.
warning distance
– Sets the world border warning distance to the specified value.
warning time
– Sets the world border warning time to the specified value.