Function at 0x4016a0
Capabilities:
Accept command line arguments
Query environment variable
Set environment variable

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x1063c
call fcn.00402430
mov eax, dword [0x413100]
xor eax, ebp
mov dword [ebp - 4], eax
mov ecx, dword [ebp + 0xc]
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov dword [ebp - 0x10638], ecx
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x10634], ecx
lea ecx, [ebp - 0x61c]
push 0x104
push ecx
push eax
mov dword [ebp - 0x1063c], eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [ebp - 0x61c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathRemoveFileSpecW]
lea eax, [ebp - 0x10630]
mov byte [ebp - 0x10624], 0
push eax
mov byte [ebp - 0x10628], 0
call dword [sym.imp.KERNEL32.dll_GetCommandLineW]
push eax
call dword [sym.imp.SHELL32.dll_CommandLineToArgvW]
mov dword [ebp - 0x1062c], eax
test eax, eax
je 0x401843
xor edi, edi
cmp dword [ebp - 0x10630], edi
jle 0x40183c
mov bl, byte [0x4241de]
lea esp, [esp]
mov edx, dword [eax + edi*4]
mov ecx, str._forceuid3d9
mov eax, edx
lea ebx, [ebx]
mov si, word [eax]
cmp si, word [ecx]
jne 0x401776
test si, si
je 0x401772
mov si, word [eax + 2]
cmp si, word [ecx + 2]
jne 0x401776
add eax, 4
add ecx, 4
test si, si
jne 0x401750
xor eax, eax
jmp 0x40177b
sbb eax, eax
or eax, 1
mov ecx, dword [ebp - 0x10624]
test eax, eax
movzx ecx, cl
mov eax, 1
cmove ecx, eax
mov eax, edx
mov dword [ebp - 0x10624], ecx
mov ecx, str._disabledxvk
jmp 0x4017a0
mov si, word [eax]
cmp si, word [ecx]
jne 0x4017c6
test si, si
je 0x4017c2
mov si, word [eax + 2]
cmp si, word [ecx + 2]
jne 0x4017c6
add eax, 4
add ecx, 4
test si, si
jne 0x4017a0
xor eax, eax
jmp 0x4017cb
sbb eax, eax
or eax, 1
mov ecx, dword [ebp - 0x10628]
test eax, eax
movzx ecx, cl
mov esi, 1
cmove ecx, esi
mov eax, str._disablenewdlldirectoryfunctions
mov dword [ebp - 0x10628], ecx
lea esp, [esp]
mov cx, word [edx]
cmp cx, word [eax]
jne 0x401816
test cx, cx
je 0x401812
mov cx, word [edx + 2]
cmp cx, word [eax + 2]
jne 0x401816
add edx, 4
add eax, 4
test cx, cx
jne 0x4017f0
xor eax, eax
jmp 0x40181b
sbb eax, eax
or eax, 1
test eax, eax
movzx ebx, bl
mov eax, dword [ebp - 0x1062c]
cmove ebx, esi
inc edi
mov byte [0x4241de], bl
cmp edi, dword [ebp - 0x10630]
jl 0x401740
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov edi, dword [sym.imp.KERNEL32.dll_SetLastError]
push 0
call edi
mov esi, dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
push 0
push 0
push str.DXVK_CONFIG_FILE
call esi
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
call ebx
cmp eax, 0xcb
push 0
setne byte [ebp - 0x1061f]
call edi
push 0
call edi
push 0
push 0
push str.BLACKMESAUI_DISABLE_INTEGRATED_QT
call esi
call ebx
cmp eax, 0xcb
push 0
setne byte [ebp - 0x1061e]
call edi
mov eax, dword [0x4241e4]
test al, 1
jne 0x4018c6
push str.wine_get_version
or eax, 1
push str.ntdll.dll
mov dword [0x4241e4], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x4241e0], eax
jmp 0x4018cb
mov eax, dword [0x4241e0]
test eax, eax
setne al
cmp byte [ebp - 0x10628], 0
je 0x401c4b
test al, al
jne 0x401c4b
xor cl, cl
xor al, al
cmp byte [ebp - 0x10624], 0
jne 0x4018fd
mov byte [ebp - 0x1061d], 0
test cl, cl
je 0x401904
mov byte [ebp - 0x1061d], 1
mov ebx, dword [sym.imp.SHLWAPI.dll_PathCanonicalizeW]
mov esi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
test al, al
je 0x401a29
call fcn.00401470
mov esi, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
test al, al
je 0x401948
push str.d3d11.dll
call esi
push 0
call edi
push str.d3d10core.dll
call esi
push 0
call edi
push str.dxgi.dll
call esi
push 0
call edi
push str.bin_thirdpartydxvk_windows_x86
lea eax, [ebp - 0x61c]
push eax
push str._ls_ls
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.004013e0
add esp, 4
cmp byte [ebp - 0x1061f], 0
jne 0x4019dc
push str.bin_thirdpartydxvk_windows_x86
lea eax, [ebp - 0x61c]
push eax
push str._ls_lsdxvk.conf
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
push str.DXVK_CONFIG_FILE
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
call fcn.00401470
test al, al
jne 0x401a23
push str.bin_thirdpartydxvk_windows_x86
lea eax, [ebp - 0x61c]
push eax
push str._ls_lsd3d9.dll
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
call esi
mov esi, dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
cmp byte [ebp - 0x1061e], 0
jne 0x401b51
push str.bin_thirdpartyqt_5.9.x_windows_x86_msvc2013_angle
lea eax, [ebp - 0x61c]
push eax
push str._ls_ls_bin
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.004013e0
add esp, 4
call fcn.00401470
test al, al
jne 0x401a90
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_SetDllDirectoryW]
push str.bin_thirdpartyqt_5.9.x_windows_x86_msvc2013_angle
lea eax, [ebp - 0x61c]
push eax
push str._ls_lspluginsplatforms
lea eax, [ebp - 0x1061c]
push 0x7fff
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x1061c]
push eax
push str.QT_QPA_PLATFORM_PLUGIN_PATH
call esi
push str.bin_thirdpartyqt_5.9.x_windows_x86_msvc2013_angle
lea eax, [ebp - 0x61c]
push eax
push str._ls_lsplugins
lea eax, [ebp - 0x1061c]
push 0x7fff
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x1061c]
push eax
push str.QT_PLUGIN_PATH
call esi
push str.bin_thirdpartyqt_5.9.x_windows_x86_msvc2013_angle
lea eax, [ebp - 0x61c]
push eax
push str._ls_lsqml
lea eax, [ebp - 0x1061c]
push 0x7fff
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x1061c]
push eax
push str.QML2_IMPORT_PATH
call esi
push str.angle
push str.QT_OPENGL
call esi
cmp byte [ebp - 0x1061d], 0
mov ecx, str.d3d11
mov eax, str.d3d9
cmove eax, ecx
push eax
push str.QT_ANGLE_PLATFORM
call esi
lea eax, [ebp - 0x61c]
push eax
push str._ls_bin
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x10
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.004013e0
add esp, 4
lea eax, [ebp - 0x61c]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.004013e0
call fcn.00401570
lea eax, [ebp - 0x61c]
push eax
push str._ls_binlauncher.dll
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.004023fb
add esp, 0x14
lea eax, [ebp - 0x414]
push eax
lea eax, [ebp - 0x20c]
push eax
call ebx
push 8
push 0
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryExW]
mov edi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov esi, eax
call edi
mov ebx, eax
test esi, esi
je 0x401c67
test ebx, ebx
jne 0x401c67
push str.LauncherMain
push esi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
call edi
test esi, esi
je 0x401c5c
test eax, eax
jne 0x401c5c
push dword [ebp + 0x14]
push dword [ebp - 0x10634]
push dword [ebp - 0x10638]
push dword [ebp - 0x1063c]
call esi
add esp, 0x10
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00402417
mov esp, ebp
pop ebp
ret 0x10
mov cl, 1
test al, al
jne 0x4018e7
mov al, cl
jmp 0x4018e9
push eax
call fcn.004014f0
add esp, 4
jmp 0x401cce
mov esi, dword [sym.imp.KERNEL32.dll_LocalAlloc]
push 0x40000
push 0x40
call esi
push 0
push 0x20000
mov edi, eax
push edi
push 0x400
push ebx
push 0
push 0x1200
call dword [sym.imp.KERNEL32.dll_FormatMessageW]
push 0x40000
push 0x40
call esi
push edi
push str.Failed_to_load_the_Launcher_DLL:_n_n_ls
mov esi, eax
push 0x20000
push esi
call fcn.004023fb
add esp, 0x10
push 0x10
push str.Launcher_Error
push esi
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_LocalFree]
call esi
push edi
call esi
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00402417
mov esp, ebp
pop ebp
ret 0x10