Updates version to 0.9.1.0, updates README and adds a permission for changing config values

Adds the stargate.admin.config permission, which is required to use /sg config
This commit is contained in:
2021-11-09 21:16:53 +01:00
parent b4d908eaa0
commit 1c2cad2ec1
5 changed files with 19 additions and 7 deletions

View File

@ -19,7 +19,7 @@ public class CommandConfig implements CommandExecutor {
public boolean onCommand(@NotNull CommandSender commandSender, @NotNull Command command, @NotNull String s,
@NotNull String[] args) {
if (commandSender instanceof Player player) {
if (!player.hasPermission("stargate.admin")) {
if (!player.hasPermission("stargate.admin.config")) {
Stargate.getMessageSender().sendErrorMessage(commandSender, "Permission Denied");
return true;
}

View File

@ -48,7 +48,7 @@ public class StarGateTabCompleter implements TabCompleter {
if (!(commandSender instanceof Player player) || player.hasPermission("stargate.admin.reload")) {
commands.add("reload");
}
if (!(commandSender instanceof Player player) || player.hasPermission("stargate.admin")) {
if (!(commandSender instanceof Player player) || player.hasPermission("stargate.admin.config")) {
commands.add("config");
}
return commands;

View File

@ -1,6 +1,6 @@
name: Stargate
main: net.knarcraft.stargate.Stargate
version: 0.9.0.7
version: 0.9.1.0
description: Stargate mod for Bukkit Revived
author: EpicKnarvik97
authors: [ Drakia, PseudoKnight, EpicKnarvik97 ]
@ -138,14 +138,18 @@ permissions:
stargate.admin.bungee:
description: Allows the creation and destruction of a stargate between BungeeCord servers
default: false
stargate.admin.config:
description: Allows the player to change config values from the chat
default: false
stargate.server:
description: Allows the creation of a BungeeCord stargate going to any server
default: false
stargate.admin:
description: Allow all admin features and commands (Hidden/Private bypass, BungeeCord, Reload)
description: Allow all admin features and commands (Hidden/Private bypass, BungeeCord, Reload, Config)
default: op
children:
stargate.admin.reload: true
stargate.admin.hidden: true
stargate.admin.private: true
stargate.admin.bungee: true
stargate.admin.bungee: true
stargate.admin.config: true