Function at 0x100299f0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x84
mov eax, dword [0x1003900c]
xor eax, esp
mov dword [esp + 0x80], eax
cmp dword [0x100397f4], 0
push ebx
push esi
push edi
mov esi, ecx
jne 0x10029acc
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
mov ebx, 6
test esi, esi
je 0x10029d6d
cmp esi, 1
jl 0x10029a3d
cmp esi, 4
jle 0x10029ae6
cmp esi, 5
je 0x10029d6d
cmp esi, ebx
je 0x10029d6d
cmp esi, 7
jne 0x10029d6d
push str.d3d9.dll
xor esi, esi
call edi
test eax, eax
je 0x10029a6b
mov esi, 1
jmp 0x10029abf
push str.d3d10.dll
call edi
test eax, eax
je 0x10029a7d
mov esi, 2
jmp 0x10029abf
push str.d3d11.dll
call edi
test eax, eax
je 0x10029a8f
mov esi, 3
jmp 0x10029abf
push str.d3d12.dll
call edi
test eax, eax
je 0x10029aa1
mov esi, 4
jmp 0x10029abf
push str.opengl32.dll
call edi
test eax, eax
je 0x10029ab3
mov esi, 5
jmp 0x10029abf
push str.vulcan_1.dll
call edi
test eax, eax
cmovne esi, ebx
cmp dword [0x100397f4], 0
je 0x10029a27
mov eax, 0xfffffffc
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x80]
xor ecx, esp
call fcn.1002bf1a
mov esp, ebp
pop ebp
ret
mov eax, dword [sym.imp.USER32.dll_DefWindowProcA]
push 0
mov dword [esp + 0x18], 0x30
mov dword [esp + 0x1c], 3
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], 0
mov dword [esp + 0x28], 0
call edi
mov dword [esp + 0x28], eax
xorps xmm0, xmm0
lea eax, [esp + 0x14]
mov dword [esp + 0x3c], str.Kiero
push eax
movups xmmword [esp + 0x30], xmm0
mov dword [esp + 0x44], 0
call dword [sym.imp.USER32.dll_RegisterClassExA]
push 0
push dword [esp + 0x2c]
push 0
push 0
push 0x64
push 0x64
push 0
push 0
push 0xcf0000
push str.Kiero_DirectX_Window
push dword [esp + 0x64]
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov ebx, eax
cmp esi, 1
jne 0x10029d84
push str.d3d9.dll
call edi
test eax, eax
jne 0x10029ba5
push ebx
call dword [sym.imp.USER32.dll_DestroyWindow]
push dword [esp + 0x28]
push dword [esp + 0x40]
call dword [sym.imp.USER32.dll_UnregisterClassA]
lea eax, [esi - 4]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x80]
xor ecx, esp
call fcn.1002bf1a
mov esp, ebp
pop ebp
ret
push str.Direct3DCreate9
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x10029c7f
push 0x20
call eax
mov esi, eax
mov dword [esp + 0xc], esi
test esi, esi
je 0x10029c7f
mov eax, dword [esi]
lea ecx, [esp + 0x7c]
push ecx
push 0
push esi
call dword [eax + 0x20]
test eax, eax
js 0x10029c7f
mov eax, dword [esp + 0x88]
lea ecx, [esp + 0x10]
push ecx
lea ecx, [esp + 0x48]
mov dword [esp + 0x48], 0
push ecx
push 0x120
push ebx
push 1
mov dword [esp + 0x5c], 0
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], 0
mov dword [esp + 0x68], 0
mov dword [esp + 0x6c], 0
mov dword [esp + 0x70], 1
mov dword [esp + 0x74], ebx
mov dword [esp + 0x78], 1
mov dword [esp + 0x7c], 0
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov eax, dword [esi]
push 0
push esi
call dword [eax + 0x40]
test eax, eax
jns 0x10029cac
mov eax, dword [esi]
push esi
call dword [eax + 8]
push ebx
call dword [sym.imp.USER32.dll_DestroyWindow]
push dword [esp + 0x28]
push dword [esp + 0x40]
call dword [sym.imp.USER32.dll_UnregisterClassA]
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x80]
xor ecx, esp
call fcn.1002bf1a
mov esp, ebp
pop ebp
ret
push 4
push 0x77
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_calloc]
mov esi, dword [esp + 0x18]
mov edi, eax
mov dword [0x100397f0], eax
mov ecx, 0x77
add esp, 8
xor eax, eax
mov esi, dword [esi]
rep movsd dword es:[edi], dword [esi]
xor esi, esi
mov ecx, 1
mov edi, 0x100397a4
lock cmpxchg dword [edi], ecx
test eax, eax
je 0x10029d14
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
nop dword [eax]
cmp esi, 0x20
jae 0x10029cf9
push 0
jmp 0x10029cfb
push 1
call edi
inc esi
mov ecx, 1
xor eax, eax
mov edx, 0x100397a4
lock cmpxchg dword [edx], ecx
test eax, eax
jne 0x10029cf0
mov edi, edx
cmp dword [0x100397a8], 0
jne 0x10029d2e
push 0
push 0
push 0
call dword [sym.imp.KERNEL32.dll_HeapCreate]
mov dword [0x100397a8], eax
xor eax, eax
xchg dword [edi], eax
mov ecx, dword [esp + 0xc]
push ecx
mov eax, dword [ecx]
call dword [eax + 8]
mov eax, dword [esp + 0x10]
push eax
mov ecx, dword [eax]
call dword [ecx + 8]
push ebx
mov dword [esp + 0x14], 0
mov dword [0x100397f4], 1
call dword [sym.imp.USER32.dll_DestroyWindow]
push dword [esp + 0x28]
push dword [esp + 0x40]
call dword [sym.imp.USER32.dll_UnregisterClassA]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x80]
xor ecx, esp
call fcn.1002bf1a
mov esp, ebp
pop ebp
ret
push ebx
call dword [sym.imp.USER32.dll_DestroyWindow]
push dword [esp + 0x28]
push dword [esp + 0x40]
call dword [sym.imp.USER32.dll_UnregisterClassA]
mov ecx, dword [esp + 0x8c]
mov eax, 0xfffffffe
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.1002bf1a
mov esp, ebp
pop ebp
ret