// File: JacobLCarter[P]2D-Portal/utils.cpp
// Function: mainMenu()
int mainMenu()
{
    int choice;
    std::string logo;

    logo = "              .,-:;/;;:=,\n";
    logo += "         . :H@@@MM@M#H/.,+%;,\n";
    logo += "      ,/X+ +M@@M@MM%=,-%HMMM@X/,\n";
    logo += "    -+@MM; $M@@MH+-,;XMMMM@MMMM@+-\n";
    logo += "   ;@M@@M- XM@X;. -+XXXXXHHH@M@M#@/.\n";
    logo += " ,%MM@@MH ,@%=             .---=-=:=,.\n";
    logo += " =@#@@@MX.,                -%HX$$%%%:;\n";
    logo += "=-./@M@M$                   .;@MMMM@MM:\n";
    logo += "X@/ -$MM/       PORTAL       . +MM@@@M$\n";
    logo += "@M@H: :@:       ------       . =X#@@@@-\n";
    logo += "@@@MMX, .       1. Play      /H- ;@M@M=\n";
    logo += "H@@@@M@+,       2. Quit      %MM+..%#$.\n";
    logo += "/MMMM@MMH/.                  XM@MH; =;\n";
    logo += " /%+%$XHH@$=              , .H@@@@MX,\n";
    logo += "  .=--------.           -%H.,@@@@@MX,\n";
    logo += "  .%MM@@@HHHXX$$$%+- .:$MMX =M@@MM%.\n";
    logo += "    =XMMM@MM@MM#H;,-+HMM@M+ /MMMX=\n";
    logo += "      =%@M@M#@$-.=$@MM@@@M; %M%=\n";
    logo += "        ,:+$+-,/H#MMMMMMM@= =,\n";
    logo += "              =++%%%%+/:-.\n";


    
    do
    {
        std::cout << logo << std::endl << std::endl;
        std::cout << "Please enter a choice 1-2: ";
        
        choice = getInt(false);

        std::cout << std::endl;
    }
    while (setRange(choice, 1, 2) != 0);

    return choice;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
leaq -0x28(%rbp), %rdi
movq %rdi, -0x40(%rbp)
callq 0x3330
movq -0x40(%rbp), %rdi
leaq 0x33b7(%rip), %rsi      # 0xdb07
callq 0x3320
jmp 0xa757
leaq 0x33c4(%rip), %rsi      # 0xdb22
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa769
leaq 0x33d1(%rip), %rsi      # 0xdb41
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa77b
leaq 0x33e1(%rip), %rsi      # 0xdb63
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa78d
leaq 0x33f3(%rip), %rsi      # 0xdb87
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa79f
leaq 0x3407(%rip), %rsi      # 0xdbad
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa7b1
leaq 0x341d(%rip), %rsi      # 0xdbd5
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa7c3
leaq 0x3433(%rip), %rsi      # 0xdbfd
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa7d5
leaq 0x344a(%rip), %rsi      # 0xdc26
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa7e7
leaq 0x3461(%rip), %rsi      # 0xdc4f
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa7f9
leaq 0x3478(%rip), %rsi      # 0xdc78
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa80b
leaq 0x348f(%rip), %rsi      # 0xdca1
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa81d
leaq 0x34a6(%rip), %rsi      # 0xdcca
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa82f
leaq 0x34bc(%rip), %rsi      # 0xdcf2
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa841
leaq 0x34d1(%rip), %rsi      # 0xdd19
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa853
leaq 0x34e6(%rip), %rsi      # 0xdd40
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa865
leaq 0x34fa(%rip), %rsi      # 0xdd66
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa877
leaq 0x350c(%rip), %rsi      # 0xdd8a
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa889
leaq 0x351c(%rip), %rsi      # 0xddac
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa89b
leaq 0x352a(%rip), %rsi      # 0xddcc
leaq -0x28(%rbp), %rdi
callq 0x3200
jmp 0xa8ad
jmp 0xa8af
movq 0x871a(%rip), %rdi      # 0x12fd0
leaq -0x28(%rbp), %rsi
callq 0x31f0
movq %rax, -0x48(%rbp)
jmp 0xa8c5
movq -0x48(%rbp), %rdi
movq 0x86f0(%rip), %rsi      # 0x12fc0
callq 0x3240
movq %rax, -0x50(%rbp)
jmp 0xa8db
movq -0x50(%rbp), %rdi
movq 0x86da(%rip), %rsi      # 0x12fc0
callq 0x3240
jmp 0xa8ed
movq 0x86dc(%rip), %rdi      # 0x12fd0
leaq 0x34ed(%rip), %rsi      # 0xdde8
callq 0x3210
jmp 0xa902
xorl %edi, %edi
callq 0x9d80
movl %eax, -0x54(%rbp)
jmp 0xa90e
movl -0x54(%rbp), %eax
movl %eax, -0x4(%rbp)
movq 0x86b5(%rip), %rdi      # 0x12fd0
movq 0x869e(%rip), %rsi      # 0x12fc0
callq 0x3240
jmp 0xa929
jmp 0xa92b
movl -0x4(%rbp), %edi
movl $0x1, %esi
movl $0x2, %edx
callq 0xa410
cmpl $0x0, %eax
jne 0xa8af
movl -0x4(%rbp), %eax
movl %eax, -0x58(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x3140
movl -0x58(%rbp), %eax
addq $0x60, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x3140
movq -0x30(%rbp), %rdi
callq 0x33b0
nopl (%rax)