Commands and Permissions
There is only one command in the plugin:
- /oldeath reload
Permissions for it:
- oldeath.reload
Configuring the config (config.yml)
Now let's move on to the configuration. Let's analyze its parameters.
onPlayerDeath - section, which is responsible for the event when a player dies.
onPlayerDeath:
SaveInventory: true - allows to save player's inventory without gamerule. The bug was fixed. true - the inventory will be saved. false - it will not.
KeepLevel: true - whether to save player's experience at death? true - yes. false - no.
DroppedExp: '0' - if KeepLevel is enabled, then if you enter 10 in the parameter, 10 experience points will be taken from the player when he dies. If KeepLevel is off, this parameter will not work, if 0, no experience will be dropped.
RespawnOnMoment: true - allows you to turn off the main function of the plugin - instant revival. If false - the player will see a sign with “Respawn”.
DisableMinecraftDeathMessage: true - also a replacement for gamerule, disables the usual message when dying from minecraft.
Now let's move on to the
onPlayerRespawn section. This section is responsible for respawning the player.
onPlayerRespawn:
sound: true - Allows you to make a sound on revival.
[v1.1]
soundOnRespawn:
BLOCK_NOTE_BLOCK_BASS - What sound will be played on revival
[v1.1]
Title: '&aRespawn!' - Shows a full screen message in the middle. This is the title.
Subtitle: '' - Shows the message at the bottom of the subtitle. This is the subtitle.
TitleFadeIn: 10, TitleStay: 70, TitleFadeOut: 20 - You can play with these parameters. First - for how long the inscription will appear, second - for how long it will go away, and third - for how long the inscription will be shown. (Works together with subtitle)
gamemodeAfterRespawn: Survival - what gamemode will be given after respawning. (Creative, Adventure, Survival and Spectator)
ActionBar: '' - Parameter to customize the message when resurrected above the player bar.
Chat: '' - Parameter to customize the message when resurrecting in chat.
messages - Command messages.
messages:
configReloaded: "&aThe OLDeath configuration has been rebooted." - message about reloading the plugin.
noPermission: "&cYou do not have permission to execute this command." - no permission for this command.
onlyPlayer: "&cThis command can only be used by the player." - the command can only be used by a player. Useless at this point.