Function at 0x401000
Capabilities:
Create process on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0xac8
mov eax, dword [0x42b014]
xor eax, esp
mov dword [esp + 0xac4], eax
push esi
push edi
push 2
push 0xffffffffffffffff
push 0x100c
push dword [0x42b8c4]
call dword [sym.imp.USER32.dll_SendMessageW]
test eax, eax
js 0x40138d
push eax
call fcn.00402970
mov ecx, eax
add esp, 4
mov dword [esp + 0xc], ecx
test ecx, ecx
jne 0x40106d
push str.GetSelectedServer___unknown_server_n
call fcn.00402870
add esp, 4
pop edi
pop esi
mov ecx, dword [esp + 0xac4]
xor ecx, esp
call fcn.00406f44
mov esp, ebp
pop ebp
ret
cmp word [0x42c340], 0
jne 0x401221
push 0x422220
push str.bf1942_path.txt
call fcn.004093a5
mov edi, eax
add esp, 8
test edi, edi
je 0x40110f
push edi
push 0x400
push 0x42c340
call fcn.00409105
push edi
mov esi, eax
call fcn.0040c980
add esp, 0x10
test esi, esi
je 0x40115a
mov ecx, esi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4010c0
sub ecx, edx
sar ecx, 1
je 0x4010f2
lea eax, [esi + ecx*2]
movzx eax, word [eax - 2]
cmp eax, 0xa
je 0x4010e2
cmp eax, 0xd
jne 0x4010f2
sub ecx, 1
mov edx, 0
lea eax, [esi + ecx*2]
mov word [eax], dx
jne 0x4010d4
push 0x422234
push esi
call fcn.0040938e
add esp, 8
test eax, eax
je 0x40115a
push eax
call fcn.0040c980
jmp 0x40120c
push 0x42223c
push 0x422240
call fcn.004093a5
add esp, 8
test eax, eax
je 0x40115a
push eax
call fcn.0040c980
movups xmm0, xmmword [str..BF1942.exe]
mov ax, word [0x422264]
mov word [0x42c358], ax
movups xmmword [0x42c340], xmm0
movq xmm0, qword [0x42225c]
movq qword [0x42c350], xmm0
jmp 0x40120c
push 0x58
lea eax, [esp + 0x74]
push 0
push eax
call fcn.00407e20
xor eax, eax
mov dword [esp + 0x7c], 0x58
mov word [0x42c340], ax
add esp, 0xc
mov eax, dword [0x42b8c0]
mov dword [esp + 0x74], eax
lea eax, [esp + 0x70]
mov dword [esp + 0x8c], 0x42c340
push eax
mov dword [esp + 0x94], 0x800
mov dword [esp + 0xa4], str.Select_BF1942.exe_in_your_game_folder
mov dword [esp + 0x80], 0x4222b4
mov dword [esp + 0xa8], 0x1808
call dword [sym.imp.COMDLG32.dll_GetOpenFileNameW]
test eax, eax
je 0x40120f
push 0x4222e4
push str.bf1942_path.txt
call fcn.004093a5
mov esi, eax
add esp, 8
test esi, esi
je 0x401202
push esi
push 0x42c340
call fcn.004091cf
push esi
call fcn.0040c980
push str.bf1942_path_saved_n
call fcn.00402870
add esp, 0x10
jmp 0x40120f
push str.failed_to_save_path__unable_to_open_txt_file_n
call fcn.00402870
add esp, 4
cmp word [0x42c340], 0
je 0x40138d
mov ecx, dword [esp + 0xc]
lea eax, [ecx + 0xe4]
push eax
push dword [ecx + 0x104]
push dword [ecx + 0x128]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
push str.BF1942.exe_restart_1_joinServer__hs:_d_game__ls
lea eax, [esp + 0xd8]
push 0x100
push eax
call fcn.00402830
push 0x800
lea eax, [esp + 0x2e4]
push 0
push eax
call fcn.00407e20
push 0x5c
push 0x42c340
call fcn.00407d71
mov edi, eax
add esp, 0x2c
test edi, edi
je 0x4012ab
xor ecx, ecx
cmp edi, 0x42c340
je 0x4012ab
mov edx, 0x42c340
xor esi, esi
nop dword [eax]
mov ax, word [edx]
lea ecx, [ecx + 1]
mov word [esp + esi + 0x2c8], ax
lea esi, [ecx + ecx]
lea edx, [esi + 0x42c340]
cmp edx, edi
jne 0x401290
lea eax, [esp + 0xc8]
push eax
push 0x42c340
push str.executing___ls___ls_n
call fcn.004028a0
lea eax, [esp + 0x2d4]
push eax
push str.in_dir___s__n
call fcn.004028a0
add esp, 0x14
mov dword [esp + 0x28], 0x44
lea eax, [esp + 0x10]
xorps xmm0, xmm0
movlpd qword [esp + 0x2c], xmm0
movlpd qword [esp + 0x34], xmm0
push eax
lea eax, [esp + 0x2c]
movlpd qword [esp + 0x40], xmm0
push eax
lea eax, [esp + 0x2d0]
movlpd qword [esp + 0x4c], xmm0
push eax
push 0
push 0x200
push 0
push 0
push 0
lea eax, [esp + 0xe8]
movlpd qword [esp + 0x6c], xmm0
push eax
push 0x42c340
movlpd qword [esp + 0x7c], xmm0
movlpd qword [esp + 0x84], xmm0
movlpd qword [esp + 0x8c], xmm0
movaps xmmword [esp + 0x38], xmm0
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x40137b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.CreateProcess_failed:__d_n
call fcn.00402870
add esp, 8
pop edi
pop esi
mov ecx, dword [esp + 0xac4]
xor ecx, esp
call fcn.00406f44
mov esp, ebp
pop ebp
ret
push dword [esp + 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push dword [esp + 0x14]
call esi
mov ecx, dword [esp + 0xacc]
pop edi
pop esi
xor ecx, esp
call fcn.00406f44
mov esp, ebp
pop ebp
ret