Skip to content

Commit

Permalink
fix server incompatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
TexBlock committed Jun 13, 2023
1 parent b701561 commit a83e185
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
6 changes: 3 additions & 3 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ loom.platform=forge
yarn_mappings=1.19.4+build.1

# Mod Properties
mod_version=0.1.1
mod_version=0.1.2
maven_group=fi.dy.masa
archives_base_name=bocchud
archives_base_name=BoccHUD
mod_id=minihud
mod_author=ThinkingStudio

# Dependencies
malilib_version=0.1.5-mc1.19.4
malilib_version=0.1.7-mc1.19.4
10 changes: 10 additions & 0 deletions src/main/java/fi/dy/masa/minihud/MiniHUD.java
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@

import fi.dy.masa.malilib.compat.forge.ForgePlatformCompat;
import fi.dy.masa.minihud.gui.GuiConfigs;
import net.minecraftforge.eventbus.api.IEventBus;
import net.minecraftforge.fml.common.Mod;
import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
import net.minecraftforge.fml.javafmlmod.FMLJavaModLoadingContext;
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import fi.dy.masa.malilib.event.InitializationHandler;
Expand All @@ -14,6 +17,13 @@ public class MiniHUD {
public static final String CHANNEL_CARPET_CLIENT = "CarpetClient";

public MiniHUD() {
IEventBus modEventBus = FMLJavaModLoadingContext.get().getModEventBus();

modEventBus.addListener(this::onInitializeClient);
}

public void onInitializeClient(FMLClientSetupEvent event) {
ForgePlatformCompat.getInstance().getModClientExtensionPoint();
InitializationHandler.getInstance().registerInitializationHandler(new InitHandler());

ForgePlatformCompat.getInstance().getMod(Reference.MOD_ID).registerModConfigScreen((screen) -> {
Expand Down

0 comments on commit a83e185

Please sign in to comment.