top.hendrixshen.magiclib.compat.modmenu.ModMenuCompatApi Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of magiclib-1_14_4 Show documentation
Show all versions of magiclib-1_14_4 Show documentation
To beat magic with magic :(
package top.hendrixshen.magiclib.compat.modmenu;
import io.github.prospector.modmenu.api.ModMenuApi;
//#if MC > 11404
//$$ import io.github.prospector.modmenu.api.ConfigScreenFactory;
//#else
import java.util.function.Function;
//#endif
import net.minecraft.class_437;
public interface ModMenuCompatApi extends ModMenuApi {
ConfigScreenFactoryCompat> getConfigScreenFactoryCompat();
String getModIdCompat();
@Override
//#if MC > 11404
//$$ default ConfigScreenFactory> getModConfigScreenFactory() {
//#else
default Function getConfigScreenFactory() {
//#endif
return (screen) -> this.getConfigScreenFactoryCompat().create(screen);
}
//#if MC <= 11404
@Override
default String getModId() {
return this.getModIdCompat();
}
//#endif
@FunctionalInterface
interface ConfigScreenFactoryCompat {
S create(class_437 screen);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy