Function at 0x40f850
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x424c50
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x4304f0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
xor ecx, ecx
mov dword [ebp - 4], ecx
mov byte [ebp - 0xd], cl
cmp byte [esi + 0x1c], cl
jne 0x40f8c3
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40f8ad
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4
mov edx, dword [ebp + 8]
cmp dword [edx - 0xc], ecx
je 0x40fa17
mov eax, dword [section..data]
mov edx, dword [eax + 0xc]
mov ecx, section..data
call edx
add eax, 0x10
mov dword [ebp - 0x14], eax
mov bl, 1
mov byte [ebp - 4], bl
mov ecx, dword [ebp + 8]
mov eax, dword [esi + 8]
push ecx
push eax
lea edi, [ebp - 0x14]
call fcn.00404c80
mov eax, dword [esi + 4]
add esp, 8
lea edi, [esi + 4]
push eax
lea edx, [ebp - 0x14]
push edx
call fcn.0040bd80
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x40f951
lea ecx, [ebp - 0x18]
push ecx
call fcn.0040e620
add esp, 4
mov byte [ebp - 4], 2
call fcn.004013d0
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40f951
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esi + 0x10]
mov byte [ebp - 0xd], bl
lea eax, [esi + 0xc]
lea edi, [ebp + 8]
lea ebx, [ebp - 0x1c]
mov dword [ebp - 0x18], ecx
call fcn.00410320
mov edx, dword [ebp - 0x18]
cmp dword [eax], edx
jne 0x40f9f4
mov eax, edi
push eax
mov eax, dword [ebp - 0x14]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x1c], esp
mov edi, esp
call fcn.00401900
add eax, 0x10
mov dword [edi], eax
call fcn.0040fa60
mov byte [ebp - 0xd], al
test al, al
jne 0x40f9f4
mov edx, dword [section..data]
mov eax, dword [edx + 0xc]
mov ecx, section..data
call eax
add eax, 0x10
mov dword [ebp - 0x18], eax
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x14]
push ecx
push str.Missing_language_file:__s
lea edi, [ebp - 0x18]
call fcn.00404c80
mov esi, dword [ebp - 0x18]
push esi
push 0x42b764
call fcn.00411710
lea eax, [esi - 0x10]
add esp, 0x10
mov byte [ebp - 4], 1
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40f9f4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], 0
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40fa17
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40fa3d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 4