Function at 0x4012d0
Capabilities:
Get graphical window text

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x3c
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x14]
push ecx
call dword [sym.imp.USER32.dll_GetWindowTextLengthW]
add eax, 1
mov dword [ebp - 4], eax
mov edx, dword [ebp - 4]
shl edx, 1
push edx
call dword [sym.imp.MSVCRT.dll_malloc]
add esp, 4
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 4]
push eax
mov ecx, dword [ebp - 0xc]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x14]
push eax
call dword [sym.imp.USER32.dll_GetWindowTextW]
mov ecx, dword [ebp - 4]
sub ecx, 1
mov dword [ebp - 4], ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x10]
and eax, 1
je 0x40132c
mov ecx, dword [ebp + 0x14]
mov dword [ebp - 8], ecx
jmp 0x401332
mov edx, dword [ebp + 0x10]
mov dword [ebp - 8], edx
lea eax, [ebp - 0x24]
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x14]
push edx
call dword [sym.imp.USER32.dll_GetWindowRect]
lea eax, [ebp - 0x3c]
push eax
push 0x18
mov ecx, dword [ebp - 8]
push ecx
call dword [sym.imp.GDI32.dll_GetObjectW]
mov edx, dword [ebp - 0x1c]
sub edx, dword [ebp - 0x24]
sub edx, dword [ebp - 0x38]
sar edx, 1
mov dword [ebp - 0x14], edx
mov eax, dword [ebp - 0x18]
sub eax, dword [ebp - 0x20]
sub eax, dword [ebp - 0x34]
sar eax, 1
mov dword [ebp - 0x10], eax
push 0
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
mov ecx, dword [ebp + 8]
add ecx, 0x1c
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x18]
push eax
call dword [sym.imp.USER32.dll_FillRect]
mov ecx, dword [ebp - 8]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.GDI32.dll_SelectObject]
push 0xcc0020
push 0
push 0
mov eax, dword [ebp + 0xc]
push eax
mov ecx, dword [ebp - 0x34]
push ecx
mov edx, dword [ebp - 0x38]
push edx
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x18]
push eax
call dword [sym.imp.GDI32.dll_BitBlt]
cmp dword [ebp + 0x18], 0
je 0x401427
cmp dword [ebp + 0x1c], 0
je 0x401427
mov ecx, dword [ebp + 0x18]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call dword [sym.imp.GDI32.dll_SelectObject]
push 0xcc0020
mov eax, dword [ebp + 0x1c]
mov ecx, dword [eax + 4]
push ecx
mov edx, dword [ebp + 0x1c]
mov eax, dword [edx]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp + 0x1c]
mov eax, dword [ebp + 0x1c]
mov ecx, dword [edx + 0xc]
sub ecx, dword [eax + 4]
push ecx
mov edx, dword [ebp + 0x1c]
mov eax, dword [ebp + 0x1c]
mov ecx, dword [edx + 8]
sub ecx, dword [eax]
push ecx
mov edx, dword [ebp + 0x1c]
mov eax, dword [edx + 4]
push eax
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ecx]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x18]
push ecx
call dword [sym.imp.GDI32.dll_BitBlt]
push 1
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x18]
push eax
call dword [sym.imp.GDI32.dll_SetBkMode]
push 0xffffff
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x18]
push edx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov eax, dword [ebp + 0x20]
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x18]
push edx
call dword [sym.imp.GDI32.dll_SelectObject]
push 0x25
mov eax, dword [ebp + 8]
add eax, 0x1c
push eax
mov ecx, dword [ebp - 4]
push ecx
mov edx, dword [ebp - 0xc]
push edx
mov eax, dword [ebp + 8]
mov ecx, dword [eax + 0x18]
push ecx
call dword [sym.imp.USER32.dll_DrawTextW]
mov edx, dword [ebp - 0xc]
push edx
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov esp, ebp
pop ebp
ret