From 521fcedd531ea2b309e899606380aad044f4f592 Mon Sep 17 00:00:00 2001 From: TelepathicGrunt <40846040+TelepathicGrunt@users.noreply.github.com> Date: Mon, 4 Nov 2024 02:10:31 -0500 Subject: [PATCH] Show a range's default value in config file (#1652) --- src/main/java/net/neoforged/neoforge/common/ModConfigSpec.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/neoforged/neoforge/common/ModConfigSpec.java b/src/main/java/net/neoforged/neoforge/common/ModConfigSpec.java index 870ce31e09..0bd991443d 100644 --- a/src/main/java/net/neoforged/neoforge/common/ModConfigSpec.java +++ b/src/main/java/net/neoforged/neoforge/common/ModConfigSpec.java @@ -363,7 +363,8 @@ public > ConfigValue defineInRange(String pat public > ConfigValue defineInRange(List path, Supplier defaultSupplier, V min, V max, Class clazz) { Range range = new Range<>(clazz, min, max); context.setRange(range); - comment("Range: " + range.toString()); + comment(" Default: " + defaultSupplier.get()); + comment(" Range: " + range); return define(path, defaultSupplier, range); }