From 4cdd0e817b34f7af2a3ed078f64361ad43f1b156 Mon Sep 17 00:00:00 2001 From: PlexSheep Date: Wed, 8 Nov 2023 22:49:33 +0100 Subject: [PATCH] text in config --- .../de/cscherr/mcpht/config/MCPHTConfig.java | 22 +++++++----------- src/main/resources/assets/mcpht/icon.png | Bin 453 -> 0 bytes .../resources/assets/mcpht/lang/en_us.json | 5 ++++ src/main/resources/fabric.mod.json | 2 +- {assets/mcpht => src/main/resources}/icon.png | Bin 5 files changed, 14 insertions(+), 15 deletions(-) delete mode 100644 src/main/resources/assets/mcpht/icon.png create mode 100644 src/main/resources/assets/mcpht/lang/en_us.json rename {assets/mcpht => src/main/resources}/icon.png (100%) diff --git a/src/client/java/de/cscherr/mcpht/config/MCPHTConfig.java b/src/client/java/de/cscherr/mcpht/config/MCPHTConfig.java index 35acb41..53b2104 100644 --- a/src/client/java/de/cscherr/mcpht/config/MCPHTConfig.java +++ b/src/client/java/de/cscherr/mcpht/config/MCPHTConfig.java @@ -5,20 +5,14 @@ import me.shedaniel.autoconfig.annotation.Config; import me.shedaniel.autoconfig.annotation.ConfigEntry; import me.shedaniel.cloth.clothconfig.shadowed.blue.endless.jankson.Comment; -@Config(name = "MCPHT Config") +@Config(name = "mcphtconf") public class MCPHTConfig implements ConfigData { - @Comment("Dummy Button") - public NetworkTrafficBarScheme netbar = new NetworkTrafficBarScheme(); - - public static class NetworkTrafficBarScheme { - public enum NetworkTrafficEnum { - None, - All, - Client, - Server, - } - public NetworkTrafficEnum state = NetworkTrafficEnum.None; + @ConfigEntry.Category("Networking") + @ConfigEntry.Gui.CollapsibleObject + @Comment("Foo") + NetworkLoggingScheme networkLogging = new NetworkLoggingScheme(); + static class NetworkLoggingScheme { + boolean RX = false; + boolean TX = false; } - @Comment("How much should network traffic be logged") - public int state = 0; } diff --git a/src/main/resources/assets/mcpht/icon.png b/src/main/resources/assets/mcpht/icon.png deleted file mode 100644 index 047b91f2347de5cf95f23284476fddbe21ba23fe..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 453 zcmV;$0XqJPP)QAFYGys`80vegN0XDFh0OXKz&i8?Le#x7{1X)R+00000NkvXXu0mjf73i~T diff --git a/src/main/resources/assets/mcpht/lang/en_us.json b/src/main/resources/assets/mcpht/lang/en_us.json new file mode 100644 index 0000000..1295472 --- /dev/null +++ b/src/main/resources/assets/mcpht/lang/en_us.json @@ -0,0 +1,5 @@ +{ + "text.autoconfig.mcphtconf.option.networkLogging": "Network Packet Logging", + "text.autoconfig.mcphtconf.option.networkLogging.RX": "RX", + "text.autoconfig.mcphtconf.option.networkLogging.TX": "TX" +} \ No newline at end of file diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index c62ca56..2f4fe36 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -17,7 +17,7 @@ "issues": "https://git.cscherr.de/PlexSheep/mcpht/issues" }, "license": "MIT", - "icon": "assets/mcpht/icon.png", + "icon": "icon.png", "environment": "*", "entrypoints": { "main": ["de.cscherr.mcpht.Mcpht"], diff --git a/assets/mcpht/icon.png b/src/main/resources/icon.png similarity index 100% rename from assets/mcpht/icon.png rename to src/main/resources/icon.png