Просмотр исходного кода

Better ARK ports info

Will test if ok
UltimateByte 9 лет назад
Родитель
Сommit
eb2788ed9e
1 измененных файлов с 7 добавлено и 2 удалено
  1. 7 2
      lgsm/functions/command_details.sh

+ 7 - 2
lgsm/functions/command_details.sh

@@ -347,9 +347,14 @@ fn_details_ark(){
 	echo -e "netstat -atunp | grep ShooterGame"
 	echo -e "netstat -atunp | grep ShooterGame"
 	echo -e ""
 	echo -e ""
 	{
 	{
-		echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL\tINI VARIABLE"
-		echo -e "> Game\tINBOUND\t${port}\tudp\tPort=${port}"
+		echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL"
+		echo -e "> Game\tINBOUND\t${port}\tudp"
+		# Don't do arithmetics if ever the port wasn't a numeric value
+		if [ "${port}" -eq "${port}" ];then 
+			echo -e "> RAW\t\INBOUND\t$((port+1))\tudp
+		fi
 		echo -e "> Query\tINBOUND\t${queryport}\tudp"
 		echo -e "> Query\tINBOUND\t${queryport}\tudp"
+		echo -e "> RCON\INBOUND\t${rconport}\ttcp"
 	} | column -s $'\t' -t
 	} | column -s $'\t' -t
 }
 }