Function at 0x485390
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x4dc168
mov eax, dword fs:[0]
push eax
sub esp, 0x48
push ebx
push ebp
push esi
push edi
mov eax, dword [0x513330]
xor eax, esp
push eax
lea eax, [esp + 0x5c]
mov dword fs:[0], eax
mov eax, dword [esp + 0x6c]
mov edi, ecx
push ecx
mov dword [edi + 4], eax
mov dword [edi + 0x284], eax
mov dword [edi + 0x1dc], eax
mov eax, esp
mov dword [esp + 0x70], esp
push eax
mov ecx, 0x4e7868
call fcn.00405a00
lea esi, [edi + 0x4c]
push esi
call fcn.0044e250
lea eax, [edi + 0x3d4]
push str.____________________Entrance____________________
lea ecx, [esp + 0x2c]
push ecx
push eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x34], str.Init
call fcn.00471a00
add esp, 0xc
lea edx, [esp + 0x1c]
xor ebx, ebx
push edx
mov dword [esp + 0x68], ebx
call fcn.0044e8b0
mov ebp, eax
push ebx
push str.LogLevel
mov ecx, esi
mov byte [esp + 0x6c], 1
call fcn.00450370
mov ebp, dword [ebp]
push eax
mov eax, ebp
call fcn.00471860
mov byte [esp + 0x68], bl
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
add esp, 4
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x485466
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push ebx
push str.NextCheckAutoUpdate
mov ecx, esi
call fcn.00450370
push ebx
mov esi, eax
call fcn.004a7a84
add esp, 4
cmp eax, esi
jb 0x4854fa
lea ecx, [esp + 0x24]
push ecx
mov ecx, str..log
call fcn.00405a00
mov esi, eax
lea edx, [esp + 0x1c]
push edx
mov byte [esp + 0x68], 2
call fcn.0044e8b0
push esi
push eax
mov byte [esp + 0x6c], 3
call fcn.0046cf20
mov byte [esp + 0x6c], 2
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
add esp, 8
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4854d6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x64], bl
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4854fa
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 1
lea ecx, [edi + 0x114]
call fcn.0048cd30
mov ebp, dword [esp + 0x14]
test al, al
jne 0x485533
push str.Failed_to_Init_m_parser__Missing_scripts0.yds__
lea ecx, [esp + 0x2c]
push ecx
push ebp
call fcn.00471980
mov edx, dword [edi + 4]
add esp, 0xc
push ebx
push ebx
push 0x405
push edx
call dword [sym.imp.USER32.dll_PostMessageW]
mov ecx, edi
call fcn.00485760
lea esi, [esp + 0x24]
call fcn.004511b0
mov byte [esp + 0x64], 4
mov eax, dword [eax]
lea ecx, [esp + 0x6c]
push ecx
mov ecx, eax
call fcn.00405a00
mov byte [esp + 0x64], 6
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x48557b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x6c]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x48565d
mov esi, vtable.ATL::CSecurityDesc.0
mov dword [esp + 0x3c], esi
mov dword [esp + 0x40], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
push 1
lea edx, [esp + 0x48]
push edx
mov byte [esp + 0x6c], 7
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push ebx
push ebx
push 1
lea eax, [esp + 0x50]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
lea eax, [esp + 0x44]
lea ecx, [esp + 0x1c]
mov dword [esp + 0x1c], esi
mov dword [esp + 0x20], ebx
call fcn.0045bd00
mov byte [esp + 0x64], 8
mov edx, dword [esp + 0x3c]
mov eax, dword [edx + 4]
lea ecx, [esp + 0x3c]
call eax
mov eax, dword [esp + 0x20]
cmp eax, ebx
je 0x485600
lea ecx, [esp + 0x3c]
call fcn.0045bd00
mov ecx, dword [esp + 0x40]
mov dword [esp + 0x34], ecx
lea ecx, [esp + 0x1c]
mov dword [esp + 0x30], 0xc
mov dword [esp + 0x38], ebx
mov dword [esp + 0x1c], esi
call fcn.0045beb0
mov eax, dword [esp + 0x6c]
push ebx
push 0x80
push 2
lea edx, [esp + 0x3c]
push edx
push 1
push 0x120116
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, ebx
je 0x48564b
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov byte [esp + 0x64], 6
lea ecx, [esp + 0x3c]
mov dword [esp + 0x3c], esi
call fcn.0045beb0
mov esi, dword [sym.imp.WININET.dll_InternetSetOptionW]
push 4
lea ecx, [esp + 0x1c]
push ecx
push 0x49
push ebx
mov dword [esp + 0x28], 0x20
call esi
push 4
lea edx, [esp + 0x1c]
push edx
push 0x4a
push ebx
call esi
mov ecx, edi
call fcn.00487070
test al, al
jne 0x4856a1
push str.Failed_to_load_localized_resources.
lea eax, [esp + 0x2c]
push eax
push ebp
call fcn.00471980
add esp, 0xc
lea esi, [esp + 0x14]
call fcn.004511b0
mov ecx, esi
push ecx
add edi, 0x414
push edi
mov byte [esp + 0x6c], 9
call fcn.00489ff0
mov esi, dword [esp + 0x14]
test al, al
jne 0x4856da
push esi
push str.Failed_to_Load_saved_items_from_file__s.
lea edx, [esp + 0x30]
push edx
push ebp
call fcn.00471980
add esp, 0x10
lea eax, [esi - 0x10]
mov byte [esp + 0x64], 6
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4856fb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x64], bl
mov eax, dword [esp + 0x6c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x48571f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push str.______________________Exit______________________
lea ecx, [esp + 0x2c]
mov dword [esp + 0x68], 0xffffffff
mov edx, dword [esp + 0x30]
push ecx
push edx
call fcn.00471a00
add esp, 0xc
xor eax, eax
mov ecx, dword [esp + 0x5c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x54
ret 4