Ejemplo n.º 1
0
 public boolean func_70289_a(EntityItem p_70289_1_) {
   if (p_70289_1_ == this) {
     return false;
   } else if (p_70289_1_.func_70089_S() && this.func_70089_S()) {
     ItemStack var2 = this.func_92014_d();
     ItemStack var3 = p_70289_1_.func_92014_d();
     if (var3.func_77973_b() != var2.func_77973_b()) {
       return false;
     } else if (var3.func_77942_o() ^ var2.func_77942_o()) {
       return false;
     } else if (var3.func_77942_o() && !var3.func_77978_p().equals(var2.func_77978_p())) {
       return false;
     } else if (var3.func_77973_b().func_77614_k() && var3.func_77960_j() != var2.func_77960_j()) {
       return false;
     } else if (var3.field_77994_a < var2.field_77994_a) {
       return p_70289_1_.func_70289_a(this);
     } else if (var3.field_77994_a + var2.field_77994_a > var3.func_77976_d()) {
       return false;
     } else {
       var3.field_77994_a += var2.field_77994_a;
       p_70289_1_.field_70293_c = Math.max(p_70289_1_.field_70293_c, this.field_70293_c);
       p_70289_1_.field_70292_b = Math.min(p_70289_1_.field_70292_b, this.field_70292_b);
       p_70289_1_.func_92013_a(var3);
       this.func_70106_y();
       return true;
     }
   } else {
     return false;
   }
 }
Ejemplo n.º 2
0
  public boolean func_70085_c(EntityPlayer p_70085_1_) {
    ItemStack var2 = p_70085_1_.field_71071_by.func_70448_g();
    boolean var3 = var2 != null && var2.func_77973_b() == Items.field_151063_bx;
    if (!var3 && this.func_70089_S() && !this.func_70940_q() && !this.func_70631_g_()) {
      if (!this.field_70170_p.field_72995_K) {
        this.func_70932_a_(p_70085_1_);
        p_70085_1_.func_71030_a(this, this.func_94057_bL());
      }

      return true;
    } else {
      return super.func_70085_c(p_70085_1_);
    }
  }
Ejemplo n.º 3
0
  public ItemStack func_82846_b(EntityPlayer p_82846_1_, int p_82846_2_) {
    ItemStack var3 = null;
    Slot var4 = (Slot) this.field_75151_b.get(p_82846_2_);
    if (var4 != null && var4.func_75216_d()) {
      ItemStack var5 = var4.func_75211_c();
      var3 = var5.func_77946_l();
      if (p_82846_2_ == 2) {
        if (!this.func_75135_a(var5, 3, 39, true)) {
          return null;
        }

        var4.func_75220_a(var5, var3);
      } else if (p_82846_2_ != 1 && p_82846_2_ != 0) {
        if (FurnaceRecipes.func_77602_a().func_77603_b(var5.func_77973_b().field_77779_bT)
            != null) {
          if (!this.func_75135_a(var5, 0, 1, false)) {
            return null;
          }
        } else if (TileEntityFurnace.func_70401_b(var5)) {
          if (!this.func_75135_a(var5, 1, 2, false)) {
            return null;
          }
        } else if (p_82846_2_ >= 3 && p_82846_2_ < 30) {
          if (!this.func_75135_a(var5, 30, 39, false)) {
            return null;
          }
        } else if (p_82846_2_ >= 30 && p_82846_2_ < 39 && !this.func_75135_a(var5, 3, 30, false)) {
          return null;
        }
      } else if (!this.func_75135_a(var5, 3, 39, false)) {
        return null;
      }

      if (var5.field_77994_a == 0) {
        var4.func_75215_d((ItemStack) null);
      } else {
        var4.func_75218_e();
      }

      if (var5.field_77994_a == var3.field_77994_a) {
        return null;
      }

      var4.func_82870_a(p_82846_1_, var5);
    }

    return var3;
  }
 public ItemStack func_82487_b(IBlockSource p_82487_1_, ItemStack p_82487_2_) {
   ItemBucket var3 = (ItemBucket) p_82487_2_.func_77973_b();
   int var4 = p_82487_1_.func_82623_d();
   int var5 = p_82487_1_.func_82622_e();
   int var6 = p_82487_1_.func_82621_f();
   EnumFacing var7 = BlockDispenser.func_100009_j_(p_82487_1_.func_82620_h());
   if (var3.func_77875_a(
       p_82487_1_.func_82618_k(),
       (double) var4,
       (double) var5,
       (double) var6,
       var4 + var7.func_82601_c(),
       var5 + var7.func_96559_d(),
       var6 + var7.func_82599_e())) {
     p_82487_2_.field_77993_c = Item.field_77788_aw.field_77779_bT;
     p_82487_2_.field_77994_a = 1;
     return p_82487_2_;
   } else {
     return this.field_96459_b.func_82482_a(p_82487_1_, p_82487_2_);
   }
 }
