function door2_slot_23() /* entry=377 class_id=0x0A07 slot=0x23 */
{
  var
    referent, /* [BP+00h] type=0x69 */
    doorList, /* [BP-02h] type=0x6C */
    counter, /* [BP-04h] type=0x69 */
    counter2, /* [BP-06h] type=0x69 */
    maxFrame; /* [BP-08h] type=0x69 */

  entry:
    set_info(0x021B, 0);
    if (Item.getStatus(arg_06) & 4) goto block_0704;

  block_06FE:
    goto block_08AD;

  block_0704:
    /* create_list element_size=0x2 count=0xC */
    /* free_local_list bp_offset=0xFE target=[BP-02h] */
    doorList = 0x0107;
    FREE.slot_3A(70, 85, 88, 101, 100, 99, 89, 0x0103, 0x0104, 0x0105, 0x0106, doorList);
    /* free_stack_list value_u8=0x0 target=[SP+00h] */
    maxFrame = retval;
    counter = (maxFrame - 1);

  block_0760:
    if (counter != 0) goto block_08A3;

  block_0768:
    FREE.slot_2D((Item.getZ(arg_06) - 8), Item.getY(arg_06), Item.getX(arg_06), Item.getFrame(arg_06), doorList, counter, list_element(size=0x2), *(arg_06));
    if retval goto block_07D1;

  block_07A8:
    spawn FREE.waitNTimerTicks(pid, 2, 0x00000000);
    suspend;
    goto block_0893;

  block_07D1:
    counter = (1 + counter);
    counter = (1 + counter);

  block_07FF:
    if (counter < (maxFrame + 1)) goto block_0889;

  block_0810:
    spawn FREE.waitNTimerTicks(doorList, counter, pid, 5, 0x00000000);
    suspend;
    counter = (1 + counter);
    goto block_07FF;

  block_0889:
    /* word_to_dword  */
    /* pop_result  */
    goto block_08AD;

  block_0893:
    counter = (counter - 1);
    goto block_0760;

  block_08A3:
    /* word_to_dword  */
    /* pop_result  */
    goto block_08AD;

  block_08AD:
    /* free_local_list bp_offset=0xFE target=[BP-02h] */
    return;

}
