Function at 0x10018990
Capabilities:
Identify system language via api
Query or enumerate registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x1bc
mov eax, dword [0x10131c40]
xor eax, esp
mov dword [esp + 0x1b8], eax
mov eax, dword [ebp + 8]
push ebx
mov ebx, ecx
mov dword [esp + 0x1c], eax
mov ecx, dword [ebp + 0x18]
push esi
mov esi, dword [ebp + 0x28]
mov dword [esp + 0x1c], ecx
mov ecx, dword [ebp + 0x1c]
push edi
mov dword [esp + 0x34], ecx
mov ecx, dword [ebp + 0x24]
push eax
mov dword [esp + 0x20], ebx
mov dword [esp + 0x2c], ecx
mov dword [esp + 0x18], esi
mov dword [esp + 0x30], 1
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov esi, dword [esi]
lea edi, [esp + 0x60]
mov ecx, 0x17
mov dword [esp + 0x18], eax
rep movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x24]
push esi
call dword [sym.imp.GDI32.dll_GetTextColor]
mov edi, dword [esp + 0x18]
push eax
push edi
call dword [sym.imp.GDI32.dll_SetTextColor]
push esi
call dword [sym.imp.GDI32.dll_GetTextAlign]
push eax
push edi
call dword [sym.imp.GDI32.dll_SetTextAlign]
call dword [sym.imp.KERNEL32.dll_GetSystemDefaultUILanguage]
cmp dword [ebp + 0x34], 0
movzx eax, ax
je 0x10018a54
or byte [esp + 0x77], 0x81
lea eax, [esp + 0x7c]
push 0x1010e5d8
push 0x20
push eax
call fcn.100b669b
mov edi, dword [esp + 0x20]
mov dword [ebx + 0x490], 0
jmp 0x10018bff
mov ecx, 0x412
cmp ax, cx
je 0x10018aff
mov ecx, 0x812
cmp ax, cx
je 0x10018aff
mov ecx, 0x411
cmp ax, cx
je 0x10018ae0
mov ecx, 0x44b
cmp ax, cx
je 0x10018ae0
mov ecx, 0x457
cmp ax, cx
je 0x10018ae0
mov ecx, 0x404
cmp ax, cx
je 0x10018ac1
mov ecx, 0x804
cmp ax, cx
je 0x10018ac1
or byte [esp + 0x77], 0x88
lea eax, [esp + 0x7c]
push str.SIMSUN
push 0x20
push eax
call fcn.100b669b
mov edi, dword [esp + 0x20]
jmp 0x10018bf5
or byte [esp + 0x77], 0x86
lea eax, [esp + 0x7c]
push str.SONG
push 0x20
push eax
call fcn.100b669b
mov edi, dword [esp + 0x20]
jmp 0x10018bf5
or byte [esp + 0x77], 0x80
lea eax, [esp + 0x7c]
push str.Mincho
push 0x20
push eax
call fcn.100b669b
mov edi, dword [esp + 0x20]
jmp 0x10018bf5
or byte [esp + 0x77], 0x81
lea eax, [esp + 0xc1]
push 0xff
push 0
push eax
mov byte [esp + 0xcc], 0
call fcn.100bac50
add esp, 0xc
lea eax, [esp + 0x30]
push eax
lea eax, [esp + 0x14]
push eax
push 0
push 1
push 0
push 0
push 0
push str.SYSTEMControlSet001ControlFontAssocAssociated_DefaultFonts
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov edi, dword [esp + 0x14]
mov eax, dword [edi]
mov cl, byte [eax + 0x1b]
test cl, 0x10
je 0x10018b6d
lea eax, [esp + 0xc]
push eax
lea eax, [esp + 0xc4]
push eax
push 0
push 0
push str.FontPackageRoman
jmp 0x10018bca
test cl, 0x20
je 0x10018b8a
lea eax, [esp + 0xc]
push eax
lea eax, [esp + 0xc4]
push eax
push 0
push 0
push str.FontPackageSwiss
jmp 0x10018bca
mov al, cl
and al, 0x30
cmp al, 0x30
lea eax, [esp + 0xc]
push eax
lea eax, [esp + 0xc4]
push eax
push 0
push 0
jne 0x10018baa
push str.FontPackageModern
jmp 0x10018bca
test cl, 0x40
je 0x10018bb6
push str.FontPackageScript
jmp 0x10018bca
and cl, 0x50
cmp cl, 0x50
jne 0x10018bc5
push str.FontPackageDecorative
jmp 0x10018bca
push str.FontPackageDontCare
push dword [esp + 0x24]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push dword [esp + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [esp + 0xc0]
push eax
lea eax, [esp + 0x80]
push 0x20
push eax
call fcn.100b669b
mov dword [ebx + 0x490], 1
and byte [esp + 0x87], 0xfe
lea eax, [esp + 0x6c]
add esp, 0xc
push eax
call dword [sym.imp.GDI32.dll_CreateFontIndirectW]
push eax
push dword [esp + 0x1c]
mov dword [esp + 0x38], eax
call dword [sym.imp.GDI32.dll_SelectObject]
lea eax, [esp + 0x48]
push eax
push esi
call dword [sym.imp.GDI32.dll_GetCurrentPositionEx]
push 0
push dword [esp + 0x50]
push dword [esp + 0x50]
push dword [esp + 0x24]
call dword [sym.imp.GDI32.dll_MoveToEx]
push esi
call dword [sym.imp.GDI32.dll_GetTextAlign]
push eax
push dword [esp + 0x1c]
call dword [sym.imp.GDI32.dll_SetTextAlign]
mov ecx, dword [ebp + 0x2c]
mov dword [ebx + 0x484], 1
mov eax, dword [ecx + 4]
mov dword [ebx + 0x488], eax
mov eax, dword [ecx + 8]
mov dword [ebx + 0x48c], eax
mov eax, dword [ebp + 0x30]
mov ecx, dword [eax + 4]
mov esi, dword [eax]
sub ecx, esi
mov eax, 0x2aaaaaab
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
cmp eax, 1
jne 0x10018cc3
push dword [esp + 0x28]
mov eax, dword [ebx]
mov ecx, ebx
push dword [ebp + 0x20]
push dword [esp + 0x3c]
push dword [esp + 0x2c]
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push dword [esp + 0x34]
call dword [eax + 0xcc]
mov dword [esp + 0x2c], eax
jmp 0x10018e19
mov eax, dword [ebp + 0xc]
mov dword [esp + 0xc], eax
mov eax, dword [ebp + 0x10]
mov dword [esp + 0x14], eax
mov eax, dword [edi]
mov eax, dword [eax + 8]
test eax, eax
je 0x10018d10
movd xmm0, eax
cvtdq2pd xmm0, xmm0
mulsd xmm0, qword [0x10116358]
divsd xmm0, qword [0x101163a8]
movsd qword [esp + 0x38], xmm0
call fcn.100d5080
movsd qword [esp + 0x50], xmm0
movsd xmm0, qword [esp + 0x38]
call fcn.100d5db0
jmp 0x10018d21
movsd xmm0, qword [0x10116328]
movsd qword [esp + 0x50], xmm0
xorps xmm0, xmm0
mov eax, dword [ebp + 0x30]
movsd qword [esp + 0x38], xmm0
cmp esi, dword [eax + 4]
je 0x10018e19
mov eax, dword [esi]
mov ebx, dword [esi + 4]
sub ebx, eax
mov dword [esp + 0x10], eax
inc ebx
test ebx, ebx
jle 0x10018e06
mov ecx, dword [esp + 0x1c]
lea edi, [ebx + ebx]
lea eax, [edi + 2]
add ecx, 0x500
push eax
call fcn.10008ac0
xor ecx, ecx
mov dword [esp + 0x44], eax
push edi
mov word [edi + eax], cx
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x38]
mov edi, dword [esp + 0x48]
lea ecx, [ecx + eax*2]
push ecx
push edi
call fcn.100ba600
mov ecx, dword [esp + 0x34]
add esp, 0xc
xor edx, edx
test ecx, ecx
je 0x10018d92
mov eax, dword [esp + 0x10]
lea edx, [ecx + eax*4]
cmp dword [esi + 8], 0
mov ecx, dword [esp + 0x1c]
push edx
push ebx
push edi
push dword [esp + 0x2c]
mov eax, dword [ecx]
push dword [ebp + 0x14]
push dword [esp + 0x28]
push dword [esp + 0x24]
je 0x10018db6
push dword [esp + 0x34]
jmp 0x10018dba
push dword [esp + 0x40]
call dword [eax + 0xcc]
lea eax, [esp + 0x58]
push eax
push ebx
push edi
push dword [esp + 0x30]
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32W]
movd xmm1, dword [esp + 0x58]
cvtdq2pd xmm1, xmm1
movapd xmm0, xmm1
mulsd xmm1, qword [esp + 0x38]
mulsd xmm0, qword [esp + 0x50]
cvttsd2si eax, xmm0
add dword [esp + 0xc], eax
cvttsd2si eax, xmm1
sub dword [esp + 0x14], eax
test edi, edi
je 0x10018e06
mov ecx, edi
call fcn.10008b90
mov eax, dword [ebp + 0x30]
add esi, 0xc
cmp esi, dword [eax + 4]
jne 0x10018d33
mov ebx, dword [esp + 0x1c]
push dword [esp + 0x30]
call dword [sym.imp.GDI32.dll_DeleteObject]
push dword [esp + 0x18]
call dword [sym.imp.GDI32.dll_DeleteDC]
mov ecx, dword [esp + 0x1c4]
mov eax, dword [esp + 0x2c]
pop edi
pop esi
mov dword [ebx + 0x484], 0
pop ebx
xor ecx, esp
call fcn.100b54bf
mov esp, ebp
pop ebp
ret 0x30