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


Java RenderBlocks.clearOverrideBlockTexture方法代码示例

本文整理汇总了Java中net.minecraft.client.renderer.RenderBlocks.clearOverrideBlockTexture方法的典型用法代码示例。如果您正苦于以下问题:Java RenderBlocks.clearOverrideBlockTexture方法的具体用法?Java RenderBlocks.clearOverrideBlockTexture怎么用?Java RenderBlocks.clearOverrideBlockTexture使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在net.minecraft.client.renderer.RenderBlocks的用法示例。


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

示例1: renderInvNormalBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public static void renderInvNormalBlock(RenderBlocks renderBlocks, Block par1Block, int var2)
{
    renderBlocks.setRenderBounds(0.2F, 0.0F, 0.2F, 0.8F, 0.5F, 0.8F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.52F, 0.0F, 0.4F, 0.68F, 0.68F, 0.6F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.65F, 0.75F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.15F, 0.0F, 0.25F, 0.2F, 0.4F, 0.75F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.8F, 0.0F, 0.25F, 0.85F, 0.4F, 0.75F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.1F, 0.75F, 0.4F, 0.2F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.8F, 0.75F, 0.4F, 0.9F);
    BlockRendererEgg.renderStandardBlock(renderBlocks, par1Block, var2);

    renderBlocks.clearOverrideBlockTexture();
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:26,代码来源:BlockRendererEgg.java

示例2: renderMachineInWorld

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderMachineInWorld(RenderBlocks renderBlocks, IBlockAccess iblockaccess, Block par1Block, int x, int y, int z)
{
    par1Block.setBlockBoundsBasedOnState(iblockaccess, x, y, z);
    renderBlocks.setRenderBoundsFromBlock(par1Block);

    int metadata = iblockaccess.getBlockMetadata(x, y, z) & 12;

    if (metadata == BlockMachineMars.CRYOGENIC_CHAMBER_METADATA && par1Block == MarsBlocks.machine)
    {

    }
    else
    {
        renderBlocks.renderStandardBlock(par1Block, x, y, z);
    }

    renderBlocks.clearOverrideBlockTexture();
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:19,代码来源:BlockRendererMachine.java

示例3: renderFluid

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderFluid(float f5)
 {
 	if(hasFluid && hasJug)
 	{
 		GL11.glPushMatrix();
 		GL11.glPushAttrib(GL11.GL_ENABLE_BIT);
 		GL11.glEnable(GL11.GL_CULL_FACE);
 		GL11.glDisable(GL11.GL_LIGHTING);
 		GL11.glEnable(GL11.GL_BLEND);
 		GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
 		float scale = 0.5F;
 		GL11.glScalef(scale, scale, scale);
 		GL11.glTranslatef(0f, 2.0F, 0f);

 		Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.locationBlocksTexture);
      
  	RenderBlocks renderBlocks = RenderBlocks.getInstance();
      renderBlocks.setOverrideBlockTexture(fluidstack.getFluid().getStillIcon());
      renderBlocks.renderBlockAsItem(Blocks.stone, 0, 1.0f);

      renderBlocks.clearOverrideBlockTexture();

GL11.glPopAttrib();
GL11.glPopMatrix();
 	}
 }
 
开发者ID:gigabit101,项目名称:PrimitiveCraft,代码行数:27,代码来源:ModelCampfire.java

示例4: renderFluid

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderFluid(float f5)
 {
 	if(hasFluid)
 	{
 		GL11.glPushMatrix();
 		GL11.glPushAttrib(GL11.GL_ENABLE_BIT);
 		GL11.glEnable(GL11.GL_CULL_FACE);
 		GL11.glDisable(GL11.GL_LIGHTING);
 		GL11.glEnable(GL11.GL_BLEND);
 		GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
 		float scale = 0.5F;
 		GL11.glScalef(scale, scale, scale);
 		GL11.glTranslatef(0f, 2.0F, 0f);

 		Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.locationBlocksTexture);
      
  	RenderBlocks renderBlocks = RenderBlocks.getInstance();
      renderBlocks.setOverrideBlockTexture(fluidstack.getFluid().getStillIcon());
      renderBlocks.renderBlockAsItem(Blocks.stone, 0, 1.0f);

      renderBlocks.clearOverrideBlockTexture();

GL11.glPopAttrib();
GL11.glPopMatrix();
 	}
 }
 
开发者ID:gigabit101,项目名称:PrimitiveCraft,代码行数:27,代码来源:ModelJug.java

示例5: renderBlockByCompleteness

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public static void renderBlockByCompleteness(Block block, Fluid fluid, int meta, RenderBlocks renderer, double complete, int x, int y, int z) {

		renderer.setRenderBounds(0.01, 0.01, 0.01, 0.99, complete * 0.99, 0.99);
		renderer.setOverrideBlockTexture(fluid.getIcon());
		renderer.renderStandardBlock(block, x, y, z);
		renderer.clearOverrideBlockTexture();
	}
 
