Function at 0x404fe0
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x466000
mov eax, dword fs:[0]
push eax
sub esp, 0x10
mov eax, dword [0x485300]
xor eax, esp
mov dword [esp + 0xc], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x485300]
xor eax, esp
push eax
lea eax, [esp + 0x24]
mov dword fs:[0], eax
mov ebp, dword [esp + 0x34]
mov ecx, dword [ebp]
xor eax, eax
cmp dword [ecx - 0xc], eax
je 0x40527c
mov edx, dword [0x4874f4]
mov eax, dword [edx + 0xc]
mov ecx, 0x4874f4
call eax
add eax, 0x10
mov dword [esp + 0x18], eax
mov dword [esp + 0x2c], 0
mov edx, dword [0x4874f4]
mov eax, dword [edx + 0xc]
mov ecx, 0x4874f4
call eax
lea ebx, [eax + 0x10]
mov dword [esp + 0x14], ebx
mov byte [esp + 0x2c], 1
cmp dword [ebx - 0xc], 0
jne 0x40508a
mov eax, ebp
lea edi, [esp + 0x14]
call fcn.004055e0
mov ebx, dword [esp + 0x14]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40508a
mov esi, edi
call fcn.00405560
mov ebx, dword [esp + 0x14]
mov eax, dword [ebx - 0xc]
test eax, eax
jne 0x40514a
lea esi, [esp + 0x18]
call fcn.00405560
lea esi, [esp + 0x1c]
call fcn.00404e20
lea edi, [esp + 0x18]
mov byte [esp + 0x2c], 4
call fcn.004055e0
mov byte [esp + 0x2c], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4050da
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x18]
cmp dword [ecx - 0xc], 0
je 0x40514a
lea ebx, [esp + 0x18]
call fcn.00425250
lea edx, [esp + 0x1c]
push ebp
push edx
call fcn.00405480
add esp, 8
lea edi, [esp + 0x14]
mov byte [esp + 0x2c], 5
call fcn.004055e0
mov byte [esp + 0x2c], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40512e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ebx, dword [esp + 0x14]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40514a
lea esi, [esp + 0x14]
call fcn.00405560
mov ebx, dword [esp + 0x14]
cmp dword [ebx - 0xc], 0
jne 0x40520d
lea esi, [esp + 0x18]
call fcn.00405560
lea esi, [esp + 0x1c]
call fcn.00404f00
lea edi, [esp + 0x18]
mov byte [esp + 0x2c], 6
call fcn.004055e0
mov byte [esp + 0x2c], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405199
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x18]
cmp dword [ecx - 0xc], 0
je 0x405209
lea ebx, [esp + 0x18]
call fcn.00425250
lea edx, [esp + 0x1c]
push ebp
push edx
call fcn.00405480
add esp, 8
lea edi, [esp + 0x14]
mov byte [esp + 0x2c], 7
call fcn.004055e0
mov byte [esp + 0x2c], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4051ed
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ebx, dword [esp + 0x14]
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x405209
lea esi, [esp + 0x14]
call fcn.00405560
mov ebx, dword [esp + 0x14]
cmp dword [ebx - 0xc], 0
mov edi, dword [sym.imp.KERNEL32.DLL_LoadLibraryW]
je 0x405229
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x405229
push ebx
call edi
mov esi, eax
test esi, esi
jne 0x405231
mov eax, dword [ebp]
push eax
call edi
mov esi, eax
lea eax, [ebx - 0x10]
mov byte [esp + 0x2c], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x405252
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x2c], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40527a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [esp + 0x24]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xc]
xor ecx, esp
call fcn.0044266a
add esp, 0x1c
ret