Function at 0x409ed0
Capabilities:
Check if file exists
Create process on windows
Delete file
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x60
cmp dword [0x506568], 0
mov dword [ebp - 8], ecx
jne 0x409f01
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
push ebx
push esi
push edi
push str.softwareGamePP
lea eax, [ebp - 4]
push eax
call fcn.004143b0
mov edi, dword [ebp - 4]
or ebx, 0xffffffff
cmp dword [edi - 0xc], 0
jne 0x409f7a
cmp dword [0x506568], 0
jne 0x409f46
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
push str.softwarePUBGTools
lea eax, [ebp - 0xc]
push eax
call fcn.004143b0
push eax
lea ecx, [ebp - 4]
call fcn.00403e50
mov edx, dword [ebp - 0xc]
mov eax, ebx
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x409f77
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov edi, dword [ebp - 4]
call fcn.004031c0
mov ecx, eax
test ecx, ecx
je 0x40a14b
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
push edi
mov dword [ebp - 4], eax
lea eax, [ebp - 4]
push str._sUninstall.exe
push eax
call fcn.004040c0
mov esi, dword [ebp - 4]
add esp, 0xc
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x40a10e
mov eax, dword [0x506568]
test eax, eax
jne 0x409fe5
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
mov eax, dword [0x506568]
cmp dword [eax + 0x1ec4], 0
mov eax, dword [ebp - 8]
je 0x40a002
push 2
sub esp, 8
push str.Now_uninstall_the_old_version_
push str.Found_that_there_is_an_old_version_of_GamePP_
jmp 0x40a011
push 1
sub esp, 8
push 0x4d9ea8
push 0x4dbcb4
push dword [eax + 4]
call fcn.00409d00
cmp eax, 1
jne 0x40a10e
mov eax, dword [ebp - 8]
push 0
push dword [eax + 4]
call dword [sym.imp.USER32.dll_ShowWindow]
cmp dword [esi - 4], 1
jle 0x40a044
push dword [esi - 0xc]
lea ecx, [ebp - 4]
call fcn.00403890
mov esi, dword [ebp - 4]
cmp dword [0x506568], 0
jne 0x40a06c
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
push 0x40
lea eax, [ebp - 0x5c]
mov dword [ebp - 0x60], 0x44
push 0
push eax
call fcn.0049b560
add esp, 0xc
mov dword [ebp - 0x34], 1
mov eax, 1
mov word [ebp - 0x30], ax
lea eax, [ebp - 0x1c]
push eax
lea eax, [ebp - 0x60]
push eax
push 0
push 0
push 0x30
push 0
push 0
push 0
push esi
push 0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
push 0xffffffffffffffff
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0xc]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_GetExitCodeProcess]
push dword [ebp - 0x1c]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
call ebx
push dword [ebp - 0x18]
call ebx
push dword [esi - 8]
push esi
call fcn.004a38d8
add esp, 8
test eax, eax
js 0x40a141
cmp eax, dword [esi - 8]
jg 0x40a141
xor ecx, ecx
mov dword [esi - 0xc], eax
push esi
mov word [esi + eax*2], cx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [ebp - 8]
push 5
push dword [eax + 4]
call dword [sym.imp.USER32.dll_ShowWindow]
or ebx, 0xffffffff
add esi, 0xfffffff0
mov eax, ebx
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x40a125
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
add edi, 0xfffffff0
lock xadd dword [edi + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x40a13a
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00402f10
push 0x80004005
call fcn.00402f10
int3