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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4efba0
mov eax, dword fs:[0]
push eax
sub esp, 0x78
mov eax, dword [0x522008]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov eax, dword [ebp + 0xc]
lea ecx, [ebp - 0x2c]
mov ebx, dword [ebp + 8]
mov esi, 0x80400000
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 0x54], eax
mov byte [ebp - 0x45], 0
call fcn.00402230
mov dword [ebp - 4], 0
lea eax, [ebp - 0x45]
push eax
lea eax, [ebp - 0x2c]
push eax
push ecx
push dword [ebp - 0x5c]
mov ecx, edi
push ebx
call fcn.004ae5c0
test al, al
jne 0x4aebac
xor bl, bl
jmp 0x4aedb9
cmp byte [ebp - 0x45], 0
mov eax, 0x80c0f000
mov ecx, edi
cmovne esi, eax
lea eax, [ebp - 0x2c]
push esi
sub esp, 8
mov dword [ebp - 0x50], esi
push eax
push ebx
call fcn.004af5a0
mov ebx, dword [sym.imp.KERNEL32.dll_InterlockedExchange]
test eax, eax
jne 0x4aec40
lea esi, [edi + 0x20]
mov dword [ebp - 0x60], esi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push esi
call ebx
mov byte [ebp - 4], 1
push ecx
push dword [ebp - 0x50]
lea ecx, [ebp - 0x2c]
push dword [ebp - 0x54]
push dword [ebp - 0x58]
call fcn.00402130
mov ecx, dword [ebp - 0x4c]
mov edx, eax
call fcn.004aeab0
add esp, 0x10
mov dword [edi + 4], eax
push 0
push esi
call ebx
cmp dword [edi + 4], 0
jne 0x4aec37
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2f19
jne 0x4aec37
push dword [ebp - 0x50]
lea eax, [ebp - 0x2c]
mov ecx, edi
sub esp, 8
push eax
push dword [ebp - 0x4c]
call fcn.004af5a0
mov byte [ebp - 4], 0
push 0
push esi
call ebx
cmp dword [edi + 4], 0
je 0x4aec58
mov ecx, edi
call fcn.004afa80
cmp eax, 0x12e
jne 0x4aedb2
lea esi, [edi + 0x20]
mov dword [ebp - 0x64], esi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push esi
call ebx
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x50]
mov edx, dword [ebp - 0x5c]
or eax, 0x80200000
push ecx
mov ecx, dword [ebp - 0x4c]
push eax
push dword [ebp - 0x54]
mov dword [ebp - 0x60], eax
push dword [ebp - 0x58]
call fcn.004aeab0
add esp, 0x10
mov dword [edi + 4], eax
push 0
push esi
call ebx
cmp dword [edi + 4], 0
jne 0x4aecbc
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2f19
jne 0x4aecbc
push dword [ebp - 0x60]
lea eax, [ebp - 0x2c]
mov ecx, edi
sub esp, 8
push eax
push dword [ebp - 0x4c]
call fcn.004af5a0
mov byte [ebp - 4], 0
push 0
push esi
call ebx
cmp dword [edi + 4], 0
mov byte [ebp - 0x45], 0
je 0x4aeda3
mov ecx, edi
call fcn.004afa80
cmp eax, 0x12e
jne 0x4aeda3
push str.Location
lea ecx, [ebp - 0x80]
call fcn.004021e0
mov byte [ebp - 4], 3
lea eax, [ebp - 0x80]
push eax
lea eax, [ebp - 0x44]
mov ecx, edi
push eax
call fcn.004af400
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x80]
call fcn.00401f40
lea ecx, [ebp - 0x44]
call fcn.00402120
test al, al
jne 0x4aed91
mov ecx, dword [edi + 4]
mov byte [ebp - 0x45], 1
call fcn.0043ea00
mov dword [ebp - 0x64], esi
call dword [sym.imp.KERNEL32.dll_GetTickCount]
push eax
push esi
call ebx
mov byte [ebp - 4], 6
push ecx
push dword [ebp - 0x50]
lea ecx, [ebp - 0x44]
push dword [ebp - 0x54]
push dword [ebp - 0x58]
call fcn.00402130
mov ecx, dword [ebp - 0x4c]
mov edx, eax
call fcn.004aeab0
add esp, 0x10
mov dword [edi + 4], eax
push 0
push esi
call ebx
cmp dword [edi + 4], 0
jne 0x4aed88
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x2f19
jne 0x4aed88
push dword [ebp - 0x50]
lea eax, [ebp - 0x44]
mov ecx, edi
sub esp, 8
push eax
push dword [ebp - 0x4c]
call fcn.004af5a0
mov byte [ebp - 4], 5
push 0
push esi
call ebx
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x44]
call fcn.00401f40
cmp byte [ebp - 0x45], 0
jne 0x4aedb2
mov ecx, dword [edi + 4]
call fcn.0043ea00
mov dword [edi + 4], 0
cmp dword [edi + 4], 0
setne bl
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x2c]
call fcn.00401f40
mov al, bl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.004b5964
mov esp, ebp
pop ebp
ret 0x14