diff --git a/src/main/java/com/viaversion/fabric/common/ViaFabric.java b/src/main/java/com/viaversion/fabric/common/ViaFabric.java new file mode 100644 index 0000000..504ca62 --- /dev/null +++ b/src/main/java/com/viaversion/fabric/common/ViaFabric.java @@ -0,0 +1,15 @@ +package com.viaversion.fabric.common; + +import net.fabricmc.api.ModInitializer; +import net.fabricmc.loader.api.FabricLoader; + +public class ViaFabric implements ModInitializer { + @Override + public void onInitialize() { + if (FabricLoader.getInstance().getAllMods() + .stream() + .noneMatch(it -> it.getMetadata().getId().startsWith("viafabric-mc"))) { + System.out.println("ViaFabric didn't load correctly... Are dependencies installed?"); + } + } +} diff --git a/src/main/resources/fabric.mod.json b/src/main/resources/fabric.mod.json index c734c5d..50d5341 100644 --- a/src/main/resources/fabric.mod.json +++ b/src/main/resources/fabric.mod.json @@ -25,6 +25,11 @@ } } ], + "entrypoints": { + "main": [ + "com.viaversion.fabric.common.ViaFabric" + ] + }, "contributors": [ { "name": "GitHub contributors",