Function at 0x402ca0
Capabilities:
Check if file exists

Disassembly:
push 0xffffffffffffffff
push 0x442beb
mov eax, dword fs:[0]
push eax
sub esp, 0x430
mov eax, dword [0x457600]
xor eax, esp
mov dword [esp + 0x42c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x457600]
xor eax, esp
push eax
lea eax, [esp + 0x444]
mov dword fs:[0], eax
mov eax, dword [esp + 0x454]
mov esi, edx
xor edx, edx
push 0x206
mov dword [esp + 0x24], eax
push edx
lea eax, [esp + 0x3a]
push eax
mov dword [esp + 0x34], esi
mov dword [esp + 0x38], ecx
mov word [esp + 0x3c], dx
call fcn.0042fb00
push esi
lea ecx, [esp + 0x40]
push 0x104
push ecx
call fcn.0042d97f
mov esi, dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
add esp, 0x18
lea edx, [esp + 0x30]
push edx
call esi
mov ebp, dword [sym.imp.SHLWAPI.dll_StrCatW]
push str.GamePatch
lea eax, [esp + 0x34]
push eax
call ebp
lea ecx, [esp + 0x30]
push ecx
call esi
push str.reg.cfg
lea edx, [esp + 0x34]
push edx
call ebp
lea eax, [esp + 0x30]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x402fc8
push 0x10
call fcn.004110f8
add esp, 4
mov dword [esp + 0x24], eax
mov dword [esp + 0x44c], 0
test eax, eax
je 0x402d87
mov ecx, eax
call fcn.00411aa9
mov esi, eax
jmp 0x402d89
xor esi, esi
push 0
mov dword [esp + 0x450], 0xffffffff
mov edx, dword [esi]
mov edx, dword [edx + 0x20]
push 0x10
lea eax, [esp + 0x38]
push eax
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0x30]
mov ecx, esi
call edx
mov edi, eax
xor ecx, ecx
lea eax, [edi + 1]
mov edx, 2
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.00411127
add esp, 4
mov ebx, eax
mov eax, dword [esi]
mov edx, dword [eax + 0x34]
push edi
push ebx
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0x4c]
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 4]
push 1
mov ecx, esi
call edx
push ebx
lea ecx, [esp + 0x20]
call fcn.00406b70
mov dword [esp + 0x44c], 1
test ebx, ebx
je 0x402e10
push ebx
call fcn.00411132
add esp, 4
push str.gamepath
lea ecx, [esp + 0x1c]
call fcn.00406b70
mov eax, dword [esp + 0x28]
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x450], 2
call fcn.00406b70
push 0x44a588
push 0x449f28
lea ecx, [esp + 0x1c]
push ecx
mov byte [esp + 0x458], 3
call fcn.00404fa0
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
push edx
push eax
lea ecx, [esp + 0x24]
push ecx
call fcn.00404fa0
mov edx, dword [esp + 0x18]
mov edx, dword [edx - 0xc]
mov ecx, dword [esp + 0x14]
mov ecx, dword [ecx - 0xc]
sub ecx, edx
imul ecx, eax
xor edx, edx
push 0x206
push edx
lea eax, [esp + 0x242]
push eax
lea ebx, [edi + ecx*2]
mov word [esp + 0x244], dx
call fcn.0042fb00
mov ecx, dword [esp + 0x2c]
add esp, 0xc
lea edi, [esp + 0x238]
call fcn.00401130
mov ecx, edi
push ecx
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
mov edx, dword [esp + 0x2c]
push edx
mov eax, edi
push eax
call ebp
push 0x44a590
mov ecx, edi
push ecx
call ebp
push 0x10
call fcn.004110f8
add esp, 4
mov dword [esp + 0x24], eax
mov byte [esp + 0x44c], 4
test eax, eax
je 0x402eec
mov ecx, eax
call fcn.00411aa9
mov esi, eax
jmp 0x402eee
xor esi, esi
push 0
mov byte [esp + 0x450], 3
mov edx, dword [esi]
mov edx, dword [edx + 0x20]
push 0x1001
lea eax, [esp + 0x240]
push eax
mov ecx, esi
call edx
mov ecx, dword [esp + 0x1c]
mov eax, dword [esi]
mov edx, dword [eax + 0x38]
push ebx
push ecx
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 0x4c]
mov ecx, esi
call edx
mov eax, dword [esi]
mov edx, dword [eax + 4]
push 1
mov ecx, esi
call edx
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [esp + 0x23c]
push eax
push str.MSG:_Convert_succeed__file_s__code_d
call fcn.0040c990
mov byte [esp + 0x458], 2
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
add esp, 0xc
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402f75
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x44c], 1
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402f9d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x44c], 0xffffffff
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x402fc8
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, 1
mov ecx, dword [esp + 0x444]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x42c]
xor ecx, esp
call fcn.0042d791
add esp, 0x43c
ret 4