public void func_579_b(int p_579_1_) { GL11.glDisable(2896); GL11.glDisable(2912); Tessellator var2 = Tessellator.field_1512_a; GL11.glBindTexture(3553, this.field_945_b.field_6315_n.func_1070_a("/gui/background.png")); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); float var3 = 32.0F; var2.func_977_b(); var2.func_990_b(4210752); var2.func_983_a( 0.0D, (double) this.field_950_d, 0.0D, 0.0D, (double) ((float) this.field_950_d / var3 + (float) p_579_1_)); var2.func_983_a( (double) this.field_951_c, (double) this.field_950_d, 0.0D, (double) ((float) this.field_951_c / var3), (double) ((float) this.field_950_d / var3 + (float) p_579_1_)); var2.func_983_a( (double) this.field_951_c, 0.0D, 0.0D, (double) ((float) this.field_951_c / var3), (double) p_579_1_); var2.func_983_a(0.0D, 0.0D, 0.0D, 0.0D, (double) p_579_1_); var2.func_982_a(); }
protected void func_22015_a( EntityPlayer p_22015_1_, double p_22015_2_, double p_22015_4_, double p_22015_6_) { if (Minecraft.func_22006_t() && p_22015_1_ != this.field_191_a.field_22188_h) { float var8 = 1.6F; float var9 = 0.016666668F * var8; float var10 = p_22015_1_.func_379_d(this.field_191_a.field_22188_h); float var11 = p_22015_1_.func_381_o() ? 32.0F : 64.0F; if (var10 < var11) { String var12 = p_22015_1_.field_771_i; if (!p_22015_1_.func_381_o()) { if (p_22015_1_.func_22051_K()) { this.func_22013_a(p_22015_1_, var12, p_22015_2_, p_22015_4_ - 1.5D, p_22015_6_, 64); } else { this.func_22013_a(p_22015_1_, var12, p_22015_2_, p_22015_4_, p_22015_6_, 64); } } else { FontRenderer var13 = this.func_6329_a(); GL11.glPushMatrix(); GL11.glTranslatef( (float) p_22015_2_ + 0.0F, (float) p_22015_4_ + 2.3F, (float) p_22015_6_); GL11.glNormal3f(0.0F, 1.0F, 0.0F); GL11.glRotatef(-this.field_191_a.field_1225_i, 0.0F, 1.0F, 0.0F); GL11.glRotatef(this.field_191_a.field_1224_j, 1.0F, 0.0F, 0.0F); GL11.glScalef(-var9, -var9, var9); GL11.glDisable(2896); GL11.glTranslatef(0.0F, 0.25F / var9, 0.0F); GL11.glDepthMask(false); GL11.glEnable(3042); GL11.glBlendFunc(770, 771); Tessellator var14 = Tessellator.field_1512_a; GL11.glDisable(3553); var14.func_977_b(); int var15 = var13.func_871_a(var12) / 2; var14.func_986_a(0.0F, 0.0F, 0.0F, 0.25F); var14.func_991_a((double) (-var15 - 1), -1.0D, 0.0D); var14.func_991_a((double) (-var15 - 1), 8.0D, 0.0D); var14.func_991_a((double) (var15 + 1), 8.0D, 0.0D); var14.func_991_a((double) (var15 + 1), -1.0D, 0.0D); var14.func_982_a(); GL11.glEnable(3553); GL11.glDepthMask(true); var13.func_873_b(var12, -var13.func_871_a(var12) / 2, 0, 553648127); GL11.glEnable(2896); GL11.glDisable(3042); GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F); GL11.glPopMatrix(); } } } }
public void func_1198_a() { if (!field_1738_u) { return; } field_1762_b++; int i = field_1761_c; int j = field_1760_d; int k = field_1759_e; int l = field_1761_c + field_1758_f; int i1 = field_1760_d + field_1757_g; int j1 = field_1759_e + field_1756_h; for (int k1 = 0; k1 < 2; k1++) { field_1748_p[k1] = true; } Chunk.field_1540_a = false; HashSet hashset = new HashSet(); hashset.addAll(field_1745_B); field_1745_B.clear(); int l1 = 1; ChunkCache chunkcache = new ChunkCache(field_1763_a, i - l1, j - l1, k - l1, l + l1, i1 + l1, j1 + l1); RenderBlocks renderblocks = new RenderBlocks(chunkcache); field_40590_G = 0; int i2 = 0; do { if (i2 >= 2) { break; } boolean flag = false; boolean flag1 = false; boolean flag2 = false; for (int j2 = j; j2 < i1; j2++) { for (int k2 = k; k2 < j1; k2++) { for (int l2 = i; l2 < l; l2++) { int i3 = chunkcache.func_600_a(l2, j2, k2); if (i3 <= 0) { continue; } if (!flag2) { flag2 = true; GL11.glNewList(field_1744_C + i2, 4864); GL11.glPushMatrix(); func_1203_g(); float f = 1.000001F; GL11.glTranslatef( (float) (-field_1756_h) / 2.0F, (float) (-field_1757_g) / 2.0F, (float) (-field_1756_h) / 2.0F); GL11.glScalef(f, f, f); GL11.glTranslatef( (float) field_1756_h / 2.0F, (float) field_1757_g / 2.0F, (float) field_1756_h / 2.0F); field_1742_D.func_977_b(); field_1742_D.func_984_b(-field_1761_c, -field_1760_d, -field_1759_e); } if (i2 == 0 && Block.field_342_q[i3]) { TileEntity tileentity = chunkcache.func_603_b(l2, j2, k2); if (TileEntityRenderer.field_1554_a.func_1028_a(tileentity)) { field_1745_B.add(tileentity); } } Block block = Block.field_345_n[i3]; int j3 = block.func_234_g(); if (i2 == 0 && renderblocks.func_35927_a(l2, j2, k2, i2)) { flag1 = true; } if (j3 != i2) { flag = true; continue; } if (j3 == i2) { flag1 |= renderblocks.func_1234_a(block, l2, j2, k2); } } } } if (flag2) { field_40590_G += field_1742_D.func_982_a(); GL11.glPopMatrix(); GL11.glEndList(); field_1742_D.func_984_b(0.0D, 0.0D, 0.0D); } else { flag1 = false; } if (flag1) { field_1748_p[i2] = false; } if (!flag) { break; } i2++; } while (true); HashSet hashset1 = new HashSet(); hashset1.addAll(field_1745_B); hashset1.removeAll(hashset); field_1737_F.addAll(hashset1); hashset.removeAll(field_1745_B); field_1737_F.removeAll(hashset); field_1747_A = Chunk.field_1540_a; field_1739_E = true; }
public int func_982_a() { if (!field_1488_w) { throw new IllegalStateException("Not tesselating!"); } if (renderingChunk && subTessellators.length > 0) { boolean flag = false; for (int j = 0; j < subTessellators.length; j++) { int k = subTextures[j]; if (k <= 0) { break; } Tessellator tessellator = subTessellators[j]; if (tessellator.field_1488_w) { GL11.glBindTexture(3553, k); tessellator.func_982_a(); flag = true; } } if (flag) { GL11.glBindTexture(3553, getTerrainTexture()); } } field_1488_w = false; if (field_1505_h > 0) { field_1508_e.clear(); field_1508_e.put(field_1506_g, 0, field_1498_o); field_1509_d.position(0); field_1509_d.limit(field_1498_o * 4); if (field_1487_x) { field_1485_z = (field_1485_z + 1) % field_1496_A; ARBVertexBufferObject.glBindBufferARB(34962, field_1486_y.get(field_1485_z)); ARBVertexBufferObject.glBufferDataARB(34962, field_1509_d, 35040); } if (field_1500_m) { if (field_1487_x) { GL11.glTexCoordPointer(2, 5126, 32, 12L); } else { field_1507_f.position(3); GL11.glTexCoordPointer(2, 32, field_1507_f); } GL11.glEnableClientState(32888); } if (field_35838_p) { OpenGlHelper.func_40451_b(OpenGlHelper.field_40455_b); if (field_1487_x) { GL11.glTexCoordPointer(2, 5122, 32, 28L); } else { field_35836_g.position(14); GL11.glTexCoordPointer(2, 32, field_35836_g); } GL11.glEnableClientState(32888); OpenGlHelper.func_40451_b(OpenGlHelper.field_40457_a); } if (field_1501_l) { if (field_1487_x) { GL11.glColorPointer(4, 5121, 32, 20L); } else { field_1509_d.position(20); GL11.glColorPointer(4, true, 32, field_1509_d); } GL11.glEnableClientState(32886); } if (field_1499_n) { if (field_1487_x) { GL11.glNormalPointer(5121, 32, 24L); } else { field_1509_d.position(24); GL11.glNormalPointer(32, field_1509_d); } GL11.glEnableClientState(32885); } if (field_1487_x) { GL11.glVertexPointer(3, 5126, 32, 0L); } else { field_1507_f.position(0); GL11.glVertexPointer(3, 32, field_1507_f); } GL11.glEnableClientState(32884); if (field_1493_r == 7 && field_1511_b) { GL11.glDrawArrays(4, 0, field_1505_h); } else { GL11.glDrawArrays(field_1493_r, 0, field_1505_h); } GL11.glDisableClientState(32884); if (field_1500_m) { GL11.glDisableClientState(32888); } if (field_35838_p) { OpenGlHelper.func_40451_b(OpenGlHelper.field_40455_b); GL11.glDisableClientState(32888); OpenGlHelper.func_40451_b(OpenGlHelper.field_40457_a); } if (field_1501_l) { GL11.glDisableClientState(32886); } if (field_1499_n) { GL11.glDisableClientState(32885); } } int i = field_1498_o * 4; func_985_d(); return i; }
public void func_991_a(double p_991_1_, double p_991_3_, double p_991_5_) { if (autoGrow && field_1498_o >= field_1494_B - 32) { Config.dbg( (new StringBuilder()) .append("Expand tessellator buffer, old: ") .append(field_1494_B) .append(", new: ") .append(field_1494_B * 2) .toString()); field_1494_B *= 2; int ai[] = new int[field_1494_B]; System.arraycopy(field_1506_g, 0, ai, 0, field_1506_g.length); field_1506_g = ai; field_1509_d = GLAllocation.func_1127_b(field_1494_B * 4); field_1508_e = field_1509_d.asIntBuffer(); field_1507_f = field_1509_d.asFloatBuffer(); field_35836_g = field_1509_d.asShortBuffer(); } field_1497_p++; if (field_1493_r == 7 && field_1511_b && field_1497_p % 4 == 0) { for (int i = 0; i < 2; i++) { int j = 8 * (3 - i); if (field_1500_m) { field_1506_g[field_1498_o + 3] = field_1506_g[(field_1498_o - j) + 3]; field_1506_g[field_1498_o + 4] = field_1506_g[(field_1498_o - j) + 4]; } if (field_35838_p) { field_1506_g[field_1498_o + 7] = field_1506_g[(field_1498_o - j) + 7]; } if (field_1501_l) { field_1506_g[field_1498_o + 5] = field_1506_g[(field_1498_o - j) + 5]; } field_1506_g[field_1498_o + 0] = field_1506_g[(field_1498_o - j) + 0]; field_1506_g[field_1498_o + 1] = field_1506_g[(field_1498_o - j) + 1]; field_1506_g[field_1498_o + 2] = field_1506_g[(field_1498_o - j) + 2]; field_1505_h++; field_1498_o += 8; } } if (field_1500_m) { field_1506_g[field_1498_o + 3] = Float.floatToRawIntBits((float) field_1504_i); field_1506_g[field_1498_o + 4] = Float.floatToRawIntBits((float) field_1503_j); } if (field_35838_p) { field_1506_g[field_1498_o + 7] = field_35837_l; } if (field_1501_l) { field_1506_g[field_1498_o + 5] = field_1502_k; } if (field_1499_n) { field_1506_g[field_1498_o + 6] = field_1489_v; } field_1506_g[field_1498_o + 0] = Float.floatToRawIntBits((float) (p_991_1_ + field_1492_s)); field_1506_g[field_1498_o + 1] = Float.floatToRawIntBits((float) (p_991_3_ + field_1491_t)); field_1506_g[field_1498_o + 2] = Float.floatToRawIntBits((float) (p_991_5_ + field_1490_u)); field_1498_o += 8; field_1505_h++; if (!autoGrow && field_1497_p % 4 == 0 && field_1498_o >= field_1494_B - 32) { func_982_a(); field_1488_w = true; } }
public void func_40446_a( TileEntityEndPortal tileentityendportal, double d, double d1, double d2, float f) { float f1 = (float) field_6509_a.field_1545_j; float f2 = (float) field_6509_a.field_1544_k; float f3 = (float) field_6509_a.field_1543_l; GL11.glDisable(2896); Random random = new Random(31100L); float f4 = 0.75F; for (int i = 0; i < 16; i++) { GL11.glPushMatrix(); float f5 = 16 - i; float f6 = 0.0625F; float f7 = 1.0F / (f5 + 1.0F); if (i == 0) { func_6507_a("/misc/tunnel.png"); f7 = 0.1F; f5 = 65F; f6 = 0.125F; GL11.glEnable(3042); GL11.glBlendFunc(770, 771); } if (i == 1) { func_6507_a("/misc/particlefield.png"); GL11.glEnable(3042); GL11.glBlendFunc(1, 1); f6 = 0.5F; } float f8 = (float) (-(d1 + (double) f4)); float f9 = f8 + ActiveRenderInfo.field_41072_b; float f10 = f8 + f5 + ActiveRenderInfo.field_41072_b; float f11 = f9 / f10; f11 = (float) (d1 + (double) f4) + f11; GL11.glTranslatef(f1, f11, f3); GL11.glTexGeni(8192, 9472, 9217); GL11.glTexGeni(8193, 9472, 9217); GL11.glTexGeni(8194, 9472, 9217); GL11.glTexGeni(8195, 9472, 9216); GL11.glTexGen(8192, 9473, func_40447_a(1.0F, 0.0F, 0.0F, 0.0F)); GL11.glTexGen(8193, 9473, func_40447_a(0.0F, 0.0F, 1.0F, 0.0F)); GL11.glTexGen(8194, 9473, func_40447_a(0.0F, 0.0F, 0.0F, 1.0F)); GL11.glTexGen(8195, 9474, func_40447_a(0.0F, 1.0F, 0.0F, 0.0F)); GL11.glEnable(3168); GL11.glEnable(3169); GL11.glEnable(3170); GL11.glEnable(3171); GL11.glPopMatrix(); GL11.glMatrixMode(5890); GL11.glPushMatrix(); GL11.glLoadIdentity(); GL11.glTranslatef(0.0F, (float) (System.currentTimeMillis() % 0xaae60L) / 700000F, 0.0F); GL11.glScalef(f6, f6, f6); GL11.glTranslatef(0.5F, 0.5F, 0.0F); GL11.glRotatef((float) (i * i * 4321 + i * 9) * 2.0F, 0.0F, 0.0F, 1.0F); GL11.glTranslatef(-0.5F, -0.5F, 0.0F); GL11.glTranslatef(-f1, -f3, -f2); f9 = f8 + ActiveRenderInfo.field_41072_b; GL11.glTranslatef( (ActiveRenderInfo.field_41074_a * f5) / f9, (ActiveRenderInfo.field_41073_c * f5) / f9, -f2); Tessellator tessellator = Tessellator.field_1512_a; tessellator.func_977_b(); f11 = random.nextFloat() * 0.5F + 0.1F; float f12 = random.nextFloat() * 0.5F + 0.4F; float f13 = random.nextFloat() * 0.5F + 0.5F; if (i == 0) { f11 = f12 = f13 = 1.0F; } tessellator.func_986_a(f11 * f7, f12 * f7, f13 * f7, 1.0F); tessellator.func_991_a(d, d1 + (double) f4, d2); tessellator.func_991_a(d, d1 + (double) f4, d2 + 1.0D); tessellator.func_991_a(d + 1.0D, d1 + (double) f4, d2 + 1.0D); tessellator.func_991_a(d + 1.0D, d1 + (double) f4, d2); tessellator.func_982_a(); GL11.glPopMatrix(); GL11.glMatrixMode(5888); } GL11.glDisable(3042); GL11.glDisable(3168); GL11.glDisable(3169); GL11.glDisable(3170); GL11.glDisable(3171); GL11.glEnable(2896); }