Function at 0x411860
Capabilities:
Check if file exists
Create process on windows
Print debug messages

Disassembly:
push 0xffffffffffffffff
push 0x446061
mov eax, dword fs:[0]
push eax
sub esp, 0xc0
mov eax, dword [0x4561c4]
xor eax, esp
mov dword [esp + 0xbc], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4561c4]
xor eax, esp
push eax
lea eax, [esp + 0xd4]
mov dword fs:[0], eax
mov eax, dword [esp + 0xe4]
mov dword [esp + 0x18], eax
mov dword [esp + 0xdc], 1
mov edx, dword [0x458fec]
mov eax, dword [edx + 0xc]
mov ecx, 0x458fec
call eax
add eax, 0x10
mov dword [esp + 0x14], eax
lea ecx, [esp + 0x1c]
push ecx
mov byte [esp + 0xe0], 2
call fcn.00423530
add esp, 4
mov esi, 8
mov byte [esp + 0xdc], 3
cmp dword [eax + 0x18], esi
jb 0x4118f4
mov eax, dword [eax + 4]
jmp 0x4118f7
add eax, 4
push eax
push str._sgameCore_cef.exe
lea edi, [esp + 0x1c]
call fcn.0040ea70
add esp, 8
mov byte [esp + 0xdc], 2
cmp dword [esp + 0x34], esi
jb 0x411924
mov edx, dword [esp + 0x20]
push edx
call fcn.0042bc90
add esp, 4
xor ebp, ebp
xor eax, eax
mov word [esp + 0x9c], ax
mov eax, dword [esp + 0x14]
mov edi, 7
mov ecx, eax
mov dword [esp + 0xb0], edi
mov dword [esp + 0xac], ebp
lea esi, [ecx + 2]
lea esp, [esp]
mov dx, word [ecx]
add ecx, 2
cmp dx, bp
jne 0x411950
sub ecx, esi
sar ecx, 1
push ecx
lea esi, [esp + 0x9c]
call fcn.00401b20
xor ecx, ecx
mov dword [esp + 0xcc], edi
mov dword [esp + 0xc8], ebp
mov word [esp + 0xb8], cx
mov bl, 5
mov byte [esp + 0xdc], bl
cmp dword [esp + 0x11c], 0x10
mov eax, dword [esp + 0x108]
jae 0x4119a5
lea eax, [esp + 0x108]
lea edx, [esp + 0xb4]
push edx
push eax
call fcn.004245d0
add esp, 8
lea eax, [esp + 0x1c]
push eax
call fcn.0041dc60
mov esi, 8
mov byte [esp + 0xdc], 6
cmp dword [eax + 0x18], esi
jb 0x4119d7
mov ecx, dword [eax + 4]
jmp 0x4119da
lea ecx, [eax + 4]
mov edx, dword [esp + 0xb8]
cmp dword [esp + 0xcc], esi
jae 0x4119f1
lea edx, [esp + 0xb8]
mov eax, dword [esp + 0xec]
cmp dword [esp + 0x100], esi
jae 0x411a08
lea eax, [esp + 0xec]
push ecx
mov ecx, dword [esp + 0x124]
push ecx
mov ecx, dword [esp + 0x20]
push 0x44ac48
push 0x44ac48
push edx
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 0x8c]
call eax
push eax
push str._p_d__u_s__d_s__a_s__b_s__m_d__c_s
lea edi, [esp + 0x34]
call fcn.0040ea70
add esp, 0x20
mov byte [esp + 0xdc], bl
cmp dword [esp + 0x34], esi
jb 0x411a57
mov ecx, dword [esp + 0x20]
push ecx
call fcn.0042bc90
add esp, 4
mov edi, dword [esp + 0x14]
xor edx, edx
mov ebx, 7
mov eax, edi
mov word [esp + 0x80], dx
mov dword [esp + 0x94], ebx
mov dword [esp + 0x90], ebp
lea edx, [eax + 2]
lea ecx, [ecx]
mov cx, word [eax]
add eax, 2
cmp cx, bp
jne 0x411a80
sub eax, edx
sar eax, 1
push eax
mov eax, edi
lea esi, [esp + 0x80]
call fcn.00401b20
mov eax, dword [esp + 0x80]
mov esi, 8
cmp dword [esp + 0x94], esi
jae 0x411aba
lea eax, [esp + 0x80]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
mov eax, dword [esp + 0x9c]
cmp dword [esp + 0xb0], esi
jae 0x411ad8
lea eax, [esp + 0x9c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x411b69
xor eax, eax
push 0x40
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
lea eax, [esp + 0x40]
push ebp
push eax
mov dword [esp + 0x28], ebp
call fcn.0042f7b0
mov ecx, dword [esp + 0x8c]
add esp, 0xc
mov dword [esp + 0x38], 0x44
cmp dword [esp + 0x94], esi
jae 0x411b28
lea ecx, [esp + 0x80]
mov eax, dword [esp + 0x9c]
cmp dword [esp + 0xb0], esi
jae 0x411b3f
lea eax, [esp + 0x9c]
lea edx, [esp + 0x1c]
push edx
lea edx, [esp + 0x3c]
push edx
push ebp
push ebp
push 0x220
push ebp
push ebp
push ebp
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x18]
mov dword [ecx + 0x2438], eax
cmp dword [esp + 0x94], esi
jb 0x411b82
mov edx, dword [esp + 0x80]
push edx
call fcn.0042bc90
add esp, 4
xor eax, eax
mov dword [esp + 0x94], ebx
mov dword [esp + 0x90], ebp
mov word [esp + 0x80], ax
cmp dword [esp + 0xcc], esi
jb 0x411bb3
mov ecx, dword [esp + 0xb8]
push ecx
call fcn.0042bc90
add esp, 4
xor edx, edx
mov dword [esp + 0xcc], ebx
mov dword [esp + 0xc8], ebp
mov word [esp + 0xb8], dx
cmp dword [esp + 0xb0], esi
jb 0x411be4
mov eax, dword [esp + 0x9c]
push eax
call fcn.0042bc90
add esp, 4
xor ecx, ecx
lea eax, [edi - 0x10]
mov word [esp + 0x9c], cx
mov dword [esp + 0xb0], ebx
mov dword [esp + 0xac], ebp
mov byte [esp + 0xdc], 1
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x411c20
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp dword [esp + 0x100], esi
jb 0x411c39
mov ecx, dword [esp + 0xec]
push ecx
call fcn.0042bc90
add esp, 4
xor edx, edx
cmp dword [esp + 0x11c], 0x10
mov dword [esp + 0x100], ebx
mov dword [esp + 0xfc], ebp
mov word [esp + 0xec], dx
jb 0x411c6b
mov eax, dword [esp + 0x108]
push eax
call fcn.0042bc90
add esp, 4
mov al, 1
mov ecx, dword [esp + 0xd4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xbc]
xor ecx, esp
call fcn.0042bc9b
add esp, 0xcc
ret 0x40