Do client only setup with this event, such as KeyBindings.
Do client only setup with this event, such as KeyBindings. Do client only setup with this event, such as KeyBindings. Do client only setup with this event, such as KeyBindings. Do client only setup with this event, such as KeyBindings. Achieved with Froge.
This commit is contained in:
parent
1b5592df4f
commit
e6caaf68ec
@ -6,7 +6,9 @@ import net.minecraft.world.entity.Entity;
|
||||
import net.minecraft.world.item.CreativeModeTab;
|
||||
import net.minecraft.world.item.ItemStack;
|
||||
import net.minecraft.world.level.block.entity.BlockEntity;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.eventbus.api.EventPriority;
|
||||
import net.minecraftforge.fml.DistExecutor;
|
||||
import net.minecraftforge.fml.ModList;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.event.lifecycle.FMLClientSetupEvent;
|
||||
@ -90,6 +92,10 @@ public final class OverdriveThatMatters {
|
||||
modBus.addListener(EventPriority.NORMAL, this::setupClient);
|
||||
modBus.addListener(EventPriority.NORMAL, MatteryCapability::register);
|
||||
|
||||
DistExecutor.unsafeRunWhenOn(Dist.CLIENT, () -> () -> {
|
||||
modBus.addListener(EventPriority.NORMAL, AndroidMenuKeyMapping.INSTANCE::register);
|
||||
});
|
||||
|
||||
ClientConfig.INSTANCE.register();
|
||||
ServerConfig.INSTANCE.register();
|
||||
}
|
||||
@ -166,7 +172,6 @@ public final class OverdriveThatMatters {
|
||||
EVENT_BUS.addListener(EventPriority.NORMAL, TooltipsKt::tooltipEvent);
|
||||
}
|
||||
|
||||
FMLJavaModLoadingContext.get().getModEventBus().addListener(EventPriority.NORMAL, AndroidMenuKeyMapping.INSTANCE::register);
|
||||
EVENT_BUS.addListener(EventPriority.NORMAL, AndroidMenuKeyMapping.INSTANCE::onRenderGuiEvent);
|
||||
|
||||
event.enqueueWork(GlobalEventHandlerKt::recordClientThread);
|
||||
|
Loading…
Reference in New Issue
Block a user