// File: malcolmyeh[P]CC3K/floor.cc
// Function: Floor::seePotion[abi:cxx11](Posn)
std::string Floor::seePotion(Posn p){
	for (int i = 0; i < potions.size(); ++i){
		if (potions.at(i)->getSymbol() == 'P' && potions.at(i)->withinRange(p)) {
			if(potions.at(i)->getType() == "RH"){
				if (knownPotion[0]){
					return "You see a Restore Health potion. ";
				}
			} else if (potions.at(i)->getType() == "BA"){
				if (knownPotion[1]){
					return "You see a Boost potion. ";
				}
			} else if (potions.at(i)->getType() == "BD"){
				if (knownPotion[2]){
					return "You see a Boost Defense potion. ";
				}				
			} else if (potions.at(i)->getType() == "PH"){
				if (knownPotion[3]){
					return "You see a Poison Health potion. ";
				}				
			} else if (potions.at(i)->getType() == "WA"){
				if (knownPotion[4]){
					return "You see a Wound Attack potion. ";
				}				
			} else if (potions.at(i)->getType() == "WD"){
				if (knownPotion[5]){
					return "You see a Wound Defense potion. ";
				}			
			}
			return "You see an unknown potion. ";			
		}
	}
	return "invalid";
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1e0, %rsp            # imm = 0x1E0
movq %rdi, -0x138(%rbp)
movq %rdi, %rax
movq %rax, -0x130(%rbp)
movq %rdi, -0x8(%rbp)
movq %rdx, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq %rax, -0x128(%rbp)
movl $0x0, -0x1c(%rbp)
movq -0x128(%rbp), %rdi
movslq -0x1c(%rbp), %rax
movq %rax, -0x140(%rbp)
addq $0x7f0, %rdi            # imm = 0x7F0
callq 0xd3d0
movq %rax, %rcx
movq -0x140(%rbp), %rax
cmpq %rcx, %rax
jae 0xa8a3
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rdi
callq 0x17b60
movsbl %al, %eax
cmpl $0x50, %eax
jne 0xa893
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rdi
movq -0x10(%rbp), %rax
movq %rax, -0x24(%rbp)
movq -0x24(%rbp), %rsi
callq 0x17b90
testb $0x1, %al
jne 0xa2aa
jmp 0xa893
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0x48(%rbp), %rdi
movq %rdi, -0x150(%rbp)
callq 0x18df0
movq -0x150(%rbp), %rdi
leaq 0x13f2a(%rip), %rsi     # 0x1e20c
callq 0x5210
movb %al, -0x141(%rbp)
jmp 0xa2ef
leaq -0x48(%rbp), %rdi
callq 0x4130
movb -0x141(%rbp), %al
testb $0x1, %al
jne 0xa307
jmp 0xa38a
movq -0x128(%rbp), %rax
testb $0x1, 0xff0(%rax)
je 0xa385
leaq -0x55(%rbp), %rdi
movq %rdi, -0x158(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x158(%rbp), %rdx
leaq 0x13f82(%rip), %rsi     # 0x1e2be
callq 0x4270
jmp 0xa343
leaq -0x55(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x48(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x55(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa839
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0x78(%rbp), %rdi
movq %rdi, -0x168(%rbp)
callq 0x18df0
movq -0x168(%rbp), %rdi
leaq 0x13e4d(%rip), %rsi     # 0x1e20f
callq 0x5210
movb %al, -0x159(%rbp)
jmp 0xa3cf
leaq -0x78(%rbp), %rdi
callq 0x4130
movb -0x159(%rbp), %al
testb $0x1, %al
jne 0xa3e7
jmp 0xa46a
movq -0x128(%rbp), %rax
testb $0x1, 0xff1(%rax)
je 0xa465
leaq -0x79(%rbp), %rdi
movq %rdi, -0x170(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x170(%rbp), %rdx
leaq 0x13ec4(%rip), %rsi     # 0x1e2e0
callq 0x4270
jmp 0xa423
leaq -0x79(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x78(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x79(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa837
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0xa0(%rbp), %rdi
movq %rdi, -0x180(%rbp)
callq 0x18df0
movq -0x180(%rbp), %rdi
leaq 0x13d6d(%rip), %rsi     # 0x1e212
callq 0x5210
movb %al, -0x171(%rbp)
jmp 0xa4b2
leaq -0xa0(%rbp), %rdi
callq 0x4130
movb -0x171(%rbp), %al
testb $0x1, %al
jne 0xa4cd
jmp 0xa55c
movq -0x128(%rbp), %rax
testb $0x1, 0xff2(%rax)
je 0xa557
leaq -0xa1(%rbp), %rdi
movq %rdi, -0x188(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x188(%rbp), %rdx
leaq 0x13df4(%rip), %rsi     # 0x1e2f9
callq 0x4270
jmp 0xa50c
leaq -0xa1(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xa0(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xa1(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa835
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0xc8(%rbp), %rdi
movq %rdi, -0x198(%rbp)
callq 0x18df0
movq -0x198(%rbp), %rdi
leaq 0x13c7e(%rip), %rsi     # 0x1e215
callq 0x5210
movb %al, -0x189(%rbp)
jmp 0xa5a4
leaq -0xc8(%rbp), %rdi
callq 0x4130
movb -0x189(%rbp), %al
testb $0x1, %al
jne 0xa5bf
jmp 0xa64e
movq -0x128(%rbp), %rax
testb $0x1, 0xff3(%rax)
je 0xa649
leaq -0xc9(%rbp), %rdi
movq %rdi, -0x1a0(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x1a0(%rbp), %rdx
leaq 0x13d23(%rip), %rsi     # 0x1e31a
callq 0x4270
jmp 0xa5fe
leaq -0xc9(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xc8(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xc9(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa833
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0xf0(%rbp), %rdi
movq %rdi, -0x1b0(%rbp)
callq 0x18df0
movq -0x1b0(%rbp), %rdi
leaq 0x13b8f(%rip), %rsi     # 0x1e218
callq 0x5210
movb %al, -0x1a1(%rbp)
jmp 0xa696
leaq -0xf0(%rbp), %rdi
callq 0x4130
movb -0x1a1(%rbp), %al
testb $0x1, %al
jne 0xa6b1
jmp 0xa740
movq -0x128(%rbp), %rax
testb $0x1, 0xff4(%rax)
je 0xa73b
leaq -0xf1(%rbp), %rdi
movq %rdi, -0x1b8(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x1b8(%rbp), %rdx
leaq 0x13c52(%rip), %rsi     # 0x1e33b
callq 0x4270
jmp 0xa6f0
leaq -0xf1(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xf0(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0xf1(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa831
movq -0x128(%rbp), %rdi
addq $0x7f0, %rdi            # imm = 0x7F0
movslq -0x1c(%rbp), %rsi
callq 0xd3f0
movq (%rax), %rsi
leaq -0x118(%rbp), %rdi
movq %rdi, -0x1c8(%rbp)
callq 0x18df0
movq -0x1c8(%rbp), %rdi
leaq 0x13aa0(%rip), %rsi     # 0x1e21b
callq 0x5210
movb %al, -0x1b9(%rbp)
jmp 0xa788
leaq -0x118(%rbp), %rdi
callq 0x4130
movb -0x1b9(%rbp), %al
testb $0x1, %al
jne 0xa7a3
jmp 0xa82f
movq -0x128(%rbp), %rax
testb $0x1, 0xff5(%rax)
je 0xa82d
leaq -0x119(%rbp), %rdi
movq %rdi, -0x1d0(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x1d0(%rbp), %rdx
leaq 0x13b80(%rip), %rsi     # 0x1e35b
callq 0x4270
jmp 0xa7e2
leaq -0x119(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x118(%rbp), %rdi
callq 0x4130
jmp 0xa90a
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x119(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa82f
jmp 0xa831
jmp 0xa833
jmp 0xa835
jmp 0xa837
jmp 0xa839
leaq -0x11a(%rbp), %rdi
movq %rdi, -0x1d8(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x1d8(%rbp), %rdx
leaq 0x13b1b(%rip), %rsi     # 0x1e37c
callq 0x4270
jmp 0xa868
leaq -0x11a(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x11a(%rbp), %rdi
callq 0x4200
jmp 0xa90a
jmp 0xa895
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0xa21a
leaq -0x11b(%rbp), %rdi
movq %rdi, -0x1e0(%rbp)
callq 0x4300
movq -0x138(%rbp), %rdi
movq -0x1e0(%rbp), %rdx
leaq 0x139a1(%rip), %rsi     # 0x1e26c
callq 0x4270
jmp 0xa8d2
leaq -0x11b(%rbp), %rdi
callq 0x4200
jmp 0xa8fa
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x50(%rbp)
movl %eax, -0x54(%rbp)
leaq -0x11b(%rbp), %rdi
callq 0x4200
jmp 0xa90a
movq -0x130(%rbp), %rax
addq $0x1e0, %rsp            # imm = 0x1E0
popq %rbp
retq
movq -0x50(%rbp), %rdi
callq 0x42f0
nopw %cs:(%rax,%rax)