當前位置: 首頁>>代碼示例>>Java>>正文


Java ISimpleBlockRenderingHandler類代碼示例

本文整理匯總了Java中cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler的典型用法代碼示例。如果您正苦於以下問題:Java ISimpleBlockRenderingHandler類的具體用法?Java ISimpleBlockRenderingHandler怎麽用?Java ISimpleBlockRenderingHandler使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ISimpleBlockRenderingHandler類屬於cpw.mods.fml.client.registry包,在下文中一共展示了ISimpleBlockRenderingHandler類的14個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: init

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@Override
public void init(FMLInitializationEvent event)
{
    ISimpleBlockRenderingHandler myISBRH = new BlockRendererMultiOre();
    RenderingRegistry.registerBlockHandler(myISBRH.getRenderId(), myISBRH);

    ISimpleBlockRenderingHandler dummyRenderer = new BlockRendererDummy();
    RenderingRegistry.registerBlockHandler(dummyRenderer.getRenderId(), dummyRenderer);

    ISimpleBlockRenderingHandler msBoosterRenderer = new BlockRendererMothershipBooster();
    RenderingRegistry.registerBlockHandler(msBoosterRenderer.getRenderId(), msBoosterRenderer);

    ISimpleBlockRenderingHandler chestRenderer = new BlockRendererARChest();
    RenderingRegistry.registerBlockHandler(chestRenderer.getRenderId(), chestRenderer);

    SystemRenderEventHandler clientEventHandler = new SystemRenderEventHandler();
    FMLCommonHandler.instance().bus().register(clientEventHandler);
    MinecraftForge.EVENT_BUS.register(clientEventHandler);

    FMLCommonHandler.instance().bus().register(new TickHandlerClient());
}
 
開發者ID:katzenpapst,項目名稱:amunra,代碼行數:22,代碼來源:ClientProxy.java

示例2: checkRenderers

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public void checkRenderers()
{
    ISimpleBlockRenderingHandler renderer = (ISimpleBlockRenderingHandler)blockRenderers.get(Integer.valueOf(BetterBarrels.blockBarrelRendererID));
    if (!(renderer instanceof BlockBarrelRenderer)) {
        throw new RuntimeException(String.format("Wrong renderer found ! %s found while looking up the Jabba Barrel renderer.", new Object[] { renderer.getClass().getCanonicalName() }));
    }
}
 
開發者ID:Dennisbonke,項目名稱:JABBA,代碼行數:8,代碼來源:ClientProxy.java

示例3: registerRendering

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@SideOnly(Side.CLIENT)
public void registerRendering(ISimpleBlockRenderingHandler blockRenderer, TileEntitySpecialRenderer tileRenderer) {
  if (blockRenderer != null) {
    renderID = RenderingRegistry.getNextAvailableRenderId();
    RenderingRegistry.registerBlockHandler(renderID, blockRenderer);
  }
  if (tileRenderer != null) {
    ClientRegistry.bindTileEntitySpecialRenderer(tileEntityClass, tileRenderer);
  }
}
 
開發者ID:twothe,項目名稱:DaVincing,代碼行數:11,代碼來源:BlockLoader.java

示例4: registerBlockHandler

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@Override
public int registerBlockHandler(ISimpleBlockRenderingHandler handler)
{
    final int renderId = RenderingRegistry.getNextAvailableRenderId();
    RenderingRegistry.registerBlockHandler(renderId, handler);
    return renderId;
}
 
開發者ID:ExtrabiomesXL,項目名稱:EBXS-AutumnWoods,代碼行數:8,代碼來源:ClientProxy.java

示例5: registerRendering

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@SideOnly(Side.CLIENT)
public void registerRendering(ISimpleBlockRenderingHandler blockRenderer, TileEntitySpecialRenderer tileRenderer){
	if(blockRenderer != null){
		renderID = RenderingRegistry.getNextAvailableRenderId();
		RenderingRegistry.registerBlockHandler(renderID, blockRenderer);
	}
	if(tileRenderer != null){
		ClientRegistry.bindTileEntitySpecialRenderer(tileEntityClass, tileRenderer);
	}
}
 
開發者ID:hypercross,項目名稱:minepainter,代碼行數:11,代碼來源:BlockLoader.java

