Puts everywhere brackets
This commit is contained in:
@@ -266,7 +266,9 @@ public class RenderBlockAssembler extends BaseBlockRender implements IBoxProvide
|
||||
if( pc.isConnected( side.getOpposite() ) )
|
||||
{
|
||||
if( covered )
|
||||
{
|
||||
return pc.getCoveredTexture( pc.getCableColor() );
|
||||
}
|
||||
return pc.getGlassTexture( pc.getCableColor() );
|
||||
}
|
||||
}
|
||||
|
||||
@@ -130,7 +130,9 @@ public class RenderBlockCharger extends BaseBlockRender
|
||||
{
|
||||
ItemStack sis = null;
|
||||
if( tile instanceof IInventory )
|
||||
{
|
||||
sis = ( (IInventory) tile ).getStackInSlot( 0 );
|
||||
}
|
||||
|
||||
if( sis != null )
|
||||
{
|
||||
|
||||
@@ -58,12 +58,18 @@ public class RenderBlockController extends BaseBlockRender
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumnPowered.getIcon() );
|
||||
if( isConflict )
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnConflict;
|
||||
}
|
||||
else
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnLights;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumn.getIcon() );
|
||||
}
|
||||
|
||||
renderer.uvRotateEast = 1;
|
||||
renderer.uvRotateWest = 1;
|
||||
@@ -76,12 +82,18 @@ public class RenderBlockController extends BaseBlockRender
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumnPowered.getIcon() );
|
||||
if( isConflict )
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnConflict;
|
||||
}
|
||||
else
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnLights;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumn.getIcon() );
|
||||
}
|
||||
|
||||
renderer.uvRotateEast = 0;
|
||||
renderer.uvRotateNorth = 0;
|
||||
@@ -92,12 +104,18 @@ public class RenderBlockController extends BaseBlockRender
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumnPowered.getIcon() );
|
||||
if( isConflict )
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnConflict;
|
||||
}
|
||||
else
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerColumnLights;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerColumn.getIcon() );
|
||||
}
|
||||
|
||||
renderer.uvRotateNorth = 1;
|
||||
renderer.uvRotateSouth = 1;
|
||||
@@ -109,9 +127,13 @@ public class RenderBlockController extends BaseBlockRender
|
||||
renderer.uvRotateEast = renderer.uvRotateBottom = renderer.uvRotateNorth = renderer.uvRotateSouth = renderer.uvRotateTop = renderer.uvRotateWest = 0;
|
||||
|
||||
if( v == 0 )
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerInsideA.getIcon() );
|
||||
}
|
||||
else
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerInsideB.getIcon() );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -119,12 +141,18 @@ public class RenderBlockController extends BaseBlockRender
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( ExtraBlockTextures.BlockControllerPowered.getIcon() );
|
||||
if( isConflict )
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerConflict;
|
||||
}
|
||||
else
|
||||
{
|
||||
lights = ExtraBlockTextures.BlockControllerLights;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
blk.getRendererInstance().setTemporaryRenderIcon( null );
|
||||
}
|
||||
}
|
||||
|
||||
boolean out = renderer.renderStandardBlock( blk, x, y, z );
|
||||
@@ -148,7 +176,9 @@ public class RenderBlockController extends BaseBlockRender
|
||||
private TileEntity getTileEntity( IBlockAccess world, int x, int y, int z )
|
||||
{
|
||||
if( y >= 0 )
|
||||
{
|
||||
return world.getTileEntity( x, y, z );
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -126,7 +126,9 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
|
||||
boolean LocalEmit = emitsLight;
|
||||
if( blk instanceof BlockCraftingMonitor && ct.getForward() != side )
|
||||
{
|
||||
LocalEmit = false;
|
||||
}
|
||||
|
||||
this.handleSide( blk, meta, x, y, z, i, renderer, ct.getForward() == side ? theIcon : nonForward, LocalEmit, isMonitor, side, w );
|
||||
}
|
||||
@@ -165,11 +167,17 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
private void renderCorner( BusRenderHelper i, RenderBlocks renderer, IBlockAccess w, int x, int y, int z, ForgeDirection up, ForgeDirection east, ForgeDirection south )
|
||||
{
|
||||
if( this.isConnected( w, x, y, z, up ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
if( this.isConnected( w, x, y, z, east ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
if( this.isConnected( w, x, y, z, south ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
i.setBounds( this.gso( east, 3, ForgeDirection.WEST ), this.gso( up, 3, ForgeDirection.DOWN ), this.gso( south, 3, ForgeDirection.NORTH ), this.gso( east, 13, ForgeDirection.EAST ), this.gso( up, 13, ForgeDirection.UP ), this.gso( south, 13, ForgeDirection.SOUTH ) );
|
||||
i.prepareBounds( renderer );
|
||||
@@ -182,7 +190,9 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
if( side == target )
|
||||
{
|
||||
if( side.offsetX > 0 || side.offsetY > 0 || side.offsetZ > 0 )
|
||||
{
|
||||
return 16;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
return def;
|
||||
@@ -191,7 +201,9 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
private void handleSide( AEBaseBlock blk, int meta, int x, int y, int z, BusRenderHelper i, RenderBlocks renderer, IIcon color, boolean emitsLight, boolean isMonitor, ForgeDirection side, IBlockAccess w )
|
||||
{
|
||||
if( this.isConnected( w, x, y, z, side ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
i.setFacesToRender( EnumSet.of( side ) );
|
||||
|
||||
@@ -203,9 +215,13 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
else
|
||||
{
|
||||
if( color == ExtraBlockTextures.BlockCraftingMonitorFit_Light.getIcon() )
|
||||
{
|
||||
i.setTexture( ExtraBlockTextures.BlockCraftingMonitorOuter.getIcon() );
|
||||
}
|
||||
else
|
||||
{
|
||||
i.setTexture( ExtraBlockTextures.BlockCraftingFitSolid.getIcon() );
|
||||
}
|
||||
|
||||
i.renderBlockCurrentBounds( x, y, z, renderer );
|
||||
|
||||
@@ -233,7 +249,9 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
i.renderFace( x, y, z, ExtraBlockTextures.BlockCraftingMonitorFit_Dark.getIcon(), side, renderer );
|
||||
}
|
||||
else
|
||||
{
|
||||
i.renderBlockCurrentBounds( x, y, z, renderer );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -267,14 +285,22 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
for( ForgeDirection a : ForgeDirection.VALID_DIRECTIONS )
|
||||
{
|
||||
if( a == side || a == side.getOpposite() )
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if( ( side.offsetX != 0 || side.offsetZ != 0 ) && ( a == ForgeDirection.NORTH || a == ForgeDirection.EAST || a == ForgeDirection.WEST || a == ForgeDirection.SOUTH ) )
|
||||
{
|
||||
i.setTexture( ExtraBlockTextures.BlockCraftingUnitRingLongRotated.getIcon() );
|
||||
}
|
||||
else if( ( side.offsetY != 0 ) && ( a == ForgeDirection.EAST || a == ForgeDirection.WEST ) )
|
||||
{
|
||||
i.setTexture( ExtraBlockTextures.BlockCraftingUnitRingLongRotated.getIcon() );
|
||||
}
|
||||
else
|
||||
{
|
||||
i.setTexture( ExtraBlockTextures.BlockCraftingUnitRingLong.getIcon() );
|
||||
}
|
||||
|
||||
double width = 3.0 / 16.0;
|
||||
|
||||
@@ -334,7 +360,9 @@ public class RenderBlockCraftingCPU extends BaseBlockRender
|
||||
if( side != target )
|
||||
{
|
||||
if( side.offsetX > 0 || side.offsetY > 0 || side.offsetZ > 0 )
|
||||
{
|
||||
return 16;
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
return def;
|
||||
|
||||
@@ -84,7 +84,9 @@ public class RenderBlockCraftingCPUMonitor extends RenderBlockCraftingCPU
|
||||
GL11.glEndList();
|
||||
}
|
||||
else
|
||||
{
|
||||
GL11.glCallList( cmt.dspList );
|
||||
}
|
||||
|
||||
GL11.glPopMatrix();
|
||||
}
|
||||
|
||||
@@ -70,15 +70,21 @@ public class RenderBlockCrank extends BaseBlockRender
|
||||
{
|
||||
TileCrank tc = (TileCrank) tile;
|
||||
if( tc.getUp() == null || tc.getUp() == ForgeDirection.UNKNOWN )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture( TextureMap.locationBlocksTexture );
|
||||
RenderHelper.disableStandardItemLighting();
|
||||
|
||||
if( Minecraft.isAmbientOcclusionEnabled() )
|
||||
{
|
||||
GL11.glShadeModel( GL11.GL_SMOOTH );
|
||||
}
|
||||
else
|
||||
{
|
||||
GL11.glShadeModel( GL11.GL_FLAT );
|
||||
}
|
||||
|
||||
GL11.glColor4f( 1.0f, 1.0f, 1.0f, 1.0f );
|
||||
|
||||
|
||||
@@ -47,9 +47,13 @@ public class RenderBlockEnergyCube extends BaseBlockRender
|
||||
int meta = (int) ( 8.0 * ( internalCurrentPower / internalMaxPower ) );
|
||||
|
||||
if( meta > 7 )
|
||||
{
|
||||
meta = 7;
|
||||
}
|
||||
if( meta < 0 )
|
||||
{
|
||||
meta = 0;
|
||||
}
|
||||
|
||||
renderer.setOverrideBlockTexture( blk.getIcon( 0, meta ) );
|
||||
super.renderInventory( blk, is, renderer, type, obj );
|
||||
|
||||
@@ -112,7 +112,9 @@ public class RenderBlockInscriber extends BaseBlockRender
|
||||
|
||||
IOrientable te = this.getOrientable( block, world, x, y, z );
|
||||
if( te == null )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
ForgeDirection fdy = te.getUp();
|
||||
ForgeDirection fdz = te.getForward();
|
||||
@@ -178,14 +180,18 @@ public class RenderBlockInscriber extends BaseBlockRender
|
||||
long currentTime = System.currentTimeMillis();
|
||||
absoluteProgress = currentTime - inv.clientStart;
|
||||
if( absoluteProgress > 800 )
|
||||
{
|
||||
inv.smash = false;
|
||||
}
|
||||
}
|
||||
|
||||
float relativeProgress = absoluteProgress % 800 / 400.0f;
|
||||
float progress = relativeProgress;
|
||||
|
||||
if( progress > 1.0f )
|
||||
{
|
||||
progress = 1.0f - ( progress - 1.0f );
|
||||
}
|
||||
press -= progress / 5.0f;
|
||||
|
||||
IIcon ic = ExtraBlockTextures.BlockInscriberInside.getIcon();
|
||||
@@ -219,11 +225,17 @@ public class RenderBlockInscriber extends BaseBlockRender
|
||||
|
||||
int items = 0;
|
||||
if( inv.getStackInSlot( 0 ) != null )
|
||||
{
|
||||
items++;
|
||||
}
|
||||
if( inv.getStackInSlot( 1 ) != null )
|
||||
{
|
||||
items++;
|
||||
}
|
||||
if( inv.getStackInSlot( 2 ) != null )
|
||||
{
|
||||
items++;
|
||||
}
|
||||
|
||||
if( relativeProgress > 1.0f || items == 0 )
|
||||
{
|
||||
@@ -233,7 +245,9 @@ public class RenderBlockInscriber extends BaseBlockRender
|
||||
{
|
||||
IInscriberRecipe ir = inv.getTask();
|
||||
if( ir != null )
|
||||
{
|
||||
is = ir.getOutput().copy();
|
||||
}
|
||||
}
|
||||
|
||||
this.renderItem( is, 0.0f, block, tile, tess, x, y, z, f, renderer );
|
||||
|
||||
@@ -73,13 +73,17 @@ public class RenderBlockPaint extends BaseBlockRender
|
||||
for( ForgeDirection side : ForgeDirection.VALID_DIRECTIONS )
|
||||
{
|
||||
if( tp.isSideValid( side ) )
|
||||
{
|
||||
validSides.add( side );
|
||||
}
|
||||
}
|
||||
|
||||
for( Splotch s : tp.getDots() )
|
||||
{
|
||||
if( !validSides.contains( s.side ) )
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
if( s.lumen )
|
||||
{
|
||||
|
||||
@@ -54,9 +54,13 @@ public class RenderBlockSkyChest extends BaseBlockRender
|
||||
|
||||
ResourceLocation loc;
|
||||
if( is.getItemDamage() == 1 )
|
||||
{
|
||||
loc = new ResourceLocation( "appliedenergistics2", "textures/models/skyblockchest.png" );
|
||||
}
|
||||
else
|
||||
{
|
||||
loc = new ResourceLocation( "appliedenergistics2", "textures/models/skychest.png" );
|
||||
}
|
||||
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture( loc );
|
||||
|
||||
@@ -83,12 +87,16 @@ public class RenderBlockSkyChest extends BaseBlockRender
|
||||
public void renderTile( AEBaseBlock block, AEBaseTile tile, Tessellator tess, double x, double y, double z, float partialTick, RenderBlocks renderer )
|
||||
{
|
||||
if( !( tile instanceof TileSkyChest ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
TileSkyChest skyChest = (TileSkyChest) tile;
|
||||
|
||||
if( !skyChest.hasWorldObj() )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
GL11.glEnable( 32826 /* GL_RESCALE_NORMAL_EXT */ );
|
||||
GL11.glColor4f( 1.0F, 1.0F, 1.0F, 1.0F );
|
||||
@@ -96,9 +104,13 @@ public class RenderBlockSkyChest extends BaseBlockRender
|
||||
ResourceLocation loc;
|
||||
|
||||
if( tile.getWorldObj().getBlockMetadata( tile.xCoord, tile.yCoord, tile.zCoord ) == 1 )
|
||||
{
|
||||
loc = new ResourceLocation( "appliedenergistics2", "textures/models/skyblockchest.png" );
|
||||
}
|
||||
else
|
||||
{
|
||||
loc = new ResourceLocation( "appliedenergistics2", "textures/models/skychest.png" );
|
||||
}
|
||||
|
||||
Minecraft.getMinecraft().getTextureManager().bindTexture( loc );
|
||||
|
||||
@@ -111,15 +123,23 @@ public class RenderBlockSkyChest extends BaseBlockRender
|
||||
long distance = now - skyChest.lastEvent;
|
||||
|
||||
if( skyChest.playerOpen > 0 )
|
||||
{
|
||||
skyChest.lidAngle += distance * 0.0001;
|
||||
}
|
||||
else
|
||||
{
|
||||
skyChest.lidAngle -= distance * 0.0001;
|
||||
}
|
||||
|
||||
if( skyChest.lidAngle > 0.5f )
|
||||
{
|
||||
skyChest.lidAngle = 0.5f;
|
||||
}
|
||||
|
||||
if( skyChest.lidAngle < 0.0f )
|
||||
{
|
||||
skyChest.lidAngle = 0.0f;
|
||||
}
|
||||
|
||||
float lidAngle = skyChest.lidAngle;
|
||||
lidAngle = 1.0F - lidAngle;
|
||||
|
||||
@@ -61,11 +61,17 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
|
||||
IInventory inv = Minecraft.getMinecraft().thePlayer.inventory;
|
||||
for( int x = 0; x < inv.getSizeInventory(); x++ )
|
||||
{
|
||||
if( inv.getStackInSlot( x ) == is )
|
||||
{
|
||||
isGood = true;
|
||||
}
|
||||
}
|
||||
|
||||
if( !isGood )
|
||||
{
|
||||
type = ItemRenderType.FIRST_PERSON_MAP;
|
||||
}
|
||||
}
|
||||
|
||||
GL11.glEnable( 32826 /* GL_RESCALE_NORMAL_EXT */ );
|
||||
@@ -85,15 +91,21 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
else
|
||||
{
|
||||
if( type == ItemRenderType.EQUIPPED_FIRST_PERSON )
|
||||
{
|
||||
GL11.glRotatef( 15.3f, 0.0f, 0.0f, 1.0f );
|
||||
}
|
||||
|
||||
GL11.glScalef( 1.0F, -1F, -1F );
|
||||
GL11.glScalef( 2.5f, 2.5f, 2.5f );
|
||||
|
||||
if( type == ItemRenderType.EQUIPPED_FIRST_PERSON )
|
||||
{
|
||||
GL11.glTranslatef( 0.3F, -1.65F, -0.19F );
|
||||
}
|
||||
else
|
||||
{
|
||||
GL11.glTranslatef( 0.2F, -1.65F, -0.19F );
|
||||
}
|
||||
}
|
||||
|
||||
long now = System.currentTimeMillis();
|
||||
@@ -114,8 +126,12 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
CompassResult cr = CompassManager.INSTANCE.getCompassDirection( 0, x, y, z );
|
||||
|
||||
for( int i = 0; i < 3; i++ )
|
||||
{
|
||||
for( int j = 0; j < 3; j++ )
|
||||
{
|
||||
CompassManager.INSTANCE.getCompassDirection( 0, x + i - 1, y, z + j - 1 );
|
||||
}
|
||||
}
|
||||
|
||||
if( cr.hasResult )
|
||||
{
|
||||
@@ -166,12 +182,16 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
public void renderTile( AEBaseBlock block, AEBaseTile tile, Tessellator tess, double x, double y, double z, float partialTick, RenderBlocks renderer )
|
||||
{
|
||||
if( !( tile instanceof TileSkyCompass ) )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
TileSkyCompass skyCompass = (TileSkyCompass) tile;
|
||||
|
||||
if( !skyCompass.hasWorldObj() )
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
GL11.glEnable( 32826 /* GL_RESCALE_NORMAL_EXT */ );
|
||||
GL11.glColor4f( 1.0F, 1.0F, 1.0F, 1.0F );
|
||||
@@ -189,9 +209,13 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
|
||||
CompassResult cr = null;
|
||||
if( skyCompass.getForward() == ForgeDirection.UP || skyCompass.getForward() == ForgeDirection.DOWN )
|
||||
{
|
||||
cr = CompassManager.INSTANCE.getCompassDirection( 0, tile.xCoord, tile.yCoord, tile.zCoord );
|
||||
}
|
||||
else
|
||||
{
|
||||
cr = new CompassResult( false, true, 0 );
|
||||
}
|
||||
|
||||
if( cr.hasResult )
|
||||
{
|
||||
@@ -201,7 +225,9 @@ public class RenderBlockSkyCompass extends BaseBlockRender
|
||||
this.model.renderAll( ( now / 50000.0f ) * (float) Math.PI * 500.0f );
|
||||
}
|
||||
else
|
||||
{
|
||||
this.model.renderAll( (float) ( skyCompass.getForward() == ForgeDirection.DOWN ? this.flipidiy( cr.rad ) : cr.rad ) );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -185,17 +185,29 @@ public class RenderBlockWireless extends BaseBlockRender
|
||||
}
|
||||
|
||||
if( ForgeDirection.UP != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.UP );
|
||||
}
|
||||
if( ForgeDirection.DOWN != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.DOWN );
|
||||
}
|
||||
if( ForgeDirection.EAST != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.EAST );
|
||||
}
|
||||
if( ForgeDirection.WEST != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.WEST );
|
||||
}
|
||||
if( ForgeDirection.SOUTH != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.SOUTH );
|
||||
}
|
||||
if( ForgeDirection.NORTH != fdz.getOpposite() )
|
||||
{
|
||||
super.renderFace( x, y, z, blk, r, renderer, ForgeDirection.NORTH );
|
||||
}
|
||||
|
||||
ri.setTemporaryRenderIcon( null );
|
||||
renderer.renderAllFaces = false;
|
||||
|
||||
@@ -253,9 +253,13 @@ public class RenderDrive extends BaseBlockRender
|
||||
}
|
||||
|
||||
if( ( forward == ForgeDirection.UP && up == ForgeDirection.SOUTH ) || forward == ForgeDirection.DOWN )
|
||||
{
|
||||
this.selectFace( renderer, west, up, forward, 3 + xx * 7, 4 + xx * 7, 1 + yy * 3, 2 + yy * 3 );
|
||||
}
|
||||
else
|
||||
{
|
||||
this.selectFace( renderer, west, up, forward, 5 + xx * 7, 6 + xx * 7, 2 + yy * 3, 3 + yy * 3 );
|
||||
}
|
||||
|
||||
if( stat != 0 )
|
||||
{
|
||||
@@ -271,16 +275,26 @@ public class RenderDrive extends BaseBlockRender
|
||||
v4 = whiteIcon.getInterpolatedV( ( ( spin ) % 4 < 2 ) ? 1 : 3 );
|
||||
|
||||
if( sp.isPowered() )
|
||||
{
|
||||
tess.setBrightness( 15 << 20 | 15 << 4 );
|
||||
}
|
||||
else
|
||||
{
|
||||
tess.setBrightness( 0 );
|
||||
}
|
||||
|
||||
if( stat == 1 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0x00ff00 );
|
||||
}
|
||||
if( stat == 2 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0xffaa00 );
|
||||
}
|
||||
if( stat == 3 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0xff0000 );
|
||||
}
|
||||
|
||||
switch( forward.offsetX + forward.offsetY * 2 + forward.offsetZ * 3 )
|
||||
{
|
||||
|
||||
@@ -70,7 +70,9 @@ public class RenderMEChest extends BaseBlockRender
|
||||
renderer.setRenderBounds( 0, 0, 0, 1, 1, 1 );
|
||||
|
||||
if( sp == null )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
ForgeDirection up = sp.getUp();
|
||||
ForgeDirection forward = sp.getForward();
|
||||
@@ -86,7 +88,9 @@ public class RenderMEChest extends BaseBlockRender
|
||||
int offsetU = -4;
|
||||
int offsetV = 8;
|
||||
if( stat == 0 )
|
||||
{
|
||||
offsetV = 3;
|
||||
}
|
||||
|
||||
int b = world.getLightBrightnessForSkyBlocks( x + forward.offsetX, y + forward.offsetY, z + forward.offsetZ, 0 );
|
||||
Tessellator.instance.setBrightness( b );
|
||||
@@ -94,15 +98,25 @@ public class RenderMEChest extends BaseBlockRender
|
||||
|
||||
FlippableIcon flippableIcon = new FlippableIcon( new OffsetIcon( ExtraBlockTextures.MEStorageCellTextures.getIcon(), offsetU, offsetV ) );
|
||||
if( forward == ForgeDirection.EAST && ( up == ForgeDirection.NORTH || up == ForgeDirection.SOUTH ) )
|
||||
{
|
||||
flippableIcon.setFlip( true, false );
|
||||
}
|
||||
else if( forward == ForgeDirection.NORTH && up == ForgeDirection.EAST )
|
||||
{
|
||||
flippableIcon.setFlip( false, true );
|
||||
}
|
||||
else if( forward == ForgeDirection.NORTH && up == ForgeDirection.WEST )
|
||||
{
|
||||
flippableIcon.setFlip( true, false );
|
||||
}
|
||||
else if( forward == ForgeDirection.DOWN && up == ForgeDirection.EAST )
|
||||
{
|
||||
flippableIcon.setFlip( false, true );
|
||||
}
|
||||
else if( forward == ForgeDirection.DOWN )
|
||||
{
|
||||
flippableIcon.setFlip( true, false );
|
||||
}
|
||||
|
||||
/*
|
||||
* 1.7.2
|
||||
@@ -123,11 +137,17 @@ public class RenderMEChest extends BaseBlockRender
|
||||
|
||||
Tessellator.instance.setBrightness( b );
|
||||
if( stat == 1 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0x00ff00 );
|
||||
}
|
||||
if( stat == 2 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0xffaa00 );
|
||||
}
|
||||
if( stat == 3 )
|
||||
{
|
||||
Tessellator.instance.setColorOpaque_I( 0xff0000 );
|
||||
}
|
||||
this.selectFace( renderer, west, up, forward, 9, 10, 11, 12 );
|
||||
this.renderFace( x, y, z, imb, ExtraBlockTextures.White.getIcon(), renderer, forward );
|
||||
}
|
||||
|
||||
@@ -61,7 +61,9 @@ public class RenderQNB extends BaseBlockRender
|
||||
{
|
||||
TileQuantumBridge tqb = block.getTileEntity( world, x, y, z );
|
||||
if( tqb == null )
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
renderer.renderAllFaces = true;
|
||||
|
||||
@@ -120,7 +122,9 @@ public class RenderQNB extends BaseBlockRender
|
||||
Tessellator.instance.setColorOpaque_F( 1.0F, 1.0F, 1.0F );
|
||||
Tessellator.instance.setBrightness( bn << 20 | bn << 4 );
|
||||
for( ForgeDirection side : ForgeDirection.VALID_DIRECTIONS )
|
||||
{
|
||||
this.renderFace( x, y, z, block, ExtraBlockTextures.BlockQRingCornerLight.getIcon(), renderer, side );
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -146,7 +150,9 @@ public class RenderQNB extends BaseBlockRender
|
||||
Tessellator.instance.setColorOpaque_F( 1.0F, 1.0F, 1.0F );
|
||||
Tessellator.instance.setBrightness( bn << 20 | bn << 4 );
|
||||
for( ForgeDirection side : ForgeDirection.VALID_DIRECTIONS )
|
||||
{
|
||||
this.renderFace( x, y, z, block, ExtraBlockTextures.BlockQRingEdgeLight.getIcon(), renderer, side );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,8 +47,12 @@ public class RenderQuartzGlass extends BaseBlockRender
|
||||
Random r = new Random( 924 );
|
||||
offsets = new byte[10][10][10];
|
||||
for( int x = 0; x < 10; x++ )
|
||||
{
|
||||
for( int y = 0; y < 10; y++ )
|
||||
{
|
||||
r.nextBytes( offsets[x][y] );
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -155,18 +159,30 @@ public class RenderQuartzGlass extends BaseBlockRender
|
||||
}
|
||||
|
||||
if( maxX <= 0.001f )
|
||||
{
|
||||
maxX += 0.9f / 16.0f;
|
||||
}
|
||||
if( maxY <= 0.001f )
|
||||
{
|
||||
maxY += 0.9f / 16.0f;
|
||||
}
|
||||
if( maxZ <= 0.001f )
|
||||
{
|
||||
maxZ += 0.9f / 16.0f;
|
||||
}
|
||||
|
||||
if( minX >= 0.999f )
|
||||
{
|
||||
minX -= 0.9f / 16.0f;
|
||||
}
|
||||
if( minY >= 0.999f )
|
||||
{
|
||||
minY -= 0.9f / 16.0f;
|
||||
}
|
||||
if( minZ >= 0.999f )
|
||||
{
|
||||
minZ -= 0.9f / 16.0f;
|
||||
}
|
||||
|
||||
renderer.setRenderBounds( minX, minY, minZ, maxX, maxY, maxZ );
|
||||
|
||||
|
||||
@@ -136,7 +136,9 @@ public class RenderSpatialPylon extends BaseBlockRender
|
||||
Tessellator.instance.setColorOpaque_I( 0xffffff );
|
||||
|
||||
for( ForgeDirection d : ForgeDirection.VALID_DIRECTIONS )
|
||||
{
|
||||
this.renderFace( x, y, z, imb, this.getBlockTextureFromSideInside( imb, sp, displayBits, ori, d ), renderer, d );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -166,16 +168,22 @@ public class RenderSpatialPylon extends BaseBlockRender
|
||||
{
|
||||
|
||||
if( ori == dir || ori.getOpposite() == dir )
|
||||
{
|
||||
return blk.getRendererInstance().getTexture( dir );
|
||||
}
|
||||
|
||||
if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_MIDDLE )
|
||||
{
|
||||
return ExtraBlockTextures.BlockSpatialPylonC.getIcon();
|
||||
|
||||
}
|
||||
else if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_END_MIN )
|
||||
{
|
||||
return ExtraBlockTextures.BlockSpatialPylonE.getIcon();
|
||||
|
||||
}
|
||||
else if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_END_MAX )
|
||||
{
|
||||
return ExtraBlockTextures.BlockSpatialPylonE.getIcon();
|
||||
}
|
||||
|
||||
return blk.getIcon( 0, 0 );
|
||||
}
|
||||
@@ -185,16 +193,22 @@ public class RenderSpatialPylon extends BaseBlockRender
|
||||
boolean good = ( displayBits & sp.DISPLAY_ENABLED ) == sp.DISPLAY_ENABLED;
|
||||
|
||||
if( ori == dir || ori.getOpposite() == dir )
|
||||
{
|
||||
return good ? ExtraBlockTextures.BlockSpatialPylon_dim.getIcon() : ExtraBlockTextures.BlockSpatialPylon_red.getIcon();
|
||||
}
|
||||
|
||||
if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_MIDDLE )
|
||||
{
|
||||
return good ? ExtraBlockTextures.BlockSpatialPylonC_dim.getIcon() : ExtraBlockTextures.BlockSpatialPylonC_red.getIcon();
|
||||
|
||||
}
|
||||
else if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_END_MIN )
|
||||
{
|
||||
return good ? ExtraBlockTextures.BlockSpatialPylonE_dim.getIcon() : ExtraBlockTextures.BlockSpatialPylonE_red.getIcon();
|
||||
|
||||
}
|
||||
else if( ( displayBits & sp.DISPLAY_MIDDLE ) == sp.DISPLAY_END_MAX )
|
||||
{
|
||||
return good ? ExtraBlockTextures.BlockSpatialPylonE_dim.getIcon() : ExtraBlockTextures.BlockSpatialPylonE_red.getIcon();
|
||||
}
|
||||
|
||||
return blk.getIcon( 0, 0 );
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user