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

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0xe0
mov ebx, dword [ebp + 0x24]
mov ecx, dword [ebp + 0x28]
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 0x20]
mov dword [esp + 0x34], ecx
mov dword [esp + 0x30], ebx
test eax, eax
mov edi, 6
cmovns edi, eax
mov eax, ebx
mov dword [esp + 0x10], ecx
or eax, ecx
mov ecx, dword [edx]
mov eax, dword [edx + 4]
mov dword [esp + 0xc], ecx
mov dword [esp + 0x28], ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x2c], eax
mov dword [esp + 0x44], 0
mov dword [esp + 0x40], 0
mov esi, edi
je 0x40f477
mov eax, edi
and eax, 0x400
jmp 0x40f489
and edi, 0x400
xor eax, eax
cmp dword [ebp + 0x14], 0
je 0x40f48f
test edi, edi
jne 0x40f48f
mov edi, eax
mov ax, 8
movzx ecx, ax
lea eax, [ecx + 0x800]
test esi, 0x10000
cmove ecx, eax
mov dword [esp + 0x7c], ecx
and esi, 0xf
sete al
mov dword [esp + 0x3c], edi
test edi, edi
setne cl
mov edi, dword [edx + 0x48]
test edi, edi
je 0x40f798
cmp dword [edx + 0x14], 2
jne 0x40f798
cmp dword [ebp + 0x14], 0
setne dl
cmp dword [ebp + 0x10], 0
sete ah
cmp dword [ebp + 0xc], 0
je 0x40f798
and ah, dl
jne 0x40f798
cmp word [ebp + 0x1c], 0
setne dl
cmp dword [ebp + 0x18], 0
sete ah
test ah, dl
jne 0x40f798
cmp esi, 0xb
jae 0x40f798
mov dword [esp + 8], edi
cmp dword [edi + 0x34], 0
mov edx, dword [ebp + 8]
mov edx, dword [edx + 0x10]
je 0x40f52f
cmp edx, 0xffffffff
mov edi, esi
jne 0x40f54b
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 2
jmp 0x40f7a2
cmp dword [esp + 0x10], 0
mov edi, esi
jne 0x40f540
cmp edx, 0xffff
jne 0x40f54b
mov edx, dword [esp + 8]
mov dword [edx + 0x34], 1
or al, cl
movzx edx, al
cmp dword [esp + 0x3c], 0
je 0x40f584
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0x2f
mov eax, dword [ebp + 8]
je 0x40f59d
mov dword [esp + 0x1c], edx
mov eax, dword [ebp + 0x2c]
mov dword [esp + 0x78], eax
push dword [ebp + 0xc]
call fcn.00417ad0
add esp, 4
cmp eax, 0x10000
jb 0x40f5a9
mov eax, dword [ebp + 8]
jmp 0x40f59d
or ebx, dword [esp + 0x10]
mov eax, dword [ebp + 8]
jne 0x40f79b
mov ecx, dword [ebp + 0xc]
cmp byte [ecx], 0x2f
jne 0x40f7ae
mov dword [eax + 0x1c], 0x19
jmp 0x40f7a2
mov dword [esp + 0x6c], edi
mov dword [esp + 0x24], eax
mov dword [esp + 0x74], 0
mov esi, 0xfffffffe
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x20]
mov edx, dword [eax + 0x24]
or edx, ecx
mov edx, 0
je 0x40f5de
lea edx, [esi + ecx]
inc edx
mov eax, dword [eax]
and eax, edx
sub ecx, eax
and ecx, edx
mov edx, ecx
mov dword [esp + 0x4c], edx
mov esi, dword [esp + 8]
mov edx, dword [esi + 4]
movzx eax, word [ebp + 0x1c]
xor ecx, ecx
mov dword [esp + 0x20], edx
mov dword [esp + 0xb4], eax
add edx, eax
setb cl
mov eax, edx
add eax, dword [esp + 0x24]
mov dword [esp + 0x70], ecx
adc ecx, 0
add eax, 0x4a
adc ecx, 0
mov edi, 0xfffffffe
cmp edi, eax
sbb dword [esp + 0x74], ecx
jae 0x40f62e
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0xf
jmp 0x40f7a2
mov eax, dword [esi + 0x34]
test eax, eax
jne 0x40f680
mov ecx, dword [esp + 0x24]
mov eax, ecx
shr eax, 0x1f
add edx, dword [ebp + 0x38]
mov esi, dword [esp + 0x70]
adc esi, 0
add ecx, ecx
add edx, dword [ebp + 0x40]
adc esi, 0
add edx, ecx
adc esi, eax
add edx, dword [esp + 0x4c]
adc esi, 0
mov eax, dword [ebp + 8]
add edx, dword [eax]
adc esi, dword [eax + 4]
add edx, 0x72
adc esi, 0xffffffff
xor eax, eax
cmp esi, 0xffffffff
je 0x40f680
mov eax, dword [esp + 8]
mov dword [eax + 0x34], 1
mov eax, 1
mov dword [esp + 0x74], 0
mov edx, dword [esp + 0x24]
test edx, edx
je 0x40f6b6
mov ecx, dword [ebp + 0xc]
cmp byte [edx + ecx - 1], 0x2f
jne 0x40f6b6
cmp dword [ebp + 0x14], 0
jne 0x40f798
mov dword [esp + 0x74], 0x10
or ebx, dword [esp + 0x10]
jne 0x40f798
test eax, eax
mov ecx, 0x1c
cmove ecx, eax
mov eax, dword [esp + 0xb4]
add eax, edx
mov edx, dword [esp + 0x20]
add edx, eax
lea eax, [ecx + edx]
add eax, 0x2e
mov edi, dword [esp + 8]
mov edx, dword [edi + 8]
cmp edx, eax
jae 0x40f715
test edx, edx
mov ecx, 1
cmovne ecx, edx
mov esi, ecx
add ecx, ecx
cmp esi, eax
jb 0x40f6ea
push esi
mov edi, dword [esp + 0xc]
push dword [edi + 0xc]
push dword [edi]
mov ebx, dword [ebp + 8]
push dword [ebx + 0x34]
call dword [ebx + 0x30]
add esp, 0x10
test eax, eax
je 0x40f7f4
mov dword [edi], eax
mov dword [edi + 8], esi
mov eax, dword [edi + 0x14]
mov ecx, dword [edi + 0x18]
inc eax
cmp ecx, eax
jae 0x40f757
test ecx, ecx
mov edx, 1
cmovne edx, ecx
mov esi, edx
add edx, edx
cmp esi, eax
jb 0x40f72a
push esi
mov edi, dword [esp + 0xc]
push dword [edi + 0x1c]
push dword [edi + 0x10]
mov ebx, dword [ebp + 8]
push dword [ebx + 0x34]
call dword [ebx + 0x30]
add esp, 0x10
test eax, eax
je 0x40f7f4
mov dword [edi + 0x10], eax
mov dword [edi + 0x18], esi
xor eax, eax
cmp dword [ebp + 0x14], 0
je 0x40f7fd
cmp dword [esp + 0x1c], 0
mov ecx, dword [ebp + 8]
mov esi, dword [esp + 0x14]
jne 0x40f804
push 0x4df40
push 1
push dword [ecx + 0x34]
mov eax, dword [ebp + 8]
call dword [eax + 0x28]
mov ecx, dword [ebp + 8]
add esp, 0xc
test eax, eax
jne 0x40f804
mov dword [ecx + 0x1c], 0x10
jmp 0x40f7a2
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x18
xor ebx, ebx
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
mov esi, dword [ebp + 0x14]
push esi
push dword [ebp + 0x10]
push 0
mov ebx, edx
call fcn.00403400
add esp, 0xc
mov dword [esp + 0x78], eax
xor eax, eax
mov dword [esp + 0x30], esi
mov dword [esp + 0x34], 0
cmp esi, 4
mov dword [esp + 0x10], 0
cmovb edi, eax
mov eax, 1
cmovb ebx, eax
mov dword [esp + 0x1c], ebx
mov ebx, esi
jmp 0x40f56d
mov dword [ebx + 0x1c], 0x10
jmp 0x40f7a2
mov ecx, dword [ebp + 8]
mov esi, dword [esp + 0x14]
mov dword [esp + 0x10], eax
mov ebx, dword [esp + 0xc]
mov edx, ebx
mov edi, dword [esp + 0x4c]
push edi
push esi
call fcn.0040ff90
add esp, 8
test eax, eax
je 0x40f8c9
cmp dword [esp + 0x1c], 0
setne dl
cmp dword [esp + 0x3c], 0
sete dh
mov ecx, dword [esp + 0x2c]
mov eax, dword [esp + 0x28]
add eax, edi
adc ecx, 0
add ebx, edi
mov edi, eax
mov dword [esp + 0xc], ebx
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], ecx
adc esi, 0
xorps xmm0, xmm0
movaps xmmword [esp + 0x80], xmm0
movups xmmword [esp + 0x8e], xmm0
and dh, dl
mov dl, dh
xor dl, 1
movzx eax, dl
shl eax, 3
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 8]
cmp dword [eax + 0x34], 0
je 0x40f8de
mov byte [esp + 0x20], dh
mov dword [esp + 8], 0
mov eax, 0xfffffffe
cmp eax, dword [esp + 0x30]
mov edx, 0
sbb edx, dword [esp + 0x34]
mov dword [esp + 0x14], esi
jae 0x40f9e5
xor edx, edx
cmp eax, edi
mov eax, 0
sbb eax, ecx
lea eax, [esp + 0x28]
cmovae eax, edx
lea edx, [esp + 0x30]
lea esi, [esp + 0x40]
jmp 0x40f9f8
push dword [esp + 0x10]
mov eax, dword [ebp + 8]
push dword [eax + 0x34]
call dword [eax + 0x2c]
add esp, 8
jmp 0x40f7a2
cmp dword [esp + 0x44], 0
jne 0x40fd96
test esi, esi
jne 0x40fd96
mov dword [esp + 0x14], esi
mov dword [esp + 0x80], 0x4034b50
xor ebx, ebx
test dh, dh
mov edx, 0x14
cmovne edx, ebx
mov byte [esp + 0x84], dl
mov byte [esp + 0x85], 0
mov edx, dword [esp + 0x7c]
movzx eax, dx
mov byte [esp + 0x86], dl
mov byte [esp + 0x87], ah
mov eax, dword [esp + 0x3c]
mov byte [esp + 0x88], al
movups xmmword [esp + 0x89], xmm0
mov byte [esp + 0x99], 0
mov eax, dword [esp + 0x24]
mov byte [esp + 0x9a], al
mov byte [esp + 0x9b], ah
mov eax, dword [ebp + 0x38]
mov byte [esp + 0x9c], al
mov byte [esp + 0x9d], ah
lea edx, [esp + 0x80]
push 0x1e
push edx
push ecx
push edi
mov esi, dword [ebp + 8]
push dword [esi + 0x44]
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, 0x1e
jne 0x40fb39
mov eax, dword [esp + 0xc]
add eax, 0x1e
mov ecx, esi
mov esi, dword [esp + 0x14]
adc esi, 0
mov edi, dword [esp + 0x24]
push edi
push dword [ebp + 0xc]
push esi
mov dword [esp + 0x18], eax
push eax
push dword [ecx + 0x44]
call dword [ecx + 0x3c]
add esp, 0x14
cmp eax, edi
jne 0x40fb29
mov eax, edi
mov ecx, dword [esp + 0xc]
add ecx, edi
adc esi, 0
mov dword [esp + 8], 0
mov dword [esp + 0x20], 0
mov eax, dword [ebp + 8]
mov edi, esi
mov esi, ecx
jmp 0x40fb50
cmp eax, edi
mov edx, 0
sbb edx, ecx
jae 0x40fa1b
lea eax, [esp + 0x28]
xor edx, edx
xor esi, esi
lea ebx, [esp + 0xc0]
mov ecx, ebx
push eax
push esi
call fcn.00410030
add esp, 8
mov esi, eax
mov edi, dword [esp + 0x28]
mov ecx, dword [esp + 0x2c]
mov dword [esp + 8], ebx
jmp 0x40fa1d
xor esi, esi
mov dword [esp + 0x80], 0x4034b50
xor ebx, ebx
cmp byte [esp + 0x20], 0
mov edx, 0x14
cmovne edx, ebx
mov byte [esp + 0x84], dl
mov byte [esp + 0x85], 0
movzx edx, word [esp + 0x7c]
mov byte [esp + 0x86], dl
mov byte [esp + 0x87], dh
mov eax, dword [ebp + 0x38]
mov dword [esp + 0x20], esi
lea edx, [esi + eax]
mov eax, dword [esp + 0x3c]
mov byte [esp + 0x88], al
xorps xmm0, xmm0
movups xmmword [esp + 0x89], xmm0
mov byte [esp + 0x99], 0
mov eax, dword [esp + 0x24]
mov byte [esp + 0x9a], al
mov byte [esp + 0x9b], ah
mov byte [esp + 0x9c], dl
mov byte [esp + 0x9d], dh
lea edx, [esp + 0x80]
push 0x1e
push edx
push ecx
push edi
mov esi, dword [ebp + 8]
push dword [esi + 0x44]
call dword [esi + 0x3c]
add esp, 0x14
cmp eax, 0x1e
jne 0x40fb39
mov ecx, dword [esp + 0xc]
add ecx, 0x1e
mov eax, esi
mov esi, dword [esp + 0x14]
adc esi, 0
mov edi, dword [esp + 0x24]
push edi
push dword [ebp + 0xc]
push esi
mov dword [esp + 0x18], ecx
push ecx
push dword [eax + 0x44]
call dword [eax + 0x3c]
add esp, 0x14
cmp eax, edi
jne 0x40fb29
mov eax, edi
mov ecx, dword [esp + 0xc]
add ecx, edi
adc esi, 0
cmp dword [esp + 8], 0
mov edi, esi
mov esi, ecx
je 0x40fb45
lea eax, [esp + 0xc0]
mov ebx, dword [esp + 0x20]
push ebx
push eax
push edi
push esi
mov eax, dword [ebp + 8]
push dword [eax + 0x44]
call dword [eax + 0x3c]
add esp, 0x14
cmp eax, ebx
jne 0x40fbb8
add esi, ebx
adc edi, 0
jmp 0x40fb4d
push dword [esp + 0x10]
mov esi, dword [ebp + 8]
push dword [esi + 0x34]
call dword [esi + 0x2c]
add esp, 8
mov dword [esi + 0x1c], 0x13
jmp 0x40f7a4
mov dword [esp + 8], 0
mov eax, dword [ebp + 8]
mov ecx, dword [ebp + 0x38]
test ecx, ecx
je 0x40fb72
push ecx
push dword [ebp + 0x34]
push edi
push esi
push dword [eax + 0x44]
call dword [eax + 0x3c]
mov ecx, dword [ebp + 0x38]
add esp, 0x14
cmp eax, ecx
jne 0x40fbb8
add esi, ecx
adc edi, 0
mov eax, dword [ebp + 0x14]
mov ecx, dword [esp + 0x1c]
test ecx, ecx
je 0x40fbc7
push eax
push dword [ebp + 0x10]
push edi
push esi
mov eax, dword [ebp + 8]
push dword [eax + 0x44]
call dword [eax + 0x3c]
mov ecx, dword [ebp + 0x14]
add esp, 0x14
cmp eax, ecx
jne 0x40fd76
add esi, ecx
mov dword [esp + 0xc], esi
adc edi, 0
mov dword [esp + 0x14], edi
mov dword [esp + 0x40], ecx
mov dword [esp + 0x44], 0
jmp 0x40fc76
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x13
jmp 0x40f7a2
mov ecx, edi
mov edi, dword [esp + 0x6c]
mov dword [esp + 0xc], esi
mov dword [esp + 0x14], ecx
test eax, eax
je 0x40fc76
mov eax, dword [ebp + 8]
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0xc]
mov dword [esp + 0x58], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x5c], eax
mov dword [esp + 0x64], 0
mov dword [esp + 0x60], 0
push 0
push 0xfffffffffffffff1
push edi
call fcn.0040e640
add esp, 0xc
lea ecx, [esp + 0x50]
push eax
push ecx
push 0x4100a0
mov esi, dword [esp + 0x1c]
push esi
call fcn.0040e4a0
add esp, 0x10
mov eax, dword [ebp + 0x14]
mov dword [esp + 0xbc], eax
lea eax, [esp + 0xbc]
push 4
push 0
push 0
push eax
push dword [ebp + 0x10]
push esi
call fcn.004041a0
add esp, 0x18
cmp eax, 1
jne 0x40fda5
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
mov dword [esp + 0x44], ecx
mov dword [esp + 0x40], eax
mov eax, dword [esp + 0x58]
mov dword [esp + 0xc], eax
mov eax, dword [esp + 0x5c]
mov dword [esp + 0x14], eax
push dword [esp + 0x10]
mov eax, dword [ebp + 8]
push dword [eax + 0x34]
call dword [eax + 0x2c]
add esp, 8
mov eax, dword [esp + 0x30]
mov ecx, dword [esp + 0x34]
mov edi, eax
mov dword [esp + 0x10], ecx
or eax, ecx
je 0x40feb3
mov dword [esp + 0x50], 0x8074b50
mov ecx, dword [esp + 0x78]
mov byte [esp + 0x54], cl
mov byte [esp + 0x55], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x56], al
mov eax, ecx
shr eax, 0x18
mov byte [esp + 0x57], al
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x44]
cmp dword [esp + 8], 0
je 0x40fd92
mov byte [esp + 0x58], cl
mov byte [esp + 0x59], ch
mov eax, ecx
shr eax, 0x10
mov byte [esp + 0x5a], al
mov eax, edx
shr eax, 0x10
shr ecx, 0x18
mov byte [esp + 0x5b], cl
mov ecx, edx
shr ecx, 0x18
mov byte [esp + 0x5c], dl
mov byte [esp + 0x5d], dh
mov byte [esp + 0x5e], al
mov byte [esp + 0x5f], cl
mov ecx, edi
mov byte [esp + 0x60], cl
mov byte [esp + 0x61], ch
mov eax, edi
shr eax, 0x10
mov byte [esp + 0x62], al
mov eax, edi
shr eax, 0x18
mov byte [esp + 0x63], al
mov dword [esp + 0x4c], 0x38
mov dword [esp + 0x6c], 0x30
mov ecx, 0x28
mov dword [esp + 0x1c], 0x18
mov dword [esp + 0x70], 0x17
mov eax, dword [esp + 0x10]
mov byte [esp + 0x1b], al
mov dword [esp + 0xb0], 0x16
mov dword [esp + 0xac], 0x15
mov dword [esp + 0xa8], 0x14
jmp 0x40fe11
push dword [esp + 0x10]
mov esi, dword [ebp + 8]
push dword [esi + 0x34]
call dword [esi + 0x2c]
add esp, 8
mov dword [esi + 0x1c], 0x13
jmp 0x40f7a2
test edx, edx
je 0x40fdc1
mov eax, dword [ebp + 8]
mov dword [eax + 0x1c], 0x1d
jmp 0x40f7a2
push dword [esp + 0x10]
mov esi, dword [ebp + 8]
push dword [esi + 0x34]
call dword [esi + 0x2c]
add esp, 8
mov dword [esi + 0x1c], 0xc
jmp 0x40f7a2
mov dword [esp + 0x58], ecx
mov dword [esp + 0x4c], 0x18
mov dword [esp + 0x6c], 0x10
mov ecx, 8
mov dword [esp + 0x70], 0xf
mov dword [esp + 0xb0], 0xe
mov eax, edi
mov byte [esp + 0x1b], al
mov dword [esp + 0xac], 0xd
mov dword [esp + 0xa8], 0xc
mov dword [esp + 0x1c], 0x10
mov ebx, edi
mov edx, dword [esp + 0x10]
shrd ebx, edx, cl
mov eax, edx
shr eax, cl
test cl, 0x20
cmove eax, ebx
mov esi, edi
mov ecx, dword [esp + 0x6c]
shrd esi, edx, cl
mov dword [esp + 0xb8], esi
movzx ebx, byte [esp + 0x1b]
mov esi, dword [esp + 0xa8]
mov byte [esp + esi + 0x50], bl
mov ebx, dword [esp + 0xac]
mov byte [esp + ebx + 0x50], al
mov eax, edx
shr eax, cl
test cl, 0x20
cmove eax, dword [esp + 0xb8]
mov ecx, dword [esp + 0xb0]
mov byte [esp + ecx + 0x50], al
mov ecx, dword [esp + 0x4c]
shrd edi, edx, cl
shr edx, cl
test cl, 0x20
cmove edx, edi
mov eax, dword [esp + 0x70]
mov byte [esp + eax + 0x50], dl
lea eax, [esp + 0x50]
mov esi, dword [esp + 0x1c]
push esi
push eax
push dword [esp + 0x1c]
push dword [esp + 0x18]
mov eax, dword [ebp + 8]
push dword [eax + 0x44]
call dword [eax + 0x3c]
add esp, 0x14
cmp eax, esi
jne 0x40f7a2
mov eax, dword [esp + 0x1c]
add dword [esp + 0xc], eax
adc dword [esp + 0x14], 0
cmp dword [esp + 8], 0
je 0x40ff05
xor ecx, ecx
mov edx, 0xfffffffe
cmp edx, dword [esp + 0x28]
mov eax, 0
sbb eax, dword [esp + 0x2c]
lea eax, [esp + 0x28]
cmovae eax, ecx
cmp edx, dword [esp + 0x30]
mov edx, 0
sbb edx, dword [esp + 0x34]
lea esi, [esp + 0x40]
cmovae esi, ecx
lea edx, [esp + 0x30]
cmovae edx, ecx
lea ecx, [esp + 0xc0]
push eax
push esi
call fcn.00410030
add esp, 8
mov dword [esp + 0x20], eax
movzx ebx, word [esp + 0x7c]
movzx esi, word [esp + 0x3c]
movzx eax, word [esp + 0x20]
movzx edi, word [esp + 0x24]
mov ecx, dword [ebp + 8]
mov edx, dword [ebp + 0xc]
push dword [ebp + 0x40]
push dword [ebp + 0x3c]
push dword [esp + 0x7c]
push dword [esp + 0x38]
push dword [esp + 0x38]
push 0
push 0
push ebx
push esi
push dword [esp + 0x9c]
push dword [esp + 0x6c]
push dword [esp + 0x6c]
push dword [esp + 0x64]
push dword [esp + 0x64]
push dword [esp + 0xec]
push dword [ebp + 0x18]
push eax
push dword [esp + 0x4c]
push edi
call fcn.00410100
add esp, 0x4c
test eax, eax
je 0x40f7a2
mov eax, dword [ebp + 8]
inc dword [eax + 0x10]
mov ecx, dword [esp + 0xc]
mov dword [eax], ecx
mov ecx, dword [esp + 0x14]
mov dword [eax + 4], ecx
mov ebx, 1
jmp 0x40f7a4