function hover_slot_20() /* entry=383 class_id=0x0A0D slot=0x20 */
{
  var
    referent, /* [BP+00h] type=0x69 */
    ref, /* [BP+0Ah] type=0x69 */
    tx, /* [BP+0Ch] type=0x69 */
    ty, /* [BP+0Eh] type=0x69 */
    tz, /* [BP+10h] type=0x69 */
    wp, /* [BP-05h] type=0x24 */
    total, /* [BP-07h] type=0x69 */
    counter, /* [BP-09h] type=0x69 */
    ddx, /* [BP-0Bh] type=0x69 */
    ddy, /* [BP-0Dh] type=0x69 */
    ddz, /* [BP-0Fh] type=0x69 */
    dx, /* [BP-11h] type=0x69 */
    dy, /* [BP-13h] type=0x69 */
    dz, /* [BP-15h] type=0x69 */
    cargo, /* [BP-17h] type=0x24 */
    hover, /* [BP-19h] type=0x24 */
    sx, /* [BP-1Bh] type=0x69 */
    sy, /* [BP-1Dh] type=0x69 */
    sz, /* [BP-1Eh] type=0x62 */
    a, /* [BP-20h] type=0x69 */
    b, /* [BP-22h] type=0x69 */
    c, /* [BP-24h] type=0x69 */
    xacc, /* [BP-28h] type=0x64 */
    yacc, /* [BP-2Ch] type=0x64 */
    zacc, /* [BP-30h] type=0x64 */
    xfract, /* [BP-34h] type=0x64 */
    yfract, /* [BP-38h] type=0x64 */
    zfract, /* [BP-3Ch] type=0x64 */
    l1, /* [BP-40h] type=0x64 */
    n; /* [BP-42h] type=0x24 */

  set_info(1, 0);
  hover = ref;
  sx = Item.getX(hover);
  sy = Item.getY(hover);
  sz = Item.getZ(hover);
  class_0A0C_slot_3F((tx - sx));
  a = retval;
  class_0A0C_slot_3F((ty - sy));
  b = retval;
  class_0A0C_slot_3F((tz - sz));
  c = retval;
  if ((a <= b) && (a > c)) {
    /* word_to_dword  */
    l1 = a;
    /* word_to_dword  */
    yfract = b;
    /* word_to_dword  */
    yfract = (yfract * 0x0FA0);
    yfract = (yfract / l1);
    /* word_to_dword  */
    yacc = 0;
    /* word_to_dword  */
    zfract = c;
    /* word_to_dword  */
    zfract = (zfract * 0x0FA0);
    zfract = (zfract / l1);
    /* word_to_dword  */
    zacc = 0;
    while (!(1)) {
      if ((Item.getStatus(hover) & 0x1000) == 0) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      dx = (tx - sx);
      dy = (ty - sy);
      dz = (tz - sz);
      ddx = 0;
      ddy = 0;
      ddz = 0;
      if ((dx >= 4) && (dx > -4)) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      ddx = 4;
      if (dx >= 0) {
        ddx = -4;
      }
      if (!dy) {
        yacc = (yacc + yfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          yacc = (yacc - 0x0FA0);
          ddy = 4;
          if (dy >= 0) {
            ddy = -4;
          }
        }
      }
      if (!dz) {
        zacc = (zacc + zfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          zacc = (zacc - 0x0FA0);
          ddz = 4;
          if (dz >= 0) {
            ddz = -4;
          }
        }
      }
      total = 0;
      /* loopscr value_u8=0x24 */
      /* loop current_var=0xE9 string_bytes=0x1 loop_type=0x6 */
      while (!condition) {
        if (Item.getShape(cargo) == 0x033A) {
          if (cargo >= 0x00FF) {
            n = cargo;
            if (!Actor.isDead(n)) {
              suspend;
            }
            else {
              total = (1 + total);
            }
          }
          else {
            total = (1 + total);
          }
        }
        /* loopnext  */
      }
      sx = (sx + ddx);
      sy = (sy + ddy);
      sz = (sz + ddz);
      wp = sx;
      local_03 = sy;
      local_01 = sz;
      if (Item.inFastArea(hover) == 0) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else if (!legalMoveToPoint(0, 1, wp, hover)) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
        if (!(Item.getQHi(hover) & 16)) {
          /* bit_not  */
          /* word_to_dword  */
          /* pop_result  */
          return;
        }
        sx = (sx - ddx);
        sy = (sy - ddy);
        sz = (sz - ddz);
        spawn class_0A0C_slot_32(pid, 10, 0x00000000);
        suspend;
      }
      spawn class_0A0C_slot_32(pid, 1, 0x00000000);
      suspend;
    }
    return;
  }
  else if ((b <= a) && (b > c)) {
    /* word_to_dword  */
    l1 = b;
    /* word_to_dword  */
    xfract = a;
    /* word_to_dword  */
    xfract = (xfract * 0x0FA0);
    xfract = (xfract / l1);
    /* word_to_dword  */
    xacc = 0;
    /* word_to_dword  */
    zfract = c;
    /* word_to_dword  */
    zfract = (zfract * 0x0FA0);
    zfract = (zfract / l1);
    /* word_to_dword  */
    zacc = 0;
    while (!(1)) {
      if ((Item.getStatus(hover) & 0x1000) == 0) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      dx = (tx - sx);
      dy = (ty - sy);
      dz = (tz - sz);
      ddx = 0;
      ddy = 0;
      ddz = 0;
      if ((dy >= 4) && (dy > -4)) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      if (!dx) {
        xacc = (xacc + xfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          xacc = (xacc - 0x0FA0);
          ddx = 4;
          if (dx >= 0) {
            ddx = -4;
          }
        }
      }
      ddy = 4;
      if (dy >= 0) {
        ddy = -4;
      }
      if (!dz) {
        zacc = (zacc + zfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          zacc = (zacc - 0x0FA0);
          ddz = 4;
          if (dz >= 0) {
            ddz = -4;
          }
        }
      }
      total = 0;
      /* loopscr value_u8=0x24 */
      /* loop current_var=0xE9 string_bytes=0x1 loop_type=0x6 */
      while (!condition) {
        if (Item.getShape(cargo) == 0x033A) {
          if (cargo >= 0x00FF) {
            n = cargo;
            if (!Actor.isDead(n)) {
              suspend;
            }
            else {
              total = (1 + total);
            }
          }
          else {
            total = (1 + total);
          }
        }
        /* loopnext  */
      }
      sx = (sx + ddx);
      sy = (sy + ddy);
      sz = (sz + ddz);
      wp = sx;
      local_03 = sy;
      local_01 = sz;
      if (Item.inFastArea(hover) == 0) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else if (!legalMoveToPoint(0, 1, wp, hover)) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
        if (!(Item.getQHi(hover) & 16)) {
          /* bit_not  */
          /* word_to_dword  */
          /* pop_result  */
          return;
        }
        sx = (sx - ddx);
        sy = (sy - ddy);
        sz = (sz - ddz);
        spawn class_0A0C_slot_32(pid, 10, 0x00000000);
        suspend;
      }
      spawn class_0A0C_slot_32(pid, 1, 0x00000000);
      suspend;
    }
    return;
  }
  else {
    /* word_to_dword  */
    l1 = c;
    /* word_to_dword  */
    xfract = a;
    /* word_to_dword  */
    xfract = (xfract * 0x0FA0);
    xfract = (xfract / l1);
    /* word_to_dword  */
    xacc = 0;
    /* word_to_dword  */
    yfract = b;
    /* word_to_dword  */
    yfract = (yfract * 0x0FA0);
    yfract = (yfract / l1);
    /* word_to_dword  */
    yacc = 0;
    while (!(1)) {
      if ((Item.getStatus(hover) & 0x1000) == 0) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      dx = (tx - sx);
      dy = (ty - sy);
      dz = (tz - sz);
      ddx = 0;
      ddy = 0;
      ddz = 0;
      if ((dz >= 4) && (dz > -4)) {
        /* word_to_dword  */
        /* pop_result  */
        return;
      }
      if (!dx) {
        xacc = (xacc + xfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          xacc = (xacc - 0x0FA0);
          ddx = 4;
          if (dx >= 0) {
            ddx = -4;
          }
        }
      }
      if (!dy) {
        yacc = (yacc + yfract);
        /* word_to_dword  */
        /* gt_dword  */
        if (!(0x0FA0)) {
          /* word_to_dword  */
          yacc = (yacc - 0x0FA0);
          ddy = 4;
          if (dy >= 0) {
            ddy = -4;
          }
        }
      }
      ddz = 4;
      if (dz >= 0) {
        ddz = -4;
      }
      total = 0;
      /* loopscr value_u8=0x24 */
      /* loop current_var=0xE9 string_bytes=0x1 loop_type=0x6 */
      while (!condition) {
        if (Item.getShape(cargo) == 0x033A) {
          if (cargo >= 0x00FF) {
            n = cargo;
            if (!Actor.isDead(n)) {
              suspend;
            }
            else {
              total = (1 + total);
            }
          }
          else {
            total = (1 + total);
          }
        }
        /* loopnext  */
      }
      sx = (sx + ddx);
      sy = (sy + ddy);
      sz = (sz + ddz);
      wp = sx;
      local_03 = sy;
      local_01 = sz;
      if (Item.inFastArea(hover) == 0) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else if (!legalMoveToPoint(0, 1, wp, hover)) {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
      }
      else {
        counter = 1;
        while (counter > total) {
          cargo = Item.getEtherealTop();
          counter = (1 + counter);
        }
        if (!(Item.getQHi(hover) & 16)) {
          /* bit_not  */
          /* word_to_dword  */
          /* pop_result  */
          return;
        }
        sx = (sx - ddx);
        sy = (sy - ddy);
        sz = (sz - ddz);
        spawn class_0A0C_slot_32(pid, 10, 0x00000000);
        suspend;
      }
      spawn class_0A0C_slot_32(pid, 1, 0x00000000);
      suspend;
    }
  }
  return;
}
