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

Disassembly:
sub esp, 0x54
mov eax, dword [esp + 0x78]
push ebx
push ebp
xor ebp, ebp
cmp eax, ebp
mov ebx, ecx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x14], ebp
je 0x407175
cmp dword [esp + 0x110], ebp
je 0x407175
push esi
mov esi, dword [esp + 0x64]
push edi
lea eax, [esp + 0x24]
push eax
push 0x1404
push esi
mov dword [esp + 0x58], ebp
mov dword [esp + 0x5c], ebp
mov dword [esp + 0x60], ebp
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], ebp
mov dword [esp + 0x38], ebp
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x40], ebp
mov dword [esp + 0x44], ebp
mov dword [esp + 0x48], ebp
mov dword [esp + 0x4c], ebp
mov dword [esp + 0x50], ebp
mov dword [esp + 0x54], ebp
call fcn.00405430
lea ecx, [esp + 0x34]
push ecx
push 0x15ac
push esi
call fcn.00405430
lea edx, [esp + 0x44]
push edx
push 0x1408
push esi
call fcn.00405430
lea eax, [esp + 0x54]
push eax
push 0x15b0
push esi
call fcn.00405430
lea ecx, [esp + 0x64]
push ecx
push 0x1700
push esi
call fcn.00405430
lea edx, [esp + 0x74]
push edx
push 0x1704
push esi
call fcn.00405430
add esp, 0x48
lea eax, [esp + 0x3c]
push eax
push 0x1438
push esi
call fcn.00405430
lea ecx, [esp + 0x4c]
push ecx
push 0x1434
push esi
call fcn.00405430
lea edx, [esp + 0x5c]
push edx
push 0x1474
push esi
call fcn.00405430
lea eax, [esp + 0x6c]
push eax
push 0x1410
push esi
call fcn.00405430
lea ecx, [esp + 0x7c]
push ecx
push 0x142c
push esi
call fcn.00405430
lea edx, [esp + 0x8c]
push edx
push 0x1428
push esi
call fcn.00405430
add esp, 0x48
lea eax, [esp + 0x54]
push eax
push 0x16e0
push esi
call fcn.00405430
mov ecx, dword [esp + 0xa0]
mov edx, dword [esp + 0x78]
push ebp
push ecx
push edx
call fcn.004014f0
add esp, 0x18
lea eax, [ebx + 0x19dc]
push eax
push esi
mov ecx, ebx
call fcn.00406330
mov eax, dword [esp + 0x74]
mov ecx, dword [esp + 0x70]
mov edi, dword [esp + 0xa0]
mov edx, dword [esp + 0x94]
push eax
mov eax, dword [esp + 0x70]
push ecx
push edi
push edx
push eax
push esi
mov ecx, ebx
call fcn.004066f0
mov ecx, dword [esp + 0x130]
mov edx, dword [esp + 0x138]
and ecx, 0x3fc0
shl ecx, 0x10
shr edx, 0xa
or ecx, edx
push ecx
push 0x142c
push esi
call fcn.004053c0
mov ecx, dword [esp + 0xb4]
mov eax, edi
and eax, 0x3fc0
shl eax, 0x10
shr ecx, 0xa
or eax, ecx
push eax
push 0x1428
push esi
call fcn.004053c0
mov edx, edi
imul edx, dword [esp + 0x8c]
mov eax, edx
add esp, 0x18
shr eax, 3
mov dword [esp + 0x10], ebp
mov dword [esp + 0x5c], edx
mov dword [esp + 0x58], eax
jmp 0x406f50
mov eax, dword [esp + 0x58]
mov edx, dword [esp + 0x5c]
xor ebp, ebp
lea ecx, [ecx]
mov edi, dword [esp + 0x88]
xor cl, cl
cmp eax, ebp
mov dword [esp + 0x68], ebp
jbe 0x406fe6
add edx, 0xfffffffc
mov dword [esp + 0x18], edx
mov dword [esp + 0x14], eax
mov edx, dword [esp + 0x18]
cmp dword [esp + 0x68], edx
ja 0x406f90
mov eax, dword [esp + 0x10]
xor edx, edx
mov ebx, 0xa
div ebx
mov eax, dword [edx*4 + 0x46bf28]
mov dword [edi], eax
mov eax, dword [esp + 0x68]
mov edx, dword [esp + 0x18]
add eax, 4
add edi, 4
cmp eax, edx
mov dword [esp + 0x68], eax
ja 0x406fcd
cmp cl, 0x10
jne 0x406fad
xor cl, cl
mov eax, dword [esp + 0x10]
xor edx, edx
mov ebx, 0xa
div ebx
mov eax, 0xf000f
shl eax, cl
xor eax, dword [edx*4 + 0x46bf50]
mov dword [edi], eax
add cl, 4
mov ebx, dword [esp + 0x68]
mov eax, dword [esp + 0x14]
add ebx, 4
add edi, 4
dec eax
mov dword [esp + 0x68], ebx
mov dword [esp + 0x14], eax
jne 0x406f70
mov ecx, dword [esp + 0x74]
mov edx, dword [esp + 0x70]
mov eax, dword [esp + 0x6c]
push 1
push ecx
push edx
push ebp
push ebp
push ebp
push ebp
push eax
push esi
call fcn.00401c20
push esi
call fcn.004010a0
mov ecx, dword [esp + 0x44]
mov edi, dword [esp + 0x140]
add esp, 0x28
or ecx, eax
mov ebx, 0
sete bl
mov dword [esp + 0x1c], ecx
mov byte [esp + 0x68], 0
mov dword [esp + 0x18], 0
test ebx, ebx
je 0x4070f2
mov ecx, dword [esp + 0x130]
imul ecx, dword [esp + 0x74]
mov eax, ecx
shr eax, 3
mov dword [esp + 0x14], ecx
mov dword [esp + 0x60], eax
jmp 0x407060
mov eax, dword [esp + 0x60]
jmp 0x407060
cmp dword [esp + 0x18], eax
jae 0x4070f2
lea eax, [ecx - 4]
cmp ebp, eax
ja 0x40708f
mov eax, dword [esp + 0x10]
xor edx, edx
mov ecx, 0xa
div ecx
mov eax, dword [edi]
cmp eax, dword [edx*4 + 0x46bf28]
mov ecx, dword [esp + 0x14]
je 0x40708f
xor ebx, ebx
add ebp, 4
lea eax, [ecx - 4]
add edi, 4
cmp ebp, eax
ja 0x4070db
cmp byte [esp + 0x68], 0x10
jne 0x4070a8
mov byte [esp + 0x68], 0
mov eax, dword [esp + 0x10]
mov ecx, 0xa
xor edx, edx
div ecx
mov cl, byte [esp + 0x68]
mov eax, 0xf000f
shl eax, cl
xor eax, dword [edx*4 + 0x46bf50]
cmp dword [edi], eax
je 0x4070cd
xor ebx, ebx
mov al, byte [esp + 0x68]
mov ecx, dword [esp + 0x14]
add al, 4
mov byte [esp + 0x68], al
mov edx, dword [esp + 0x18]
add ebp, 4
add edi, 4
inc edx
test ebx, ebx
mov dword [esp + 0x18], edx
jne 0x407053
mov eax, dword [esp + 0x10]
inc eax
cmp eax, 0xa
mov dword [esp + 0x10], eax
jb 0x406f43
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x20]
add eax, 0x19dc
push eax
push esi
call fcn.00406510
push esi
call fcn.004010a0
mov ecx, dword [esp + 0x20]
add esp, 4
or ecx, eax
test ebx, ebx
pop edi
pop esi
jne 0x40716b
mov eax, dword [esp + 0x70]
dec eax
cmp eax, 7
ja case.0x407137.3
jmp dword [eax*4 + 0x4071c4]
or ecx, 4
pop ebp
mov eax, ecx
pop ebx
add esp, 0x54
ret 0x134
or ecx, 8
pop ebp
mov eax, ecx
pop ebx
add esp, 0x54
ret 0x134
or ecx, 1
pop ebp
mov eax, ecx
pop ebx
add esp, 0x54
ret 0x134
or ecx, 2
or ecx, 0x20
pop ebp
mov eax, ecx
pop ebx
add esp, 0x54
ret 0x134
mov ecx, dword [esp + 0x70]
dec ecx
cmp ecx, 7
mov eax, 0x40
ja case.0x407184.3
jmp dword [ecx*4 + 0x4071e4]
pop ebp
mov eax, 0x44
pop ebx
add esp, 0x54
ret 0x134
pop ebp
mov eax, 0x48
pop ebx
add esp, 0x54
ret 0x134
pop ebp
mov eax, 0x41
pop ebx
add esp, 0x54
ret 0x134
mov eax, 0x42
pop ebp
or eax, 0x20
pop ebx
add esp, 0x54
ret 0x134