示例6: registerRenderInformation

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@Override
public void registerRenderInformation() {
    ExtraUtilsClient.colorBlockID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.fullBrightBlockID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.multiBlockID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.spikeBlockID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.drumRendererID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.connectedTextureID = RenderingRegistry.getNextAvailableRenderId();
    ExtraUtilsClient.connectedTextureEtheralID = RenderingRegistry.getNextAvailableRenderId();
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockColor());
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockFullBright());
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockMultiBlock());
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)ExtraUtilsClient.renderBlockSpike);
    for (final Item item : ItemBlockSpike.itemHashSet) {
        MinecraftForgeClient.registerItemRenderer(item, (IItemRenderer)ExtraUtilsClient.renderItemSpikeSword);
    }
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockDrum());
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockConnectedTextures());
    RenderingRegistry.registerBlockHandler((ISimpleBlockRenderingHandler)new RenderBlockConnectedTexturesEthereal());
    if (ExtraUtils.spikeGoldEnabled) {
        ClientRegistry.bindTileEntitySpecialRenderer((Class)TileEntityEnchantedSpike.class, (TileEntitySpecialRenderer)new RenderTileEntitySpike());
    }
    if (ExtraUtils.colorBlockDataEnabled) {
        for (final BlockColor b : ExtraUtils.colorblocks) {
            MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock((Block)b), (IItemRenderer)ExtraUtilsClient.renderItemBlockColor);
        }
    }
    if (ExtraUtils.unstableIngot != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.unstableIngot, (IItemRenderer)ExtraUtilsClient.renderItemUnstable);
    }
    if (ExtraUtils.erosionShovel != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.erosionShovel, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.destructionPickaxe != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.destructionPickaxe, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.buildersWand != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.buildersWand, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.ethericSword != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.ethericSword, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.healingAxe != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.healingAxe, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.creativeBuildersWand != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.creativeBuildersWand, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.precisionShears != null) {
        MinecraftForgeClient.registerItemRenderer((Item)ExtraUtils.precisionShears, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.temporalHoe != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.temporalHoe, (IItemRenderer)ExtraUtilsClient.renderItemMultiTransparency);
    }
    if (ExtraUtils.drum != null) {
        MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(ExtraUtils.drum), (IItemRenderer)ExtraUtilsClient.renderItemDrum);
    }
    if (ExtraUtils.microBlocks != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.microBlocks, (IItemRenderer)new RenderItemMicroblock());
    }
    if (ExtraUtils.lawSwordEnabled) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.lawSword, (IItemRenderer)new RenderItemLawSword());
    }
    if (ExtraUtils.glove != null) {
        MinecraftForgeClient.registerItemRenderer(ExtraUtils.glove, (IItemRenderer)RenderItemGlove.INSTANCE);
    }
}
 
開發者ID:sameer,項目名稱:ExtraUtilities,代碼行數:68,代碼來源:ExtraUtilsClient.java

示例7: registerRenderInformation

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public void registerRenderInformation()
  {
epicproportionsmod_christmas.BulbModelID = RenderingRegistry.instance().getNextAvailableRenderId();
      RenderingRegistry.instance().registerBlockHandler(epicproportionsmod_christmas.BulbModelID , (ISimpleBlockRenderingHandler) new TileEntityBulbRender());
      }
 
開發者ID:jtrent238,項目名稱:PopularMMOS-EpicProportions-Mod,代碼行數:6,代碼來源:ClientProxy.java

示例8: register

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@Override
protected void register(ISimpleBlockRenderingHandler obj,
        RegBlockRenderer anno) throws Exception {
    RenderingRegistry.registerBlockHandler(obj);
}
 
開發者ID:LambdaInnovation,項目名稱:LambdaLib,代碼行數:6,代碼來源:BlockRendererRegistration.java

示例9: registerBlockHandler

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public int registerBlockHandler(ISimpleBlockRenderingHandler handler) {
	return 0;
}
 
開發者ID:ExtrabiomesXL,項目名稱:EBXS-AutumnWoods,代碼行數:4,代碼來源:CommonProxy.java

示例10: setRenderer

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@SideOnly(Side.CLIENT)
public void setRenderer(ISimpleBlockRenderingHandler handler) {
	renderId = handler.getRenderId();
}
 
開發者ID:asiekierka,項目名稱:ConveyorBelts,代碼行數:5,代碼來源:BlockBase.java

