Function at 0x401000
Capabilities:
Create thread
Get common file path
Inject dll
Inject thread

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x402257
mov eax, dword fs:[0]
push eax
sub esp, 0x114
mov eax, dword [0x405004]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push 0x1c
call fcn.004014fa
mov edi, eax
add esp, 4
mov dword [ebp - 0x118], edi
xorps xmm0, xmm0
mov ecx, edi
movups xmmword [edi], xmm0
movq qword [edi + 0x10], xmm0
mov dword [edi + 0x18], 0
mov dword [edi], 0
movups xmmword [edi + 4], xmm0
mov dword [edi + 0x14], 7
mov dword [edi + 0x18], 0xf
mov eax, dword [str.hl2.exe]
mov dword [edi + 4], eax
mov ax, word [0x4031a8]
mov word [edi + 8], ax
mov al, byte [0x4031aa]
mov byte [edi + 0xa], al
mov byte [edi + 0xb], 0
call fcn.004012c0
test eax, eax
jne 0x4010ae
cmp dword [edi + 0x18], 0x10
lea eax, [edi + 4]
jb 0x40109e
mov eax, dword [edi + 4]
push eax
push str.Failed_getting__s_process_ID__Make_sure_your_game_is_running_and_its_called_hl2.exe_n
call fcn.00401290
add esp, 8
jmp 0x4010c3
push eax
push 0
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [edi], eax
cmp eax, 0xffffffff
jne 0x4010d0
push str.Failed_process_initialization._n
call fcn.00401290
add esp, 4
lea eax, [ebp - 0x114]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetCurrentDirectoryA]
push str.VR.dll
lea eax, [ebp - 0x114]
push 0x104
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strcat_s]
push str.DLL_Path:
call fcn.00401290
lea eax, [ebp - 0x114]
push eax
call fcn.00401290
add esp, 0x14
push str.LoadLibraryA
push str.kernel32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x118], eax
test eax, eax
je 0x4011ed
lea ecx, [ebp - 0x114]
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401140
sub ecx, edx
push 4
push 0x3000
lea eax, [ecx + 1]
push eax
push 0
push dword [edi]
call dword [sym.imp.KERNEL32.dll_VirtualAllocEx]
mov edx, eax
mov dword [ebp - 0x11c], edx
test edx, edx
je 0x4011ed
lea ecx, [ebp - 0x114]
lea eax, [ecx + 1]
mov dword [ebp - 0x120], eax
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401180
sub ecx, dword [ebp - 0x120]
push 0
lea eax, [ecx + 1]
push eax
lea eax, [ebp - 0x114]
push eax
push edx
push dword [edi]
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
je 0x4011ed
push 0
push 0
push dword [ebp - 0x11c]
push dword [ebp - 0x118]
push 0
push 0
push dword [edi]
call dword [sym.imp.KERNEL32.dll_CreateRemoteThread]
cmp eax, 0xffffffff
je 0x4011ed
push 0xffffffffffffffff
push eax
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push 0x8000
push 0
push dword [ebp - 0x11c]
push dword [edi]
call dword [sym.imp.KERNEL32.dll_VirtualFreeEx]
mov eax, str._nSuccessfully_injected__Please_close_this_window__n
jmp 0x4011f2
mov eax, str._nInjection_failed__n
push eax
call fcn.00401290
add esp, 4
call dword [sym.imp.api_ms_win_crt_conio_l1_1_0.dll__getwch]
mov ecx, dword [edi + 0x18]
movzx eax, ax
mov dword [ebp - 0x118], eax
cmp ecx, 0x10
jb 0x40123a
mov eax, dword [edi + 4]
inc ecx
cmp ecx, 0x1000
jb 0x401230
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x401278
mov eax, edx
push ecx
push eax
call fcn.004014ec
add esp, 8
push 0x1c
push edi
mov dword [edi + 0x14], 0
mov dword [edi + 0x18], 0xf
mov byte [edi + 4], 0
call fcn.004014ec
mov eax, dword [ebp - 0x118]
add esp, 8
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004014de
mov esp, ebp
pop ebp
ret
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll__invalid_parameter_noinfo_noreturn]
int3