Function at 0x4107d0
Capabilities:
Create directory
Delete registry value
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x434
mov eax, dword [0x5023a4]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, dword [0x506568]
push esi
push edi
test ebx, ebx
jne 0x410815
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
mov ebx, dword [0x506568]
push 0x1e6
lea eax, [ebp - 0x3f6]
push 0
push eax
call fcn.0049b560
mov ax, word [0x4dc100]
add esp, 0xc
movups xmm0, xmmword [0x4dc0e0]
mov word [ebp - 0x3f8], ax
lea eax, [ebp - 0x428]
push eax
push 1
push 0
movups xmmword [ebp - 0x418], xmm0
lea eax, [ebp - 0x418]
movups xmm0, xmmword [0x4dc0f0]
push eax
push SysReAllocString
movups xmmword [ebp - 0x408], xmm0
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test eax, eax
jne 0x410895
push dword [ebp - 0x428]
call esi
push str.GamePlusPlus
call fcn.00404670
test eax, eax
jne 0x410895
xor ecx, ecx
jmp 0x4108b4
push ecx
push str.GamePlusPlus
lea eax, [ebx + 0xc34]
push eax
push 1
lea ecx, [ebp - 0x419]
call fcn.004042d0
mov ecx, 1
call fcn.00418790
push 0x4dc0bc
call fcn.00404670
test eax, eax
je 0x410927
push 0x4dc0bc
call fcn.00405d30
sub esp, 0xc
mov dword [ebp - 0x434], 0
lea ecx, [ebp - 0x434]
mov dword [ebp - 0x430], 0
mov dword [ebp - 0x42c], 0
call fcn.00404210
test eax, eax
jne 0x41091a
mov edi, dword [ebp - 0x434]
push 0x4dc0bc
push edi
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
test edi, edi
je 0x410927
push edi
jmp 0x410925
mov eax, dword [ebp - 0x434]
test eax, eax
je 0x410927
push eax
call esi
push 0x4da2d8
call fcn.00404670
test eax, eax
je 0x410995
push 0x4da2d8
call fcn.00405d30
sub esp, 0xc
mov dword [ebp - 0x434], 0
lea ecx, [ebp - 0x434]
mov dword [ebp - 0x430], 0
mov dword [ebp - 0x42c], 0
call fcn.00404210
test eax, eax
jne 0x410988
mov edi, dword [ebp - 0x434]
push 0x4da2d8
push edi
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
test edi, edi
je 0x410995
push edi
jmp 0x410993
mov eax, dword [ebp - 0x434]
test eax, eax
je 0x410995
push eax
call esi
mov ecx, dword [0x506568]
test ecx, ecx
jne 0x4109c4
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
mov ecx, dword [0x506568]
cmp dword [ecx + 0x1ec4], 0
mov edx, 0x4da2d8
mov eax, 0x4da3b0
lea ecx, [ebp - 0x420]
cmove eax, edx
push eax
call fcn.00403470
lea ecx, [ebx + 0x414]
lea esi, [ebx + 0xe3c]
movzx eax, word [ecx]
lea ecx, [ecx + 2]
mov word [ecx + 0xa26], ax
test ax, ax
jne 0x4109f0
push 0x4da000
push 0x104
push esi
call fcn.004a468c
add esp, 0xc
push 0x4dc170
push 0x104
push esi
call fcn.004a468c
add esp, 0xc
lea eax, [ebp - 0x210]
push 0x208
push 0
push eax
call fcn.0049b560
add esp, 0xc
mov dword [ebp - 0x424], 0
lea eax, [ebp - 0x424]
push eax
push 0x17
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
jne 0x410b3c
lea eax, [ebp - 0x210]
push eax
push dword [ebp - 0x424]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
push dword [ebp - 0x424]
mov esi, eax
call dword [sym.imp.ole32.dll_CoTaskMemFree]
test esi, esi
je 0x410b3c
lea edi, [ebp - 0x210]
add edi, 0xfffffffe
mov ax, word [edi + 2]
lea edi, [edi + 2]
test ax, ax
jne 0x410a93
mov eax, dword [0x4da000]
mov dword [edi], eax
mov eax, dword [ebp - 0x420]
cmp dword [eax - 4], 1
jle 0x410ac6
push dword [eax - 0xc]
lea ecx, [ebp - 0x420]
call fcn.00403890
mov eax, dword [ebp - 0x420]
mov edx, eax
mov esi, eax
nop word [eax + eax]
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x410ad0
lea edi, [ebp - 0x210]
sub edx, esi
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x410ae6
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]
mov esi, dword [ebp - 0x420]
push dword [esi - 8]
push esi
call fcn.004a38d8
add esp, 8
test eax, eax
js 0x410d4e
cmp eax, dword [esi - 8]
jg 0x410d4e
xor ecx, ecx
mov dword [esi - 0xc], eax
mov word [esi + eax*2], cx
lea eax, [ebp - 0x210]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
jmp 0x410b42
mov esi, dword [ebp - 0x420]
mov edi, dword [0x506568]
test edi, edi
jne 0x410b94
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
mov edi, dword [0x506568]
test edi, edi
jne 0x410b94
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
push 1
lea eax, [ebp - 0x210]
push eax
push dword [edi + 0x1ec4]
lea eax, [ebp - 0x424]
push eax
call fcn.00413040
call fcn.004031c0
mov ecx, eax
test ecx, ecx
je 0x410d58
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
mov eax, dword [0x506568]
test eax, eax
jne 0x410bf9
push 0x20d0
call fcn.0049786c
add esp, 4
mov ecx, eax
call fcn.00414c70
mov ecx, eax
mov dword [0x506568], eax
mov edx, dword [eax]
call dword [edx]
mov eax, dword [0x506568]
add eax, 0x414
push eax
lea eax, [ebp - 0x428]
push str._s_resdesk.ico
push eax
call fcn.004040c0
add esp, 0xc
cmp dword [esi - 4], 1
jle 0x410c2d
push dword [esi - 0xc]
lea ecx, [ebp - 0x420]
call fcn.00403890
mov esi, dword [ebp - 0x420]
mov edi, dword [ebp - 0x424]
cmp dword [edi - 4], 1
jle 0x410c4d
push dword [edi - 0xc]
lea ecx, [ebp - 0x424]
call fcn.00403890
mov edi, dword [ebp - 0x424]
push 0x4d9ea8
push ecx
push esi
sub esp, 8
lea eax, [ebp - 0x210]
push edi
push eax
lea eax, [ebx + 0xc34]
push eax
push dword [ebp - 0x428]
call fcn.00411d10
push dword [edi - 8]
push edi
call fcn.004a38d8
add esp, 8
test eax, eax
js 0x410d4e
cmp eax, dword [edi - 8]
jg 0x410d4e
mov dword [edi - 0xc], eax
xor ecx, ecx
mov word [edi + eax*2], cx
push dword [esi - 8]
push esi
call fcn.004a38d8
add esp, 8
test eax, eax
js 0x410d4e
cmp eax, dword [esi - 8]
jg 0x410d4e
xor ecx, ecx
mov dword [esi - 0xc], eax
mov word [esi + eax*2], cx
lea eax, [ebx + 0xe3c]
push eax
push ecx
mov ecx, ebx
call fcn.00411960
call fcn.00408bd0
mov ecx, eax
call fcn.00406dc0
test eax, eax
jne 0x410cf1
push ecx
lea eax, [ebx + 0x824]
push eax
lea eax, [ebx + 0x414]
push eax
push ecx
call fcn.00411c60
mov edx, dword [ebp - 0x428]
or ebx, 0xffffffff
add edx, 0xfffffff0
mov eax, ebx
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x410d11
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add edi, 0xfffffff0
mov eax, ebx
lock xadd dword [edi + 0xc], eax
dec eax
test eax, eax
jg 0x410d28
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 0xfffffff0
lock xadd dword [esi + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x410d3d
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0049765c
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00402f10
push 0x80004005
call fcn.00402f10
int3