mirror of
https://github.com/StarWishsama/Slimefun4.git
synced 2024-09-20 03:35:51 +00:00
fix: add missing judge in getRandomEnchantment
This commit is contained in:
parent
9e49071161
commit
8302c0c932
@ -75,7 +75,7 @@ public class MagicianTalisman extends Talisman {
|
||||
|
||||
// @formatter:off
|
||||
List<TalismanEnchantment> enabled = enchantments.stream()
|
||||
.filter(e -> item.getType() == Material.BOOK || e.getEnchantment().canEnchantItem(item))
|
||||
.filter(e -> (isAllowEnchantBook().getValue() && item.getType() == Material.BOOK) || e.getEnchantment().canEnchantItem(item))
|
||||
.filter(e -> hasConflicts(existingEnchantments, e))
|
||||
.filter(TalismanEnchantment::getValue)
|
||||
.collect(Collectors.toList());
|
||||
|
Loading…
Reference in New Issue
Block a user