Code style changes, entities fixes

This commit is contained in:
paulevsGitch 2021-07-08 00:21:47 +03:00
parent 9d604b2d25
commit 44962e18b6
377 changed files with 5038 additions and 4914 deletions

View file

@ -18,35 +18,35 @@ public class Integrations {
public static final ModIntegration BYG = ModIntegrationAPI.register(new BYGIntegration());
public static final ModIntegration NOURISH = ModIntegrationAPI.register(new NourishIntegration());
public static final ModIntegration FLAMBOYANT_REFABRICATED = ModIntegrationAPI.register(new FlamboyantRefabricatedIntegration());
private static boolean hasHydrogen;
public static void init() {
if (hasGuideBook()) {
GuideBookItem.register();
PlayerAdvancementsCallback.PLAYER_ADVANCEMENT_COMPLETE.register((player, advancement, criterionName) -> {
ResourceLocation advId = new ResourceLocation("minecraft:end/enter_end_gateway");
if (advId.equals(advancement.getId())) {
player.addItem(new ItemStack(GuideBookItem.GUIDE_BOOK));
}
});
GridRecipe.make(BetterEnd.MOD_ID, "guide_book", GuideBookItem.GUIDE_BOOK)
.checkConfig(Configs.RECIPE_CONFIG)
.setShape("D", "B", "C")
.addMaterial('D', EndItems.ENDER_DUST)
.addMaterial('B', Items.BOOK)
.addMaterial('C', EndItems.CRYSTAL_SHARDS)
.build();
.checkConfig(Configs.RECIPE_CONFIG)
.setShape("D", "B", "C")
.addMaterial('D', EndItems.ENDER_DUST)
.addMaterial('B', Items.BOOK)
.addMaterial('C', EndItems.CRYSTAL_SHARDS)
.build();
}
hasHydrogen = FabricLoader.getInstance().isModLoaded("hydrogen");
}
public static boolean hasGuideBook() {
return FabricLoader.getInstance().isModLoaded("patchouli");
}
public static boolean hasHydrogen() {
return hasHydrogen;
}