Search in sources :

Example 26 with EventHandler

use of net.minecraftforge.fml.common.Mod.EventHandler in project Witchworks by Um-Mitternacht.

the class WitchWorks method start.

@EventHandler
public void start(FMLServerStartingEvent event) {
    ModCommands.init();
    event.registerServerCommand(new CommandIncantation());
}
Also used : CommandIncantation(com.witchworks.common.core.command.CommandIncantation) EventHandler(net.minecraftforge.fml.common.Mod.EventHandler)

Example 27 with EventHandler

use of net.minecraftforge.fml.common.Mod.EventHandler in project Valkyrien-Warfare-Revamped by ValkyrienWarfare.

the class ValkyrienWarfareMod method serverStart.

@EventHandler
public void serverStart(FMLServerStartingEvent event) {
    MinecraftServer server = event.getServer();
    ModCommands.registerCommands(server);
}
Also used : MinecraftServer(net.minecraft.server.MinecraftServer) EventHandler(net.minecraftforge.fml.common.Mod.EventHandler)

Example 28 with EventHandler

use of net.minecraftforge.fml.common.Mod.EventHandler in project Valkyrien-Warfare-Revamped by ValkyrienWarfare.

the class ValkyrienWarfareWorldMod method init.

@EventHandler
public void init(FMLInitializationEvent event) {
    EntityRegistry.registerModEntity(EntityFallingUpBlock.class, "FallingUpBlockEntity", 75, this, 80, 1, true);
    MinecraftForge.EVENT_BUS.register(worldEventsCommon);
    proxy.init(event);
    GameRegistry.registerWorldGenerator(new ValkyrienWarfareWorldGen(), 1);
}
Also used : ValkyrienWarfareWorldGen(ValkyrienWarfareWorld.WorldGen.ValkyrienWarfareWorldGen) EventHandler(net.minecraftforge.fml.common.Mod.EventHandler)

Example 29 with EventHandler

use of net.minecraftforge.fml.common.Mod.EventHandler in project SecurityCraft by Geforce132.

the class SecurityCraft method init.

@EventHandler
public void init(FMLInitializationEvent event) {
    log("Setting up inter-mod stuff...");
    FMLInterModComms.sendMessage("Waila", "register", "net.geforcemods.securitycraft.imc.waila.WailaDataProvider.callbackRegister");
    if (config.checkForUpdates) {
        NBTTagCompound vcUpdateTag = VersionUpdateChecker.getNBTTagCompound();
        if (vcUpdateTag != null)
            FMLInterModComms.sendRuntimeMessage(MODID, "VersionChecker", "addUpdate", vcUpdateTag);
    }
    log("Registering mod content... (PT 2/2)");
    SecurityCraft.serverProxy.registerResourceLocations();
    NetworkRegistry.INSTANCE.registerGuiHandler(this, guiHandler);
    RegistrationHandler.registerEntities();
    EnumCustomModules.refresh();
    serverProxy.registerRenderThings();
}
Also used : NBTTagCompound(net.minecraft.nbt.NBTTagCompound) EventHandler(net.minecraftforge.fml.common.Mod.EventHandler)

Example 30 with EventHandler

use of net.minecraftforge.fml.common.Mod.EventHandler in project SecurityCraft by Geforce132.

the class SecurityCraft method serverStarting.

@EventHandler
public void serverStarting(FMLServerStartingEvent event) {
    event.registerServerCommand(new CommandSC());
    event.registerServerCommand(new CommandModule());
}
Also used : CommandModule(net.geforcemods.securitycraft.commands.CommandModule) CommandSC(net.geforcemods.securitycraft.commands.CommandSC) EventHandler(net.minecraftforge.fml.common.Mod.EventHandler)

Aggregations

EventHandler (net.minecraftforge.fml.common.Mod.EventHandler)33 ItemStack (net.minecraft.item.ItemStack)5 Configuration (net.minecraftforge.common.config.Configuration)5 File (java.io.File)3 ForgeEventHandler (net.geforcemods.securitycraft.handlers.ForgeEventHandler)3 BookshelfEvents (net.darkhax.bookshelf.BookshelfEvents)2 ChestBuilder (net.darkhax.bookshelf.builder.ChestBuilder)2 RegistryHelper (net.darkhax.bookshelf.registry.RegistryHelper)2 TeleportEventHandler (net.dyeo.teleporter.event.TeleportEventHandler)2 CommandModule (net.geforcemods.securitycraft.commands.CommandModule)2 CommandSC (net.geforcemods.securitycraft.commands.CommandSC)2 Block (net.minecraft.block.Block)2 ItemBlock (net.minecraft.item.ItemBlock)2 NBTTagCompound (net.minecraft.nbt.NBTTagCompound)2 ModMetadata (net.minecraftforge.fml.common.ModMetadata)2 WorldTypeMessageEventHandler (rtg.event.WorldTypeMessageEventHandler)2 ControlGUIHandler (ValkyrienWarfareControl.GUI.ControlGUIHandler)1 ValkyrienWarfareWorldGen (ValkyrienWarfareWorld.WorldGen.ValkyrienWarfareWorldGen)1 GuiHandler (betterwithaddons.client.GuiHandler)1 ModConfiguration (betterwithaddons.config.ModConfiguration)1