From 40b4b9809f24fd90a797434ab36e3099707b90c6 Mon Sep 17 00:00:00 2001 From: Daniel Gibbs Date: Sun, 27 Jun 2021 15:08:05 +0100 Subject: [PATCH] pvr gameport+400 --- lgsm/functions/command_dev_query_raw.sh | 6 ++++++ lgsm/functions/info_messages.sh | 12 +++++++----- lgsm/functions/info_parms.sh | 1 + 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/lgsm/functions/command_dev_query_raw.sh b/lgsm/functions/command_dev_query_raw.sh index fafb77b45..8c19ac2c6 100755 --- a/lgsm/functions/command_dev_query_raw.sh +++ b/lgsm/functions/command_dev_query_raw.sh @@ -53,6 +53,12 @@ if [ "${shortname}" == "rw" ]; then fi fi +if [ -v port401 ]; then + echo -e "Game+400: \t${port401} \t$(ss -tupl|grep ${port401}|wc -l) \t$(ss -tupl|grep ${port401}|grep tcp|awk '{ print $2 }') \t$(ss -tupl|grep ${port401}|grep udp|awk '{ print $2 }')" +else + echo -e "Game+400:" +fi + if [ -v portipv6 ]; then echo -e "Game ipv6: \t${portipv6} \t$(ss -tupl|grep ${portipv6}|wc -l) \t$(ss -tupl|grep ${portipv6}|grep tcp|awk '{ print $2 }') \t$(ss -tupl|grep ${portipv6}|grep udp|awk '{ print $2 }')" else diff --git a/lgsm/functions/info_messages.sh b/lgsm/functions/info_messages.sh index b77ff6130..a8c704508 100755 --- a/lgsm/functions/info_messages.sh +++ b/lgsm/functions/info_messages.sh @@ -1472,16 +1472,18 @@ fn_info_message_soldat(){ fn_info_message_warfork(){ { fn_port "header" - fn_port "Game" port udp - fn_port "HTTP" httpport tcp + fn_port "Game" port udp + fn_port "HTTP" httpport tcp } | column -s $'\t' -t } fn_info_message_pavlovvr(){ { - echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL" - echo -e "> Game\t${port}\tudp" - echo -e "> Game\t$((port+400))\tudp" + fn_port "header" + fn_port "Game" port udp + fn_port "Game" port tcp + fn_port "Game +400" port401 udp + fn_port "Query" queryport tcp } | column -s $'\t' -t } diff --git a/lgsm/functions/info_parms.sh b/lgsm/functions/info_parms.sh index 864e6c1cb..f08d7728c 100755 --- a/lgsm/functions/info_parms.sh +++ b/lgsm/functions/info_parms.sh @@ -230,6 +230,7 @@ fn_info_parms_teeworlds(){ fn_info_parms_pavlovvr(){ port=${port:-"0"} + port401=$((port+400)) queryport=${port:-"0"} }