Function at 0x40b320
Capabilities:
Check if file exists
Print debug messages
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x45dae6
mov eax, dword fs:[0]
push eax
sub esp, 0x580
mov eax, dword [0x4754f4]
xor eax, esp
mov dword [esp + 0x57c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4754f4]
xor eax, esp
push eax
lea eax, [esp + 0x594]
mov dword fs:[0], eax
mov eax, dword [esp + 0x5a4]
mov dword [esp + 0x2c], eax
add eax, 4
push eax
lea ecx, [esp + 0x54]
call fcn.00402eb0
push str.GameInfoModifyIni.ini
push eax
lea eax, [esp + 0x20]
push eax
mov dword [esp + 0x5a8], 0
call fcn.00402300
add esp, 0xc
mov byte [esp + 0x59c], 2
mov eax, dword [esp + 0x50]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b3b9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
jne 0x40b3fa
mov dword [esp + 0x59c], 0xffffffff
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40b3f3
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor al, al
jmp 0x40ba8d
mov ebx, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov dword [esp + 0x1c], 1
mov edx, dword [esp + 0x1c]
push 0xa
push 0xa
lea ecx, [esp + 0x78]
xor eax, eax
push ecx
push edx
mov byte [esp + 0x80], 0
mov dword [esp + 0x81], eax
mov dword [esp + 0x85], eax
mov byte [esp + 0x89], al
call fcn.0042db1e
mov eax, dword [esp + 0x28]
add esp, 0x10
push eax
push 0x104
lea ecx, [esp + 0x84]
push ecx
push 0x465b3c
push str.name
lea edx, [esp + 0x84]
push edx
call ebx
mov eax, dword [esp + 0x18]
push eax
push 0xa
lea ecx, [esp + 0x28c]
push ecx
push 0x465b3c
push 0x468854
lea edx, [esp + 0x84]
push edx
call ebx
mov eax, dword [esp + 0x18]
push eax
push 0x104
lea ecx, [esp + 0x390]
push ecx
push 0x465b3c
push 0x468060
lea edx, [esp + 0x84]
push edx
call ebx
mov eax, dword [esp + 0x18]
push eax
push 0x104
lea ecx, [esp + 0x494]
push ecx
push 0x465b3c
push str.KeyName
lea edx, [esp + 0x84]
push edx
call ebx
lea eax, [esp + 0x7c]
lea ecx, [eax + 1]
lea esp, [esp]
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x40b4e0
sub eax, ecx
cmp eax, 1
jb 0x40ba60
lea eax, [esp + 0x48c]
push eax
lea ecx, [esp + 0x68]
call fcn.00402eb0
mov esi, eax
lea ecx, [esp + 0x388]
push ecx
lea ecx, [esp + 0x6c]
mov byte [esp + 0x5a0], 3
call fcn.00402eb0
mov edi, eax
lea edx, [esp + 0x284]
push edx
lea ecx, [esp + 0x2c]
mov byte [esp + 0x5a0], 4
call fcn.00402eb0
mov ebp, eax
lea eax, [esp + 0x7c]
push eax
lea ecx, [esp + 0x64]
mov byte [esp + 0x5a0], 5
call fcn.00402eb0
push 0x465b00
push eax
lea ecx, [esp + 0x50]
push ecx
mov byte [esp + 0x5a8], 6
call fcn.00402300
push ebp
push eax
lea edx, [esp + 0x6c]
push edx
mov byte [esp + 0x5b4], 7
call fcn.00402240
push 0x465b00
push eax
lea eax, [esp + 0x60]
push eax
mov byte [esp + 0x5c0], 8
call fcn.00402300
push edi
push eax
lea ecx, [esp + 0x80]
push ecx
mov byte [esp + 0x5cc], 9
call fcn.00402240
push 0x465b00
push eax
lea edx, [esp + 0x70]
push edx
mov byte [esp + 0x5d8], 0xa
call fcn.00402300
push esi
push eax
lea eax, [esp + 0xa0]
push eax
mov byte [esp + 0x5e4], 0xb
call fcn.00402240
add esp, 0x48
push 0x465a78
push eax
lea ecx, [esp + 0x38]
push ecx
mov byte [esp + 0x5a8], 0xc
call fcn.00402300
mov eax, dword [eax]
add esp, 0xc
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [esp + 0x30]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40b622
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 0xb
mov eax, dword [esp + 0x5c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b64a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 0xa
mov eax, dword [esp + 0x38]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b672
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 9
mov eax, dword [esp + 0x54]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b69a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 8
mov eax, dword [esp + 0x40]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b6c2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 7
mov eax, dword [esp + 0x58]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b6ea
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 6
mov eax, dword [esp + 0x48]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b712
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 5
mov eax, dword [esp + 0x60]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b73a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 4
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b762
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 3
mov eax, dword [esp + 0x68]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b78a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 2
mov eax, dword [esp + 0x64]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b7b2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push ecx
lea edx, [esp + 0x288]
mov ecx, esp
mov dword [esp + 0x70], esp
push edx
xor ebp, ebp
call fcn.00402eb0
mov edi, dword [esp + 0x30]
lea eax, [esp + 0x18]
push eax
mov ecx, edi
call fcn.0040cc50
mov byte [esp + 0x59c], 0xd
mov edx, dword [esp + 0x14]
mov eax, edx
lea esi, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x40b7f0
sub eax, esi
cmp eax, 2
jae 0x40b803
mov ebp, 1
cmp dword [edx - 4], 1
jle 0x40b81a
mov ecx, dword [edx - 0xc]
push ecx
lea ecx, [esp + 0x18]
call fcn.00402c00
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashA]
mov eax, dword [esp + 0x14]
mov ecx, dword [eax - 8]
push ecx
push eax
call fcn.0042e005
add esp, 8
test eax, eax
jl 0x40bab7
mov ecx, dword [esp + 0x14]
cmp eax, dword [ecx - 8]
jg 0x40bab7
mov dword [ecx - 0xc], eax
mov edx, dword [esp + 0x14]
mov byte [eax + edx], 0
lea eax, [esp + 0x388]
push eax
lea ecx, [esp + 0x38]
call fcn.00402eb0
push eax
lea ecx, [esp + 0x18]
push ecx
lea edx, [esp + 0x2c]
push edx
mov byte [esp + 0x5a8], 0xe
call fcn.00402240
add esp, 0xc
mov byte [esp + 0x59c], 0x10
mov eax, dword [esp + 0x34]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b8a6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push 0x103
lea ecx, [esp + 0x185]
push 0
push ecx
mov byte [esp + 0x18c], 0
call fcn.004314b0
mov edx, dword [esp + 0x24]
add esp, 0xc
push edx
push 0x104
lea eax, [esp + 0x188]
push eax
push 0x465b3c
push str.file
push str.config
call ebx
lea ecx, [esp + 0x180]
push ecx
lea ecx, [esp + 0x50]
call fcn.00402eb0
mov esi, eax
lea eax, [edi + 4]
push eax
lea ecx, [esp + 0x48]
mov byte [esp + 0x5a0], 0x11
call fcn.00402eb0
push 0x465af8
push eax
lea edx, [esp + 0x44]
push edx
mov byte [esp + 0x5a8], 0x12
call fcn.00402300
push esi
push eax
lea eax, [esp + 0x34]
push eax
mov byte [esp + 0x5b4], 0x13
call fcn.00402240
mov byte [esp + 0x5b4], 0x12
mov eax, dword [esp + 0x54]
add eax, 0xfffffff0
add esp, 0x18
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b967
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 0x11
mov eax, dword [esp + 0x44]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b98f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 0x10
mov eax, dword [esp + 0x4c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40b9b7
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp ebp, 1
je 0x40b9dc
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
push ecx
push edx
lea eax, [esp + 0x494]
push eax
lea ecx, [esp + 0x88]
push ecx
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40b9fc
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 0xd
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ba24
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x59c], 2
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40ba4c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x1c]
inc eax
cmp eax, 0x1388
mov dword [esp + 0x1c], eax
jl 0x40b408
mov dword [esp + 0x59c], 0xffffffff
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 0x40ba8b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov al, 1
mov ecx, dword [esp + 0x594]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x57c]
xor ecx, esp
call fcn.0042d298
add esp, 0x58c
ret 4
push 0x80070057
call fcn.00402d50
int3