diff --git a/legacy-fabric-item-api-v1/1.12.2/src/main/java/net/legacyfabric/fabric/impl/item/versioned/EarlyInitializer.java b/legacy-fabric-item-api-v1/1.12.2/src/main/java/net/legacyfabric/fabric/impl/item/versioned/EarlyInitializer.java index 17d33b408..0f6105ee8 100644 --- a/legacy-fabric-item-api-v1/1.12.2/src/main/java/net/legacyfabric/fabric/impl/item/versioned/EarlyInitializer.java +++ b/legacy-fabric-item-api-v1/1.12.2/src/main/java/net/legacyfabric/fabric/impl/item/versioned/EarlyInitializer.java @@ -17,6 +17,9 @@ package net.legacyfabric.fabric.impl.item.versioned; +import net.fabricmc.api.EnvType; +import net.fabricmc.loader.api.FabricLoader; + import net.minecraft.item.Item; import net.fabricmc.loader.api.entrypoint.PreLaunchEntrypoint; @@ -35,6 +38,6 @@ public void onPreLaunch() { private static void itemRegistryInit(Registry holder) { SyncedRegistry registry = (SyncedRegistry) holder; - registry.fabric$getRegistryRemapCallback().register(new ItemModelsRemapper()); + if (FabricLoader.getInstance().getEnvironmentType() == EnvType.CLIENT) registry.fabric$getRegistryRemapCallback().register(new ItemModelsRemapper()); } }