FMLCommonSetupEvent event isn't triggered when mod is started
Closed this issue ยท 2 comments
The FMLCommonSetupEvent event isn't triggered when the mod is started.
The event handler for the event is the main mod class BasseBombeCraft. The mod class also contains handlers for these events:
- FMLServerAboutToStartEvent
- FMLServerStartedEvent
- FMLServerStoppedEvent
The FMLCommonSetupEvent event is apparently posted on the mod bus (https://suppergerrie2.com/minecraft-1-14-modding-with-forge-3-how-to-use-events/)
The other three events (FMLServerAboutToStartEvent, FMLServerStartedEvent, FMLServerStoppedEvent ) are posted on the forge bus.
The mod is registered with forge event bus using:
MinecraftForge.EVENT_BUS.register(this);
Solution is register the FMLCommonSetupEvent manually in the mod constructor:
FMLJavaModLoadingContext.get().getModEventBus().addListener(this::setup);