本文整理汇总了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);
}
}
}
}
示例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));
}
}
}
示例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));
}
}
}
示例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));
}
}
}
示例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));
}
}
}
示例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());
}
}
}
}
示例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();
}
示例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;
}
示例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));
}
}
示例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));
}
}
示例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));
}
}
示例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));
}
}
示例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));
}
}
示例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();
}
示例15: initGui
import codechicken.nei.ItemList; //导入依赖的package包/类
@SuppressWarnings("unchecked")
@Override
public void initGui() {
if (ItemList.items.size() == 0) {
ItemList.loadItems();
}
scroll = 0;
}