From a392702df214cbfb2c30ff4f6d3746a1d2f4a66a Mon Sep 17 00:00:00 2001 From: alexcrea Date: Thu, 21 May 2026 20:42:53 +0200 Subject: [PATCH] negative max dialog size as infinity --- defaultconfigs/1.18/config.yml | 10 +++++++++- defaultconfigs/1.21.11/config.yml | 10 +++++++++- defaultconfigs/1.21.9/config.yml | 10 +++++++++- defaultconfigs/1.21/config.yml | 10 +++++++++- src/main/kotlin/io/delilaheve/util/ConfigOptions.kt | 2 +- src/main/resources/config.yml | 8 +++++++- 6 files changed, 44 insertions(+), 6 deletions(-) diff --git a/defaultconfigs/1.18/config.yml b/defaultconfigs/1.18/config.yml index 9fbdb5c..12322e9 100644 --- a/defaultconfigs/1.18/config.yml +++ b/defaultconfigs/1.18/config.yml @@ -100,7 +100,9 @@ permission_needed_for_color: true use_of_color_cost: 0 # Dialogue rename menu make use of dialog menu to allow bigger rename -# You can change the maximum size +# You can also change the maximum size and set it to -1 or less for maximum +# +# This feature only work on paper 1.21.7 or later # # At the moment only english is available for this menu... sorry ! # @@ -109,6 +111,12 @@ enable_dialog_rename: false dialog_rename_max_size: 256 permission_needed_for_dialog_rename: false +# This allows custom anvil to not "guess" the text used for rename but store it in the item +# It will make item stackable only and only if it had used the same rename text +# +# For practical reason. this only work when dialog rename is enabled +dialog_rename_keep_user_text: true + # Override limits for specific enchants # # Enchantments not listed here will use the value of default_limit diff --git a/defaultconfigs/1.21.11/config.yml b/defaultconfigs/1.21.11/config.yml index a3bcd76..39c8504 100644 --- a/defaultconfigs/1.21.11/config.yml +++ b/defaultconfigs/1.21.11/config.yml @@ -102,7 +102,9 @@ permission_needed_for_color: true use_of_color_cost: 0 # Dialogue rename menu make use of dialog menu to allow bigger rename -# You can change the maximum size +# You can also change the maximum size and set it to -1 or less for maximum +# +# This feature only work on paper 1.21.7 or later # # At the moment only english is available for this menu... sorry ! # @@ -111,6 +113,12 @@ enable_dialog_rename: false dialog_rename_max_size: 256 permission_needed_for_dialog_rename: false +# This allows custom anvil to not "guess" the text used for rename but store it in the item +# It will make item stackable only and only if it had used the same rename text +# +# For practical reason. this only work when dialog rename is enabled +dialog_rename_keep_user_text: true + # Override limits for specific enchants # # Enchantments not listed here will use the value of default_limit diff --git a/defaultconfigs/1.21.9/config.yml b/defaultconfigs/1.21.9/config.yml index 4d88d1b..84eccba 100644 --- a/defaultconfigs/1.21.9/config.yml +++ b/defaultconfigs/1.21.9/config.yml @@ -100,7 +100,9 @@ permission_needed_for_color: true use_of_color_cost: 0 # Dialogue rename menu make use of dialog menu to allow bigger rename -# You can change the maximum size +# You can also change the maximum size and set it to -1 or less for maximum +# +# This feature only work on paper 1.21.7 or later # # At the moment only english is available for this menu... sorry ! # @@ -109,6 +111,12 @@ enable_dialog_rename: false dialog_rename_max_size: 256 permission_needed_for_dialog_rename: false +# This allows custom anvil to not "guess" the text used for rename but store it in the item +# It will make item stackable only and only if it had used the same rename text +# +# For practical reason. this only work when dialog rename is enabled +dialog_rename_keep_user_text: true + # Override limits for specific enchants # # Enchantments not listed here will use the value of default_limit diff --git a/defaultconfigs/1.21/config.yml b/defaultconfigs/1.21/config.yml index 8549ca2..df62e6a 100644 --- a/defaultconfigs/1.21/config.yml +++ b/defaultconfigs/1.21/config.yml @@ -100,7 +100,9 @@ permission_needed_for_color: true use_of_color_cost: 0 # Dialogue rename menu make use of dialog menu to allow bigger rename -# You can change the maximum size +# You can also change the maximum size and set it to -1 or less for maximum +# +# This feature only work on paper 1.21.7 or later # # At the moment only english is available for this menu... sorry ! # @@ -109,6 +111,12 @@ enable_dialog_rename: false dialog_rename_max_size: 256 permission_needed_for_dialog_rename: false +# This allows custom anvil to not "guess" the text used for rename but store it in the item +# It will make item stackable only and only if it had used the same rename text +# +# For practical reason. this only work when dialog rename is enabled +dialog_rename_keep_user_text: true + # Override limits for specific enchants # # Enchantments not listed here will use the value of default_limit diff --git a/src/main/kotlin/io/delilaheve/util/ConfigOptions.kt b/src/main/kotlin/io/delilaheve/util/ConfigOptions.kt index f34b9ef..46f79bc 100644 --- a/src/main/kotlin/io/delilaheve/util/ConfigOptions.kt +++ b/src/main/kotlin/io/delilaheve/util/ConfigOptions.kt @@ -461,7 +461,7 @@ object ConfigOptions { .config .getInt(DIALOG_MAX_SIZE, DEFAULT_DIALOG_MAX_SIZE) .takeIf { it in DIALOG_MAX_SIZE_RANGE } - ?: DEFAULT_DIALOG_MAX_SIZE + ?: Int.MAX_VALUE } /** diff --git a/src/main/resources/config.yml b/src/main/resources/config.yml index f59dc46..49b5e5a 100644 --- a/src/main/resources/config.yml +++ b/src/main/resources/config.yml @@ -102,7 +102,7 @@ permission_needed_for_color: true use_of_color_cost: 0 # Dialogue rename menu make use of dialog menu to allow bigger rename -# You can also change the maximum size up to 2147483647 +# You can also change the maximum size and set it to -1 or less for maximum # # This feature only work on paper 1.21.7 or later # @@ -113,6 +113,12 @@ enable_dialog_rename: false dialog_rename_max_size: 256 permission_needed_for_dialog_rename: false +# This allows custom anvil to not "guess" the text used for rename but store it in the item +# It will make item stackable only and only if it had used the same rename text +# +# For practical reason. this only work when dialog rename is enabled +dialog_rename_keep_user_text: true + # Override limits for specific enchants # # Enchantments not listed here will use the value of default_limit