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

Disassembly:
push rbp
push rdi
lea rbp, [rsp - 0x4f]
sub rsp, 0x88
cmp byte [rcx], 0
mov rdi, rcx
je 0x1400193f8
movzx eax, word [0x1401f2944]
add rsp, 0x88
pop rdi
pop rbp
ret
mov qword [rsp + 0x80], rbx
add rcx, 0x18
mov qword [rsp + 0x78], rsi
mov qword [rsp + 0x68], r14
mov qword [rsp + 0x60], r15
call qword [sym.imp.KERNEL32.dll_EnterCriticalSection]
mov rbx, qword [0x1401f2928]
mov esi, dword [0x1401f2944]
mov byte [rdi], 1
call qword [sym.imp.KERNEL32.dll_GetTickCount]
sub eax, dword [0x1401f2924]
btr eax, 0x1f
cmp eax, 0xc8
jbe 0x1400195bc
lea rcx, [rbp - 1]
call qword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
test rbx, rbx
jne 0x1400195b3
mov rax, qword [rdi + 8]
test rax, rax
je 0x140019473
lea r8, [rbp + 0x77]
lea rdx, [rbp + 0x67]
lea rcx, [rbp + 0x6f]
call rax
jmp 0x140019526
mov rax, qword [rdi + 0x10]
mov qword [rbp + 0x6f], rbx
mov qword [rbp + 0x67], rbx
mov qword [rbp + 0x77], rbx
test rax, rax
je 0x140019526
mov r8d, dword [rdi + 0x48]
test r8d, r8d
je 0x140019526
mov rdx, qword [rdi + 0x40]
lea r9, [rdi + 0x48]
mov ecx, 8
call rax
test eax, eax
jne 0x140019526
mov ecx, dword [rdi + 0x48]
movabs rax, 0xaaaaaaaaaaaaaaab
mov r8, qword [rbp + 0x67]
mul rcx
mov rcx, qword [rbp + 0x77]
shr rdx, 5
movsxd r10, edx
test edx, edx
mov rdx, qword [rbp + 0x6f]
jle 0x140019502
mov rax, qword [rdi + 0x40]
mov r9, r10
add rax, 0x10
nop
add rdx, qword [rax - 0x10]
lea rax, [rax + 0x30]
mov qword [rbp + 0x6f], rdx
add r8, qword [rax - 0x38]
mov qword [rbp + 0x67], r8
add rcx, qword [rax - 0x30]
mov qword [rbp + 0x77], rcx
sub r9, 1
jne 0x1400194e0
mov rax, rdx
cqo
idiv r10
mov qword [rbp + 0x6f], rax
mov rax, r8
cqo
idiv r10
mov qword [rbp + 0x67], rax
mov rax, rcx
cqo
idiv r10
mov qword [rbp + 0x77], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r9, [rbp + 0x7f]
lea rax, [rbp - 9]
lea r8, [rbp + 7]
mov qword [rsp + 0x20], rax
lea rdx, [rbp + 0xf]
call qword [sym.imp.KERNEL32.dll_GetProcessTimes]
mov rax, qword [rbp - 1]
mov rcx, qword [rbp - 9]
mov qword [0x1401f2928], rax
mov rax, qword [rbp + 0x6f]
mov qword [0x1401f2980], rax
mov rax, qword [rbp + 0x67]
mov qword [0x1401f2930], rax
mov rax, qword [rbp + 0x77]
mov qword [0x1401f2948], rax
mov rax, qword [rbp + 0x7f]
mov qword [0x1401f2938], rax
mov qword [0x1401f2988], rcx
mov dword [0x1401f2944], ebx
call qword [sym.imp.KERNEL32.dll_GetTickCount]
mov dword [0x1401f2924], eax
cmp byte [rdi], bl
je 0x1400195ac
lea rcx, [rdi + 0x18]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [rdi], bl
jmp 0x1400198da
mov r15, qword [rbp - 1]
sub r15, rbx
jne 0x1400195d6
cmp byte [rdi], 0
je 0x1400195cb
lea rcx, [rdi + 0x18]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [rdi], 0
movzx eax, si
jmp 0x1400198dd
mov rax, qword [rdi + 8]
xor ebx, ebx
mov qword [rsp + 0x70], r12
test rax, rax
je 0x1400195f9
lea r8, [rbp + 0x77]
lea rdx, [rbp + 0x67]
lea rcx, [rbp + 0x6f]
call rax
jmp 0x1400196b6
mov rax, qword [rdi + 0x10]
mov qword [rbp + 0x6f], rbx
mov qword [rbp + 0x67], rbx
mov qword [rbp + 0x77], rbx
test rax, rax
je 0x1400196b6
mov r8d, dword [rdi + 0x48]
test r8d, r8d
je 0x1400196b6
mov rdx, qword [rdi + 0x40]
lea r9, [rdi + 0x48]
mov ecx, 8
call rax
test eax, eax
jne 0x1400196b6
mov ecx, dword [rdi + 0x48]
movabs rax, 0xaaaaaaaaaaaaaaab
mov r8, qword [rbp + 0x67]
mul rcx
mov rcx, qword [rbp + 0x77]
shr rdx, 5
movsxd r10, edx
test edx, edx
mov rdx, qword [rbp + 0x6f]
jle 0x140019692
mov rax, qword [rdi + 0x40]
mov r9, r10
add rax, 0x10
nop dword [rax + rax]
add rdx, qword [rax - 0x10]
lea rax, [rax + 0x30]
mov qword [rbp + 0x6f], rdx
add r8, qword [rax - 0x38]
mov qword [rbp + 0x67], r8
add rcx, qword [rax - 0x30]
mov qword [rbp + 0x77], rcx
sub r9, 1
jne 0x140019670
mov rax, rdx
cqo
idiv r10
mov qword [rbp + 0x6f], rax
mov rax, r8
cqo
idiv r10
mov qword [rbp + 0x67], rax
mov rax, rcx
cqo
idiv r10
mov qword [rbp + 0x77], rax
call qword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov rcx, rax
lea r9, [rbp + 0x7f]
lea rax, [rbp - 9]
lea r8, [rbp + 0x17]
mov qword [rsp + 0x20], rax
lea rdx, [rbp + 0x1f]
call qword [sym.imp.KERNEL32.dll_GetProcessTimes]
mov rsi, qword [rbp + 0x67]
mov r12, qword [rbp + 0x77]
mov rcx, rsi
sub rcx, qword [0x1401f2948]
sub rcx, qword [0x1401f2930]
mov r11, qword [rbp + 0x6f]
add rcx, r12
je 0x140019717
mov rax, qword [0x1401f2980]
sub rax, r11
add rax, rcx
imul rax, rax, 0x64
cqo
idiv rcx
mov r10, rax
jmp 0x14001971a
mov r10d, ebx
mov r8, qword [rbp - 9]
mov r9, qword [rbp + 0x7f]
mov rcx, qword [rbp - 1]
mov rax, r9
sub rax, qword [0x1401f2988]
sub rax, qword [0x1401f2938]
add rax, r8
mov qword [0x1401f2928], rcx
imul rax, rax, 0x64
mov qword [0x1401f2988], r8
mov r8d, dword [0x1401f2964]
cqo
idiv r15
movsxd rdx, dword [0x1401f2940]
inc r8d
mov qword [0x1401f2930], rsi
lea rsi, [0x140000000]
mov qword [0x1401f2948], r12
mov r12, qword [rsp + 0x70]
mov dword [rsi + rdx*4 + 0x1f2968], eax
lea ecx, [rdx + 1]
mov dword [rsi + rdx*4 + 0x1f2950], r10d
mov eax, 0x66666667
imul ecx
mov qword [0x1401f2980], r11
mov r10d, ebx
sar edx, 1
mov eax, edx
mov qword [0x1401f2938], r9
shr eax, 0x1f
add edx, eax
mov dword [0x1401f2964], r8d
lea eax, [rdx + rdx*4]
mov edx, ebx
sub ecx, eax
mov dword [0x1401f2940], ecx
cmp r8d, 5
jle 0x1400197db
mov r8d, 5
mov dword [0x1401f2964], r8d
jmp 0x140019859
test r8d, r8d
jle 0x140019859
cmp r8d, 8
jb 0x140019859
mov ecx, r8d
xorps xmm2, xmm2
xorps xmm1, xmm1
and ecx, 0x80000007
jge 0x1400197fe
dec ecx
or ecx, 0xfffffff8
inc ecx
mov eax, r8d
sub eax, ecx
movsxd rcx, eax
mov rax, rbx
nop dword [rax]
movdqu xmm0, xmmword [rsi + rax*4 + 0x1f2968]
add edx, 8
paddd xmm2, xmm0
movdqu xmm0, xmmword [rsi + rax*4 + 0x1f2978]
add rax, 8
paddd xmm1, xmm0
cmp rax, rcx
jl 0x140019810
paddd xmm1, xmm2
movdqa xmm0, xmm1
psrldq xmm0, 8
paddd xmm1, xmm0
movdqa xmm0, xmm1
psrldq xmm0, 4
paddd xmm1, xmm0
movd r10d, xmm1
mov r9d, ebx
cmp edx, r8d
jge 0x1400198ad
mov eax, r8d
movsxd rcx, edx
sub eax, edx
cmp eax, 2
jl 0x14001989e
mov eax, r8d
sub eax, edx
sub eax, 2
shr eax, 1
inc eax
mov r11d, eax
lea eax, [rdx + rax*2]
add ebx, dword [rsi + rcx*4 + 0x1f2968]
add r9d, dword [rsi + rcx*4 + 0x1f296c]
add rcx, 2
sub r11, 1
jne 0x140019880
cmp eax, r8d
jge 0x1400198a6
add r10d, dword [rsi + rcx*4 + 0x1f2968]
lea ecx, [r9 + rbx]
add r10d, ecx
mov eax, r10d
cdq
idiv r8d
mov ebx, eax
mov dword [0x1401f2944], eax
call qword [sym.imp.KERNEL32.dll_GetTickCount]
cmp byte [rdi], 0
mov dword [0x1401f2924], eax
je 0x1400198d7
lea rcx, [rdi + 0x18]
call qword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov byte [rdi], 0
movzx eax, bx
mov r14, qword [rsp + 0x68]
mov rsi, qword [rsp + 0x78]
mov rbx, qword [rsp + 0x80]
mov r15, qword [rsp + 0x60]
add rsp, 0x88
pop rdi
pop rbp
ret