当前位置: 首页>>代码示例>>Java>>正文


Java ItemList类代码示例

本文整理汇总了Java中codechicken.nei.ItemList的典型用法代码示例。如果您正苦于以下问题:Java ItemList类的具体用法?Java ItemList怎么用?Java ItemList使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ItemList类属于codechicken.nei包,在下文中一共展示了ItemList类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels()
{
    IngotCompressorRecipeHandler.afuels = new ArrayList<FuelPair>();
    for (ItemStack item : ItemList.items)
    {
        if (!IngotCompressorRecipeHandler.efuels.contains(Item.getIdFromItem(item.getItem())))
        {
            int burnTime = TileEntityFurnace.getItemBurnTime(item);
            if (burnTime > 0)
            {
                FuelPair fuelPair = new FuelPair(item.copy(), burnTime);
                fuelPair.stack.relx = 57;
                fuelPair.stack.rely = 83;
                IngotCompressorRecipeHandler.afuels.add(fuelPair);
            }
        }
    }
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:19,代码来源:IngotCompressorRecipeHandler.java

示例2: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels()
{
	afuels = new ArrayList<>();
	Set<Item> efuels = excludedFuels();

	for (ItemStack item : ItemList.items)
	{
		Block block = Block.getBlockFromItem(item.getItem());
		if (block instanceof BlockDoor)
		{
			continue;
		}

		if (efuels.contains(item.getItem()))
		{
			continue;
		}

		int burnTime = TileEntityBrickOven.getItemBurnTime(item);
		if (burnTime > 0)
		{
			afuels.add(new FuelPair(item.copy(), burnTime));
		}
	}
}
 
开发者ID:einsteinsci,项目名称:betterbeginnings-MC1.7,代码行数:26,代码来源:NEIBrickOvenRecipeHandler.java

示例3: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels()
{
	afuels = new ArrayList<>();
	Set<Item> efuels = excludedFuels();

	for (ItemStack item : ItemList.items)
	{
		Block block = Block.getBlockFromItem(item.getItem());
		if (block instanceof BlockDoor)
		{
			continue;
		}

		if (efuels.contains(item.getItem()))
		{
			continue;
		}

		int burnTime = TileEntitySmelter.getItemBurnTime(item);
		if (burnTime > 0)
		{
			afuels.add(new FurnaceRecipeHandler.FuelPair(item.copy(), burnTime));
		}
	}
}
 
开发者ID:einsteinsci,项目名称:betterbeginnings-MC1.7,代码行数:26,代码来源:NEISmelterRecipeHandler.java

示例4: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels()
{
	afuels = new ArrayList<>();
	Set<Item> efuels = excludedFuels();

	for (ItemStack item : ItemList.items)
	{
		Block block = Block.getBlockFromItem(item.getItem());
		if (block instanceof BlockDoor)
		{
			continue;
		}

		if (efuels.contains(item.getItem()))
		{
			continue;
		}

		int burnTime = TileEntityKiln.getItemBurnTime(item);
		if (burnTime > 0)
		{
			afuels.add(new FurnaceRecipeHandler.FuelPair(item.copy(), burnTime));
		}
	}
}
 
开发者ID:einsteinsci,项目名称:betterbeginnings-MC1.7,代码行数:26,代码来源:NEIKilnRecipeHandler.java

示例5: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels()
{
	afuels = new ArrayList<>();
	Set<Item> efuels = excludedFuels();

	for (ItemStack item : ItemList.items)
	{
		Block block = Block.getBlockFromItem(item.getItem());
		if (block instanceof BlockDoor)
		{
			continue;
		}

		if (efuels.contains(item.getItem()))
		{
			continue;
		}

		int burnTime = TileEntityCampfire.getBurnTimeForFuel(item);
		if (burnTime > 0)
		{
			afuels.add(new FuelPair(item.copy(), burnTime));
		}
	}
}
 
开发者ID:einsteinsci,项目名称:betterbeginnings-MC1.7,代码行数:26,代码来源:NEICampfireRecipeHandler.java

示例6: drawScreen

import codechicken.nei.ItemList; //导入依赖的package包/类
@Override
public void drawScreen(int x, int y, float f) {
	scroll -= 10;
	int rx = scroll, ry = mc.displayWidth / 2 - 180;

	for (int j = 0; j < 2; j++) {
		for (int i = 0; i < ItemList.items.size(); i++) {
			ItemStack block = ItemList.items.get(i);
			if (block != null) {
				ry += 20;
				//if (i % 2 == 0) {
				rx += 200;
				ry = mc.displayWidth / 2 - 180;
				// }

				renderBlockIntoGui(block, rx, ry, 10F, Minecraft.getMinecraft().fontRenderer, Minecraft.getMinecraft());


			}
		}
	}


}
 
开发者ID:modmuss50,项目名称:Network,代码行数:25,代码来源:GuiItemList.java

示例7: onPostInit

import codechicken.nei.ItemList; //导入依赖的package包/类
@EventHandler
public void onPostInit(FMLPostInitializationEvent event) {
	// Load NEI item list and wait until it's loaded
	ItemList.loadItems.restart();
	while (ReflectionHelper.getPrivateValue(RestartableTask.class, ItemList.loadItems, "thread") != null) {
		try {
			Thread.sleep(1);
		} catch (InterruptedException e) {
		} // Don't stress the CPU too much
	}
	neiConfig.init();
}
 
开发者ID:CraftedMods,项目名称:nei-lotr,代码行数:13,代码来源:NeiLotr.java

示例8: getSawList

import codechicken.nei.ItemList; //导入依赖的package包/类
public static HashSet<ItemStack> getSawList() {
    if (FMPMicroBlocksHandler.sawList == null) {
        FMPMicroBlocksHandler.sawList = new HashSet<ItemStack>();
        synchronized (ItemList.class) {
            for (final Item item : ItemList.itemMap.keySet()) {
                if (item instanceof Saw) {
                    for (final ItemStack stack : ItemList.itemMap.get(item)) {
                        FMPMicroBlocksHandler.sawList.add(stack);
                    }
                }
            }
        }
    }
    return FMPMicroBlocksHandler.sawList;
}
 
开发者ID:sameer,项目名称:ExtraUtilities,代码行数:16,代码来源:FMPMicroBlocksHandler.java

示例9: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels() {
    afuels = new ArrayList<FuelPair>();
    Set<Item> efuels = excludedFuels();
    for (ItemStack item : ItemList.items)
        if (!efuels.contains(item.getItem())) {
            int burnTime = TileEntityFurnace.getItemBurnTime(item);
            if (burnTime > 0)
                afuels.add(new FuelPair(item.copy(), burnTime));
        }
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:11,代码来源:FurnaceRecipeHandler.java

示例10: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels() {
    afuels = new ArrayList<FuelPair>();
    Set<Item> efuels = excludedFuels();
    for (ItemStack item : ItemList.items) {
        Block block = Block.getBlockFromItem(item.getItem());
        if (block instanceof BlockDoor)
            continue;
        if (efuels.contains(item.getItem()))
            continue;

        int burnTime = TileEntityFurnace.getItemBurnTime(item);
        if (burnTime > 0)
            afuels.add(new FuelPair(item.copy(), burnTime));
    }
}
 
开发者ID:SneakyTactician,项目名称:BIGB,代码行数:16,代码来源:FurnaceRecipeHandler.java

示例11: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels() {
    afuels = new ArrayList<FuelPair>();
    Set<Item> efuels = excludedFuels();
    for (ItemStack item : ItemList.items)
        if (!efuels.contains(item.getItem())) {
            int burnTime = TileEntityInfusionAltar.isMagicalItem(item);
            if (burnTime > 0)
                afuels.add(new FuelPair(item, burnTime));
        }
}
 
开发者ID:BRForgers,项目名称:DynamicCraft,代码行数:11,代码来源:InfusionAltarHandler.java

示例12: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels() {
    afuels = new ArrayList<FuelPair>();
    Set<Item> efuels = excludedFuels();
    for (ItemStack item : ItemList.items)
        if (!efuels.contains(item.getItem())) {
            int burnTime = TileChemicalExtractor.getItemBurnTime(item);
            if (burnTime > 0)
                afuels.add(new FuelPair(item.copy(), burnTime));
        }
}
 
开发者ID:jasonmpen,项目名称:CarbonMod,代码行数:11,代码来源:ChemicalExtractorRecipeHandler.java

示例13: findFuels

import codechicken.nei.ItemList; //导入依赖的package包/类
private static void findFuels() {
    afuels = new ArrayList<FuelPair>();
    Set<Item> efuels = excludedFuels();
    for (ItemStack item : ItemList.items)
        if (!efuels.contains(item.getItem())) {
            int burnTime = TileCompressionChamber.getItemBurnTime(item);
            if (burnTime > 0)
                afuels.add(new FuelPair(item.copy(), burnTime));
        }
}
 
开发者ID:jasonmpen,项目名称:CarbonMod,代码行数:11,代码来源:CompressionChamberRecipeHandler.java

示例14: newInstance

import codechicken.nei.ItemList; //导入依赖的package包/类
@Override
public TemplateRecipeHandler newInstance() {
    for (ItemStack stack : ItemList.items) {
        if (stack != null && stack.getItem() instanceof ItemMoarSign) {
            moarSigns.add(stack);
        }
    }

    return super.newInstance();
}
 
开发者ID:GoryMoon,项目名称:MoarSigns,代码行数:11,代码来源:NEIShapedMoarSignHandler.java

示例15: initGui

import codechicken.nei.ItemList; //导入依赖的package包/类
@SuppressWarnings("unchecked")
@Override
public void initGui() {
	if (ItemList.items.size() == 0) {
		ItemList.loadItems();
	}
	scroll = 0;
}
 
开发者ID:modmuss50,项目名称:Network,代码行数:9,代码来源:GuiItemList.java


注:本文中的codechicken.nei.ItemList类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。