Search in sources :

Example 1 with BPEventHandler

use of com.bluepowermod.event.BPEventHandler in project BluePower by Qmunity.

the class BluePower method preInit.

@EventHandler
public void preInit(FMLPreInitializationEvent event) {
    event.getModMetadata().version = Refs.fullVersionString();
    log = event.getModLog();
    config = new Configuration(event.getSuggestedConfigurationFile());
    BPApi.init(new BluePowerAPI());
    // Load configs
    Config.syncConfig(config);
    BPEnchantments.init();
    CompatibilityUtils.preInit(event);
    FMLCommonHandler.instance().bus().register(new Config());
    BPEventHandler eventHandler = new BPEventHandler();
    MinecraftForge.EVENT_BUS.register(eventHandler);
    FMLCommonHandler.instance().bus().register(eventHandler);
    MinecraftForge.EVENT_BUS.register(new WorldConversionEventHandler());
    RedstoneApi.getInstance().registerRedstoneProvider(new RedstoneProviderQmunityLib());
}
Also used : Configuration(net.minecraftforge.common.config.Configuration) Config(com.bluepowermod.init.Config) BPEventHandler(com.bluepowermod.event.BPEventHandler) WorldConversionEventHandler(com.bluepowermod.convert.WorldConversionEventHandler) RedstoneProviderQmunityLib(com.bluepowermod.redstone.RedstoneProviderQmunityLib) BPEventHandler(com.bluepowermod.event.BPEventHandler) WorldConversionEventHandler(com.bluepowermod.convert.WorldConversionEventHandler) EventHandler(cpw.mods.fml.common.Mod.EventHandler)

Aggregations

WorldConversionEventHandler (com.bluepowermod.convert.WorldConversionEventHandler)1 BPEventHandler (com.bluepowermod.event.BPEventHandler)1 Config (com.bluepowermod.init.Config)1 RedstoneProviderQmunityLib (com.bluepowermod.redstone.RedstoneProviderQmunityLib)1 EventHandler (cpw.mods.fml.common.Mod.EventHandler)1 Configuration (net.minecraftforge.common.config.Configuration)1