Saturn Client provider

This commit is contained in:
2026-03-05 23:51:28 +01:00
parent 9bf04639b3
commit 98d5bf5ce5
@@ -0,0 +1,27 @@
package org.saturnclient.saturnclient.impl;
import java.io.File;
import org.lwjgl.glfw.GLFW;
import org.saturnclient.common.minecraft.MinecraftProvider;
import org.saturnclient.saturnclient.SaturnClient;
import net.minecraft.util.Identifier;
public class SaturnClientProvider extends MinecraftProvider {
@Override
public Object createIdentifier(String namespace, String path) {
return Identifier.of(namespace, path);
}
@Override
public File getRunDirectory() {
return SaturnClient.client.runDirectory;
}
@Override
public boolean isKeyPressed(int key) {
return GLFW.glfwGetKey(SaturnClient.client.getWindow().getHandle(), key) == GLFW.GLFW_PRESS
&& SaturnClient.client.currentScreen == null;
}
}