Function at 0x40b9c0
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x442492
mov eax, dword fs:[0]
push eax
sub esp, 0x100
mov eax, dword [0x452284]
xor eax, esp
mov dword [esp + 0xf8], eax
push ebx
push esi
push edi
mov eax, dword [0x452284]
xor eax, esp
push eax
lea eax, [esp + 0x110]
mov dword fs:[0], eax
xor ebx, ebx
push ebx
lea esi, [esp + 0x40]
call fcn.00406ea0
mov dword [esp + 0x118], ebx
mov dword [esp + 0x10], 1
jmp 0x40ba20
mov eax, dword [esp + 0x50]
push 0x445d34
xor edi, edi
lea ecx, [esp + 0x40]
call fcn.0040ec00
test eax, eax
je 0x40bbc5
cmp dword [esp + 0x54], 8
mov eax, dword [esp + 0x40]
jae 0x40ba4b
lea eax, [esp + 0x40]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40bbc5
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x54], esp
xor eax, eax
mov dword [ecx + 0x18], 7
mov dword [ecx + 0x14], ebx
push 0xffffffffffffffff
mov word [ecx + 4], ax
push ebx
lea eax, [esp + 0x60]
call fcn.00402780
lea ebx, [esp + 0x74]
call fcn.00408f60
add esp, 0x1c
lea ecx, [esp + 0x74]
push ecx
mov byte [esp + 0x11c], 1
call fcn.00418dc0
mov eax, 0xfffffe00
and dword [esp + 0x1c], eax
xor ebx, ebx
mov dword [esp + 0x20], ebx
and dword [esp + 0x2c], eax
mov dword [esp + 0x30], ebx
push 0xffffffffffffffff
push ebx
lea edx, [esp + 0x60]
push edx
lea ecx, [esp + 0xc0]
mov byte [esp + 0x124], 6
call fcn.00402610
mov eax, dword [esp + 0xb8]
mov esi, 0x10
cmp dword [esp + 0xcc], esi
jae 0x40baec
lea eax, [esp + 0xb8]
mov ecx, dword [esp + 0xc8]
lea edx, [esp + 0x14]
push edx
add ecx, eax
push ecx
push eax
lea eax, [esp + 0x80]
push eax
call fcn.00418e80
test al, al
je 0x40bb80
push str.extensions
lea ecx, [esp + 0x18]
push ecx
call fcn.004171f0
push str.settings
push eax
call fcn.004171f0
push 0x445cb8
push eax
call fcn.004171f0
push eax
lea ecx, [esp + 0x28]
call fcn.00416760
test al, al
jne 0x40bb80
push str.extensions
lea edx, [esp + 0x18]
push edx
call fcn.004171f0
push str.settings
push eax
call fcn.004171f0
push 0x445cb8
push eax
call fcn.004171f0
push str.state
push eax
call fcn.004171f0
mov ecx, eax
call fcn.00416980
cmp eax, 1
je 0x40bc5d
lea eax, [esp + 0x24]
mov byte [esp + 0x118], 4
call fcn.004165e0
lea eax, [esp + 0x14]
mov byte [esp + 0x118], 2
call fcn.004165e0
lea edi, [esp + 0x74]
call fcn.004049b0
mov byte [esp + 0x118], bl
cmp dword [esp + 0x70], esi
jb 0x40bbc5
mov eax, dword [esp + 0x5c]
push eax
call fcn.00438d27
add esp, 4
cmp dword [ebp + 8], 0x25
jl 0x40bcc6
push 1
lea esi, [esp + 0x5c]
call fcn.00406ea0
push 0xffffffffffffffff
xor ebx, ebx
push ebx
lea ecx, [esp + 0x44]
mov byte [esp + 0x120], 7
call fcn.00402780
mov esi, 8
mov byte [esp + 0x118], bl
cmp dword [esp + 0x70], esi
jb 0x40bc0f
mov ecx, dword [esp + 0x5c]
push ecx
call fcn.00438d27
add esp, 4
mov eax, dword [esp + 0x10]
mov edx, eax
dec eax
mov dword [esp + 0x10], eax
test edx, edx
jne 0x40ba20
cmp dword [esp + 0x54], esi
jb 0x40bc35
mov eax, dword [esp + 0x40]
push eax
call fcn.00438d27
add esp, 4
xor al, al
mov ecx, dword [esp + 0x110]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0xf8]
xor ecx, esp
call fcn.00425608
mov esp, ebp
pop ebp
ret 4
lea eax, [esp + 0x24]
mov byte [esp + 0x118], 4
call fcn.004165e0
lea eax, [esp + 0x14]
mov byte [esp + 0x118], 2
call fcn.004165e0
lea edi, [esp + 0x74]
call fcn.004049b0
cmp dword [esp + 0x70], esi
jb 0x40bc9b
mov eax, dword [esp + 0x5c]
push eax
call fcn.00438d27
add esp, 4
cmp dword [esp + 0x54], 8
mov dword [esp + 0x70], 0xf
mov dword [esp + 0x6c], ebx
mov byte [esp + 0x5c], bl
jb 0x40bcbf
mov ecx, dword [esp + 0x40]
push ecx
call fcn.00438d27
add esp, 4
mov al, 1
jmp 0x40bc37
cmp dword [esp + 0x54], 8
jb 0x40bc35
mov edx, dword [esp + 0x40]
push edx
jmp 0x40bc2d