Function at 0x51fe9c
Capabilities:
Check for time delay via gettickcount

Disassembly:
push ebp
mov ebp, esp
mov ecx, 5
push 0
push 0
dec ecx
jne 0x51fea4
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], edx
mov ebx, eax
xor eax, eax
push ebp
push 0x5200ea
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 5], 0
mov eax, dword [ebx + 0xc]
call fcn.00405080
test eax, eax
jle 0x5200b2
lea eax, [ebp - 0x24]
mov edx, dword [ebx + 0xc]
call fcn.00405688
mov eax, dword [ebp - 0x24]
lea ecx, [ebp - 0xc]
mov dl, 1
call fcn.004d4628
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x1a]
push eax
lea ecx, [ebp - 0x14]
lea edx, [ebp - 0xd]
mov eax, dword [ebp - 0xc]
call fcn.0051ee58
xor eax, eax
push ebp
push 0x5200a8
push dword fs:[eax]
mov dword fs:[eax], esp
xor edx, edx
mov eax, dword [ebp - 4]
call fcn.0051ce80
mov edx, dword [ebp - 0x14]
mov eax, dword [ebp - 4]
call fcn.0051bfa0
mov dl, byte [ebp - 0xd]
mov eax, dword [ebp - 4]
call fcn.0051bff8
lea edx, [ebp - 0x28]
movzx eax, word [ebp - 0x1a]
call fcn.00409c7c
mov edx, dword [ebp - 0x28]
mov eax, dword [ebp - 4]
call fcn.0051bfcc
mov edx, dword [ebp - 0x18]
mov eax, dword [ebp - 4]
call fcn.0051c038
mov dl, 1
mov eax, dword [0x419ca4]
call fcn.00403f14
mov dword [ebp - 0x20], eax
xor eax, eax
push ebp
push 0x520097
push dword fs:[eax]
mov dword fs:[eax], esp
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 4]
call fcn.0051c0c8
mov eax, dword [ebp - 4]
call fcn.0051d1d0
call sub.kernel32.dll_GetTickCount_1
mov esi, eax
push 1
call sub.kernel32.dll_Sleep_1
call sub.kernel32.dll_GetTickCount_1
sub eax, esi
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0xc]
cdq
cmp edx, dword [esp + 4]
jne 0x51ffb3
cmp eax, dword [esp]
pop edx
pop eax
ja 0x51ffc8
jmp 0x51ffb7
pop edx
pop eax
jg 0x51ffc8
mov eax, dword [ebp - 0x20]
mov edx, dword [eax]
call dword [edx]
cmp edx, 0
jne 0x51ffc8
cmp eax, 0
je 0x51fff6
cmp byte [ebx + 4], 0
je 0x51ffe0
call fcn.004047d0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x5200b2
mov eax, dword [ebp - 4]
call fcn.0051be04
sub al, 2
je 0x51fff6
sub al, 2
je 0x51fff6
add al, 0xf9
sub al, 2
jae 0x51ff8b
cmp byte [ebx + 4], 0
je 0x52000e
call fcn.004047d0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x5200b2
mov eax, dword [ebp - 4]
call fcn.0051be04
cmp al, 0xb
jne 0x520060
mov eax, dword [ebp - 0x20]
mov edx, dword [eax]
call dword [edx]
push edx
push eax
lea edx, [ebp - 0x2c]
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 4]
call fcn.004cee00
mov eax, dword [ebp - 0x2c]
mov edx, dword [ebx + 0x10]
call fcn.004098ac
test al, al
je 0x520051
mov edx, dword [ebx + 0x14]
mov eax, dword [ebp - 0x20]
call fcn.0041f118
mov byte [ebp - 5], 1
jmp 0x52006d
lea eax, [ebx + 0x18]
mov edx, 0x520104
call fcn.00404e04
jmp 0x52006d
lea eax, [ebx + 0x18]
mov edx, 0x520114
call fcn.00404e04
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x52009e
xor edx, edx
mov eax, dword [ebp - 4]
call fcn.0051c0c8
mov eax, dword [ebp - 0x20]
call fcn.00403f44
xor edx, edx
mov eax, dword [ebp - 4]
call fcn.0051ce80
ret
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x5200f1
lea eax, [ebp - 0x2c]
mov edx, 2
call fcn.00404dd4
lea eax, [ebp - 0x24]
call fcn.00405508
lea eax, [ebp - 0x18]
mov edx, 2
call fcn.00404dd4
lea eax, [ebp - 0xc]
call fcn.00404db0
ret