This is an updated version of BuyRegion for Minecraft 1.13 .
Original code credit goes to Luke199 .
If anyone has a problem with me publishing this resource, please let me know.
Allows you to create signs which can be used to buy or rent WorldGuard/RedProtect regions. The plugin works with all Vault supported economy systems as it requires Vault for economy support.
Requirements
- Vault
- Region Manager
- WorldGuard >7.0.0 Beta 3 (MC 1.13)
- RedProtect >7.6.0 b#200
- Vault-supported Economy plugin (i.e. Essentials)
Upgrading
If you are upgrading from MC <1.13, make sure you make a backup of your BuyRegion, WorldGuard & WorldEdit configs.
Download the latest WorldGuard & WorldEdit versions (currently in development for MC 1.13), and replace the BuyRegion.jar with this project's.
Changes
Features
- Added better i18n to choose between languages in config.yml
- Support for region managers other than WorldGuard
Bug Fixes
- Fixed a NullPointerException that would sometimes occur when the region was not found
- If a rented region is deleted that has auto-renewal, it will most likely fail silently
- Added context to most errors logged to console
- Easier to troubleshoot for both user & me
Performance
- Hopefully made config performance a tad faster at the cost of unnoticeable memory usage
- It's no longer casting the object every time it wants to use it, only on load & unload
Usage
Here you can find the instructions for the original BuyRegion.
Everything still works the same way.
Installation
- Put the plugin in your plugins directory.
- Restart the server.
- Configure your permissions if needed.
- Enjoy!
Permissions
- buyregion.create - allows the creation of [BuyRegion] and [RentRegion] signs.
- buyregion.admin - allows usage of admin commands.
- buyregion.exempt - allows player to bypass BuyRegionMax
- buyregion.buy - allows player to buy a region (if config requires)
- buyregion.rent - allows player to rent a region (if config requires)
Signs
Create a BuyRegion Sign
- [BuyRegion]
- <regionname>
- <price>
- unused/any
- [BuyRegion]
- epic_store
- 200
Create a RentRegion Sign
- [RentRegion]
- <regionname>
- <price>
- <timespan>
- [RentRegion]
- epic_store
- 200
- 7 days
Buy a Region
- The player must enter buy mode by typing /buyregion
- The player must right-click a BuyRegion sign.
If RequireBuyMode is set to false the player will not be required to enter buy mode before buying or renting a region.
Rent a Region
- Same as buying a region, see above.
Commands
Player Commands
- /buyregion - toggles buy mode
- /buyregion renew <region> - renews rental on <region>
- /buyregion autorenew - shows current autorenew status
- /buyregion autorenew <true/false> - sets auto-renew for all of the player's rentals
- /buyregion help - shows help screen
- /buyregion reload - reloads config and locale
- /buyregion buycheck <player> - checks total bought regions for <player>
- /buyregion rentcheck <player> - checks total rented regions for <player>
- /buyregion buyset <player> <amount> - sets total bought regions for <player>
- /buyregion rentset <player> <amount> - sets total rented regions for <player>
- /buyregion buymax - displays current BuyRegionMax
- /buyregion buymax <amount> - sets BuyRegionMax
- /buyregion rentmax - displays current RentRegionMax
- /buyregion rentmax <amount> - sets RentRegionMax
- /buyregion buymode - shows the current RequireBuyMode setting
- /buyregion buymode <true/false> - sets RequireBuyMode
- /buyregion buyperms - shows the current RequireBuyPerms setting
- /buyregion buyperms <true/false> - sets RequireBuyPerms
- /buyregion rentperms - shows the current RequireRentPerms setting
- /buyregion rentperms <true/false> - sets RequireRentPerms
- /buyregion evict <region> - performs an eviction on <region>
- /buyregion help - shows all commands
Timespans
Timespan Examples
- 1 day
- 15 secs
- 20 mins
- 5 h
- Seconds: s, sec, secs, second, seconds
- Minutes: m, min, mins, minute, minutes
- Hours: h, hour, hours
- Days: d, day, days
Config
Config Options
- NEW SignHeaderBuy - top line of signs for buy regions, default [BuyRegion]
- NEW SignHeaderRent - top line of signs for rent regions, default [RentRegion]
- NEW PayRentOwners - pays rent to owner of region
- BuyRegionMax - max regions a player can buy with BuyRegion
- RentRegionMax - max regions a player can rent with BuyRegion
- CheckExpirationsInMins - how often to check for expired rented regions IN MINUTES
- RequireBuyMode - is buy mode required to be on to use buy/rent signs? Recommended: true
- RequireBuyPerms - require the player to have buyregion.buy to buy a region
- RequireRentPerms - require the player to have buyregion.rent to rent a region
- DateFormat - Sets the date format - Accepted Values: Default, US, EU
- Default - year/month/day
- US - month/day/year
- EU - day/month/year
- All messages that are sent to a player can be changed by editing your config.yml in the 'Messages' section.
- Between the name of the field and the contents you should be able to figure out which is which.
- Sentences that seem to just end will probably have the value placed there.. consider this when making changes.
- No admin messages can be changed... would be a lot of work on my end for nothing.
- Auto-renew is defaulted to OFF for all players. They will only need to turn it on once, however.
- Only use 1 [RentRegion] sign per rentable region. For performance reasons it does not properly support multiple signs per region. It will let you create them, but it will probably lead to strange behavior. This applies to [BuyRegion] signs also.
- I would recommend trying to avoid original RentRegion signs being destroyed.. the replacement of them is still a little sketchy for positioning. I do plan to look at this but was trying to get a release out with the renting for all the people currently dead in the water from that other plugin going inactive.
- The CheckExpirationsInMins config setting can accept decimals.. so 0.05 = 3 seconds for instance. Although I wouldn't recommend going less than 0.5 for that setting. With a lot of rented regions it could be a taxing operation. Best left to 5+ minutes for average servers that rent things for days, and not minutes or seconds.
- I didn't bother making the signs indestructible as the idea is to place it inside the already defined protected region.. which would typically make it unbreakable anyways. Furthermore, for performance reasons I'm trying very hard to avoid hooking the block break event.
Quick facts
- Edition: Minecraft Java
- File type: .jar
- Minecraft versions listed: 1.13, 1.14
- How to install: Install the matching mod loader (Forge, Fabric or NeoForge) for your Minecraft version. → Download the .jar. → Put it in the .minecraft/mods folder and launch that loader profile.
- Where to get it: Opens on Spigot — not every file is mirrored on our own servers.
Install steps are the general flow for this file type — How to install Minecraft Java mods & modpacks walks through it step by step.
BuyRegion (1.13+) is a free Minecraft Java mod. Compatible with Minecraft 1.13, 1.14. Downloaded 5,271 times (via Spigot). Download it and open it directly in the game.