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

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x38
push ebx
mov ebx, dword [edx]
xor eax, eax
push esi
xor esi, esi
mov dword [ebp - 0x24], edx
cmp word [ecx + 0x24], si
mov dword [ebp - 0x18], esi
mov dword [ebp - 0x1c], esi
setne al
mov dword [ebp - 8], esi
mov esi, dword [edx + 0xc]
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0x14], eax
push edi
mov edi, dword [ecx + 0x40]
test esi, esi
jne 0x40fcbd
movzx esi, byte [ebx + 0x6c]
movzx eax, byte [ebx + 0x6b]
shl esi, 8
or esi, eax
movzx eax, byte [ebx + 0x6a]
shl esi, 8
or esi, eax
movzx eax, byte [ebx + 0x69]
shl esi, 8
or esi, eax
add esi, ebx
and dword [edi + 4], 0
mov eax, 0xb8
mov dword [edi + 0x10], eax
mov edx, 0x7fffffff
mov dword [edi + 8], eax
mov ecx, esi
lea eax, [ebp - 0xc]
push eax
call fcn.0040d116
test eax, eax
jns 0x40fce8
and dword [edi], 0
jmp 0x41020e
mov edx, dword [ebp - 0xc]
lea ecx, [edx + edx]
lea eax, [ecx + 0xb8]
mov dword [edi + 0xc], eax
mov dword [edi + 0x14], eax
mov eax, dword [ebp - 0x10]
cmp dword [eax + 0x14], 0
lea eax, [edx + 1]
push eax
push esi
lea edx, [ecx + 2]
push 0
je 0x40fd34
lea ecx, [edi + 0xba]
call int.004555bc
mov eax, dword [edi + 0x10]
xor ecx, ecx
mov edx, dword [ebp - 0xc]
push 0x40
lea eax, [eax + edx*2]
mov word [eax + edi + 2], cx
mov eax, dword [edi + 0x10]
pop ecx
mov word [edi + eax], cx
jmp 0x40fd4e
lea ecx, [edi + 0xb8]
call int.004555bc
mov eax, dword [edi + 0x10]
xor ecx, ecx
mov edx, dword [ebp - 0xc]
lea eax, [eax + edx*2]
mov word [eax + edi], cx
mov esi, dword [ebp - 0x10]
xor edx, edx
inc edx
mov eax, dword [esi + 0x30]
mov dword [edi], eax
cmp dword [esi + 0x38], 2
jbe 0x40fd6b
cmp dword [esi + 0x38], 3
jne 0x40fdca
and dword [edi + 0x18], 0
jmp 0x40fdca
mov ecx, dword [esi + 0x2c]
add ecx, 0xbb
and ecx, 0xfffffffc
mov dword [edi + 0x18], ecx
mov eax, dword [esi + 0x38]
test eax, eax
je 0x40fd9c
dec eax
cmp eax, edx
ja 0x40fdca
and dword [ecx + edi], 0
lea eax, [edi + 0xc]
and dword [ecx + edi + 4], 0
mov dword [ecx + edi + 8], 0xc
jmp 0x40fdc5
push 0x20
pop eax
mov dword [ecx + edi + 4], eax
lea eax, [edi + 0xc]
add eax, ecx
mov dword [ecx + edi], 0xc
mov dword [ebp - 0x18], eax
lea eax, [edi + 0x20]
add eax, ecx
mov dword [ecx + edi + 8], 0x34
mov dword [ebp - 0x1c], eax
lea eax, [edi + 0x34]
add eax, ecx
mov dword [ebp - 8], eax
mov al, byte [ebx + 0x55]
mov byte [edi + 0x2c], al
mov cl, byte [ebx + 0x5a]
and cl, 0xf0
mov byte [edi + 0x2d], cl
cmp byte [ebx + 0x56], 0
sete al
inc al
or al, cl
mov byte [edi + 0x2d], al
movzx ecx, byte [ebx + 0x54]
movzx eax, byte [ebx + 0x53]
shl cx, 8
or cx, ax
movzx eax, cx
mov ecx, 0x3e8
mov word [edi + 0x2e], ax
cmp ax, cx
ja 0x40fe0c
cmp ax, dx
jae 0x40fe15
mov eax, 0x190
mov word [edi + 0x2e], ax
mov al, byte [edi + 0x2d]
and al, 0xf
mov dword [edi + 0x30], 0x203a0822
cmp al, 1
mov eax, dword [ebp - 0x14]
jne 0x40fe3a
test eax, eax
jne 0x40fe33
mov dword [edi + 0x30], 0x203a1822
or dword [edi + 0x30], 0x400000
test eax, eax
je 0x40fe45
or dword [edi + 0x30], 0x10000000
and dword [edi + 0x1c], 0
mov ecx, ebx
call fcn.0040f2c2
mov word [edi + 0x34], ax
xor eax, eax
mov word [edi + 0x36], ax
movzx ecx, byte [ebx + 0x4d]
movzx eax, byte [ebx + 0x4c]
shl cx, 8
or cx, ax
movzx eax, cx
movsx ecx, word [esi + 0x20]
mov dword [ebp - 0x20], eax
test ax, ax
jle 0x40fe7b
cwde
sub ecx, eax
mov word [edi + 0x38], cx
xor eax, eax
mov word [edi + 0x3a], ax
movzx ecx, byte [ebx + 0x4b]
movzx eax, byte [ebx + 0x4a]
shl cx, 8
or cx, ax
movzx eax, cx
mov word [edi + 0x3c], ax
movzx edx, word [esi + 0x20]
sub dx, ax
mov word [edi + 0x40], ax
mov word [edi + 0x3e], dx
neg edx
mov word [edi + 0x42], dx
movzx ecx, byte [ebx + 0x4f]
shl cx, 8
mov dword [ebp - 0xc], eax
movzx eax, byte [ebx + 0x4e]
or cx, ax
mov word [edi + 0x48], dx
mov eax, dword [ebp - 0xc]
mov word [edi + 0x44], cx
mov word [edi + 0x4a], cx
mov word [edi + 0x46], ax
mov ax, word [esi + 0x22]
mov word [edi + 0x4e], ax
movzx ecx, byte [ebx + 0x5c]
movzx eax, byte [ebx + 0x5b]
shl cx, 8
or cx, ax
mov word [edi + 0x4c], cx
movzx edx, word [esi + 0x22]
movsx ecx, cx
cmp ecx, edx
jle 0x40feff
mov word [edi + 0x4c], dx
movzx ecx, word [edi + 0x3e]
xor eax, eax
mov dword [edi + 0x54], eax
mov dword [edi + 0x58], eax
mov dword [edi + 0x5c], eax
mov dword [edi + 0x60], eax
mov eax, dword [ebp - 0xc]
add eax, ecx
push 0xc
movzx eax, ax
pop ecx
cmp ax, cx
jle 0x40ff27
cwde
cdq
idiv ecx
jmp 0x40ff2a
xor eax, eax
inc eax
movsx esi, ax
or ecx, 0xffffffff
mov dword [ebp - 0x14], eax
mov word [edi + 0x64], ax
mov eax, esi
cdq
sub eax, edx
movzx edx, word [edi + 0x3e]
sar eax, 1
sub ecx, eax
mov eax, dword [ebp - 0x14]
mov word [edi + 0x68], ax
lea eax, [esi + 1]
sar eax, 1
movzx ecx, cx
sub eax, ecx
mov word [edi + 0x66], cx
sub eax, edx
movzx eax, ax
test ax, ax
jle 0x40ff69
add eax, ecx
mov word [edi + 0x66], ax
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 0x20]
cwde
movsx ecx, cx
sub eax, ecx
mov esi, dword [ebp - 0x10]
add eax, 2
cdq
push 3
pop ecx
idiv ecx
push 1
mov word [edi + 0x6a], ax
mov al, byte [esi + 0x1c]
mov byte [edi + 0x6c], al
mov al, byte [esi + 0x1d]
mov byte [edi + 0x6d], al
mov al, byte [esi + 0x1f]
add al, byte [esi + 0x1c]
mov byte [edi + 0x6f], al
mov eax, dword [ebp - 0x24]
mov eax, dword [eax]
mov cl, byte [eax + 0x61]
add cl, byte [eax + 0x5f]
mov byte [edi + 0x6e], cl
mov al, byte [esi + 0x1e]
add al, byte [esi + 0x1c]
mov byte [ebp - 1], al
mov al, byte [esi + 0x1f]
add al, byte [esi + 0x1c]
mov byte [ebp - 2], al
lea eax, [ebp - 1]
push eax
push 0
push 2
lea eax, [edi + 0x74]
push eax
call dword [0x480140]
push 1
lea eax, [ebp - 2]
push eax
push 0
push 2
lea eax, [edi + 0x76]
push eax
call dword [0x480140]
mov edx, dword [esi + 0x3c]
xor esi, esi
mov ecx, dword [edx + 0x20]
mov ax, word [edx + 0x24]
mov word [edi + 0x70], ax
mov ax, word [edx + ecx*8 + 0x1e]
dec ax
add ax, word [edx + ecx*8 + 0x1c]
movsx ecx, word [edi + 0x38]
mov word [edi + 0x72], ax
mov eax, ecx
cdq
sub eax, edx
mov dword [edi + 0x28], esi
sar eax, 1
mov word [edi + 0x50], ax
mov eax, ecx
cdq
and edx, 3
mov dword [edi + 0x78], 1
add eax, edx
mov dword [edi + 0x7c], esi
sar eax, 2
mov word [edi + 0x52], ax
movzx eax, byte [ebx + 0x47]
shl ax, 8
movzx edx, ax
movzx eax, byte [ebx + 0x46]
or edx, eax
mov dword [edi + 0x84], edx
movzx eax, byte [ebx + 0x49]
shl ax, 8
movzx ecx, ax
movzx eax, byte [ebx + 0x48]
or ecx, eax
xor eax, eax
mov dword [edi + 0x80], ecx
inc eax
test edx, edx
jne 0x410068
mov dword [edi + 0x84], eax
cmp ecx, esi
jne 0x410072
mov dword [edi + 0x80], eax
test byte [edi + 0x34], 1
jne 0x410086
mov dword [edi + 0x88], esi
mov dword [edi + 0x8c], eax
jmp 0x410096
mov dword [edi + 0x88], eax
mov dword [edi + 0x8c], 2
movsx eax, word [edi + 0x46]
mov dword [edi + 0x94], eax
movsx eax, word [edi + 0x4e]
mov dword [edi + 0x98], eax
movsx eax, word [edi + 0x48]
mov dword [edi + 0x9c], eax
mov dword [edi + 0x90], esi
mov dword [edi + 0xa0], 0x6e6b6e55
movzx eax, byte [edi + 0x2d]
mov dword [edi + 0xa4], esi
mov dword [edi + 0xa8], esi
test al, 0x40
je 0x4100dd
push 3
pop eax
jmp 0x4100e7
and al, 0x50
neg al
sbb al, al
and al, 2
add al, 2
mov byte [edi + 0xac], al
mov al, byte [edi + 0x2d]
and al, 0xf0
cmp al, 0x20
push 0x64
setne al
dec al
and al, 0xb
mov byte [edi + 0xad], al
movzx eax, word [edi + 0x2e]
cdq
pop ecx
idiv ecx
inc al
mov byte [edi + 0xae], al
movzx ecx, byte [ebx + 0x57]
movzx eax, byte [ebx + 0x56]
shl cx, 8
or cx, ax
neg cx
sbb cl, cl
xor eax, eax
and cl, 9
mov dword [edi + 0xb0], eax
mov byte [edi + 0xaf], cl
mov word [edi + 0xb4], ax
cmp dword [edi + 0x18], eax
je 0x41020e
mov edx, dword [ebp - 0x18]
mov ebx, 0x2bc
mov word [ebp - 0x38], ax
mov byte [ebp - 0x36], al
mov al, byte [edi + 0xae]
mov byte [ebp - 0x35], al
mov ax, word [edi + 0x2e]
mov word [ebp - 0x34], ax
mov ax, word [edi + 0x34]
mov word [ebp - 0x32], ax
mov ax, word [edi + 0x4c]
mov word [ebp - 0x30], ax
mov ax, word [edi + 0x4e]
mov word [ebp - 0x2e], ax
mov eax, dword [edi + 0x88]
mov dword [ebp - 0x2c], eax
mov eax, dword [edi + 0x8c]
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 8]
test edx, edx
je 0x4101ba
push 5
pop ecx
lea esi, [ebp - 0x38]
mov edi, edx
rep movsd dword es:[edi], dword [esi]
mov byte [eax + 3], 8
push 0x20
pop ecx
or word [edx + 6], cx
inc word [edx + 8]
inc word [edx + 0xa]
mov word [edx + 4], bx
mov edx, dword [ebp - 0x1c]
xor ebx, ebx
inc ebx
test edx, edx
je 0x4101dc
push 5
pop ecx
lea esi, [ebp - 0x38]
mov edi, edx
rep movsd dword es:[edi], dword [esi]
or word [edx + 6], bx
mov dword [edx + 0xc], ebx
mov dword [edx + 0x10], 2
test eax, eax
je 0x41020e
push 5
pop ecx
lea esi, [ebp - 0x38]
mov edi, eax
rep movsd dword es:[edi], dword [esi]
or word [eax + 6], 0x21
mov ecx, 0x2bc
inc word [eax + 8]
inc word [eax + 0xa]
mov byte [eax + 3], 8
mov word [eax + 4], cx
mov dword [eax + 0xc], ebx
mov dword [eax + 0x10], 2
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret