Function at 0x402860
Capabilities:
Hide graphical window

Disassembly:
push ecx
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
push ebx
push ebp
push esi
push edi
test eax, eax
mov dword [esp + 0x10], 0
jne 0x40288b
cmp ecx, 6
jae 0x40288b
mov al, byte [0x4247e8]
test al, al
je 0x402b7d
mov ebp, dword [esp + 0x18]
xor edi, edi
mov dword [esp + 0x20], edi
mov eax, 0x431624
cmp dword [eax], ebp
je 0x4028ab
add eax, 0x160
inc edi
cmp eax, 0x4323e4
jb 0x40289a
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x20], edi
test esi, esi
je 0x402afd
lea eax, [edi + edi*4]
lea ebx, [edi + eax*2]
shl ebx, 5
mov eax, dword [ebx + 0x43173c]
mov edx, dword [ebx + 0x431738]
mov dword [0x42e914], eax
mov al, byte [ebx + 0x431621]
test al, al
lea eax, [esi + ecx]
lea ecx, [esi + 0xff0]
mov dword [0x42e910], edx
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], ecx
je 0x40296f
cmp eax, ecx
jb 0x4028fc
mov eax, ecx
cmp esi, eax
jae 0x4029df
lea edx, [esi + 0x14]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, ecx
add edi, 4
and edi, 0xfffffffc
cmp edi, 0xfff
jbe 0x402929
mov byte [esi + 0x1013], al
mov ecx, dword [esi + 0x10]
mov eax, dword [esi + 8]
push edx
mov edx, dword [esi + 0xc]
push ecx
mov ecx, dword [esi + 4]
push edx
mov edx, dword [ebx + 0x431748]
push eax
mov eax, dword [esp + 0x30]
push ecx
mov ecx, dword [esi]
add edx, ecx
push edx
push eax
push ebp
call fcn.0040d620
mov ecx, dword [esp + 0x30]
add esp, 0x20
or ecx, eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x1c]
lea esi, [esi + edi + 0x14]
mov edi, dword [esp + 0x20]
jmp 0x4028f6
cmp eax, ecx
jb 0x402975
mov eax, ecx
cmp esi, eax
jae 0x4029df
lea edx, [esi + 0x14]
or ecx, 0xffffffff
mov edi, edx
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
mov edi, ecx
inc edi
cmp edi, 0xfff
jbe 0x402999
mov byte [esi + 0x1013], al
mov ecx, dword [esi + 0x10]
mov eax, dword [esi + 8]
push edx
mov edx, dword [esi + 0xc]
push ecx
mov ecx, dword [esi + 4]
push edx
mov edx, dword [ebx + 0x431748]
push eax
mov eax, dword [esp + 0x30]
push ecx
mov ecx, dword [esi]
add edx, ecx
push edx
push eax
push ebp
call fcn.0040d620
mov ecx, dword [esp + 0x30]
add esp, 0x20
or ecx, eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x10], ecx
mov ecx, dword [esp + 0x1c]
lea esi, [esi + edi + 0x14]
mov edi, dword [esp + 0x20]
jmp 0x40296f
cmp dword [0x431624], ebp
jne 0x402a49
mov esi, dword [0x4313d0]
test esi, esi
je 0x402a38
mov edx, dword [esi + 0x14]
mov eax, dword [esi + 0x10]
lea ecx, [esi + 0x18]
push ecx
mov ecx, dword [esi + 0xc]
push edx
mov edx, dword [esi + 8]
push eax
mov eax, dword [esi + 4]
push ecx
mov ecx, dword [ebx + 0x431748]
add eax, ecx
push edx
push eax
push edi
push ebp
call fcn.0040d620
mov ecx, dword [esp + 0x30]
or ecx, eax
mov eax, esi
mov dword [0x4313d0], eax
mov esi, dword [esi]
push eax
mov dword [esp + 0x34], ecx
call fcn.00410acf
add esp, 0x24
test esi, esi
jne 0x4029f1
xor eax, eax
mov dword [0x4313d0], eax
mov dword [0x435800], eax
mov byte [0x4247e8], al
mov eax, dword [0x4247ec]
test eax, eax
je 0x402aa4
mov eax, dword [esp + 0x10]
test eax, eax
je 0x402aa4
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push 0
push 0xb
push ebp
call esi
mov ecx, dword [0x4247f0]
mov eax, dword [0x4247ec]
cmp ecx, eax
jb 0x402a99
push 0
push 0
push 0x1008
push ebp
call esi
mov eax, dword [0x4247f0]
mov ecx, dword [0x4247ec]
dec eax
cmp eax, ecx
mov dword [0x4247f0], eax
jae 0x402a78
push 0
push 1
push 0xb
push ebp
call esi
jmp 0x402aaa
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
mov al, byte [0x41d55d]
test al, al
je 0x402b03
mov eax, dword [esp + 0x10]
test eax, eax
je 0x402b03
mov eax, dword [0x4247f4]
lea edx, [eax + eax*4]
lea eax, [eax + edx*2]
shl eax, 5
cmp dword [eax + 0x431624], ebp
jne 0x402ae3
mov eax, dword [0x4247c8]
test eax, eax
je 0x402ae3
push 0
push eax
call dword [sym.imp.USER32.dll_ShowWindow]
push 0
push 0
push 0
push 0x1004
push ebp
call esi
dec eax
push eax
push 0x1013
push ebp
call esi
jmp 0x402b03
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [esp + 0x24]
test eax, eax
je 0x402b7d
mov al, byte [0x42d8e4]
mov ebx, dword [sym.imp.USER32.dll_SetCursor]
test al, al
jne 0x402b31
mov ecx, dword [0x42e900]
push ecx
call ebx
push 0
push 0
push 0xb
push ebp
mov dword [0x4313c0], eax
call esi
push 0
push 0
push 0x1009
push ebp
call esi
lea edx, [edi + edi*4]
mov dword [0x4247f0], 0
lea eax, [edi + edx*2]
shl eax, 5
mov byte [eax + 0x43174c], 1
mov al, byte [0x42d8e4]
test al, al
jne 0x402b7d
mov ecx, dword [0x4313c0]
push ecx
call ebx
push 0
push 1
push 0xb
push ebp
call esi
push 0
push 0
push ebp
call dword [sym.imp.USER32.dll_InvalidateRect]
pop edi
pop esi
pop ebp
pop ebx
pop ecx
ret