Function at 0x417140
Capabilities:
Read .ini file

Disassembly:
sub esp, 8
push ebx
push ebp
push esi
mov esi, ecx
push edi
mov ecx, dword [esi + 0x120]
test ecx, ecx
je 0x417169
mov eax, dword [ecx]
push 1
call dword [eax]
call dword [sym.imp.core.dll_bool___cdecl_UnloadGraphicsAPI_void_]
mov dword [esi + 0x120], 0
lea ecx, [esp + 0x14]
lea edx, [esp + 0x10]
push ecx
push edx
call sub.DSETUP.dll_Ordinal_11
mov ebp, dword [sym.imp.core.dll_bool___cdecl_LoadGraphicsAPI_char_const__]
mov edi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
test eax, eax
je 0x417231
cmp word [esp + 0x10], 8
jb 0x417231
mov eax, dword [esi + 0x10]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
lea ebx, [eax + 0x1004]
add eax, 4
push eax
push 0x1000
push ebx
push str.gfx2d_dx8.dll
push str.GraphicsAPI_1
push ecx
call edi
test eax, eax
jne 0x4171c7
mov ebx, 0x4288d8
push ebx
call ebp
add esp, 4
test al, al
jne 0x417213
mov eax, dword [esi + 0x10]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
lea ebx, [eax + 0x1004]
add eax, 4
push eax
push 0x1000
push ebx
push str.gfx2d_dx8.dll
push str.GraphicsAPI_1
push ecx
call edi
test eax, eax
jne 0x417200
mov ebx, 0x4288d8
push ebx
push str.Failed_to_load_graphics_API:_CFFFF00_sc_f
push 2
call dword [sym.imp.logger.dll_public:_static_void___cdecl_udLogger::log_int__char_const__]
add esp, 0xc
jmp 0x417231
mov eax, dword [sym.imp.core.dll_class_gfxSubsystem_____stdcall___void__gfxCreateGfxSubsystem]
call dword [eax]
mov ecx, esi
mov dword [esi + 0x120], eax
call fcn.00417020
test al, al
jne 0x417231
call dword [sym.imp.core.dll_bool___cdecl_UnloadGraphicsAPI_void_]
mov eax, dword [esi + 0x120]
test eax, eax
jne 0x4173a0
call dword [sym.imp.core.dll_enum_e_OperatingSystem___cdecl_Platform::GetPlatformOS_void_]
cmp eax, 2
jle 0x4172e8
mov eax, dword [esi + 0x10]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
lea ebx, [eax + 0x1004]
add eax, 4
push eax
push 0x1000
push ebx
push str.gfx2d_ogl.dll
push str.GraphicsAPI_2
push ecx
call edi
test eax, eax
jne 0x41727d
mov ebx, 0x4288d8
push ebx
call ebp
add esp, 4
test al, al
jne 0x4172c9
mov eax, dword [esi + 0x10]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
lea ebx, [eax + 0x1004]
add eax, 4
push eax
push 0x1000
push ebx
push str.gfx2d_ogl.dll
push str.GraphicsAPI_2
push ecx
call edi
test eax, eax
jne 0x4172b6
mov ebx, 0x4288d8
push ebx
push str.Failed_to_load_graphics_API:_CFFFF00_sc_f
push 2
call dword [sym.imp.logger.dll_public:_static_void___cdecl_udLogger::log_int__char_const__]
add esp, 0xc
jmp 0x4172e8
mov ecx, dword [sym.imp.core.dll_class_gfxSubsystem_____stdcall___void__gfxCreateGfxSubsystem]
call dword [ecx]
mov ecx, esi
mov dword [esi + 0x120], eax
call fcn.00417020
test al, al
jne 0x4172e8
call dword [sym.imp.core.dll_bool___cdecl_UnloadGraphicsAPI_void_]
mov eax, dword [esi + 0x120]
test eax, eax
jne 0x4173a0
mov eax, dword [esi + 0x10]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
lea ebx, [eax + 0x1004]
add eax, 4
push eax
push 0x1000
push ebx
push str.gfx2d_dd7.dll
push str.GraphicsAPI_3
push ecx
call edi
test eax, eax
jne 0x417325
mov ebx, 0x4288d8
push ebx
call ebp
add esp, 4
test al, al
jne 0x417379
mov esi, dword [esi + 0x10]
mov eax, dword [esi + 8]
mov esi, dword [esi + 4]
lea ebx, [esi + 0x1004]
add esi, 4
push esi
push 0x1000
push ebx
push str.gfx2d_dd7.dll
push str.GraphicsAPI_3
push eax
call edi
test eax, eax
jne 0x41735e
mov ebx, 0x4288d8
push ebx
push str.Failed_to_load_alt_graphics_API:_CFFFF00_sc_f
push 2
call dword [sym.imp.logger.dll_public:_static_void___cdecl_udLogger::log_int__char_const__]
add esp, 0xc
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 8
ret
mov edx, dword [sym.imp.core.dll_class_gfxSubsystem_____stdcall___void__gfxCreateGfxSubsystem]
call dword [edx]
mov ecx, esi
mov dword [esi + 0x120], eax
call fcn.00417020
test al, al
jne 0x417398
call dword [sym.imp.core.dll_bool___cdecl_UnloadGraphicsAPI_void_]
mov eax, dword [esi + 0x120]
test eax, eax
pop edi
pop esi
pop ebp
pop ebx
setne al
add esp, 8
ret