diff --git a/gradle.properties b/gradle.properties index 9c24649..67d5066 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,7 +7,7 @@ org.gradle.jvmargs=-Xmx3G loader_version=0.12.12 # Mod Properties - mod_version = 1.4.2 + mod_version = 1.4.3 maven_group = obro1961 archives_base_name = wmch # Dependencies diff --git a/src/main/java/obro1961/config/ClothConfig.java b/src/main/java/obro1961/config/ClothConfig.java index 400415d..33ea0c1 100644 --- a/src/main/java/obro1961/config/ClothConfig.java +++ b/src/main/java/obro1961/config/ClothConfig.java @@ -29,12 +29,12 @@ protected ClothConfig(boolean timeEnabled, String timeString, Formatting[] timeF * @return A new config Screen for player access */ public Screen getWMCHConfigScreen(Screen prevScreen) { - ConfigBuilder bldr = ConfigBuilder.create().setParentScreen(prevScreen).setDoesConfirmSave(true).setTitle(new TranslatableText("wmch.config.title")); + ConfigBuilder bldr = ConfigBuilder.create().setParentScreen(prevScreen).setDoesConfirmSave(true).setTitle(new TranslatableText("text.wmch.title")); ConfigEntryBuilder iBldr = bldr.entryBuilder(); - ConfigCategory time = bldr.getOrCreateCategory(new TranslatableText("wmch.config.time_category")); - ConfigCategory hover = bldr.getOrCreateCategory(new TranslatableText("wmch.config.hover_category")); - ConfigCategory boundary = bldr.getOrCreateCategory(new TranslatableText("wmch.config.boundary_category")); - ConfigCategory other = bldr.getOrCreateCategory(new TranslatableText("wmch.config.other_category")); + ConfigCategory time = bldr.getOrCreateCategory(new TranslatableText("text.wmch.time_category")); + ConfigCategory hover = bldr.getOrCreateCategory(new TranslatableText("text.wmch.hover_category")); + ConfigCategory boundary = bldr.getOrCreateCategory(new TranslatableText("text.wmch.boundary_category")); + ConfigCategory other = bldr.getOrCreateCategory(new TranslatableText("text.wmch.other_category")); iBldr = quickStart("time", cfg.time, iBldr, time, null, current -> { cfg.time = (boolean)WMCH.or(current, cfg.time_enabled, TIME); @@ -84,9 +84,9 @@ public Screen getWMCHConfigScreen(Screen prevScreen) { cfg.boundaryFormatting = (Formatting[])WMCH.or(bFmts.toArray(EMPTY), cfg.boundary_formatting, BOUNDARYFORMATTING); }); - other.addEntry( iBldr.startIntField(new TranslatableText("wmch.config.maxMsgs"), cfg.maxMsgs) + other.addEntry( iBldr.startIntField(new TranslatableText("text.wmch.maxMsgs"), cfg.maxMsgs) .setDefaultValue(maxMsgs) - .setTooltip(new TranslatableText("wmch.config.maxMsgs_desc")) + .setTooltip(new TranslatableText("text.wmch.maxMsgs_desc")) .setSaveConsumer(current -> { cfg.maxMsgs = current>100 && current<16835 ? current : cfg.maxMsgs>100 && cfg.maxMsgs<16835 ? cfg.maxMsgs : MAXMSGS; }) .build() ); quickStart("reset", cfg.reset, iBldr, other, null, current -> { if(current) reset(); cfg.reset = false; }, null); @@ -99,7 +99,7 @@ public Screen getWMCHConfigScreen(Screen prevScreen) { } private static ConfigEntryBuilder quickStart(String key, Object def, ConfigEntryBuilder iBldr, ConfigCategory category, Consumer saveStr, Consumer saveBool, Consumer> saveList) { - TranslatableText[] texts = {new TranslatableText("wmch.config."+key), new TranslatableText("wmch.config."+key+"_desc")}; + TranslatableText[] texts = {new TranslatableText("text.wmch."+key), new TranslatableText("text.wmch."+key+"_desc")}; switch (def.getClass().getName()) { case "java.lang.String": category.addEntry( diff --git a/src/main/java/obro1961/mixins/ChatHudMixin.java b/src/main/java/obro1961/mixins/ChatHudMixin.java index 5f92b54..9b896f7 100644 --- a/src/main/java/obro1961/mixins/ChatHudMixin.java +++ b/src/main/java/obro1961/mixins/ChatHudMixin.java @@ -60,7 +60,7 @@ public Text addTimestamp(Text m) { .withClickEvent( WMCH.config.hover ? new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, WMCH.config.getFormattedHover(now) ) : null ) ) ) - .append(!isBoundary&&WMCH.config.time ? Text.of("") : new LiteralText(" ").setStyle(m.getStyle())) + .append(isBoundary||!WMCH.config.time ? Text.of("") : new LiteralText(" ").setStyle(m.getStyle())) .append(m); } } \ No newline at end of file diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index 943d60b..cefbea9 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -1,7 +1,7 @@ { "schemaVersion": 1, "id": "wmch", - "version": "1.4.2", + "version": "1.4.3", "name": "Where's My Chat History", "description": "Currently:\n- Keeps chat history when you leave a server\n- increases the amount of maximum chat messages depending on allocated RAM\n- adds a timestamp before each message.\nTo access the config, either modify wmch.json in the config folder or install Mod Menu(v3.0.1+) and Cloth Config(6.1.48+) to edit the options in-game\nHeavily inspired by ryanbester and JackFred2's original mods.\n\nFor any technical users, this mod's only mixins are in the ChatHud.class and Keyboard.class; all problems most likely stemmed from conflict there.",