Function at 0x40ade0
Capabilities:
Check if file exists
Create process on windows
Read .ini file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x52dddd
mov eax, dword fs:[0]
push eax
sub esp, 0x230
mov eax, dword [0x58e188]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor eax, eax
push 0x206
push eax
lea ecx, [ebp - 0x216]
push ecx
mov dword [ebp - 4], 2
mov word [ebp - 0x218], ax
call fcn.00515860
mov eax, dword [ebp + 8]
add esp, 8
add eax, 0xfffffff0
mov dword [ebp - 0x21c], esp
mov esi, esp
push eax
call fcn.00402000
lea edx, [ebp - 0x234]
add esp, 4
add eax, 0x10
push edx
mov dword [esi], eax
call fcn.00406240
mov eax, dword [ebp + 0xc]
add esp, 4
add eax, 0xfffffff0
mov dword [ebp - 0x21c], esp
mov esi, esp
push eax
mov byte [ebp - 4], 3
call fcn.00402000
add eax, 0x10
mov dword [esi], eax
lea eax, [ebp - 0x230]
add esp, 4
push eax
call fcn.00406240
mov eax, dword [ebp + 0x10]
add esp, 4
add eax, 0xfffffff0
mov dword [ebp - 0x21c], esp
mov esi, esp
push eax
mov byte [ebp - 4], 4
call fcn.00402000
lea ecx, [ebp - 0x23c]
add esp, 4
add eax, 0x10
push ecx
mov dword [esi], eax
call fcn.00406240
mov edx, dword [ebp - 0x230]
push edx
lea eax, [ebp - 0x218]
push 0x104
push eax
mov byte [ebp - 4], 5
call fcn.00515a14
add esp, 0x14
cmp word [ebp - 0x216], 0x3a
jne 0x40aef3
lea ecx, [ebp - 0x218]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
jmp 0x40afb5
cmp dword [0x58f9dc], 0
jne 0x40af1c
mov edx, dword [ebp - 0x234]
push edx
lea eax, [ebp - 0x218]
push 0x104
push eax
call fcn.00515a14
add esp, 0xc
jmp 0x40afb5
lea ecx, [ebp - 0x234]
push ecx
push ecx
mov ecx, esp
mov dword [ebp - 0x21c], esp
push str._GamePath_
call fcn.00402730
lea edx, [ebp - 0x21c]
push edx
call fcn.00406240
add esp, 8
push eax
lea eax, [ebp - 0x220]
push eax
mov byte [ebp - 4], 6
call fcn.00406dc0
mov eax, dword [eax]
push eax
lea ecx, [ebp - 0x218]
push 0x104
push ecx
call fcn.00515a14
mov eax, dword [ebp - 0x220]
add eax, 0xfffffff0
add esp, 0x18
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40af8f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x21c]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40afb5
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov esi, dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
lea ecx, [ebp - 0x218]
push ecx
call esi
test eax, eax
je 0x40aff1
mov eax, dword [ebp - 0x23c]
mov ecx, dword [ebp - 0x230]
push 1
lea edx, [ebp - 0x218]
push edx
push eax
push ecx
push 0x53ead0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
jmp 0x40b0b4
push 0x1024
push 0x53f48c
push 0x53f438
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
cmp eax, 1
jne 0x40b0b4
push 0x53f41c
lea ecx, [ebp - 0x220]
call fcn.00402730
lea edx, [ebp - 0x220]
push edx
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x21c]
push ecx
mov byte [ebp - 4], 7
call fcn.00406e80
mov eax, dword [eax]
add esp, 0xc
push eax
call esi
mov esi, eax
mov eax, dword [ebp - 0x21c]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40b06b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
test esi, esi
je 0x40b08e
mov edx, dword [ebp - 0x220]
push 5
lea ecx, [ebp - 0x218]
push ecx
push 0
push edx
push 0x53ead0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov eax, dword [ebp - 0x220]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b0b4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push str.none
lea ecx, [ebp - 0x224]
call fcn.00402730
lea ecx, [ebp - 0x224]
push ecx
push ecx
mov ecx, esp
mov dword [ebp - 0x228], esp
mov bl, 8
push str.State
mov byte [ebp - 4], bl
call fcn.00402730
mov eax, dword [0x58f980]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x22c], esp
mov esi, esp
push eax
mov byte [ebp - 4], 9
call fcn.00402000
add eax, 0x10
mov dword [esi], eax
add esp, 4
mov byte [ebp - 4], bl
call fcn.00407510
lea edx, [ebp - 0x224]
push 0x53e19c
push edx
call fcn.00402630
add esp, 0x14
test al, al
je 0x40b1b6
push ecx
lea eax, [ebp - 0x218]
mov ecx, esp
mov dword [ebp - 0x22c], esp
push eax
call fcn.00402730
push ecx
mov ecx, esp
mov dword [ebp - 0x228], esp
push str.Path
mov byte [ebp - 4], 0xa
call fcn.00402730
mov eax, dword [0x58f980]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x238], esp
mov esi, esp
push eax
mov byte [ebp - 4], 0xb
call fcn.00402000
add eax, 0x10
mov dword [esi], eax
add esp, 4
mov byte [ebp - 4], bl
call fcn.00405fa0
add esp, 8
mov ecx, esp
mov dword [ebp - 0x238], esp
push str.StartGame
call fcn.00402730
push ecx
mov ecx, esp
mov dword [ebp - 0x22c], esp
push str.State
mov byte [ebp - 4], 0xc
call fcn.00402730
mov byte [ebp - 4], 0xd
jmp 0x40b259
lea ecx, [ebp - 0x224]
push 0x53ea7c
push ecx
call fcn.00402630
add esp, 8
test al, al
je 0x40b283
push ecx
lea edx, [ebp - 0x218]
mov ecx, esp
mov dword [ebp - 0x238], esp
push edx
call fcn.00402730
push ecx
mov ecx, esp
mov dword [ebp - 0x22c], esp
push str.Path
mov byte [ebp - 4], 0xe
call fcn.00402730
mov eax, dword [0x58f980]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x228], esp
mov esi, esp
push eax
mov byte [ebp - 4], 0xf
call fcn.00402000
add eax, 0x10
mov dword [esi], eax
add esp, 4
mov byte [ebp - 4], bl
call fcn.00405fa0
add esp, 8
mov ecx, esp
mov dword [ebp - 0x238], esp
push 0x53f404
call fcn.00402730
push ecx
mov ecx, esp
mov dword [ebp - 0x22c], esp
push str.State
mov byte [ebp - 4], 0x10
call fcn.00402730
mov byte [ebp - 4], 0x11
mov eax, dword [0x58f980]
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x228], esp
mov esi, esp
push eax
call fcn.00402000
add eax, 0x10
mov dword [esi], eax
add esp, 4
mov byte [ebp - 4], bl
call fcn.00405fa0
add esp, 0xc
mov eax, dword [0x58f9b0]
push eax
push 0
push str.isAutoExit
push 0x53ebf4
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntW]
cmp eax, 1
jne 0x40b2ab
mov ecx, dword [0x58f97c]
call fcn.00401e70
mov eax, dword [ebp - 0x224]
add eax, 0xfffffff0
mov byte [ebp - 4], 5
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b2d1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x23c]
add eax, 0xfffffff0
mov byte [ebp - 4], 4
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b2f7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x230]
add eax, 0xfffffff0
mov byte [ebp - 4], 3
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b31d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp - 0x234]
add eax, 0xfffffff0
mov byte [ebp - 4], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b343
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
mov byte [ebp - 4], 1
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b366
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
mov byte [ebp - 4], 0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b389
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [ebp + 0x10]
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b3af
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00514c0e
mov esp, ebp
pop ebp
ret