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


Java IOverlayHandler类代码示例

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


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

示例1: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public IOverlayHandler getOverlayHandler(final GuiContainer gui, final int recipe) {
    IOverlayHandler handler = RecipeInfo.getOverlayHandler(gui, "microblocks");
    if (handler != null) {
        return handler;
    }
    if (this.isRecipe2x2(recipe)) {
        handler = RecipeInfo.getOverlayHandler(gui, "microblocks2x2");
        if (handler != null) {
            return handler;
        }
    }
    return super.getOverlayHandler(gui, recipe);
}
 
开发者ID:sameer,项目名称:ExtraUtilities,代码行数:14,代码来源:FMPMicroBlocksHandler.java

示例2: overlayRecipe

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
private void overlayRecipe(int recipe) {
    IRecipeOverlayRenderer renderer = currenthandlers.get(recipetype).getOverlayRenderer(firstGui, recipe);
    IOverlayHandler handler = currenthandlers.get(recipetype).getOverlayHandler(firstGui, recipe);
    boolean shift = NEIClientUtils.shiftKey();

    if (handler != null && (renderer == null || shift)) {
        mc.displayGuiScreen(firstGui);
        handler.overlayRecipe(firstGui, currenthandlers.get(recipetype), recipe, shift);
    } else if (renderer != null) {
        mc.displayGuiScreen(firstGui);
        LayoutManager.overlayRenderer = renderer;
    }
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:14,代码来源:GuiRecipe.java

示例3: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe) {
    IOverlayHandler handler = super.getOverlayHandler(gui, recipe);
    if (handler != null)
        return handler;

    return RecipeInfo.getOverlayHandler(gui, "crafting2x2");
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:9,代码来源:ShapedRecipeHandler.java

示例4: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe) {
    IOverlayHandler handler = super.getOverlayHandler(gui, recipe);
    if (handler != null) {
        return handler;
    }

    return RecipeInfo.getOverlayHandler(gui, "crafting2x2");
}
 
开发者ID:TheCBProject,项目名称:NotEnoughItems,代码行数:10,代码来源:ShapedRecipeHandler.java

示例5: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
   public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe) {
IOverlayHandler handler = super.getOverlayHandler(gui, recipe);
if (handler != null)
    return handler;

return RecipeInfo.getOverlayHandler(gui, "crafting2x2");
   }
 
开发者ID:OwnAgePau,项目名称:Soul-Forest,代码行数:9,代码来源:GemmerationTableRecipeHandler.java

示例6: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public IOverlayHandler getOverlayHandler(final GuiContainer gui, final int recipe) {
    return null;
}
 
开发者ID:sameer,项目名称:ExtraUtilities,代码行数:4,代码来源:InfoHandler.java

