float func_528_a(int var1) {
      if((double)var1 < (double)((float)this.heightLimit) * 0.3D) {
         return -1.618F;
      } else {
         float var2 = (float)this.heightLimit / 2.0F;
         float var3 = (float)this.heightLimit / 2.0F - (float)var1;
         float var4;
         if(var3 == 0.0F) {
            var4 = var2;
         } else if(Math.abs(var3) >= var2) {
            var4 = 0.0F;
         } else {
            var4 = (float)Math.sqrt(Math.pow((double)Math.abs(var2), 2.0D) - Math.pow((double)Math.abs(var3), 2.0D));
         }

         var4 *= 0.5F;
         return var4;
      }
   }