This commit is contained in:
Dragoon Dorise 2024-04-13 23:14:11 +02:00
parent b8d512b483
commit 77a0d5c810

View file

@ -12,18 +12,20 @@ netplaySetIP(){
segment=$(echo $localIP | awk -F '.' '{print $1"."$2"."$3}')
subnet="$segment".
port=55435
#netplaySetHost
netplaySetHost
sleep 1
for i in {2..255}; do
{
ip="$subnet$i"
if (echo > /dev/tcp/$ip/$port) >/dev/null 2>&1; then
setSetting netplayHost "false"
setSetting netplayIP "$ip"
sleep 1
exit
fi
} &
done
sleep 1
}
netplaySetHost(){