diff --git a/gradle.properties b/gradle.properties index 2b79c11..8e9eb2d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -3,14 +3,14 @@ org.gradle.jvmargs=-Xmx1G # Fabric Properties # check these on https://fabricmc.net/develop - minecraft_version=1.20.1 - yarn_mappings=1.20.1+build.10 - loader_version=0.14.22 + minecraft_version=1.20.2 + yarn_mappings=1.20.2+build.4 + loader_version=0.14.23 # Mod Properties - mod_version = 1.3.0+1.20.1 + mod_version = 1.4.0+1.20.2 maven_group = com.minenash archives_base_name = rebind-all-the-keys # Dependencies - fabric_version=0.86.1+1.20.1 + fabric_version=0.90.0+1.20.2 diff --git a/src/main/java/com/minenash/rebind_all_the_keys/RebindAllTheKeys.java b/src/main/java/com/minenash/rebind_all_the_keys/RebindAllTheKeys.java index 709fbe3..123ff86 100644 --- a/src/main/java/com/minenash/rebind_all_the_keys/RebindAllTheKeys.java +++ b/src/main/java/com/minenash/rebind_all_the_keys/RebindAllTheKeys.java @@ -45,8 +45,10 @@ public class RebindAllTheKeys implements ClientModInitializer { public static final KeyBinding GAMEMODE_SWITCHER = debugKeybind("gamemode_switcher", -GLFW.GLFW_KEY_F4); public static final KeyBinding INTENTIONAL_CRASH = debugKeybind("intentional_crash", -GLFW.GLFW_KEY_C); - public static final KeyBinding PROFILER = debugKeybind("profiler", -GLFW.GLFW_KEY_LEFT_SHIFT); - public static final KeyBinding TPS = debugKeybind("tps", -GLFW.GLFW_KEY_LEFT_ALT); + public static final KeyBinding DYNAMIC_TEXTURE_DUMP = debugKeybind("dynamic_texture_dump", -GLFW.GLFW_KEY_S); + public static final KeyBinding CHART_PIE = debugKeybind("profiler", -GLFW.GLFW_KEY_1); + public static final KeyBinding CHART_FPS_TPS = debugKeybind("tps_fps", -GLFW.GLFW_KEY_2); + public static final KeyBinding CHART_BANDWIDTH_PING = debugKeybind("bandwidth_ping", -GLFW.GLFW_KEY_3); public static final KeyBinding QUIT_ALIAS = miscKeybind("quit", GLFW.GLFW_KEY_UNKNOWN); public static final KeyBinding TOGGLE_HUD = miscKeybind("toggle_hud", GLFW.GLFW_KEY_F1); @@ -123,6 +125,10 @@ public static void updateDebugKeybinds() { DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(SHOW_DEBUG_BINDINGS).getCode(), GLFW.GLFW_KEY_Q); DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(RELOAD_RESOURCES).getCode(), GLFW.GLFW_KEY_T); DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(GAMEMODE_SWITCHER).getCode(), GLFW.GLFW_KEY_F4); + DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(DYNAMIC_TEXTURE_DUMP).getCode(), GLFW.GLFW_KEY_S); + DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(CHART_PIE).getCode(), GLFW.GLFW_KEY_1); + DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(CHART_FPS_TPS).getCode(), GLFW.GLFW_KEY_2); + DEBUG_REBINDS.put(-KeyBindingHelper.getBoundKeyOf(CHART_BANDWIDTH_PING).getCode(), GLFW.GLFW_KEY_3); if (gamemodeSwitcherSelectText != null) updateGamemodeSwitcherSelectText(); diff --git a/src/main/java/com/minenash/rebind_all_the_keys/mixin/KeyboardMixin.java b/src/main/java/com/minenash/rebind_all_the_keys/mixin/KeyboardMixin.java index d50b7ae..8dd3ea5 100644 --- a/src/main/java/com/minenash/rebind_all_the_keys/mixin/KeyboardMixin.java +++ b/src/main/java/com/minenash/rebind_all_the_keys/mixin/KeyboardMixin.java @@ -83,16 +83,7 @@ public void showActualIntentionalCrashKeybind(Keyboard keyboard, String key, Obj .append(" ").append(I18n.translate(key).replace("F3 + C", RebindAllTheKeys.getDebugKeybindString(INTENTIONAL_CRASH)))); } - @Redirect(method = "onKey", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/screen/Screen;hasShiftDown()Z")) - public boolean remapProfilerModifier() { - return InputUtil.isKeyPressed(MinecraftClient.getInstance().getWindow().getHandle(), RebindAllTheKeys.getKeyCode(PROFILER)); - } - - @Redirect(method = "onKey", at = @At(value = "INVOKE", target = "Lnet/minecraft/client/gui/screen/Screen;hasAltDown()Z")) - public boolean remapTpsModifier() { - return InputUtil.isKeyPressed(MinecraftClient.getInstance().getWindow().getHandle(), RebindAllTheKeys.getKeyCode(RebindAllTheKeys.TPS)); - } - + //TODO: Update @Inject(method = "processF3", at = @At("HEAD"), cancellable = true) public void showDebugKeybinds(int key, CallbackInfoReturnable info) { if (key != 81) diff --git a/src/main/resources/assets/rebind_all_the_keys/lang/en_us.json b/src/main/resources/assets/rebind_all_the_keys/lang/en_us.json index ae19b1e..74f24c7 100644 --- a/src/main/resources/assets/rebind_all_the_keys/lang/en_us.json +++ b/src/main/resources/assets/rebind_all_the_keys/lang/en_us.json @@ -18,6 +18,7 @@ "rebind_all_the_keys.keybind.gamemode_switcher" : "Gamemode Switcher", "rebind_all_the_keys.keybind.intentional_crash" : "Intentional Crash", "rebind_all_the_keys.keybind.intentional_crash.button.held" : " (held)", + "rebind_all_the_keys.keybind.dynamic_texture_dump" : "Dynamic Texture Dump", "rebind_all_the_keys.keybind.toggle_narrator_override" : "Toggle Narrator (Override)", "rebind_all_the_keys.keybind.toggle_hud" : "Toggle Hud", "rebind_all_the_keys.keybind.toggle_auto_jump" : "Toggle Auto Jump", @@ -29,8 +30,9 @@ "rebind_all_the_keys.keybind.quick_move" : "Quick Move", "rebind_all_the_keys.keybind.drop_stack_modifier" : "Drop Stack Modifier", "rebind_all_the_keys.keybind.quit" : "Quit/Close Menu (ESC still work)", - "rebind_all_the_keys.keybind.profiler" : "Profiler", - "rebind_all_the_keys.keybind.tps" : "TPS Graph", + "rebind_all_the_keys.keybind.profiler" : "Graph: Profiler", + "rebind_all_the_keys.keybind.tps_fps" : "Graph: FPS & TPS", + "rebind_all_the_keys.keybind.bandwidth_ping" : "Graph: Bandwidth & Ping", "rebind_all_the_keys.controls.cmdToCtrl": "Cmd → Ctrl", "rebind_all_the_keys.controls.doubleTapSprint": "Double Tap Sprint" diff --git a/src/main/resources/assets/rebind_all_the_keys/lang/fr_fr.json b/src/main/resources/assets/rebind_all_the_keys/lang/fr_fr.json index f72e9da..a52c345 100644 --- a/src/main/resources/assets/rebind_all_the_keys/lang/fr_fr.json +++ b/src/main/resources/assets/rebind_all_the_keys/lang/fr_fr.json @@ -18,6 +18,7 @@ "rebind_all_the_keys.keybind.gamemode_switcher" : "Sélecteur de mode de jeu", "rebind_all_the_keys.keybind.intentional_crash" : "Crash intentionnel", "rebind_all_the_keys.keybind.intentional_crash.button.held" : " (maintenu)", + "rebind_all_the_keys.keybind.dynamic_texture_dump" : "Vidage de texture dynamique", "rebind_all_the_keys.keybind.toggle_narrator_override" : "Activer/désactiver le narrateur (Remplacement)", "rebind_all_the_keys.keybind.toggle_hud" : "Activer/désactiver l'HUD", "rebind_all_the_keys.keybind.toggle_auto_jump" : "Activer/désactiver le saut automatique", @@ -28,8 +29,9 @@ "rebind_all_the_keys.keybind.hotbar_previous_override" : "Barre d'actions précédente (Remplacement)", "rebind_all_the_keys.keybind.quick_move" : "Déplacement rapide", "rebind_all_the_keys.keybind.quit" : "Quitter/Fermer le menu (ESC fonctionne toujours)", - "rebind_all_the_keys.keybind.profiler" : "Profil", - "rebind_all_the_keys.keybind.tps" : "Graphique TPS", + "rebind_all_the_keys.keybind.profiler" : "Graphique du Profil", + "rebind_all_the_keys.keybind.tps_fps" : "Graphique TPS et FPS", + "rebind_all_the_keys.keybind.bandwidth_ping" : "Graphiques de bande passante et de ping", "rebind_all_the_keys.controls.cmdToCtrl": "Cmd → Ctrl", "rebind_all_the_keys.controls.doubleTapSprint": "Sprint à double-tap"