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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffffd8
push ebx
push esi
push edi
xor ecx, ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x28], ecx
mov byte [ebp - 5], dl
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x489a2c
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 6], 0
mov eax, dword [ebp - 4]
cmp byte [eax + 0xd], 0
jne 0x489a11
mov eax, dword [ebp - 4]
cmp byte [eax + 0x34], 0
jne 0x489a11
mov eax, dword [ebp - 4]
cmp byte [eax + 0x14], 0
je 0x489a11
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
mov edx, dword [eax]
call dword [edx + 0x14]
cmp eax, 2
jle 0x489742
jmp 0x4896d1
mov eax, dword [ebp - 4]
mov ebx, dword [eax + 0x30]
mov eax, ebx
mov edx, dword [eax]
call dword [edx + 0x14]
mov edx, eax
dec edx
mov eax, ebx
mov ecx, dword [eax]
call dword [ecx + 0x44]
mov eax, dword [ebp - 4]
mov ebx, dword [eax + 0x30]
mov eax, ebx
mov edx, dword [eax]
call dword [edx + 0x14]
mov edx, eax
dec edx
lea ecx, [ebp - 0x24]
mov eax, ebx
mov ebx, dword [eax]
call dword [ebx + 0xc]
cmp dword [ebp - 0x24], 0
jne 0x489713
mov eax, dword [ebp - 4]
mov esi, dword [eax + 0x30]
mov eax, esi
mov edx, dword [eax]
call dword [edx + 0x14]
mov edx, eax
sub edx, 2
lea ecx, [ebp - 0x28]
mov eax, esi
mov ebx, dword [eax]
call dword [ebx + 0xc]
cmp dword [ebp - 0x28], 0
je 0x4896ba
lea ecx, [ebp - 0x24]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
xor edx, edx
mov ebx, dword [eax]
call dword [ebx + 0xc]
mov eax, dword [ebp - 0x24]
mov edx, dword [0x5bc024]
mov edx, dword [edx]
call fcn.00404028
jne 0x489742
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
xor edx, edx
mov ecx, dword [eax]
call dword [ecx + 0x44]
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
call fcn.0046b2f0
xor eax, eax
push ebp
push 0x48977b
push dword fs:[eax]
mov dword fs:[eax], esp
push 2
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 0x10]
mov dl, 1
mov eax, dword [0x40f87c]
call fcn.00413ee4
mov ebx, eax
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4897e4
test ebx, ebx
je 0x489a11
mov eax, dword [ebp - 4]
cmp byte [eax + 0x2c], 0
jne 0x48981b
mov eax, dword [ebp - 4]
cmp byte [eax + 0x2d], 0
je 0x489997
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov edx, dword [0x5bc024]
mov edx, dword [edx]
call fcn.00404028
je 0x489997
mov dl, 1
mov eax, dword [0x40f96c]
call fcn.00402f88
mov edi, eax
mov dl, 1
mov eax, dword [0x40f96c]
call fcn.00402f88
mov esi, eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
mov edx, edi
mov ecx, dword [eax]
call dword [ecx + 0x68]
mov eax, edi
call fcn.00489610
push 0
push 0
mov eax, edi
call fcn.00413934
lea eax, [ebp - 0x20]
xor ecx, ecx
mov edx, 0x18
call fcn.00402c18
mov eax, edi
call fcn.00413948
mov dword [ebp - 0x10], eax
mov eax, dword [0x489a40]
mov dword [ebp - 0x20], eax
mov ax, word [0x489a44]
mov word [ebp - 0x1c], ax
mov al, byte [0x489a46]
mov byte [ebp - 0x1a], al
mov dword [ebp - 0x18], 0x20000
mov eax, dword [ebp - 4]
mov al, byte [eax + 0x2c]
mov byte [ebp - 0x14], al
mov eax, dword [ebp - 4]
cmp byte [eax + 0x2d], 0
je 0x4898ba
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
mov edx, dword [0x5bc024]
mov edx, dword [edx]
call fcn.00404028
jne 0x4898be
xor eax, eax
jmp 0x4898c0
mov al, 1
mov byte [ebp - 0x13], al
mov eax, edi
call fcn.00413948
push edx
push eax
mov edx, edi
mov eax, esi
call fcn.00413c90
push 0
push 0
mov eax, esi
call fcn.00413934
mov eax, esi
call fcn.00413948
mov ecx, eax
mov edx, dword [esi + 4]
or eax, 0xffffffff
call fcn.004888e0
mov dword [ebp - 0xc], eax
cmp byte [ebp - 0x13], 0
je 0x489933
push 0x10
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
call fcn.00403f18
push eax
mov eax, dword [ebp - 4]
mov eax, dword [eax + 4]
call fcn.004040dc
xor ecx, ecx
pop edx
call fcn.00486044
test al, al
je 0x489933
mov eax, esi
call fcn.00413948
mov edx, eax
mov eax, dword [esi + 4]
call fcn.004862ec
cmp byte [ebp - 0x13], 0
jne 0x48993f
cmp byte [ebp - 0x14], 0
je 0x48997d
push 0
push 0
mov eax, ebx
call fcn.00413998
lea edx, [ebp - 0x20]
mov ecx, 0x18
mov eax, ebx
call fcn.00413c14
push 0
push 0
mov eax, esi
call fcn.00413934
mov edx, ebx
mov eax, esi
call fcn.0041407c
mov eax, edi
call fcn.00402fb8
mov eax, esi
call fcn.00402fb8
jmp 0x4899af
push 0
push 0
mov eax, ebx
call fcn.00413998
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
mov edx, ebx
mov ecx, dword [eax]
call dword [ecx + 0x68]
jmp 0x4899af
push 0
push 0
mov eax, ebx
call fcn.00413998
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x30]
mov edx, ebx
mov ecx, dword [eax]
call dword [ecx + 0x68]
cmp byte [ebp - 5], 0
jne 0x4899c7
call sub.kernel32.dll_GetTickCount
mov edx, dword [ebp - 4]
sub eax, dword [edx + 0x1c]
cmp eax, 0x1d4c0
jbe 0x4899db
call sub.kernel32.dll_GetTickCount
mov edx, dword [ebp - 4]
mov dword [edx + 0x1c], eax
mov eax, dword [ebx + 4]
push eax
call sub.kernel32.dll_FlushFileBuffers
mov eax, ebx
call fcn.00402fb8
mov eax, dword [ebp - 4]
mov al, byte [eax + 0x2d]
mov edx, dword [ebp - 4]
mov byte [edx + 0xc], al
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x10]
call fcn.004092e4
mov edx, dword [ebp - 4]
mov dword [edx + 0x18], eax
mov eax, dword [ebp - 4]
mov byte [eax + 0x2e], 1
mov eax, dword [ebp - 4]
mov byte [eax + 0x15], 0
mov byte [ebp - 6], 1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x489a33
lea eax, [ebp - 0x28]
mov edx, 2
call fcn.00403cc0
ret