mirror of
https://github.com/GeorgH93/Minepacks.git
synced 2025-03-12 13:29:46 +01:00
Fix permission check not working and don't bind pickup toggle to toggle by default
This commit is contained in:
parent
bb3420c550
commit
7ed7f70512
@ -117,7 +117,6 @@ Command:
|
||||
- clean
|
||||
Pickup:
|
||||
- pickup
|
||||
- toggle
|
||||
|
||||
# Will be shown in the console during startup
|
||||
LanguageName: "english"
|
||||
|
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2021 GeorgH93
|
||||
* Copyright (C) 2022 GeorgH93
|
||||
*
|
||||
* This program is free software: you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
@ -78,8 +78,8 @@ public void run()
|
||||
// No permission ot use the backpack.
|
||||
if (!player.hasPermission(Permissions.USE)) return;
|
||||
|
||||
// If a player has either of these permissions, pickup is allowed.
|
||||
if (!player.hasPermission(Permissions.FULL_PICKUP) && !player.hasPermission(Permissions.PICKUP_TOGGLE));
|
||||
// Check if auto pickup is allowed
|
||||
if (!player.hasPermission(Permissions.FULL_PICKUP)) return;
|
||||
|
||||
// Inventory is full
|
||||
if (player.getInventory().firstEmpty() != -1) return;
|
||||
|
Loading…
Reference in New Issue
Block a user