Function at 0x10013020
Capabilities:
Check for time delay via queryperformancecounter

Disassembly:
push ebx
mov ebx, esp
sub esp, 8
and esp, 0xfffffff8
add esp, 4
push ebp
mov ebp, dword [ebx + 4]
mov dword [esp + 4], ebp
mov ebp, esp
sub esp, 0x78
mov eax, dword [0x10064008]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0xc]
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x74], eax
cmp dword [eax], 0
jne 0x1001307a
mov eax, dword [edi + 0x10]
test eax, eax
jne 0x1001308f
lea eax, [edi + 8]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov ecx, dword [edi + 0x10]
test ecx, ecx
js 0x10013074
mov eax, dword [ebx + 8]
add dword [edi + 0x18], eax
adc dword [edi + 0x1c], 0
lea eax, [ecx + 1]
mov dword [edi + 0x10], eax
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.1002e779
mov esp, ebp
pop ebp
mov esp, ebx
pop ebx
ret 8
jle 0x10013063
lea eax, [ebp - 0x70]
push eax
call dword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov edx, dword [ebp - 0x6c]
mov ecx, dword [ebp - 0x70]
call fcn.10047940
mov edx, dword [edi + 0xc]
mov ecx, dword [edi + 8]
movsd qword [ebp - 0x70], xmm0
call fcn.10047940
movsd xmm1, qword [ebp - 0x70]
mov edx, dword [edi + 4]
subsd xmm1, xmm0
mov ecx, dword [edi]
movsd qword [ebp - 0x70], xmm1
call fcn.10047940
movsd xmm1, qword [ebp - 0x70]
divsd xmm1, xmm0
comisd xmm1, xmmword [0x1005ab48]
movsd qword [ebp - 0x70], xmm1
jae 0x100130fe
comisd xmm1, xmmword [0x1005ab40]
jb 0x10013063
cmp dword [edi + 0x10], 5
jl 0x10013063
mov edx, dword [edi + 0x1c]
mov ecx, dword [edi + 0x18]
call fcn.10047940
movaps xmm1, xmmword [0x1005ac30]
lea edx, [ebp - 0x60]
movsd xmm3, qword [0x1005aca0]
movaps xmm2, xmm0
movaps xmm0, xmmword [0x1005ac60]
or esi, 0xffffffff
divsd xmm2, qword [ebp - 0x70]
mov ecx, 2
movups xmmword [ebp - 0x38], xmm0
movaps xmm0, xmmword [0x1005ac70]
movups xmmword [ebp - 0x68], xmm1
movaps xmm1, xmmword [0x1005ac40]
movups xmmword [ebp - 0x28], xmm0
movaps xmm0, xmmword [0x1005ac80]
movups xmmword [ebp - 0x58], xmm1
movaps xmm1, xmmword [0x1005ac50]
movups xmmword [ebp - 0x18], xmm0
movsd xmm0, qword [0x1005abc8]
movups xmmword [ebp - 0x48], xmm1
nop
movsd xmm1, qword [edx - 8]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x10013188
lea esi, [ecx - 2]
movaps xmm0, xmm1
movsd xmm1, qword [edx]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x1001319f
lea esi, [ecx - 1]
movaps xmm0, xmm1
movsd xmm1, qword [edx + 8]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x100131b6
mov esi, ecx
movaps xmm0, xmm1
movsd xmm1, qword [edx + 0x10]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x100131ce
lea esi, [ecx + 1]
movaps xmm0, xmm1
movsd xmm1, qword [edx + 0x18]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x100131e6
lea esi, [ecx + 2]
movaps xmm0, xmm1
movsd xmm1, qword [edx + 0x20]
subsd xmm1, xmm2
andps xmm1, xmm3
comisd xmm0, xmm1
jbe 0x100131fe
lea esi, [ecx + 3]
movaps xmm0, xmm1
add ecx, 6
add edx, 0x30
lea eax, [ecx - 2]
cmp eax, 0xc
jb 0x10013170
movsd xmm0, qword [ebp + esi*8 - 0x68]
call fcn.100477d1
mov ecx, dword [ebp - 0x74]
mov dword [ecx], eax
mov dword [edi + 0x18], 0
mov dword [edi + 0x1c], 0
mov dword [edi + 0x10], 0
jmp 0x1001307a