// File: /workspace/github_cpp_makefile_star2_O1/MichaelXanth[P]RPG_Game/Market/Market.cpp
// Function: Market::Sale(Hero&, int const&)
void Market::Sale(Hero& hero, const int& sellState)
{
    int  column, row;
    char confirmation;
    bool errFlag = false;
    string testSelections[2];

    cout << endl;
    cout << "-------------------------------" << endl << endl;
    cout << "(Type 0 to cancel)" << endl;

    if (sellState == 0) {
        cout << "Choose a Spell by selecting its position in the table(e.g.: \033[1;34m<\033[1;33mcolumn\033[1;34m> <\033[1;33mrow\033[1;34m>\033[0m): ";

        cout << "\n\n\n\n\n\n\n\n";
        cout << "\033[8A\033[77C";
    
    } else if (sellState == 1) {
        cout << "Choose an Item by selecting its position in the table(e.g.: \033[1;34m<\033[1;33mcolumn\033[1;34m> <\033[1;33mrow\033[1;34m>\033[0m): ";

        cout << "\n\n\n\n\n\n\n\n";
        cout << "\033[8A\033[77C";
    
    } else {
        cout << "Choose an Item or a Spell by selecting its position in the table(e.g.: \033[1;34m<\033[1;33mcolumn\033[1;34m> <\033[1;33mrow\033[1;34m>\033[0m): ";

        cout << "\n\n\n\n\n\n\n\n";
        cout << "\033[8A\033[88C";
    }

    cout << "\033[s";

    do {
        if (errFlag)
            usleep(1800000);

        cout << "\033[u";
        cout << "\033[J";
        cout << "\033[s";

        errFlag = true;

        cin >> testSelections[0];

        if (testSelections[0] == "0") {
            column = 0;
            break;
        }

        cin >> testSelections[1];
    } while(!hero.isValidForSale(testSelections,column,row,sellState));

    if (column == 0) {
        cout << endl << "\033[1;32mInfo:\033[0m The sale operation was canceled." << endl << endl;
        return;
    }

    switch(column)
    {
        case 1:
            if (sellState == 1) {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;166m" << hero.GetWeaponFromSlot(row - 1)->GetName() << "\033[0m\" Weapon? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemoveWeapon(row - 1);
            
            } else {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;32m" << hero.GetSpellFromSlot(row - 1, 2)->GetName() << "\033[0m\" Ice Spell? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemoveIceSpell(row - 1);
            }

            break;

        case 2:
            if (sellState == 1) {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;28m" << hero.GetArmorFromSlot(row - 1)->GetName() << "\033[0m\" Armor? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemoveArmor(row - 1);
            
            } else {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[1;31m" << hero.GetSpellFromSlot(row - 1, 3)->GetName() << "\033[0m\" Fire Spell? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemoveFireSpell(row - 1);
            }

            break;

        case 3:
            if (sellState == 1) {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;90m" << hero.GetPotionFromSlot(row - 1)->GetName() << "\033[0m\" Potion? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemovePotion(row - 1);
            
            } else {
                cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;15m" << hero.GetSpellFromSlot(row - 1, 1)->GetName() << "\033[0m\" Lighting Spell? [y/n]: ";

                do {
                    cin >> confirmation;
                } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

                if (confirmation == 'n' || confirmation == 'N')
                    break;

                hero.RemoveLightingSpell(row - 1);
            }

            break;

        case 4:
            cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;166m" << hero.GetWeaponFromSlot(row - 1)->GetName() << "\033[0m\" Weapon? [y/n]: ";

            do {
                cin >> confirmation;
            } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

            if (confirmation == 'n' || confirmation == 'N')
                break;

            hero.RemoveWeapon(row - 1);

            break;

        case 5:
            cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;28m" << hero.GetArmorFromSlot(row - 1)->GetName() << "\033[0m\" Armor? [y/n]: ";

            do {
                cin >> confirmation;
            } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

            if (confirmation == 'n' || confirmation == 'N')
                break;

            hero.RemoveArmor(row - 1);

            break;

        case 6:
            cout << endl << "Are you sure you want to sell \"\033[1m\033[38;5;90m" << hero.GetPotionFromSlot(row - 1)->GetName() << "\033[0m\" Potion? [y/n]: ";

            do {
                cin >> confirmation;
            } while(confirmation != 'y' && confirmation != 'Y' && confirmation != 'n' && confirmation != 'N');

            if (confirmation == 'n' || confirmation == 'N')
                break;

            hero.RemovePotion(row - 1);

            break;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x88, %rsp
movq %rdx, -0x60(%rbp)
movq %rsi, -0x38(%rbp)
movl $0x10, %eax
leaq (%rax,%rbp), %rcx
addq $-0xb0, %rcx
movq %rcx, -0x10(%rcx)
movq $0x0, -0x8(%rcx)
movb $0x0, (%rcx)
addq $0x20, %rax
cmpq $0x50, %rax
jne 0x21155
movq 0xde48(%rip), %rdi      # 0x2efc8
movq (%rdi), %rax
addq -0x18(%rax), %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xde2d(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq 0xde19(%rip), %rbx      # 0x2efc8
leaq 0x606c(%rip), %rsi      # 0x27222
movl $0x1f, %edx
movq %rbx, %rdi
callq 0x31e0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xdde7(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq 0xdda9(%rip), %rbx      # 0x2efc8
leaq 0x6147(%rip), %rsi      # 0x2736d
movl $0x12, %edx
movq %rbx, %rdi
callq 0x31e0
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xdd77(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq -0x60(%rbp), %rax
movl (%rax), %eax
cmpl $0x1, %eax
je 0x21276
testl %eax, %eax
jne 0x212af
leaq 0x610c(%rip), %rsi      # 0x27380
jmp 0x2127d
leaq 0x618b(%rip), %rsi      # 0x27408
movq 0xdd44(%rip), %rdi      # 0x2efc8
movl $0x74, %edx
callq 0x31e0
movq 0xdd33(%rip), %rdi      # 0x2efc8
leaq 0x6159(%rip), %rsi      # 0x273f5
movl $0x8, %edx
callq 0x31e0
leaq 0x6151(%rip), %rsi      # 0x273fe
jmp 0x212e6
movq 0xdd12(%rip), %rdi      # 0x2efc8
leaq 0x61c0(%rip), %rsi      # 0x2747d
movl $0x7f, %edx
callq 0x31e0
movq 0xdcfa(%rip), %rdi      # 0x2efc8
leaq 0x6120(%rip), %rsi      # 0x273f5
movl $0x8, %edx
callq 0x31e0
leaq 0x6217(%rip), %rsi      # 0x274fd
movq 0xdcdb(%rip), %rdi      # 0x2efc8
movl $0x9, %edx
callq 0x31e0
movq 0xdcca(%rip), %rdi      # 0x2efc8
leaq 0x3579(%rip), %rsi      # 0x2487e
movl $0x3, %edx
callq 0x31e0
movq 0xdcb2(%rip), %r15      # 0x2efc8
movq 0xdcbb(%rip), %r12      # 0x2efd8
leaq -0xb0(%rbp), %r13
leaq 0x61dc(%rip), %rbx      # 0x27507
leaq -0x30(%rbp), %r14
movl $0x3, %edx
movq %r15, %rdi
leaq 0x356a(%rip), %rsi      # 0x248a8
callq 0x31e0
movl $0x3, %edx
movq %r15, %rdi
leaq 0x5451(%rip), %rsi      # 0x267a3
callq 0x31e0
movl $0x3, %edx
movq %r15, %rdi
leaq 0x3518(%rip), %rsi      # 0x2487e
callq 0x31e0
movq %r12, %rdi
movq %r13, %rsi
callq 0x3230
movq %r13, %rdi
movq %rbx, %rsi
callq 0x3070
testl %eax, %eax
je 0x213be
movq %r12, %rdi
leaq -0x90(%rbp), %rsi
callq 0x3230
movq -0x38(%rbp), %rdi
movq %r13, %rsi
leaq -0x64(%rbp), %rdx
movq %r14, %rcx
movq -0x60(%rbp), %r8
callq 0x11242
testb %al, %al
jne 0x213c5
movl $0x1b7740, %edi         # imm = 0x1B7740
callq 0x3260
jmp 0x2132f
movl $0x0, -0x64(%rbp)
movl -0x64(%rbp), %eax
cmpq $0x6, %rax
ja 0x21cb4
leaq 0x5cd3(%rip), %rcx      # 0x270ac
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq (%r15), %rax
addq -0x18(%rax), %r15
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xdbc8(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x6419(%rip), %rsi      # 0x27830
movl $0x31, %edx
movq %rax, %rdi
callq 0x31e0
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3040
movq %rax, %rdi
callq 0x3100
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xdb30(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x63b3(%rip), %rsi      # 0x27862
movl $0x2e, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x116cc
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x614b(%rip), %rsi      # 0x27638
movl $0x15, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x2150c
callq 0x3170
movq 0xdac5(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21521
btq %rcx, %r15
jae 0x21521
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x10fa8
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq -0x60(%rbp), %rax
cmpl $0x1, (%rax)
jne 0x21a0b
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xda3c(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x631c(%rip), %rsi      # 0x278bf
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x11698
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x609a(%rip), %rsi      # 0x2767b
movl $0x14, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x21600
callq 0x3170
movq 0xd9d1(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21615
btq %rcx, %r15
jae 0x21615
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x1102e
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq -0x60(%rbp), %rax
cmpl $0x1, (%rax)
jne 0x21af1
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd948(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x6281(%rip), %rsi      # 0x27918
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x115e0
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5fe8(%rip), %rsi      # 0x276bd
movl $0x15, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x216f4
callq 0x3170
movq 0xd8dd(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21709
btq %rcx, %r15
jae 0x21709
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x110b4
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq -0x60(%rbp), %rax
cmpl $0x1, (%rax)
jne 0x21bd7
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd854(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x60d7(%rip), %rsi      # 0x27862
movl $0x2e, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x116cc
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5e6f(%rip), %rsi      # 0x27638
movl $0x15, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x217e8
callq 0x3170
movq 0xd7e9(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x217fd
btq %rcx, %r15
jae 0x217fd
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x10fa8
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd76d(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x604d(%rip), %rsi      # 0x278bf
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x11698
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5dcb(%rip), %rsi      # 0x2767b
movl $0x14, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x218cf
callq 0x3170
movq 0xd702(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x218e4
btq %rcx, %r15
jae 0x218e4
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x1102e
jmp 0x21cb4
movq (%r15), %rax
addq -0x18(%rax), %r15
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd686(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x5fbf(%rip), %rsi      # 0x27918
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
callq 0x115e0
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5d26(%rip), %rsi      # 0x276bd
movl $0x15, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x219b6
callq 0x3170
movq 0xd61b(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x219cb
btq %rcx, %r15
jae 0x219cb
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x110b4
jmp 0x21cb4
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd5a6(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x5eb4(%rip), %rsi      # 0x278ed
movl $0x2a, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
movl $0x3, %edx
callq 0x11220
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *0x8(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5b28(%rip), %rsi      # 0x275a5
movl $0x19, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x21a9c
callq 0x3170
movq 0xd535(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21ab1
btq %rcx, %r15
jae 0x21ab1
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x10ebc
jmp 0x21cb4
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd4c0(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x5e27(%rip), %rsi      # 0x27946
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
movl $0x1, %edx
callq 0x11220
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *0x8(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5a89(%rip), %rsi      # 0x275ec
movl $0x1d, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x21b82
callq 0x3170
movq 0xd44f(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21b97
btq %rcx, %r15
jae 0x21b97
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x10f32
jmp 0x21cb4
movq %r15, %rdi
movl $0xa, %esi
callq 0x3190
movsbl %al, %esi
movq 0xd3da(%rip), %rdi      # 0x2efc8
callq 0x3040
movq %rax, %rdi
callq 0x3100
movq %rax, %rbx
leaq 0x5c8c(%rip), %rsi      # 0x27891
movl $0x2d, %edx
movq %rax, %rdi
callq 0x31e0
movl -0x30(%rbp), %esi
decl %esi
movq -0x38(%rbp), %rdi
movl $0x2, %edx
callq 0x11220
movq (%rax), %rcx
leaq -0x58(%rbp), %rdi
movq %rax, %rsi
callq *0x8(%rcx)
movq -0x58(%rbp), %rsi
movq -0x50(%rbp), %rdx
movq %rbx, %rdi
callq 0x31e0
leaq 0x5919(%rip), %rsi      # 0x27562
movl $0x18, %edx
movq %rax, %rdi
callq 0x31e0
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x21c68
callq 0x3170
movq 0xd369(%rip), %rbx      # 0x2efd8
leaq -0x29(%rbp), %r14
movabsq $0x80100000801, %r15    # imm = 0x80100000801
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3250
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x21c7d
btq %rcx, %r15
jae 0x21c7d
andb $0x5f, %al
cmpb $0x4e, %al
je 0x21cb4
movl -0x30(%rbp), %eax
decl %eax
leaq -0x58(%rbp), %rsi
movl %eax, (%rsi)
movq -0x38(%rbp), %rdi
callq 0x10e46
leaq -0x80(%rbp), %rbx
xorl %r14d, %r14d
movq -0x90(%rbp,%r14), %rdi
leaq (%rbx,%r14), %rax
cmpq %rdi, %rax
je 0x21cd1
callq 0x3170
addq $-0x20, %r14
cmpq $-0x40, %r14
jne 0x21cbb
addq $0x88, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d1b
jmp 0x21d1b
jmp 0x21d1b
jmp 0x21d1b
jmp 0x21d1b
jmp 0x21d1b
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d1b
jmp 0x21d1b
movq %rax, %rbx
leaq -0x48(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x21d4f
callq 0x3170
jmp 0x21d4f
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
jmp 0x21d4c
movq %rax, %rbx
leaq -0x80(%rbp), %r14
xorl %r15d, %r15d
movq -0x90(%rbp,%r15), %rdi
leaq (%r14,%r15), %rax
cmpq %rdi, %rax
je 0x21d6c
callq 0x3170
addq $-0x20, %r15
cmpq $-0x40, %r15
jne 0x21d56
movq %rbx, %rdi
callq 0x32f0