Function at 0x404050
Capabilities:
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x624
mov eax, dword [0x424008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push 0x425750
push 0x425548
push 0x425414
lea eax, [ebp - 0x414]
push str._s_s_s
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x14
lea eax, [ebp - 0x414]
push str..ini
push eax
call dword [sym.imp.SHLWAPI.dll_PathRenameExtensionA]
mov ebx, dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
lea eax, [ebp - 0x310]
push 0
push 2
push eax
push 0
call ebx
test eax, eax
jns 0x4040eb
push 0
push 0x17
lea eax, [ebp - 0x310]
push eax
push 0
call ebx
test eax, eax
jns 0x4040eb
push 0x30
push 0x42564c
push 0x420ee0
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
push edi
lea edi, [ebp - 0x310]
dec edi
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4040f3
mov ax, word [0x420894]
mov edx, 0x425548
mov word [edi], ax
mov ecx, 0x425958
xor eax, eax
cmp byte [0x425958], al
push esi
setne al
test eax, eax
cmovne edx, ecx
mov esi, edx
mov al, byte [edx]
inc edx
test al, al
jne 0x404123
lea edi, [ebp - 0x310]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x404133
mov ecx, edx
lea eax, [ebp - 0x310]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push 0
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
mov ebx, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x310]
push eax
push str.brand
push str.Link
call ebx
lea edi, [ebp - 0x310]
dec edi
nop
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x404180
mov ax, word [0x420894]
mov edx, 0x42564c
mov word [edi], ax
mov esi, edx
nop word [eax + eax]
mov al, byte [edx]
inc edx
test al, al
jne 0x4041a0
lea edi, [ebp - 0x310]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4041b0
mov ecx, edx
lea eax, [ebp - 0x310]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push 0
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x310]
push eax
push str.game
push str.Link
call ebx
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x310]
push 0x42564c
push eax
lea eax, [ebp - 0x108]
push str._s_s.lnk
push eax
call esi
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [ebp - 0x108]
add esp, 0x10
push eax
call edi
push 0x425b60
push 0x425854
lea eax, [ebp - 0x20c]
push 0x42086c
push eax
call esi
push 0x4209af
push 0x425854
lea edx, [ebp - 0x108]
lea ecx, [ebp - 0x20c]
call fcn.00408370
add esp, 0x18
test eax, eax
jne 0x404281
push 0x30
push 0x42564c
push 0x420f48
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
pop esi
pop edi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x108]
push eax
push 0x420f7c
push str.Link
call ebx
cmp dword [0x42551c], 0
je 0x40436d
push 0
push 0x10
lea eax, [ebp - 0x108]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
lea edi, [ebp - 0x108]
dec edi
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4042c2
mov ax, word [0x420894]
mov edx, 0x42564c
mov word [edi], ax
mov esi, edx
nop dword [eax]
mov al, byte [edx]
inc edx
test al, al
jne 0x4042e0
lea edi, [ebp - 0x108]
sub edx, esi
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4042f0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebp - 0x108]
dec ecx
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x404310
mov eax, dword [0x420f80]
lea edx, [ebp - 0x108]
mov dword [ecx], eax
mov al, byte [0x420f84]
mov byte [ecx + 4], al
lea ecx, [ebp - 0x20c]
push 0x4209af
push 0x425854
call fcn.00408370
add esp, 8
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x108]
push eax
push str.desktop
push str.Link
call ebx
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x108]
push 0x420f90
push eax
call esi
push 0x425a5c
push 0x425854
lea eax, [ebp - 0x20c]
push 0x42086c
push eax
call esi
push 0x4209af
push 0x425854
lea edx, [ebp - 0x108]
lea ecx, [ebp - 0x20c]
call fcn.00408370
add esp, 0x24
test eax, eax
jne 0x4043e2
push 0x30
push 0x42564c
push 0x420fa4
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
pop esi
pop edi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x108]
push eax
push str.read_me
push str.Link
call ebx
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x108]
push 0x420fe0
push eax
call esi
push str.Setup.exe
push 0x425854
lea eax, [ebp - 0x20c]
push 0x42086c
push eax
call esi
push 0x4209b8
push 0x425854
lea edx, [ebp - 0x108]
lea ecx, [ebp - 0x20c]
call fcn.00408370
add esp, 0x24
test eax, eax
jne 0x404471
push 0x30
push 0x42564c
push 0x420ff8
push eax
call dword [sym.imp.USER32.dll_MessageBoxA]
pop esi
pop edi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x108]
push eax
push str.uninstall
push str.Link
call ebx
xor eax, eax
mov ebx, 0x425d68
mov dword [ebp - 0x624], eax
nop dword [eax + eax]
cmp byte [ebx], 0x2a
je 0x404643
push ebx
push 0x425854
lea eax, [ebp - 0x20c]
push 0x42086c
push eax
call esi
add esp, 0x10
lea edx, [ebp - 0x20c]
lea ecx, [ebp - 0x61c]
call fcn.00407d90
test eax, eax
jne 0x4044f5
push ebx
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameA]
push eax
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x108]
push 0x42086c
push eax
call esi
add esp, 0x10
lea eax, [ebp - 0x61c]
push eax
lea eax, [ebp - 0x310]
push eax
lea eax, [ebp - 0x108]
push 0x42086c
push eax
call esi
add esp, 0x10
lea eax, [ebp - 0x108]
push 0x420f80
push eax
call dword [sym.imp.SHLWAPI.dll_PathRenameExtensionA]
lea eax, [ebp - 0x108]
push eax
call edi
push ebx
push 0x425854
lea eax, [ebp - 0x20c]
push 0x42086c
push eax
call esi
add esp, 0x10
lea eax, [ebp - 0x20c]
push eax
call edi
push 0
mov edi, eax
lea eax, [ebp - 0x518]
push 0
push eax
lea eax, [ebp - 0x620]
push eax
lea eax, [ebp - 0x20c]
push eax
call fcn.0040eaea
add esp, 0x14
lea eax, [ebp - 0x620]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov esi, eax
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
add eax, esi
cmp eax, edi
jge 0x4045dc
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
dec eax
cmp eax, 0x104
jae 0x4046c8
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
mov byte [ebp + eax - 0x518], 0
lea eax, [ebp - 0x518]
push eax
lea eax, [ebp - 0x620]
push eax
lea eax, [ebp - 0x61c]
push str._s_s
push eax
call esi
add esp, 0x10
jmp 0x4045e2
mov esi, dword [sym.imp.USER32.dll_wsprintfA]
lea eax, [ebp - 0x61c]
push 0x4209af
push eax
lea edx, [ebp - 0x108]
lea ecx, [ebp - 0x20c]
call fcn.00408370
add esp, 8
test eax, eax
je 0x404663
push dword [ebp - 0x624]
lea eax, [ebp - 0x20c]
push str.exe_02d
push eax
call esi
add esp, 0xc
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x20c]
push eax
push str.Link
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
mov eax, dword [ebp - 0x624]
inc eax
add ebx, 0x104
mov dword [ebp - 0x624], eax
cmp ebx, 0x426588
jge 0x4046b2
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
jmp 0x4044a0
lea eax, [ebp - 0x61c]
push eax
lea eax, [ebp - 0x108]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x414]
push 0x42103c
push eax
call esi
add esp, 0x14
lea eax, [ebp - 0x414]
push 0x30
push 0x42564c
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxA]
pop esi
pop edi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
mov eax, 1
pop esi
pop edi
xor ecx, ebp
pop ebx
call fcn.0040a88f
mov esp, ebp
pop ebp
ret
call fcn.0040a9c1
int3