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

Disassembly:
mov ecx, dword fs:[0x14]
mov ecx, dword [ecx]
cmp esp, dword [ecx + 8]
jbe 0x418970
sub esp, 0x74
mov eax, dword [esp + 0x78]
test byte [eax], al
lea ecx, [eax + 0x40]
mov dword [esp + 0x70], ecx
mov dword [esp], ecx
call fcn.004020c0
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0x80]
cmp ecx, eax
setl dl
mov ebx, dword [esp + 4]
mov ebp, dword [esp + 0x7c]
cmp ebp, ebx
xchg esi, ebx
setb bl
xchg esi, ebx
cmp ecx, eax
xchg edi, ebx
sete bl
xchg edi, ebx
and edi, esi
or edi, edx
xchg edi, eax
test al, al
xchg edi, eax
jne 0x4187aa
mov dword [esp + 0x20], eax
mov edx, dword [esp + 0x78]
mov esi, dword [edx + 0x4c]
mov dword [esp + 0x5c], esi
mov edi, ebp
sub ebp, ebx
mov dword [esp + 0x58], ebp
mov eax, ebp
mul esi
mov dword [esp + 0x54], edx
mov dword [esp + 0x2c], eax
sub edi, ebx
mov ebx, dword [esp + 0x20]
sbb ecx, ebx
mov dword [esp + 0x50], ecx
nop
mov ebx, dword [esp + 0x70]
mov dword [esp], ebx
mov ebx, dword [esp + 0x80]
mov dword [esp + 8], ebx
mov edi, dword [esp + 0x7c]
mov dword [esp + 4], edi
call fcn.00402080
nop
mov ecx, dword [esp + 0x78]
lea edx, [ecx + 0x28]
mov dword [esp + 0x70], edx
mov dword [esp], edx
call fcn.004020c0
mov ecx, dword [esp + 8]
test ecx, ecx
setne dl
mov ebx, dword [esp + 4]
mov dword [esp + 0x1c], ebx
test ebx, ebx
xchg ebp, ebx
setne bl
xchg ebp, ebx
mov esi, dword [esp + 0x50]
mov edi, dword [esp + 0x5c]
imul esi, edi
mov eax, ecx
mov ecx, dword [esp + 0x54]
add ecx, esi
sar edi, 0x1f
mov esi, dword [esp + 0x58]
imul edi, esi
add ecx, edi
mov dword [esp + 0x58], ecx
or ebp, edx
mov edx, dword [esp + 8]
mov dword [esp + 0x28], edx
xchg ebp, eax
test al, al
xchg ebp, eax
je 0x4186e5
xor ecx, ecx
sub ecx, ebx
mov edx, 0
sbb edx, eax
mov eax, dword [esp + 0x70]
mov dword [esp], eax
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
call fcn.004020e0
nop
mov eax, dword [esp + 0x78]
lea ecx, [eax + 0x38]
mov dword [esp + 0x70], ecx
mov dword [esp], ecx
call fcn.004020c0
mov eax, dword [esp + 4]
test eax, eax
setne cl
mov edx, dword [esp + 8]
test edx, edx
setne bl
or ecx, ebx
mov ebx, dword [esp + 8]
test cl, cl
je 0x418744
mov dword [esp + 0x24], ebx
mov dword [esp + 0x18], eax
xor ecx, ecx
sub ecx, eax
mov ebx, 0
sbb ebx, edx
mov edx, dword [esp + 0x70]
mov dword [esp], edx
mov dword [esp + 8], ebx
mov dword [esp + 4], ecx
call fcn.004020e0
mov eax, dword [esp + 0x18]
mov ebx, dword [esp + 0x24]
mov ecx, dword [esp + 0x78]
movzx edx, byte [ecx + 0x50]
test dl, dl
jne 0x4187a0
mov ebp, dword fs:[0x14]
mov ebp, dword [ebp]
mov esi, dword [ebp + 0x18]
nop
inc dword [esi + 0x7c]
mov esi, dword [0x57f0b0]
mov dword [esp + 0x6c], esi
mov edi, dword [0x57f0b4]
mov dword [esp + 0x4c], edi
mov ebp, dword [ebp + 0x18]
mov dword [esp + 0x68], ebp
xor edx, edx
mov edx, dword [esp + 0x28]
mov dword [esp + 0x44], edx
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x60]
xor edx, edx
jmp 0x41887d
mov edx, dword [esp + 0x28]
mov ebp, dword [esp + 0x1c]
jmp 0x4187ae
add esp, 0x74
ret
movzx esi, byte [ecx + 0x20]
xchg esi, eax
test al, al
xchg esi, eax
je 0x418834
mov dword [esp + 0x30], ebp
mov dword [esp + 0x34], edx
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], ebx
mov eax, dword [esp + 0x58]
mov dword [esp + 4], eax
mov ecx, dword [esp + 0x2c]
mov dword [esp], ecx
call fcn.0044c530
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
mov dword [esp + 4], eax
mov dword [esp], ecx
mov dword [esp + 0xc], 0x3fd00000
mov dword [esp + 8], 0
call fcn.0044ae60
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov dword [esp + 4], eax
mov dword [esp], ecx
call fcn.0044c5c0
mov ebp, dword [esp + 8]
mov edx, dword [esp + 0xc]
mov eax, dword [esp + 0x30]
add ebp, eax
mov eax, dword [esp + 0x34]
adc edx, eax
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x78]
mov ebx, dword [esp + 0x3c]
mov esi, dword [esp + 0x2c]
sub esi, eax
mov eax, dword [esp + 0x58]
sbb eax, ebx
sub esi, ebp
sbb eax, edx
mov dword [esp], ecx
mov dword [esp + 8], eax
mov dword [esp + 4], esi
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], ebp
call fcn.00418980
add esp, 0x74
ret
mov edx, dword [esp + 0x48]
inc edx
mov esi, dword [esp + 0x6c]
mov edi, dword [esp + 0x4c]
mov dword [esp + 0x44], ecx
mov dword [esp + 0x40], ebp
mov ecx, dword [esp + 0x78]
mov ebp, dword [esp + 0x68]
cmp edx, edi
jge 0x41891f
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x48], edx
mov eax, dword [esi + edx*4]
test byte [eax], al
add eax, 0x948
mov dword [esp], eax
mov eax, dword [esp + 0x80]
mov dword [esp + 8], eax
mov ecx, dword [esp + 0x7c]
mov dword [esp + 4], ecx
call fcn.00418d90
movzx eax, byte [esp + 0xc]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
cmp al, 1
ja 0x4188de
test al, al
jne 0x418906
mov ecx, dword [esp + 0x44]
mov ebp, dword [esp + 0x40]
mov ebx, dword [esp + 0x3c]
mov eax, dword [esp + 0x38]
jmp 0x418860
cmp al, 2
je 0x4188e8
cmp al, 3
jne 0x418901
mov ebp, dword [esp + 0x40]
add ebp, ecx
mov ecx, dword [esp + 0x44]
adc ecx, edx
mov ebx, dword [esp + 0x3c]
mov eax, dword [esp + 0x38]
jmp 0x418860
cmp al, 4
jne 0x418959
mov eax, dword [esp + 0x38]
add eax, ecx
mov ebx, dword [esp + 0x3c]
adc ebx, edx
mov ecx, dword [esp + 0x44]
mov ebp, dword [esp + 0x40]
jmp 0x418860
nop
mov edx, dword fs:[0x14]
mov edx, dword [edx]
mov esi, dword [ebp + 0x7c]
lea edi, [esi - 1]
mov dword [ebp + 0x7c], edi
cmp esi, 1
jne 0x41894c
movzx ebp, byte [edx + 0x65]
xchg ebp, eax
test al, al
xchg ebp, eax
je 0x41894c
mov dword [edx + 8], 0xfffffade
mov edx, dword [esp + 0x44]
mov ebp, dword [esp + 0x40]
jmp 0x4187ae
lea eax, [0x4d471e]
mov dword [esp], eax
mov dword [esp + 4], 0x20
call fcn.004358a0
nop
call fcn.00462370
jmp fcn.004185b0