Function at 0x40d0c0
Capabilities:
Accept command line arguments
Check for time delay via gettickcount
Log keystrokes via polling

Disassembly:
sub esp, 0x24
push ebx
push ebp
push esi
xor esi, esi
push edi
mov ebp, 0x280
mov ebx, 0x1e0
mov dword [0x41cf3c], esi
mov dword [0x41cf38], esi
mov dword [0x41ceb0], esi
mov dword [0x41ba90], esi
mov dword [0x41cea8], esi
call dword [sym.imp.KERNEL32.dll_GetCommandLineA]
push 0x104
push 0x41b988
push esi
mov dword [0x41cc94], eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
xor eax, eax
nop
mov cl, byte [eax + 0x41b988]
mov byte [eax + 0x41cc98], cl
inc eax
test cl, cl
jne 0x40d110
push 0x41cc98
call fcn.0040bfc0
mov dl, byte [0x4183d8]
mov ecx, 0x10
mov esi, str.HSPHED
mov edi, 0x41cf40
rep movsd dword es:[edi], dword [esi]
mov cl, byte [0x41cf40]
xor eax, eax
sub cl, 0x30
add esp, 4
cmp cl, dl
mov dword [esp + 0x14], eax
jne 0x40d15d
mov eax, 1
mov dl, byte [0x41cf41]
mov cl, byte [0x4183d9]
sub dl, 0x30
cmp dl, cl
jne 0x40d171
inc eax
mov cl, byte [0x41cf42]
mov dl, byte [0x4183da]
sub cl, 0x30
cmp cl, dl
jne 0x40d185
inc eax
mov dl, byte [0x41cf43]
mov cl, byte [0x4183db]
sub dl, 0x30
cmp dl, cl
jne 0x40d199
inc eax
mov dl, byte [0x41cf44]
mov ecx, dword [0x4183dc]
sub dl, 0x30
cmp dl, cl
jne 0x40d1ad
inc eax
mov dl, byte [0x41cf45]
sub dl, 0x30
cmp dl, ch
jne 0x40d1bb
inc eax
mov dl, byte [0x41cf46]
mov cx, word [str.NN_]
sub dl, 0x30
cmp dl, cl
jne 0x40d1d0
inc eax
mov dl, byte [0x41cf47]
sub dl, 0x30
cmp dl, ch
jne 0x40d1de
inc eax
test eax, eax
jne 0x40d30a
push 0x41cf49
call fcn.0040ec28
mov esi, eax
mov al, byte [0x41cf51]
add esi, 0x10000
add esp, 4
cmp al, 0x66
mov dword [esp + 0x10], esi
jne 0x40d210
inc dword [0x41ba90]
jmp 0x40d21a
cmp al, 0x73
jne 0x40d21a
inc dword [0x41cf3c]
mov eax, dword [esp + 0x40]
mov edx, 0x41bbb8
mov byte [0x41cda8], 0
sub edx, eax
lea esp, [esp]
mov cl, byte [eax]
mov byte [eax + edx], cl
inc eax
test cl, cl
jne 0x40d230
mov ecx, dword [0x41cf60]
movsx ebp, word [0x41cf54]
movsx ebx, word [0x41cf57]
xor eax, eax
mov al, byte [0x41cf5a]
push ecx
and eax, 1
mov dword [0x41d010], eax
movzx eax, word [0x41cf5d]
push eax
push esi
push 0x41b988
call fcn.00403750
mov dword [esp + 0x24], eax
xor eax, eax
mov al, byte [0x41cf5a]
add esp, 0x10
and eax, 2
test eax, eax
jne 0x40d293
push 0x41cc98
call fcn.0040f526
add esp, 4
cmp esi, 0xffffffff
jne 0x40d2a9
push esi
push esi
push 0
push str.data.dpm
call fcn.00403750
add esp, 0x10
call fcn.00407d70
mov edx, dword [esp + 0x38]
push edx
call fcn.0040cb70
add esp, 4
call fcn.0040bbc0
call fcn.00403ff0
mov esi, eax
mov eax, dword [0x41cf3c]
test eax, eax
je 0x40d385
movsx eax, byte [0x41bbb9]
push eax
call fcn.0040ef79
add esp, 4
push 0
push str.oniwndp
mov byte [esp + 0x48], al
mov byte [0x41bbb9], al
call dword [sym.imp.USER32.dll_FindWindowA]
test eax, eax
je 0x40d316
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x24
ret 0x10
or esi, 0xffffffff
mov dword [esp + 0x10], esi
jmp 0x40d286
mov al, byte [esp + 0x40]
cmp al, 0x70
jne 0x40d351
push 0x41bbbb
call fcn.0040ec28
mov edi, eax
push edi
call fcn.00401f30
push edi
mov ebp, eax
call fcn.00401f50
push esi
push eax
push ebp
push eax
push ebp
xor ebp, ebp
push ebp
push ebp
push 7
push ebp
call fcn.0040cd20
add esp, 0x30
jmp 0x40d3d7
cmp al, 0x73
jne 0x40d385
mov edi, dword [0x41cf38]
inc edi
push 0x41b980
mov dword [0x41cf38], edi
call dword [sym.imp.USER32.dll_GetCursorPos]
push 0
call dword [sym.imp.USER32.dll_ShowCursor]
inc dword [0x41cf3c]
mov dword [0x41ceb0], 0xa
mov eax, dword [0x41ba90]
test eax, eax
push esi
push ebx
push ebp
je 0x40d3c3
mov ecx, dword [0x41cda4]
mov edx, dword [0x41cc88]
push ecx
push edx
push 0xffffffffffffffff
push 0xffffffffffffffff
push 2
push 1
call fcn.0040cd20
push esi
push ebx
push ebp
push ebx
push ebp
push 0xffffffffffffffff
push 0xffffffffffffffff
push 3
push 0
call fcn.0040cd20
add esp, 0x48
jmp 0x40d3d5
push ebx
push ebp
push 0xffffffffffffffff
push 0xffffffffffffffff
push 3
push 0
call fcn.0040cd20
add esp, 0x24
xor ebp, ebp
mov eax, dword [0x41cd9c]
mov ebx, dword [eax + 0x34]
push 0x11
call dword [sym.imp.USER32.dll_GetAsyncKeyState]
test ah, ah
js 0x40d3f2
cmp dword [esp + 0x10], 0xffffffff
jne 0x40d417
push ebp
push ebx
call dword [sym.imp.USER32.dll_GetSystemMenu]
mov edi, dword [sym.imp.USER32.dll_AppendMenuA]
push ebp
push ebp
mov esi, eax
push 0x800
push esi
call edi
push str.About_HSP...
push 0x64
push ebp
push esi
call edi
cmp dword [esp + 0x14], ebp
push ebx
jne 0x40d788
call fcn.0040d850
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
add esp, 4
mov esi, 0xfffffffe
mov al, byte [0x41cda8]
test al, al
jne 0x40d498
mov al, byte [0x4183e0]
xor ecx, ecx
test al, al
mov esi, 0x41cda8
mov edi, 0x4183e1
je 0x40d787
imul ecx, ecx, 0x11
add al, 0x28
movzx edx, al
mov byte [esi], al
mov al, byte [edi]
inc esi
add ecx, edx
inc edi
test al, al
jne 0x40d457
cmp ecx, 0x6cced385
jne 0x40d787
push 0x41cda8
call fcn.00403d10
add esp, 4
cmp eax, 1
jne 0x40d787
mov edi, dword [sym.imp.USER32.dll_TranslateMessage]
mov esi, 0xfffffffe
push 0x41cda8
call fcn.0040b260
add esp, 4
test eax, eax
jne 0x40d792
cmp dword [0x41d014], ebp
je 0x40d4bf
push 2
call fcn.0040b2a0
add esp, 4
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [esp + 0x40], eax
mov dword [0x41cc90], ebp
mov dword [0x41bb2c], ebp
mov dword [0x41baa0], 5
nop
push 1
push ebp
push ebp
push ebp
lea eax, [esp + 0x28]
push eax
call dword [sym.imp.USER32.dll_PeekMessageA]
test eax, eax
je 0x40d57a
cmp dword [esp + 0x1c], 0x12
je 0x40d7b3
lea ecx, [esp + 0x18]
push ecx
call edi
lea edx, [esp + 0x18]
push edx
call dword [sym.imp.USER32.dll_DispatchMessageA]
cmp dword [esp + 0x1c], 0x100
jne 0x40d4e0
cmp dword [0x41cf38], ebp
je 0x40d530
push ebx
call fcn.0040bc70
add esp, 4
cmp dword [esp + 0x20], 9
jne 0x40d545
call fcn.0040bea0
push eax
call fcn.0040bee0
add esp, 4
push 1
call fcn.0040aa60
add esp, 4
test eax, eax
je 0x40d4e0
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
movzx edx, al
mov dword [0x41cf8c], eax
mov dword [0x41ba9c], ecx
mov dword [0x41c3dc], edx
mov dword [0x41a9a0], ebp
jmp 0x40d4e0
mov eax, dword [0x41a9a0]
cmp eax, ebp
jne 0x40d6a9
call fcn.0040b370
cmp dword [0x41cf3c], ebp
mov dword [0x41a9a0], eax
je 0x40d5aa
mov ecx, dword [0x41ceb0]
cmp ecx, ebp
je 0x40d5aa
dec ecx
mov dword [0x41ceb0], ecx
cmp eax, 0xffffffff
je 0x40d7b3
cmp eax, 0xfffffffd
jne 0x40d5e8
push 4
call fcn.0040aa60
add esp, 4
test eax, eax
jne 0x40d721
call fcn.004079f0
push ebp
push ebp
push 0x7400
push ebx
mov dword [0x41a9a0], esi
call dword [sym.imp.USER32.dll_SendMessageA]
mov eax, dword [0x41a9a0]
cmp eax, 0xfffffffc
je 0x40d74a
cmp eax, 0xfffffffb
jne 0x40d607
push 1
push ebx
call dword [sym.imp.USER32.dll_KillTimer]
mov dword [0x41a9a0], esi
jmp 0x40d632
cmp eax, ebp
jle 0x40d62a
test eax, 0x10000
je 0x40d6cc
mov edx, dword [esp + 0x40]
mov ecx, eax
and ecx, 0xffff
add ecx, edx
mov dword [0x41bb2c], ecx
cmp eax, esi
jne 0x40d4e0
push ebp
push ebp
push ebp
lea edx, [esp + 0x24]
push edx
call dword [sym.imp.USER32.dll_GetMessageA]
test eax, eax
je 0x40d7b3
lea eax, [esp + 0x18]
push eax
call edi
lea ecx, [esp + 0x18]
push ecx
call dword [sym.imp.USER32.dll_DispatchMessageA]
cmp dword [esp + 0x1c], 0x100
jne 0x40d698
cmp dword [0x41cf38], ebp
je 0x40d675
push ebx
call fcn.0040bc70
add esp, 4
cmp dword [esp + 0x20], 9
jne 0x40d68a
call fcn.0040bea0
push eax
call fcn.0040bee0
add esp, 4
push 1
call fcn.0040aa60
add esp, 4
test eax, eax
jne 0x40d6e2
mov eax, dword [0x41a9a0]
cmp eax, esi
je 0x40d632
cmp eax, ebp
je 0x40d587
jle 0x40d4e0
call dword [sym.imp.KERNEL32.dll_GetTickCount]
cmp dword [0x41bb2c], eax
mov dword [esp + 0x40], eax
ja 0x40d708
mov dword [0x41a9a0], ebp
jmp 0x40d4e0
push ebp
push eax
push 1
push ebx
call dword [sym.imp.USER32.dll_SetTimer]
mov dword [0x41a9a0], esi
jmp 0x40d632
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x24]
mov dword [0x41cf8c], eax
movzx eax, al
mov dword [0x41ba9c], edx
mov dword [0x41c3dc], eax
mov dword [0x41a9a0], ebp
jmp 0x40d587
mov eax, dword [0x41baa0]
cmp eax, ebp
je 0x40d4e0
push eax
call dword [sym.imp.KERNEL32.dll_Sleep]
jmp 0x40d4e0
mov ecx, dword [0x41b2f8]
mov edx, dword [0x41a798]
mov dword [0x41cf8c], ecx
mov dword [0x41ba9c], edx
mov dword [0x41c3dc], ebp
mov dword [0x41a9a0], ebp
jmp 0x40d4e0
call fcn.004079f0
call fcn.0040b2c0
call fcn.0040b240
mov edx, 0x41cda8
mov edi, edi
mov cl, byte [eax]
inc eax
mov byte [edx], cl
inc edx
test cl, cl
jne 0x40d760
push 0x800
call fcn.0040b250
push eax
push 0x41bbb8
call fcn.0040f960
add esp, 0xc
jmp 0x40d435
push ebx
call fcn.0040c010
add esp, 4
jmp 0x40d7d2
push 0x40
push 0x415301
call fcn.0040b240
push eax
push ebx
call dword [sym.imp.USER32.dll_MessageBoxA]
push ebp
push ebp
push 0x10
push ebx
call dword [sym.imp.USER32.dll_SendMessageA]
jmp 0x40d7d2
call fcn.0040b450
push 0xffffffffffffffff
call fcn.0040aa10
add esp, 4
push ebp
push ebp
push 0x10
push ebx
call dword [sym.imp.USER32.dll_SendMessageA]
call fcn.004079f0
call fcn.0040d9c0
call fcn.0040b2c0
call fcn.004039d0
call fcn.0040bc20
call fcn.00407da0
mov eax, dword [esp + 0x20]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret 0x10