Function at 0x40406f
Capabilities:
Terminate process

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x40f1d6
push eax
mov dword fs:[0], esp
sub esp, 0xc7c
lea eax, [esp + 0x144]
push ebx
push ebp
push esi
push edi
push 0x104
push eax
call fcn.004070df
add esp, 8
call dword [sym.imp.COMCTL32.dll_InitCommonControls]
mov ebp, dword [esp + 0xca0]
mov ecx, dword [ebp]
push ecx
call fcn.004043d0
mov edi, dword [ebp]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x50]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push 0x2e
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x55]
lea esi, [esp + 0x54]
push ecx
call fcn.00406510
add esp, 0xc
test eax, eax
je 0x403f87
mov esi, eax
inc eax
push 0x2e
push eax
call fcn.00406510
add esp, 8
test eax, eax
jne 0x403f75
cmp byte [esi], 0x2e
jne 0x403f8f
mov byte [esi], 0
mov edi, str..lcf
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x4c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov ebx, ecx
mov edi, edx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x14]
call fcn.00401000
lea eax, [esp + 0x4c]
push 0x41318c
push eax
mov dword [esp + 0xc9c], 0
call fcn.00407424
mov esi, eax
add esp, 8
test esi, esi
jne 0x404002
push eax
push str.Launcher_config_file_missing
push str.You_must_run_the_game_from_its_install_directory.
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
push 0xffffffffffffffff
call fcn.0040700a
push esi
lea ecx, [esp + 0x18]
call fcn.004011f0
push esi
mov bl, al
call fcn.004073ae
add esp, 4
test bl, bl
jne 0x404036
push 0
push 0x413130
push str.File_launcher.cfg_is_corrupt
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
push 0xffffffffffffffff
call fcn.0040700a
lea ecx, [esp + 0x35c]
call fcn.004051b0
lea ecx, [esp + 0x35c]
push 0
lea edx, [esp + 0x18]
push ecx
push edx
call fcn.00405320
add esp, 0xc
lea ecx, [esp + 0x97c]
call fcn.004051b0
lea eax, [esp + 0x97c]
push str.RUN2
lea ecx, [esp + 0x18]
push eax
push ecx
call fcn.00405320
mov ebx, dword [esp + 0xca8]
add esp, 0xc
movsx edx, al
cmp ebx, 1
mov dword [esp + 0x10], edx
jle 0x404174
lea edx, [ebp + 4]
dec ebx
mov edi, 0x41309c
or ecx, 0xffffffff
xor eax, eax
lea ebp, [esp + 0x55c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, ebp
mov ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
lea ebp, [esp + 0x55c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [edx]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, ebp
mov ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov eax, dword [esp + 0x10]
mov ecx, ebp
and ecx, 3
test eax, eax
rep movsb byte es:[edi], byte [esi]
je 0x40415c
mov edi, 0x41309c
or ecx, 0xffffffff
xor eax, eax
lea ebp, [esp + 0xb7c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, ebp
mov ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
lea ebp, [esp + 0xb7c]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, dword [edx]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, ebp
mov ebp, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, ebp
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, ebp
and ecx, 3
rep movsb byte es:[edi], byte [esi]
add edx, 4
dec ebx
jne 0x40409a
mov ebx, dword [esp + 0xc9c]
mov ebp, dword [esp + 0xca0]
cmp ebx, 2
jl 0x4042bb
mov eax, dword [ebp + 4]
mov esi, str.GrabPatches
mov dl, byte [eax]
mov bl, byte [esi]
mov cl, dl
cmp dl, bl
jne 0x4041ad
test cl, cl
je 0x4041a9
mov dl, byte [eax + 1]
mov bl, byte [esi + 1]
mov cl, dl
cmp dl, bl
jne 0x4041ad
add eax, 2
add esi, 2
test cl, cl
jne 0x404185
xor eax, eax
jmp 0x4041b2
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x4042bb
lea ecx, [esp + 0x66c]
call fcn.004051b0
lea edi, [esp + 0x35c]
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x66c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x76c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, str.patchgetmd.dat
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x86c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edi, 0x414240
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x66c]
push ecx
call fcn.004051d0
lea edx, [esp + 0x670]
push 0
push edx
call fcn.004052e0
lea eax, [esp + 0x20]
lea ecx, [esp + 0x264]
push eax
push 0x104
push ecx
call fcn.00403420
add esp, 0x18
test eax, eax
je 0x4042ae
push eax
lea edx, [esp + 0x18]
lea eax, [esp + 0x25c]
push edx
push eax
call fcn.00404670
lea ecx, [esp + 0x20]
lea edx, [esp + 0x264]
push ecx
push 0x104
push edx
call fcn.00403420
add esp, 0x18
test eax, eax
jne 0x40427d
lea eax, [esp + 0x154]
push eax
jmp 0x404393
mov eax, dword [esp + 0x10]
test eax, eax
je 0x404372
lea ecx, [esp + 0x10]
call fcn.00401ca0
lea ecx, [esp + 0x10]
mov byte [esp + 0xc94], 1
push ecx
push str.FLAG
lea ecx, [esp + 0x1c]
call fcn.00401550
test al, al
je 0x404307
lea ecx, [esp + 0x10]
call fcn.00401f90
push eax
call fcn.004066ae
mov esi, eax
add esp, 4
test esi, esi
jne 0x404322
push 0
push 0x413130
push str.File_launcher.cfg_is_corrupt
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
push 0xffffffffffffffff
call fcn.0040700a
push 0
call fcn.004072d2
add esp, 4
cmp eax, esi
jle 0x40434b
mov ecx, dword [ebp]
lea edx, [esp + 0x35c]
lea eax, [esp + 0x14]
push edx
push eax
push ecx
call fcn.00403d40
add esp, 0xc
jmp 0x40435f
mov eax, dword [ebp]
lea edx, [esp + 0x97c]
push edx
push eax
call fcn.00403ed0
add esp, 8
lea ecx, [esp + 0x10]
mov byte [esp + 0xc94], 0
call fcn.00401cd0
jmp 0x40438b
mov eax, dword [ebp]
lea ecx, [esp + 0x35c]
lea edx, [esp + 0x14]
push ecx
push edx
push eax
call fcn.00403d40
add esp, 0xc
lea ecx, [esp + 0x154]
push ecx
call fcn.004043d0
add esp, 4
lea ecx, [esp + 0x14]
mov dword [esp + 0xc94], 0xffffffff
call fcn.00401090
mov ecx, dword [esp + 0xc8c]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
mov dword fs:[0], ecx
add esp, 0xc88
ret