Function at 0x40ce60
Capabilities:
Identify system language via api

Disassembly:
push 0xffffffffffffffff
mov eax, dword fs:[0]
push 0x438bf1
push eax
mov eax, 0x1014
mov dword fs:[0], esp
call fcn.0040df70
push ebx
push ebp
push esi
push edi
xor ebp, ebp
push ebp
push 0xfffffffffffffffe
push str.._AV__TSHashTable_ULOCALIZEDENTRY__VHASHKEY_STRI____
push 0x28
call fcn.0040ff20
mov esi, eax
mov dword [esp + 0x20], esi
mov dword [esp + 0x1c], esi
cmp esi, ebp
mov dword [esp + 0x102c], ebp
je 0x40cf2d
lea ebx, [esi + 4]
lea edi, [ebx + 4]
mov dword [esp + 0x18], ebx
mov dword [edi], ebp
mov dword [edi + 4], ebp
mov ecx, ebx
mov byte [esp + 0x102c], 1
mov dword [ebx], ebp
call fcn.0040d7f0
mov dword [edi], edi
or edi, 1
mov dword [ebx], 0xdddddddd
mov dword [ebx + 8], edi
mov dword [esi + 0x14], ebp
mov dword [esi + 0x18], ebp
mov dword [esi + 0x1c], ebp
mov dword [esi + 0x20], ebp
mov dword [esi], 0x439564
mov dword [esi + 0x10], ebp
cmp dword [ebx], 0xc
mov byte [esp + 0x102c], 3
je 0x40cf24
lea edi, [ebx + 4]
mov eax, dword [edi + 4]
test al, 1
jne 0x40cf16
cmp eax, ebp
je 0x40cf16
mov ecx, dword [ebx]
add ecx, eax
call fcn.00406b90
jmp 0x40cf00
mov dword [edi], edi
or edi, 1
mov dword [ebx], 0xc
mov dword [ebx + 8], edi
mov dword [esi + 0x24], 0xffffffff
jmp 0x40cf2f
xor esi, esi
mov dword [esp + 0x102c], 0xffffffff
mov dword [0x45da18], esi
call sub.KERNEL32.dll_GetUserDefaultLangID
mov ecx, eax
and ecx, 0x3ff
cmp cx, 4
je 0x40cf5b
or ecx, 0x400
mov eax, ecx
xor ecx, ecx
mov dword [esp + 0x14], ecx
xor esi, esi
mov edx, 0x442068
cmp word [edx], ax
je 0x40cf7b
add edx, 0xc
inc esi
cmp edx, 0x4420f8
jb 0x40cf68
jmp 0x40cf89
lea eax, [esi + esi*2]
mov ecx, dword [eax*4 + 0x442060]
mov dword [esp + 0x14], ecx
mov edx, dword [0x441e68]
cmp byte [edx], 0
je 0x40d135
mov edx, 0x441e68
mov eax, edx
mov dword [esp + 0x1c], eax
mov esi, dword [edx]
cmp byte [esi], 0
mov dword [esp + 0x10], esi
je 0x40d11f
jmp 0x40cfbc
mov ecx, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
test ecx, ecx
mov ebp, esi
mov dword [esp + 0x20], ebp
mov dword [esp + 0x18], 0
jle 0x40cfe7
mov edi, ecx
mov dword [esp + 0x18], ecx
push esi
call fcn.00410390
dec edi
lea eax, [esi + eax + 1]
mov dword [esp + 0x10], eax
mov esi, eax
jne 0x40cfd4
cmp byte [esi], 0
mov eax, esi
jne 0x40cff0
mov eax, ebp
push 0x1000
lea ecx, [esp + 0x28]
push ecx
push eax
call fcn.0040d150
mov esi, dword [0x45da18]
add esp, 0xc
push ebp
call fcn.004108d0
mov ebx, eax
cmp dword [esi + 0x24], 0xffffffff
jne 0x40d049
push 4
lea ecx, [esi + 0x14]
mov dword [esi + 0x24], 3
call fcn.0040da30
xor edi, edi
xor ebp, ebp
mov eax, dword [esi + 0x1c]
mov ecx, ebp
push 4
add ecx, eax
call fcn.0040d600
mov eax, dword [esi + 0x24]
inc edi
add ebp, 0xc
cmp edi, eax
jbe 0x40d02c
mov ebp, dword [esp + 0x20]
mov edi, dword [esi + 0x24]
and edi, ebx
push edi
mov ecx, esi
call fcn.0040d760
test eax, eax
je 0x40d05f
mov edi, dword [esi + 0x24]
and edi, ebx
mov ecx, dword [esi + 0x1c]
mov edx, dword [esi]
push 0
lea eax, [edi + edi*2]
lea eax, [ecx + eax*4]
push 0
push eax
mov ecx, esi
call dword [edx + 4]
push 0
mov edi, eax
push 2
push edi
lea ecx, [esi + 4]
call fcn.00405c80
mov dword [edi], ebx
mov eax, dword [edi + 0x14]
cmp eax, ebp
je 0x40d0b5
test eax, eax
je 0x40d0a2
push 0
push 0x8c2
push str......._stormh_stpl.h
push eax
call fcn.00410070
push 0x8c3
push str......._stormh_stpl.h
push ebp
call fcn.004102d0
mov dword [edi + 0x14], eax
push 0
push 0xa2
push str.E:ProjectsLegacyToolsPatcher_bnupdate_strings.cpp
lea ecx, [esp + 0x30]
push ecx
call fcn.00410390
inc eax
push eax
call fcn.0040ff20
push 0x7fffffff
lea edx, [esp + 0x28]
push edx
push eax
mov dword [edi + 0x18], eax
call fcn.00410250
mov eax, dword [esp + 0x18]
cmp eax, 0xc
jge 0x40d10a
mov esi, 0xc
sub esi, eax
mov edi, dword [esp + 0x10]
push edi
call fcn.00410390
dec esi
lea eax, [edi + eax + 1]
mov dword [esp + 0x10], eax
jne 0x40d0f5
mov ecx, dword [esp + 0x10]
cmp byte [ecx], 0
jne 0x40cfb4
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x14]
mov esi, dword [eax + 4]
mov bl, byte [esi]
add eax, 4
test bl, bl
mov dword [esp + 0x1c], eax
mov edx, eax
jne 0x40cfa3
mov ecx, dword [esp + 0x1024]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x1020
ret