WorldBorder
Further releases for Spigot 1.13+ are now being posted on the Spigot site. I do not plan to release any further updates here on BukkitDev.
- Full list of Commands and Permissions
- Changelog
- Further Miscellaneous Information
- Source available on GitHub
- Old discussion on main Bukkit forum
If you appreciate this plugin and actually want to see it developed further by me rather than only receiving compatibility updates, you are welcome to
.
Thanks to the following people who have been kind enough to donate: jonDatz, xrobau, Gussi, Dizzy, R. Meijer, FoundationCraft, T. Bronner, R. Thompson, The Pokemon Server, legitplay.net, D. Senff, Vik1395, TagCraftMC, D. Strickner, M. Wilson, Rhythmatic, W. Downey, P. V. Gretener, MiniCraft Server, Cosmic Craft, ScarcityFree.com, polaris_iv (Forge port), matagin, T. Ahokas.
Also thanks to IMathe172I (Lang Lukas) for contributing code to support elliptic and rectangular border shapes, and Indiv0 for contributing code to support border wrapping.
Description
This plugin is intended to efficiently provide a border for each of your worlds, which only people granted special bypass access are allowed beyond. These borders can be round/elliptic or square/rectangular. As the plugin has been written with performance as the most important goal, it should have no performance impact on your server. Additional world trimming and filling commands are available as well.
Older plugins which originally inspired the creation of this one: rBorder and BorderGuard.
Features
- You can set up a separate border for each world, but only one border per world.
- You can have either round/elliptic or square/rectangular borders. Square/rectangular borders are slightly higher performance, round/elliptic borders make for nicer display maps. Different worlds can have different border shapes if you so choose.
- Configuration and border setup is done completely using commands in-game or through the server console. No need to ever edit the config file directly.
- Support for all permission plugins which interface with Bukkit's built-in "superperms" permission system.
- You can fully generate (fill) your world all the way to the border, filling in any missing chunks, including a configurable buffer zone just outside your border.
- You can trim off any world chunks beyond the border, getting rid of extraneous parts, with a configurable buffer zone left just outside your border.
- You can use a bypass command to allow specific players to go beyond all borders.
- Borders can be automatically displayed in DynMap if you use that plugin.
- All plugin data is automatically saved whenever any borders or settings are changed.
- If a player crosses a border while in a vehicle, the momentum of the vehicle is stopped and it is moved back inside the border with the player.
- When a player is moved back inside a border, they will be moved to a safe vertical location if needed.
- Borders for specific worlds can be set to wrap around instead of just knocking back players who cross the border, instead sending them to the opposite edge of the border.
English Tutorial:
Spanish Tutorial:
Of special interest are the Fill command and the Trim command features:

Borders are also displayed automatically by default in DynMap if you have it:


