HudEditor moved to common

This commit is contained in:
2026-03-07 16:00:51 +01:00
parent 5b8ce8f048
commit 4d7a79f517
12 changed files with 635 additions and 9 deletions
@@ -7,6 +7,7 @@ import net.minecraft.client.util.InputUtil;
import org.saturnclient.saturnclient.SaturnClient;
import org.saturnclient.saturnclient.client.ServiceClient;
import org.saturnclient.common.minecraft.MinecraftProvider;
import org.saturnclient.config.Config;
import org.saturnclient.ui.screens.EmoteWheel;
import org.saturnclient.ui.screens.ShiftMenu;
@@ -36,12 +37,12 @@ public class KeyInputHandler {
// Register the event handler for the main menu key
ClientTickEvents.END_CLIENT_TICK.register(client -> {
if (mainMenuKeyBinding.wasPressed()) {
client.setScreen(new ShiftMenu());
MinecraftProvider.PROVIDER.setScreen(new ShiftMenu());
}
if (Config.openEmoteWheel.wasKeyPressed() && client.currentScreen == null
&& !InputUtil.isKeyPressed(client.getWindow().getHandle(), GLFW.GLFW_KEY_F3)) {
client.setScreen(new EmoteWheel());
MinecraftProvider.PROVIDER.setScreen(new EmoteWheel());
}
if (SaturnClient.client.player != null && SaturnClient.client.player.isSneaking()) {
@@ -128,6 +128,7 @@ public abstract class SaturnScreenFabric extends Screen implements ScreenProvide
@Override
public void close() {
this.screen.onClose();
super.close();
}
}