开发者ID:grand-mine-inc,项目名称:Steam-and-Steel,代码行数:8,代码来源:Utils.java

示例6: renderWorldBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
private boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, BlockInfusedBlockOre block, int modelId,
		RenderBlocks renderer) {
	renderer.setRenderBoundsFromBlock(block);
	renderer.renderStandardBlock(block.getBaseBlock(), x, y, z);
	renderer.clearOverrideBlockTexture();
	return true;
}
 
开发者ID:MJaroslav,项目名称:ThaumOres,代码行数:8,代码来源:BlockInfusedBlockOreRenderer.java

示例7: renderBlockMeteor

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderBlockMeteor(RenderBlocks renderBlocks, Block par1Block, IBlockAccess var1, int par2, int par3, int par4)
{
    var1.getBlockMetadata(par2, par3, par4);

    renderBlocks.setRenderBounds(0.2F, 0.0F, 0.2F, 0.8F, 0.5F, 0.8F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.52F, 0.0F, 0.4F, 0.68F, 0.68F, 0.6F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.25F, 0.75F, 0.65F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.15F, 0.0F, 0.25F, 0.2F, 0.4F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.8F, 0.0F, 0.25F, 0.85F, 0.4F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.1F, 0.75F, 0.4F, 0.2F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.0F, 0.8F, 0.75F, 0.4F, 0.9F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.clearOverrideBlockTexture();
    par1Block.setBlockBoundsForItemRender();
    renderBlocks.uvRotateTop = 0;
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:30,代码来源:BlockRendererEgg.java

示例8: renderInvNormalBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public static void renderInvNormalBlock(RenderBlocks var0, Block var1, int var2)
{
    var0.setRenderBounds(0.2F, 0.2F, 0.2F, 0.8F, 0.8F, 0.8F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.52F, 0.85F, 0.4F, 0.68F, 0.88F, 0.6F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.25F, 0.8F, 0.25F, 0.75F, 0.85F, 0.75F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.25F, 0.15F, 0.25F, 0.75F, 0.2F, 0.75F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.15F, 0.3F, 0.25F, 0.2F, 0.7F, 0.75F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.8F, 0.3F, 0.25F, 0.85F, 0.7F, 0.75F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.25F, 0.3F, 0.15F, 0.75F, 0.7F, 0.2F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.setRenderBounds(0.25F, 0.3F, 0.8F, 0.75F, 0.7F, 0.85F);
    BlockRendererMeteor.renderStandardBlock(var0, var1, var2);

    var0.clearOverrideBlockTexture();
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:29,代码来源:BlockRendererMeteor.java

示例9: renderNasaBench

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderNasaBench(RenderBlocks renderBlocks, IBlockAccess iblockaccess, Block par1Block, int par2, int par3, int par4)
{
    renderBlocks.setRenderBounds(0.0F, 0.0F, 0.0F, 1.0F, 0.92F, 1.0F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.clearOverrideBlockTexture();
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:8,代码来源:BlockRendererNasaWorkbench.java

示例10: renderInventoryBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
@Override
public void renderInventoryBlock(Block block, int metadata, int modelId, RenderBlocks renderer) {
    renderInventoryBlock(renderer, block, 0);

    renderer.setOverrideBlockTexture(BlockPIM.iIcon1);
    setTopPartBounds(renderer, false);
    renderInventoryBlockNoBounds(renderer, block, 0);
    renderer.clearOverrideBlockTexture();
}
 
开发者ID:Avaja,项目名称:OpenTechnology,代码行数:10,代码来源:BlockPIMRender.java

示例11: renderWorldBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
@Override
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
    renderer.setRenderBoundsFromBlock(block);
    renderer.renderStandardBlock(block, x, y, z);

    final boolean isBreaking = renderer.hasOverrideBlockTexture();
    if (!isBreaking) renderer.setOverrideBlockTexture(BlockPIM.iIcon1);

    final boolean hasPlayer = hasPlayer(world, x, y, z);
    setTopPartBounds(renderer, hasPlayer);
    renderer.renderStandardBlock(block, x, y, z);

    if (!isBreaking) renderer.clearOverrideBlockTexture();
    return true;
}
 
开发者ID:Avaja,项目名称:OpenTechnology,代码行数:16,代码来源:BlockPIMRender.java

示例12: renderWorldBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
@Override
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer) {
	TELatexExtractor te = (TELatexExtractor) world.getTileEntity(x, y, z);
	Block latexBlock = ModBlocks.latex;
	float p = 0.0625f;
	
	renderer.renderAllFaces = true;
	GL11.glPushMatrix();

	if (te.getLatexAmount() > 0 && te.isBowlInstalled()) {
		FluidStack fs = new FluidStack(ModFluids.LATEX, te.getLatexAmount());

		int color = fs.getFluid().getColor(fs);
		float f = (color >> 16 & 255) / 255.0F;
		float f1 = (color >> 8 & 255) / 255.0F;
		float f2 = (color & 255) / 255.0F;
		float h = 4*p * (fs.amount / 200f);
		
		IIcon still = fs.getFluid().getStillIcon();
		
		setRotatedRenderBounds(renderer, te.rotation, MIN_X+5*p, MIN_Y+p, MIN_Z+7*p, MAX_X-5*p, MIN_Y+p+h, MAX_Z-3*p);
		renderer.setOverrideBlockTexture(still);
		renderer.renderStandardBlockWithColorMultiplier(latexBlock, x, y, z, f, f1, f2);
		renderer.clearOverrideBlockTexture();
		
	}
	
	rotate(renderer, 0);
	renderer.renderAllFaces = false;
	GL11.glPopMatrix();
	
	return true;
}
 
开发者ID:Shurgent,项目名称:TFCTech,代码行数:34,代码来源:RenderLatexExtractor.java

示例13: renderFire

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderFire(float f5)
 {
 	if(isActive)
 	{
GL11.glPushMatrix();
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
GL11.glRotatef(180, 0, 0, 5);
if(!hasJug)
{
	GL11.glTranslatef(0f, -0.8F, 0f);
}
else
{
	GL11.glTranslatef(0f, -1.2F, 0f);
}
if(hasJug)
{
	GL11.glScalef(1F, 0.5F, 1F);
}

Minecraft.getMinecraft().renderEngine.bindTexture(TextureMap.locationBlocksTexture);
      
  	RenderBlocks renderBlocks = RenderBlocks.getInstance();
      renderBlocks.setOverrideBlockTexture(Blocks.fire.getFireIcon(1));
      renderBlocks.renderBlockAsItem(Blocks.torch, 1, 2.0f);
	
      renderBlocks.clearOverrideBlockTexture();

GL11.glDisable(GL11.GL_BLEND);
GL11.glPopMatrix();
 	}
 }
 
开发者ID:gigabit101,项目名称:PrimitiveCraft,代码行数:34,代码来源:ModelCampfire.java

示例14: renderWorldBlock

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
@Override
public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId,
		RenderBlocks renderer) 
{
	int ovenType = 0;
	
	if(block instanceof TFPBrickOven)
		ovenType = ((TFPBrickOven)block).getOvenType();
	
	IIcon cobbleIcon = TFCBlocks.stoneIgExCobble.getIcon(0, ovenType);
	
	if(ovenType > 3)
		cobbleIcon = TFCBlocks.stoneIgInCobble.getIcon(0, ovenType - 4);
			
	renderer.renderAllFaces = true;
	
	renderer.setRenderBounds(0, 0, 0, 1, 1, 1);

	renderer.overrideBlockTexture = cobbleIcon;
	renderer.renderStandardBlock(block, x, y, z);
	renderer.clearOverrideBlockTexture();
	
	renderer.renderStandardBlock(block, x, y, z);
	
	renderer.uvRotateTop = 0;
	renderer.uvRotateBottom = 0;
	renderer.uvRotateWest = 0;
	renderer.uvRotateEast = 0;
	renderer.uvRotateNorth = 0;
	renderer.uvRotateSouth = 0;
	
	renderer.renderAllFaces = false;
	return true;
}
 
开发者ID:StrayWolfe,项目名称:TerrafirmaPunk-Tweaks,代码行数:35,代码来源:TFPBrickOvenRenderer.java

示例15: renderBlockMeteor

import net.minecraft.client.renderer.RenderBlocks; //导入方法依赖的package包/类
public void renderBlockMeteor(RenderBlocks renderBlocks, Block par1Block, IBlockAccess var1, int par2, int par3, int par4)
{
    final int var5 = var1.getBlockMetadata(par2, par3, par4);
    final int var6 = var5 & 3;

    if (var6 == 0)
    {
        renderBlocks.uvRotateTop = 3;
    }
    else if (var6 == 3)
    {
        renderBlocks.uvRotateTop = 1;
    }
    else if (var6 == 1)
    {
        renderBlocks.uvRotateTop = 2;
    }

    renderBlocks.setRenderBounds(0.2F, 0.2F, 0.2F, 0.8F, 0.8F, 0.8F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.52F, 0.85F, 0.4F, 0.68F, 0.88F, 0.6F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.8F, 0.25F, 0.75F, 0.85F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.15F, 0.25F, 0.75F, 0.2F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.15F, 0.3F, 0.25F, 0.2F, 0.7F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.8F, 0.3F, 0.25F, 0.85F, 0.7F, 0.75F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.3F, 0.15F, 0.75F, 0.7F, 0.2F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.25F, 0.3F, 0.8F, 0.75F, 0.7F, 0.85F);
    renderBlocks.renderStandardBlock(par1Block, par2, par3, par4);

    renderBlocks.setRenderBounds(0.12F, 0.12F, 0.12F, 0.88F, 0.88F, 0.88F);

    renderBlocks.clearOverrideBlockTexture();
    par1Block.setBlockBoundsForItemRender();
    renderBlocks.uvRotateTop = 0;
}
 
开发者ID:4Space,项目名称:4Space-5,代码行数:49,代码来源:BlockRendererMeteor.java


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