Ejemplo n.º 5
0
  public void func_78440_a(float p_78440_1_) {
    float var2 = this.field_78451_d + (this.field_78454_c - this.field_78451_d) * p_78440_1_;
    EntityClientPlayerMP var3 = this.field_78455_a.field_71439_g;
    float var4 = var3.field_70127_C + (var3.field_70125_A - var3.field_70127_C) * p_78440_1_;
    GL11.glPushMatrix();
    GL11.glRotatef(var4, 1.0F, 0.0F, 0.0F);
    GL11.glRotatef(
        var3.field_70126_B + (var3.field_70177_z - var3.field_70126_B) * p_78440_1_,
        0.0F,
        1.0F,
        0.0F);
    RenderHelper.func_74519_b();
    GL11.glPopMatrix();
    float var6;
    float var7;
    if (var3 instanceof EntityPlayerSP) {
      EntityPlayerSP var5 = (EntityPlayerSP) var3;
      var6 = var5.field_71164_i + (var5.field_71155_g - var5.field_71164_i) * p_78440_1_;
      var7 = var5.field_71163_h + (var5.field_71154_f - var5.field_71163_h) * p_78440_1_;
      GL11.glRotatef((var3.field_70125_A - var6) * 0.1F, 1.0F, 0.0F, 0.0F);
      GL11.glRotatef((var3.field_70177_z - var7) * 0.1F, 0.0F, 1.0F, 0.0F);
    }

    ItemStack var17 = this.field_78453_b;
    var6 =
        this.field_78455_a.field_71441_e.func_72801_o(
            MathHelper.func_76128_c(var3.field_70165_t),
            MathHelper.func_76128_c(var3.field_70163_u),
            MathHelper.func_76128_c(var3.field_70161_v));
    var6 = 1.0F;
    int var18 =
        this.field_78455_a.field_71441_e.func_72802_i(
            MathHelper.func_76128_c(var3.field_70165_t),
            MathHelper.func_76128_c(var3.field_70163_u),
            MathHelper.func_76128_c(var3.field_70161_v),
            0);
    int var8 = var18 % 65536;
    int var9 = var18 / 65536;
    OpenGlHelper.func_77475_a(OpenGlHelper.field_77476_b, (float) var8 / 1.0F, (float) var9 / 1.0F);
    GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
    float var10;
    float var21;
    float var20;
    if (var17 != null) {
      var18 = Item.field_77698_e[var17.field_77993_c].func_82790_a(var17, 0);
      var20 = (float) (var18 >> 16 & 255) / 255.0F;
      var21 = (float) (var18 >> 8 & 255) / 255.0F;
      var10 = (float) (var18 & 255) / 255.0F;
      GL11.glColor4f(var6 * var20, var6 * var21, var6 * var10, 1.0F);
    } else {
      GL11.glColor4f(var6, var6, var6, 1.0F);
    }

    float var11;
    float var12;
    float var13;
    Render var24;
    RenderPlayer var26;
    if (var17 != null && var17.field_77993_c == Item.field_77744_bd.field_77779_bT) {
      GL11.glPushMatrix();
      var7 = 0.8F;
      var20 = var3.func_70678_g(p_78440_1_);
      var21 = MathHelper.func_76126_a(var20 * 3.1415927F);
      var10 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glTranslatef(
          -var10 * 0.4F,
          MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.2F,
          -var21 * 0.2F);
      var20 = 1.0F - var4 / 45.0F + 0.1F;
      if (var20 < 0.0F) {
        var20 = 0.0F;
      }

      if (var20 > 1.0F) {
        var20 = 1.0F;
      }

      var20 = -MathHelper.func_76134_b(var20 * 3.1415927F) * 0.5F + 0.5F;
      GL11.glTranslatef(
          0.0F, 0.0F * var7 - (1.0F - var2) * 1.2F - var20 * 0.5F + 0.04F, -0.9F * var7);
      GL11.glRotatef(90.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(var20 * -85.0F, 0.0F, 0.0F, 1.0F);
      GL11.glEnable('\u803a');
      GL11.glBindTexture(
          3553,
          this.field_78455_a.field_71446_o.func_78350_a(
              this.field_78455_a.field_71439_g.field_70120_cr,
              this.field_78455_a.field_71439_g.func_70073_O()));

      for (var9 = 0; var9 < 2; ++var9) {
        int var22 = var9 * 2 - 1;
        GL11.glPushMatrix();
        GL11.glTranslatef(-0.0F, -0.6F, 1.1F * (float) var22);
        GL11.glRotatef((float) (-45 * var22), 1.0F, 0.0F, 0.0F);
        GL11.glRotatef(-90.0F, 0.0F, 0.0F, 1.0F);
        GL11.glRotatef(59.0F, 0.0F, 0.0F, 1.0F);
        GL11.glRotatef((float) (-65 * var22), 0.0F, 1.0F, 0.0F);
        var24 = RenderManager.field_78727_a.func_78713_a(this.field_78455_a.field_71439_g);
        var26 = (RenderPlayer) var24;
        var13 = 1.0F;
        GL11.glScalef(var13, var13, var13);
        var26.func_82441_a(this.field_78455_a.field_71439_g);
        GL11.glPopMatrix();
      }

      var21 = var3.func_70678_g(p_78440_1_);
      var10 = MathHelper.func_76126_a(var21 * var21 * 3.1415927F);
      var11 = MathHelper.func_76126_a(MathHelper.func_76129_c(var21) * 3.1415927F);
      GL11.glRotatef(-var10 * 20.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var11 * 20.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(-var11 * 80.0F, 1.0F, 0.0F, 0.0F);
      var12 = 0.38F;
      GL11.glScalef(var12, var12, var12);
      GL11.glRotatef(90.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
      GL11.glTranslatef(-1.0F, -1.0F, 0.0F);
      var13 = 0.015625F;
      GL11.glScalef(var13, var13, var13);
      this.field_78455_a.field_71446_o.func_78342_b(
          this.field_78455_a.field_71446_o.func_78341_b("/misc/mapbg.png"));
      Tessellator var28 = Tessellator.field_78398_a;
      GL11.glNormal3f(0.0F, 0.0F, -1.0F);
      var28.func_78382_b();
      byte var27 = 7;
      var28.func_78374_a((double) (0 - var27), (double) (128 + var27), 0.0D, 0.0D, 1.0D);
      var28.func_78374_a((double) (128 + var27), (double) (128 + var27), 0.0D, 1.0D, 1.0D);
      var28.func_78374_a((double) (128 + var27), (double) (0 - var27), 0.0D, 1.0D, 0.0D);
      var28.func_78374_a((double) (0 - var27), (double) (0 - var27), 0.0D, 0.0D, 0.0D);
      var28.func_78381_a();
      MapData var16 = Item.field_77744_bd.func_77873_a(var17, this.field_78455_a.field_71441_e);
      if (var16 != null) {
        this.field_78449_f.func_78319_a(
            this.field_78455_a.field_71439_g, this.field_78455_a.field_71446_o, var16);
      }

      GL11.glPopMatrix();
    } else if (var17 != null) {
      GL11.glPushMatrix();
      var7 = 0.8F;
      if (var3.func_71052_bv() > 0) {
        EnumAction var19 = var17.func_77975_n();
        if (var19 == EnumAction.eat || var19 == EnumAction.drink) {
          var21 = (float) var3.func_71052_bv() - p_78440_1_ + 1.0F;
          var10 = 1.0F - var21 / (float) var17.func_77988_m();
          var11 = 1.0F - var10;
          var11 = var11 * var11 * var11;
          var11 = var11 * var11 * var11;
          var11 = var11 * var11 * var11;
          var12 = 1.0F - var11;
          GL11.glTranslatef(
              0.0F,
              MathHelper.func_76135_e(MathHelper.func_76134_b(var21 / 4.0F * 3.1415927F) * 0.1F)
                  * (float) ((double) var10 > 0.2D ? 1 : 0),
              0.0F);
          GL11.glTranslatef(var12 * 0.6F, -var12 * 0.5F, 0.0F);
          GL11.glRotatef(var12 * 90.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(var12 * 10.0F, 1.0F, 0.0F, 0.0F);
          GL11.glRotatef(var12 * 30.0F, 0.0F, 0.0F, 1.0F);
        }
      } else {
        var20 = var3.func_70678_g(p_78440_1_);
        var21 = MathHelper.func_76126_a(var20 * 3.1415927F);
        var10 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
        GL11.glTranslatef(
            -var10 * 0.4F,
            MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.2F,
            -var21 * 0.2F);
      }

      GL11.glTranslatef(0.7F * var7, -0.65F * var7 - (1.0F - var2) * 0.6F, -0.9F * var7);
      GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
      GL11.glEnable('\u803a');
      var20 = var3.func_70678_g(p_78440_1_);
      var21 = MathHelper.func_76126_a(var20 * var20 * 3.1415927F);
      var10 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glRotatef(-var21 * 20.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var10 * 20.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(-var10 * 80.0F, 1.0F, 0.0F, 0.0F);
      var11 = 0.4F;
      GL11.glScalef(var11, var11, var11);
      float var14;
      float var15;
      if (var3.func_71052_bv() > 0) {
        EnumAction var23 = var17.func_77975_n();
        if (var23 == EnumAction.block) {
          GL11.glTranslatef(-0.5F, 0.2F, 0.0F);
          GL11.glRotatef(30.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(-80.0F, 1.0F, 0.0F, 0.0F);
          GL11.glRotatef(60.0F, 0.0F, 1.0F, 0.0F);
        } else if (var23 == EnumAction.bow) {
          GL11.glRotatef(-18.0F, 0.0F, 0.0F, 1.0F);
          GL11.glRotatef(-12.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(-8.0F, 1.0F, 0.0F, 0.0F);
          GL11.glTranslatef(-0.9F, 0.2F, 0.0F);
          var13 = (float) var17.func_77988_m() - ((float) var3.func_71052_bv() - p_78440_1_ + 1.0F);
          var14 = var13 / 20.0F;
          var14 = (var14 * var14 + var14 * 2.0F) / 3.0F;
          if (var14 > 1.0F) {
            var14 = 1.0F;
          }

          if (var14 > 0.1F) {
            GL11.glTranslatef(
                0.0F,
                MathHelper.func_76126_a((var13 - 0.1F) * 1.3F) * 0.01F * (var14 - 0.1F),
                0.0F);
          }

          GL11.glTranslatef(0.0F, 0.0F, var14 * 0.1F);
          GL11.glRotatef(-335.0F, 0.0F, 0.0F, 1.0F);
          GL11.glRotatef(-50.0F, 0.0F, 1.0F, 0.0F);
          GL11.glTranslatef(0.0F, 0.5F, 0.0F);
          var15 = 1.0F + var14 * 0.2F;
          GL11.glScalef(1.0F, 1.0F, var15);
          GL11.glTranslatef(0.0F, -0.5F, 0.0F);
          GL11.glRotatef(50.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(335.0F, 0.0F, 0.0F, 1.0F);
        }
      }

      if (var17.func_77973_b().func_77629_n_()) {
        GL11.glRotatef(180.0F, 0.0F, 1.0F, 0.0F);
      }

      if (var17.func_77973_b().func_77623_v()) {
        this.func_78443_a(var3, var17, 0);
        int var25 = Item.field_77698_e[var17.field_77993_c].func_82790_a(var17, 1);
        var13 = (float) (var25 >> 16 & 255) / 255.0F;
        var14 = (float) (var25 >> 8 & 255) / 255.0F;
        var15 = (float) (var25 & 255) / 255.0F;
        GL11.glColor4f(var6 * var13, var6 * var14, var6 * var15, 1.0F);
        this.func_78443_a(var3, var17, 1);
      } else {
        this.func_78443_a(var3, var17, 0);
      }

      GL11.glPopMatrix();
    } else if (!var3.func_82150_aj()) {
      GL11.glPushMatrix();
      var7 = 0.8F;
      var20 = var3.func_70678_g(p_78440_1_);
      var21 = MathHelper.func_76126_a(var20 * 3.1415927F);
      var10 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glTranslatef(
          -var10 * 0.3F,
          MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.4F,
          -var21 * 0.4F);
      GL11.glTranslatef(0.8F * var7, -0.75F * var7 - (1.0F - var2) * 0.6F, -0.9F * var7);
      GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
      GL11.glEnable('\u803a');
      var20 = var3.func_70678_g(p_78440_1_);
      var21 = MathHelper.func_76126_a(var20 * var20 * 3.1415927F);
      var10 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glRotatef(var10 * 70.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var21 * 20.0F, 0.0F, 0.0F, 1.0F);
      GL11.glBindTexture(
          3553,
          this.field_78455_a.field_71446_o.func_78350_a(
              this.field_78455_a.field_71439_g.field_70120_cr,
              this.field_78455_a.field_71439_g.func_70073_O()));
      GL11.glTranslatef(-1.0F, 3.6F, 3.5F);
      GL11.glRotatef(120.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(200.0F, 1.0F, 0.0F, 0.0F);
      GL11.glRotatef(-135.0F, 0.0F, 1.0F, 0.0F);
      GL11.glScalef(1.0F, 1.0F, 1.0F);
      GL11.glTranslatef(5.6F, 0.0F, 0.0F);
      var24 = RenderManager.field_78727_a.func_78713_a(this.field_78455_a.field_71439_g);
      var26 = (RenderPlayer) var24;
      var13 = 1.0F;
      GL11.glScalef(var13, var13, var13);
      var26.func_82441_a(this.field_78455_a.field_71439_g);
      GL11.glPopMatrix();
    }

    GL11.glDisable('\u803a');
    RenderHelper.func_74518_a();
  }
Ejemplo n.º 6
0
  public void func_78440_a(float p_78440_1_) {
    float var2 = this.field_78451_d + (this.field_78454_c - this.field_78451_d) * p_78440_1_;
    EntityClientPlayerMP var3 = this.field_78455_a.field_71439_g;
    float var4 = var3.field_70127_C + (var3.field_70125_A - var3.field_70127_C) * p_78440_1_;
    GL11.glPushMatrix();
    GL11.glRotatef(var4, 1.0F, 0.0F, 0.0F);
    GL11.glRotatef(
        var3.field_70126_B + (var3.field_70177_z - var3.field_70126_B) * p_78440_1_,
        0.0F,
        1.0F,
        0.0F);
    RenderHelper.func_74519_b();
    GL11.glPopMatrix();
    EntityPlayerSP var5 = (EntityPlayerSP) var3;
    float var6 = var5.field_71164_i + (var5.field_71155_g - var5.field_71164_i) * p_78440_1_;
    float var7 = var5.field_71163_h + (var5.field_71154_f - var5.field_71163_h) * p_78440_1_;
    GL11.glRotatef((var3.field_70125_A - var6) * 0.1F, 1.0F, 0.0F, 0.0F);
    GL11.glRotatef((var3.field_70177_z - var7) * 0.1F, 0.0F, 1.0F, 0.0F);
    ItemStack var8 = this.field_78453_b;
    float var9 =
        this.field_78455_a.field_71441_e.func_72801_o(
            MathHelper.func_76128_c(var3.field_70165_t),
            MathHelper.func_76128_c(var3.field_70163_u),
            MathHelper.func_76128_c(var3.field_70161_v));
    var9 = 1.0F;
    int var10 =
        this.field_78455_a.field_71441_e.func_72802_i(
            MathHelper.func_76128_c(var3.field_70165_t),
            MathHelper.func_76128_c(var3.field_70163_u),
            MathHelper.func_76128_c(var3.field_70161_v),
            0);
    int var11 = var10 % 65536;
    int var12 = var10 / 65536;
    OpenGlHelper.func_77475_a(
        OpenGlHelper.field_77476_b, (float) var11 / 1.0F, (float) var12 / 1.0F);
    GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
    float var13;
    float var20;
    float var22;
    if (var8 != null) {
      var10 = Item.field_77698_e[var8.field_77993_c].func_82790_a(var8, 0);
      var20 = (float) (var10 >> 16 & 255) / 255.0F;
      var22 = (float) (var10 >> 8 & 255) / 255.0F;
      var13 = (float) (var10 & 255) / 255.0F;
      GL11.glColor4f(var9 * var20, var9 * var22, var9 * var13, 1.0F);
    } else {
      GL11.glColor4f(var9, var9, var9, 1.0F);
    }

    float var14;
    float var15;
    float var16;
    float var21;
    Render var27;
    RenderPlayer var26;
    if (var8 != null && var8.field_77993_c == Item.field_77744_bd.field_77779_bT) {
      GL11.glPushMatrix();
      var21 = 0.8F;
      var20 = var3.func_70678_g(p_78440_1_);
      var22 = MathHelper.func_76126_a(var20 * 3.1415927F);
      var13 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glTranslatef(
          -var13 * 0.4F,
          MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.2F,
          -var22 * 0.2F);
      var20 = 1.0F - var4 / 45.0F + 0.1F;
      if (var20 < 0.0F) {
        var20 = 0.0F;
      }

      if (var20 > 1.0F) {
        var20 = 1.0F;
      }

      var20 = -MathHelper.func_76134_b(var20 * 3.1415927F) * 0.5F + 0.5F;
      GL11.glTranslatef(
          0.0F, 0.0F * var21 - (1.0F - var2) * 1.2F - var20 * 0.5F + 0.04F, -0.9F * var21);
      GL11.glRotatef(90.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(var20 * -85.0F, 0.0F, 0.0F, 1.0F);
      GL11.glEnable('\u803a');
      this.field_78455_a.func_110434_K().func_110577_a(var3.func_110306_p());

      for (var12 = 0; var12 < 2; ++var12) {
        int var24 = var12 * 2 - 1;
        GL11.glPushMatrix();
        GL11.glTranslatef(-0.0F, -0.6F, 1.1F * (float) var24);
        GL11.glRotatef((float) (-45 * var24), 1.0F, 0.0F, 0.0F);
        GL11.glRotatef(-90.0F, 0.0F, 0.0F, 1.0F);
        GL11.glRotatef(59.0F, 0.0F, 0.0F, 1.0F);
        GL11.glRotatef((float) (-65 * var24), 0.0F, 1.0F, 0.0F);
        var27 = RenderManager.field_78727_a.func_78713_a(this.field_78455_a.field_71439_g);
        var26 = (RenderPlayer) var27;
        var16 = 1.0F;
        GL11.glScalef(var16, var16, var16);
        var26.func_82441_a(this.field_78455_a.field_71439_g);
        GL11.glPopMatrix();
      }

      var22 = var3.func_70678_g(p_78440_1_);
      var13 = MathHelper.func_76126_a(var22 * var22 * 3.1415927F);
      var14 = MathHelper.func_76126_a(MathHelper.func_76129_c(var22) * 3.1415927F);
      GL11.glRotatef(-var13 * 20.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var14 * 20.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(-var14 * 80.0F, 1.0F, 0.0F, 0.0F);
      var15 = 0.38F;
      GL11.glScalef(var15, var15, var15);
      GL11.glRotatef(90.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(180.0F, 0.0F, 0.0F, 1.0F);
      GL11.glTranslatef(-1.0F, -1.0F, 0.0F);
      var16 = 0.015625F;
      GL11.glScalef(var16, var16, var16);
      this.field_78455_a.func_110434_K().func_110577_a(field_110931_c);
      Tessellator var30 = Tessellator.field_78398_a;
      GL11.glNormal3f(0.0F, 0.0F, -1.0F);
      var30.func_78382_b();
      byte var29 = 7;
      var30.func_78374_a((double) (0 - var29), (double) (128 + var29), 0.0D, 0.0D, 1.0D);
      var30.func_78374_a((double) (128 + var29), (double) (128 + var29), 0.0D, 1.0D, 1.0D);
      var30.func_78374_a((double) (128 + var29), (double) (0 - var29), 0.0D, 1.0D, 0.0D);
      var30.func_78374_a((double) (0 - var29), (double) (0 - var29), 0.0D, 0.0D, 0.0D);
      var30.func_78381_a();
      MapData var19 = Item.field_77744_bd.func_77873_a(var8, this.field_78455_a.field_71441_e);
      if (var19 != null) {
        this.field_78449_f.func_78319_a(
            this.field_78455_a.field_71439_g, this.field_78455_a.func_110434_K(), var19);
      }

      GL11.glPopMatrix();
    } else if (var8 != null) {
      GL11.glPushMatrix();
      var21 = 0.8F;
      if (var3.func_71052_bv() > 0) {
        EnumAction var23 = var8.func_77975_n();
        if (var23 == EnumAction.eat || var23 == EnumAction.drink) {
          var22 = (float) var3.func_71052_bv() - p_78440_1_ + 1.0F;
          var13 = 1.0F - var22 / (float) var8.func_77988_m();
          var14 = 1.0F - var13;
          var14 = var14 * var14 * var14;
          var14 = var14 * var14 * var14;
          var14 = var14 * var14 * var14;
          var15 = 1.0F - var14;
          GL11.glTranslatef(
              0.0F,
              MathHelper.func_76135_e(MathHelper.func_76134_b(var22 / 4.0F * 3.1415927F) * 0.1F)
                  * (float) ((double) var13 > 0.2D ? 1 : 0),
              0.0F);
          GL11.glTranslatef(var15 * 0.6F, -var15 * 0.5F, 0.0F);
          GL11.glRotatef(var15 * 90.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(var15 * 10.0F, 1.0F, 0.0F, 0.0F);
          GL11.glRotatef(var15 * 30.0F, 0.0F, 0.0F, 1.0F);
        }
      } else {
        var20 = var3.func_70678_g(p_78440_1_);
        var22 = MathHelper.func_76126_a(var20 * 3.1415927F);
        var13 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
        GL11.glTranslatef(
            -var13 * 0.4F,
            MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.2F,
            -var22 * 0.2F);
      }

      GL11.glTranslatef(0.7F * var21, -0.65F * var21 - (1.0F - var2) * 0.6F, -0.9F * var21);
      GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
      GL11.glEnable('\u803a');
      var20 = var3.func_70678_g(p_78440_1_);
      var22 = MathHelper.func_76126_a(var20 * var20 * 3.1415927F);
      var13 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glRotatef(-var22 * 20.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var13 * 20.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(-var13 * 80.0F, 1.0F, 0.0F, 0.0F);
      var14 = 0.4F;
      GL11.glScalef(var14, var14, var14);
      float var17;
      float var18;
      if (var3.func_71052_bv() > 0) {
        EnumAction var25 = var8.func_77975_n();
        if (var25 == EnumAction.block) {
          GL11.glTranslatef(-0.5F, 0.2F, 0.0F);
          GL11.glRotatef(30.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(-80.0F, 1.0F, 0.0F, 0.0F);
          GL11.glRotatef(60.0F, 0.0F, 1.0F, 0.0F);
        } else if (var25 == EnumAction.bow) {
          GL11.glRotatef(-18.0F, 0.0F, 0.0F, 1.0F);
          GL11.glRotatef(-12.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(-8.0F, 1.0F, 0.0F, 0.0F);
          GL11.glTranslatef(-0.9F, 0.2F, 0.0F);
          var16 = (float) var8.func_77988_m() - ((float) var3.func_71052_bv() - p_78440_1_ + 1.0F);
          var17 = var16 / 20.0F;
          var17 = (var17 * var17 + var17 * 2.0F) / 3.0F;
          if (var17 > 1.0F) {
            var17 = 1.0F;
          }

          if (var17 > 0.1F) {
            GL11.glTranslatef(
                0.0F,
                MathHelper.func_76126_a((var16 - 0.1F) * 1.3F) * 0.01F * (var17 - 0.1F),
                0.0F);
          }

          GL11.glTranslatef(0.0F, 0.0F, var17 * 0.1F);
          GL11.glRotatef(-335.0F, 0.0F, 0.0F, 1.0F);
          GL11.glRotatef(-50.0F, 0.0F, 1.0F, 0.0F);
          GL11.glTranslatef(0.0F, 0.5F, 0.0F);
          var18 = 1.0F + var17 * 0.2F;
          GL11.glScalef(1.0F, 1.0F, var18);
          GL11.glTranslatef(0.0F, -0.5F, 0.0F);
          GL11.glRotatef(50.0F, 0.0F, 1.0F, 0.0F);
          GL11.glRotatef(335.0F, 0.0F, 0.0F, 1.0F);
        }
      }

      if (var8.func_77973_b().func_77629_n_()) {
        GL11.glRotatef(180.0F, 0.0F, 1.0F, 0.0F);
      }

      if (var8.func_77973_b().func_77623_v()) {
        this.func_78443_a(var3, var8, 0);
        int var28 = Item.field_77698_e[var8.field_77993_c].func_82790_a(var8, 1);
        var16 = (float) (var28 >> 16 & 255) / 255.0F;
        var17 = (float) (var28 >> 8 & 255) / 255.0F;
        var18 = (float) (var28 & 255) / 255.0F;
        GL11.glColor4f(var9 * var16, var9 * var17, var9 * var18, 1.0F);
        this.func_78443_a(var3, var8, 1);
      } else {
        this.func_78443_a(var3, var8, 0);
      }

      GL11.glPopMatrix();
    } else if (!var3.func_82150_aj()) {
      GL11.glPushMatrix();
      var21 = 0.8F;
      var20 = var3.func_70678_g(p_78440_1_);
      var22 = MathHelper.func_76126_a(var20 * 3.1415927F);
      var13 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glTranslatef(
          -var13 * 0.3F,
          MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F * 2.0F) * 0.4F,
          -var22 * 0.4F);
      GL11.glTranslatef(0.8F * var21, -0.75F * var21 - (1.0F - var2) * 0.6F, -0.9F * var21);
      GL11.glRotatef(45.0F, 0.0F, 1.0F, 0.0F);
      GL11.glEnable('\u803a');
      var20 = var3.func_70678_g(p_78440_1_);
      var22 = MathHelper.func_76126_a(var20 * var20 * 3.1415927F);
      var13 = MathHelper.func_76126_a(MathHelper.func_76129_c(var20) * 3.1415927F);
      GL11.glRotatef(var13 * 70.0F, 0.0F, 1.0F, 0.0F);
      GL11.glRotatef(-var22 * 20.0F, 0.0F, 0.0F, 1.0F);
      this.field_78455_a.func_110434_K().func_110577_a(var3.func_110306_p());
      GL11.glTranslatef(-1.0F, 3.6F, 3.5F);
      GL11.glRotatef(120.0F, 0.0F, 0.0F, 1.0F);
      GL11.glRotatef(200.0F, 1.0F, 0.0F, 0.0F);
      GL11.glRotatef(-135.0F, 0.0F, 1.0F, 0.0F);
      GL11.glScalef(1.0F, 1.0F, 1.0F);
      GL11.glTranslatef(5.6F, 0.0F, 0.0F);
      var27 = RenderManager.field_78727_a.func_78713_a(this.field_78455_a.field_71439_g);
      var26 = (RenderPlayer) var27;
      var16 = 1.0F;
      GL11.glScalef(var16, var16, var16);
      var26.func_82441_a(this.field_78455_a.field_71439_g);
      GL11.glPopMatrix();
    }

    GL11.glDisable('\u803a');
    RenderHelper.func_74518_a();
  }
Ejemplo n.º 7
0
 protected IBehaviorDispenseItem func_96472_a(ItemStack p_96472_1_) {
   return (IBehaviorDispenseItem) field_82527_a.func_82594_a(p_96472_1_.func_77973_b());
 }