Function at 0x40e580
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x45888d
mov eax, dword fs:[0]
push eax
sub esp, 0x50
mov eax, dword [0x477140]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
lea ecx, [ebp - 0x58]
call fcn.0040ac20
mov dword [ebp - 4], 0
mov edx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x58]
cmp edx, 7
jbe 0x40e5cd
test ecx, ecx
je 0x40e774
cmp edx, 7
lea eax, [ebp - 0x58]
cmova eax, ecx
cmp word [eax], 0
je 0x40e774
cmp edx, 7
lea eax, [ebp - 0x58]
cmova eax, ecx
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40e76e
xorps xmm0, xmm0
mov dword [ebp - 0x30], 0
movups xmmword [ebp - 0x40], xmm0
mov dword [ebp - 0x2c], 0xf
mov byte [ebp - 0x40], 0
movups xmmword [ebp - 0x28], xmm0
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
lea eax, [ebp - 0x28]
mov byte [ebp - 4], 2
push eax
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x58]
push eax
call fcn.0042b040
add esp, 0xc
lea ecx, [ebp - 0x28]
xor edx, edx
call fcn.0040dfd0
test al, al
je 0x40e6f8
test esi, esi
je 0x40e66f
lea eax, [ebp - 0x40]
cmp esi, eax
je 0x40e66f
cmp dword [ebp - 0x2c], 0xf
mov ecx, esi
push dword [ebp - 0x30]
cmova eax, dword [ebp - 0x40]
push eax
call fcn.00404ea0
mov ecx, dword [ebp - 0x14]
cmp ecx, 0xf
jbe 0x40e6a3
mov edx, dword [ebp - 0x28]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40e699
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40e7c5
push ecx
push edx
call fcn.004256de
add esp, 8
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
cmp ecx, 0xf
jbe 0x40e6e9
mov edx, dword [ebp - 0x40]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40e6df
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40e7c5
push ecx
push edx
call fcn.004256de
add esp, 8
mov edx, dword [ebp - 0x44]
mov ecx, dword [ebp - 0x58]
mov byte [ebp - 0x59], 1
jmp 0x40e778
mov ecx, dword [ebp - 0x14]
cmp ecx, 0xf
jbe 0x40e72c
mov edx, dword [ebp - 0x28]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40e722
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40e7c5
push ecx
push edx
call fcn.004256de
add esp, 8
mov ecx, dword [ebp - 0x2c]
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x14], 0xf
mov byte [ebp - 0x28], 0
cmp ecx, 0xf
jbe 0x40e76e
mov edx, dword [ebp - 0x40]
inc ecx
mov eax, edx
cmp ecx, 0x1000
jb 0x40e764
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40e7c5
push ecx
push edx
call fcn.004256de
add esp, 8
mov ecx, dword [ebp - 0x58]
mov edx, dword [ebp - 0x44]
mov byte [ebp - 0x59], 0
cmp edx, 7
jbe 0x40e7a8
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x40e79e
mov ecx, dword [eax - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x40e7ca
push edx
push ecx
call fcn.004256de
add esp, 8
mov al, byte [ebp - 0x59]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00425278
mov esp, ebp
pop ebp
ret
call fcn.004313ba
call fcn.004313ba
int3