WorldRestrictions is designed to set access restrictions and command whitelists for specific worlds. This plugin allows server administrators to control player behavior in different worlds, offering features such as teleportation restrictions, command restrictions, and economic system integration.
Tested server
Tested on Mohist-1.20.1 and Catserver-side -1.12.2 respectively. The plugin supports both pure and mod servers by default. If your server version cannot be used, please leave a message
Project Advantages
- Flexible World Restrictions: Different access and command restrictions can be set for each world.
- Economic System Integration: Supports integration with the Vault economy plugin, allowing the setting of teleportation fees.
- Easy Configuration: Various settings of the plugin can be easily managed through configuration files.
- Detailed Logging: Generates detailed operation and error logs during plugin execution, facilitating debugging and maintenance.
Usage Tutorial
- Adding an Existing World to the Restricted Worlds List
If you already have a world (e.g., "world" [default world]), you can add it to the restricted worlds list.You can also create new worlds using a multi-world plugin.
- When the prompt appears, it indicates that the world has been successfully added to the restricted worlds list.
- In the plugin configuration file, the restricted world will appear, and you can enable or disable features by inputting `true` or `false`, or modify values to customize operations.
Adding Command Restriction Functionality
- Input `/wr addcmd world cmi spawn` to add the `cmi spawn` command to the command whitelist. This allows players to execute the `spawn` command in this world.
(By default, plugins cannot execute any commands, which means that when you add a world to the restricted world list, the world cannot execute any commands unless it is on the whitelist)
- Note: Due to the installation of CMI, the actual command for `spawn` is `cmi spawn`. Therefore, it must be added this way to execute the `/spawn` command.
The `/spawn` command can be executed, but the `/gm 1` command cannot be executed.
File Introduction
- Plugin Directory Files:
- Configuration File:
- Log File: This file should not be modified; it is used to record installation steps.
Downloading the Plugin - Download the latest version of `WorldRestrictions.jar` from the plugin's release page.
- Pre installation: Ensure that the pre installation plugin Vault is installed correctly and the economy plugin is loaded correctly
- Install the plugin by placing the downloaded `.jar` file in the server's `plugins` folder.
- Start or restart your Minecraft server, and the plugin will load automatically.
Configuration File
The plugin's configuration file is located at `plugins/WorldRestrictions/config.yml`. You can modify the following settings as needed:
# Whether to enable cooldown time
enableCooldown: true
# Cooldown time in seconds
cooldownTime: 60
# Whether to enable maximum entry count
enableMaxEntries: true
# Maximum entry count
maxEntries: 5
# Main city world name
mainCityWorld: "world"
# List of restricted worlds
restrictedWorlds:
- "world1"
- "world2"
# Whether to enable world teleportation cost
enableWorldTeleportCost: true
# World teleportation cost amount
worldTeleportCost: 1000
# Whether to enable teleportation delay
enableTeleportDelay: true
# Teleportation delay time in seconds
teleportDelay: 5
# Is it allowed for administrators to bypass the command whitelist? When true, it will prompt the administrator in the restricted world that the command has been bypassed and the administrator can execute it unconditionally in the restricted world
AllowAdminBypass: True
Using Commands
The plugin provides the following commands to manage world restrictions:
/wr add <world>`: Add a world to the restricted list.
/wr delete <world>`: Remove a world from the restricted list.
/wr list`: List all restricted worlds.
/wr reload`: Reload the plugin configuration.
/wr tp <world>`: Teleport to a restricted world.
/wr leave`: Leave a restricted world.
/wr addcmd <world> <command>`: Add a command to the whitelist for a restricted world.
/wr delcmd <world> <command>`: Remove a command from the whitelist for a restricted world.
Permission Settings
The following permissions are defined in `plugin.yml`:
- `worldrestrictions.use`: Allows the use of `/wr tp` and `/wr leave` commands, default open to all players.
- `worldrestrictions.admin`: Allows the use of all `/wr` commands, default open only to server administrators.
Log Files The plugin generates log files in the `plugins/WorldRestrictions/log` folder, including:
- `world_restrictions_record.txt`: Records restricted worlds and their command whitelists.
- `error_log.txt`: Records error information during plugin execution.
Through these features, the WorldRestrictions plugin provides powerful tools for server administrators to manage player behavior in different worlds, ensuring the stability and security of the server.
Update log
1.0.0
First release of plugin
1.0.1
The plugin has been released for the first time with the addition of a configuration item in config. yml: Control whether administrators can bypass the command whitelist and prompt them when they do so. 1: Fix 1.12.2 catserver incompatibility issue 2: Optimization administrators cannot use command functions in restricted worlds 3: Optimization: Unable to add command whitelist function in restricted world: 4: At present, in the case of restricting the world and no whitelist of commands, it is still possible to execute commands for the restricting world plugin by default 5: Optimize compatibility issues across different versions
1.0.2
Fix: Command whitelist cannot be stored after restarting the server
If there are any issues with the plugin or if you need to add features, you can leave a message below the post and we will reply as soon as you see it. The plugin will continue to be updated and maintained, and there will be more features in the future