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

Disassembly:
sub esp, 0x64
mov eax, dword [0x4231dc]
push ebx
push ebp
mov ebp, dword [esp + 0x70]
push esi
push edi
xor ebx, ebx
lea esi, [esp + 0x48]
mov edi, ebp
mov dword [esp + 0x70], eax
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x2c], ebx
call fcn.0040c210
cmp eax, ebx
jne 0x40cd24
mov eax, dword [esp + 0x4c]
cmp eax, ebx
ja 0x40c998
mov esi, dword [esp + 0x48]
cmp esi, 0x80000000
jae 0x40c998
cmp eax, ebx
ja 0x40c998
cmp esi, 0x4000000
jae 0x40c998
cmp esi, 0x20
ja 0x40c998
cmp esi, ebx
mov edi, dword [esp + 0x7c]
mov dword [edi + 0x10], esi
jne 0x40c829
mov dword [edi], ebx
jmp 0x40c842
mov ecx, dword [esp + 0x80]
lea edx, [esi + esi*2]
shl edx, 3
call dword [ecx]
cmp eax, ebx
mov dword [edi], eax
je 0x40cd4e
cmp esi, ebx
jbe 0x40c865
xor edi, edi
mov ebx, esi
lea ebx, [ebx]
mov eax, dword [esp + 0x7c]
mov ecx, dword [eax]
add ecx, edi
call fcn.0040ed40
add edi, 0x18
dec ebx
jne 0x40c850
xor ebx, ebx
cmp esi, ebx
mov dword [esp + 0x10], ebx
jbe 0x40c998
mov dword [esp + 0x28], ebx
mov ecx, dword [esp + 0x7c]
mov ebx, dword [ecx]
add ebx, dword [esp + 0x28]
mov ecx, dword [ebp + 4]
test ecx, ecx
mov dword [esp + 0x20], ebx
je 0x40cb9d
mov eax, dword [ebp]
dec ecx
xor edx, edx
mov dword [ebp + 4], ecx
mov dl, byte [eax]
inc eax
mov byte [esp + 0x78], dl
mov dword [ebp], eax
mov esi, 0
and edx, 0xf
mov edi, edx
jbe 0x40c8cb
lea ecx, [ecx]
test ecx, ecx
je 0x40cb9d
dec ecx
mov dword [ebp + 4], ecx
mov dl, byte [eax]
inc eax
mov byte [esp + esi + 0x60], dl
inc esi
cmp esi, edi
mov dword [ebp], eax
jb 0x40c8b0
cmp edi, 8
ja 0x40c998
xor eax, eax
cmp edi, eax
mov dword [ebx + 8], eax
mov dword [ebx + 0xc], eax
jbe 0x40c914
mov dword [esp + 0x24], eax
lea esi, [esp + edi + 0x5f]
movzx eax, byte [esi]
mov ecx, dword [esp + 0x24]
cdq
call fcn.00412ee0
mov ecx, dword [ebx + 8]
or ecx, eax
mov eax, dword [ebx + 0xc]
mov dword [ebx + 8], ecx
mov ecx, dword [esp + 0x24]
or eax, edx
add ecx, 8
dec esi
dec edi
mov dword [ebx + 0xc], eax
mov dword [esp + 0x24], ecx
jne 0x40c8e8
test byte [esp + 0x78], 0x10
je 0x40c9b0
lea esi, [esp + 0x50]
mov edi, ebp
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x54]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x50]
jb 0x40c947
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40c954
cmp eax, 0x4000000
jae 0x40c998
lea esi, [esp + 0x58]
mov edi, ebp
mov dword [ebx], eax
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x5c]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x58]
jb 0x40c97e
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40c98b
cmp eax, 0x4000000
jae 0x40c998
cmp dword [ebx], 0x20
mov dword [ebx + 4], eax
ja 0x40c998
cmp eax, 0x20
jbe 0x40c9bd
pop edi
pop esi
pop ebp
mov eax, 4
pop ebx
mov ecx, dword [esp + 0x60]
call fcn.00411920
add esp, 0x64
ret 0xc
mov dword [ebx], 1
mov dword [ebx + 4], 1
test byte [esp + 0x78], 0x20
je 0x40ca12
xor eax, eax
lea esi, [esp + 0x40]
mov edi, ebp
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov eax, dword [esp + 0x80]
mov esi, dword [esp + 0x40]
lea edi, [ebx + 0x10]
push eax
mov edx, esi
mov ecx, edi
call fcn.0040f120
test eax, eax
je 0x40cd4e
mov edi, dword [edi]
mov eax, ebp
call fcn.0040c190
test eax, eax
jne 0x40cd24
mov al, byte [esp + 0x78]
test al, al
jns 0x40cb43
mov edi, edi
mov eax, dword [ebp + 4]
test eax, eax
je 0x40cb9d
lea ecx, [eax - 1]
mov eax, dword [ebp]
mov dword [ebp + 4], ecx
mov bl, byte [eax]
mov dl, bl
and dl, 0xf
lea esi, [eax + 1]
movzx eax, dl
cdq
xor edi, edi
cmp edx, edi
mov dword [ebp], esi
ja 0x40cb9d
jb 0x40ca59
cmp eax, ecx
ja 0x40cb9d
sub ecx, eax
add esi, eax
test bl, 0x10
mov dword [ebp + 4], ecx
mov dword [ebp], esi
je 0x40caf6
lea esi, [esp + 0x30]
mov edi, ebp
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x34]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x30]
jb 0x40ca9c
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40cab1
cmp eax, 0x4000000
jae 0x40c998
lea esi, [esp + 0x14]
mov edi, ebp
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x18]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x14]
jb 0x40cae1
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40caf6
cmp eax, 0x4000000
jae 0x40c998
test bl, 0x20
je 0x40cb37
xor eax, eax
lea esi, [esp + 0x38]
mov edi, ebp
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov edx, dword [esp + 0x3c]
mov eax, dword [ebp + 4]
xor ecx, ecx
cmp edx, ecx
ja 0x40cb9d
mov ecx, dword [esp + 0x38]
jb 0x40cb2f
cmp ecx, eax
ja 0x40cb9d
sub eax, ecx
mov dword [ebp + 4], eax
add dword [ebp], ecx
test bl, bl
js 0x40ca20
mov ebx, dword [esp + 0x20]
mov eax, dword [ebx]
mov edx, dword [esp + 0x1c]
mov ecx, dword [ebx + 4]
mov esi, dword [esp + 0x28]
add edx, eax
mov eax, dword [esp + 0x2c]
add eax, ecx
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x1c], edx
mov edx, dword [esp + 0x48]
inc ecx
add esi, 0x18
cmp ecx, edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x10], ecx
mov dword [esp + 0x28], esi
jb 0x40c875
xor ebx, ebx
cmp eax, ebx
je 0x40c998
mov edi, dword [esp + 0x7c]
lea esi, [eax - 1]
cmp esi, ebx
mov dword [esp + 0x78], esi
mov dword [edi + 0x14], esi
jne 0x40cbb5
mov dword [edi + 4], ebx
jmp 0x40cbd0
pop edi
pop esi
pop ebp
mov eax, 0x10
pop ebx
mov ecx, dword [esp + 0x60]
call fcn.00411920
add esp, 0x64
ret 0xc
mov ecx, dword [esp + 0x80]
lea edx, [esi*8]
call dword [ecx]
cmp eax, ebx
mov dword [edi + 4], eax
je 0x40cd4e
cmp esi, ebx
mov dword [esp + 0x10], ebx
jbe 0x40cc92
lea esp, [esp]
mov ecx, dword [esp + 0x7c]
mov edx, dword [ecx + 4]
mov eax, dword [esp + 0x10]
lea esi, [esp + 0x14]
mov edi, ebp
lea ebx, [edx + eax*8]
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x18]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x14]
jb 0x40cc1e
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40cc33
cmp eax, 0x4000000
jae 0x40c998
lea esi, [esp + 0x30]
mov edi, ebp
mov dword [ebx], eax
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x34]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x30]
jb 0x40cc65
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40cc7a
cmp eax, 0x4000000
jae 0x40c998
mov ecx, dword [esp + 0x78]
mov dword [ebx + 4], eax
mov eax, dword [esp + 0x10]
inc eax
cmp eax, ecx
mov dword [esp + 0x10], eax
jb 0x40cbe0
mov ebx, dword [esp + 0x1c]
mov eax, dword [esp + 0x78]
cmp ebx, eax
jb 0x40c998
mov edi, dword [esp + 0x7c]
mov esi, ebx
sub esi, eax
mov dword [esp + 0x78], esi
mov dword [edi + 0x18], esi
jne 0x40cd37
mov dword [edi + 8], 0
xor ebx, ebx
test esi, esi
jbe 0x40cd22
mov edx, dword [esp + 0x7c]
mov eax, dword [edx + 8]
lea ecx, [eax + ebx*4]
lea esi, [esp + 0x14]
mov edi, ebp
mov dword [esp + 0x20], ecx
call fcn.0040c210
test eax, eax
jne 0x40cd24
mov ecx, dword [esp + 0x18]
test ecx, ecx
ja 0x40c998
mov eax, dword [esp + 0x14]
jb 0x40ccfe
cmp eax, 0x80000000
jae 0x40c998
test ecx, ecx
ja 0x40c998
jb 0x40cd13
cmp eax, 0x4000000
jae 0x40c998
mov edx, dword [esp + 0x20]
mov dword [edx], eax
mov eax, dword [esp + 0x78]
inc ebx
cmp ebx, eax
jb 0x40ccc4
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x60]
call fcn.00411920
add esp, 0x64
ret 0xc
mov ecx, dword [esp + 0x80]
lea edx, [esi*4]
call dword [ecx]
test eax, eax
mov dword [edi + 8], eax
jne 0x40cd66
pop edi
pop esi
pop ebp
mov eax, 2
pop ebx
mov ecx, dword [esp + 0x60]
call fcn.00411920
add esp, 0x64
ret 0xc
cmp esi, 1
jne 0x40ccbe
xor esi, esi
test ebx, ebx
jbe 0x40cd87
mov edx, esi
mov ecx, edi
call fcn.0040ee20
test eax, eax
jl 0x40cd87
inc esi
cmp esi, ebx
jb 0x40cd75
cmp esi, ebx
je 0x40c998
mov ecx, dword [edi + 8]
pop edi
mov dword [ecx], esi
mov ecx, dword [esp + 0x6c]
pop esi
pop ebp
xor eax, eax
pop ebx
call fcn.00411920
add esp, 0x64
ret 0xc