Function at 0x404190
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xf7c
push ebx
mov ebx, ecx
push esi
xor esi, esi
mov ecx, dword [ebx + 0x70]
push edi
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0xc], esi
mov edx, dword [ecx + 4]
mov dword [ebp - 0x94], esi
mov dword [ebp - 0x90], edx
mov dword [ebp - 0x38], esi
mov eax, dword [edx + 0xd8]
mov dword [ebp - 0x34], esi
cmp eax, esi
mov dword [ebp - 0x30], esi
mov dword [ebp - 8], esi
mov dword [ebp - 4], esi
mov dword [ebp - 0x48], esi
je 0x4041fc
mov edi, dword [eax + 0x14e4]
cmp edi, esi
je 0x4041fc
cmp dword [edi + 0x10], ecx
jne 0x4041fc
cmp dword [eax + 0x14fc], esi
je 0x4041fc
mov al, byte [ebx + 0x54]
mov dword [ebp - 0x9c], 1
test al, 8
je 0x404202
mov dword [ebp - 0x9c], esi
mov eax, dword [ebp + 8]
mov ecx, 6
mov esi, eax
lea edi, [ebp - 0xcc]
rep movsd dword es:[edi], dword [esi]
lea edi, [ebx + 0x24]
mov ecx, 6
mov esi, eax
mov dword [ebp - 0x54], edi
rep movsd dword es:[edi], dword [esi]
mov ecx, 6
lea esi, [ebp - 0xcc]
lea edi, [ebp - 0xf0]
rep movsd dword es:[edi], dword [esi]
mov eax, dword [edx + 0x58]
mov ecx, dword [eax + 0xc0]
test ecx, ecx
je 0x404276
lea ecx, [ebp - 0x15c]
push ecx
push 0x4000
push 0x4000
call fcn.00406a30
lea edx, [ebp - 0xf0]
lea eax, [ebp - 0x15c]
push edx
lea ecx, [ebp - 0xf0]
push eax
push ecx
call fcn.00406520
add esp, 0x18
lea edx, [ebp - 0x2c4]
mov ecx, ebx
push edx
call fcn.00402670
mov eax, dword [ebp - 0x1c4]
mov ecx, dword [ebp - 0x1b4]
mov dword [ebx + 0x5c], eax
mov eax, dword [ebx + 0x70]
xor edx, edx
mov dword [ebp - 0x58], ecx
mov cx, word [ebx + 0x54]
mov dword [ebp - 0x80], edx
mov dword [ebp - 0x7c], edx
mov esi, dword [eax + 0xc]
mov eax, 2
mov dword [ebp - 0x80], esi
test cl, 1
mov dword [ebp - 0x6c], 0x20000000
mov dword [ebp - 0x7c], eax
je 0x4042c9
mov eax, 6
mov dword [ebp - 0x7c], eax
jmp 0x4042d2
cmp dword [ebp + 0x10], edx
jne 0x4052be
test cl, 4
je 0x4042f5
lea ecx, [ebp - 0xd0]
push 1
push ecx
lea ecx, [ebp - 0x80]
call fcn.0041afa0
mov edx, dword [eax]
mov eax, dword [ebp - 0x7c]
mov esi, dword [ebp - 0x80]
mov dword [ebp - 0x40], edx
jmp 0x4042fc
mov dword [ebp - 0x40], 0xff000000
mov cx, word [ebx + 0x54]
test cl, 2
je 0x40430b
add eax, 2
mov dword [ebp - 0x7c], eax
test ch, 0x20
je 0x40435c
inc eax
xor ecx, ecx
xor edx, edx
lea edi, [eax + esi]
add eax, 2
mov dword [ebp - 0x7c], eax
mov ch, byte [edi + 1]
mov cl, byte [edi]
lea edi, [eax + esi]
add eax, 2
mov dword [ebp - 0x34], ecx
mov dword [ebp - 0x7c], eax
mov dh, byte [edi + 1]
mov dl, byte [edi]
lea edi, [eax + esi]
add eax, 2
xor ecx, ecx
mov dword [ebp - 0x7c], eax
mov ch, byte [edi + 1]
mov cl, byte [edi]
add esi, eax
mov dword [ebp - 0x30], edx
add eax, 2
xor edx, edx
mov dword [ebp - 0x7c], eax
mov dh, byte [esi + 1]
mov dword [ebp - 8], ecx
mov dl, byte [esi]
mov dword [ebp - 4], edx
mov eax, dword [ebx + 0x9c]
push eax
call fcn.00406d40
mov ecx, dword [ebx + 0x10]
lea edx, [ecx*4 + 4]
push edx
call fcn.00406d30
mov dword [ebx + 0x9c], eax
mov eax, dword [ebx + 0x5c]
shl eax, 0x10
add esp, 8
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
mov ebx, dword [ebp - 0xe4]
imul ebx
shrd eax, edx, 0x10
adc eax, 0
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x18]
cdq
and edx, 0xffff
add edx, eax
mov eax, dword [ebp + 0x10]
sar edx, 0x10
test eax, eax
jne 0x4043bd
test edx, edx
je 0x4052bb
mov ecx, 0xf
xor eax, eax
lea edi, [ebp - 0x134]
lea ebx, [ebp - 0x118]
rep stosd dword es:[edi], eax
lea edi, [ebp - 0x2c4]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, ebx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [ebp - 0x1c0]
and ecx, 3
neg edx
rep movsb byte es:[edi], byte [esi]
test eax, eax
mov dword [ebp - 0x134], edx
mov byte [ebp - 0x11c], 3
mov byte [ebp - 0x11b], 2
mov byte [ebp - 0x11a], 2
je 0x404424
mov dword [ebp - 0x124], 0x2bc
mov eax, dword [ebp - 0x1bc]
test eax, eax
je 0x404435
mov byte [ebp - 0x120], 1
mov eax, dword [ebp - 0x1b8]
test eax, eax
je 0x404446
mov byte [ebp - 0x11d], 0x80
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x40467d
push 0x5c
call fcn.00406d30
add esp, 4
test eax, eax
je 0x404478
mov ebx, dword [ebp - 0x24]
mov edx, dword [ebx + 0x6c]
lea ecx, [edx + 0x7c]
mov edx, dword [edx]
push ecx
push edx
mov ecx, eax
call fcn.00424690
mov dword [ebp - 0x48], eax
jmp 0x404482
mov ebx, dword [ebp - 0x24]
mov dword [ebp - 0x48], 0
mov eax, dword [ebx + 0x6c]
mov ecx, dword [eax]
mov eax, dword [ebp - 0x48]
mov edx, dword [ecx + 0xc0]
mov dword [eax], edx
mov eax, dword [ebp - 0x58]
mov ecx, dword [ebx + 0x5c]
mov edx, dword [ebp - 0x1b0]
mov esi, dword [eax + 0xc]
mov dword [ebp - 0x5c], ecx
mov dword [ebp - 0x80], esi
mov dword [ebp - 0x7c], edx
mov dword [ebp - 0x6c], 0x20000000
mov cl, byte [eax + 0x2a]
test cl, 4
je 0x4044c4
xor ecx, ecx
mov cx, word [eax + 0x28]
lea ecx, [edx + ecx*2]
jmp 0x4044cc
xor ecx, ecx
mov cx, word [eax + 0x28]
add ecx, edx
lea edi, [ecx + esi]
add ecx, 2
xor eax, eax
mov dword [ebp - 0x7c], ecx
mov ah, byte [edi + 1]
mov al, byte [edi]
lea edi, [ecx + esi]
imul eax, dword [ebp - 0x5c]
cdq
and edx, 0x3ff
add ecx, 2
add eax, edx
mov dword [ebp - 0x7c], ecx
sar eax, 0xa
mov dword [ebx + 0x94], eax
xor eax, eax
mov ah, byte [edi + 1]
add ecx, 2
mov al, byte [edi]
mov edi, dword [ebx + 0x94]
imul eax, dword [ebp - 0x5c]
cdq
and edx, 0x3ff
mov dword [ebp - 0x7c], ecx
add eax, edx
add ecx, esi
movsx edx, word [ebp - 4]
mov esi, dword [ebp + 8]
mov dword [ebp - 0xc], ecx
mov ecx, dword [ebp - 0x3d]
sar eax, 0xa
add edx, eax
mov eax, dword [ebx + 0x6c]
add edx, edi
push eax
mov eax, dword [ebp - 0x3f]
mov dword [ebx + 0x98], edx
mov edx, dword [ebp - 0x3e]
push esi
and ecx, 0xff
push 1
and edx, 0xff
push ecx
and eax, 0xff
push edx
push eax
mov eax, dword [ebp - 0x40]
and eax, 0xff
push eax
call fcn.00403f20
mov ecx, dword [ebx + 0x6c]
mov dword [ebp - 0x10], eax
push ecx
push esi
push 0
push 0xff
push 0xff
push 0xff
push 0xff
call fcn.00403f20
mov edx, dword [ebx + 0x6c]
mov edi, eax
push edx
push esi
push 2
push 0xff
push 0
push 0
push 0
call fcn.00403f20
add esp, 0x54
mov dword [ebp - 0x44], eax
mov eax, dword [ebx + 0x6c]
push eax
push esi
push 3
push 0xff
push 0xff
push 0xff
push 0xff
call fcn.00403f20
add esp, 0x1c
mov dword [ebp - 0x98], eax
test byte [ebx + 0x55], 8
je 0x404616
mov eax, dword [ebx + 0x6c]
mov ecx, dword [ebp - 0x48]
mov esi, dword [ebp - 0x54]
push ecx
mov ecx, dword [ebp - 0x44]
lea edx, [eax + 0x7c]
mov eax, dword [eax]
push edx
mov edx, dword [ebx + 0x70]
push eax
push ecx
add edx, 0x10
push esi
push edx
call fcn.0041ad30
mov eax, dword [ebx + 0x6c]
push 0
mov edx, dword [eax]
lea ecx, [eax + 0x7c]
mov eax, dword [ebx + 0x70]
push ecx
push edx
push edi
add eax, 0x10
push esi
push eax
call fcn.0041ad30
add esp, 0x30
mov ecx, dword [ebx + 0x70]
lea eax, [ebx + 0x84]
add ecx, 0x10
mov edx, eax
push eax
push 0x28
mov esi, dword [ecx]
mov dword [ebp - 0x50], eax
mov dword [edx], esi
mov esi, dword [ecx + 4]
mov dword [edx + 4], esi
mov esi, dword [ecx + 8]
mov dword [edx + 8], esi
mov ecx, dword [ecx + 0xc]
mov dword [edx + 0xc], ecx
call fcn.00405e20
mov eax, dword [ebp - 0x34]
mov esi, dword [ebp + 0xc]
and eax, 0xffff
add esp, 8
mov dword [ebp - 0x84], eax
mov eax, dword [ebp - 0x30]
and eax, 0xffff
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 8]
and eax, 0xffff
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x8c], eax
jmp 0x404927
mov ecx, 6
lea esi, [ebp - 0xf0]
lea edi, [ebp - 0xcc]
lea edx, [ebp - 0xcc]
rep movsd dword es:[edi], dword [esi]
push edx
call fcn.00406a50
add esp, 4
test eax, eax
je 0x4052bb
mov eax, dword [ebp - 0x24]
lea ecx, [ebp - 0xcc]
lea edi, [eax + 0x84]
mov eax, dword [eax + 0x70]
add eax, 0x10
push edi
push eax
push ecx
mov dword [ebp - 0x50], edi
call fcn.00406420
mov edx, dword [ebp - 0x90]
add esp, 0xc
mov ecx, dword [edx + 0x58]
add ecx, 0x158
call fcn.0040f2e0
mov eax, dword [ebp - 0x34]
and eax, 0xffff
shl eax, 0x10
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 0xcc]
imul ebx
shrd eax, edx, 0x10
adc eax, 0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
cdq
and edx, 0xffff
add eax, edx
sar eax, 0x10
mov dword [ebp - 0x84], eax
mov eax, dword [ebp - 0x30]
and eax, 0xffff
shl eax, 0x10
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 0xcc]
imul ebx
shrd eax, edx, 0x10
adc eax, 0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
cdq
and edx, 0xffff
add eax, edx
sar eax, 0x10
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 8]
and eax, 0xffff
mov dword [ebp - 0x1c], eax
shl eax, 0x10
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 0xcc]
imul ebx
shrd eax, edx, 0x10
adc eax, 0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
cdq
and edx, 0xffff
add eax, edx
sar eax, 0x10
mov dword [ebp - 0x8c], eax
mov eax, dword [ebp - 4]
and eax, 0xffff
shl eax, 0x10
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
mov ebx, dword [ebp - 0xc0]
imul ebx
shrd eax, edx, 0x10
adc eax, 0
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp + 8]
lea ecx, [ebp + 8]
push eax
push ecx
lea ecx, [edx + 0x18]
call fcn.00413400
mov eax, dword [eax]
lea ecx, [ebp - 0x134]
push ecx
mov dword [ebp - 0x40], eax
call dword [sym.imp.GDI32.dll_CreateFontIndirectA]
mov esi, dword [ebp + 0xc]
push eax
push esi
mov dword [ebp - 0xd0], eax
call dword [sym.imp.GDI32.dll_SelectObject]
lea edx, [ebp - 0x194]
mov dword [ebp - 0xf8], eax
push edx
push esi
call dword [sym.imp.GDI32.dll_GetTextMetricsA]
mov ebx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x190]
mov ecx, dword [ebp - 0x194]
mov dword [ebx + 0x94], eax
mov dword [ebp - 0x5c], ecx
mov eax, dword [ebp - 0x10]
cdq
and edx, 0xffff
add eax, edx
sar eax, 0x10
add eax, ecx
mov ecx, dword [ebp - 0x3f]
mov dword [ebx + 0x98], eax
mov ebx, dword [ebp - 0x3e]
mov eax, dword [ebp - 0x40]
and ebx, 0xff
or bh, 2
and ecx, 0xff
shl ebx, 8
or ebx, ecx
and eax, 0xff
shl ebx, 8
or ebx, eax
push ebx
push esi
mov dword [ebp - 0x98], ebx
call dword [sym.imp.GDI32.dll_SetTextColor]
mov edx, dword [ebp - 0x24]
test byte [edx + 0x55], 8
je 0x4048d1
push 0x2ffffff
call dword [sym.imp.GDI32.dll_CreateSolidBrush]
push eax
push esi
mov dword [ebp + 0xc], eax
call dword [sym.imp.GDI32.dll_SelectObject]
push 7
mov dword [ebp + 8], eax
call dword [sym.imp.GDI32.dll_GetStockObject]
push eax
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x24]
mov ecx, dword [eax + 0x90]
mov edx, dword [eax + 0x88]
mov eax, dword [eax + 0x8c]
push ecx
mov ecx, dword [edi]
push edx
push eax
push ecx
push esi
call dword [sym.imp.GDI32.dll_Rectangle]
mov edx, dword [ebp + 8]
push edx
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov eax, dword [ebp + 0xc]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov ecx, dword [ebp - 0x44]
push ecx
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
push ebx
push 1
push 0
call dword [sym.imp.GDI32.dll_CreatePen]
push eax
push esi
mov dword [ebp - 0x10], eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov edx, dword [ebp - 0x24]
mov dword [ebp - 0x44], eax
mov ecx, edi
push edi
mov eax, dword [edx + 0x70]
push 0x28
add eax, 0x10
mov edx, dword [eax]
mov dword [ecx], edx
mov edx, dword [eax + 4]
mov dword [ecx + 4], edx
mov edx, dword [eax + 8]
mov dword [ecx + 8], edx
mov eax, dword [eax + 0xc]
mov dword [ecx + 0xc], eax
call fcn.00405e20
push edi
lea ecx, [ebp - 0xcc]
push edi
push ecx
call fcn.00406420
mov ebx, dword [ebp - 0x24]
add esp, 0x14
mov edx, dword [ebx + 0x10]
lea eax, [edx + edx + 2]
push eax
call fcn.00406d30
mov edi, eax
mov al, byte [ebx + 0x54]
add esp, 4
mov dword [ebp - 0x38], edi
test al, 0x10
je 0x404969
mov ecx, dword [ebx + 0x10]
xor eax, eax
test ecx, ecx
jle 0x40495e
mov ecx, edi
mov word [ecx], 0x2a
mov edx, dword [ebx + 0x10]
inc eax
add ecx, 2
cmp eax, edx
jl 0x40494e
mov ecx, dword [ebx + 0x10]
mov word [edi + ecx*2], 0
jmp 0x404981
mov eax, dword [ebx + 4]
test eax, eax
je 0x40497c
push eax
push edi
call fcn.00402aa0
add esp, 8
jmp 0x404981
mov word [edi], 0
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x4049fc
mov eax, dword [ebx + 0x10]
lea edx, [ebp - 0x2c4]
push edx
push eax
push edi
mov ecx, ebx
call fcn.00404130
mov ecx, dword [ebx + 0x10]
xor edi, edi
test ecx, ecx
mov dword [ebp - 0x94], eax
jle 0x404a76
mov ecx, eax
mov ax, word [ecx]
cmp ax, 0xffff
jne 0x4049bd
xor eax, eax
jmp 0x4049e1
mov edx, dword [ebp - 0xc]
and eax, 0xffff
lea eax, [edx + eax*2]
xor edx, edx
mov dh, byte [eax + 1]
mov dl, byte [eax]
imul edx, dword [ebx + 0x5c]
mov eax, edx
cdq
and edx, 0x3ff
add eax, edx
sar eax, 0xa
mov edx, dword [ebx + 0x9c]
and eax, 0xffff
add ecx, 2
mov dword [edx + edi*4], eax
mov eax, dword [ebx + 0x10]
inc edi
cmp edi, eax
jl 0x4049b0
jmp 0x404a76
mov eax, dword [ebx + 0x10]
mov ecx, ebx
push eax
push 0
push edi
call fcn.00402a20
mov dword [ebp - 0x4c], eax
mov dword [ebp + 8], eax
mov eax, dword [ebx + 0x10]
xor edi, edi
test eax, eax
mov dword [ebp + 0xc], edi
jle 0x404a6a
mov ecx, dword [ebp + 8]
mov dl, byte [ecx]
mov ecx, ebx
push edx
call fcn.00402990
test eax, eax
je 0x404a30
inc dword [ebp + 8]
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x64]
inc eax
push ecx
mov dword [ebp + 8], eax
mov edx, eax
mov eax, dword [ebp - 0x4c]
sub edx, eax
push edx
push eax
push esi
call dword [sym.imp.GDI32.dll_GetTextExtentPoint32A]
mov eax, dword [ebp - 0x64]
mov edx, dword [ebp + 0xc]
mov ecx, eax
sub eax, edx
mov edx, dword [ebx + 0x9c]
inc edi
mov dword [ebp + 0xc], ecx
mov dword [edx + edi*4 - 4], eax
mov eax, dword [ebx + 0x10]
cmp edi, eax
jl 0x404a1c
mov eax, dword [ebp - 0x4c]
push eax
call fcn.00406d40
add esp, 4
mov ecx, dword [ebp - 0x1c]
mov edi, dword [ebp - 0x50]
mov edx, dword [ebx + 0x88]
mov eax, dword [ebp - 0x88]
push ecx
mov ecx, dword [edi]
sub edx, ecx
mov ecx, dword [ebp - 0x84]
sub edx, eax
mov eax, dword [ebx + 0x9c]
sub edx, ecx
mov ecx, ebx
push edx
push eax
call fcn.00403dd0
mov ecx, ebx
call fcn.00402f70
mov dword [ebp - 0x34], eax
mov eax, dword [ebx + 0x78]
test eax, eax
je 0x404acd
mov ecx, dword [ebx + 0x9c]
push ecx
push edi
mov ecx, ebx
call fcn.00402ce0
mov dword [ebx + 0x78], 0
mov edi, dword [ebx + 0x20]
mov eax, dword [ebx + 0x64]
mov edx, dword [ebx + 0x8c]
cmp edi, eax
mov dword [ebp - 0x20], edx
jle 0x404ae3
lea edi, [eax - 1]
mov eax, dword [ebx + 0x60]
lea edx, [ebp - 0xb4]
push edx
mov ecx, dword [eax + edi*4]
mov dword [ebp + 0xc], ecx
call fcn.00406a10
mov eax, dword [ebx + 0x8c]
mov edx, dword [ebx + 0x94]
mov ecx, dword [ebx + 0x3c]
add eax, edx
mov dword [ebp - 0xa0], eax
mov eax, dword [ebx + 0x5c]
shl eax, 6
push ecx
mov dword [ebp - 0xa8], eax
mov dword [ebp - 0xb4], eax
call fcn.00406d40
mov edx, dword [ebx + 0x64]
lea eax, [edx*4 + 4]
push eax
call fcn.00406d30
mov ecx, dword [ebx + 0x64]
mov dword [ebx + 0x3c], eax
add esp, 0xc
xor eax, eax
test ecx, ecx
jl 0x404b59
mov ecx, dword [ebx + 0x3c]
inc eax
mov dword [ecx + eax*4 - 4], 0
mov ecx, dword [ebx + 0x64]
cmp eax, ecx
jle 0x404b46
mov eax, dword [ebp - 0x34]
mov edx, dword [ebp - 0x8c]
dec eax
mov dword [ebp - 0x34], eax
js 0x405272
lea eax, [edi*4]
inc edi
mov dword [ebp - 0xd8], eax
mov dword [ebp - 0x30], edi
mov ecx, edi
jmp 0x404b8a
mov ecx, dword [ebp - 0x30]
mov edx, dword [ebp - 0xd4]
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x5c]
add eax, edi
mov dword [ebp - 0xc], eax
mov dword [ebp - 0x4c], eax
mov eax, dword [ebx + 0x64]
cmp eax, ecx
jl 0x404ba1
mov eax, ecx
mov ecx, dword [ebx + 0x60]
mov dword [ebp - 0xd4], 0
mov eax, dword [ecx + eax*4]
mov ecx, dword [ebp - 0x50]
mov dword [ebp - 0x40], eax
mov edi, dword [ecx]
mov ecx, dword [ebp - 0x84]
add edi, edx
add edi, ecx
mov ecx, dword [ebp + 0xc]
sub eax, ecx
je 0x404bf4
lea edx, [eax + ecx]
mov ecx, dword [ebp - 0x38]
mov cx, word [ecx + edx*2 - 2]
cmp cx, 0xd
je 0x404be1
cmp cx, 0xa
jne 0x404be2
dec eax
cmp cx, 0xd
jne 0x404bf4
mov edx, dword [ebp - 0x8c]
mov dword [ebp - 0xd4], edx
mov ecx, dword [ebx + 0x1c]
cmp ecx, eax
jle 0x404c04
mov dword [ebp - 0x2c], 0
jmp 0x404c11
sub eax, ecx
mov dword [ebp - 0x2c], eax
mov eax, dword [ebp + 0xc]
add eax, ecx
mov dword [ebp + 0xc], eax
mov eax, dword [ebp - 0x2c]
lea ecx, [eax*4 + 4]
push ecx
call fcn.00406d30
mov ecx, dword [ebp - 0x2c]
add esp, 4
xor edx, edx
mov dword [ebp + 8], eax
test ecx, ecx
mov dword [ebp - 0x14], edx
jle 0x404c97
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 8], eax
shl ecx, 2
mov dword [ebp - 4], ecx
mov eax, dword [ebp - 8]
mov dword [eax], edi
mov ecx, dword [ebx + 0x9c]
mov eax, dword [ebp - 4]
mov eax, dword [eax + ecx]
mov cl, byte [ebx + 0x54]
test cl, 0x40
mov dword [ebp - 0x18], eax
jne 0x404c75
mov ecx, dword [ebx + 0x88]
mov edx, dword [ebp - 0x88]
add eax, edi
sub ecx, edx
mov edx, dword [ebp - 0x14]
cmp eax, ecx
jg 0x404c97
mov eax, dword [ebp - 0x18]
mov ecx, dword [ebp - 8]
add edi, eax
mov eax, 4
inc edx
add ecx, eax
mov dword [ebp - 0x14], edx
mov dword [ebp - 8], ecx
mov ecx, dword [ebp - 4]
add ecx, eax
mov eax, dword [ebp - 0x2c]
cmp edx, eax
mov dword [ebp - 4], ecx
jl 0x404c3f
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2c], edx
mov dword [eax + edx*4], edi
mov eax, dword [ebx + 0x80]
dec eax
je 0x404cc4
dec eax
jne 0x404cee
mov eax, dword [ebp - 0x50]
mov ecx, dword [ebx + 0x88]
sub ecx, dword [eax]
mov eax, dword [ebp + 8]
sub ecx, edi
mov edi, dword [eax]
add ecx, edi
sar ecx, 1
jmp 0x404cd8
mov eax, dword [ebp - 0x50]
mov ecx, dword [ebx + 0x88]
sub ecx, dword [eax]
mov eax, dword [ebp + 8]
sub ecx, edi
mov edi, dword [eax]
add ecx, edi
test ecx, ecx
je 0x404cee
test edx, edx
jl 0x404cee
mov eax, dword [ebp + 8]
lea edi, [edx + 1]
add dword [eax], ecx
add eax, 4
dec edi
jne 0x404ce6
mov eax, dword [ebp + 8]
mov ecx, dword [ebx + 0x3c]
mov edi, dword [eax]
mov eax, dword [ebp - 0xd8]
mov dword [ecx + eax], edi
mov edi, dword [ebp - 0x30]
mov ecx, dword [ebx + 0x14]
inc edi
mov dword [ebp - 0x30], edi
mov edi, dword [ebx + 0x18]
add eax, 4
cmp ecx, edi
mov dword [ebp - 0xd8], eax
jge 0x404d1f
mov eax, ecx
mov ecx, edi
jmp 0x404d21
mov eax, edi
mov edi, dword [ebp + 0xc]
sub ecx, edi
sub eax, edi
cmp ecx, edx
mov dword [ebp - 4], eax
mov dword [ebp - 8], ecx
jle 0x404d3e
mov edi, dword [ebx + 0x98]
add edi, dword [ebp - 0x20]
mov dword [ebp - 0x4c], edi
cmp eax, edx
mov edi, eax
jl 0x404d46
mov edi, edx
test edi, edi
jge 0x404d53
mov dword [ebp - 4], 0
jmp 0x404d5a
cmp eax, edx
jl 0x404d5a
mov dword [ebp - 4], edx
cmp ecx, edx
mov eax, ecx
jl 0x404d62
mov eax, edx
xor edi, edi
cmp eax, edi
jge 0x404d6d
mov dword [ebp - 8], edi
jmp 0x404d74
cmp ecx, edx
jl 0x404d74
mov dword [ebp - 8], edx
cmp dword [ebp + 0x10], edi
je 0x404f41
mov eax, dword [ebp - 0x2c]
mov dword [ebp - 0x14], edi
cmp eax, edi
jle 0x404ee4
mov ecx, dword [ebp + 8]
mov edx, dword [ebp - 0x94]
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x1c], ecx
lea ecx, [edx + eax*2]
mov dword [ebp - 0x28], ecx
mov edx, dword [ebp - 0x28]
mov di, word [edx]
cmp di, 0xffff
je 0x404ec0
mov eax, dword [ebp - 0x1c]
lea edx, [ebp - 0x1ac]
push edx
mov ecx, dword [eax]
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0xa4], ecx
lea ecx, [ebp - 0xb4]
push eax
push ecx
call fcn.00406520
mov edx, dword [ebp - 0x58]
add esp, 0xc
test byte [edx + 0x2a], 8
mov eax, edx
mov eax, dword [eax + 0xc]
je 0x404e0d
and edi, 0xffff
xor ecx, ecx
xor edx, edx
mov ch, byte [eax + edi*4 + 3]
mov dl, byte [eax + edi*4 + 1]
mov cl, byte [eax + edi*4 + 2]
lea edi, [eax + edi*4]
shl ecx, 8
or ecx, edx
xor edx, edx
mov dl, byte [edi]
shl ecx, 8
or ecx, edx
jmp 0x404e1e
and edi, 0xffff
xor ecx, ecx
mov ch, byte [eax + edi*2 + 1]
lea edi, [eax + edi*2]
mov cl, byte [edi]
lea edx, [ebp - 0x1ac]
push edx
push ecx
push eax
mov eax, dword [ebp - 0x90]
push eax
lea ecx, [ebp - 0xf7c]
call fcn.0041b480
mov edx, dword [ebx + 0x6c]
mov eax, dword [ebp - 0xf10]
mov ecx, 1
mov dword [ebp - 0x2c8], edx
mov dword [ebp - 0x2e0], ecx
mov dword [eax], 0
mov edx, dword [ebp - 0xf0c]
mov dword [edx], 0
mov eax, dword [ebp - 0xf0c]
mov edx, dword [ebp - 4]
mov dword [eax + 4], 0
mov eax, dword [ebp - 0x14]
cmp eax, edx
jl 0x404e8f
cmp eax, dword [ebp - 8]
jge 0x404e8f
mov edx, dword [ebp - 0xf10]
mov eax, dword [ebp - 0x98]
jmp 0x404e98
mov edx, dword [ebp - 0xf10]
mov eax, dword [ebp - 0x10]
mov dword [edx + 4], eax
mov dword [ebp - 0xf14], ecx
mov ecx, dword [ebx + 0x6c]
add ecx, 0x4c
push ecx
push 0
lea ecx, [ebp - 0xf7c]
call fcn.004187c0
lea ecx, [ebp - 0xf7c]
call fcn.0041b530
mov eax, dword [ebp - 0x14]
mov edi, dword [ebp - 0x28]
mov edx, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x2c]
inc eax
add edi, 2
add edx, 4
cmp eax, ecx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x1c], edx
jl 0x404da0
mov edx, dword [ebp - 4]
mov ecx, dword [ebp - 8]
cmp edx, ecx
je 0x40512c
mov eax, dword [ebp + 8]
push 0
mov edx, dword [eax + edx*4]
mov eax, dword [eax + ecx*4]
mov ecx, dword [ebp - 0x4c]
mov dword [ebp - 0x144], edx
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x140], eax
mov eax, dword [ebx + 0x6c]
mov dword [ebp - 0x13c], edx
mov dword [ebp - 0x138], ecx
mov ecx, dword [ebp - 0x44]
lea edx, [eax + 0x7c]
mov eax, dword [eax]
push edx
mov edx, dword [ebp - 0x54]
push eax
push ecx
lea eax, [ebp - 0x144]
push edx
push eax
call fcn.0041ad30
add esp, 0x18
jmp 0x40512c
mov eax, dword [ebx + 0x14]
mov ecx, dword [ebx + 0x18]
cmp eax, ecx
jne 0x404f9e
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp - 0x38]
mov eax, dword [ebp + 0xc]
push ecx
push 0
lea ecx, [edx + eax*2]
push ecx
mov ecx, ebx
call fcn.00402a20
mov edx, eax
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 0
push ecx
push edx
push eax
push eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x18], edx
mov edx, dword [ebp - 0xa0]
mov ecx, dword [eax]
push edx
push ecx
push esi
call dword [sym.imp.GDI32.dll_ExtTextOutA]
mov edx, dword [ebp - 0x18]
push edx
call fcn.00406d40
add esp, 4
jmp 0x40512c
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 4]
lea eax, [eax + ecx*2]
push edx
push 0
push eax
mov ecx, ebx
mov dword [ebp - 0x28], eax
call fcn.00402a20
mov edi, dword [ebp - 8]
mov edx, dword [ebp - 0x28]
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 4]
mov ecx, edi
sub ecx, eax
push ecx
push eax
push edx
mov ecx, ebx
call fcn.00402a20
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x14]
sub eax, edi
mov ecx, ebx
push eax
mov eax, dword [ebp - 0x28]
push edi
push eax
call fcn.00402a20
mov edi, dword [ebp - 0x1c]
mov dword [ebp - 0x28], eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edi, dword [ebp + 8]
mov edx, dword [ebp - 0xa0]
not ecx
dec ecx
push 0
push ecx
mov ecx, dword [ebp - 0x1c]
push ecx
push eax
push eax
mov eax, dword [edi]
push edx
push eax
push esi
call dword [sym.imp.GDI32.dll_ExtTextOutA]
push 0xffffff
push esi
call dword [sym.imp.GDI32.dll_SetTextColor]
push esi
call dword [sym.imp.GDI32.dll_GetBkMode]
push 1
push esi
mov dword [ebp - 0x14], eax
call dword [sym.imp.GDI32.dll_SetBkMode]
push esi
call dword [sym.imp.GDI32.dll_GetBkColor]
push 0
push esi
mov dword [ebp - 0xf4], eax
call dword [sym.imp.GDI32.dll_SetBkColor]
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 8]
push 0
push 0
mov edx, dword [edi + ecx*4]
mov ecx, dword [edi + eax*4]
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x14c], ecx
mov dword [ebp - 0x154], edx
mov edx, dword [ebp - 0x20]
lea ecx, [ebp - 0x154]
push 0
push ecx
mov dword [ebp - 0x150], edx
mov dword [ebp - 0x148], eax
push 2
push 0
push 0
push esi
call dword [sym.imp.GDI32.dll_ExtTextOutA]
mov edx, dword [ebp - 0x18]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 0
push ecx
mov ecx, dword [ebp - 4]
push edx
mov edx, dword [ebp - 0xa0]
push eax
push eax
mov eax, dword [ebp + 8]
push edx
mov edx, dword [eax + ecx*4]
push edx
push esi
call dword [sym.imp.GDI32.dll_ExtTextOutA]
mov eax, dword [ebp - 0x98]
push eax
push esi
call dword [sym.imp.GDI32.dll_SetTextColor]
mov ecx, dword [ebp - 0x14]
push ecx
push esi
call dword [sym.imp.GDI32.dll_SetBkMode]
mov edx, dword [ebp - 0xf4]
push edx
push esi
call dword [sym.imp.GDI32.dll_SetBkColor]
mov edx, dword [ebp - 0x28]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
push 0
push ecx
mov ecx, dword [ebp + 8]
push edx
mov edx, dword [ebp - 8]
push eax
push eax
mov eax, dword [ebp - 0xa0]
push eax
mov eax, dword [ecx + edx*4]
push eax
push esi
call dword [sym.imp.GDI32.dll_ExtTextOutA]
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.00406d40
mov edx, dword [ebp - 0x18]
push edx
call fcn.00406d40
mov eax, dword [ebp - 0x28]
push eax
call fcn.00406d40
add esp, 0xc
mov eax, dword [ebp - 0x9c]
test eax, eax
je 0x40522a
mov edx, dword [ebx + 0x18]
mov ecx, dword [ebp + 0xc]
mov eax, edx
sub eax, ecx
mov ecx, dword [ebp - 0x2c]
js 0x405154
cmp eax, ecx
mov dword [ebp - 0x18], 1
jl 0x40515b
mov dword [ebp - 0x18], 0
cmp eax, ecx
jne 0x405181
mov edi, dword [ebx + 0x68]
test edi, edi
jne 0x40518c
mov edi, dword [ebx + 0x10]
dec edi
cmp edx, edi
jge 0x40518c
test ecx, ecx
je 0x40518c
mov edx, dword [ebp + 0xc]
add ecx, edx
mov edx, dword [ebp - 0x38]
cmp word [edx + ecx*2], 0xd
je 0x40518c
mov ecx, dword [ebp - 0x18]
test ecx, ecx
je 0x40522a
mov ecx, dword [ebp + 8]
mov edi, dword [ecx + eax*4]
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x4051d9
mov edx, dword [ebp - 0x48]
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 0xc]
push edx
mov edx, dword [ebp - 0x20]
push eax
mov eax, dword [ebp - 0x54]
push ecx
mov ecx, dword [ebx + 0x6c]
push edx
push edi
push eax
push ecx
call fcn.00404010
mov edx, dword [ebp - 0x20]
lea eax, [ebp - 0x64]
mov dword [ebp - 0x60], edx
lea ecx, [ebp - 0x64]
push eax
lea edx, [ebp - 0xf0]
push ecx
push edx
mov dword [ebp - 0x64], edi
call fcn.004062a0
add esp, 0x28
jmp 0x4051fc
mov eax, dword [ebp - 0x20]
push 0
push eax
push edi
push esi
call dword [sym.imp.GDI32.dll_MoveToEx]
mov ecx, dword [ebp - 0xc]
push ecx
push edi
push esi
call dword [sym.imp.GDI32.dll_LineTo]
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x64], edi
mov dword [ebp - 0x60], edx
mov ecx, dword [ebp - 0x60]
mov edx, dword [ebp - 0x64]
lea eax, [ebp - 0x134]
mov dword [ebp - 0x9c], 0
push eax
mov eax, dword [ebp - 0x90]
push ecx
push edx
mov ecx, dword [eax + 0xd8]
push ecx
call fcn.00402360
add esp, 0x10
mov edx, dword [ebp + 8]
push edx
call fcn.00406d40
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp + 0xc]
add esp, 4
cmp word [eax + ecx*2], 0
je 0x405272
mov edx, dword [ebp - 0x40]
mov eax, dword [ebx + 0x98]
mov ecx, dword [ebp - 0xa0]
mov dword [ebp + 0xc], edx
mov edx, dword [ebp - 0x20]
add ecx, eax
add edx, eax
mov eax, dword [ebp - 0x34]
dec eax
mov dword [ebp - 0x20], edx
mov dword [ebp - 0xa0], ecx
mov dword [ebp - 0x34], eax
jns 0x404b81
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x4052a7
mov eax, dword [ebp - 0xf8]
mov edi, dword [sym.imp.GDI32.dll_SelectObject]
push eax
push esi
call edi
mov ecx, dword [ebp - 0xd0]
push ecx
call dword [sym.imp.GDI32.dll_DeleteObject]
mov edx, dword [ebp - 0x44]
push edx
push esi
call edi
mov eax, dword [ebp - 0x10]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
test byte [ebx + 0x55], 0x10
jne 0x4052b4
mov ecx, ebx
call fcn.00402b40
mov dword [ebp - 0xc], 1
mov ebx, dword [ebp - 0x24]
mov ecx, dword [ebp - 0x94]
push ecx
call fcn.00406d40
mov edx, dword [ebp - 0x38]
push edx
call fcn.00406d40
mov eax, dword [ebp - 0x48]
push eax
call fcn.00406d40
mov eax, dword [ebp - 0xc]
add esp, 0xc
mov dword [ebx + 0x74], eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc