Function at 0x4976d0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
sub esp, 0x3c
lea eax, [esp + 1]
lea ecx, [esp + 0x18]
push ebx
push esi
push edi
push eax
call fcn.00405d90
mov edi, str.helpType
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, str.helpType
push ecx
push str.helpType
lea ecx, [esp + 0x2c]
call fcn.00406380
lea ecx, [esp + 0xe]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00405d90
mov edi, 0x6092e0
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, 0x6092e0
push ecx
push 0x6092e0
lea ecx, [esp + 0x20]
call fcn.00406380
lea edx, [esp + 0x24]
push 0
lea eax, [esp + 0x1c]
push edx
push eax
call fcn.00409fb0
add esp, 0xc
lea ecx, [esp + 0x18]
mov ebx, eax
call fcn.00406010
lea ecx, [esp + 0x24]
call fcn.00406010
push 0x1bc9
mov ecx, 0x628700
call fcn.005cbd90
mov esi, eax
test esi, esi
je 0x497a15
lea ecx, [esp + 0xe]
push 8
push ecx
lea ecx, [esp + 0x20]
call fcn.00405da0
mov edx, dword [esp + 0x1c]
lea eax, [esp + 0xe]
push eax
lea ecx, [esp + 0x34]
mov byte [edx], 0
call fcn.00405d90
mov edi, str.lastfile
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, str.lastfile
push ecx
push str.lastfile
lea ecx, [esp + 0x38]
call fcn.00406380
lea ecx, [esp + 0xd]
push ecx
lea ecx, [esp + 0x28]
call fcn.00405d90
mov edi, str.user
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, str.user
push ecx
push str.user
lea ecx, [esp + 0x2c]
call fcn.00406380
lea edx, [esp + 0x18]
lea eax, [esp + 0x30]
push edx
lea ecx, [esp + 0x28]
push eax
lea edx, [esp + 0x44]
push ecx
push edx
call fcn.00409be0
lea ecx, [esp + 0x28]
add esp, 0x10
cmp eax, ecx
je 0x49782f
mov edx, dword [esp + 0x14]
mov ecx, dword [eax + 4]
push edx
mov edx, dword [eax]
push ecx
push edx
lea ecx, [esp + 0x24]
call fcn.00406830
lea ecx, [esp + 0x3c]
call fcn.00406010
lea ecx, [esp + 0x24]
call fcn.00406010
lea ecx, [esp + 0x30]
call fcn.00406010
mov ecx, dword [esp + 0x1c]
mov eax, dword [esp + 0x18]
sub ecx, eax
je 0x497922
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x497922
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x68]
mov edi, 0x609640
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push 0xffffffffffffffff
push 0x609640
lea ecx, [esp + 0x24]
call fcn.004927c0
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x18]
mov edi, ecx
sub edi, edx
cmp eax, edi
jae 0x4978cb
inc eax
sub ecx, edx
mov dword [esp + 0x14], eax
cmp ecx, eax
mov dword [esp + 0x10], ecx
lea eax, [esp + 0x10]
jb 0x4978b8
lea eax, [esp + 0x14]
mov eax, dword [eax]
lea ecx, [esp + 0x18]
add eax, edx
push eax
push edx
call fcn.00407dd0
mov edx, dword [esp + 0x18]
test ebx, ebx
mov eax, 0x1bd3
je 0x4978e0
mov ecx, dword [0x61caa0]
lea eax, [ecx + 0x1bd3]
push edx
lea edx, [esp + 0x40]
push eax
push edx
call fcn.0045e0e0
push eax
call fcn.00404b90
add esp, 0x10
lea eax, [esp + 0x3c]
lea ecx, [esi + 0xc]
mov dword [esi + 0x54], 0
push eax
call fcn.00407c80
lea ecx, [esp + 0x3c]
call fcn.00406010
lea ecx, [esp + 0x18]
call fcn.00406010
pop edi
pop esi
pop ebx
add esp, 0x3c
ret
mov edx, dword [esi]
mov ecx, esi
call dword [edx + 0x6c]
lea eax, [esp + 0xe]
lea ecx, [esp + 0x3c]
push eax
call fcn.00405d90
mov edi, 0x61f1e0
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, 0x61f1e0
push ecx
push 0x61f1e0
lea ecx, [esp + 0x44]
call fcn.00406380
lea ecx, [esp + 0xd]
push ecx
lea ecx, [esp + 0x28]
call fcn.00405d90
mov edi, str.lastfile
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, str.lastfile
push ecx
push str.lastfile
lea ecx, [esp + 0x2c]
call fcn.00406380
lea edx, [esp + 0xf]
lea ecx, [esp + 0x30]
push edx
call fcn.00405d90
mov edi, str.user
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, str.user
push ecx
push str.user
lea ecx, [esp + 0x38]
call fcn.00406380
lea eax, [esp + 0x3c]
lea ecx, [esp + 0x24]
push eax
lea edx, [esp + 0x34]
push ecx
push edx
call fcn.0040a0b0
add esp, 0xc
lea ecx, [esp + 0x30]
call fcn.00406010
lea ecx, [esp + 0x24]
call fcn.00406010
lea ecx, [esp + 0x3c]
call fcn.00406010
test ebx, ebx
mov eax, 0x1bd7
je 0x497a04
mov eax, dword [0x61caa0]
add eax, 0x1bd7
push eax
mov ecx, esi
call fcn.005c6810
lea ecx, [esp + 0x18]
call fcn.00406010
pop edi
pop esi
pop ebx
add esp, 0x3c
ret