-
View User Profile
-
Send Message
Posted Jul 11, 2012@StuckingFoned
This plugin does not monitor player move events, so your question is misguided. You can confirm this by viewing the publicly available source on GitHub.
@meowcat64646
That should work.
-
View User Profile
-
Send Message
Posted Jul 10, 2012Question. Lets say that I were to go into a 1.1 world that was fully generated inside of the border. Now that its 1.2, my world is fully generated without any jungles and no more room to generate new ones. Would I be able to set the border radius to lets say 1 and then use the trim command to cut off the old 1.1 chunks so that when they are passed into they will now generate as 1.2 chunks?
-
View User Profile
-
Send Message
Posted Jul 10, 2012Isnt watching player move events going to destroy cpu on larger servers?
-
View User Profile
-
Send Message
Posted Jul 6, 2012@xsonarx
That would be a useful option.
I'd also like to suggest an option to configure a warning message sent to the player when they come within a certain distance of the border. For both shapes, rectangle and circle, it would just be another miniature inside of the original border, which, when the player crosses, a warning would print in their chat box saying they are getting near the border. This would help players to stop building near the border without knowing it and getting cut off.
Not sure how complicated that would be, but IMO it would be a nice feature. =)
-
View User Profile
-
Send Message
Posted Jun 28, 2012I cant see any permission to allow certain Groups or even OP's to cross the border? is there one?
-
View User Profile
-
Send Message
Posted Jun 26, 2012Is there any way to choose what block appears beyond the boarder? I would like air only beyond the border because the world is skylands. I am using SkyLands+.
If not, is there any way to place a visible border?
I also wanted to mention that trim does not seem to work in my skylands world. Perhaps it doesn't like SkyLands+?
-
View User Profile
-
Send Message
Posted Jun 25, 2012@FenixAzulDev
To get border info for a specific world you can use this to get the BorderData for it (or null if no border is set for the specified world): Config.Border(String world)
-
View User Profile
-
Send Message
Posted Jun 25, 2012First off, great plugin. Works very well and is simple to use! It also works great with Dynmap.
So, I've been messing with WorldBorder lately (the trim command in particular, alongside Dynmap), and have discovered a few issues (and their solutions/workarounds) that brought me a bit of grief while trying to clean up the borders of my world(s).
I thought you might like to know about these potential issues (if you don't already), just for future reference, and/or in case anyone comes asking for these exact answers.
I kept receiving the "Error: could not delete region xxx.mca" - so I tried to delete them myself while the server was running. It didn't work, and let me know that it was Java (i.e. the server) using the file. So I stopped the server, restarted it (made sure nobody logged on), and then it worked. That being said: to ensure that you can successfully use the trim command, you should completely stop your server (not just a reload), restart it, and run and let the trim command complete before you let any players back on. This is not the fault of WorldBorder, but more just normal server functions interfering with it. I believe it has to do with the server holding on to the regions that players were located in, and so WorldBorder is not able to delete those regions until the server is restarted and "lets go" of those regions.
The same goes for Dynmap. If you have Dynmap running, and it's still trying to render pieces of the map, I believe it will take hold of the region xxx.mca files as well, giving you a similar error. This may have just been all the server's fault as stated above, but just to be on the safe side: if you still receive the "Error: could not delete region xxx.mca" message while trying to use /trim even after doing the above, you should additionally disable Dynmap as well when trying to /trim.
-
View User Profile
-
Send Message
Posted Jun 25, 2012Any documentation of the api? just need to get my worlds area for a teleportation plugin im coding
-
View User Profile
-
Send Message
Posted Jun 24, 2012@dropposite
When chunks are generated by the fill command, obviously the newly generated chunks take up more space. It's the same as if players had wandered around and generated those chunks. Until those chunks have been generated, they don't really "exist" and don't take up any space on your hard drive. I'm not sure what else to say if that doesn't make sense to you.
-
View User Profile
-
Send Message
Posted Jun 24, 2012@Brettflanthats exactly how I used it.
Why did my map size go from 500 megs to 1.8gigs after performing the fill command then?
this is by design?
I had to restore and lost 2 days of builds, but what i gained was players quiting the server and a load of complaints.
So, thats why u are inheriting this 1 complaint :)
I am still using WB, same border size.... I redid the Trim command, but theres just no way i am ever typing the word Fill ever again
map is 500megs, border is set.....theres only 1 player on my server, but life goes on.
-
View User Profile
-
Send Message
Posted Jun 24, 2012@dropposite
The fill command fills in (generates) all missing chunks out to the border, by default including the same buffer zone used by the trim command.
-
View User Profile
-
Send Message
Posted Jun 23, 2012@Brettflan First off, i have used the trim/fill command before. i thought i understood what it does.
correct me here, but fill is to be used after the trim command
example.... set a border to 100..... then use trim which removes all chunks after 100....then u use the fill command to regenerate the chunks just outside the trim zone so the map is smooth.
This is how i used it previously, and never had issues
some great players of mine all decided to travel in opposite dirctions until finding a mushroom biome......
they ran like 8000 in each direction and totally messed up my small map..... so i turned on wb, stood in the approximate center of the map, and set the border to 7000.(becuse they built there)
Then I did the trim and fill commands.
3 days later i realized the map size was thru the roof.
Maybe i am using the trim/fill command wrong, as your suggesting i dont undersatnd what it does.....if thats the case i would ask why you dont have a better description of what it does for idiots like me.
Anyway, I went back in and reran the trim command again.... it says it removed some 40,000 chunks, yet my world size is 200 bytes smaller now.
-
View User Profile
-
Send Message
Posted Jun 23, 2012@dropposite
A trim wouldn't have increased the world size, obviously, it would have decreased it for every 512x512 region dropped.
Are you telling me you set a large border and used the fill command without any understanding of what it does? Why would you do that? You can always set a smaller border and use the trim command to reduce the world size back down again, but as you say your players might not be that happy if they've built out towards the current border. It's up to you.
-
View User Profile
-
Send Message
Posted Jun 23, 2012@droppositecorrection, its 1.68 gigs
-
View User Profile
-
Send Message
Posted Jun 23, 2012holy crap, help me. I turned on world border, and initiated the trim and fill commands....
My main world just went from about 300 megs to about 1.1gigs in size from this.
I did the trim/fill 3 days ago and just realized now what it did.
I cant roll back to a backup from 3 days ago cause all my players would flip out.
What the hell did worldborder do to my world??????
How can I reclaim this space and fix my world size?!???
-
View User Profile
-
Send Message
Posted Jun 22, 2012@Hans6666
Yeah, nothing useful there. Without an error message I have no idea why it would be causing a crash for you.
-
View User Profile
-
Send Message
Posted Jun 22, 2012hmmm...nothing special http://pastebin.com/qynqNQv3
no "overloaded" message....hmmmm
-
View User Profile
-
Send Message
Posted Jun 22, 2012@ryvix
Sadly there's no way to prevent it from generating those chunks. You might try to limit the Nether world size to 1/8 of the main world size.
-
View User Profile
-
Send Message
Posted Jun 22, 2012@Hans6666
Do you get any messages at all in the server log before it crashes?