Function at 0x537a50
Capabilities:
Check if file exists
Get common file path

Disassembly:
push 0xffffffffffffffff
push 0x586be4
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x238
push ebx
push esi
push edi
mov esi, ecx
mov eax, dword [esi + 4]
xor ebx, ebx
cmp eax, ebx
mov dword [esp + 0x24c], ebx
jne 0x537af5
cmp eax, ebx
je 0x537a8a
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [esi + 4], ebx
mov dword [esp + 0xc], ebx
lea edx, [esp + 0xc]
mov byte [esp + 0x24c], 1
push edx
push 0x5d19c0
push 7
push ebx
push 0x59c654
call dword [sym.imp.ole32.dll_CoCreateInstance]
cmp eax, ebx
jl 0x537ae5
mov eax, dword [esp + 0xc]
cmp eax, ebx
je 0x537ae5
mov ecx, dword [eax]
push ebx
push eax
call dword [ecx + 0xfc]
mov eax, dword [esp + 0xc]
push ebx
push eax
mov edx, dword [eax]
call dword [edx + 0x118]
mov eax, dword [esp + 0xc]
mov byte [esp + 0x24c], bl
mov dword [esi + 4], eax
jmp 0x537af5
lea ecx, [esp + 0xc]
mov byte [esp + 0x24c], bl
call fcn.004f3790
mov ecx, dword [esp + 0x254]
push 0x5e5830
push ecx
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
test eax, eax
jne 0x537b7a
mov ecx, 0x41
lea edi, [esp + 0x13d]
lea edx, [esp + 0x34]
mov byte [esp + 0x13c], bl
rep stosd dword es:[edi], eax
push edx
push ebx
mov ecx, 0x41
lea edi, [esp + 0x3d]
push ebx
mov byte [esp + 0x40], bl
push 0x23
push ebx
rep stosd dword es:[edi], eax
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
push str.download_1.xml
lea eax, [esp + 0x38]
push str.storm_skinMat
push eax
push 0x5e2698
lea ecx, [esp + 0x14c]
push 4
push ecx
call dword [sym.imp.MSVCRT.dll__snprintf]
add esp, 0x18
lea edx, [esp + 0x13c]
lea ecx, [esi + 8]
push edx
call sub.MFC42.DLL_CString::operator_2
lea edi, [esi + 8]
lea eax, [esp + 0x254]
push eax
mov ecx, edi
call sub.MFC42.DLL_CString::operator_1
mov eax, dword [edi]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x537cba
mov esi, dword [esi + 4]
mov edi, dword [edi]
cmp esi, ebx
je 0x537cba
push edi
lea ecx, [esp + 0x14]
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x10]
mov byte [esp + 0x24c], 2
call sub.MFC42.DLL_CString::AllocSysString
push eax
lea ecx, [esp + 0x28]
mov word [esp + 0x28], bx
call fcn.00480a70
lea ecx, [esp + 0x14]
mov byte [esp + 0x24c], 3
push ecx
call dword [sym.imp.OLEAUT32.dll_VariantClear]
lea edx, [esp + 0x24]
lea eax, [esp + 0x14]
push edx
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopyInd]
cmp eax, ebx
jge 0x537c01
push eax
call fcn.00565a92
lea edx, [esp + 0xc]
mov ecx, dword [esi]
push edx
mov edx, dword [esp + 0x18]
sub esp, 0x10
mov byte [esp + 0x260], 4
mov eax, esp
push esi
mov dword [eax], edx
mov edx, dword [esp + 0x30]
mov dword [eax + 4], edx
mov edx, dword [esp + 0x34]
mov dword [eax + 8], edx
mov edx, dword [esp + 0x38]
mov dword [eax + 0xc], edx
call dword [ecx + 0xe8]
cmp eax, ebx
jge 0x537c47
push 0x5d19c0
push esi
push eax
call fcn.00565aa0
mov esi, dword [sym.imp.OLEAUT32.dll_VariantCopy]
lea eax, [esp + 0x14]
push eax
mov byte [esp + 0x250], 3
call esi
cmp eax, ebx
jge 0x537c66
push eax
call fcn.00565a92
cmp word [esp + 0xc], 0xffff
jne 0x537ca3
lea ecx, [esp + 0x24]
push ecx
call esi
lea ecx, [esp + 0x10]
mov byte [esp + 0x24c], bl
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x254]
mov dword [esp + 0x24c], 0xffffffff
call sub.MFC42.DLL_CString::CString
mov eax, 1
jmp 0x537cd3
lea edx, [esp + 0x24]
push edx
call esi
lea ecx, [esp + 0x10]
mov byte [esp + 0x24c], bl
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x254]
mov dword [esp + 0x24c], 0xffffffff
call sub.MFC42.DLL_CString::CString
xor eax, eax
mov ecx, dword [esp + 0x244]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
add esp, 0x244
ret 4