Function at 0x407dd0
Capabilities:
Get graphical window text
Print debug messages

Disassembly:
sub esp, 0x12c
mov eax, dword [0x428990]
push ebx
push ebp
mov ebp, dword [sym.imp.GDI32.dll_SetBkMode]
push esi
push edi
mov edi, dword [esp + 0x140]
push 1
push edi
mov dword [esp + 0x140], eax
mov ebx, ecx
call ebp
mov ecx, dword [ebx + 8]
lea eax, [esp + 0x28]
push eax
push ecx
call dword [sym.imp.USER32.dll_GetClientRect]
mov eax, dword [esp + 0x30]
mov esi, dword [esp + 0x28]
mov edx, dword [esp + 0x2c]
sub eax, esi
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x34]
sub eax, edx
push edi
mov dword [esp + 0x18], eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov esi, eax
test esi, esi
jne 0x407e3d
push str.Create_MemDc_ERROR
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push edi
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov edi, eax
test edi, edi
jne 0x407e55
push str.Create_MemDc_ERROR
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push esi
call dword [sym.imp.GDI32.dll_SaveDC]
push 1
push esi
mov dword [esp + 0x28], eax
call ebp
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x140]
push edx
push eax
push ecx
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
mov ebp, dword [sym.imp.GDI32.dll_SelectObject]
push eax
push esi
mov dword [esp + 0x2c], eax
call ebp
mov eax, dword [ebx + 0x8c]
test eax, eax
jne 0x407ea1
mov ecx, esi
call fcn.00408130
jmp 0x4080ab
mov eax, dword [ebx + 0x84]
test eax, eax
je 0x407fd5
mov eax, dword [ebx + 0x4c]
test eax, eax
je 0x407ee4
mov ecx, dword [ebx + 0x5c]
test ecx, ecx
jne 0x407ec0
push eax
jmp 0x407ee1
call dword [sym.imp.WINMM.dll_timeGetTime]
mov edx, eax
mov eax, 0x10624dd3
mul edx
shr edx, 5
test dl, 1
jne 0x407edd
mov eax, dword [ebx + 0x5c]
push eax
jmp 0x407ee1
mov ecx, dword [ebx + 0x4c]
push ecx
push edi
call ebp
mov eax, dword [ebx + 0x7c]
test eax, eax
jne 0x407ef5
mov eax, dword [ebx + 0x88]
test eax, eax
je 0x407f00
mov eax, dword [ebx + 0x50]
test eax, eax
je 0x407f00
push eax
push edi
call ebp
mov eax, dword [ebx + 0x80]
test eax, eax
je 0x407f15
mov eax, dword [ebx + 0x54]
test eax, eax
je 0x407f15
push eax
push edi
call ebp
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
push 0xcc0020
push 0
push 0
push edi
push edx
push eax
push 0
push 0
push esi
call dword [sym.imp.GDI32.dll_BitBlt]
push edi
call dword [sym.imp.GDI32.dll_DeleteDC]
mov edx, dword [ebx + 8]
push 0x100
lea ecx, [esp + 0x3c]
push ecx
push edx
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x407f6b
lea eax, [esp + 0x38]
lea edx, [ebx + 0x98]
mov ecx, eax
sub edx, ecx
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x407f61
lea eax, [ebx + 0x98]
mov dword [esp + 0x1c], eax
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x407f78
sub eax, edx
mov dword [esp + 0x10], eax
je 0x4080ab
mov edx, dword [ebx + 0x78]
mov ebp, dword [sym.imp.GDI32.dll_SetTextColor]
push edx
push esi
call ebp
mov ebx, dword [ebx + 0x298]
test ebx, ebx
mov dword [esp + 0x10], eax
je 0x407fb2
push ebx
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov edi, eax
jmp 0x407fb6
mov edi, dword [esp + 0x10]
mov ecx, dword [esp + 0x1c]
push 0x25
lea eax, [esp + 0x2c]
push eax
push 0xffffffffffffffff
push ecx
push esi
call dword [sym.imp.USER32.dll_DrawTextA]
mov edx, dword [esp + 0x10]
push edx
jmp 0x4080a0
mov eax, dword [ebx + 0x58]
test eax, eax
je 0x407fe0
push eax
push edi
call ebp
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
push 0xcc0020
push 0
push 0
push edi
push eax
push ecx
push 0
push 0
push esi
call dword [sym.imp.GDI32.dll_BitBlt]
push edi
call dword [sym.imp.GDI32.dll_DeleteDC]
mov eax, dword [ebx + 8]
push 0x100
lea edx, [esp + 0x3c]
push edx
push eax
call dword [sym.imp.USER32.dll_GetWindowTextA]
test eax, eax
je 0x40803a
lea eax, [esp + 0x38]
lea edx, [ebx + 0x98]
mov ecx, eax
sub edx, ecx
lea esp, [esp]
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
test cl, cl
jne 0x408030
lea eax, [ebx + 0x98]
mov dword [esp + 0x1c], eax
lea edx, [eax + 1]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x408047
sub eax, edx
mov dword [esp + 0x10], eax
je 0x4080ab
push 0x11
call dword [sym.imp.USER32.dll_GetSysColor]
mov ebp, dword [sym.imp.GDI32.dll_SetTextColor]
push eax
push esi
call ebp
mov ebx, dword [ebx + 0x298]
test ebx, ebx
mov dword [esp + 0x10], eax
je 0x408082
push ebx
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov edi, eax
jmp 0x408086
mov edi, dword [esp + 0x10]
mov eax, dword [esp + 0x1c]
push 0x25
lea edx, [esp + 0x2c]
push edx
push 0xffffffffffffffff
push eax
push esi
call dword [sym.imp.USER32.dll_DrawTextA]
mov ecx, dword [esp + 0x10]
push ecx
push esi
call ebp
push edi
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x140]
push 0xcc0020
push 0
push 0
push esi
push edx
push eax
push 0
push 0
push ecx
call dword [sym.imp.GDI32.dll_BitBlt]
mov edx, dword [esp + 0x20]
push edx
push esi
call dword [sym.imp.GDI32.dll_RestoreDC]
push esi
call dword [sym.imp.GDI32.dll_DeleteDC]
test eax, eax
pop edi
pop esi
pop ebp
pop ebx
jne 0x4080f7
push str.DeleteDC_hdcMem__ERROR
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [esp + 0x14]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
test eax, eax
jne 0x408111
push str.DeleteObject_bmp__ERROR
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov ecx, dword [esp + 0x128]
mov eax, 1
call fcn.0040b285
add esp, 0x12c
ret 4