Function at 0x18006bd90
Capabilities:
Link many functions at runtime

Disassembly:
mov r11, rsp
push rbp
push rsi
lea rbp, [r11 - 0xa8]
sub rsp, 0x198
mov rax, qword [0x1801044f8]
xor rax, rsp
mov qword [rbp + 0x80], rax
mov esi, ecx
test ecx, ecx
je 0x18006c754
mov qword [r11 + 8], rbx
mov qword [r11 + 0x10], rdi
mov qword [r11 + 0x18], r14
cmp ecx, 1
jl 0x18006c5ac
cmp ecx, 4
jg 0x18006c5ac
mov rax, qword [sym.imp.USER32.dll_DefWindowProcW]
xor edi, edi
xor ecx, ecx
mov qword [rbp - 0x78], rax
mov qword [rbp - 0x70], rdi
mov dword [rbp - 0x80], 0x50
mov dword [rbp - 0x7c], 3
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
xorps xmm0, xmm0
mov qword [rbp - 0x38], rdi
mov qword [rbp - 0x68], rax
lea rcx, [rbp - 0x80]
lea rax, str.Kiero
movdqa xmmword [rbp - 0x60], xmm0
xorps xmm1, xmm1
mov qword [rbp - 0x40], rax
movdqa xmmword [rbp - 0x50], xmm1
call qword [sym.imp.USER32.dll_RegisterClassExW]
mov rax, qword [rbp - 0x68]
lea r8, str.Kiero_DirectX_Window
mov rdx, qword [rbp - 0x40]
mov r9d, 0xcf0000
mov qword [rsp + 0x58], rdi
xor ecx, ecx
mov qword [rsp + 0x50], rax
mov qword [rsp + 0x48], rdi
mov qword [rsp + 0x40], rdi
mov dword [rsp + 0x38], 0x64
mov dword [rsp + 0x30], 0x64
mov dword [rsp + 0x28], edi
mov dword [rsp + 0x20], edi
call qword [sym.imp.USER32.dll_CreateWindowExW]
mov rbx, rax
cmp esi, 1
jne 0x18006c065
lea rcx, str.d3d9.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
je 0x18006c2e4
lea rdx, str.Direct3DCreate9
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18006bf3d
lea ecx, [rdi + 0x20]
call rax
mov rsi, rax
test rax, rax
je 0x18006bf3d
mov rax, qword [rax]
lea r8, [rbp + 0x30]
xor edx, edx
mov rcx, rsi
call qword [rax + 0x40]
test eax, eax
js 0x18006bf3d
mov eax, dword [rbp + 0x3c]
lea rcx, [rsp + 0x60]
mov qword [rsp + 0x30], rcx
lea r8d, [rdi + 1]
mov qword [rbp + 0x40], rdi
lea rcx, [rbp + 0x40]
mov qword [rsp + 0x28], rcx
mov r9, rbx
mov dword [rbp + 0x48], eax
mov rcx, rsi
mov qword [rbp + 0x4c], rdi
xor edx, edx
mov dword [rbp + 0x54], edi
mov dword [rbp + 0x58], 1
mov qword [rbp + 0x60], rbx
mov qword [rbp + 0x68], 1
mov qword [rbp + 0x70], rdi
mov qword [rbp + 0x78], rdi
mov rax, qword [rsi]
mov dword [rsp + 0x20], 0x120
call qword [rax + 0x80]
test eax, eax
jns 0x18006bf5e
mov rax, qword [rsi]
mov rcx, rsi
call qword [rax + 0x10]
mov rcx, rbx
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [rbp - 0x68]
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.USER32.dll_UnregisterClassW]
mov eax, 0xffffffff
jmp 0x18006c034
mov edx, 8
lea ecx, [rdx + 0x6f]
call fcn.18009a53c
mov rcx, qword [rsp + 0x60]
mov rdx, rax
mov qword [0x180108898], rax
mov rax, qword [rcx]
mov ecx, 7
lea rdx, [rdx + 0x80]
movups xmm0, xmmword [rax]
lea rax, [rax + 0x80]
movups xmmword [rdx - 0x80], xmm0
movups xmm1, xmmword [rax - 0x70]
movups xmmword [rdx - 0x70], xmm1
movups xmm0, xmmword [rax - 0x60]
movups xmmword [rdx - 0x60], xmm0
movups xmm1, xmmword [rax - 0x50]
movups xmmword [rdx - 0x50], xmm1
movups xmm0, xmmword [rax - 0x40]
movups xmmword [rdx - 0x40], xmm0
movups xmm1, xmmword [rax - 0x30]
movups xmmword [rdx - 0x30], xmm1
movups xmm0, xmmword [rax - 0x20]
movups xmmword [rdx - 0x20], xmm0
movups xmm1, xmmword [rax - 0x10]
movups xmmword [rdx - 0x10], xmm1
sub rcx, 1
jne 0x18006bf82
movups xmm0, xmmword [rax]
movups xmmword [rdx], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rdx + 0x10], xmm1
movups xmm0, xmmword [rax + 0x20]
movups xmmword [rdx + 0x20], xmm0
mov rax, qword [rax + 0x30]
mov qword [rdx + 0x30], rax
call fcn.18008e7e0
mov rax, qword [rsi]
mov rcx, rsi
call qword [rax + 0x10]
mov rcx, qword [rsp + 0x60]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, rbx
mov qword [rsp + 0x60], rdi
mov dword [0x180108890], 1
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [rbp - 0x68]
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.USER32.dll_UnregisterClassW]
xor eax, eax
mov rdi, qword [rsp + 0x1b8]
mov rbx, qword [rsp + 0x1b0]
mov r14, qword [rsp + 0x1c0]
mov rcx, qword [rbp + 0x80]
xor rcx, rsp
call fcn.180093c30
add rsp, 0x198
pop rsi
pop rbp
ret
cmp esi, 2
jne 0x18006c2c9
lea rcx, str.dxgi.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov rsi, rax
test rax, rax
je 0x18006c2e4
lea rcx, str.d3d10.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov r14, rax
test rax, rax
je 0x18006c2e4
lea rdx, str.CreateDXGIFactory
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18006bf3d
lea rdx, [rbp + 0x30]
lea rcx, [0x1800d0408]
call rax
test eax, eax
js 0x18006bf3d
mov rcx, qword [rbp + 0x30]
lea r8, [rsp + 0x70]
xor edx, edx
mov rax, qword [rcx]
call qword [rax + 0x38]
cmp eax, 0x887a0002
je 0x18006bf3d
lea rdx, str.D3D10CreateDeviceAndSwapChain
mov rcx, r14
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18006bf3d
lea rcx, [rsp + 0x68]
mov dword [rbp + 0x40], 0x64
mov qword [rsp + 0x38], rcx
mov esi, 2
lea rcx, [rsp + 0x60]
mov dword [rbp + 0x44], 0x64
mov qword [rsp + 0x30], rcx
xor r9d, r9d
lea rcx, [rbp - 0x20]
mov dword [rbp + 0x48], 0x3c
mov qword [rsp + 0x28], rcx
xor r8d, r8d
mov rcx, qword [rsp + 0x70]
xor edx, edx
mov dword [rbp + 0x4c], 1
movups xmm0, xmmword [rbp + 0x40]
mov qword [rbp + 0x50], 0x1c
movsd xmm1, qword [rbp + 0x50]
movaps xmmword [rbp - 0x20], xmm0
movsd qword [rbp - 0x10], xmm1
mov dword [rbp - 8], edi
mov qword [rbp - 4], 1
mov dword [rbp + 4], 0x20
mov dword [rbp + 8], 1
mov qword [rbp + 0x10], rbx
mov qword [rbp + 0x18], 1
mov dword [rbp + 0x20], esi
mov dword [rsp + 0x20], 0x1d
call rax
test eax, eax
js 0x18006bf3d
lea edx, [rsi + 6]
lea ecx, [rsi + 0x72]
call fcn.18009a53c
mov rcx, qword [rsp + 0x60]
mov r8, rax
mov qword [0x180108898], rax
add r8, 0x90
mov rdx, qword [rcx]
movups xmm0, xmmword [rdx]
movups xmmword [rax], xmm0
movups xmm1, xmmword [rdx + 0x10]
movups xmmword [rax + 0x10], xmm1
movups xmm0, xmmword [rdx + 0x20]
movups xmmword [rax + 0x20], xmm0
movups xmm1, xmmword [rdx + 0x30]
movups xmmword [rax + 0x30], xmm1
movups xmm0, xmmword [rdx + 0x40]
movups xmmword [rax + 0x40], xmm0
movups xmm1, xmmword [rdx + 0x50]
movups xmmword [rax + 0x50], xmm1
movups xmm0, xmmword [rdx + 0x60]
movups xmmword [rax + 0x60], xmm0
movups xmm1, xmmword [rdx + 0x70]
movups xmmword [rax + 0x70], xmm1
movups xmm0, xmmword [rdx + 0x80]
movups xmmword [rax + 0x80], xmm0
mov rax, qword [rsp + 0x68]
mov rcx, qword [rax]
lea eax, [rsi + 4]
nop dword [rax]
lea r8, [r8 + 0x80]
movups xmm0, xmmword [rcx]
lea rcx, [rcx + 0x80]
movups xmmword [r8 - 0x80], xmm0
movups xmm1, xmmword [rcx - 0x70]
movups xmmword [r8 - 0x70], xmm1
movups xmm0, xmmword [rcx - 0x60]
movups xmmword [r8 - 0x60], xmm0
movups xmm1, xmmword [rcx - 0x50]
movups xmmword [r8 - 0x50], xmm1
movups xmm0, xmmword [rcx - 0x40]
movups xmmword [r8 - 0x40], xmm0
movups xmm1, xmmword [rcx - 0x30]
movups xmmword [r8 - 0x30], xmm1
movups xmm0, xmmword [rcx - 0x20]
movups xmmword [r8 - 0x20], xmm0
movups xmm1, xmmword [rcx - 0x10]
movups xmmword [r8 - 0x10], xmm1
sub rax, 1
jne 0x18006c220
movups xmm0, xmmword [rcx]
movups xmmword [r8], xmm0
call fcn.18008e7e0
mov rcx, qword [rsp + 0x60]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rsp + 0x68]
mov qword [rsp + 0x60], rdi
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, rbx
mov qword [rsp + 0x68], rdi
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [rbp - 0x68]
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.USER32.dll_UnregisterClassW]
mov dword [0x180108890], esi
jmp 0x18006c032
cmp esi, 3
jne 0x18006c74a
lea rcx, [0x1800d04a8]
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
test rax, rax
jne 0x18006c305
mov rcx, rbx
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [rbp - 0x68]
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.USER32.dll_UnregisterClassW]
mov eax, 0xfffffffd
jmp 0x18006c034
lea rdx, str.D3D11CreateDeviceAndSwapChain
mov rcx, rax
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
test rax, rax
je 0x18006bf3d
lea rcx, [rsp + 0x70]
mov dword [rbp + 0x40], 0x64
mov qword [rsp + 0x58], rcx
mov esi, 2
lea rcx, [rsp + 0x60]
mov dword [rbp + 0x44], 0x64
mov qword [rsp + 0x50], rcx
xor r9d, r9d
lea rcx, [rbp - 0x30]
mov dword [rbp + 0x48], 0x3c
mov qword [rsp + 0x48], rcx
lea edx, [rsi - 1]
lea rcx, [rsp + 0x68]
mov dword [rbp + 0x4c], 1
movups xmm0, xmmword [rbp + 0x40]
mov qword [rsp + 0x40], rcx
xor r8d, r8d
lea rcx, [rbp - 0x20]
mov qword [rbp + 0x50], 0x1c
movsd xmm1, qword [rbp + 0x50]
mov qword [rsp + 0x38], rcx
lea rcx, [rbp + 0x30]
mov dword [rsp + 0x30], 7
mov dword [rsp + 0x28], 1
mov qword [rsp + 0x20], rcx
xor ecx, ecx
mov dword [rbp + 0x30], 0xa100
mov dword [rbp + 0x34], 0xb000
movaps xmmword [rbp - 0x20], xmm0
movsd qword [rbp - 0x10], xmm1
mov dword [rbp - 8], edi
mov qword [rbp - 4], 1
mov dword [rbp + 4], 0x20
mov dword [rbp + 8], 1
mov qword [rbp + 0x10], rbx
mov qword [rbp + 0x18], 1
mov dword [rbp + 0x20], esi
call rax
test eax, eax
js 0x18006bf3d
lea edx, [rsi + 6]
mov ecx, 0xcd
call fcn.18009a53c
mov rcx, qword [rsp + 0x68]
mov r8, rax
mov qword [0x180108898], rax
mov rdx, qword [rcx]
lea rcx, [r8 + 0x90]
movups xmm0, xmmword [rdx]
movups xmmword [rax], xmm0
movups xmm1, xmmword [rdx + 0x10]
movups xmmword [rax + 0x10], xmm1
movups xmm0, xmmword [rdx + 0x20]
movups xmmword [rax + 0x20], xmm0
movups xmm1, xmmword [rdx + 0x30]
movups xmmword [rax + 0x30], xmm1
movups xmm0, xmmword [rdx + 0x40]
movups xmmword [rax + 0x40], xmm0
movups xmm1, xmmword [rdx + 0x50]
movups xmmword [rax + 0x50], xmm1
movups xmm0, xmmword [rdx + 0x60]
movups xmmword [rax + 0x60], xmm0
movups xmm1, xmmword [rdx + 0x70]
movups xmmword [rax + 0x70], xmm1
movups xmm0, xmmword [rdx + 0x80]
movups xmmword [rax + 0x80], xmm0
mov rax, qword [rbp - 0x30]
mov rax, qword [rax]
lea rcx, [rcx + 0x80]
movups xmm0, xmmword [rax]
lea rax, [rax + 0x80]
movups xmmword [rcx - 0x80], xmm0
movups xmm1, xmmword [rax - 0x70]
movups xmmword [rcx - 0x70], xmm1
movups xmm0, xmmword [rax - 0x60]
movups xmmword [rcx - 0x60], xmm0
movups xmm1, xmmword [rax - 0x50]
movups xmmword [rcx - 0x50], xmm1
movups xmm0, xmmword [rax - 0x40]
movups xmmword [rcx - 0x40], xmm0
movups xmm1, xmmword [rax - 0x30]
movups xmmword [rcx - 0x30], xmm1
movups xmm0, xmmword [rax - 0x20]
movups xmmword [rcx - 0x20], xmm0
movups xmm1, xmmword [rax - 0x10]
movups xmmword [rcx - 0x10], xmm1
sub rsi, 1
jne 0x18006c466
movups xmm0, xmmword [rax]
lea edx, [rsi + 9]
movups xmmword [rcx], xmm0
movups xmm1, xmmword [rax + 0x10]
movups xmmword [rcx + 0x10], xmm1
movups xmm0, xmmword [rax + 0x20]
movups xmmword [rcx + 0x20], xmm0
movups xmm1, xmmword [rax + 0x30]
movups xmmword [rcx + 0x30], xmm1
movups xmm0, xmmword [rax + 0x40]
movups xmmword [rcx + 0x40], xmm0
mov rax, qword [rax + 0x50]
mov qword [rcx + 0x50], rax
mov rax, qword [rsp + 0x70]
mov rcx, qword [rax]
lea rax, [r8 + 0x1e8]
nop dword [rax]
lea rax, [rax + 0x80]
movups xmm0, xmmword [rcx]
lea rcx, [rcx + 0x80]
movups xmmword [rax - 0x80], xmm0
movups xmm1, xmmword [rcx - 0x70]
movups xmmword [rax - 0x70], xmm1
movups xmm0, xmmword [rcx - 0x60]
movups xmmword [rax - 0x60], xmm0
movups xmm1, xmmword [rcx - 0x50]
movups xmmword [rax - 0x50], xmm1
movups xmm0, xmmword [rcx - 0x40]
movups xmmword [rax - 0x40], xmm0
movups xmm1, xmmword [rcx - 0x30]
movups xmmword [rax - 0x30], xmm1
movups xmm0, xmmword [rcx - 0x20]
movups xmmword [rax - 0x20], xmm0
movups xmm1, xmmword [rcx - 0x10]
movups xmmword [rax - 0x10], xmm1
sub rdx, 1
jne 0x18006c500
call fcn.18008e7e0
mov rcx, qword [rsp + 0x68]
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rbp - 0x30]
mov qword [rsp + 0x68], rdi
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, qword [rsp + 0x70]
mov qword [rbp - 0x30], rdi
mov rax, qword [rcx]
call qword [rax + 0x10]
mov rcx, rbx
mov qword [rsp + 0x70], rdi
call qword [sym.imp.USER32.dll_DestroyWindow]
mov rdx, qword [rbp - 0x68]
mov rcx, qword [rbp - 0x40]
call qword [sym.imp.USER32.dll_UnregisterClassW]
mov dword [0x180108890], 3
jmp 0x18006c032
cmp esi, 5
jne 0x18006c6c1
lea rcx, str.opengl32.dll
call fcn.18006b930
mov rsi, rax
test rax, rax
je 0x18006c2fb
lea rax, str.glBegin
mov qword [rsp + 0x190], r15
mov qword [rbp + 0x40], rax
mov edx, 8
lea rax, str.glEnd
mov qword [rbp + 0x48], rax
lea rax, str.wglSwapBuffers
mov qword [rbp + 0x50], rax
lea rax, str.glFinish
lea ecx, [rdx - 4]
mov qword [rbp + 0x58], rax
call fcn.18009a53c
xor edi, edi
mov qword [0x180108898], rax
mov r14d, edi
mov r15d, 0x10
lea rbx, [rbp + 0x40]
mov rcx, rsi
add rbx, r15
mov rdx, qword [rbx - 0x10]
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x180108898]
mov rdx, qword [rbx - 8]
mov qword [r14 + rcx], rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rdx, qword [rbx]
lea rcx, [rbp + 0x48]
mov r8, rbx
sub r8, rcx
mov rcx, qword [0x180108898]
mov qword [r8 + rcx], rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x180108898]
mov rdx, qword [rbx + 8]
mov qword [r15 + rcx], rax
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x180108898]
lea r14, [r14 + 0x20]
add edi, 4
add r15, 0x20
mov qword [r14 + rcx - 8], rax
cmp edi, 4
jb 0x18006c620
mov r15, qword [rsp + 0x190]
call fcn.18008e7e0
mov dword [0x180108890], 5
jmp 0x18006c032
cmp esi, 6
jne 0x18006c74a
lea rcx, str.libEGL.dll
call qword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov rsi, rax
test rax, rax
je 0x18006c2fb
mov edx, 8
lea rax, str.eglSwapBuffers
mov qword [rbp + 0x30], rax
lea ecx, [rdx - 7]
call fcn.18009a53c
xor edi, edi
mov qword [0x180108898], rax
mov ebx, edi
nop word [rax + rax]
mov rdx, qword [rbp + rbx + 0x30]
mov rcx, rsi
call qword [sym.imp.KERNEL32.dll_GetProcAddress]
mov rcx, qword [0x180108898]
lea rbx, [rbx + 8]
inc edi
mov qword [rbx + rcx - 8], rax
cmp edi, 1
jb 0x18006c710
call fcn.18008e7e0
mov eax, 6
mov dword [0x180108890], eax
jmp 0x18006c032
mov eax, 0xfffffffe
jmp 0x18006c034
xor eax, eax
jmp 0x18006c04c