Function at 0x522490
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0xd4
push ebx
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
mov ecx, dword [edi]
xor eax, eax
inc eax
xor ebx, ebx
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], ecx
cmp esi, ebx
je 0x523190
cmp byte [ecx + 0x1e], bl
jne 0x523190
cmp dword [edi + 0x40], ebx
jne 0x523190
push ebx
push ebx
push ebx
push 0x15
mov eax, edi
call fcn.005139c6
add esp, 0x10
test eax, eax
je 0x5224e9
xor eax, eax
inc eax
jmp 0x523190
push 0x2c
lea eax, [esp + 0x70]
push ebx
push eax
call fcn.0054ff70
mov eax, dword [ebp + 0x10]
add esp, 0xc
cmp byte [eax], 4
ja 0x52251d
push dword [esp + 0x28]
mov edi, dword [esi + 0x18]
call fcn.0050f9b1
mov edi, dword [ebp + 8]
mov eax, 0xfffe
and word [esi + 6], ax
pop ecx
mov dword [esi + 0x18], ebx
push ebx
push esi
push edi
call fcn.00522182
mov eax, dword [esi + 0x18]
mov dword [esp + 0x38], eax
mov eax, dword [esi + 8]
mov dword [esp + 0x48], eax
mov eax, dword [esi]
add esp, 0xc
mov dword [esp + 0x48], eax
cmp dword [edi + 0x40], ebx
jne 0x52316c
mov eax, dword [esp + 0x28]
cmp byte [eax + 0x1e], bl
jne 0x52316c
movzx eax, word [esi + 6]
mov edi, dword [ebp + 8]
shr eax, 2
and eax, 1
mov dword [esp + 0x38], eax
call fcn.00520245
mov dword [esp + 0x10], eax
cmp eax, ebx
je 0x52316c
mov ecx, dword [esp + 0x48]
cmp dword [ecx], 1
mov edi, dword [ebp + 0x10]
movzx eax, byte [edi]
jle 0x5225a0
cmp eax, 6
je 0x52258d
cmp eax, 7
jne 0x5225a0
mov edi, dword [ebp + 8]
push str.only_a_single_result_allowed_for_a_SELECT_that_is_part_of_an_expression
call fcn.004f4a08
pop ecx
jmp 0x52316c
mov dword [esp + 0x34], ebx
jmp 0x5226ca
mov eax, dword [esp + 0x3c]
movsx ecx, word [eax]
cmp dword [esp + 0x34], ecx
jge 0x5226d3
mov ecx, dword [esp + 0x34]
imul ecx, ecx, 0x38
lea eax, [ecx + eax + 8]
mov dword [esp + 0x20], eax
mov eax, dword [eax + 0x10]
mov dword [esp + 0x30], eax
cmp eax, ebx
je 0x5226c6
mov eax, dword [esp + 0x20]
cmp byte [eax + 0x14], bl
jne 0x5226c6
lea eax, [esp + 0x14]
mov ecx, esi
mov dword [esp + 0x14], ebx
call fcn.0050ed17
mov ecx, dword [esp + 0x14]
mov eax, dword [ebp + 8]
add dword [eax + 0x220], ecx
mov eax, dword [esp + 0x30]
movzx edi, word [eax + 6]
shr edi, 2
and edi, 1
push edi
push dword [esp + 0x3c]
mov eax, esi
push dword [esp + 0x3c]
push dword [ebp + 8]
call fcn.00521630
add esp, 0x10
test eax, eax
je 0x522641
cmp edi, ebx
je 0x52263a
or word [esi + 6], 4
mov dword [esp + 0x38], 1
or dword [esp + 0x34], 0xffffffff
jmp 0x522687
mov edi, dword [esp + 0x20]
mov eax, dword [edi + 0x18]
mov dword [esp + 0xb0], eax
lea eax, [esp + 0xac]
push eax
push dword [esp + 0x34]
mov byte [esp + 0xb4], 9
push dword [ebp + 8]
mov byte [esp + 0xb9], bl
mov dword [esp + 0xc0], ebx
mov dword [esp + 0xc4], ebx
call fcn.00522490
add esp, 0xc
mov byte [edi + 0x14], 1
mov eax, dword [esp + 0x28]
cmp byte [eax + 0x1e], bl
jne 0x52316c
lea eax, [esp + 0x14]
mov ecx, esi
mov dword [esp + 0x14], ebx
call fcn.0050ed17
mov eax, dword [ebp + 8]
mov ecx, dword [esp + 0x14]
sub dword [eax + 0x220], ecx
mov edi, dword [ebp + 0x10]
cmp byte [edi], 4
mov eax, dword [esi + 8]
mov dword [esp + 0x3c], eax
jbe 0x5226c6
mov eax, dword [esi + 0x18]
mov dword [esp + 0x2c], eax
inc dword [esp + 0x34]
cmp dword [esi + 0x1c], ebx
je 0x5225a9
mov eax, dword [esi + 0xc]
movzx ecx, word [esi + 6]
mov edx, dword [esi]
mov dword [esp + 0x40], eax
mov eax, dword [esi + 0x10]
mov dword [esp + 0x1c], eax
mov eax, dword [esi + 0x14]
mov dword [esp + 0x64], eax
mov eax, ecx
and eax, 1
mov dword [esp + 0x48], edx
mov dword [esp + 0x14], eax
cmp dword [esi + 0x1c], ebx
je 0x52274f
cmp dword [esi + 0x24], ebx
jne 0x52273d
xor ecx, ecx
xor edx, edx
mov eax, esi
mov dword [eax + 0x20], ecx
mov dword [eax + 0x24], esi
mov ecx, eax
mov eax, dword [eax + 0x1c]
inc edx
cmp eax, ebx
jne 0x52270b
mov eax, dword [esp + 0x28]
mov eax, dword [eax + 0x58]
cmp eax, ebx
je 0x52273d
cmp edx, eax
jle 0x52273d
mov edi, dword [ebp + 8]
push str.too_many_terms_in_compound_SELECT
call fcn.004f4a08
pop ecx
jmp 0x5224e1
push edi
push dword [ebp + 8]
mov eax, esi
call fcn.005203f5
pop ecx
pop ecx
jmp 0x523190
and cl, 5
cmp cl, 1
jne 0x52277a
push ebx
push dword [esp + 0x2c]
mov ebx, edx
call fcn.0050f552
mov dword [esi + 0x10], eax
mov dword [esp + 0x24], eax
mov eax, 0xfffe
and word [esi + 6], ax
and dword [esp + 0x1c], 0
pop ecx
pop ecx
mov ebx, dword [esp + 0x2c]
mov edi, dword [esi + 0x10]
call fcn.005119aa
test eax, eax
jne 0x522799
mov eax, dword [esp + 0x28]
test byte [eax + 0xc], 0x20
jne 0x522799
and dword [esp + 0x2c], 0
mov edi, dword [esp + 0x2c]
mov ebx, dword [ebp + 8]
test edi, edi
je 0x5227d8
push edi
push ebx
call fcn.0051f92c
mov ecx, dword [ebx + 0x44]
push 0xfffffffffffffff0
push eax
mov dword [edi + 8], ecx
inc dword [ebx + 0x44]
mov eax, dword [edi]
push 0
inc eax
inc eax
push eax
push dword [edi + 8]
push 0x29
push dword [esp + 0x30]
call fcn.00504691
add esp, 0x24
mov dword [esp + 0x20], eax
mov dword [esi + 0x40], eax
jmp 0x5227dd
or dword [esp + 0x20], 0xffffffff
mov eax, dword [ebp + 0x10]
cmp byte [eax], 9
jne 0x5227fc
mov ecx, dword [esp + 0x48]
push dword [ecx]
push dword [eax + 4]
mov eax, dword [esp + 0x18]
push 0x29
call fcn.0050467a
add esp, 0xc
mov eax, dword [esp + 0x10]
call fcn.005046f0
push eax
mov dword [esp + 0xac], eax
push esi
mov eax, ebx
call fcn.0052026e
cmp dword [esp + 0x1c], 0
pop ecx
pop ecx
je 0x522859
mov edi, dword [ebx + 0x44]
lea eax, [edi + 1]
mov dword [ebx + 0x44], eax
push dword [esi]
mov dword [esp + 0xa4], edi
push ebx
call fcn.0051f92c
push 0xfffffffffffffff0
push eax
push 0
push 0
push edi
push 0x29
push dword [esp + 0x30]
call fcn.00504691
mov ecx, dword [esp + 0x34]
add esp, 0x24
mov dl, 0x10
call fcn.005048ab
jmp 0x522861
or dword [esp + 0xa0], 0xffffffff
cmp dword [esp + 0x38], 0
mov edx, dword [esp + 0x1c]
jne 0x5228dd
test edx, edx
jne 0x5228e1
push edx
lea eax, [esp + 0x30]
push eax
push dword [esp + 0x48]
push dword [esp + 0x48]
push ebx
call fcn.005294d4
mov edi, eax
add esp, 0x14
test edi, edi
je 0x52316c
mov ecx, dword [esp + 0x20]
test ecx, ecx
jl 0x5228b0
cmp dword [esp + 0x2c], 0
jne 0x5228b0
mov eax, dword [esp + 0x10]
push 1
call fcn.005049df
or dword [esi + 0x40], 0xffffffff
pop ecx
push dword [edi + 0x14]
mov eax, dword [ebp + 0x10]
push dword [edi + 0x10]
push 0xffffffffffffffff
push dword [esp + 0x38]
push 0
push 0
push dword [esp + 0x60]
push esi
push dword [ebp + 8]
call fcn.0051f608
add esp, 0x24
call fcn.00529d92
jmp 0x52311c
test edx, edx
je 0x522915
mov esi, dword [esi]
mov eax, dword [esi]
mov esi, dword [esi + 0xc]
test eax, eax
jle 0x5228fc
lea ecx, [esi + 0x10]
xor esi, esi
mov word [ecx], si
dec eax
add ecx, 0x14
test eax, eax
jg 0x5228ef
mov eax, dword [edx]
mov ecx, dword [edx + 0xc]
test eax, eax
jle 0x522915
add ecx, 0x10
xor edx, edx
mov word [ecx], dx
dec eax
add ecx, 0x14
test eax, eax
jg 0x522908
mov eax, dword [esp + 0x10]
call fcn.005046f0
mov dword [esp + 0x44], eax
xor eax, eax
push 9
pop ecx
lea edi, [esp + 0xbc]
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x3c]
mov dword [esp + 0xc0], eax
lea eax, [esp + 0x6c]
mov dword [esp + 0xd8], eax
mov eax, dword [esp + 0x1c]
mov dword [esp + 0xbc], ebx
test eax, eax
je 0x52295e
mov eax, dword [eax]
inc eax
mov dword [esp + 0x78], eax
jmp 0x522963
and dword [esp + 0x78], 0
mov eax, dword [esp + 0x1c]
mov esi, dword [esp + 0x48]
mov dword [esp + 0x74], eax
lea eax, [esp + 0xbc]
push eax
call fcn.00511ca3
mov esi, dword [esp + 0x30]
pop ecx
lea eax, [esp + 0xbc]
push eax
call fcn.00511ca3
xor edi, edi
pop ecx
cmp dword [esp + 0x64], edi
je 0x5229a8
push dword [esp + 0x64]
lea eax, [esp + 0xc0]
call fcn.00511c7c
pop ecx
mov eax, dword [esp + 0x80]
xor ebx, ebx
cmp dword [esp + 0x90], edi
mov dword [esp + 0x88], eax
jle 0x5229e9
mov eax, dword [esp + 0x8c]
mov eax, dword [edi + eax]
mov esi, dword [eax + 0x10]
lea ecx, [esp + 0xbc]
push ecx
call fcn.00511ca3
inc ebx
add edi, 0x10
cmp ebx, dword [esp + 0x94]
pop ecx
jl 0x5229c1
mov eax, dword [esp + 0x28]
cmp byte [eax + 0x1e], 0
jne 0x52316c
mov esi, dword [esp + 0x1c]
test esi, esi
je 0x522ee3
mov ebx, dword [ebp + 8]
mov eax, dword [ebx + 0x44]
mov dword [esp + 0x70], eax
inc eax
push esi
push ebx
mov dword [ebx + 0x44], eax
call fcn.0051f92c
push 0xfffffffffffffff0
push eax
push 0
push dword [esp + 0x8c]
mov dword [esp + 0x74], eax
push dword [esp + 0x88]
push 0x29
push dword [esp + 0x30]
call fcn.00504691
mov dword [esp + 0x84], eax
mov eax, dword [ebx + 0x48]
add esp, 0x24
inc eax
lea edi, [eax + 1]
mov dword [esp + 0x30], eax
lea eax, [edi + 1]
mov dword [esp + 0x54], eax
mov dword [ebx + 0x48], eax
mov eax, dword [esp + 0x10]
mov dword [esp + 0x9c], edi
call fcn.005046f0
inc dword [ebx + 0x48]
mov dword [esp + 0x68], eax
mov eax, dword [ebx + 0x48]
mov dword [esp + 0x14], eax
mov eax, dword [esp + 0x10]
call fcn.005046f0
mov dword [esp + 0x20], eax
mov eax, dword [ebx + 0x48]
lea ecx, [eax + 1]
mov dword [esp + 0x98], ecx
mov ecx, dword [esi]
add eax, ecx
lea ecx, [eax + 1]
mov dword [ebx + 0x48], eax
mov dword [esp + 0x38], ecx
mov ecx, dword [esi]
xor esi, esi
push esi
push edi
add ecx, eax
mov eax, dword [esp + 0x18]
push esi
push 7
mov dword [ebx + 0x48], ecx
call fcn.005045fc
mov eax, dword [esp + 0x20]
push esi
push dword [esp + 0x44]
push esi
push 7
call fcn.005045fc
push dword [esp + 0x40]
mov eax, dword [esp + 0x34]
push dword [esp + 0x38]
push 2
call fcn.0050467a
add esp, 0x2c
push esi
lea eax, [esp + 0x20]
push eax
push dword [esp + 0x48]
push dword [esp + 0x48]
push ebx
call fcn.005294d4
add esp, 0x14
mov dword [esp + 0xa4], eax
cmp eax, esi
je 0x52316c
mov eax, dword [esp + 0x1c]
test eax, eax
jne 0x522b1e
mov eax, dword [ebp + 0xc]
mov eax, dword [eax + 0x10]
and dword [esp + 0x40], esi
mov dword [esp + 0x1c], eax
jmp 0x522c80
mov edi, dword [eax]
mov edx, dword [esp + 0x80]
lea eax, [edi + 1]
mov dword [esp + 0x40], 1
mov dword [esp + 0x24], eax
mov dword [esp + 0x50], eax
test edx, edx
jle 0x522b54
mov ecx, dword [esp + 0x7c]
add ecx, 0xc
cmp dword [ecx], eax
jl 0x522b4e
inc dword [esp + 0x50]
inc eax
add ecx, 0x18
dec edx
jne 0x522b45
mov esi, dword [esp + 0x50]
mov ecx, ebx
call fcn.00511d18
mov esi, eax
mov eax, ebx
call fcn.00510695
mov eax, dword [esp + 0x1c]
push 0
push ebx
mov ecx, esi
call fcn.005112f2
lea eax, [esi + edi]
push eax
push dword [esp + 0x7c]
mov eax, dword [esp + 0x20]
push 0x35
call fcn.0050467a
mov eax, dword [esp + 0x38]
and dword [esp + 0x48], 0
add esp, 0x14
cmp dword [esp + 0x80], 0
mov dword [esp + 0x4c], eax
jle 0x522c0e
add eax, esi
and dword [esp + 0x24], 0
mov dword [esp + 0x58], eax
mov ecx, dword [esp + 0x24]
mov eax, dword [esp + 0x7c]
add eax, ecx
mov ecx, dword [esp + 0x4c]
cmp dword [eax + 0xc], ecx
jl 0x522bf8
push dword [esp + 0x58]
mov edi, ebx
push dword [eax + 4]
push dword [eax + 8]
push dword [eax]
call fcn.0051061d
add esp, 0x10
cmp dword [esp + 0x58], eax
je 0x522bf0
push dword [esp + 0x58]
push eax
mov eax, dword [esp + 0x18]
push 0xf
call fcn.0050467a
add esp, 0xc
inc dword [esp + 0x4c]
inc dword [esp + 0x58]
inc dword [esp + 0x34]
mov eax, dword [esp + 0x34]
add dword [esp + 0x24], 0x18
cmp eax, dword [esp + 0x80]
jl 0x522bae
mov eax, ebx
call fcn.00511cc9
mov edi, eax
mov eax, dword [esp + 0x10]
push edi
push dword [esp + 0x54]
push esi
push 0x1e
call fcn.005045fc
mov eax, dword [esp + 0x20]
push edi
push dword [esp + 0x84]
push 0x46
call fcn.0050467a
add esp, 0x1c
mov edx, edi
mov eax, ebx
call fcn.00511ce4
mov edi, dword [esp + 0x50]
mov ecx, esi
call fcn.00511d3c
mov edi, dword [esp + 0xa4]
call fcn.00529d92
push dword [esp + 0x44]
mov eax, dword [esp + 0x14]
push dword [esp + 0x74]
push 0x40
call fcn.0050467a
add esp, 0xc
mov eax, ebx
mov byte [esp + 0x6d], 1
call fcn.00510695
mov eax, dword [esp + 0x10]
mov eax, dword [eax + 0xc]
mov dword [esp + 0x4c], eax
mov eax, ebx
call fcn.00510695
mov eax, dword [esp + 0x1c]
xor esi, esi
cmp dword [eax], esi
jle 0x522cee
mov dword [esp + 0x24], esi
cmp dword [esp + 0x40], 0
mov eax, dword [esp + 0x38]
je 0x522cc3
add eax, esi
push eax
mov eax, dword [esp + 0x14]
push esi
push dword [esp + 0x78]
push 0x1c
call fcn.005045fc
add esp, 0x10
jmp 0x522ce0
mov ecx, dword [esp + 0x24]
lea edi, [esi + eax]
mov eax, dword [esp + 0x1c]
mov byte [esp + 0x6c], 1
mov eax, dword [eax + 0xc]
mov eax, dword [eax + ecx]
mov ecx, ebx
call fcn.005111d3
mov eax, dword [esp + 0x1c]
add dword [esp + 0x24], 0x14
inc esi
cmp esi, dword [eax]
jl 0x522ca0
mov esi, dword [esp + 0x1c]
mov edi, dword [esp + 0x10]
push 0xfffffffffffffffa
push dword [esp + 0x60]
push dword [esi]
push dword [esp + 0x44]
push dword [esp + 0xa8]
push 0x18
push edi
call fcn.00504691
mov eax, dword [edi + 0xc]
add esp, 0x1c
mov dword [esp + 0x5c], eax
inc eax
push eax
push 0
push eax
push 0x19
mov eax, edi
call fcn.005045fc
push dword [esp + 0xa8]
mov ebx, dword [esi]
mov edi, dword [esp + 0x4c]
mov eax, dword [ebp + 8]
call fcn.005106b3
mov esi, dword [esp + 0x24]
add esp, 0x14
push dword [esp + 0x68]
mov eax, esi
push dword [esp + 0x58]
push 2
call fcn.0050467a
add esp, 0xc
push dword [esp + 0x44]
mov eax, esi
push dword [esp + 0xa0]
push 0x71
call fcn.0050467a
add esp, 0xc
push dword [esp + 0x20]
mov eax, esi
push dword [esp + 0x18]
push 2
call fcn.0050467a
mov edx, dword [esi + 0xc]
mov eax, dword [esp + 0x68]
add esp, 0xc
mov ecx, esi
call fcn.0050489b
lea eax, [esp + 0x6c]
push eax
push dword [ebp + 8]
call fcn.00522314
push 0
push dword [esp + 0x3c]
xor ebx, ebx
inc ebx
push ebx
push 7
mov eax, esi
call fcn.005045fc
add esp, 0x18
cmp dword [esp + 0x40], 0
je 0x522dd2
push dword [esp + 0x4c]
mov eax, esi
push dword [esp + 0x74]
push 0x43
call fcn.0050467a
add esp, 0xc
jmp 0x522deb
mov edi, dword [esp + 0xa4]
call fcn.00529d92
mov ecx, dword [esp + 0x60]
push ebx
mov eax, esi
call fcn.005049df
pop ecx
push dword [esp + 0x68]
mov eax, esi
push dword [esp + 0x58]
push 2
call fcn.0050467a
add esp, 0xc
xor edi, edi
push edi
push dword [esp + 0x48]
mov eax, esi
push edi
push ebx
call fcn.005045fc
mov eax, dword [esi + 0xc]
push edi
push dword [esp + 0xb0]
mov dword [esp + 0x78], eax
push ebx
push 7
mov eax, esi
call fcn.005045fc
push dword [esp + 0x74]
mov eax, esi
push 3
call fcn.00504665
mov edx, dword [esp + 0x90]
mov ecx, esi
call fcn.0050473c
mov ebx, dword [esi + 0xc]
lea eax, [ebx + 2]
push eax
push dword [esp + 0x5c]
mov eax, esi
push 0x71
call fcn.0050467a
add esp, 0x34
push dword [esp + 0x54]
mov eax, esi
push 3
call fcn.00504665
mov eax, dword [ebp + 8]
lea edi, [esp + 0x74]
call fcn.005222ca
push 8
inc ebx
push ebx
push dword [esp + 0x74]
push dword [ebp + 8]
call fcn.0051163c
push dword [esp + 0x78]
mov eax, dword [ebp + 0xc]
push ebx
push dword [esp + 0xc0]
push dword [esp + 0x50]
push 0
push 0
push dword [eax]
push eax
push dword [ebp + 8]
mov eax, dword [ebp + 0x10]
call fcn.0051f608
add esp, 0x3c
push dword [esp + 0x54]
mov eax, esi
push 3
call fcn.00504665
mov edx, dword [esp + 0x28]
mov ecx, esi
call fcn.0050473c
push dword [ebp + 8]
mov ebx, edi
call fcn.00522207
add esp, 0xc
push dword [esp + 0x14]
mov eax, esi
push 3
call fcn.00504665
pop ecx
jmp 0x52310d
and dword [esp + 0x30], 0
lea eax, [esp + 0x6c]
push eax
mov eax, dword [ebp + 0xc]
call fcn.00521b6f
mov edi, eax
pop ecx
test edi, edi
je 0x522fe7
mov ebx, dword [ebp + 8]
mov esi, dword [edi + 0x44]
mov ecx, dword [ebx]
call fcn.0051ea49
and dword [esp + 0x14], 0
and dword [esp + 0x60], 0
mov esi, eax
mov eax, dword [ebx + 0x44]
mov dword [esp + 0x20], eax
inc eax
mov dword [ebx + 0x44], eax
mov eax, dword [edi + 0x14]
mov dword [esp + 0x5c], eax
mov eax, ebx
call fcn.00516c5f
push dword [edi]
mov ebx, dword [edi + 0x14]
mov eax, dword [ebp + 8]
push 0
push esi
call fcn.00513a43
mov eax, dword [edi + 0x10]
xor ebx, ebx
add esp, 0xc
cmp eax, ebx
je 0x522f87
mov ecx, dword [esp + 0x60]
cmp ecx, ebx
je 0x522f5e
mov edx, dword [eax + 4]
cmp edx, dword [ecx + 4]
jge 0x522f60
mov ecx, eax
mov eax, dword [eax + 0x20]
cmp eax, ebx
jne 0x522f52
cmp ecx, ebx
je 0x522f87
mov eax, dword [ecx + 4]
cmp eax, dword [edi + 8]
jge 0x522f87
mov edi, dword [ecx + 0x14]
push ecx
push dword [ebp + 8]
call fcn.00516f60
pop ecx
pop ecx
mov dword [esp + 0x14], eax
jmp 0x522f8b
mov edi, dword [esp + 0x5c]
push esi
mov esi, dword [esp + 0x14]
push edi
push dword [esp + 0x28]
mov eax, esi
push 0x26
call fcn.005045fc
add esp, 0x10
cmp dword [esp + 0x14], ebx
je 0x522fb9
push 0xfffffffffffffff0
push dword [esp + 0x18]
or eax, 0xffffffff
push esi
call fcn.00504a1e
add esp, 0xc
mov eax, dword [esp + 0x8c]
push dword [eax + 8]
mov eax, esi
push dword [esp + 0x24]
push 0x1f
call fcn.0050467a
add esp, 0xc
push dword [esp + 0x20]
mov eax, esi
push 0x2b
call fcn.00504665
pop ecx
pop ecx
jmp 0x5230c5
mov eax, dword [ebp + 0xc]
and dword [esp + 0x14], 0
call fcn.00521aff
mov byte [esp + 0x1b], al
test al, al
je 0x52303f
mov eax, dword [ebp + 0xc]
mov eax, dword [eax]
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov esi, dword [esp + 0x28]
mov ebx, dword [eax + 0x10]
push 0
push esi
call fcn.0050f552
pop ecx
pop ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x30], eax
test eax, eax
je 0x52303f
cmp byte [esi + 0x1e], 0
jne 0x52303f
cmp byte [esp + 0x1b], 1
mov edx, dword [eax + 0xc]
setne cl
mov byte [edx + 0xc], cl
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
mov byte [eax], 0x98
mov esi, dword [ebp + 8]
push esi
lea ebx, [esp + 0x70]
call fcn.00522207
movzx ax, byte [esp + 0x1f]
pop ecx
movzx eax, ax
push eax
lea eax, [esp + 0x18]
push eax
push dword [esp + 0x48]
push dword [esp + 0x48]
push esi
call fcn.005294d4
mov edi, eax
xor ebx, ebx
add esp, 0x14
cmp edi, ebx
jne 0x523087
push dword [esp + 0x28]
mov edi, dword [esp + 0x34]
call fcn.0050f9b1
jmp 0x52259a
lea eax, [esp + 0x6c]
push eax
push esi
call fcn.00522314
pop ecx
pop ecx
cmp dword [esp + 0x14], ebx
jne 0x5230b3
cmp byte [esp + 0x1b], bl
je 0x5230b3
mov eax, dword [esp + 0x10]
push ebx
push dword [edi + 0x14]
push ebx
push 1
call fcn.005045fc
add esp, 0x10
call fcn.00529d92
lea edi, [esp + 0x6c]
mov eax, esi
call fcn.005222ca
xor ebx, ebx
push 8
push dword [esp + 0x48]
mov dword [esp + 0x34], ebx
push dword [esp + 0x6c]
push dword [ebp + 8]
call fcn.0051163c
push dword [esp + 0x54]
mov eax, dword [ebp + 0xc]
push dword [esp + 0x58]
push 0xffffffffffffffff
push ebx
push ebx
push ebx
push dword [eax]
push eax
push dword [ebp + 8]
mov eax, dword [ebp + 0x10]
call fcn.0051f608
mov edi, dword [esp + 0x64]
add esp, 0x34
push dword [esp + 0x28]
call fcn.0050f9b1
mov esi, dword [esp + 0x14]
mov edx, dword [esp + 0x48]
pop ecx
mov ecx, esi
call fcn.0050473c
mov esi, dword [ebp + 0xc]
cmp dword [esp + 0x2c], 0
je 0x52313c
push dword [ebp + 0x10]
mov eax, dword [esp + 0x4c]
push dword [eax]
push dword [esp + 0x18]
push esi
push dword [ebp + 8]
call fcn.0051f9c5
add esp, 0x14
mov edx, dword [esp + 0xa8]
mov ecx, dword [esp + 0x10]
call fcn.0050473c
mov eax, dword [ebp + 0x10]
and dword [esp + 0x24], 0
cmp byte [eax], 5
jne 0x52316c
push dword [esp + 0x48]
push dword [esp + 0x40]
push dword [ebp + 8]
call fcn.0051fdd9
add esp, 0xc
push dword [esp + 0x7c]
push dword [esp + 0x2c]
call fcn.004f2f5d
push dword [esp + 0x94]
push dword [esp + 0x34]
call fcn.004f2f5d
mov eax, dword [esp + 0x34]
add esp, 0x10
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret