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

Disassembly:
push rbx
push rbp
push rsi
push rdi
sub rsp, 0x78
mov esi, r8d
mov rbp, rdx
mov rbx, rcx
call qword [sym.imp.api_ms_win_core_sysinfo_l1_1_0.dll_GetTickCount]
mov ecx, dword [rbx + 0x10]
lea r8, [0x160000000]
mov r10d, eax
mov r11d, eax
sub r10d, dword [rbx + 0x14]
mov edi, dword [r8 + rcx*4 + 0x270d30]
mov ecx, dword [r8 + rcx*4 + 0x1f67f0]
cmp edi, ecx
jae 0x160015384
test edi, edi
jne 0x1600153ba
mov eax, dword [rbx + 0x10]
cmp r10d, dword [r8 + rax*4 + 0x1f67f0]
jae 0x1600153c8
mov eax, dword [rbx + 0x10]
lea rdx, [rax*4 + 0x1f67f0]
mov eax, dword [rbx + 0x10]
mov eax, dword [r8 + rax*4 + 0x270d30]
cmp eax, dword [rdx + r8]
jae 0x1600153c8
mov byte [rbx + 0x1c], 0
add rsp, 0x78
pop rdi
pop rsi
pop rbp
pop rbx
ret
xor edx, edx
mov eax, ecx
sub eax, edi
mov edi, ecx
div esi
sub edi, eax
jmp 0x160015384
mov qword [rsp + 0xb8], r14
lea rax, [rbp - 1]
xor r14d, r14d
mov qword [rsp + 0x70], r15
mov dword [rbx + 0x14], r11d
cmp rax, 0xfffffffffffffffd
ja 0x1600153f1
mov qword [rsp + 0x30], rbp
mov r14d, 1
mov rcx, qword [rbx + 0x28]
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x16001542b
lea rax, [rcx - 1]
cmp rax, 0xfffffffffffffffd
ja 0x160015414
mov eax, r14d
inc r14d
mov qword [rsp + rax*8 + 0x30], rcx
test edi, edi
jne 0x16001544d
mov byte [rbx + 0x1c], dil
mov r14, qword [rsp + 0xb8]
mov r15, qword [rsp + 0x70]
jmp 0x1600153b1
xor r9d, r9d
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call qword [sym.imp.api_ms_win_core_synch_l1_1_0.dll_CreateEventW]
mov rdx, rax
lea rcx, [rbx + 0x28]
call fcn.1600161cc
mov rcx, qword [rbx + 0x28]
jmp 0x1600153ff
mov qword [rsp + 0xa8], r12
mov qword [rsp + 0xb0], r13
xor edx, edx
lea rcx, [rsp + 0x40]
lea r8d, [rdx + 0x30]
call sub.msvcrt.dll_memset
xor r9d, r9d
mov dword [rsp + 0x20], 1
xor r8d, r8d
lea rcx, [rsp + 0x40]
xor edx, edx
call qword [sym.imp.ext_ms_win_rtcore_ntuser_window_ext_l1_1_0.dll_PeekMessageW]
test eax, eax
jne 0x16007dfae
test dword [0x160274340], 0x200
jne 0x16007dfe8
mov r9d, edi
mov dword [rsp + 0x20], 0x1cff
xor r8d, r8d
lea rdx, [rsp + 0x30]
mov ecx, r14d
call qword [sym.imp.ext_ms_win_rtcore_ntuser_synch_ext_l1_1_0.dll_MsgWaitForMultipleObjects]
mov r13d, eax
call qword [sym.imp.api_ms_win_core_sysinfo_l1_1_0.dll_GetTickCount]
test dword [0x160274340], 0x200
mov r12d, eax
jne 0x16007dffd
mov ecx, dword [rbx + 0x10]
lea r8, [0x160000000]
mov eax, dword [rbx + 0x10]
mov eax, dword [r8 + rax*4 + 0x270d30]
cmp eax, dword [r8 + rcx*4 + 0x1f67f0]
jae 0x16007e012
mov eax, dword [rbx + 0x10]
sub r12d, dword [rbx + 0x14]
mov edx, dword [r8 + rax*4 + 0x270d30]
test edx, edx
je 0x160015575
mov ecx, dword [r8 + rax*4 + 0x1f67f0]
mov eax, ecx
sub eax, edx
xor edx, edx
div esi
sub ecx, eax
mov dword [rsp + 0xa0], ecx
mov eax, dword [rsp + 0xa0]
cmp r12d, eax
jb 0x16001554c
mov r13, qword [rsp + 0xb0]
mov r12, qword [rsp + 0xa8]
mov byte [rbx + 0x1c], 0
jmp 0x16001541c
mov edi, dword [rsp + 0xa0]
sub edi, r12d
cmp r13d, 0x102
je 0x16001556b
cmp r14d, r13d
jbe 0x160015579
cmp qword [rsp + r13*8 + 0x30], rbp
je 0x160015533
test edi, edi
jne 0x16001545d
jmp 0x160015533
xor ecx, ecx
jmp 0x160015520
jne 0x160015533
jmp 0x16001556b
cmp dword [rsp + 0x48], 0x12
je 0x160015533
lea rcx, [rsp + 0x40]
call qword [sym.imp.ext_ms_win_rtcore_ntuser_window_ext_l1_1_0.dll_DispatchMessageW]
xor r9d, r9d
mov dword [rsp + 0x20], 1
xor r8d, r8d
lea rcx, [rsp + 0x40]
xor edx, edx
call qword [sym.imp.ext_ms_win_rtcore_ntuser_window_ext_l1_1_0.dll_PeekMessageW]
test eax, eax
jne 0x16007dfae
jmp 0x160015490
mov r8d, edi
lea rdx, [0x1601f95b8]
call fcn.1600c260c
nop
jmp 0x1600154a0
mov r8d, r13d
lea rdx, [0x1601f9018]
call fcn.1600c260c
nop
jmp 0x1600154d8
mov rax, qword [rbx + 0x28]
dec rax
cmp rax, 0xfffffffffffffffd
ja 0x16007e027
or edi, 0xffffffff
jmp 0x160015556
mov eax, dword [rbx + 0x10]
mov edi, dword [r8 + rax*4 + 0x270d30]
jmp 0x160015556