示例7: loadConfig

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public void loadConfig() {
    NEIPing.init();
    if (ExtraUtils.drum != null) {
        API.addSubset("Extra Common.Drums", (ItemFilter)new SubsetItemsNBT(Item.getItemFromBlock(ExtraUtils.drum)));
    }
    if (ExtraUtils.microBlocks != null) {
        API.addSubset("Extra Common.Extra Microblocks", (ItemFilter)new SubsetItemsNBT(ExtraUtils.microBlocks));
    }
    if (ExtraUtils.colorBlockDataEnabled) {
        API.addSubset("Extra Common.Colored Blocks", (ItemFilter)new SubsetBlockClass(BlockColor.class));
    }
    if (ExtraUtils.greenScreen != null) {
        API.addSubset("Extra Common.Lapis Caelestis", (ItemFilter)new SubsetItems(new Item[] { Item.getItemFromBlock((Block)ExtraUtils.greenScreen) }));
    }
    if (ExtraUtils.cobblestoneCompr != null) {
        API.addSubset("Extra Common.Compressed Blocks", (ItemFilter)new SubsetItems(new Item[] { Item.getItemFromBlock((Block)ExtraUtils.cobblestoneCompr) }));
    }
    if (ExtraUtils.decorative1Enabled || ExtraUtils.decorative2Enabled) {
        API.addSubset("Extra Common.Decorative Blocks", (ItemFilter)new SubsetBlockClass(BlockDecoration.class));
    }
    if (ExtraUtils.generator2 != null) {
        final SubsetItems s = new SubsetItems(new Item[] { Item.getItemFromBlock(ExtraUtils.generator2) });
        if (ExtraUtils.generator3 != null) {
            s.addItem(Item.getItemFromBlock(ExtraUtils.generator3));
        }
        API.addSubset("Extra Common.Higher Tier Generators", (ItemFilter)s);
    }
    for (final Matcher matcher : AdvancedNodeUpgrades.entryList) {
        if (matcher != AdvancedNodeUpgrades.nullMatcher && matcher.type == Matcher.Type.ITEM && matcher.shouldAddToNEI() && matcher.isSelectable()) {
            String localizedName = matcher.getLocalizedName();
            localizedName = localizedName.replace(".exe", "");
            localizedName = localizedName.replaceAll("\\.", "");
            API.addSubset("Extra Filtering." + localizedName, (ItemFilter)new ItemFilterWrapper(matcher));
        }
    }
    API.registerRecipeHandler((ICraftingHandler)new EnderConstructorHandler());
    API.registerUsageHandler((IUsageHandler)new EnderConstructorHandler());
    API.registerRecipeHandler((ICraftingHandler)new InfoHandler());
    API.registerUsageHandler((IUsageHandler)new InfoHandler());
    API.registerRecipeHandler((ICraftingHandler)new SoulHandler());
    API.registerUsageHandler((IUsageHandler)new SoulHandler());
    if (Loader.isModLoaded("ForgeMultipart")) {
        API.registerRecipeHandler((ICraftingHandler)new FMPMicroBlocksHandler());
        API.registerUsageHandler((IUsageHandler)new FMPMicroBlocksHandler());
        API.registerRecipeHandler((ICraftingHandler)new MicroBlocksHandler());
        API.registerUsageHandler((IUsageHandler)new MicroBlocksHandler());
        API.registerGuiOverlayHandler((Class)GuiCrafting.class, (IOverlayHandler)new FMPMicroBlocksOverlayHandler(), "microblocks");
        API.registerGuiOverlayHandler((Class)GuiInventory.class, (IOverlayHandler)new FMPMicroBlocksOverlayHandler(63, 20), "microblocks2x2");
    }
    if (ExtraUtils.colorBlockData != null) {
        API.hideItem(new ItemStack(ExtraUtils.colorBlockData));
    }
    LogHelper.info("Added NEI integration", new Object[0]);
}
 
开发者ID:sameer,项目名称:ExtraUtilities,代码行数:55,代码来源:NEIInfoHandlerConfig.java

示例8: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe) {
    return RecipeInfo.getOverlayHandler(gui, getOverlayIdentifier());
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:5,代码来源:TemplateRecipeHandler.java

示例9: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe)
{
    return null;
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:6,代码来源:ProfilerRecipeHandler.java

示例10: registerOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public static void registerOverlayHandler(Class<? extends GuiContainer> classz, IOverlayHandler handler, String ident)
{
    overlayMap.put(new OverlayKey(classz, ident), handler);
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:5,代码来源:RecipeInfo.java

示例11: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public static IOverlayHandler getOverlayHandler(GuiContainer gui, String ident)
{
    return overlayMap.get(new OverlayKey(gui.getClass(), ident));
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:5,代码来源:RecipeInfo.java

示例12: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
@Override
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe) {
    return null;
}
 
开发者ID:TheCBProject,项目名称:NotEnoughItems,代码行数:5,代码来源:ProfilerRecipeHandler.java

示例13: registerOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public static void registerOverlayHandler(Class<? extends GuiContainer> classz, IOverlayHandler handler, String ident) {
    overlayMap.put(new OverlayKey(classz, ident), handler);
}
 
开发者ID:TheCBProject,项目名称:NotEnoughItems,代码行数:4,代码来源:RecipeInfo.java

示例14: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
public static IOverlayHandler getOverlayHandler(GuiContainer gui, String ident) {
    return overlayMap.get(new OverlayKey(gui.getClass(), ident));
}
 
开发者ID:TheCBProject,项目名称:NotEnoughItems,代码行数:4,代码来源:RecipeInfo.java

示例15: getOverlayHandler

import codechicken.nei.api.IOverlayHandler; //导入依赖的package包/类
/**
 * 
 * @param recipe The recipe index to get the overlay renderer for.
 * @return An instance of {@link IOverlayHandler} to be used for rendering the overlay of this specific recipe.
 */
public IOverlayHandler getOverlayHandler(GuiContainer gui, int recipe);
 
开发者ID:4Space,项目名称:4Space-5,代码行数:7,代码来源:IRecipeHandler.java


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