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

Disassembly:
mov eax, 0x430e4c
call fcn.0041d9a8
sub esp, 0x278
push ebx
push esi
push edi
xor ebx, ebx
push str.DownLoadDllAndRunStart...
mov dword [ebp - 4], ebx
call fcn.00404422
pop ecx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
xor edx, edx
mov ecx, 0x3e8
div ecx
mov eax, dword [0x43c180]
mov dword [ebp - 0x10], eax
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x18], eax
push 0x40
pop ecx
xor eax, eax
mov byte [ebp - 0x180], bl
lea edi, [ebp - 0x17f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x180]
push eax
mov esi, 0x104
push esi
mov byte [ebp - 4], 2
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
lea eax, [ebp - 0x180]
push eax
call fcn.0041c1c0
test eax, eax
pop ecx
jne 0x404a30
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetTempPath_failed.lastError___d.
call fcn.00404422
pop ecx
pop ecx
jmp 0x404c12
lea eax, [ebp - 0x180]
push eax
lea ecx, [ebp - 0x18]
call fcn.00402471
push 0x43375c
lea ecx, [ebp - 0x18]
call fcn.00402878
push dword [ebp - 0x1c]
lea eax, [ebp - 0x10]
push dword [ebp - 0x18]
push str._sFInstP_d.dll
push eax
call fcn.00402865
push dword [ebp - 0x10]
mov edi, dword [ebp + 8]
push edi
push str.Will_down_file_URL___s.FILENAME_s.
call fcn.00404422
add esp, 0x1c
lea ecx, [ebp - 0x7c]
call fcn.00418300
push ebx
push ebx
push dword [ebp - 0x10]
lea ecx, [ebp - 0x7c]
push edi
mov byte [ebp - 4], 3
call fcn.00418b70
cmp eax, 0xffffffff
jne 0x404ad6
mov dword [ebp - 0x14], ebx
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
push ebx
push ebx
push dword [ebp - 0x10]
lea ecx, [ebp - 0x7c]
push edi
call fcn.00418b70
cmp eax, 0xffffffff
jne 0x404ad6
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0xffffffffffffffff
push edi
push str.CRsLoadCloud::DownLoadCldRsdDll_strUrl_s..._faild_hre___d__lasterror___d
call fcn.00404422
add esp, 0x10
inc dword [ebp - 0x14]
cmp dword [ebp - 0x14], 3
jl 0x404a96
jmp 0x404ae5
push dword [ebp - 0x10]
push str.Down_file__s_success.
call fcn.00404422
pop ecx
pop ecx
mov edi, dword [ebp - 0x10]
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
push edi
je 0x404bf7
push str.FileNameDLL___s_exist.
call fcn.00404422
pop ecx
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
cmp eax, ebx
mov dword [ebp - 0x24], eax
je 0x404bd7
push 0x4338b0
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
mov dword [ebp - 0x20], eax
je 0x404bb9
push 0x40
pop ecx
xor eax, eax
mov byte [ebp - 0x284], bl
lea edi, [ebp - 0x283]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
push esi
lea eax, [ebp - 0x284]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x284]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameA]
push eax
lea ecx, [ebp - 0x1c]
call fcn.00403265
push 7
push 7
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 4
call fcn.004032bb
push ebx
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 5
call fcn.00402498
push eax
call dword [ebp - 0x20]
pop ecx
push 0xffffffffffffffff
lea ecx, [ebp - 0x14]
call fcn.004024ea
push dword [ebp - 0x14]
push str.Start___is_over.ActionID___s
call fcn.00404422
pop ecx
pop ecx
lea ecx, [ebp - 0x14]
call fcn.004023b4
lea ecx, [ebp - 0x1c]
call fcn.004023b4
jmp 0x404bcc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Start_is_NULL.lastError__d
call fcn.00404422
pop ecx
pop ecx
push dword [ebp - 0x24]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x404bec
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push edi
push str.LoadLibrary__s_is_Failed.lastError__d
call fcn.00404422
add esp, 0xc
push dword [ebp - 0x10]
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
jmp 0x404c03
push str.FileNameDLL___s__not_exist.
call fcn.00404422
pop ecx
pop ecx
lea ecx, [ebp - 0x7c]
mov byte [ebp - 4], 2
call fcn.00418470
xor ebx, ebx
inc ebx
lea ecx, [ebp - 0x18]
call fcn.004023b4
lea ecx, [ebp - 0x10]
call fcn.004023b4
lea ecx, [ebp + 8]
call fcn.004023b4
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov eax, ebx
pop ebx
mov dword fs:[0], ecx
leave
ret