Function at 0x4a7ac0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d1b6b
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x748
mov eax, dword [ebp + 8]
push ebx
push esi
mov esi, ecx
test eax, eax
push edi
mov dword [ebp - 0x10], esi
je 0x4a7d5a
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
add esp, 4
cmp eax, 0x32
jae 0x4a7d5a
mov ebx, dword [ebp + 0xc]
test ebx, ebx
je 0x4a7d5a
mov al, byte [esi + 4]
test al, al
jne 0x4a7d5a
mov eax, dword [esi + 8]
test eax, eax
jne 0x4a7d5a
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea edi, [eax + eax + 2]
mov eax, edi
add eax, 3
and al, 0xfc
call fcn.0049bb40
mov esi, esp
push 0
push 0
push edi
push esi
push 0xffffffffffffffff
push ebx
push 0
push 0
mov byte [esi], 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push esi
lea ecx, [ebp - 0x28]
call fcn.00410700
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x28]
push eax
xor ebx, ebx
push ecx
lea ecx, [ebp - 0x4a4]
mov dword [ebp - 4], ebx
call fcn.004c38e0
mov ecx, eax
call fcn.004c45a0
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 2
call fcn.004106e0
mov edx, dword [ebp + 8]
push 0x104
push edx
call fcn.004aeff0
add esp, 8
lea ecx, [ebp - 0x1c]
call fcn.004ca290
mov edi, eax
cmp edi, ebx
je 0x4a7bd4
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
inc esi
lea eax, [esi + esi]
add eax, 3
and al, 0xfc
call fcn.0049bb40
mov ebx, esp
push esi
push ebx
push 0xffffffffffffffff
push edi
push 0
push 0
mov word [ebx], 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push 0x104
push ebx
call fcn.004af030
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0x10]
mov esi, dword [sym.imp.MSVCRT.dll__snwprintf]
add esp, 8
add ecx, 0x28
push eax
push 0x4e33c0
push 0x31
push ecx
call esi
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x22e]
mov word [ebp - 0x230], 0
rep stosd dword es:[edi], eax
add esp, 0x10
lea ecx, [ebp - 0x1c]
stosw word es:[edi], ax
call fcn.004ca290
mov ebx, eax
test ebx, ebx
jne 0x4a7c2b
xor edi, edi
jmp 0x4a7c5e
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
inc esi
lea eax, [esi + esi]
add eax, 3
and al, 0xfc
call fcn.0049bb40
mov edi, esp
push esi
push edi
push 0xffffffffffffffff
push ebx
push 0
push 0
mov word [edi], 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
mov esi, dword [sym.imp.MSVCRT.dll__snwprintf]
push edi
push 0x4e33c0
lea edx, [ebp - 0x230]
push 0x104
push edx
call esi
mov ebx, dword [ebp - 0x10]
add esp, 0x10
lea eax, [ebp - 0x230]
push eax
push 0x4e33c0
lea ecx, [ebx + 0x8c]
push 0x32
push ecx
call esi
mov ecx, 0x81
xor eax, eax
lea edi, [ebp - 0x436]
mov word [ebp - 0x438], 0
rep stosd dword es:[edi], eax
add esp, 0x10
lea edx, [ebp - 0x438]
mov ecx, ebx
push 0x104
push edx
stosw word es:[edi], ax
call fcn.004ae610
lea eax, [ebp - 0x438]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
cmp eax, 1
jne 0x4a7d32
lea ecx, [ebp - 0x754]
call fcn.004c49e0
lea ecx, [ebp - 0x438]
mov byte [ebp - 4], 3
push ecx
lea ecx, [ebp - 0x754]
call fcn.004c4fa0
lea edx, [ebp - 0x230]
push eax
push edx
call dword [sym.imp.SHLWAPI.dll_StrCmpIW]
test eax, eax
jne 0x4a7d23
push 2
call fcn.004af170
add esp, 4
lea eax, [ebp - 0x438]
push 1
push eax
call fcn.004afc20
mov ecx, eax
call fcn.004be530
lea ecx, [ebp - 0x754]
mov byte [ebp - 4], 2
call fcn.004c4a60
mov edx, dword [ebp + 8]
lea ecx, [ebp - 0x230]
push ecx
push edx
mov ecx, ebx
mov dword [ebx + 0x1c], 0
call fcn.004a7600
lea ecx, [ebp - 0x1c]
mov dword [ebp - 4], 0xffffffff
call fcn.004106e0
mov ecx, dword [ebp - 0xc]
lea esp, [ebp - 0x760]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8