Function at 0x10012830
Capabilities:
Log keystrokes via polling

Disassembly:
mov eax, dword [esp + 8]
sub esp, 0xc4
cmp eax, 8
push ebx
push esi
push edi
push ebp
ja 0x1001285f
cmp eax, 7
jae 0x10012967
cmp eax, 1
je 0x100128ac
cmp eax, 2
je 0x10012947
jmp case.default.0x100128a5
cmp eax, 0x87
ja 0x1001287a
je 0x10012e76
cmp eax, 0xf
je 0x1001297e
jmp case.default.0x100128a5
cmp eax, 0x201
ja 0x10012897
je 0x10012fbb
cmp eax, 0x100
je 0x10012e80
jmp case.default.0x100128a5
sub eax, 0x805a
cmp eax, 0xb
ja case.default.0x100128a5
jmp dword [eax*4 + 0x10013758]
mov eax, dword [esp + 0xd8]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov eax, dword [esp + 0xd8]
push 0x20
push 4
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov eax, dword [esp + 0xd8]
push 0
push 0xc
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
push 0x14
push 0x20
call fcn.1002e710
add esp, 8
mov esi, eax
mov eax, dword [esp + 0xd8]
push esi
push 8
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov eax, dword [esp + 0xd8]
push 0x20
push esi
push eax
call fcn.10012720
mov eax, dword [esp + 0xe4]
add esp, 0xc
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push 8
push 0x805d
push eax
call esi
mov ecx, dword [esp + 0xd8]
push 1
push 0
push 0x8061
push ecx
call esi
xor eax, eax
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 8
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
push eax
call fcn.1002e7c0
add esp, 4
jmp case.default.0x100128a5
mov eax, dword [esp + 0xd8]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
jmp case.default.0x100128a5
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov ecx, dword [esp + 0xd8]
push 8
mov dword [esp + 0x48], eax
push ecx
call ebp
mov dword [esp + 0x14], eax
push 0xc
mov eax, dword [esp + 0xdc]
push eax
call ebp
and al, 1
lea ecx, [esp + 0x94]
mov edx, dword [esp + 0xd8]
push ecx
mov byte [esp + 0x17], al
push edx
call dword [sym.imp.USER32.dll_BeginPaint]
mov dword [esp + 0x2c], eax
test eax, eax
je 0x10012e59
lea eax, [esp + 0x80]
mov ecx, dword [esp + 0xd8]
push eax
mov esi, dword [sym.imp.USER32.dll_GetClientRect]
push ecx
call esi
lea ecx, [esp + 0x70]
mov eax, dword [esp + 0xd8]
push ecx
push eax
call esi
mov esi, dword [esp + 0x2c]
push esi
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
mov dword [esp + 0x18], eax
test eax, eax
je 0x10012a82
mov eax, dword [esp + 0x7c]
mov ecx, dword [esp + 0x2c]
sub eax, dword [esp + 0x74]
push eax
mov eax, dword [esp + 0x7c]
sub eax, dword [esp + 0x74]
push eax
push ecx
call dword [sym.imp.GDI32.dll_CreateCompatibleBitmap]
mov dword [esp + 0x30], eax
test eax, eax
je 0x10012a64
mov ecx, dword [esp + 0x18]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x6c], eax
test eax, eax
je 0x10012a51
mov esi, dword [esp + 0x18]
jmp 0x10012a64
mov eax, dword [esp + 0x30]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov dword [esp + 0x30], 0
cmp dword [esp + 0x30], 0
jne 0x10012a82
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.GDI32.dll_DeleteDC]
mov dword [esp + 0x18], 0
mov esi, dword [esp + 0x2c]
push 0x14
call dword [sym.imp.USER32.dll_GetSysColor]
push eax
mov ebx, dword [sym.imp.GDI32.dll_CreateSolidBrush]
call ebx
push eax
mov edi, eax
lea eax, [esp + 0x84]
mov ebp, dword [sym.imp.USER32.dll_FillRect]
push eax
push esi
call ebp
push edi
call dword [sym.imp.GDI32.dll_DeleteObject]
push 0x12
call dword [sym.imp.USER32.dll_GetSysColor]
push eax
call ebx
push eax
mov edi, eax
lea eax, [esp + 0x84]
push eax
push esi
call dword [sym.imp.USER32.dll_FrameRect]
push edi
call dword [sym.imp.GDI32.dll_DeleteObject]
mov ecx, dword [esp + 0x44]
mov dword [esp + 0x3c], ecx
cmp ecx, 0x20
jge 0x10012ae7
mov dword [esp + 0x3c], 0x20
mov eax, dword [esp + 0x3c]
cdq
sub eax, edx
mov edx, dword [esp + 0x14]
sar eax, 1
mov ebx, dword [edx]
mov dword [esp + 0x58], eax
shl eax, 2
lea ecx, [eax + eax*4]
mov eax, dword [ecx + edx + 8]
add eax, ebx
cdq
sub eax, edx
sar eax, 1
sub ebx, eax
mov edi, eax
sub ebx, 4
add edi, 2
mov eax, dword [esp + 0x3c]
cdq
and edx, 3
add eax, edx
mov edx, dword [esp + 0x14]
sar eax, 2
lea ecx, [eax*4]
shl eax, 2
lea ebp, [ecx + ecx*4]
mov ecx, dword [ebp + edx + 0xc]
lea edx, [eax + eax*2]
mov eax, dword [esp + 0x14]
lea ebp, [edx + edx*4]
add ecx, dword [ebp + eax + 4]
mov dword [esp + 0x40], 0
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
add eax, 2
mov dword [esp + 0x24], eax
cmp dword [esp + 0x40], 0
jne 0x10012b69
push 0xf
jmp 0x10012b6b
push 0x12
call dword [sym.imp.USER32.dll_GetSysColor]
push eax
push 2
push 0
call dword [sym.imp.GDI32.dll_CreatePen]
mov dword [esp + 0x68], eax
push eax
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x38], 0
cmp dword [esp + 0x3c], 0
mov dword [esp + 0x90], eax
mov eax, dword [esp + 0x14]
mov dword [esp + 0x34], eax
jle 0x10012d45
mov eax, dword [esp + 0x34]
mov eax, dword [eax + 0x10]
and eax, 0x1001
cmp eax, 1
jne 0x10012d2e
fild dword [esp + 0x38]
mov dword [esp + 0x28], ebx
fmul qword [0x1003b078]
fidiv dword [esp + 0x58]
fst qword [esp + 0x48]
fcos
fstp qword [esp + 0x1c]
fld qword [esp + 0x48]
fsin
fstp qword [esp + 0x50]
fild dword [esp + 0x28]
fld qword [esp + 0x1c]
fmul st(1)
call fcn.1002dbb0
fmul qword [esp + 0x50]
add eax, edi
mov ebp, dword [esp + 0x24]
mov dword [esp + 0x64], eax
call fcn.1002dbb0
sub ebp, eax
cmp byte [esp + 0x13], 0
mov dword [esp + 0x60], ebp
je 0x10012c3f
mov eax, ebx
cdq
sub eax, edx
sar eax, 1
mov dword [esp + 0x28], eax
fild dword [esp + 0x28]
fld qword [esp + 0x1c]
fmul st(1)
call fcn.1002dbb0
fmul qword [esp + 0x50]
add eax, edi
mov ebp, dword [esp + 0x24]
mov dword [esp + 0x28], eax
jmp 0x10012c62
fld qword [esp + 0x1c]
fmul qword [0x1003b080]
call fcn.1002dbb0
fld qword [esp + 0x50]
fmul qword [0x1003b080]
add eax, edi
mov ebp, dword [esp + 0x24]
mov dword [esp + 0x28], eax
sub ebx, 8
call fcn.1002dbb0
fld qword [esp + 0x48]
fadd qword [0x1003b088]
sub ebp, eax
mov dword [esp + 0x1c], ebx
fild dword [esp + 0x1c]
fld st(1)
fcos
add ebx, 8
fmul st(1)
call fcn.1002dbb0
add eax, edi
mov ecx, dword [esp + 0x24]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x5c], ecx
fxch st(1)
fsin
fmul st(1)
call fcn.1002dbb0
fld qword [esp + 0x48]
fsub qword [0x1003b088]
sub dword [esp + 0x5c], eax
fld st(0)
fcos
fmul st(2)
call fcn.1002dbb0
fsin
mov ecx, dword [esp + 0x24]
add eax, edi
mov dword [esp + 0x48], ecx
mov dword [esp + 0x50], eax
fmulp st(1)
call fcn.1002dbb0
mov ecx, dword [esp + 0x28]
push 0
sub dword [esp + 0x4c], eax
push ebp
push ecx
push esi
call dword [sym.imp.GDI32.dll_MoveToEx]
mov eax, dword [esp + 0x60]
mov ecx, dword [esp + 0x64]
push eax
push ecx
push esi
call dword [sym.imp.GDI32.dll_LineTo]
mov ecx, dword [esp + 0x5c]
mov edx, dword [esp + 0x1c]
push ecx
push edx
push esi
call dword [sym.imp.GDI32.dll_LineTo]
mov ecx, dword [esp + 0x60]
push 0
mov edx, dword [esp + 0x68]
push ecx
push edx
push esi
call dword [sym.imp.GDI32.dll_MoveToEx]
mov ecx, dword [esp + 0x48]
mov edx, dword [esp + 0x50]
push ecx
push edx
push esi
call dword [sym.imp.GDI32.dll_LineTo]
add dword [esp + 0x34], 0x14
inc dword [esp + 0x38]
mov eax, dword [esp + 0x38]
cmp dword [esp + 0x3c], eax
jg 0x10012baa
sub edi, 2
mov eax, dword [esp + 0x90]
sub dword [esp + 0x24], 2
push eax
push esi
call dword [sym.imp.GDI32.dll_SelectObject]
mov eax, dword [esp + 0x68]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
inc dword [esp + 0x40]
cmp dword [esp + 0x40], 2
jl 0x10012b5e
mov eax, dword [esp + 0x44]
mov edx, dword [esp + 0x14]
push eax
mov ecx, 0x16
mov eax, dword [esp + 0x90]
push edx
cdq
idiv ecx
push eax
push esi
call fcn.100137a0
add esp, 0x10
call dword [sym.imp.USER32.dll_GetFocus]
cmp eax, dword [esp + 0xd8]
jne 0x10012de5
lea eax, [edi - 1]
add edi, 5
mov dword [esp + 0x80], eax
mov dword [esp + 0x88], edi
mov eax, dword [esp + 0x24]
lea ecx, [esp + 0x80]
dec eax
push ecx
mov dword [esp + 0x88], eax
push esi
mov eax, dword [esp + 0x2c]
add eax, 5
mov dword [esp + 0x94], eax
call dword [sym.imp.USER32.dll_DrawFocusRect]
cmp dword [esp + 0x18], 0
je 0x10012e59
mov eax, dword [esp + 0x18]
push 0xcc0020
push 0
push 0
push eax
mov eax, dword [esp + 0x8c]
mov ecx, dword [esp + 0x84]
sub eax, dword [esp + 0x84]
mov edx, dword [esp + 0x80]
push eax
mov eax, dword [esp + 0x8c]
sub eax, dword [esp + 0x84]
push eax
push ecx
mov eax, dword [esp + 0x48]
push edx
push eax
call dword [sym.imp.GDI32.dll_BitBlt]
mov ecx, dword [esp + 0x6c]
mov eax, dword [esp + 0x18]
push ecx
push eax
call dword [sym.imp.GDI32.dll_SelectObject]
mov ecx, dword [esp + 0x30]
push ecx
call dword [sym.imp.GDI32.dll_DeleteObject]
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.GDI32.dll_DeleteDC]
lea eax, [esp + 0x94]
mov ecx, dword [esp + 0xd8]
push eax
push ecx
call dword [sym.imp.USER32.dll_EndPaint]
xor eax, eax
jmp 0x10013748
mov eax, 1
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov ebx, eax
push 0xc
mov eax, dword [esp + 0xdc]
push eax
call ebp
test al, 1
jne case.default.0x100128a5
mov esi, 1
cmp ebx, 0x20
jge 0x10012ec1
mov eax, 0x20
cdq
idiv ebx
mov esi, eax
mov ebx, 0x20
mov eax, dword [esp + 0xd8]
push 0
push eax
call ebp
mov ebp, eax
mov edi, dword [esp + 0xe0]
lea eax, [edi - 0x25]
cmp eax, 3
ja case.default.0x10012ede
jmp dword [eax*4 + 0x10013788]
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jge 0x10012f54
mov eax, ebx
cdq
and edx, 3
add eax, edx
sar eax, 2
lea ebp, [eax*2]
jmp case.default.0x10012ede
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jge 0x10012f54
mov eax, ebx
cdq
and edx, 3
add eax, edx
sar eax, 2
mov ebp, eax
jmp case.default.0x10012ede
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jge 0x10012f33
xor ebp, ebp
jmp case.default.0x10012ede
sub ebp, esi
jmp case.default.0x10012ede
push 0x11
call dword [sym.imp.USER32.dll_GetKeyState]
test ax, ax
jge 0x10012f54
mov eax, ebx
cdq
and edx, 3
add eax, edx
sar eax, 2
lea ebp, [eax + eax*2]
jmp case.default.0x10012ede
add ebp, esi
cmp ebx, ebp
jg 0x10012f5e
sub ebp, ebx
jmp 0x10012f64
test ebp, ebp
jge 0x10012f64
add ebp, ebx
mov eax, dword [esp + 0xd8]
push 0
push ebp
push 0x805f
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov ecx, dword [esp + 0xd8]
push ecx
call dword [sym.imp.USER32.dll_GetParent]
mov esi, eax
test esi, esi
je 0x10013729
shl ebp, 0x10
mov eax, dword [esp + 0xd8]
push eax
push eax
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
movzx eax, ax
or eax, ebp
push eax
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
jmp 0x10013729
call dword [sym.imp.USER32.dll_GetFocus]
cmp eax, dword [esp + 0xd8]
je 0x10012fd8
mov eax, dword [esp + 0xd8]
push eax
call dword [sym.imp.USER32.dll_SetFocus]
mov eax, dword [esp + 0xd8]
push 0xc
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
and al, 1
push 4
mov bl, al
mov ecx, dword [esp + 0xdc]
push ecx
call ebp
mov esi, eax
push 8
mov eax, dword [esp + 0xdc]
push eax
call ebp
movsx ecx, word [esp + 0xe4]
mov dword [esp + 0x1c], ecx
push esi
mov ecx, dword [esp + 0xe8]
push eax
shr ecx, 0x10
mov eax, dword [esp + 0x24]
movsx edx, cx
push edx
push eax
call fcn.10013970
add esp, 0x10
mov edi, eax
cmp edi, 0xffffffff
je 0x100130b5
push 0
test bl, bl
push edi
je 0x1001306a
mov eax, dword [esp + 0xe0]
push 0x8060
push eax
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
call esi
xor eax, 1
mov ecx, dword [esp + 0xd8]
push eax
push edi
push 0x8061
push ecx
call esi
jmp 0x1001307d
mov eax, dword [esp + 0xe0]
push 0x805f
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [esp + 0xd8]
push eax
call dword [sym.imp.USER32.dll_GetParent]
mov esi, eax
test esi, esi
je 0x100130b5
shl edi, 0x10
mov eax, dword [esp + 0xd8]
push eax
push eax
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
movzx eax, ax
or eax, edi
push eax
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
xor eax, eax
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 0xc
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 0xc
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov esi, eax
mov ecx, dword [esp + 0xd8]
mov eax, dword [esp + 0xe4]
push eax
push 0xc
push ecx
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov eax, esi
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov ebx, eax
push 0xc
mov eax, dword [esp + 0xdc]
push eax
call ebp
and al, 1
mov edi, dword [esp + 0xe0]
mov byte [esp + 0x13], al
cmp edi, 2
jge 0x10013154
mov edi, 2
cmp edi, 0x168
jle 0x10013161
mov edi, 0x168
cmp edi, 0x20
jge 0x1001317a
xor ecx, ecx
dec edi
je 0x10013173
sar edi, 1
inc ecx
test edi, edi
jne 0x1001316b
mov edi, 1
shl edi, cl
mov eax, dword [esp + 0xd8]
push 8
push eax
call ebp
mov dword [esp + 0x14], eax
cmp edi, 0x20
jg 0x10013198
cmp ebx, 0x20
jle 0x10013220
cmp edi, 0x20
mov eax, edi
jae 0x100131a4
mov eax, 0x20
shl eax, 2
mov edx, dword [esp + 0x14]
lea ecx, [eax + eax*4]
push ecx
push edx
call fcn.1002e890
add esp, 8
mov esi, eax
test esi, esi
jne 0x100131c5
mov eax, ebx
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push esi
mov dword [esp + 0x18], esi
push 8
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
cmp ebx, edi
jge 0x10013220
lea eax, [ebx*4]
lea ecx, [eax + eax*4]
add esi, ecx
test ebx, ebx
jle 0x10013203
mov eax, ebx
test byte [esi + 0x11], 0x10
je 0x100131fd
mov dword [esi + 0x10], 0
add esi, 0x14
dec eax
jne 0x100131f0
cmp ebx, 0x20
jg 0x1001320d
mov ebx, 0x20
cmp ebx, edi
jge 0x10013220
mov ecx, edi
xor eax, eax
sub ecx, ebx
mov dword [esi + 0x10], eax
add esi, 0x14
dec ecx
jne 0x10013217
cmp edi, 0x20
jg 0x1001325d
mov esi, dword [esp + 0x14]
mov eax, 0x20
cdq
idiv edi
mov ecx, eax
xor ebx, ebx
mov eax, ebx
cdq
idiv ecx
test edx, edx
je 0x10013247
mov dword [esi + 0x10], 0x1000
jmp 0x10013254
test byte [esi + 0x11], 0x10
je 0x10013254
mov dword [esi + 0x10], 0
inc ebx
add esi, 0x14
cmp ebx, 0x20
jl 0x10013235
mov eax, dword [esp + 0xd8]
push edi
push 4
push eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
cmp edi, 0x20
mov eax, edi
jg 0x1001327a
mov eax, 0x20
mov ecx, dword [esp + 0x14]
push eax
mov eax, dword [esp + 0xdc]
push ecx
push eax
call fcn.10012720
add esp, 0xc
cmp byte [esp + 0x13], 0
jne 0x100132cf
mov eax, dword [esp + 0xd8]
push 0
push eax
call ebp
cmp edi, eax
jl 0x100132b8
shl eax, 2
mov ecx, dword [esp + 0x14]
lea edx, [eax + eax*4]
test byte [edx + ecx + 0x10], 1
jne 0x100132cf
mov eax, dword [esp + 0xd8]
push 0
push 0
push 0x805f
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [esp + 0xd8]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
mov eax, edi
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 0xc
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
test al, 1
je 0x10013305
xor eax, eax
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 0
push eax
call ebp
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
cmp eax, 0x20
jge 0x10013332
mov eax, 0x20
mov ecx, eax
mov edi, dword [esp + 0xe0]
cmp edi, ecx
jb 0x10013347
mov eax, edi
sub edx, edx
div ecx
mov edi, edx
mov eax, dword [esp + 0xd8]
push 0xc
push eax
call ebp
mov eax, dword [esp + 0xd8]
push 1
push edi
push 0x8061
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
jmp 0x10013729
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
cmp eax, 0x20
mov ecx, eax
jge 0x1001338c
mov ecx, 0x20
mov edi, dword [esp + 0xe0]
cmp edi, ecx
jb 0x1001339f
mov eax, edi
sub edx, edx
div ecx
mov edi, edx
mov eax, dword [esp + 0xd8]
push 8
push eax
call ebp
test eax, eax
jne 0x100133b6
xor eax, eax
jmp 0x10013748
shl edi, 2
lea ecx, [edi + edi*4]
mov eax, dword [eax + ecx + 0x10]
test ah, 0x10
je 0x100133cc
xor eax, eax
jmp 0x10013748
and eax, 1
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov ebx, eax
test ebx, ebx
je case.default.0x100128a5
cmp ebx, 0x20
jge 0x1001341e
mov eax, 0x20
mov edi, dword [esp + 0xe0]
cdq
idiv ebx
mov ecx, eax
sub edx, edx
mov eax, edi
div ecx
test edx, edx
je 0x10013417
xor eax, eax
jmp 0x10013748
mov ebx, 0x20
jmp 0x10013425
mov edi, dword [esp + 0xe0]
cmp edi, ebx
jb 0x10013431
mov eax, edi
sub edx, edx
div ebx
mov edi, edx
mov eax, dword [esp + 0xd8]
push 0xc
push eax
call ebp
and al, 1
push 8
mov ecx, dword [esp + 0xdc]
mov byte [esp + 0x17], al
push ecx
call ebp
lea ecx, [edi*4]
mov dword [esp + 0x14], eax
lea eax, [ecx + ecx*4]
add eax, dword [esp + 0x14]
mov dword [esp + 0x34], eax
mov ecx, dword [eax + 0x10]
test ch, 0x10
je 0x10013474
xor eax, eax
jmp 0x10013748
mov eax, ecx
and eax, 1
cmp dword [esp + 0xe4], 1
sbb esi, esi
mov dword [esp + 0x38], eax
inc esi
cmp esi, eax
je 0x100134f7
cmp byte [esp + 0x13], 0
je 0x100134a1
and ecx, 0xfffffffe
mov eax, dword [esp + 0x34]
or ecx, esi
mov dword [eax + 0x10], ecx
jmp 0x100134e5
test esi, 1
je 0x100134e5
mov eax, dword [esp + 0xd8]
push 0
push eax
call ebp
cmp ebx, eax
jg 0x100134be
cdq
idiv ebx
mov eax, edx
shl eax, 2
mov ecx, dword [esp + 0x14]
push edi
push 0
lea edx, [eax + eax*4]
mov eax, dword [esp + 0xe0]
push eax
and dword [edx + ecx + 0x10], 0xfffffffe
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov ecx, dword [esp + 0x34]
or dword [ecx + 0x10], esi
mov eax, dword [esp + 0xd8]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
cmp dword [esp + 0x38], 1
sbb eax, eax
inc eax
jmp 0x10013748
xor esi, esi
push 4
mov eax, dword [esp + 0xdc]
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
push eax
call ebp
cmp eax, 0x20
jg 0x10013555
mov edi, 1
push 8
mov eax, dword [esp + 0xdc]
push eax
call ebp
test eax, eax
jne 0x10013539
xor eax, eax
jmp 0x10013748
mov edx, 0x20
mov ecx, dword [eax + 0x10]
test ch, 0x10
jne 0x1001354d
test cl, 1
je 0x1001354d
or esi, edi
add edi, edi
add eax, 0x14
dec edx
jne 0x1001353e
mov eax, esi
jmp 0x10013748
xor esi, esi
push 4
mov eax, dword [esp + 0xdc]
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
push eax
call ebp
cmp eax, 0x20
jg 0x100135eb
mov edi, 1
push 8
mov eax, dword [esp + 0xdc]
push eax
call ebp
test eax, eax
jne 0x10013591
xor eax, eax
jmp 0x10013748
mov ebx, 0x20
mov edx, dword [eax + 0x10]
test dh, 0x10
jne 0x100135ca
mov ebp, edx
and ebp, 1
je 0x100135a7
or esi, edi
mov ecx, edi
and ecx, dword [esp + 0xe4]
cmp ecx, 1
sbb ecx, ecx
inc ecx
cmp ecx, ebp
je 0x100135ca
mov dword [esp + 0x1c], 1
and edx, 0xfffffffe
or edx, ecx
mov dword [eax + 0x10], edx
add edi, edi
add eax, 0x14
dec ebx
jne 0x10013596
cmp dword [esp + 0x1c], 0
je 0x100135eb
mov eax, dword [esp + 0xd8]
push 0
push 0
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
mov eax, esi
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
cmp eax, 0x20
mov ecx, eax
jge 0x10013610
mov ecx, 0x20
mov edi, dword [esp + 0xe0]
cmp edi, ecx
jb 0x10013623
mov eax, edi
sub edx, edx
div ecx
mov edi, edx
mov eax, dword [esp + 0xd8]
push 8
push eax
call ebp
test eax, eax
jne 0x1001363a
xor eax, eax
jmp 0x10013748
shl edi, 2
lea ecx, [edi + edi*4]
mov eax, dword [eax + ecx + 0x10]
test ah, 0x10
je 0x10013650
xor eax, eax
jmp 0x10013748
and eax, 2
shr eax, 1
jmp 0x10013748
mov eax, dword [esp + 0xd8]
push 4
push eax
mov ebp, dword [sym.imp.USER32.dll_GetWindowLongA]
call ebp
mov ecx, eax
test ecx, ecx
je case.default.0x100128a5
cmp ecx, 0x20
jge 0x100136a5
mov eax, 0x20
mov edi, dword [esp + 0xe0]
cdq
idiv ecx
mov ecx, eax
sub edx, edx
mov eax, edi
div ecx
test edx, edx
je 0x1001369e
xor eax, eax
jmp 0x10013748
mov ecx, 0x20
jmp 0x100136ac
mov edi, dword [esp + 0xe0]
cmp edi, ecx
jb 0x100136b8
mov eax, edi
sub edx, edx
div ecx
mov edi, edx
mov eax, dword [esp + 0xd8]
push 0xc
shl edi, 2
push eax
call ebp
mov eax, dword [esp + 0xd8]
push 8
push eax
call ebp
lea ecx, [edi + edi*4]
add ecx, eax
mov edx, dword [ecx + 0x10]
test dh, 0x10
je 0x100136e4
xor eax, eax
jmp 0x10013748
mov esi, edx
mov eax, 0
and esi, 2
cmp dword [esp + 0xe4], 1
adc eax, 0xffffffff
and eax, 2
cmp eax, esi
je 0x1001371a
and edx, 0xfffffffd
push 0
or edx, eax
push 0
mov eax, dword [esp + 0xe0]
mov dword [ecx + 0x10], edx
push eax
call dword [sym.imp.USER32.dll_InvalidateRect]
cmp esi, 1
sbb eax, eax
inc eax
jmp 0x10013748
mov edi, dword [esp + 0xe0]
mov eax, dword [esp + 0xe4]
mov ecx, dword [esp + 0xdc]
mov edx, dword [esp + 0xd8]
push eax
push edi
push ecx
push edx
call dword [sym.imp.USER32.dll_DefWindowProcA]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0xc4
ret 0x10