Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

3c0n.png

 

when i destroy the block, while i'm destroyng it it doesn't show the destroying animation, it just glows until it get destoyed.

here is the block renderer:

 

 

package net.minecraft.src;

import net.minecraft.block.Block;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.world.IBlockAccess;
import cpw.mods.fml.client.registry.ISimpleBlockRenderingHandler;
import cpw.mods.fml.client.registry.RenderingRegistry;
import org.lwjgl.opengl.GL11;
import net.minecraft.util.ResourceLocation;
import net.minecraft.client.renderer.texture.TextureManager;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.util.Icon;

public class RenderGlaciaColumn implements ISimpleBlockRenderingHandler
{
public Icon getColumnIcon(int par1)
    {
return mod_Glacia.GlaciaColumn.getIcon(0, par1);
}

private ModelGlaciaColumn aModel;
private static final ResourceLocation GlaciaColumn = new ResourceLocation("textures/entity/Glacia/GlaciaColumn.png");

public RenderGlaciaColumn()
    {
        aModel = new ModelGlaciaColumn();
    }

    public void renderInventoryBlock(Block block, int metadata, int modelID, RenderBlocks renderer)
{
double minU2 = (double)getColumnIcon(0).getMinU();
double minV2 = (double)getColumnIcon(0).getMinV();
double maxU2 = (double)getColumnIcon(0).getMaxU();
double maxV2 = (double)getColumnIcon(0).getMaxV();
double minU1 = (double)getColumnIcon(1).getMinU();
    double minV1 = (double)getColumnIcon(1).getMinV();
    double maxU1 = (double)getColumnIcon(1).getMaxU();
    double maxV1 = (double)getColumnIcon(1).getMaxV();
double minU3 = (double)getColumnIcon(2).getMinU();
    double minV3 = (double)getColumnIcon(2).getMinV();
    double maxU3 = (double)getColumnIcon(2).getMaxU();
    double maxV3 = (double)getColumnIcon(2).getMaxV();
Tessellator tessellator = Tessellator.instance;
    GL11.glTranslatef(-0.5F, -0.5F, -0.5F);

//portantdown face 1

    tessellator.startDrawingQuads();
    tessellator.setNormal(0.0F, 0.0F, 1.0F);
    tessellator.addVertexWithUV(1.0, 0.0, 0.0, maxU2, maxV2);
tessellator.addVertexWithUV(0.0, 0.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(0.0, 0.25, 0.0, minU2, minV2);
tessellator.addVertexWithUV(1.0, 0.25, 0.0, minU2, maxV2);
    tessellator.draw();

//portantdown face inverse  1

tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 0.0F, -1.0F);
tessellator.addVertexWithUV(1.0, 0.25, 1.0, minU2, maxV2);
tessellator.addVertexWithUV(0.0, 0.25, 1.0, minU2, minV2);
tessellator.addVertexWithUV(0.0, 0.0, 1.0, maxU2, minV2);
tessellator.addVertexWithUV(1.0, 0.0, 1.0, maxU2, maxV2);
tessellator.draw();

// portantdown face 2
tessellator.startDrawingQuads();
    tessellator.setNormal(-1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(0.0, 0.25, 1.0, minU2, maxV2);
tessellator.addVertexWithUV(0.0, 0.25, 0.0, minU2, minV2);
tessellator.addVertexWithUV(0.0, 0.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(0.0, 0.0, 1.0, maxU2, maxV2);
tessellator.draw();

// portantdown face inverse 2
tessellator.startDrawingQuads();
    tessellator.setNormal(1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(1.0, 0.0, 1.0, maxU2, maxV2);
tessellator.addVertexWithUV(1.0, 0.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(1.0, 0.25, 0.0, minU2, minV2);
tessellator.addVertexWithUV(1.0, 0.25, 1.0, minU2, maxV2);
tessellator.draw();

// portantup face 1
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 0.0F, 1.0F);
tessellator.addVertexWithUV(1.0, 0.75, 0.0, minU2, maxV2);
tessellator.addVertexWithUV(0.0, 0.75, 0.0, minU2, minV2);
tessellator.addVertexWithUV(0.0, 1.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(1.0, 1.0, 0.0, maxU2, maxV2);
tessellator.draw();

// portantup face inverse 1
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 0.0F, 1.0F);
tessellator.addVertexWithUV(1.0, 1.0, 1.0, maxU2, maxV2);
tessellator.addVertexWithUV(0.0, 1.0, 1.0, maxU2, minV2);
tessellator.addVertexWithUV(0.0, 0.75, 1.0, minU2, minV2);
tessellator.addVertexWithUV(1.0, 0.75, 1.0, minU2, maxV2);
tessellator.draw();

// portantup face 2
tessellator.startDrawingQuads();
tessellator.setNormal(1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(1.0, 0.75, 1.0, minU2, maxV2);
tessellator.addVertexWithUV(1.0, 0.75, 0.0, minU2, minV2);
tessellator.addVertexWithUV(1.0, 1.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(1.0, 1.0, 1.0, maxU2, maxV2);
tessellator.draw();

// portantup face inverse 2
tessellator.startDrawingQuads();
tessellator.setNormal(1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(0.0, 1.0, 1.0, maxU2, maxV2);
tessellator.addVertexWithUV(0.0, 1.0, 0.0, maxU2, minV2);
tessellator.addVertexWithUV(0.0, 0.75, 0.0, minU2, minV2);
tessellator.addVertexWithUV(0.0, 0.75, 1.0, minU2, maxV2);
tessellator.draw();

// portantup base up
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 1.0F, 0.0F);
tessellator.addVertexWithUV(0.0, 1.0, 0.0, maxU1, maxV1);
tessellator.addVertexWithUV(0.0, 1.0, 1.0, maxU1, minV1);
tessellator.addVertexWithUV(1.0, 1.0, 1.0, minU1, minV1);
tessellator.addVertexWithUV(1.0, 1.0, 0.0, minU1, maxV1);
tessellator.draw();

// portantup base down
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(1.0, 0.75, 0.0, minU1, maxV1);
tessellator.addVertexWithUV(1.0, 0.75, 1.0, minU1, minV1);
tessellator.addVertexWithUV(0.0, 0.75, 1.0, maxU1, minV1);
tessellator.addVertexWithUV(0.0, 0.75, 0.0, maxU1, maxV1);
tessellator.draw();

// portantdown base up
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 1.0F, 0.0F);
tessellator.addVertexWithUV(0.0, 0.25, 0.0, maxU1, maxV1);
tessellator.addVertexWithUV(0.0, 0.25, 1.0, maxU1, minV1);
tessellator.addVertexWithUV(1.0, 0.25, 1.0, minU1, minV1);
tessellator.addVertexWithUV(1.0, 0.25, 0.0, minU1, maxV1);
tessellator.draw();

// portantdown base down
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(1.0, 0.0, 0.0, minU1, maxV1);
tessellator.addVertexWithUV(1.0, 0.0, 1.0, minU1, minV1);
tessellator.addVertexWithUV(0.0, 0.0, 1.0, maxU1, minV1);
tessellator.addVertexWithUV(0.0, 0.0, 0.0, maxU1, maxV1);
tessellator.draw();

// pillar 1
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 0.0F, 1.0F);
tessellator.addVertexWithUV(0.25, 0.99, 0.25, minU3, minV3);
tessellator.addVertexWithUV(0.75, 0.99, 0.25, minU3, maxV3);
tessellator.addVertexWithUV(0.75, 0.0, 0.25, maxU3, maxV3);
tessellator.addVertexWithUV(0.25, 0.0, 0.25, maxU3, minV3);
tessellator.draw();

// pillar inverse 1
tessellator.startDrawingQuads();
tessellator.setNormal(0.0F, 0.0F, -1.0F);
tessellator.addVertexWithUV(0.75, 0.99, 0.75, minU3, minV3);
tessellator.addVertexWithUV(0.25, 0.99, 0.75, minU3, maxV3);
tessellator.addVertexWithUV(0.25, 0.0, 0.75, maxU3, maxV3);
tessellator.addVertexWithUV(0.75, 0.0, 0.75, maxU3, minV3);
tessellator.draw();

// pillar 2
tessellator.startDrawingQuads();
tessellator.setNormal(-1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(0.25, 0.99, 0.75, minU3, minV3);
tessellator.addVertexWithUV(0.25, 0.99, 0.25, minU3, maxV3);
tessellator.addVertexWithUV(0.25, 0.0, 0.25, maxU3, maxV3);
tessellator.addVertexWithUV(0.25, 0.0, 0.75, maxU3, minV3);
tessellator.draw();

// pillar inverse 2
tessellator.startDrawingQuads();
tessellator.setNormal(1.0F, 0.0F, 0.0F);
tessellator.addVertexWithUV(0.75, 0.99, 0.25, minU3, minV3);
tessellator.addVertexWithUV(0.75, 0.99, 0.75, minU3, maxV3);
tessellator.addVertexWithUV(0.75, 0.0, 0.75, maxU3, maxV3);
tessellator.addVertexWithUV(0.75, 0.0, 0.25, maxU3, minV3);
tessellator.draw();

    GL11.glTranslatef(0.5F, 0.5F, 0.5F);
}

    public boolean renderWorldBlock(IBlockAccess world, int x, int y, int z, Block block, int modelId, RenderBlocks renderer)
    {
	Tessellator tessellator = Tessellator.instance;
	int lightValue = block.getMixedBrightnessForBlock(world, x, y, z);
	tessellator.setBrightness(lightValue);
	tessellator.setColorOpaque_F(1.0F, 1.0F, 1.0F);

	if (world.getBlockMetadata(x, y, z) == 3)
	{
	renderColumnFull(tessellator, (double)x, (double)y, (double) z);
	}
	else if (world.getBlockMetadata(x, y, z) == 2)
	{
	renderColumnDown(tessellator, (double)x, (double)y, (double) z);
	} 
	else if (world.getBlockMetadata(x, y, z) == 1)
	{
	renderColumnUp(tessellator, (double)x, (double)y, (double) z);
	}
	else
	{
	renderColumnCenter(tessellator, (double)x, (double)y, (double) z);
	} 

	aModel.ColumnDown.showModel = false;
	aModel.ColumnUp.showModel = false;
	aModel.ColumnFull.showModel = false;
	aModel.PortantUp.showModel = true;
	aModel.PortantDown.showModel = true;
	aModel.ColumnCenter.showModel = true;

	return true;


	//aModel.ColumnDown.showModel = false;
	//aModel.ColumnUp.showModel = false;
	//aModel.ColumnFull.showModel = false;
	//aModel.PortantUp.showModel = true;
	//aModel.PortantDown.showModel = true;
	//aModel.ColumnCenter.showModel = true;

	//GL11.glBindTexture(GL11.GL_TEXTURE_2D, 2);
	//GL11.glPushMatrix();
	//GL11.glTranslatef((float)x + 0.5F, (float)y - 0.50F, (float)z + 0.5F);
	//GL11.glRotatef(0, 0F, 0F, 0F);
	//GL11.glPushMatrix();
	//aModel.renderModel(0.0625F);
	//GL11.glPopMatrix();
	//GL11.glPopMatrix();

	//tessellator.startDrawingQuads();
	//tessellator.setNormal(0.0F, -1.0F, 0.0F);
	//tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, minU1, maxV1);
	//tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, minU1, minV1);
	//tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU1, minV1);
	//tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU1, maxV1);
}

    public boolean shouldRender3DInInventory(){ return true; }

@Override
public int getRenderId()
{
	return 0;
}

private void renderColumnFull(Tessellator tessellator, double x, double y, double z) {

    double minU2 = (double)getColumnIcon(0).getMinU();
    double minV2 = (double)getColumnIcon(0).getMinV();
    double maxU2 = (double)getColumnIcon(0).getMaxU();
    double maxV2 = (double)getColumnIcon(0).getMaxV();
    double minU1 = (double)getColumnIcon(1).getMinU();
    double minV1 = (double)getColumnIcon(1).getMinV();
    double maxU1 = (double)getColumnIcon(1).getMaxU();
    double maxV1 = (double)getColumnIcon(1).getMaxV();
double minU3 = (double)getColumnIcon(2).getMinU();
    double minV3 = (double)getColumnIcon(2).getMinV();
    double maxU3 = (double)getColumnIcon(2).getMaxU();
    double maxV3 = (double)getColumnIcon(2).getMaxV();

// portantdown face 1
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face inverse 1
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face 2
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face inverse 2
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup base up
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU1, maxV1);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, minU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup base down
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU1, maxV1);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, maxU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown base up
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, maxU1, maxV1);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown base down
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, minU1, maxV1);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();
  }
  
