Skip to content

Commit

Permalink
don't run projecte compat datagen when the mod is not present
Browse files Browse the repository at this point in the history
  • Loading branch information
bl4ckscor3 committed Nov 26, 2022
1 parent 4e26ea0 commit 37efaab
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
import net.minecraftforge.common.data.ExistingFileHelper;
import net.minecraftforge.data.event.GatherDataEvent;
import net.minecraftforge.eventbus.api.SubscribeEvent;
import net.minecraftforge.fml.ModList;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber;
import net.minecraftforge.fml.common.Mod.EventBusSubscriber.Bus;

Expand All @@ -23,7 +24,10 @@ public static void onGatherData(GatherDataEvent event) {
generator.addProvider(event.includeServer(), new BlockLootTableGenerator(generator));
generator.addProvider(event.includeServer(), blockTagGenerator);
generator.addProvider(event.includeServer(), new ItemTagGenerator(generator, blockTagGenerator, existingFileHelper));
generator.addProvider(event.includeServer(), new ProjectECompatConversionProvider(generator));

if (ModList.get().isLoaded("projecte"))
generator.addProvider(event.includeServer(), new ProjectECompatConversionProvider(generator));

generator.addProvider(event.includeServer(), new RecipeGenerator(generator));
}
}

0 comments on commit 37efaab

Please sign in to comment.