本文整理汇总了Java中cpw.mods.fml.common.Mod.Init类的典型用法代码示例。如果您正苦于以下问题:Java Init类的具体用法?Java Init怎么用?Java Init使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Init类属于cpw.mods.fml.common.Mod包,在下文中一共展示了Init类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event) {
OilGenerator oilGenerator = OilGenerator.getInstance();
LanguageRegistry.addName(oilGenerator, "Oil Generator");
GameRegistry.registerBlock(oilGenerator, "oilGenerator");
GameRegistry.registerTileEntity(OilGeneratorTileEntity.class,
"oilGenerator");
OilStill oilStill = OilStill.getInstance();
LanguageRegistry.addName(oilStill, "Oil Still");
GameRegistry.registerBlock(oilStill, "oilStill");
OilFlow oilFlow = OilFlow.getInstance();
LanguageRegistry.addName(oilFlow, "Oil Flow");
GameRegistry.registerBlock(oilFlow, "oilFlow");
// liquid world gen stuff
ReplaceWithLiquidWorldGen liquidWorldGen = new ReplaceWithLiquidWorldGen();
ToGenerateLiquid oilGen = new ToGenerateLiquid(55, 60, 1, 5, 16, 5,
OilStill.getInstance().blockID);
liquidWorldGen.add(oilGen, "oil");
}
示例2: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event) {
gameRegistry();
languageRegistry();
setHarvestLevels();
tileEntities();
networkRegisters();
// proxy.registerRenderers();
GameRegistry.registerWorldGenerator(new WorldGeneratorHeroez());
RecipesTabletDecoder.decoding().addSmelting(Block.gravel.blockID,
new ItemStack(Block.cobblestone, 1, 0), 0.7F);
}
示例3: init
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void init(FMLInitializationEvent event) {
log(Level.INFO, "Initializing " + Reference.MOD_ID + " version: " + meta.version);
proxy.registerTileEntities();
proxy.initRenderingAndTextures();
/*
* if (!useUeVoltageSensitivity) {
* UniversalElectricity.isVoltageSensitive = true;
* //EELogger.finest("Successfully toggled Voltage Sensitivity!");
* }
*/
UniversalElectricity.isNetworkActive = true;
DimensionManager.registerProviderType(DimensionIds.TERRA, WorldProviderTerra.class, false);
DimensionManager.registerDimension(DimensionIds.TERRA, DimensionIds.TERRA);
}
示例4: init
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void init(FMLInitializationEvent evt) {
hexbiscus = new BlockHexbiscus(HexxitGearConfig.hexbiscus.getInt());
tribalHelmet = new ItemTribalArmor(HexxitGearConfig.tribalHelmetId.getInt(), proxy.addArmor("tribal"), 0).setUnlocalizedName("hexxitgear.tribal.helmet");
tribalChest = new ItemTribalArmor(HexxitGearConfig.tribalChestId.getInt(), proxy.addArmor("tribal"), 1).setUnlocalizedName("hexxitgear.tribal.chest");
tribalLeggings = new ItemTribalArmor(HexxitGearConfig.tribalLeggingsId.getInt(), proxy.addArmor("tribal"), 2).setUnlocalizedName("hexxitgear.tribal.leggings");
tribalShoes = new ItemTribalArmor(HexxitGearConfig.tribalShoesId.getInt(), proxy.addArmor("tribal"), 3).setUnlocalizedName("hexxitgear.tribal.boots");
scaleHelmet = new ItemScaleArmor(HexxitGearConfig.scaleHelmetId.getInt(), proxy.addArmor("scale"), 0).setUnlocalizedName("hexxitgear.scale.helmet");
scaleChest = new ItemScaleArmor(HexxitGearConfig.scaleChestId.getInt(), proxy.addArmor("scale"), 1).setUnlocalizedName("hexxitgear.scale.chest");
scaleLeggings = new ItemScaleArmor(HexxitGearConfig.scaleLeggingsId.getInt(), proxy.addArmor("scale"), 2).setUnlocalizedName("hexxitgear.scale.leggings");
scaleBoots = new ItemScaleArmor(HexxitGearConfig.scaleBootsId.getInt(), proxy.addArmor("scale"), 3).setUnlocalizedName("hexxitgear.scale.boots");
thiefHelmet = new ItemThiefArmor(HexxitGearConfig.thiefHelmetId.getInt(), proxy.addArmor("thief"), 0).setUnlocalizedName("hexxitgear.thief.helmet");
thiefChest = new ItemThiefArmor(HexxitGearConfig.thiefChestId.getInt(), proxy.addArmor("thief"), 1).setUnlocalizedName("hexxitgear.thief.chest");
thiefLeggings = new ItemThiefArmor(HexxitGearConfig.thiefLeggingsId.getInt(), proxy.addArmor("thief"), 2).setUnlocalizedName("hexxitgear.thief.leggings");
thiefBoots = new ItemThiefArmor(HexxitGearConfig.thiefBootsId.getInt(), proxy.addArmor("thief"), 3).setUnlocalizedName("hexxitgear.thief.boots");
hexicalEssence = new ItemHexicalEssence(HexxitGearConfig.hexicalEssence.getInt());
hexicalDiamond = new ItemHexicalDiamond(HexxitGearConfig.hexicalDiamond.getInt());
GameRegistry.registerBlock(hexbiscus, hexbiscus.getUnlocalizedName());
GameRegistry.registerWorldGenerator(new HGWorldGen());
proxy.init();
}
示例5: Init
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void Init(FMLInitializationEvent e)
{
converterBlockRedPower = new BlockPowerConverterRedPower(blockIdRedPower);
GameRegistry.registerBlock(converterBlockRedPower, ItemBlockPowerConverterRedPower.class, "blockPowerConverterRedPower");
GameRegistry.registerTileEntity(TileEntityRedPowerConsumer.class, "powerConverterRP2Consumer");
GameRegistry.registerTileEntity(TileEntityRedPowerProducer.class, "powerConverterRP2Producer");
LanguageRegistry.addName(new ItemStack(converterBlockRedPower, 1, 0), "RP2 Consumer");
LanguageRegistry.addName(new ItemStack(converterBlockRedPower, 1, 1), "RP2 Producer");
GameRegistry.addRecipe(new ItemStack(converterBlockRedPower, 1, 0),
"G G", "ROR", "G G",
Character.valueOf('G'), Item.ingotGold,
Character.valueOf('R'), Item.redstone,
Character.valueOf('O'), Block.obsidian);
GameRegistry.addShapelessRecipe(new ItemStack(converterBlockRedPower, 1, 1), new ItemStack(converterBlockRedPower, 1, 0));
GameRegistry.addShapelessRecipe(new ItemStack(converterBlockRedPower, 1, 0), new ItemStack(converterBlockRedPower, 1, 1));
proxy.load();
}
示例6: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event) {
//load the keyboard bindings
kbh = ShoulderKeybindings.registerKeybindings();
//create mc pointer
mc = ModLoader.getMinecraftInstance();
//create tick handler
st = new ShoulderTickHandler();
TickRegistry.registerTickHandler(st, Side.CLIENT);
}
示例7: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init // used in 1.5.2
public void load(FMLInitializationEvent event) {
//proxy.registerKeyBindings();
TickRegistry.registerTickHandler(tickHandler, Side.CLIENT);
NetworkRegistry.instance().registerConnectionHandler(new WDLConnectionHandler());
System.err.println("WDL loaded");
instance = this;
}
示例8: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event) {
// GameRegistry.registerPlayerTracker(new PlayerTracker());
TickRegistry.registerTickHandler(new TickHandler(), Side.SERVER);
// MinecraftForge.EVENT_BUS.register(new EventHandler());
logger.info("Loaded.");
}
示例9: initMod
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void initMod(FMLInitializationEvent e){
items = new ItemHandler(config);
blocks = new BlockHandler(config);
crafting = new CraftingHandler();
GameRegistry.registerTileEntity(me.aronth.minetechplus.blocks.tileentitys.TileWorkstation.class, "MineTech:Workstation");
GameRegistry.registerTileEntity(me.aronth.minetechplus.blocks.tileentitys.TileIdeaBuilder.class, "MineTech:IdeaBuilder");
GameRegistry.registerTileEntity(me.aronth.minetechplus.blocks.tileentitys.TileCraftingTable.class, "MineTech:CraftingTable");
GameRegistry.registerTileEntity(me.aronth.minetechplus.blocks.tileentitys.TileDualFurnace.class, "MineTech:DualFurnace");
GameRegistry.registerTileEntity(me.aronth.minetechplus.blocks.tileentitys.TileSuperContainer.class, "MineTech:SuperContainer");
proxy.addNames();
proxy.registerHandlers();
}
示例10: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event) {
NetworkRegistry.instance().registerGuiHandler(instance, proxy);
proxy.registerTileEntities();
proxy.initRenderingAndTextures();
}
示例11: initBooks
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void initBooks(FMLInitializationEvent event) { // Main init method
proxy.registerRenderInformation();
proxy.registerEntities();
proxy.registerItems();
proxy.registerTileEntities(); // Myah
proxy.registerBlocks(); //Calls the registerBlocks method
proxy.addNames(); // Whatever
proxy.addRecipes(); // Etc
NetworkRegistry.instance().registerGuiHandler(this, new GuiHandler()); // Registers the class that deals with GUI data
}
示例12: init
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void init(FMLInitializationEvent evt) {
makeshiftBattery = new BlockMakeshiftBattery(SPSConfig.makeshiftBatteryId.getInt());
if (Loader.isModLoaded("ThermalExpansion")) {
makeshiftConductance = new ItemMakeshiftConductanceCoil(SPSConfig.conductanceCoilId.getInt());
}
makeshiftUpgrade = new ItemMakeshiftUpgrade(SPSConfig.makeshiftUpgradeId.getInt());
GameRegistry.registerBlock(makeshiftBattery, makeshiftBattery.getUnlocalizedName());
GameRegistry.registerTileEntity(TileEntityMakeshiftBattery.class, "entityMSBattery");
NetworkRegistry.instance().registerGuiHandler(this, new GuiHandler());
}
示例13: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@SuppressWarnings("unchecked")
@Init
public void load(FMLInitializationEvent event) {
// Register the GUI Handler
// NetworkRegistry.instance().registerGuiHandler(instance, proxy);
// Initialize mod tile entities
proxy.registerTileEntities();
// Initialize custom rendering and pre-load textures (Client only)
proxy.initRenderingAndTextures();
CraftingManager.getInstance().getRecipeList().add(new RecipesArcPad());
}
示例14: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event){
proxy.registerRenderers();
items = new ItemHandler(config);
blocks = new BlockHandler(config);
crafting = new CraftingHandler();
proxy.addNames();
}
示例15: load
import cpw.mods.fml.common.Mod.Init; //导入依赖的package包/类
@Init
public void load(FMLInitializationEvent event)
{
GameRegistry.registerBlock(lavaBrick, "lavaBrick");
LanguageRegistry.addName(lavaBrick, "Lava Brick");
}