mirror of
https://github.com/GeorgH93/Minepacks.git
synced 2024-11-15 10:55:20 +01:00
Remove old "backpack" permission
This commit is contained in:
parent
d74071acda
commit
2603b9be31
@ -27,14 +27,10 @@ permissions:
|
||||
backpack.disable:
|
||||
description: This permission group can be used to disable the plugin for certian users/groups/worlds.
|
||||
children:
|
||||
backpack: false
|
||||
backpack.use: false
|
||||
backpack.others: false
|
||||
backpack.keepOnDeath: true
|
||||
backpack.clean: false
|
||||
backpack:
|
||||
description: Allows a player to open the backpack. This is a fallback permission since some permission plugins have problems with the backpack.use permission.
|
||||
default: false
|
||||
backpack.use:
|
||||
description: Allows a player to open the backpack.
|
||||
default: false
|
||||
|
@ -77,7 +77,7 @@ public boolean onCommand(CommandSender sender, Command cmd, String arg, String[]
|
||||
if(args.length == 0)
|
||||
{
|
||||
// Open player backpack
|
||||
if(player.hasPermission("backpack.use") || player.hasPermission("backpack"))
|
||||
if(player.hasPermission("backpack.use"))
|
||||
{
|
||||
if(gameModes.contains(player.getGameMode()) || player.hasPermission("backpack.ignoreGameMode"))
|
||||
{
|
||||
@ -120,7 +120,7 @@ public boolean onCommand(CommandSender sender, Command cmd, String arg, String[]
|
||||
case "help": // Shows the help for the plugin
|
||||
case "hilfe":
|
||||
case "?":
|
||||
if(player.hasPermission("backpack.use") || player.hasPermission("backpack"))
|
||||
if(player.hasPermission("backpack.use"))
|
||||
{
|
||||
player.sendMessage(ChatColor.GOLD + "Minepacks Help:");
|
||||
player.sendMessage(ChatColor.AQUA + "/backpack" + ChatColor.WHITE + " - " + plugin.lang.getTranslated("Commands.Description.Backpack"));
|
||||
|
@ -43,7 +43,7 @@ public void run()
|
||||
{
|
||||
for(Player player : Bukkit.getServer().getOnlinePlayers())
|
||||
{
|
||||
if(player.getInventory().firstEmpty() == -1 && (player.hasPermission("backpack.use") || player.hasPermission("backpack")) && player.hasPermission("backpack.fullpickup"))
|
||||
if(player.getInventory().firstEmpty() == -1 && player.hasPermission("backpack.use") && player.hasPermission("backpack.fullpickup"))
|
||||
{
|
||||
// Only check loaded backpacks (loading them would take to much time for a repeating task, the backpack will be loaded async soon enough)
|
||||
Backpack backpack = (Backpack) plugin.getBackpackCachedOnly(player);
|
||||
|
Loading…
Reference in New Issue
Block a user