Function at 0x402f50
Capabilities:
Create process on windows
Create process suspended
Resume thread
Terminate process

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x40783c
mov eax, dword fs:[0]
push eax
sub esp, 0x4e8
mov eax, dword [0x40b040]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov edx, dword [ebp + 0xc]
xorps xmm0, xmm0
mov dword [ebp - 4], 0
xor eax, eax
movups xmmword [ebp - 0x5c], xmm0
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x48], 7
mov word [ebp - 0x5c], ax
movlpd qword [ebp - 0x64], xmm0
mov dword [ebp - 0x64], eax
mov dword [ebp - 0x60], eax
movq qword [ebp - 0x2c], xmm0
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], eax
movq qword [ebp - 0x20], xmm0
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x20]
mov byte [ebp - 4], 5
push eax
lea eax, [ebp - 0x2c]
push eax
push ecx
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x5c]
push eax
call fcn.00402570
add esp, 0x10
mov dword [ebp - 4], 4
lea eax, [ebp - 0x1ac]
push 0xb0
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 8
lea ecx, [ebp - 0x1ac]
call fcn.00403f90
mov byte [ebp - 4], 7
lea edx, [ebp - 0x5c]
cmp dword [ebp - 0x48], 7
lea ecx, [ebp - 0x19c]
push dword [ebp - 0x4c]
cmova edx, dword [ebp - 0x5c]
call fcn.00405290
add esp, 4
mov edx, str..exe
mov ecx, eax
call fcn.00404760
lea eax, [ebp - 0x44]
push eax
lea ecx, [ebp - 0x1ac]
call fcn.00403e90
push 0xb0
lea eax, [ebp - 0x25c]
mov byte [ebp - 4], 8
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 8
lea ecx, [ebp - 0x25c]
call fcn.00403f90
mov byte [ebp - 4], 9
lea edx, [ebp - 0x44]
cmp dword [ebp - 0x30], 7
lea ecx, [ebp - 0x24c]
push dword [ebp - 0x34]
cmova edx, dword [ebp - 0x44]
call fcn.00405290
mov edi, dword [ebp - 0x20]
add esp, 4
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x490], eax
cmp edi, eax
je 0x403194
mov edx, 0x4083fc
lea ecx, [ebp - 0x24c]
call fcn.00404760
cmp dword [edi + 0x14], 7
mov esi, edi
mov ecx, dword [edi + 0x10]
jbe 0x4030c8
mov esi, dword [edi]
test ecx, ecx
je 0x403110
xor eax, eax
mov edx, esi
cmp word [esi], 0x20
je 0x4030e5
cmp ecx, 1
je 0x4030e9
add edx, 2
dec ecx
cmp word [edx], 0x20
jne 0x4030d6
mov ecx, edx
jmp 0x4030eb
mov ecx, eax
test ecx, ecx
je 0x403110
sub ecx, esi
sar ecx, 1
mov dword [ebp - 0x48c], ecx
cmp ecx, 0xffffffff
je 0x40311a
mov edx, 0x408400
lea ecx, [ebp - 0x24c]
call fcn.00404760
jmp 0x40311a
mov dword [ebp - 0x48c], 0xffffffff
cmp dword [edi + 0x14], 7
jbe 0x403126
mov esi, dword [edi]
mov ecx, esi
jmp 0x40312a
mov esi, edi
mov ecx, edi
mov eax, dword [edi + 0x10]
lea eax, [ecx + eax*2]
mov dword [ebp - 0x494], eax
cmp esi, eax
je 0x40316d
movzx edx, word [esi]
lea ecx, [ebp - 0x24c]
cmp edx, 0x22
jne 0x40315d
mov edx, 0x408404
call fcn.00404760
mov eax, dword [ebp - 0x494]
add esi, 2
jmp 0x403136
call fcn.00404990
mov eax, dword [ebp - 0x494]
add esi, 2
jmp 0x403136
cmp dword [ebp - 0x48c], 0xffffffff
je 0x403186
mov edx, 0x408400
lea ecx, [ebp - 0x24c]
call fcn.00404760
mov eax, dword [ebp - 0x490]
add edi, 0x18
jmp 0x4030a3
lea eax, [ebp - 0x7c]
push eax
lea ecx, [ebp - 0x25c]
call fcn.00403e90
mov eax, dword [ebp - 0x25c]
mov eax, dword [eax + 4]
mov dword [ebp + eax - method.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.virtual_0], vtable.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
mov eax, dword [ebp - 0x25c]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0x260], eax
lea ecx, [ebp - 0x244]
call fcn.00403de0
lea ecx, [ebp - 0x23c]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_iostream_wchar_t__struct_std::char_traits_wchar_t__::destructor_void_]
lea ecx, [ebp - 0x1f4]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ios_wchar_t__struct_std::char_traits_wchar_t__::destructor_void_]
mov byte [ebp - 4], 0xa
lea edx, [ebp - 0x488]
cmp dword [ebp - 0x68], 7
lea ecx, [ebp - 0x7c]
push edx
cmova ecx, dword [ebp - 0x7c]
lea edx, [ebp - 0xfc]
cmp dword [ebp - 0x30], 7
lea eax, [ebp - 0x44]
push edx
cmova eax, dword [ebp - 0x44]
xorps xmm0, xmm0
push 0
push 0
push 4
push 0
push 0
push 0
push ecx
push eax
movlpd qword [ebp - 0xf8], xmm0
movlpd qword [ebp - 0xf0], xmm0
movlpd qword [ebp - 0xe8], xmm0
movlpd qword [ebp - 0xe0], xmm0
movlpd qword [ebp - 0xd8], xmm0
movlpd qword [ebp - 0xd0], xmm0
movlpd qword [ebp - 0xc8], xmm0
movlpd qword [ebp - 0xc0], xmm0
mov dword [ebp - 0xfc], 0x44
movups xmmword [ebp - 0x488], xmm0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
je 0x40358d
lea eax, [ebp - 0x488]
mov dword [ebp - fcn.00405920], vtable.std::_Func_impl_no_alloc_class__int___cdecl_wmain_int__wchar_t___::_3::_lambda_1___void___.0
mov dword [ebp - 0x4bc], eax
lea eax, [ebp - 0x4c0]
mov dword [ebp - 0x49c], eax
lea eax, [ebp - 0xa4]
mov dword [ebp - 0x80], 0
mov dword [ebp - 0x490], eax
push eax
lea ecx, [ebp - 0x4c0]
mov byte [ebp - 4], 0xc
call fcn.00405920
mov ecx, dword [ebp - 0x49c]
mov dword [ebp - 0x80], eax
test ecx, ecx
je 0x4032f4
mov eax, dword [ecx]
mov edx, dword [eax + 0x10]
lea eax, [ebp - 0x4c0]
cmp ecx, eax
setne al
push eax
call edx
mov dword [ebp - 0x49c], 0
push 0x2c8
lea eax, [ebp - 0x474]
mov byte [ebp - 4], 0xe
push 0
push eax
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
mov dword [ebp - 0x478], 0x10002
lea eax, [ebp - 0x478]
push eax
push dword [ebp - 0x484]
call dword [sym.imp.KERNEL32.dll_GetThreadContext]
test eax, eax
je 0x4035bd
movups xmm0, xmmword [ebp - 0x488]
mov eax, dword [ebp - 0x3c8]
mov esi, dword [ebp - 0x2c]
mov edi, dword [ebp - 0x28]
movups xmmword [ebp - 0xb8], xmm0
mov dword [ebp - 0xa8], eax
cmp esi, edi
je 0x403369
mov ecx, dword [esi]
lea edx, [ebp - 0xb8]
push edx
mov eax, dword [ecx]
call dword [eax]
add esi, 4
jmp 0x403353
push dword [ebp - 0x484]
call dword [sym.imp.KERNEL32.dll_ResumeThread]
mov dword [ebp - 4], 0x10
mov ecx, dword [ebp - 0x80]
test ecx, ecx
jne 0x403389
call dword [sym.imp.MSVCP140.dll_void___cdecl_std::_Xbad_function_call_void_]
mov eax, dword [ecx]
call dword [eax + 8]
mov ecx, dword [ebp - 0x80]
test ecx, ecx
je 0x4033b0
mov edx, dword [ecx]
lea eax, [ebp - 0xa4]
cmp ecx, eax
setne al
movzx eax, al
push eax
call dword [edx + 0x10]
mov dword [ebp - 0x80], 0
mov ecx, dword [ebp - 0x68]
cmp ecx, 7
jbe 0x4033ea
mov edx, dword [ebp - 0x7c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x4033e0
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x403535
push ecx
push edx
call fcn.00406a4f
add esp, 8
mov ecx, dword [ebp - 0x30]
xor eax, eax
mov dword [ebp - 0x6c], 0
mov dword [ebp - 0x68], 7
mov word [ebp - 0x7c], ax
cmp ecx, 7
jbe 0x403438
mov edx, dword [ebp - 0x44]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40342e
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x403535
push ecx
push edx
call fcn.00406a4f
add esp, 8
xor eax, eax
mov dword [ebp - 0x34], 0
mov word [ebp - 0x44], ax
mov eax, dword [ebp - 0x1ac]
mov dword [ebp - 0x30], 7
mov eax, dword [eax + 4]
mov dword [ebp + eax - method.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.virtual_0], vtable.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
mov eax, dword [ebp - 0x1ac]
mov ecx, dword [eax + 4]
lea eax, [ecx - 0x68]
mov dword [ebp + ecx - 0x1b0], eax
lea ecx, [ebp - 0x194]
call fcn.00403de0
lea ecx, [ebp - 0x18c]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_iostream_wchar_t__struct_std::char_traits_wchar_t__::destructor_void_]
lea ecx, [ebp - 0x144]
call dword [sym.imp.MSVCP140.dll_public_virtual:_void___thiscall_std::basic_ios_wchar_t__struct_std::char_traits_wchar_t__::destructor_void_]
mov ecx, dword [ebp - 0x20]
test ecx, ecx
je 0x403501
mov edx, dword [ebp - 0x1c]
push ecx
call fcn.00404cb0
mov ecx, dword [ebp - 0x18]
mov eax, 0x2aaaaaab
mov esi, dword [ebp - 0x20]
add esp, 4
sub ecx, esi
imul ecx
sar edx, 2
mov eax, edx
shr eax, 0x1f
add eax, edx
lea ecx, [eax + eax*2]
mov eax, esi
shl ecx, 3
cmp ecx, 0x1000
jb 0x4034e2
mov esi, dword [eax - 4]
add ecx, 0x23
sub eax, esi
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x403535
push ecx
push esi
call fcn.00406a4f
add esp, 8
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 0
lea ecx, [ebp - 0x2c]
call fcn.00404380
mov ecx, dword [ebp - 0x48]
cmp ecx, 7
jbe 0x403545
mov edx, dword [ebp - 0x5c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x40353b
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
jbe 0x40353b
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
push ecx
push edx
call fcn.00406a4f
add esp, 8
xor eax, eax
jmp 0x403571
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004066a6
mov esp, ebp
pop ebp
ret
call fcn.00401cf0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push str.CreateProcess
push esi
push eax
lea ecx, [ebp - 0x4e0]
call fcn.004019c0
push 0x409f20
lea eax, [ebp - 0x4e0]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
call fcn.00401cf0
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
push 0x408510
push esi
push eax
lea ecx, [ebp - 0x4f4]
call fcn.004019c0
push 0x409f20
lea eax, [ebp - 0x4f4]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
push 1
push dword [ebp - 0x488]
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
push 0
push 0
call sub.VCRUNTIME140.dll__CxxThrowException
push str.Usage:_abapatch__game___patch_args___game_args_
lea ecx, [ebp - 0x4cc]
call fcn.00401560
push 0x409f40
lea eax, [ebp - 0x4cc]
push eax
call sub.VCRUNTIME140.dll__CxxThrowException
int3