// File: /workspace/github_cpp_makefile_star2_O1/arisKoutsou[P]oopproj/./src/inventory/Inventory.cpp
// Function: Inventory::printItems()
void Inventory :: printItems() {
  if (this->getCurrentItems() == 0) {
    cout << endl << "No items in the inventory" << endl << endl;
    return;
  } else {
    list<Item*> :: const_iterator it = items.begin();
    vector<Weapon*> weapons;
    vector<Armor*> armors;
    vector<Potion*> potions;
    for ( ; it != items.end(); ++it) {
      string kind = (*it)->kindOf();
      if (kind == "Weapon") {
	weapons.push_back(static_cast<Weapon*>(*it));
      } else if (kind == "Armor") {
	armors.push_back(static_cast<Armor*>(*it));
      } else if (kind == "Potion") {
	potions.push_back(static_cast<Potion*>(*it));
      }
    }
    printWeapons(weapons);
    printArmors(armors);
    printPotions(potions);
  }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
cmpl $0x0, 0x18(%rdi)
je 0xd835
movq %rdi, %rbx
movq 0x8(%rdi), %rbp
addq $0x8, %rbx
xorl %eax, %eax
movq %rax, 0x60(%rsp)
xorps %xmm0, %xmm0
movaps %xmm0, 0x50(%rsp)
movq %rax, 0x40(%rsp)
movaps %xmm0, 0x30(%rsp)
movq %rax, 0x20(%rsp)
movaps %xmm0, 0x10(%rsp)
cmpq %rbx, %rbp
je 0xd7c0
leaq 0x78(%rsp), %r12
leaq 0x68(%rsp), %r14
leaq 0xe4a3(%rip), %r15      # 0x1bbb2
leaq 0x8(%rsp), %r13
movq 0x10(%rbp), %rsi
movq (%rsi), %rax
movq %r14, %rdi
callq *0x18(%rax)
movq %r14, %rdi
movq %r15, %rsi
callq 0x40d0
testl %eax, %eax
je 0xd76e
movq %r14, %rdi
leaq 0xe47f(%rip), %rsi      # 0x1bbb9
callq 0x40d0
testl %eax, %eax
je 0xd786
movq %r14, %rdi
leaq 0xe7da(%rip), %rsi      # 0x1bf27
callq 0x40d0
testl %eax, %eax
jne 0xd79c
movq 0x10(%rbp), %rax
movq %rax, 0x8(%rsp)
leaq 0x10(%rsp), %rdi
movq %r13, %rsi
callq 0xf6d6
jmp 0xd79c
movq 0x10(%rbp), %rax
movq %rax, 0x8(%rsp)
leaq 0x50(%rsp), %rdi
movq %r13, %rsi
callq 0xf3fe
jmp 0xd79c
movq 0x10(%rbp), %rax
movq %rax, 0x8(%rsp)
leaq 0x30(%rsp), %rdi
movq %r13, %rsi
callq 0xf56a
movq 0x68(%rsp), %rdi
cmpq %r12, %rdi
je 0xd7b3
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x42a0
movq (%rbp), %rbp
cmpq %rbx, %rbp
jne 0xd714
leaq 0x50(%rsp), %rsi
callq 0xcaca
leaq 0x30(%rsp), %rsi
callq 0xcea8
leaq 0x10(%rsp), %rsi
callq 0xd236
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xd7f5
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0xd80c
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0xd823
movq 0x60(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x17784(%rip), %rbx     # 0x24fc0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4270
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41b0
movq %rax, %rbx
leaq 0xe32b(%rip), %rsi      # 0x1bb98
movl $0x19, %edx
movq %rax, %rdi
callq 0x42f0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4270
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4040
movq %rax, %rdi
callq 0x41b0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x4270
movsbl %al, %esi
movq %rbx, %rdi
callq 0x4040
movq %rax, %rdi
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x41b0
jmp 0xd8e2
jmp 0xd8fe
jmp 0xd8e2
movq %rax, %rbx
movq 0x68(%rsp), %rdi
cmpq %r12, %rdi
je 0xd901
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x42a0
jmp 0xd901
movq %rax, %rbx
movq 0x10(%rsp), %rdi
testq %rdi, %rdi
je 0xd918
movq 0x20(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
movq 0x30(%rsp), %rdi
testq %rdi, %rdi
je 0xd92f
movq 0x40(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
movq 0x50(%rsp), %rdi
testq %rdi, %rdi
je 0xd946
movq 0x60(%rsp), %rsi
subq %rdi, %rsi
callq 0x42a0
movq %rbx, %rdi
callq 0x4430