// File: BohangZhang[P]Sorcery-C-Project/player.cc
// Function: Player::inspect(int)
void Player::inspect(int i) {
    shared_ptr<Slot> s = this->slot;
    if (s->getSize() < i) {
        throw 11; // Number, You don't have enough minion
    }
    shared_ptr<Minion> m = s->getSlot()[i-1];
    shared_ptr<Minion> am = s->getSlot()[i-1];
    shared_ptr<vector<card_template_t>> temp {new vector<card_template_t>};
    while (1) {
        if ((m->getType() == "Minion") || (m->getType() == "Act_Minion") || (m->getType() == "Tri_Minion")) {
            am->print();
            break;
        } else {
            if (m->getName() == "Giant Strength") {
                temp->push_back(display_enchantment_attack_defence(m->getName(), m->getCost(), m->getEffect(), "+2", "+2"));
            } else {
                temp->push_back(display_enchantment(m->getName(), m->getCost(), m->getEffect()));
            }
            m = m->getOrigin();
        }
    }
    if (temp->size() == 0) {return;}
    int turn = temp->size() / 5;
    int left = temp->size() % 5;
    for (int k = 0; k < turn; ++k) {
        for (int i = 0; i < 11; ++i) {
            for (int j = 0; j < 5; ++j) { cout << (*temp)[j][i]; }
            cout << endl;
        }
    }
    for (int i = 0; i < 11; ++i) {
        for (int j = 0; j < left; ++j) { cout << (*temp)[j][i]; }
        cout << endl;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x280, %rsp            # imm = 0x280
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rsi
addq $0x48, %rsi
leaq -0x20(%rbp), %rdi
movq %rdi, -0x230(%rbp)
callq 0x3aa70
movq -0x230(%rbp), %rdi
callq 0x12af0
movq %rax, %rdi
callq 0x3d230
movl %eax, -0x224(%rbp)
jmp 0x314a6
movl -0x224(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x314ea
movl $0x4, %edi
callq 0x6160
movq %rax, %rdi
movl $0xb, (%rdi)
movq 0x22acd(%rip), %rsi     # 0x53f98
xorl %eax, %eax
movl %eax, %edx
callq 0x6430
jmp 0x31d7f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31d6d
leaq -0x20(%rbp), %rdi
callq 0x12af0
movq %rax, %rdi
callq 0x3d220
movq %rax, -0x238(%rbp)
jmp 0x31504
movq -0x238(%rbp), %rdi
movl -0xc(%rbp), %eax
decl %eax
movslq %eax, %rsi
callq 0x12c80
movq %rax, %rsi
leaq -0x40(%rbp), %rdi
callq 0x12c10
leaq -0x20(%rbp), %rdi
callq 0x12af0
movq %rax, %rdi
callq 0x3d220
movq %rax, -0x240(%rbp)
jmp 0x3153e
movq -0x240(%rbp), %rdi
movl -0xc(%rbp), %eax
decl %eax
movslq %eax, %rsi
callq 0x12c80
movq %rax, %rsi
leaq -0x50(%rbp), %rdi
callq 0x12c10
movl $0x18, %edi
callq 0x6290
movq %rax, -0x248(%rbp)
jmp 0x31571
movq -0x248(%rbp), %rdi
callq 0x28780
movq -0x248(%rbp), %rsi
leaq -0x60(%rbp), %rdi
callq 0x3add0
jmp 0x3158f
jmp 0x31591
jmp 0x31593
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
movb $0x0, -0xa1(%rbp)
movb $0x0, -0xc9(%rbp)
leaq -0x80(%rbp), %rdi
callq 0x19c20
jmp 0x315b8
leaq 0x1026e(%rip), %rsi     # 0x4182d
leaq -0x80(%rbp), %rdi
callq 0x12920
movb %al, -0x249(%rbp)
jmp 0x315d0
movb -0x249(%rbp), %cl
movb $0x1, %al
testb $0x1, %cl
movb %al, -0x24a(%rbp)
jne 0x31684
jmp 0x315e9
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0xa0(%rbp), %rdi
callq 0x19c20
jmp 0x31603
movb $0x1, -0xa1(%rbp)
leaq 0x1020d(%rip), %rsi     # 0x4181e
leaq -0xa0(%rbp), %rdi
callq 0x12920
movb %al, -0x24b(%rbp)
jmp 0x31625
movb -0x24b(%rbp), %cl
movb $0x1, %al
testb $0x1, %cl
movb %al, -0x24a(%rbp)
jne 0x31684
jmp 0x3163a
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0xc8(%rbp), %rdi
callq 0x19c20
jmp 0x31654
movb $0x1, -0xc9(%rbp)
leaq 0x101c7(%rip), %rsi     # 0x41829
leaq -0xc8(%rbp), %rdi
callq 0x12920
movb %al, -0x24c(%rbp)
jmp 0x31676
movb -0x24c(%rbp), %al
movb %al, -0x24a(%rbp)
jmp 0x31684
movb -0x24a(%rbp), %al
movb %al, -0x24d(%rbp)
testb $0x1, -0xc9(%rbp)
jne 0x3169b
jmp 0x316a7
leaq -0xc8(%rbp), %rdi
callq 0x64c8
testb $0x1, -0xa1(%rbp)
jne 0x316b2
jmp 0x316be
leaq -0xa0(%rbp), %rdi
callq 0x64c8
leaq -0x80(%rbp), %rdi
callq 0x64c8
movb -0x24d(%rbp), %al
testb $0x1, %al
jne 0x316d6
jmp 0x3178d
leaq -0x50(%rbp), %rdi
callq 0x12d30
movq %rax, %rdi
movq (%rdi), %rax
movq 0x58(%rax), %rax
callq *%rax
jmp 0x316ed
jmp 0x31b3a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31d64
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31d5b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31d52
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x3177f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31766
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
testb $0x1, -0xc9(%rbp)
jne 0x31758
jmp 0x31764
leaq -0xc8(%rbp), %rdi
callq 0x64c8
jmp 0x31766
testb $0x1, -0xa1(%rbp)
jne 0x31771
jmp 0x3177d
leaq -0xa0(%rbp), %rdi
callq 0x64c8
jmp 0x3177f
leaq -0x80(%rbp), %rdi
callq 0x64c8
jmp 0x31d52
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0xf0(%rbp), %rdi
callq 0x19bf0
jmp 0x317a7
leaq 0x101d6(%rip), %rsi     # 0x41984
leaq -0xf0(%rbp), %rdi
callq 0x12920
movb %al, -0x24e(%rbp)
jmp 0x317c2
leaq -0xf0(%rbp), %rdi
callq 0x64c8
movb -0x24e(%rbp), %al
testb $0x1, %al
jne 0x317dd
jmp 0x319f0
leaq -0x60(%rbp), %rdi
callq 0x3ae00
movq %rax, -0x258(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0x128(%rbp), %rdi
callq 0x19bf0
jmp 0x31807
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rdi
callq 0x19c80
movl %eax, -0x25c(%rbp)
jmp 0x31820
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0x148(%rbp), %rdi
callq 0x19c50
jmp 0x3183a
leaq -0x169(%rbp), %rdi
movq %rdi, -0x268(%rbp)
callq 0x6470
movq -0x268(%rbp), %rdx
leaq 0x10290(%rip), %rsi     # 0x41aeb
leaq -0x168(%rbp), %rdi
callq 0x12870
jmp 0x31869
leaq -0x191(%rbp), %rdi
movq %rdi, -0x270(%rbp)
callq 0x6470
movq -0x270(%rbp), %rdx
leaq 0x10261(%rip), %rsi     # 0x41aeb
leaq -0x190(%rbp), %rdi
callq 0x12870
jmp 0x31898
movl -0x25c(%rbp), %edx
leaq -0x108(%rbp), %rdi
leaq -0x128(%rbp), %rsi
leaq -0x148(%rbp), %rcx
leaq -0x168(%rbp), %r8
leaq -0x190(%rbp), %r9
callq 0x18250
jmp 0x318c8
movq -0x258(%rbp), %rdi
leaq -0x108(%rbp), %rsi
callq 0x3ae20
jmp 0x318dd
leaq -0x108(%rbp), %rdi
callq 0x15d90
leaq -0x190(%rbp), %rdi
callq 0x64c8
leaq -0x191(%rbp), %rdi
callq 0x62f0
leaq -0x168(%rbp), %rdi
callq 0x64c8
leaq -0x169(%rbp), %rdi
callq 0x62f0
leaq -0x148(%rbp), %rdi
callq 0x64c8
leaq -0x128(%rbp), %rdi
callq 0x64c8
jmp 0x31afb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0x64c8
jmp 0x31d52
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x319df
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x319c7
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x319af
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x319a3
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x108(%rbp), %rdi
callq 0x15d90
leaq -0x190(%rbp), %rdi
callq 0x64c8
leaq -0x191(%rbp), %rdi
callq 0x62f0
leaq -0x168(%rbp), %rdi
callq 0x64c8
leaq -0x169(%rbp), %rdi
callq 0x62f0
leaq -0x148(%rbp), %rdi
callq 0x64c8
leaq -0x128(%rbp), %rdi
callq 0x64c8
jmp 0x31d52
leaq -0x60(%rbp), %rdi
callq 0x3ae00
movq %rax, -0x278(%rbp)
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0x1d0(%rbp), %rdi
callq 0x19bf0
jmp 0x31a1a
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rdi
callq 0x19c80
movl %eax, -0x27c(%rbp)
jmp 0x31a33
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
leaq -0x1f0(%rbp), %rdi
callq 0x19c50
jmp 0x31a4d
movl -0x27c(%rbp), %edx
leaq -0x1b0(%rbp), %rdi
leaq -0x1d0(%rbp), %rsi
leaq -0x1f0(%rbp), %rcx
callq 0x17cf0
jmp 0x31a6f
movq -0x278(%rbp), %rdi
leaq -0x1b0(%rbp), %rsi
callq 0x3ae20
jmp 0x31a84
leaq -0x1b0(%rbp), %rdi
callq 0x15d90
leaq -0x1f0(%rbp), %rdi
callq 0x64c8
leaq -0x1d0(%rbp), %rdi
callq 0x64c8
jmp 0x31afb
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31aea
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
jmp 0x31ade
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x1b0(%rbp), %rdi
callq 0x15d90
leaq -0x1f0(%rbp), %rdi
callq 0x64c8
leaq -0x1d0(%rbp), %rdi
callq 0x64c8
jmp 0x31d52
leaq -0x40(%rbp), %rdi
callq 0x12d30
movq %rax, %rsi
movq (%rsi), %rax
movq 0x68(%rax), %rax
leaq -0x200(%rbp), %rdi
callq *%rax
jmp 0x31b19
leaq -0x40(%rbp), %rdi
leaq -0x200(%rbp), %rsi
callq 0x21670
leaq -0x200(%rbp), %rdi
callq 0x12d50
jmp 0x31591
leaq -0x60(%rbp), %rdi
callq 0x3ae00
movq %rax, %rdi
callq 0x28890
cmpq $0x0, %rax
jne 0x31b60
movl $0x1, -0x204(%rbp)
jmp 0x31d25
leaq -0x60(%rbp), %rdi
callq 0x3ae00
movq %rax, %rdi
callq 0x28890
movl $0x5, %ecx
xorl %edx, %edx
divq %rcx
movl %eax, -0x208(%rbp)
leaq -0x60(%rbp), %rdi
callq 0x3ae00
movq %rax, %rdi
callq 0x28890
movl $0x5, %ecx
xorl %edx, %edx
divq %rcx
movl %edx, %eax
movl %eax, -0x20c(%rbp)
movl $0x0, -0x210(%rbp)
movl -0x210(%rbp), %eax
cmpl -0x208(%rbp), %eax
jge 0x31c76
movl $0x0, -0x214(%rbp)
cmpl $0xb, -0x214(%rbp)
jge 0x31c60
movl $0x0, -0x218(%rbp)
cmpl $0x5, -0x218(%rbp)
jge 0x31c35
leaq -0x60(%rbp), %rdi
callq 0x3ae50
movq %rax, %rdi
movslq -0x218(%rbp), %rsi
callq 0x288c0
movq %rax, %rdi
movslq -0x214(%rbp), %rsi
callq 0x288e0
movq %rax, %rsi
movq 0x223ad(%rip), %rdi     # 0x53fc8
callq 0x6250
jmp 0x31c22
jmp 0x31c24
movl -0x218(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x218(%rbp)
jmp 0x31be1
movq 0x2238c(%rip), %rdi     # 0x53fc8
movq 0x22365(%rip), %rsi     # 0x53fa8
callq 0x62d0
jmp 0x31c4a
jmp 0x31c4c
movl -0x214(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x214(%rbp)
jmp 0x31bca
jmp 0x31c62
movl -0x210(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x210(%rbp)
jmp 0x31bae
movl $0x0, -0x21c(%rbp)
cmpl $0xb, -0x21c(%rbp)
jge 0x31d1b
movl $0x0, -0x220(%rbp)
movl -0x220(%rbp), %eax
cmpl -0x20c(%rbp), %eax
jge 0x31cf0
leaq -0x60(%rbp), %rdi
callq 0x3ae50
movq %rax, %rdi
movslq -0x220(%rbp), %rsi
callq 0x288c0
movq %rax, %rdi
movslq -0x21c(%rbp), %rsi
callq 0x288e0
movq %rax, %rsi
movq 0x222f2(%rip), %rdi     # 0x53fc8
callq 0x6250
jmp 0x31cdd
jmp 0x31cdf
movl -0x220(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x220(%rbp)
jmp 0x31c97
movq 0x222d1(%rip), %rdi     # 0x53fc8
movq 0x222aa(%rip), %rsi     # 0x53fa8
callq 0x62d0
jmp 0x31d05
jmp 0x31d07
movl -0x21c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x21c(%rbp)
jmp 0x31c80
movl $0x0, -0x204(%rbp)
leaq -0x60(%rbp), %rdi
callq 0x3ae80
leaq -0x50(%rbp), %rdi
callq 0x12d50
leaq -0x40(%rbp), %rdi
callq 0x12d50
leaq -0x20(%rbp), %rdi
callq 0x12b30
addq $0x280, %rsp            # imm = 0x280
popq %rbp
retq
leaq -0x60(%rbp), %rdi
callq 0x3ae80
leaq -0x50(%rbp), %rdi
callq 0x12d50
leaq -0x40(%rbp), %rdi
callq 0x12d50
leaq -0x20(%rbp), %rdi
callq 0x12b30
movq -0x28(%rbp), %rdi
callq 0x6460
nop