Function at 0x51e12556
Capabilities:
Identify system language via api

Disassembly:
mov eax, 0x51e7dcb8
call fcn.51e038b0
sub esp, 0x98
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [eax + 0x10]
mov ecx, dword [ebx]
push esi
push edi
mov dword [ebp - 0x10], esp
push eax
lea eax, [ebp - 0xa4]
push eax
mov dword [ebp - 0x14], ecx
call fcn.51e161cf
mov esi, eax
lea edi, [ebp - 0x50]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
lea esi, [ebx + 4]
mov dword [ebp - 0x40], esi
lea edi, [ebp - 0x5c]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov esi, dword [ebp + 8]
push esi
call fcn.51e12501
and byte [ebp - 0x30], 0xf8
and word [ebp - 0x32], 0x801f
lea eax, [ebp - 0x3c]
xor ebx, ebx
push eax
push esi
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x20], ebx
call fcn.51e161bb
mov eax, dword [0x51e8b69c]
add esp, 0x14
cmp word [eax + 0x537c], bx
jne 0x51e23fba
cmp byte [ebp - 0x34], 5
je 0x51e126f8
cmp byte [ebp - 0x34], 4
je 0x51e126f8
mov eax, dword [ebp + 0xc]
cmp eax, 0xffffffff
je 0x51e125f8
mov dword [ebp - 0x3c], eax
push 9
pop ecx
lea esi, [ebp - 0x3c]
lea edi, [ebp - 0x94]
push 3
lea eax, [ebp - 0x70]
rep movsd dword es:[edi], dword [esi]
mov edi, dword [ebp + 8]
push eax
push edi
mov dword [ebp - 4], ebx
call fcn.51e0e876
add esp, 0xc
cmp dword [ebp - 0x70], ebx
je 0x51e23fe5
mov eax, dword [ebp - 0x50]
neg eax
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x4c]
neg eax
cmp dword [ebp - 0x18], ebx
mov dword [ebp - 0x60], eax
jne 0x51e12656
push dword [0x51e8b558]
push ebx
push dword [ebp - 0x38]
call fcn.51e1745c
add esp, 0xc
cmp eax, ebx
mov dword [ebp - 0x18], eax
je 0x51e23fef
mov ecx, dword [ebp - 0x18]
mov eax, dword [ecx + 0x28]
add eax, dword [ecx + 0x24]
mov ecx, dword [ebp - 0x44]
sub ecx, dword [ebp - 0x4c]
lea eax, [eax + eax*2]
cdq
sub eax, edx
xor edx, edx
sar eax, 1
cmp ecx, eax
setge dl
push ebx
push edx
push 0xac5
push dword [ebp - 0x14]
call dword [0x51e8bba0]
push ebx
push dword [ebp - 0x24]
push 0xadd
push dword [ebp - 0x14]
call dword [0x51e8bba0]
mov eax, dword [0x51e8b69c]
cmp eax, ebx
je 0x51e23ff9
cmp dword [eax + 0x53b8], ebx
jne 0x51e24023
mov edi, dword [ebp - 0x40]
lea esi, [ebp - 0x70]
movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x94]
push eax
push ebx
movsd dword es:[edi], dword [esi]
push 0xac7
push dword [ebp - 0x14]
movsd dword es:[edi], dword [esi]
call dword [0x51e8bba0]
cmp eax, ebx
jne 0x51e2403f
cmp dword [ebp - 0x5c], ebx
je 0x51e126e9
lea eax, [ebp - 0x5c]
push eax
push dword [ebp + 8]
call fcn.51e18564
pop ecx
pop ecx
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
leave
ret
mov byte [ebp - 0x34], 1
jmp 0x51e125ed
cmp dword [esi + 0x20], 0xe
jne 0x51e125d9
cmp dword [esi + 0x24], ebx
jne 0x51e125d9
mov eax, dword [ebp - 0x32]
and ax, 0xffe8
or ax, 8
mov byte [ebp - 0x34], 1
mov word [ebp - 0x32], ax
jmp 0x51e125d9
push 0x7d1
call fcn.51e0d896
push 0x7d1
call fcn.51e0d896
mov esi, dword [sym.imp.KERNEL32.dll_GetUserDefaultLangID]
call esi
cmp ax, 0x411
je 0x51e24023
call esi
cmp ax, 0x404
je 0x51e24023
call esi
cmp ax, 0x412
je 0x51e24023
call esi
cmp ax, 0x804
jne 0x51e126af
mov eax, dword [edi + 0xc]
movzx eax, byte [eax + 0x20]
push ebx
push eax
push 0xadc
push dword [ebp - 0x14]
call dword [0x51e8bba0]
jmp 0x51e126af
push 0x7d1
call fcn.51e0d896
push 0
push 2
push 0xac7
push dword [ebp - 0x14]
call dword [0x51e8bba0]
mov eax, 0x51e126e9
ret