  private void renderColumnUp(Tessellator tessellator, double x, double y, double z) {

    double minU2 = (double)getColumnIcon(0).getMinU();
    double minV2 = (double)getColumnIcon(0).getMinV();
    double maxU2 = (double)getColumnIcon(0).getMaxU();
    double maxV2 = (double)getColumnIcon(0).getMaxV();
    double minU1 = (double)getColumnIcon(1).getMinU();
    double minV1 = (double)getColumnIcon(1).getMinV();
    double maxU1 = (double)getColumnIcon(1).getMaxU();
    double maxV1 = (double)getColumnIcon(1).getMaxV();
double minU3 = (double)getColumnIcon(2).getMinU();
    double minV3 = (double)getColumnIcon(2).getMinV();
    double maxU3 = (double)getColumnIcon(2).getMaxU();
    double maxV3 = (double)getColumnIcon(2).getMaxV();

// portantup face 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup face inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup base up
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+0.0, maxU1, maxV1);
tessellator.addVertexWithUV(x+0.0, y+1.0, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+1.0, z+0.0, minU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// portantup base down
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+0.0, minU1, maxV1);
tessellator.addVertexWithUV(x+1.0, y+0.75, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.75, z+0.0, maxU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();
  }
  
  private void renderColumnDown(Tessellator tessellator, double x, double y, double z) {

    double minU2 = (double)getColumnIcon(0).getMinU();
    double minV2 = (double)getColumnIcon(0).getMinV();
    double maxU2 = (double)getColumnIcon(0).getMaxU();
    double maxV2 = (double)getColumnIcon(0).getMaxV();
    double minU1 = (double)getColumnIcon(1).getMinU();
    double minV1 = (double)getColumnIcon(1).getMinV();
    double maxU1 = (double)getColumnIcon(1).getMaxU();
    double maxV1 = (double)getColumnIcon(1).getMaxV();
double minU3 = (double)getColumnIcon(2).getMinU();
    double minV3 = (double)getColumnIcon(2).getMinV();
    double maxU3 = (double)getColumnIcon(2).getMaxU();
    double maxV3 = (double)getColumnIcon(2).getMaxV();

// portantdown face 1
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face inverse 1
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face 2
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown face inverse 2
    tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, maxU2, maxV2);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, maxU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU2, minV2);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU2, maxV2);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown base up
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+0.0, maxU1, maxV1);
tessellator.addVertexWithUV(x+0.0, y+0.25, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+1.0, y+0.25, z+0.0, minU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// portantdown base down
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+0.0, minU1, maxV1);
tessellator.addVertexWithUV(x+1.0, y+0.0, z+1.0, minU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+1.0, maxU1, minV1);
tessellator.addVertexWithUV(x+0.0, y+0.0, z+0.0, maxU1, maxV1);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();
  }
  
  private void renderColumnCenter(Tessellator tessellator, double x, double y, double z) {

    double minU2 = (double)getColumnIcon(0).getMinU();
    double minV2 = (double)getColumnIcon(0).getMinV();
    double maxU2 = (double)getColumnIcon(0).getMaxU();
    double maxV2 = (double)getColumnIcon(0).getMaxV();
    double minU1 = (double)getColumnIcon(1).getMinU();
    double minV1 = (double)getColumnIcon(1).getMinV();
    double maxU1 = (double)getColumnIcon(1).getMaxU();
    double maxV1 = (double)getColumnIcon(1).getMaxV();
double minU3 = (double)getColumnIcon(2).getMinU();
    double minV3 = (double)getColumnIcon(2).getMinV();
    double maxU3 = (double)getColumnIcon(2).getMaxU();
    double maxV3 = (double)getColumnIcon(2).getMaxV();

// pillar 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 1
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.75, minU3, minV3);
tessellator.addVertexWithUV(x+0.25, y+1.0, z+0.25, minU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.25, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.25, y+0.0, z+0.75, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();

// pillar inverse 2
tessellator.setNormal(0.0F, -1.0F, 0.0F);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.25, minU3, minV3);
tessellator.addVertexWithUV(x+0.75, y+1.0, z+0.75, minU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.75, maxU3, maxV3);
tessellator.addVertexWithUV(x+0.75, y+0.0, z+0.25, maxU3, minV3);
tessellator.draw();
tessellator.startDrawingQuads();
  }
}

 

Actually i don't know what to write in this signature soooo.... anyway

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.