Add toggle for enchant level clamping

This commit is contained in:
granny
2025-01-12 14:59:56 -08:00
committed by granny
parent 20b77f1368
commit 07e9649920
4 changed files with 52 additions and 80 deletions

View File

@@ -392,6 +392,7 @@ public class PurpurConfig {
public static boolean allowHigherEnchantsLevels = false;
public static boolean allowUnsafeEnchantCommand = false;
public static boolean replaceIncompatibleEnchants = false;
public static boolean clampEnchantLevels = true;
private static void enchantmentSettings() {
if (version < 30) {
boolean oldValue = getBoolean("settings.enchantment.allow-unsafe-enchants", false);
@@ -415,6 +416,7 @@ public class PurpurConfig {
allowHigherEnchantsLevels = getBoolean("settings.enchantment.anvil.allow-higher-enchants-levels", allowHigherEnchantsLevels);
allowUnsafeEnchantCommand = getBoolean("settings.enchantment.allow-unsafe-enchant-command", allowUnsafeEnchantCommand);
replaceIncompatibleEnchants = getBoolean("settings.enchantment.anvil.replace-incompatible-enchants", replaceIncompatibleEnchants);
clampEnchantLevels = getBoolean("settings.enchantment.clamp-levels", clampEnchantLevels);
}
public static boolean endermanShortHeight = false;