-
Notifications
You must be signed in to change notification settings - Fork 35
Configuration
There are two configuration files for PerWorldInventory. The config.yml
file holds all of the general settings for the plugin's operation. World groups are configured in the worlds.yml
file.
This is the default contents of the config.yml
file. Every option is commented, and should be pretty straightforward.
##########################################
# PerWorldInventory configuration file #
##########################################
# If true, the server will change player's gamemodes when entering a world
# The gamemode set is configured in the worlds.yml file
manage-gamemodes: false
# If true, players will have different inventories for each gamemode
separate-gamemode-inventories: true
# If true, any worlds that are not in the worlds.yml configuration file will share the same inventory
share-if-unconfigured: false
# True if PWI should set the respawn world when a player dies
manage-death-respawn: false
# Disables the nagging message when a world is created on the fly
# Intended for users who know what their doing, and don't need to have worlds configured
disable-nag-message: false
metrics:
# Choose whether or not to enable metrics sending.
# See https://bstats.org/getting-started for details.
enable: true
# Send the number of configured groups.
# No group names will be sent!
send-number-of-groups: true
# Send the total number of worlds on the server.
send-number-of-worlds: true
# All settings for players are here:
player:
# Save and Load players' economy balances. Requires Vault!
economy: false
# Load players' ender chests
ender-chest: true
# Load players' inventory
inventory: true
# All options for player stats are here:
stats:
# Load if a player is able to fly
can-fly: true
# Load the player's display name
display-name: false
# Load a player's exhaustion level
exhaustion: true
# Load how much exp a player has
exp: true
# Load a player's hunger level
food: true
# Load if a player is flying
flying: true
# Load how much health a player has
health: true
# Load what level the player is
level: true
# Load all the potion effects of the player
potion-effects: true
# Load the saturation level of the player
saturation: true
# Load a player's fall distance
fall-distance: true
# Load the fire ticks a player has
fire-ticks: true
# Load the maximum amount of air a player can have
max-air: true
# Load the current remaining air a player has
remaining-air: true
# Attempt to figure out which world a player last logged off in
# and save/load the correct data if that world is different.
# REQUIRES MC 1.9.2 OR NEWER
load-data-on-join: false
# Set the level of debug messages shown by PWI.
# INFO: Print general messages
# FINE: Print more detailed messages about what the plugin is doing
# DEBUG: Print detailed messages about everything
logging-level: 'INFO'
# Disables bypass regardless of permission
# Defaults to false
disable-bypass: false
# Set the duration in minutes for player profile information to be cached
cache-duration: 10
# Set the maximum number of player profiles that can be cached at any given time
cache-maximum-limit: 1000
The worlds.yml
file is slightly more complex than the main configuration. It is highly recommended that you do not edit this by hand, and instead use the PWI commands for doing so (see here). In case you do wish to hand-edit this file, read on.
First, the contents of the default configuration:
groups:
default:
worlds:
- world
- world_nether
- world_the_end
default-gamemode: SURVIVAL
respawnWorld: world
This has one group named 'default', and it has three worlds in it. The default-gamemode
key is only used for figuring out what GameMode a player should be when joining that group if manage-gamemodes
is enabled in the main config. As of version 2.1.0, the ability to have PWI set the respawn world after death is supported, and is configured per-group with the respawnWorld
key. Currently, the respawn world must be in the same group.
A group has four parts: the name, the list of worlds, the respawn world, and the default GameMode. The file hierarchy is like this:
<group_name>:
worlds:
- <world_name>
- [more worlds if there are more]
default-gamemode: <GameMode>
respawnWorld: <world_name>
All groups should be under groups:
(at the top). Thus, a second group after the first could look like this:
groups:
default:
worlds:
- world
- world_nether
- world_the_end
default-gamemode: SURVIVAL
respawnWorld: world
creative:
worlds:
- creative
- plotCreative
default-gamemode: CREATIVE
respawnWorld: creative
Follow the above template, watch the number of spaces, and you will be fine.