Function at 0x405260
Capabilities:
Check mutex on windows
Create thread
Resolve dns
Set registry value

Disassembly:
push 0x1e4
mov eax, 0x420d91
call fcn.0041e546
mov edi, ecx
push str.GlobalJPLAYStreamer_Driver
push 0
push 0x100000
call dword [sym.imp.KERNEL32.dll_OpenMutexW]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov esi, eax
push esi
call ebx
test esi, esi
je 0x4052a6
push str.BUSY:_Close_player_or_press_STOP_to_open_settings
mov ecx, 0x42fc14
call fcn.0040344c
jmp 0x4055f6
xor eax, eax
push eax
push eax
push edi
push 0x404be0
push eax
push eax
mov dword [0x42e478], eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov ecx, dword fs:[0x2c]
mov esi, eax
mov edx, dword [ecx]
mov ecx, dword [0x430420]
cmp ecx, dword [edx + 4]
jle 0x4052fc
mov edi, 0x430420
push edi
call fcn.00407c3a
cmp dword [0x430420], 0xffffffff
pop ecx
jne 0x4052fc
call fcn.00402bef
push edi
mov dword [0x430428], eax
call fcn.00407bfb
pop ecx
push 0x3e8
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push esi
call ebx
cmp dword [0x42e478], 0
je 0x40532d
mov ecx, dword [0x430428]
mov eax, 0x427cbc
push eax
push eax
call fcn.00402223
mov al, 1
jmp 0x4055f8
push 2
push dword [0x42d7c0]
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [0x42d7c0]
call dword [sym.imp.WS2_32.dll_closesocket]
or dword [0x42d7c0], 0xffffffff
lea ecx, [ebp - 0x5c]
mov edi, 0x42fbfc
mov edx, str.Unable_to_connect_to_JPLAY_on
push edi
call fcn.00404345
and dword [ebp - 4], 0
lea ecx, [ebp - 0x44]
mov edx, eax
mov dword [esp], str._nCheck_if_server_is_up_and_JPLAY_is_running
call fcn.004043c9
pop ecx
mov esi, 0x42fc14
push eax
mov ecx, esi
call fcn.00403075
push 0
push 1
lea ecx, [ebp - 0x44]
call fcn.00403338
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x5c]
push 0
push 1
call fcn.00403338
cmp dword [0x42fc28], 8
mov ecx, dword [0x430428]
cmovae esi, dword [0x42fc14]
push str.Cant_connect
push esi
call fcn.00402223
push 0x7d0
call dword [sym.imp.KERNEL32.dll_Sleep]
mov esi, dword [sym.imp.WS2_32.dll_gethostbyname]
push 0x427cb8
call esi
push dword [eax]
call esi
mov eax, dword [eax + 0xc]
mov eax, dword [eax]
push dword [eax]
call dword [sym.imp.WS2_32.dll_inet_ntoa]
push eax
lea ecx, [ebp - 0x2c]
call fcn.0040318b
mov dword [ebp - 4], 1
lea eax, [ebp - 0xe0]
cmp dword [0x42fc10], 8
lea ecx, [ebp - 0xe4]
push 3
cmovae edi, dword [0x42fbfc]
push edi
mov dword [ebp - 0xe4], eax
call fcn.00405d58
mov byte [ebp - 4], 2
lea eax, [ebp - 0x2c]
cmp dword [ebp - 0x18], 0x10
push dword [ebp - 0xe4]
cmovae eax, dword [ebp - 0x2c]
push eax
call fcn.00413da8
pop ecx
pop ecx
test eax, eax
je 0x4055d0
cmp dword [ebp - 0x18], 0x10
lea eax, [ebp - 0x2c]
lea ecx, [ebp - 0x1e8]
cmovae eax, dword [ebp - 0x2c]
push 3
mov dword [ebp - 0x1ec], ecx
lea ecx, [ebp - 0x1ec]
push eax
call fcn.00403211
xor eax, eax
mov byte [ebp - 4], 3
push eax
push eax
push dword [ebp - 0x1ec]
push 0x404be0
push eax
push eax
call dword [sym.imp.KERNEL32.dll_CreateThread]
mov esi, eax
push 0x3e8
push esi
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
push esi
call ebx
push 2
push dword [0x42d7c0]
call dword [sym.imp.WS2_32.dll_shutdown]
push dword [0x42d7c0]
call dword [sym.imp.WS2_32.dll_closesocket]
or dword [0x42d7c0], 0xffffffff
cmp dword [0x42e478], 0
je 0x4055b6
push dword [ebp - 0x1ec]
mov esi, 0x42fbcc
mov ecx, esi
call fcn.0040344c
mov ecx, dword [0x430428]
push str.Reconnected_locally
push str.Using_JPLAY_on_local_PC
call fcn.00402223
cmp dword [0x42fbf8], 8
mov edi, 0x42fbe4
mov ebx, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov eax, edi
cmovae eax, dword [0x42fbe4]
push 0x42e47c
push 3
push 0
push eax
push connect
call ebx
test eax, eax
jne 0x4055b6
cmp dword [0x42fbe0], 8
mov ecx, esi
mov eax, dword [0x42fbdc]
cmovae ecx, dword [0x42fbcc]
add eax, eax
push eax
push ecx
push 1
push 0
push str.Host
push dword [0x42e47c]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [0x42e47c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [0x42fbf8], 8
lea eax, [ebp - 0x1f0]
push eax
cmovae edi, dword [0x42fbe4]
push 3
push 0
push edi
push connect
call ebx
test eax, eax
jne 0x4055b6
cmp dword [0x42fbe0], 8
mov eax, dword [0x42fbdc]
cmovae esi, dword [0x42fbcc]
add eax, eax
push eax
push esi
push 1
push 0
push str.StreamerDestination
push dword [ebp - 0x1f0]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push dword [ebp - 0x1f0]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x1e8]
cmp dword [ebp - 0x1ec], eax
je 0x4055d0
push dword [ebp - 0x1ec]
call fcn.00412b80
pop ecx
lea eax, [ebp - 0xe0]
cmp dword [ebp - 0xe4], eax
je 0x4055ea
push dword [ebp - 0xe4]
call fcn.00412b80
pop ecx
push 0
push 1
lea ecx, [ebp - 0x2c]
call fcn.004034fb
xor al, al
call fcn.0041e501
ret