Function at 0x407b90
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4811c8
mov eax, dword fs:[0]
push eax
sub esp, 0x38
mov eax, dword [0x4a20a0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
cmp dword [edi], 0
jne 0x407be2
push 0xc
call fcn.004176eb
add esp, 4
mov dword [eax], 0
mov dword [eax + 4], 0
mov dword [eax + 8], 0
mov dword [edi], eax
mov ecx, edi
call fcn.00407ee0
test eax, eax
jne 0x407bf4
xor eax, eax
jmp 0x407ec3
mov eax, dword [edi]
mov ecx, dword [eax + 4]
sub ecx, dword [eax]
mov eax, 0x2fa0be83
imul ecx
sar edx, 5
mov ebx, edx
shr ebx, 0x1f
add ebx, edx
je 0x407bed
push 0
call fcn.004380a8
add esp, 4
mov esi, eax
push 0
push str.25dd4
push str.MainSetting
call fcn.0040da80
mov ecx, eax
call fcn.0041e5fe
mov ecx, eax
mov eax, esi
sub eax, ecx
mov dword [ebp - 0x44], ecx
cdq
xor eax, edx
sub eax, edx
cmp eax, 0x384
jle 0x407bed
push esi
push str.25dd4
push str.MainSetting
call fcn.0040da80
mov ecx, eax
call fcn.0041fe0c
push dword [ebp - 0x44]
call fcn.0042813f
add esp, 4
mov esi, eax
call fcn.0042812f
cmp esi, eax
jne 0x407c97
push 0
push str.3622c
push str.MainSetting
call fcn.0040da80
mov ecx, eax
call fcn.0041e5fe
mov esi, eax
xor eax, eax
cmp esi, ebx
cmovge esi, eax
jmp 0x407c99
xor esi, esi
mov ecx, dword [edi]
push esi
call fcn.00409bd0
inc esi
mov ebx, eax
push esi
push str.3622c
push str.MainSetting
call fcn.0040da80
mov ecx, eax
call fcn.0041fe0c
cmp dword [ebx + 0x78], 8
lea ecx, [ebx + 0x64]
lea edx, [ecx + 0x10]
jb 0x407cc9
mov ecx, dword [ecx]
mov edx, dword [edx]
mov esi, 1
cmp edx, esi
mov dword [ebp - 0x44], edx
cmovb esi, edx
test esi, esi
je 0x407cf7
mov edx, 0x49a9b4
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x407d28
add ecx, 2
add edx, 2
sub esi, 1
jne 0x407ce1
mov edx, dword [ebp - 0x44]
xor eax, eax
test eax, eax
jne 0x407d39
cmp edx, 1
jb 0x407d39
ja 0x407d39
lea eax, [ebp - 0x40]
push 0x49a9b8
push eax
call fcn.00420aa1
add esp, 8
lea ecx, [edi + 4]
push eax
call fcn.00409d80
lea ecx, [ebp - 0x40]
call fcn.00409d40
jmp 0x407d68
movzx eax, word [ecx]
cmp ax, word [edx]
mov edx, dword [ebp - 0x44]
sbb eax, eax
and eax, 0xfffffffe
inc eax
jmp 0x407cf9
call fcn.0040da80
mov ecx, eax
call fcn.0041e4e2
push eax
lea ecx, [edi + 4]
call fcn.00409cf0
push str.Config
lea ecx, [edi + 4]
call fcn.00409ca0
push 0x49a9dc
lea ecx, [edi + 4]
call fcn.00409ca0
lea esi, [ebx + 4]
mov ecx, edi
push esi
lea eax, [ebp - 0x28]
push eax
call fcn.004093e0
mov dword [ebp - 4], 0
lea eax, [ebp - 0x28]
cmp dword [ebx + 0x2c], 0
jbe 0x407e43
cmp dword [ebp - 0x14], 8
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x407db8
sub esp, 0x18
mov ecx, esp
push esi
call fcn.00409ee0
mov ecx, edi
call fcn.00409890
test eax, eax
je 0x407e6c
cmp dword [ebx + 0x48], 8
lea esi, [ebx + 0x34]
jb 0x407dc5
mov eax, dword [esi]
jmp 0x407dc7
mov eax, esi
cmp dword [ebx + 0x30], 8
push eax
lea eax, [ebx + 0x1c]
jb 0x407dd3
mov eax, dword [eax]
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push eax
call fcn.00409ee0
call fcn.004082c0
test eax, eax
jne 0x407e70
cmp dword [ebp - 0x14], 8
lea eax, [ebp - 0x28]
cmovae eax, dword [ebp - 0x28]
push eax
call fcn.0041ff38
sub esp, 0x14
lea eax, [ebx + 4]
mov ecx, esp
push eax
call fcn.00409ee0
mov ecx, edi
call fcn.00409890
test eax, eax
je 0x407e6c
cmp dword [esi + 0x14], 8
jb 0x407e21
mov esi, dword [esi]
cmp dword [ebx + 0x30], 8
lea eax, [ebx + 0x1c]
push esi
jb 0x407e2d
mov eax, dword [eax]
push eax
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push eax
call fcn.00409ee0
call fcn.004082c0
jmp 0x407e68
cmp dword [ebp - 0x14], 8
cmovae eax, dword [ebp - 0x28]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x407e70
sub esp, 0x18
mov ecx, esp
push esi
call fcn.00409ee0
mov ecx, edi
call fcn.00409890
test eax, eax
jne 0x407e70
xor esi, esi
jmp 0x407eb9
cmp dword [ebx + 0xa8], 8
movzx eax, byte [ebx]
push eax
lea eax, [ebx + 0x94]
jb 0x407e85
mov eax, dword [eax]
cmp dword [ebx + 0x90], 8
push eax
lea eax, [ebx + 0x7c]
jb 0x407e94
mov eax, dword [eax]
add ebx, 0x4c
push eax
cmp dword [ebx + 0x14], 8
jb 0x407ea0
mov ebx, dword [ebx]
push ebx
sub esp, 0x18
lea eax, [ebp - 0x28]
mov ecx, esp
push eax
call fcn.00409ee0
call fcn.00408760
mov esi, 1
lea ecx, [ebp - 0x28]
call fcn.00409d40
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00417499
mov esp, ebp
pop ebp
ret