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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
mov eax, dword [ebp + 0x30]
push ebx
mov ebx, dword [ebp + 0x1c]
cmp dword [ebx + 0x1c], 3
push esi
push edi
mov byte [eax], 0
jne 0x40c498
mov eax, dword [ebx + 8]
test eax, eax
jne 0x411d9d
mov esi, dword [ebp + 0x10]
push 9
add esi, 4
lea edi, [ebx + 0x88]
pop ecx
rep movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 8]
lea ecx, [ebx + 0x22]
push ecx
mov ecx, dword [ebx + 0x84]
add ecx, 0x28
push ecx
push dword [ebp + 0x30]
lea ecx, [ebp + 0x1f]
push ecx
movzx ecx, word [ebx + 0x20]
push ecx
lea eax, [ebx + 0xc]
push esi
call fcn.00405efc
test eax, eax
jne 0x40c5d5
mov eax, dword [ebp + 0x18]
movzx eax, byte [eax + 0x15d]
push eax
lea eax, [ebx + 0xae]
push eax
lea eax, [ebx + 0x30]
push eax
lea eax, [ebx + 0x2e]
push eax
lea eax, [ebx + 0x2c]
push eax
movzx eax, word [ebx + 0x20]
lea edi, [ebx + 0x2a]
push eax
call fcn.0040c3ae
test eax, eax
jne 0x40c5d5
cmp byte [ebp + 0x1f], al
setne al
mov dword [ebx + 0x1c], eax
mov eax, dword [ebx + 0x1c]
test eax, eax
jne 0x411be3
push dword [ebp + 0x38]
mov eax, dword [ebx + 0x84]
push dword [ebp + 0x34]
lea ecx, [ebx + 0x80]
push ecx
lea edx, [ebx + 0x7e]
push edx
push dword [eax + 0x20]
mov dword [ebp + 0x1c], ecx
push dword [eax + 0x1c]
movzx ecx, word [eax + 0x28]
push ecx
mov ecx, dword [ebp + 0x30]
movzx ecx, byte [ecx]
push ecx
push dword [ebp + 0xc]
lea edi, [ebx + 0xc]
push edi
push dword [eax + 0x10]
mov dword [ebp + 0x14], edx
push dword [eax + 0x14]
push dword [eax + 0x18]
lea eax, [ebp + 0x30]
push eax
call fcn.00407de1
test eax, eax
jne 0x40c5d5
mov esi, dword [ebx + 0x84]
call fcn.0040a084
lea eax, [ebp + 0x33]
push eax
lea eax, [ebp + 0x28]
push eax
lea eax, [ebp + 0xc]
push eax
mov eax, dword [ebp + 0x1c]
push dword [eax]
mov eax, dword [ebp + 0x14]
movzx eax, word [eax]
push eax
lea eax, [ebx + 0x22]
push eax
lea eax, [ebx + 0x88]
push eax
movzx eax, byte [ebx + 0xac]
push eax
movzx eax, word [ebx + 0xae]
push eax
movzx eax, word [ebx + 0x30]
mov esi, dword [ebp + 0x10]
push eax
movzx eax, word [ebx + 0x2e]
push eax
movzx eax, word [ebx + 0x2c]
push eax
movzx eax, word [ebx + 0x2a]
push eax
movzx eax, word [esi]
push eax
push dword [ebp + 0x28]
push dword [ebp + 0x2c]
push dword [ebx + 0x84]
push dword [ebp + 0x24]
push dword [ebp + 0x18]
call fcn.0040cb3f
test eax, eax
jne 0x40c5d5
mov edx, dword [esi + 0x30]
mov ecx, dword [ebp + 0x28]
call fcn.004061d5
test al, al
je 0x4165b9
mov ax, word [ebp + 0xc]
push dword [ebx + 0x54]
mov word [ebx + 0x7c], ax
mov eax, dword [ebx + 0x44]
call fcn.00406de3
push dword [ebx + 0x50]
mov esi, eax
mov eax, dword [ebx + 0x48]
call fcn.00406de3
sub esi, eax
js 0x424dcd
xor esi, esi
cmp dword [ebx + 8], esi
jne 0x411a65
cmp dword [edi + 0xc], esi
je 0x40c5c6
push dword [edi + 8]
mov eax, dword [ebp + 8]
call dword [eax + 8]
mov dword [edi + 8], esi
mov dword [edi + 0xc], esi
mov dword [edi + 4], esi
mov dword [edi], esi
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0x14]
mov dword [eax], esi
xor eax, eax
mov word [ecx], ax
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret 0x34
mov ecx, dword [ebp + 0xc]
lea eax, [ecx + 0x1e]
cmp word [eax], 1
jb 0x42d8ca
movzx edx, word [ebx + 0x32]
movzx eax, word [eax]
inc edx
cmp edx, eax
ja 0x424e2a
inc dword [ebp + 0x28]
lea eax, [ecx + 0x1c]
cmp word [eax], 3
jb 0x42d8d4
mov cx, word [ebp + 0x28]
cmp cx, word [eax]
ja 0x424e2a
mov edx, dword [ebp + 0x20]
lea eax, [ebp + 0x2c]
push eax
push dword [ebp + 0x14]
call fcn.00405dbe
test eax, eax
jne 0x40c5d5
mov ax, word [ebx + 0x32]
inc ax
movzx eax, ax
push eax
mov eax, dword [ebp + 0x2c]
push 0
push edx
call fcn.00405df1
mov ecx, dword [ebx + 4]
test ecx, ecx
jne 0x4118b4
mov dword [ebx + 4], eax
push 9
pop ecx
lea edi, [eax + 0x88]
mov dword [eax], ebx
mov dword [eax + 8], ebx
lea edx, [ebp + 0x33]
push edx
lea esi, [ebx + 0x88]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp + 0x2c]
mov al, byte [ebx + 0xac]
lea edx, [ebp + 0xb]
push edx
lea ecx, [edi + 0x44]
push ecx
lea ecx, [edi + 0x40]
push ecx
lea ecx, [edi + 0x3e]
push ecx
lea ecx, [edi + 0x3c]
push ecx
lea ecx, [edi + 0x3a]
push ecx
lea esi, [edi + 0x20]
push esi
lea ecx, [ebp + 0x13]
push ecx
lea ecx, [edi + 0x6a]
push ecx
lea ecx, [edi + 0x69]
push ecx
lea ecx, [edi + 0x38]
push ecx
lea ecx, [edi + 0x34]
mov byte [edi + 0xac], al
lea eax, [ebx + 0xc]
push ecx
push eax
call fcn.0041161b
mov ecx, dword [ebp + 0xc]
mov dword [ebp + 0x24], eax
mov ax, word [esi]
cmp ax, word [ecx + 4]
jae 0x424e34
cmp byte [ebp + 0xb], 0
jne 0x424d81
mov eax, dword [ebp + 0x24]
test eax, eax
jne 0x40c5d5
mov al, byte [ebp + 0x1b]
or al, byte [ebp + 0x13]
cmp byte [ebp + 0x33], 0
mov byte [ebp + 0x1b], al
je 0x41177c
test al, al
je 0x40c5d3
lea esi, [ebx + 0xc]
lea ecx, [ebx + 0x7e]
sub ebx, 0xffffff80
push ebx
call fcn.00411d4c
test eax, eax
je 0x40c5d3
jmp 0x40c5d5
cmp dword [ecx], ebx
jne 0x424e17
mov dword [ecx], eax
jmp 0x4117f3
mov eax, dword [ebp + 0x10]
movzx eax, word [eax]
push eax
push ebx
push dword [ebp + 0x18]
call fcn.00411916
cmp eax, esi
je 0x40c5ad
jmp 0x40c5d5
push 2
pop ecx
cmp eax, ecx
jne 0x411ce4
lea eax, [ebp + 0x33]
push eax
lea eax, [ebp + 0x28]
push eax
lea eax, [ebp + 0xc]
push eax
push dword [ebx + 0x80]
movzx eax, word [ebx + 0x7e]
push eax
lea eax, [ebx + 0x22]
push eax
lea eax, [ebx + 0x88]
push eax
movzx eax, byte [ebx + 0xac]
push eax
movzx eax, word [ebx + 0xae]
push eax
movzx eax, word [ebx + 0x30]
mov esi, dword [ebp + 0x10]
push eax
movzx eax, word [ebx + 0x2e]
push eax
movzx eax, word [ebx + 0x2c]
push eax
movzx eax, word [ebx + 0x2a]
push eax
movzx eax, word [esi]
push eax
push dword [ebp + 0x28]
push dword [ebp + 0x2c]
push dword [ebx + 0x84]
push dword [ebp + 0x24]
push dword [ebp + 0x18]
call fcn.00411a82
xor edi, edi
cmp eax, edi
jne 0x40c5d5
cmp byte [ebx + 0x68], 0
je 0x411ca6
mov eax, dword [ebx + 0x84]
movsx ecx, word [eax + 0x28]
mov edx, dword [eax + 0x20]
mov cx, word [edx + ecx*2 - 2]
mov esi, dword [eax]
mov edi, dword [ebx + 0x6c]
inc cx
movzx edx, cx
mov ecx, edx
mov dword [esi + ecx*4], edi
mov esi, dword [eax + 4]
mov edi, dword [ebx + 0x70]
mov dword [esi + ecx*4], edi
mov esi, dword [ebx + 0x74]
inc edx
movzx ecx, dx
mov edx, dword [eax]
mov dword [edx + ecx*4], esi
mov eax, dword [eax + 4]
mov edx, dword [ebx + 0x78]
mov esi, dword [ebp + 0x10]
mov dword [eax + ecx*4], edx
xor edi, edi
cmp byte [ebp + 0x33], 0
jne 0x415ae2
cmp dword [ebx + 8], edi
jne 0x42d8b8
cmp dword [ebx + 0x18], edi
je 0x411cd3
push dword [ebx + 0x14]
mov eax, dword [ebp + 8]
call dword [eax + 8]
mov dword [ebx + 0x14], edi
mov dword [ebx + 0x18], edi
mov dword [ebx + 0x10], edi
mov dword [ebx + 0xc], edi
xor eax, eax
mov dword [ebx + 0x80], edi
mov word [ebx + 0x7e], ax
jmp 0x40c5d3
cmp eax, 1
jne 0x40c5d3
and dword [ebp + 0x28], 0
mov byte [ebp + 0x33], 0
mov byte [ebp + 0x13], 0
mov byte [ebp + 0x1b], 0
mov dword [ebx + 0x1c], ecx
jmp 0x41177c
mov eax, dword [eax + 0x84]
mov ecx, dword [ebx + 0x84]
call fcn.00411db3
jmp 0x40c42e
mov edx, dword [esi + 0x30]
mov ecx, dword [ebp + 0x28]
call fcn.004061d5
test al, al
je 0x42d8b0
mov ax, word [ebp + 0xc]
mov word [ebx + 0x7c], ax
jmp 0x411cb0
push 2
pop eax
jmp 0x40c57e
lea esi, [edi + 0x88]
lea eax, [edi + 0x44]
call fcn.00424c9f
cmp dword [edi + 0x48], 0
jne 0x424e1e
cmp dword [edi + 0x50], 0
jne 0x424e1e
mov ecx, dword [edi + 0x44]
mov edx, ecx
test ecx, ecx
jns 0x424daa
neg edx
mov eax, dword [edi + 0x54]
test eax, eax
js 0x42d8de
cmp edx, eax
jne 0x424e1e
test ecx, ecx
jns 0x424dbf
neg ecx
cmp ecx, 0x10000
je 0x411872
jmp 0x424e1e
mov eax, dword [ebx + 0x84]
xor edx, edx
xor esi, esi
xor ecx, ecx
cmp dx, word [eax + 0x28]
jge 0x40c5a4
xor eax, eax
mov edx, dword [ebx + 0x84]
mov edx, dword [edx + 0x2c]
xor byte [eax + edx], 1
mov edx, dword [ebx + 0x84]
movsx edx, word [edx + 0x28]
inc ecx
movzx eax, cx
cmp eax, edx
jge 0x40c5a4
jmp 0x424de5
cmp eax, edi
je 0x411cb9
jmp 0x40c5d5
mov ecx, dword [ecx]
jmp 0x4118b4
mov byte [edi + 0xac], 0
jmp 0x411872
mov eax, 0x140b
jmp 0x40c5d5
mov eax, 0x1410
jmp 0x40c5d5
push 2
pop eax
jmp 0x415af9
movzx eax, word [esi]
push eax
push ebx
push dword [ebp + 0x18]
call fcn.00411916
jmp 0x424e0a
mov eax, 0x430e9c
jmp 0x41178c
mov eax, 0x430e98
jmp 0x4117ac
neg eax
jmp 0x424db5