Function at 0x4f5948
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 - 0x20], ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x28], ecx
mov dword [ebp - 4], eax
xor eax, eax
push ebp
push 0x4f5c16
push dword fs:[eax]
mov dword fs:[eax], esp
mov byte [ebp - 5], 1
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x58]
call fcn.00407d08
dec eax
test eax, eax
jl 0x4f59a9
inc eax
xor edx, edx
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx + 0x58]
mov ecx, dword [ecx + edx*4]
cmp byte [ebp - 5], 0
je 0x4f599c
cmp byte [ecx + 0x38c], 0
jne 0x4f59a0
xor ecx, ecx
jmp 0x4f59a2
mov cl, 1
mov byte [ebp - 5], cl
inc edx
dec eax
jne 0x4f5984
call fcn.00409830
mov dword [ebp - 0xc], eax
xor eax, eax
push ebp
push 0x4f5a6d
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x74]
mov eax, dword [eax + 0x70]
mov ecx, dword [ebp - 4]
sub eax, dword [ecx + 0x78]
sbb edx, dword [ecx + 0x7c]
push edx
push eax
mov eax, 8
xor edx, edx
call fcn.00407818
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], edx
fild qword [ebp - 0x14]
mov eax, dword [ebp - 4]
mov edx, dword [ebp - 0xc]
sub edx, dword [eax + 0x80]
mov dword [ebp - 0x1c], edx
xor eax, eax
mov dword [ebp - 0x18], eax
fild qword [ebp - 0x1c]
fdivp st(1)
mov eax, dword [ebp - 4]
fstp qword [eax + 0x98]
wait
call fcn.00460cdc
mov eax, dword [ebp - 4]
fsub qword [eax + 0x88]
mov eax, dword [ebp - 4]
fstp qword [eax + 0x90]
wait
mov eax, dword [ebp - 4]
cmp dword [eax + 0x64], 0
jne 0x4f5a45
cmp dword [eax + 0x60], 0
jne 0x4f5a45
mov eax, dword [ebp - 4]
xor edx, edx
mov dword [eax + 0xa0], edx
mov dword [eax + 0xa4], edx
jmp 0x4f5a63
mov eax, dword [ebp - 4]
fild qword [eax + 0x70]
fmul dword [0x4f5c24]
mov eax, dword [ebp - 4]
fild qword [eax + 0x60]
fdivp st(1)
mov eax, dword [ebp - 4]
fstp qword [eax + 0xa0]
wait
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4f5a77
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x78]
mov eax, dword [ebp - 4]
mov edx, dword [ebp - 0xc]
mov dword [eax + 0x80], edx
mov eax, dword [ebp - 4]
mov edx, dword [eax + 0x74]
mov eax, dword [eax + 0x70]
mov ecx, dword [ebp - 4]
cmp edx, dword [ecx + 0x7c]
jne 0x4f5b3a
cmp eax, dword [ecx + 0x78]
jne 0x4f5b3a
call fcn.00409830
mov ebx, eax
mov eax, dword [ebp - 4]
mov edx, ebx
sub edx, dword [eax + 0x108]
mov eax, dword [ebp - 4]
imul eax, dword [eax + 0x10c], 0x3e8
cmp edx, eax
jbe 0x4f5b48
push 0x4f5c34
mov eax, ebx
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x24]
call fcn.0045d468
push dword [ebp - 0x24]
push 0x4f5c6c
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x108]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x28]
call fcn.0045d468
push dword [ebp - 0x28]
lea eax, [ebp - 0x20]
mov edx, 4
call fcn.00406bec
mov edx, dword [ebp - 0x20]
xor ecx, ecx
mov eax, dword [ebp - 4]
call fcn.004f3614
mov eax, dword [ebp - 4]
cmp word [eax + 0x112], 0
je 0x4f5b48
mov ebx, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov eax, dword [ebx + 0x114]
call dword [ebx + 0x110]
jmp 0x4f5b48
call fcn.00409830
mov edx, dword [ebp - 4]
mov dword [edx + 0x108], eax
mov eax, dword [ebp - 4]
mov edx, dword [ebp - 4]
mov ecx, dword [edx + 0x70]
mov dword [eax + 0x78], ecx
mov ecx, dword [edx + 0x74]
mov dword [eax + 0x7c], ecx
cmp byte [ebp - 5], 0
je 0x4f5bfb
mov eax, dword [ebp - 4]
mov eax, dword [eax + 0x104]
xor edx, edx
call fcn.004d3e80
xor eax, eax
push ebp
push 0x4f5bc5
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [ebp - 4]
push dword [eax + 0x74]
push dword [eax + 0x70]
mov eax, 8
xor edx, edx
call fcn.00407818
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], edx
fild qword [ebp - 0x14]
mov eax, dword [ebp - 4]
fld qword [eax + 0x90]
fmul dword [0x4f5c88]
fdivp st(1)
mov eax, dword [ebp - 4]
fstp qword [eax + 0x98]
wait
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x4f5bcf
mov eax, dword [ebp - 4]
mov edx, dword [eax]
call dword [edx + 0x78]
mov eax, dword [ebp - 4]
add eax, 0x84
mov edx, dword [eax]
xor ecx, ecx
mov dword [eax], ecx
mov eax, edx
call fcn.004045f8
xor ecx, ecx
mov edx, 0x4f5c98
mov eax, dword [ebp - 4]
call fcn.004f3614
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x4f5c1d
lea eax, [ebp - 0x28]
mov edx, 3
call fcn.00406740
ret