本文整理汇总了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());
}
示例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() }));
}
}
示例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);
}
}
示例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;
}
示例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);
}
}
示例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);
}
}
示例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());
}
示例8: register
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //导入依赖的package包/类
@Override
protected void register(ISimpleBlockRenderingHandler obj,
RegBlockRenderer anno) throws Exception {
RenderingRegistry.registerBlockHandler(obj);
}
示例9: registerBlockHandler
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //导入依赖的package包/类
public int registerBlockHandler(ISimpleBlockRenderingHandler handler) {
return 0;
}
示例10: setRenderer
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //导入依赖的package包/类
@SideOnly(Side.CLIENT)
public void setRenderer(ISimpleBlockRenderingHandler handler) {
renderId = handler.getRenderId();
}
示例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;
}
示例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);
}
示例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"));
}
}
示例14: registerISBRH
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler; //导入依赖的package包/类
public static void registerISBRH(ISimpleBlockRenderingHandler isbrh) {
RenderingRegistry.registerBlockHandler(isbrh);
}