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

Disassembly:
push 0xffffffffffffffff
push 0x52b058
mov eax, dword fs:[0]
push eax
sub esp, 0x3c
push ebx
push ebp
push esi
push edi
mov eax, dword [0x580ca0]
xor eax, esp
push eax
lea eax, [esp + 0x50]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x6c]
mov edi, ecx
lea eax, [esp + 0x38]
push eax
call fcn.0040a330
mov ecx, dword [esp + 0x64]
xor ebx, ebx
lea edx, [esp + 0x38]
mov dword [esp + 0x58], ebx
call fcn.0040f0b0
mov esi, eax
cmp esi, ebx
je 0x40c619
lea ebx, [esp + 0x38]
call fcn.0040a500
mov ecx, dword [esp + 0x38]
push 1
push ecx
lea ecx, [esp + 0x44]
call fcn.00405360
lea ecx, [esp + 0x38]
call fcn.0046c590
mov eax, esi
jmp 0x40cb53
mov esi, dword [esp + 0x44]
lea ecx, [esp + 0x18]
call fcn.0046bb70
cmp dword [esp + 0x44], esi
ja 0x40c632
cmp esi, dword [esp + 0x48]
jbe 0x40c637
call fcn.004bd101
lea edx, [esp + 0x38]
push edx
lea ecx, [esp + 0x1c]
call fcn.004027c0
mov dword [esp + 0x1c], esi
lea esp, [esp]
mov esi, dword [esp + 0x48]
lea ecx, [esp + 0x20]
call fcn.0046bb70
cmp dword [esp + 0x44], esi
ja 0x40c669
cmp esi, dword [esp + 0x48]
jbe 0x40c66e
call fcn.004bd101
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x24]
call fcn.004027c0
lea ecx, [esp + 0x18]
mov dword [esp + 0x24], esi
call fcn.004060e0
test al, al
je 0x40c69f
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00407860
test al, al
jne 0x40c6a4
call fcn.004bd101
mov edx, dword [esp + 0x1c]
cmp edx, dword [esp + 0x24]
je 0x40ca34
mov esi, dword [esp + 0x68]
mov eax, dword [esi + 8]
or eax, dword [esi + 0xc]
jne 0x40c730
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c6d0
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [ecx + 0x10]
jb 0x40c6ed
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x58]
or edx, dword [eax + 0x5c]
je 0x40c730
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c707
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [ecx + 0x10]
jb 0x40c724
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x58]
mov dword [esi + 8], edx
mov eax, dword [eax + 0x5c]
mov dword [esi + 0xc], eax
test ebx, ebx
jne 0x40c930
mov ecx, dword [esp + 0x60]
cmp dword [ecx + 0x20], 1
je 0x40c930
mov edx, dword [edi]
mov dword [esi + 0x10], edx
mov eax, dword [edi + 4]
lea ecx, [esp + 0x18]
mov dword [esi + 0x14], eax
call fcn.004060e0
test al, al
jne 0x40c763
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40c77a
call fcn.004bd101
mov edx, dword [esp + 0x1c]
test byte [edx + 0x32], 1
je 0x40c875
mov ebx, dword [esp + 0x70]
mov eax, ebx
call fcn.0040da20
mov esi, eax
test byte [esi + 0x32], 2
je 0x40ca0a
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c7b1
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [ecx + 0x10]
jb 0x40c7ce
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x10]
add dword [edi], edx
mov eax, dword [eax + 0x14]
lea ecx, [esp + 0x18]
adc dword [edi + 4], eax
call fcn.004060e0
test al, al
jne 0x40c7eb
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40c802
call fcn.004bd101
mov edx, dword [esi + 0x58]
mov eax, dword [esp + 0x1c]
mov dword [eax + 0x58], edx
mov ecx, dword [esi + 0x5c]
mov edx, dword [esp + 0x1c]
mov dword [edx + 0x5c], ecx
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c828
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40c83f
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [esi + 0x10]
add eax, 0x10
add dword [eax], edx
mov ecx, dword [esi + 0x14]
adc dword [eax + 4], ecx
test byte [esi + 0x32], 1
jne 0x40c86b
lea esi, [esp + 0x18]
call fcn.0040a3e0
add eax, 0x32
mov edx, 0xfffe
and word [eax], dx
call fcn.0040daa0
jmp 0x40c9d2
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c887
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40c89e
call fcn.004bd101
mov edx, dword [edi]
mov eax, dword [esp + 0x1c]
mov dword [eax + 0x58], edx
mov ecx, dword [edi + 4]
mov edx, dword [esp + 0x1c]
mov dword [edx + 0x5c], ecx
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c8c3
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [ecx + 0x10]
jb 0x40c8e0
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x10]
add dword [edi], edx
mov eax, dword [eax + 0x14]
mov esi, 0x64
adc dword [edi + 4], eax
inc dword [ebp]
mov ecx, dword [ebp]
xor edx, edx
mov eax, ecx
div esi
test edx, edx
jne 0x40c9d2
mov eax, dword [esp + 0x74]
mov edx, dword [eax]
push ecx
push eax
mov eax, dword [edx + 0x10]
call eax
mov esi, eax
test esi, esi
je 0x40c9d2
lea ebx, [esp + 0x38]
call fcn.0040a500
mov eax, dword [esp + 0x38]
push 1
push eax
jmp 0x40c600
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c942
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40c959
call fcn.004bd101
mov edx, dword [edi]
mov eax, dword [esp + 0x1c]
mov dword [eax + 0x58], edx
mov ecx, dword [edi + 4]
mov edx, dword [esp + 0x1c]
mov dword [edx + 0x5c], ecx
lea ecx, [esp + 0x18]
call fcn.004060e0
test al, al
jne 0x40c97e
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [ecx + 0x10]
jb 0x40c99b
call fcn.004bd101
mov eax, dword [esp + 0x1c]
mov edx, dword [eax + 0x10]
add dword [edi], edx
mov eax, dword [eax + 0x14]
mov esi, 0x64
adc dword [edi + 4], eax
inc dword [ebp]
mov ecx, dword [ebp]
xor edx, edx
mov eax, ecx
div esi
test edx, edx
jne 0x40c9d2
mov eax, dword [esp + 0x74]
mov edx, dword [eax]
push ecx
push eax
mov eax, dword [edx + 0x10]
call eax
mov esi, eax
test esi, esi
jne 0x40c5f0
lea ecx, [esp + 0x18]
mov ebx, 1
call fcn.004060e0
test al, al
jne 0x40c9e9
call fcn.004bd101
lea ecx, [esp + 0x18]
call fcn.00406000
mov ecx, dword [esp + 0x1c]
cmp ecx, dword [eax + 0x10]
jb 0x40ca00
call fcn.004bd101
add dword [esp + 0x1c], 0x68
jmp 0x40c650
lea ebx, [esp + 0x38]
call fcn.0040a500
mov edx, dword [esp + 0x38]
push 1
push edx
lea ecx, [esp + 0x44]
call fcn.00405360
mov ecx, ebx
call fcn.0046c590
mov eax, 0x80004005
jmp 0x40cb53
mov eax, dword [esp + 0x68]
mov edx, dword [edi]
sub edx, dword [eax + 0x10]
mov ecx, dword [edi + 4]
sbb ecx, dword [eax + 0x14]
mov ebp, dword [esp + 0x70]
mov dword [eax + 0x1c], ecx
mov dword [eax + 0x18], edx
mov esi, dword [ebp + 0x10]
lea ecx, [esp + 0x28]
call fcn.0046bb70
cmp dword [ebp + 0xc], esi
ja 0x40ca63
cmp esi, dword [ebp + 0x10]
jbe 0x40ca68
call fcn.004bd101
push ebp
lea ecx, [esp + 0x2c]
call fcn.004027c0
mov edi, dword [esp + 0x28]
mov dword [esp + 0x2c], esi
mov ebx, esi
mov esi, dword [esp + 0x48]
lea ecx, [esp + 0x20]
call fcn.0046bb70
cmp dword [esp + 0x44], esi
ja 0x40ca95
cmp esi, dword [esp + 0x48]
jbe 0x40ca9a
call fcn.004bd101
lea edx, [esp + 0x38]
push edx
lea ecx, [esp + 0x24]
call fcn.004027c0
mov dword [esp + 0x24], esi
mov esi, dword [esp + 0x44]
lea ecx, [esp + 0x30]
call fcn.0046bb70
cmp dword [esp + 0x44], esi
ja 0x40cac5
cmp esi, dword [esp + 0x48]
jbe 0x40caca
call fcn.004bd101
lea eax, [esp + 0x38]
push eax
lea ecx, [esp + 0x34]
call fcn.004027c0
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x20]
push ecx
mov ecx, dword [esp + 0x78]
push edx
mov eax, esi
push eax
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x3c]
push eax
push ebx
push edi
push ecx
mov ecx, ebp
call fcn.0040e080
mov esi, dword [esp + 0x44]
xor ebx, ebx
cmp esi, ebx
je 0x40cb2c
mov edi, dword [esp + 0x48]
cmp esi, edi
je 0x40cb23
mov edi, edi
lea ecx, [esi + 0x38]
call fcn.00401320
add esi, 0x68
cmp esi, edi
jne 0x40cb10
mov esi, dword [esp + 0x44]
push esi
call fcn.004b9d78
add esp, 4
mov edx, dword [esp + 0x38]
push 1
push edx
lea ecx, [esp + 0x44]
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x50], ebx
mov dword [esp + 0x54], ebx
call fcn.00405360
lea ecx, [esp + 0x38]
call fcn.0046c590
xor eax, eax
mov ecx, dword [esp + 0x50]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x48
ret 0x18