Function at 0x403220
Capabilities:
Check if file exists
Create directory

Disassembly:
mov eax, 0x420abe
call main
sub esp, 0x57c
push ebx
push esi
push edi
mov ebx, ecx
push 0x54
call sub.MFC42.DLL_operatornew
pop ecx
mov dword [ebp - 0x14], eax
xor edi, edi
cmp eax, edi
mov dword [ebp - 4], edi
je 0x403252
mov ecx, eax
call fcn.00407680
jmp 0x403254
xor eax, eax
or dword [ebp - 4], 0xffffffff
push 0x38
mov dword [ebx + 0x154], eax
call sub.MFC42.DLL_operatornew
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, edi
mov dword [ebp - 4], 1
je 0x40327f
mov ecx, eax
call fcn.0040a38d
mov esi, eax
jmp 0x403281
xor esi, esi
or dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x18]
push eax
lea ecx, [ebx + 0x16c]
call fcn.00404e33
push dword [eax]
mov ecx, esi
mov dword [ebp - 4], 2
call fcn.0040a43d
neg al
sbb al, al
or dword [ebp - 4], 0xffffffff
inc al
lea ecx, [ebp - 0x18]
mov byte [ebp - 0x1d], al
call sub.MFC42.DLL_CString::CString
cmp byte [ebp - 0x1d], 0
je 0x4032d0
push edi
push edi
push 0x42c220
call sub.MFC42.DLL_AfxMessageBox
jmp 0x403702
push 8
mov dword [ebx + 0x158], esi
call sub.MFC42.DLL_operatornew
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, edi
mov dword [ebp - 4], 3
je 0x4032fc
lea ecx, [ebx + 0x104]
push ecx
mov ecx, eax
call fcn.00404b51
jmp 0x4032fe
xor eax, eax
or dword [ebp - 4], 0xffffffff
mov dword [ebx + 0x164], eax
mov eax, dword [esi + 0x34]
cmp dword [eax + 0x38], 1
jbe 0x40339d
push edi
lea ecx, [ebp - 0x588]
call fcn.00401e90
mov esi, dword [esi + 0x34]
lea ecx, [ebp - 0x58]
add esi, 0x14
mov dword [ebp - 4], 4
push esi
call fcn.00417b3a
lea ecx, [ebp - 0x588]
call sub.MFC42.DLL_CDialog::DoModal
cmp eax, 2
jne 0x40335b
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x588]
call fcn.00401f27
jmp 0x403702
mov eax, dword [ebx + 0xcc]
mov ecx, dword [ebx + 0x158]
push dword [eax]
call fcn.0040a60a
test al, al
jne 0x403380
push edi
push edi
push 0x42c220
call sub.MFC42.DLL_AfxMessageBox
jmp 0x403347
push 1
push edi
lea ecx, [ebx + 0xc8]
call sub.MFC42.DLL_CStringArray::RemoveAt
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x588]
call fcn.00401f27
mov eax, dword [ebx + 0x158]
lea ecx, [ebp - 0x34]
mov eax, dword [eax + 0x34]
add eax, 0x20
push eax
call fcn.00417b2e
push 0x42c150
push str..exe
lea ecx, [ebp - 0x34]
mov dword [ebp - 4], 5
call sub.MFC42.DLL_CString::Replace
mov esi, str._GLDIR_
lea eax, [ebp - 0x3c]
push esi
push eax
mov ecx, 0x42faf0
call fcn.00408867
lea eax, [ebp - 0x3c]
push 0x42c210
push eax
lea eax, [ebp - 0x44]
push eax
mov byte [ebp - 4], 6
call sub.MFC42.DLL_operator
lea ecx, [ebp - 0x34]
mov byte [ebp - 4], 7
push ecx
push eax
lea eax, [ebp - 0x38]
push eax
call sub.MFC42.DLL_operator_1
lea ecx, [ebp - 0x44]
mov byte [ebp - 4], 9
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x10]
mov dword [ebp - 0x2c], edi
mov dword [ebp - 0x40], edi
call sub.MFC42.DLL_CString::CString_2
push dword [ebp - 0x38]
mov byte [ebp - 4], 0xa
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x40365b
mov dword [ebp - 0x30], edi
push 7
push edi
push 0x42c200
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 0xb
call fcn.00404be7
cmp eax, edi
jl 0x403641
push dword [ebp - 0x38]
lea ecx, [ebp - 0x1c]
call fcn.0040393c
push eax
lea ecx, [ebp - 0x54]
mov byte [ebp - 4], 0xc
call fcn.00403a23
mov eax, dword [ebp - 0x30]
mov byte [ebp - 4], 0xd
cmp eax, edi
jne 0x403485
push 0x80004003
call fcn.00417ff8
mov eax, dword [ebp - 0x30]
lea edx, [ebp - 0x1e]
lea esi, [ebp - 0x54]
push edx
mov ecx, dword [eax]
sub esp, 0x10
mov dword [ebp - 0x18], eax
mov edi, esp
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
push eax
movsd dword es:[edi], dword [esi]
call dword [ecx + 0xe8]
test eax, eax
jge 0x4034b3
push 0x42c1f0
push dword [ebp - 0x18]
push eax
call fcn.00418006
lea eax, [ebp - 0x54]
mov byte [ebp - 4], 0xc
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
test eax, eax
jge 0x4034cb
push eax
call fcn.00417ff8
mov ecx, dword [ebp - 0x1c]
mov byte [ebp - 4], 0xb
test ecx, ecx
je 0x4034db
call fcn.004039d6
cmp word [ebp - 0x1e], 0xffff
jne 0x40363f
push ecx
mov ecx, esp
mov dword [ebp - 0x14], esp
push str._Glsetup2_Directorys_Directory
call fcn.0040393c
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x30]
push eax
mov byte [ebp - 4], 0xb
call fcn.00404bd1
mov ecx, eax
call fcn.00403a75
push str.Name
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0xf
call fcn.00404bd1
mov ecx, eax
call fcn.00403b11
push ecx
dec eax
mov ecx, esp
mov dword [ebp - 0x14], esp
push eax
push ecx
lea ecx, [ebp - 0x1c]
call fcn.00404bd1
mov ecx, eax
call fcn.00403adc
lea eax, [ebp - 0x18]
push eax
call fcn.00409725
add esp, 0xc
push eax
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 0x10
call fcn.00417b3a
lea ecx, [ebp - 0x18]
mov byte [ebp - 4], 0xf
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebx + 0x158]
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x18], 1
mov eax, dword [eax + 0x34]
mov esi, dword [eax + 0x30]
add eax, 0x28
push eax
mov dword [ebp - 0x40], esi
call fcn.00417b2e
push 0x42f9e0
mov byte [ebp - 4], 0x11
push dword [ebp - 0x28]
call dword [sym.imp.MSVCRT.dll__mbscmp]
pop ecx
test eax, eax
pop ecx
je 0x403622
test esi, esi
je 0x403622
lea eax, [ebp - 0x10]
lea ecx, [ebp - 0x24]
push eax
call fcn.00417b2e
lea eax, [ebp - 0x28]
lea ecx, [ebp - 0x20]
push eax
mov byte [ebp - 4], 0x12
call fcn.00417b2e
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0x13
call sub.MFC42.DLL_CString::MakeLower
lea ecx, [ebp - 0x20]
call sub.MFC42.DLL_CString::MakeLower
push dword [ebp - 0x20]
lea ecx, [ebp - 0x24]
call sub.MFC42.DLL_CString::Find_1
cmp eax, 0xffffffff
je 0x40360a
push eax
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::Left
push eax
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 0x14
call fcn.00417b3a
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0x13
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x20]
mov byte [ebp - 4], 0x12
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0x11
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0xf
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp - 0x1c]
mov byte [ebp - 4], 0xb
test eax, eax
je 0x40363f
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
xor edi, edi
mov eax, dword [ebp - 0x30]
mov byte [ebp - 4], 0xa
cmp eax, edi
je 0x403741
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
jmp 0x403741
mov eax, dword [ebx + 0x158]
mov dword [ebp - 0x40], edi
mov eax, dword [eax + 0x34]
mov ecx, dword [eax + 0x2c]
add eax, 0x24
mov dword [ebp - 0x2c], ecx
push eax
lea ecx, [ebp - 0x10]
call fcn.00417b3a
cmp dword [ebp - 0x2c], edi
je 0x4036a8
push dword [ebp - 0x10]
lea eax, [ebp - 0x14]
mov ecx, 0x42faf0
push eax
call fcn.00408867
push eax
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 0x15
call fcn.00417b3a
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x14]
jmp 0x403739
lea eax, [ebp - 0x18]
push eax
push 0x20019
push edi
push str.SoftwareGloballinkGameShare
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
cmp eax, edi
je 0x403709
push edi
push edi
push 0x42c184
call sub.MFC42.DLL_AfxMessageBox
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 9
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x38]
mov byte [ebp - 4], 6
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 5
call sub.MFC42.DLL_CString::CString
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x34]
call sub.MFC42.DLL_CString::CString
xor al, al
jmp 0x4038a2
lea eax, [ebp - 0x14]
push esi
push eax
mov ecx, 0x42faf0
call fcn.00408867
push dword [ebp - 0x10]
mov byte [ebp - 4], 0x16
push dword [eax]
lea eax, [ebp - 0x10]
push str._sGame_s
push eax
call sub.MFC42.DLL_CString::Format
add esp, 0x10
mov byte [ebp - 4], 0xa
lea ecx, [ebp - 0x14]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 0x18], edi
cmp dword [ebx + 0x194], edi
je 0x4038b1
push 0x1710
call sub.MFC42.DLL_operatornew
pop ecx
mov dword [ebp - 0x14], eax
cmp eax, edi
mov byte [ebp - 4], 0x17
je 0x40376d
push edi
mov ecx, eax
call fcn.00405162
jmp 0x40376f
xor eax, eax
mov dword [ebx + 0x15c], eax
mov dword [ebx + 0x20], eax
mov eax, dword [ebx + 0x158]
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0xa
mov eax, dword [eax + 0x34]
add eax, 0x18
push eax
call fcn.00417b2e
mov eax, dword [ebx + 0x158]
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0x18
mov eax, dword [eax + 0x34]
add eax, 0x1c
push eax
call fcn.00417b2e
mov eax, dword [ebx + 0x158]
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0x19
mov eax, dword [eax + 0x34]
add eax, 0x28
push eax
call fcn.00417b2e
mov eax, dword [ebx + 0x158]
mov byte [ebp - 4], 0x1a
mov ecx, dword [eax + 0x34]
lea eax, [ebp - 0x14]
push eax
call fcn.00408d45
mov ecx, dword [ebx + 0x15c]
push eax
add ecx, 0x6d4
mov byte [ebp - 4], 0x1b
call fcn.00417b3a
lea ecx, [ebp - 0x14]
mov byte [ebp - 4], 0x1a
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebx + 0x158]
mov ecx, dword [eax + 0x34]
mov eax, dword [ebx + 0x15c]
add eax, 0x64
push eax
call fcn.00408e64
mov ecx, dword [ebx + 0x15c]
mov dword [ecx + 0x60], eax
push dword [ebp - 0x1c]
mov eax, ebx
lea ecx, [ebx + 0xc4]
push dword [ebp - 0x40]
neg eax
push dword [ebp - 0x2c]
sbb eax, eax
push dword [ebp - 0x18]
and eax, ecx
mov ecx, dword [ebx + 0x15c]
push dword [ebp - 0x10]
push edi
push dword [ebp - 0x28]
push dword [ebp - 0x24]
push eax
call fcn.00405ebe
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 0x19
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x28]
mov byte [ebp - 4], 0x18
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x24]
mov byte [ebp - 4], 0xa
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x10]
mov byte [ebp - 4], 9
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x38]
mov byte [ebp - 4], 6
call sub.MFC42.DLL_CString::CString
lea ecx, [ebp - 0x3c]
mov byte [ebp - 4], 5
call sub.MFC42.DLL_CString::CString
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x34]
call sub.MFC42.DLL_CString::CString
mov al, 1
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret
push dword [ebp - 0x10]
mov ecx, 0x42faf0
call fcn.004088f4
push dword [ebp - 0x10]
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryA]
test eax, eax
jne 0x403870
mov eax, dword [ebp - 0x10]
push edi
mov eax, dword [eax - 8]
mov dword [ebp - 0x18], eax
push 0x5c
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::Find
mov esi, eax
cmp esi, edi
jl 0x403870
lea eax, [ebp - 0x14]
push esi
push eax
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::Left
push dword [eax]
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryA]
mov ebx, eax
lea ecx, [ebp - 0x14]
neg ebx
sbb bl, bl
inc bl
call sub.MFC42.DLL_CString::CString
test bl, bl
je 0x40392d
lea eax, [ebp - 0x2c]
push esi
push eax
lea ecx, [ebp - 0x10]
call sub.MFC42.DLL_CString::Left
mov eax, dword [eax]
push edi
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea ecx, [ebp - 0x2c]
call sub.MFC42.DLL_CString::CString
lea eax, [esi + 1]
cmp eax, dword [ebp - 0x18]
jge 0x403870
push eax
jmp 0x4038d5