Function at 0x180047d50
Capabilities:
Resume thread

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x10], rbp
mov qword [rsp + 0x18], rsi
mov qword [rsp + 0x20], rdi
push r12
push r14
push r15
sub rsp, 0x30
xor ebx, ebx
mov r12d, 1
xor eax, eax
lock cmpxchg dword [0x1800f9ed4], r12d
je 0x180004df6
cmp rbx, 0x20
jae 0x180004ddd
xor ecx, ecx
jmp 0x180004de0
mov ecx, r12d
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x1800f9ed4], r12d
jne 0x180004dd3
cmp qword [0x1800f9ee0], 0
jne 0x180004e14
xor r8d, r8d
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_HeapCreate]
mov qword [0x1800f9ee0], rax
xor eax, eax
lea rcx, str.opengl32.dll
xchg dword [0x1800f9ed4], eax
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rcx, str.Kernel32.dll
mov r14, rax
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rcx, str.Winmm.dll
mov rbp, rax
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rcx, [0x1800ddd28]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea rdx, str.wglSwapBuffers
mov rcx, r14
mov rbx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, [0x1800ddd48]
mov rcx, r14
mov r15, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.WSASend
mov rcx, rbx
mov rsi, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.GetTickCount
mov rcx, rbp
mov rdi, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.GetTickCount64
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.timeGetTime
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, [0x1800ddd90]
mov rcx, rbp
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea rdx, str.glCallList
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
lea r8, [0x1800f13c0]
mov rcx, rdi
lea rdx, [0x180004d80]
mov rbx, rax
call fcn.1800479e0
lea r8, [0x1800f9e38]
mov rcx, rsi
lea rdx, [0x180004490]
call fcn.1800479e0
lea r8, [0x1800f9e40]
mov rcx, r15
lea rdx, [0x180003c70]
call fcn.1800479e0
lea r8, [0x1800f9e30]
mov rcx, rbx
lea rdx, [0x180003ac0]
call fcn.1800479e0
xor r9d, r9d
mov qword [rsp + 0x28], 0
lea r8, [0x180003bc0]
mov dword [rsp + 0x20], 0
xor edx, edx
xor ecx, ecx
call qword [sym.imp.KERNEL32.dll_CreateThread]
mov edx, r12d
call fcn.180047cc0
mov rbx, qword [rsp + 0x50]
mov rbp, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x60]
mov rdi, qword [rsp + 0x68]
add rsp, 0x30
pop r15
pop r14
pop r12
jmp 0x180047d50
mov qword [rsp + 0x10], rbx
mov qword [rsp + 0x18], rbp
mov qword [rsp + 0x20], rdi
push r15
sub rsp, 0x30
xor r15d, r15d
mov edi, 1
mov ebp, r15d
mov ebx, r15d
xor eax, eax
lock cmpxchg dword [0x1800f9ed4], edi
je 0x180047da1
nop
cmp rbx, 0x20
jae 0x180047d8a
xor ecx, ecx
jmp 0x180047d8c
mov ecx, edi
call qword [sym.imp.KERNEL32.dll_Sleep]
inc rbx
xor eax, eax
lock cmpxchg dword [0x1800f9ed4], edi
jne 0x180047d80
cmp qword [0x1800f9ee0], rbp
je 0x180047ecd
mov r8d, dword [0x1800fa0bc]
mov ebx, r15d
test r8d, r8d
je 0x180047ed2
mov rdx, qword [0x1800fa0b0]
add rdx, 0x20
nop dword [rax]
movzx ecx, byte [rdx]
shr cl, 1
xor cl, byte [rdx]
test cl, 2
jne 0x180047dec
inc ebx
add rdx, 0x38
cmp ebx, r8d
jb 0x180047dd0
jmp 0x180047ed2
cmp ebx, 0xffffffff
je 0x180047ed2
mov edx, 0xffffffff
lea rcx, [rsp + 0x20]
mov r8d, 2
call fcn.1800475b0
mov edx, dword [0x1800fa0bc]
cmp ebx, edx
jae 0x180047e61
nop dword [rax]
nop dword [rax + rax]
mov eax, ebx
imul rcx, rax, 0x38
mov rax, qword [0x1800fa0b0]
movzx r8d, byte [rcx + rax + 0x20]
movzx eax, r8b
shr al, 1
xor al, r8b
test al, 2
je 0x180047e5b
mov edx, r8d
mov ecx, ebx
shr edx, 2
and edx, edi
call fcn.180047760
mov ebp, eax
test eax, eax
jne 0x180047e61
mov edx, dword [0x1800fa0bc]
inc ebx
cmp ebx, edx
jb 0x180047e20
cmp qword [rsp + 0x20], r15
je 0x180047ed2
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x180047eb7
mov rbx, qword [rsp + 0x20]
mov qword [rsp + 0x40], rsi
mov esi, eax
nop dword [rax]
mov r8d, dword [rbx]
xor edx, edx
lea ecx, [rdx + 0x5a]
call qword [sym.imp.KERNEL32.dll_OpenThread]
mov rdi, rax
test rax, rax
je 0x180047ea8
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_ResumeThread]
mov rcx, rdi
call qword [sym.imp.KERNEL32.dll_CloseHandle]
add rbx, 4
sub rsi, 1
jne 0x180047e80
mov rsi, qword [rsp + 0x40]
mov r8, qword [rsp + 0x20]
xor edx, edx
mov rcx, qword [0x1800f9ee0]
call qword [sym.imp.KERNEL32.dll_HeapFree]
jmp 0x180047ed2
mov ebp, 2
xchg dword [0x1800f9ed4], r15d
mov rbx, qword [rsp + 0x48]
mov eax, ebp
mov rbp, qword [rsp + 0x50]
mov rdi, qword [rsp + 0x58]
add rsp, 0x30
pop r15
ret