示例11: registerBlockRenderer

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public int registerBlockRenderer(ISimpleBlockRenderingHandler renderer) {
    int nextId = RenderingRegistry.getNextAvailableRenderId();
    RenderingRegistry.registerBlockHandler(nextId, renderer);
    return nextId;
}
 
開發者ID:makeoo,項目名稱:Gadomancy,代碼行數:6,代碼來源:ClientProxy.java

示例12: registerRenderers

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public static void registerRenderers(Object o, Class<? extends AmaTileEntity> te, Item item) {

    if (o instanceof AmaTESR) registerTESR((AmaTESR) o, te);
    if (o instanceof ISimpleBlockRenderingHandler) registerISBRH((ISimpleBlockRenderingHandler) o);
    if (o instanceof IItemRenderer) registerItemRenderer((IItemRenderer) o, item);
}
 
開發者ID:amadornes,項目名稱:AmadornesLib,代碼行數:7,代碼來源:AmaUtils.java

示例13: registerRenders

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
@Override
	public void registerRenders() {
		
		int r = RenderingRegistry.getNextAvailableRenderId();
		ISimpleBlockRenderingHandler handler = new RenderFakeBlock(r);
		RenderingRegistry.registerBlockHandler(handler);
		((BlockIllusionary)BlockIllusionary.instance).renderType = r;
//		GameRegistry.registerTileEntity(TileEntitySpikes.class, "artifacts.spiketrap");
		
		r = RenderingRegistry.getNextAvailableRenderId();
		handler = new RenderArrowTrap(r);
		RenderingRegistry.registerBlockHandler(handler);
		((BlockTrap)BlockTrap.instance).renderType = r;
//		GameRegistry.registerTileEntity(TileEntityTrap.class, "artifacts.arrowtrap");

//		r = RenderingRegistry.getNextAvailableRenderId();
//		handler = new RenderQuickSand(r);
//		RenderingRegistry.registerBlockHandler(handler);
//		((BlockQuickSand)BlockQuickSand.instance).renderType = r;
		
		r = RenderingRegistry.getNextAvailableRenderId();
		handler = new RenderCoverPlate(r);
		RenderingRegistry.registerBlockHandler(handler);
		((BlockCoverPlate)BlockCoverPlate.instance).renderType = r;
        RenderingRegistry.registerEntityRenderingHandler(EntityClayGolem.class, new RenderClayGolem());
        
		TileEntitySpecialRenderer render = new TESwordRenderer();
		ClientRegistry.bindTileEntitySpecialRenderer(TileEntitySword.class, render);
        MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(BlockSword.instance), new ItemRenderPedestal(render, new TileEntitySword()));
		
        render = new PedestalRenderer();
		ClientRegistry.bindTileEntitySpecialRenderer(TileEntityDisplayPedestal.class, render);
        MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(BlockPedestal.instance), new ItemRenderPedestal(render, new TileEntityDisplayPedestal()));
        
        render = new SpikesRenderer();
        ClientRegistry.bindTileEntitySpecialRenderer(TileEntitySpikes.class, render);
        MinecraftForgeClient.registerItemRenderer(Item.getItemFromBlock(BlockSpikes.instance), new ItemRenderPedestal(render, new TileEntitySpikes()));
        
        r = RenderingRegistry.getNextAvailableRenderId();
        handler = new RenderLaserBeam(r);
		RenderingRegistry.registerBlockHandler(handler);
		((BlockLaserBeam)BlockLaserBeam.instance).renderID = r;

        r = RenderingRegistry.getNextAvailableRenderId();
        handler = new RenderLaserSource(r);
		RenderingRegistry.registerBlockHandler(handler);
		((BlockLaserBeamSource)BlockLaserBeamSource.instance).renderID = r;
		
		if(Loader.isModLoaded("antiqueatlas")) {
//			AtlasAPI.getTileAPI().setTexture("wizardtower", new ResourceLocation("artifacts:textures/gui/tower.png"));
		}
	}
 
開發者ID:Draco18s,項目名稱:Artifacts,代碼行數:53,代碼來源:ClientProxy.java

示例14: registerISBRH

import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //導入依賴的package包/類
public static void registerISBRH(ISimpleBlockRenderingHandler isbrh) {

    RenderingRegistry.registerBlockHandler(isbrh);
}
 
開發者ID:amadornes,項目名稱:AmadornesLib,代碼行數:5,代碼來源:AmaUtils.java


注:本文中的cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。