Function at 0x408810
Capabilities:
Check if process is running under wine
Get common file path
Get number of processors
Get process heap flags
Hide graphical window
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
push eax
mov eax, 0x1470
call fcn.0040b4a8
sub esp, eax
mov eax, dword [esp + eax]
mov dword [ebp - 0x142c], edx
mov dword [ebp - 0x1438], eax
mov eax, dword [0x41602c]
mov dword [ebp - 0x1430], eax
test eax, eax
je 0x408850
mov eax, 1
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
lea eax, [ebp - 0xe18]
mov dword [esp + 0xc], 1
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.SoftwareWineWineFile
mov dword [esp], 0x80000001
call dword [sym.imp.advapi32.dll_RegOpenKeyExW]
lea eax, [ebp - 0x1218]
mov dword [ebp - 0x1218], 4
mov ebx, dword [sym.imp.advapi32.dll_RegQueryValueExW]
sub esp, 0x14
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc10]
mov dword [ebp - 0x1434], eax
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1018]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.startX
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call ebx
sub esp, 0x18
test eax, eax
je 0x4088e2
mov dword [ebp - 0xc10], 0x80000000
mov dword [ebp - 0x1218], 4
lea eax, [ebp - 0x1218]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc0c]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1018]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.startY
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call ebx
sub esp, 0x18
test eax, eax
je 0x408936
mov dword [ebp - 0xc0c], 0x80000000
mov dword [ebp - 0x1218], 4
lea eax, [ebp - 0x1218]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc08]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1018]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.width
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call ebx
sub esp, 0x18
test eax, eax
je 0x40898a
mov dword [ebp - 0xc08], 0x80000000
mov dword [ebp - 0x1218], 4
lea eax, [ebp - 0x1218]
mov dword [esp + 0x14], eax
lea eax, [ebp - 0xc04]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1018]
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.height
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call ebx
sub esp, 0x18
test eax, eax
je 0x4089de
mov dword [ebp - 0xc04], 0x80000000
mov dword [ebp - 0x1218], 0x5c
lea eax, [ebp - 0x1218]
mov dword [esp + 0x14], eax
lea edi, [ebp - 0x80c]
lea eax, [ebp - 0x1018]
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], eax
mov dword [esp + 8], 0
mov dword [esp + 4], str.logfont
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call ebx
sub esp, 0x18
test eax, eax
jne 0x409078
mov eax, dword [ebp - 0xe18]
mov dword [esp], eax
call dword [sym.imp.advapi32.dll_RegCloseKey]
sub esp, 4
mov dword [esp], edi
call dword [sym.imp.gdi32.dll_CreateFontIndirectW]
mov ecx, dword [ebp - 0xc0c]
mov edx, dword [ebp - 0xc08]
mov dword [0x416054], eax
sub esp, 4
mov eax, dword [ebp - 0xc10]
mov dword [ebp - 0x1440], ecx
mov ecx, dword [ebp - 0xc04]
mov dword [ebp - 0x144c], edx
mov dword [ebp - 0x1444], eax
mov dword [ebp - 0x1448], ecx
mov dword [esp + 4], 0x66
mov eax, dword [0x416020]
mov dword [esp], eax
call dword [sym.imp.user32.dll_LoadMenuW]
sub esp, 8
mov ebx, eax
mov dword [esp], eax
call dword [sym.imp.user32.dll_GetMenuItemCount]
mov esi, dword [sym.imp.user32.dll_GetSubMenu]
sub esp, 4
sub eax, 2
mov dword [esp], ebx
mov dword [esp + 4], eax
call esi
mov dword [0x416030], ebx
sub esp, 8
mov dword [ebp - 0x143c], eax
mov dword [esp], ebx
mov dword [esp + 4], 2
call esi
sub esp, 8
mov dword [0x41603c], eax
mov dword [esp], ebx
mov dword [esp + 4], 3
call esi
mov esi, dword [ebp - 0x143c]
mov dword [ebp - 0x1424], 0xc000
mov ebx, dword [0x416020]
sub esp, 8
mov dword [0x416040], eax
mov dword [ebp - 0x1428], esi
mov esi, dword [0x416030]
mov dword [esp + 8], edi
mov dword [esp], ebx
mov dword [esp + 0xc], 0x400
mov dword [esp + 4], 0x4b0
call dword [sym.imp.user32.dll_LoadStringW]
sub esp, 0x10
mov dword [esp + 0x28], ebx
mov ebx, dword [sym.imp.user32.dll_CreateWindowExW]
mov dword [esp + 0x24], esi
mov esi, section..data
mov dword [esp + 0x2c], 0
mov dword [esp + 0x20], 0
mov ecx, dword [ebp - 0x1448]
mov dword [esp + 0x1c], ecx
mov edx, dword [ebp - 0x144c]
mov dword [esp + 0x18], edx
mov ecx, dword [ebp - 0x1440]
mov dword [esp + 0x14], ecx
mov eax, dword [ebp - 0x1444]
mov dword [esp + 8], edi
mov dword [esp + 0xc], 0xcf0000
mov dword [esp + 0x10], eax
movzx eax, word [0x416028]
mov dword [esp], 0
mov dword [esp + 4], eax
call ebx
lea edx, [ebp - 0x1428]
sub esp, 0x30
mov dword [0x41602c], eax
mov dword [esp + 0x2c], edx
mov edx, dword [0x416020]
mov dword [esp + 0x24], 0
mov dword [esp + 0x20], eax
mov dword [esp + 0x1c], 0
mov dword [esp + 0x28], edx
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], 0x52b00000
mov dword [esp + 8], 0
mov dword [esp + 4], str.MDICLIENT
mov dword [esp], 0
call ebx
mov ebx, dword [sym.imp.user32.dll_CheckMenuItem]
sub esp, 0x30
mov dword [0x416044], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1fb
mov eax, dword [0x416040]
mov dword [esp], eax
call ebx
sub esp, 0xc
mov dword [esp + 8], 0
mov dword [esp + 4], 0x1ff
mov eax, dword [0x416040]
mov dword [esp], eax
call ebx
sub esp, 0xc
call fcn.00402090
lea eax, [ebp - 0xc10]
mov edi, dword [ebp - 0x1434]
mov ecx, 0x19
rep movsd dword es:[edi], dword [esi]
mov dword [esp + 0x30], 0x14
mov dword [esp + 0x2c], 0xf
mov dword [esp + 0x28], 0x10
mov dword [esp + 0x24], 0xf
mov dword [esp + 0x20], 0x10
mov dword [esp + 0x1c], 5
mov dword [ebp - 0x1434], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], 0x64
mov eax, dword [0x416020]
mov dword [esp + 0xc], 2
mov dword [esp + 8], 0x101
mov dword [esp + 4], 0x50000000
mov dword [esp + 0x10], eax
mov eax, dword [0x41602c]
mov dword [esp], eax
call sub.comctl32.dll_CreateToolbarEx
sub esp, 0x34
mov dword [0x41604c], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1fc
mov eax, dword [0x416040]
mov dword [esp], eax
call ebx
sub esp, 0xc
mov dword [esp + 0xc], 0x100
mov eax, dword [0x41602c]
mov dword [esp + 4], 0
mov dword [esp], 0x50000000
mov dword [esp + 8], eax
call dword [sym.imp.comctl32.dll_CreateStatusWindowW]
sub esp, 0x10
mov dword [0x416048], eax
mov dword [esp + 8], 8
mov dword [esp + 4], 0x1f7
mov eax, dword [0x416040]
mov dword [esp], eax
call ebx
mov eax, dword [ebp - 0x142c]
sub esp, 0xc
test eax, eax
je 0x409048
cmp word [eax], 0
je 0x409048
mov eax, dword [ebp - 0x1438]
lea edi, [ebp - 0x1018]
mov dword [esp + 4], eax
mov eax, dword [0x41602c]
mov dword [esp], eax
call dword [sym.imp.user32.dll_ShowWindow]
mov eax, dword [0x416870]
sub esp, 8
mov ebx, dword [0x41602c]
mov edx, dword [eax]
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], edi
mov edi, dword [ebp - 0x1434]
mov dword [esp + 0x10], edi
mov edi, dword [ebp - 0x142c]
mov dword [esp + 8], 0
mov dword [esp + 4], ebx
mov dword [esp], eax
mov dword [esp + 0xc], edi
call dword [edx + 0xc]
sub esp, 0x1c
test eax, eax
js 0x408dd2
mov eax, dword [ebp - 0x1018]
mov dword [ebp - 0x1430], eax
mov edx, dword [ebp - 0x1430]
mov ecx, ebx
mov eax, dword [ebp - 0x142c]
call fcn.00407160
movdqa xmm0, xmmword [0x40d5b0]
mov dword [eax + 0x138], 3
mov esi, eax
movups xmmword [eax + 0x14c], xmm0
call fcn.00401b10
test eax, eax
je 0x4090a8
lea eax, [esi + 0x130]
mov dword [esp + 4], eax
mov eax, dword [esi]
mov dword [esp], eax
call dword [sym.imp.user32.dll_SetWindowPlacement]
sub esp, 8
mov dword [esp + 0x18], 0
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0xff00
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0x10
mov dword [esp + 4], 0x66
mov eax, dword [0x416020]
mov dword [esp], eax
call dword [sym.imp.comctl32.dll_ImageList_LoadImageW]
mov dword [0x416868], 0
mov dword [0x416064], eax
mov eax, dword [0x41602c]
sub esp, 0x1c
mov dword [esp], eax
call dword [sym.imp.user32.dll_UpdateWindow]
mov eax, dword [esi]
sub esp, 4
test eax, eax
je 0x408841
mov eax, dword [ebp - 0x142c]
cmp word [eax], 0
je 0x408841
lea edi, [ebp - 0x1218]
xor eax, eax
mov ecx, pe_nt_image_headers32
rep stosd dword es:[edi], eax
lea eax, [ebp - 0x1018]
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x1218]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x1418]
mov dword [esp + 8], eax
lea eax, [ebp - 0x1420]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x142c]
mov dword [esp], eax
call dword [sym.imp.ucrtbase.dll__wsplitpath]
cmp word [ebp - 0x1218], 0
je 0x408841
mov dword [esp + 0xc], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0x18b
mov eax, dword [esi + 0x98]
mov dword [esp], eax
mov eax, dword [sym.imp.user32.dll_SendMessageW]
mov dword [ebp - 0x142c], eax
call eax
mov ebx, dword [ebp - 0x1434]
mov edx, eax
sub esp, 0x10
xor eax, eax
nop
movzx ecx, word [ebp + eax - 0x1218]
mov word [ebx + eax], cx
add eax, 2
test cx, cx
jne 0x408f30
cmp word [ebp - 0xc10], 0
mov ecx, dword [ebp - 0x1434]
je 0x408f61
lea esi, [esi]
add ecx, 2
cmp word [ecx], 0
jne 0x408f58
xor eax, eax
lea esi, [esi]
nop
movzx ebx, word [ebp + eax - 0x1018]
mov word [ecx + eax], bx
add eax, 2
test bx, bx
jne 0x408f68
test edx, edx
jle 0x408841
xor ebx, ebx
mov dword [ebp - 0x1430], edx
jmp 0x408fbf
mov eax, dword [ebp - 0x1434]
lea edx, [edi + 0x24c]
mov dword [esp], edx
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_lstrcmpW]
sub esp, 8
test eax, eax
je 0x409006
add ebx, 1
cmp dword [ebp - 0x1430], ebx
je 0x408841
mov dword [esp + 0xc], 0
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x199
mov eax, dword [esi + 0x98]
mov dword [esp], eax
mov eax, dword [ebp - 0x142c]
call eax
mov edi, eax
mov eax, dword [ebp - 0x1434]
sub esp, 0x10
mov dword [esp + 4], eax
lea eax, [edi + 0x44]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_lstrcmpW]
sub esp, 8
test eax, eax
jne 0x408f90
mov dword [esp + 0xc], 0
mov dword [esp + 8], ebx
mov dword [esp + 4], 0x186
mov eax, dword [esi + 0x98]
mov dword [esp], eax
mov eax, dword [ebp - 0x142c]
call eax
mov eax, dword [esi + 0x98]
sub esp, 0x10
mov dword [esp], eax
call dword [sym.imp.user32.dll_SetFocus]
sub esp, 4
jmp 0x408841
lea eax, [ebp - 0xe18]
mov dword [esp], 0x104
mov dword [esp + 4], eax
call dword [sym.imp.kernel32.dll_GetCurrentDirectoryW]
lea eax, [ebp - 0xe18]
sub esp, 8
mov dword [ebp - 0x142c], eax
jmp 0x408d5f
mov dword [esp], 0x11
call dword [sym.imp.gdi32.dll_GetStockObject]
sub esp, 4
mov dword [esp + 8], edi
mov dword [esp + 4], 0x5c
mov dword [esp], eax
call dword [sym.imp.gdi32.dll_GetObjectW]
sub esp, 0xc
jmp 0x408a2c
mov dword [esp + 8], esi
mov dword [esp + 4], 0
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapFree]
xor eax, eax
sub esp, 0xc
jmp 0x408846