Skip to content

Releases: xpple/BetterConfig

Release 2.1.3

24 Oct 12:33
Compare
Choose a tag to compare
  • Fixed a mixin bug causing a crash with some mods

Release 2.1.2

09 Oct 17:06
Compare
Choose a tag to compare
  • Added the sources JAR to the publication

Release 2.1.1

09 Oct 14:13
Compare
Choose a tag to compare
  • Fixed a bug with ModConfig#resetTemporaryConfigs that could cause a bug when a config is both temporary and readOnly

Release 2.1.0

13 Sep 16:46
Compare
Choose a tag to compare

This release introduces two new features and some bug fixes!

  • Added the onChange config attribute (#10). You can now register a function that is called whenever a specific config is updated. For example:
    @Config(onChange = "onChange")
    public static List<String> exampleOnChange = new ArrayList<>(List.of("xpple, earthcomputer"));
    private static void onChange(List<String> oldValue, List<String> newValue) {
        LOGGER.info("exampleOnChange was updated | old: {}, new: {}", oldValue, newValue);
    }
  • Added global change hook (#11). This allows you to register a global function that is called whenever any config is updated. For example:
    new ModConfigBuilder<>("<mod id>", Configs.class)
        .registerGlobalChangeHook(event -> BetterConfigCommon.LOGGER.info("{} was updated | old: {}, new: {}", event.config(), event.oldValue(), event.newValue()))
        .build();
  • Added Tatar translations (#8 by Amirhan-Taipovjan-Greatest-I)

Release 2.0

20 Aug 15:13
Compare
Choose a tag to compare
  • Added support for Paper servers
    Depending on your setup, you might have to adjust how the config is initialised:
    • Fabric clients:
      new ModConfigBuilder<FabricClientCommandSource, CommandBuildContext>(<mod id>, Configs.class)
          // ...
          .build();
    • Fabric servers:
      new ModConfigBuilder<CommandSourceStack, CommandBuildContext>(<mod id>, Configs.class)
          // ...
          .build();
    • Paper servers:
      new ModConfigBuilder<>(<plugin name>, Configs.class)
          // ...
          .build();
  • Added support for server-sided custom argument types
    • Fabric:
      dev.xpple.betterconfig.util.WrappedArgumentType
    • Paper:
      io.papermc.paper.command.brigadier.argument.CustomArgumentType
  • Fixed bug where the reset subcommand would be available for readonly configs

Release 1.3-multi-platform

05 Aug 22:12
Compare
Choose a tag to compare
Pre-release
  • Added support for Paper servers (details will follow in the stable release)

Release 1.3

14 Jun 20:02
Compare
Choose a tag to compare
  • Updated to Minecraft 1.21
  • Fixed resetting some configs by using deep copied value

Release 1.2.1

24 Aug 18:37
Compare
Choose a tag to compare
  • Added boolean argument type back to default arguments

Release 1.2.0

23 Aug 18:11
Compare
Choose a tag to compare
  • Made non-api packages no longer visible
  • Rewrote argument registration
    Consider the below example to see how things have changed.
    - .registerTypeWithArgument(Block.class, new BlockAdapter(), new Pair<>(BlockArgumentType::block, BlockArgumentType::getBlock))
    + .registerType(Block.class, new BlockAdapter(), BlockArgumentType::block)

Release 1.1.7

19 Aug 16:00
Compare
Choose a tag to compare
  • Fixed enum parsing when enum overrides toString
  • Prioritised custom arguments/suggestors over enum check
  • Fixed crashing on startup when the config is corrupted