Got a question that the wiki doesn't answer? Ask on the forum (preferred), or join us on IRC.

BeastNode

WorldGuard/Regions

From EngineHub.org Wiki
Jump to: navigation, search

Regions in WorldGuard allow you to define rules for and protect certain areas.

Contents

Introduction

Regions:

  • Have a list of owners that can edit in the region
  • Have a list of members that can build in the region
  • May have a parent region and a priority
  • Can have flags to disable certain features (such as PvP)

Regions protect building and breaking blocks by default, and can have flags that disable other actions such as using doors, placing vehicles, and so on.


Selecting regions

Regions are selected using WorldEdit.

Unfamiliar with WorldEdit?

  1. Give the worldedit.selection.* permission to allow users to select areas.
  2. With the wooden axe, left and right click blocks to set a cuboid's first and second point.
  3. Use //expand 10 15 up to make the area 10 units larger upwards and 15 units larger downwards.

If you want to make the selection extend between sky and bedrock, use //expand vert.

Check out the help for WorldEdit. WorldEdit has the most powerful cuboid and polygonal selection and manipulation tools of any plugin or mod in Minecraft and so you should become familiar with it!

Commands

Permission must be given for /region for users to be able to use these commands. See the the permissions page for a list of these permissions.

Defining regions

  • /region define <id> [owner1] [owner2] [owner3] (etc.)

This defines a new protected region. You can enter a list of owners that will be able to build in this area. To specify a player, just enter their name for player. To specify groups, put 'g:' in front of the group name. Re-defining an area will clear all of its information. To add members, use /region addmember (see below).

Tip: To give a user the ability to bypass protection, use the permission worldguard.region.bypass.[Your Worldname].

Claiming regions

  • /region claim <id>

Allows a regular user to claim a plot of land and be set as its areas owner. Users can only claim areas that don't overlap other people's areas and they cannot replace another existing area that they don't own. They redefine areas they own with this command. Re-claiming an existing owned area will clear its owner list.

Setting a region's flags

Main article: Region Flags

The regions list will be written to file when a flag is changed.

The region "__global__" is a master region. Apply flags to it, and it will be the default.

State flags

The following syntax is for setting state flags, the most common type of flag:

  • /region flag <id> <flag> <none|allow|deny>
  • /rf <id> <flag> <none|allow|deny>

Set a flag on an existing region.

  • A flag with none as its state means that it will have the default behavior.
  • allow explicitly allows the behavior.
  • deny explicitly denies the behavior.
  • deny takes precedence over allow, and allow takes precedence over none.
  • All regions start off with none for all of its flags when first created.

For example, if two regions overlap, if one of those two regions has deny for its build flag, then no one will be able to build at all. If one of those regions has allow for its build flag and the other does not have deny, then anyone can build in the region.

Setting a region's parent

  • /region setparent <id> <parent-id>
  • /region setparent <id> (to clear the parent)

Set a region's parent to another region. Not providing a parent clears the specified region's parent.

Deleting a region

  • /region delete <id>

Removes a region. The regions list will be written to file.

If the region has children, all the children will be removed.

Getting information about a region

  • /region info <id>

Lists information about a region.

Adding owners and members

  • /region addowner <id> <owner1> [owner1] [owner2] [owner3] (etc.)
  • /region addmember <id> <member1> [member2] [member3] [member4] (etc.)

Add owners or members to an existing region. You can specify both players and groups just like in the /region define command. The regions list will be written to file.

/region addowner jonpagoda jit erich g:members

Listing regions

  • /region list [page]

Prints a list of regions.

Saving the list of regions

  • /region save

Save the list of protected regions to file. Every time you add, remove, or edit a protected region, the changes are automatically saved so you rarely need to use this command.

Loading the list of regions

  • /region load

Load the list of protected regions from file. You only need to use this command if you edited the protected regions file out-of-game and now need to reload it without restarting the server.

Region wand

You can use leather and right click a block to see a list of regions that encompass this. You can change the wand item by modifying WorldGuard's configuration.

Tutorial

Allowing only "Jon" and "Tetsu" to work on a pagoda

The name of this region will be pagoda.

  1. Select the region with WorldEdit.
  2. Type in /region define pagoda Jon Tetsu.
  3. You're done!

Now Zhyk wants to join in? Don't want him as a region owner? Use /region addmember pagoda Zhyk

Allowing players to build inside plots inside a protected city

  1. Select the city's region with WorldEdit.
  2. Create a region for it with /region define city.
  3. For Alex, who is a resident of the city, select the region for his plot.
  4. Create a region for it with /region define alexplot alex.
  5. Make Alex's region higher priority than the city's region in order for access to work out properly by using /region setpriority alexplot 10. If you do not do this, Alex would need build access in both his plot and the city plot.
  6. You're done!

Allowing specific groups as owners of an area

  1. Select the city's region with WorldEdit.
  2. Create a region for it with /region define area g:Admins g:Moderators.
  3. You're done!

Database Format / External Tools

See the database format article.



Namespaces

Variants
Actions