Skip to content

Commit afe2b70

Browse files
authored
feat(new server): pvrserver (#2384)
1 parent a62d923 commit afe2b70

File tree

8 files changed

+221
-0
lines changed

8 files changed

+221
-0
lines changed
Lines changed: 173 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,173 @@
1+
##################################
2+
######## Default Settings ########
3+
##################################
4+
# DO NOT EDIT WILL BE OVERWRITTEN!
5+
# Copy settings from here and use them in either
6+
# common.cfg - applies settings to every instance
7+
# [instance].cfg - applies settings to a specific instance
8+
9+
#### Server Settings ####
10+
11+
## Server Start Settings | https://docs.linuxgsm.com/configuration/start-parameters
12+
ip="0.0.0.0"
13+
port="7777"
14+
15+
# Maps: bridge, datacenter, sand
16+
defaultmap="datacenter"
17+
18+
## Server Start Command | https://docs.linuxgsm.com/configuration/start-parameters#additional-parameters
19+
fn_parms(){
20+
parms="${defaultmap} -log -MultiHome=${ip} -Port=${port}"
21+
}
22+
23+
#### LinuxGSM Settings ####
24+
25+
## Notification Alerts
26+
# (on|off)
27+
28+
# Display IP | https://docs.linuxgsm.com/alerts#display-ip
29+
displayip=""
30+
31+
# More info | https://docs.linuxgsm.com/alerts#more-info
32+
postalert="off"
33+
postdays="7"
34+
posttarget="https://hastebin.com"
35+
36+
# Discord Alerts | https://docs.linuxgsm.com/alerts/discord
37+
discordalert="off"
38+
discordwebhook="webhook"
39+
40+
# Email Alerts | https://docs.linuxgsm.com/alerts/email
41+
emailalert="off"
42+
43+
emailfrom=""
44+
45+
# IFTTT Alerts | https://docs.linuxgsm.com/alerts/ifttt
46+
iftttalert="off"
47+
ifttttoken="accesstoken"
48+
iftttevent="linuxgsm_alert"
49+
50+
# Mailgun Email Alerts | https://docs.linuxgsm.com/alerts/mailgun
51+
mailgunalert="off"
52+
mailgunapiregion="us"
53+
mailguntoken="accesstoken"
54+
mailgundomain="example.com"
55+
mailgunemailfrom="[email protected]"
56+
mailgunemail="[email protected]"
57+
58+
# Pushbullet Alerts | https://docs.linuxgsm.com/alerts/pushbullet
59+
pushbulletalert="off"
60+
pushbullettoken="accesstoken"
61+
channeltag=""
62+
63+
# Pushover Alerts | https://docs.linuxgsm.com/alerts/pushover
64+
pushoveralert="off"
65+
pushovertoken="accesstoken"
66+
67+
# Rocket.Chat Alerts | https://docs.linuxgsm.com/alerts/rocket.chat
68+
rocketchatalert="off"
69+
rocketchatwebhook="webhook"
70+
rocketchattoken=""
71+
72+
# Slack Alerts | https://docs.linuxgsm.com/alerts/slack
73+
slackalert="off"
74+
slackwebhook="webhook"
75+
76+
# Telegram Alerts | https://docs.linuxgsm.com/alerts/telegram
77+
# You can add a custom cURL string eg proxy (useful in Russia) or else in "curlcustomstring".
78+
# like a "--socks5 ipaddr:port" for socks5 proxy see more in "curl --help", if you not need
79+
telegramalert="off"
80+
telegramtoken="accesstoken"
81+
telegramchatid=""
82+
curlcustomstring=""
83+
84+
## Updating | https://docs.linuxgsm.com/commands/update
85+
updateonstart="off"
86+
87+
## Backup | https://docs.linuxgsm.com/commands/backup
88+
maxbackups="4"
89+
maxbackupdays="30"
90+
stoponbackup="on"
91+
92+
## Logging | https://docs.linuxgsm.com/features/logging
93+
consolelogging="on"
94+
logdays="7"
95+
96+
## Monitor | https://docs.linuxgsm.com/commands/monitor
97+
# Query delay time
98+
querydelay="1"
99+
100+
#### LinuxGSM Advanced Settings ####
101+
102+
# ANSI Colors
103+
ansi="on"
104+
105+
# Message Display Time
106+
sleeptime="0.5"
107+
108+
## SteamCMD Settings | https://docs.linuxgsm.com/steamcmd
109+
# Server appid
110+
appid="622970"
111+
# SteamCMD Branch | https://docs.linuxgsm.com/steamcmd/branch
112+
branch=""
113+
betapassword=""
114+
# Master Server | https://docs.linuxgsm.com/steamcmd/steam-master-server
115+
steammaster="false"
116+
117+
## Stop Mode | https://docs.linuxgsm.com/features/stop-mode
118+
# 1: tmux kill
119+
# 2: CTRL+c
120+
# 3: quit
121+
# 4: quit 120s
122+
# 5: stop
123+
# 6: q
124+
# 7: exit
125+
# 8: 7 Days to Die
126+
# 9: GoldSrc
127+
# 10: Avorion
128+
# 11: end
129+
stopmode="2"
130+
131+
## Query mode
132+
# 1: session only
133+
# 2: gamedig + gsquery
134+
# 3: gamedig
135+
# 4: gsquery
136+
# 5: tcp
137+
querymode="1"
138+
querytype=""
139+
140+
## LinuxGSM Server Details
141+
# Do not edit
142+
gamename="Pavlov VR"
143+
engine="unreal4"
144+
glibc="2.17"
145+
146+
#### Directories ####
147+
# Edit with care
148+
149+
## Server Specific Directories
150+
systemdir="${serverfiles}/Pavlov"
151+
executabledir="${systemdir}/Binaries/Linux"
152+
executable="./PavlovServer"
153+
servercfgdir="${systemdir}/Saved/Config/LinuxServer"
154+
servercfg="Game.ini"
155+
servercfgdefault="Game.ini"
156+
servercfgfullpath="${servercfgdir}/${servercfg}"
157+
158+
## Backup Directory
159+
backupdir="${lgsmdir}/backup"
160+
161+
## Logging Directories
162+
logdir="${rootdir}/log"
163+
gamelogdir="${systemdir}/Saved/Logs"
164+
lgsmlogdir="${logdir}/script"
165+
consolelogdir="${logdir}/console"
166+
lgsmlog="${lgsmlogdir}/${selfname}-script.log"
167+
consolelog="${consolelogdir}/${selfname}-console.log"
168+
alertlog="${lgsmlogdir}/${selfname}-alert.log"
169+
postdetailslog="${lgsmlogdir}/${selfname}-postdetails.log"
170+
171+
## Logs Naming
172+
lgsmlogdate="${lgsmlogdir}/${selfname}-script-$(date '+%Y-%m-%d-%H:%M:%S').log"
173+
consolelogdate="${consolelogdir}/${selfname}-console-$(date '+%Y-%m-%d-%H:%M:%S').log"

lgsm/data/serverlist.csv

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ opfor,opforserver,Opposing Force
6969
pc,pcserver,Project Cars
7070
pstbs,pstbsserver,Post Scriptum: The Bloody Seventh
7171
pvkii,pvkiiserver,Pirates Vikings & Knights II
72+
pvr,pvrserver,Pavlov VR
7273
pz,pzserver,Project Zomboid
7374
q2,q2server,Quake 2
7475
q3,q3server,Quake 3: Arena

lgsm/functions/check_system_requirements.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ elif [ "${shortname}" == "ns2" ]||[ "${shortname}" == "ns2c" ]; then
3838
elif [ "${shortname}" == "st" ]; then
3939
ramrequirementmb="1000"
4040
ramrequirementgb="1"
41+
elif [ "${shortname}" == "pvr" ];then
42+
ramrequirementmb="2000"
43+
ramrequirementgb="2"
4144
fi
4245

4346
# If the game or engine has a minimum RAM Requirement, compare it to system's available RAM.

lgsm/functions/fix_steamcmd.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,8 @@ elif [ "${shortname}" == "ins" ]; then
8484
elif [ "${shortname}" == "pz" ]; then
8585
fn_fix_steamclient_so "32" "${serverfiles}/linux32"
8686
fn_fix_steamclient_so "64" "${serverfiles}/linux64"
87+
elif [ "${shortname}" == "pvr" ]; then
88+
fn_fix_steamclient_so "64" "${executabledir}"
8789
elif [ "${shortname}" == "ss3" ]; then
8890
fn_fix_steamclient_so "32" "${serverfiles}/Bin"
8991
elif [ "${shortname}" == "tu" ];then

lgsm/functions/info_config.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1511,6 +1511,20 @@ fn_info_config_soldat(){
15111511
fi
15121512
}
15131513

1514+
fn_info_config_pavlovvr(){
1515+
if [ ! -f "${servercfgfullpath}" ]; then
1516+
servername="${unavailable}"
1517+
maxplayers="${unavailable}"
1518+
else
1519+
servername=$(grep "ServerName" "${servercfgfullpath}" | awk -F '=' '{print $2}')
1520+
maxplayers=$(grep "MaxPlayers" "${servercfgfullpath}" | awk -F '=' '{print $2}')
1521+
1522+
# Not set
1523+
servername=${servername:-"NOT SET"}
1524+
maxplayers=${maxplayers:-"0"}
1525+
fi
1526+
}
1527+
15141528
if [ "${shortname}" == "ac" ]; then
15151529
fn_info_config_assettocorsa
15161530
elif [ "${shortname}" == "ark" ]; then
@@ -1631,4 +1645,6 @@ elif [ "${shortname}" == "st" ]; then
16311645
fn_info_config_stationeers
16321646
elif [ "${shortname}" == "mh" ]; then
16331647
fn_info_config_mordhau
1648+
elif [ "${shortname}" == "pvr" ];then
1649+
fn_info_config_pavlovvr
16341650
fi

lgsm/functions/info_messages.sh

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1435,6 +1435,16 @@ fn_info_message_warfork(){
14351435
} | column -s $'\t' -t
14361436
}
14371437

1438+
fn_info_message_pavlovvr(){
1439+
echo "netstat -atunp | grep Pavlov"
1440+
echo -e ""
1441+
{
1442+
echo -e "DESCRIPTION\tDIRECTION\tPORT\tPROTOCOL"
1443+
echo -e "> Game\tINBOUND\t${port}\tudp"
1444+
echo -e "> Game\tINBOUND\t$((port+400))\tudp"
1445+
} | column -s $'\t' -t
1446+
}
1447+
14381448
fn_info_message_select_engine(){
14391449
# Display details depending on game or engine.
14401450
if [ "${shortname}" == "ac" ]; then
@@ -1547,6 +1557,8 @@ fn_info_message_select_engine(){
15471557
fn_info_message_bfv
15481558
elif [ "${shortname}" == "rtcw" ]; then
15491559
fn_info_message_rtcw
1560+
elif [ "${shortname}" == "pvr" ]; then
1561+
fn_info_message_pavlovvr
15501562
elif [ "${shortname}" == "rust" ]; then
15511563
fn_info_message_rust
15521564
elif [ "${shortname}" == "wf" ]; then

lgsm/functions/info_parms.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,6 +196,11 @@ fn_info_parms_teeworlds(){
196196
queryport=${port:-"0"}
197197
}
198198

199+
fn_info_parms_pavlovvr(){
200+
port=${port:-"0"}
201+
queryport=${queryport:-"0"}
202+
}
203+
199204
fn_info_parms_unreal(){
200205
defaultmap=${defaultmap:-"NOT SET"}
201206
queryport=$((port + 1))
@@ -250,6 +255,8 @@ elif [ "${shortname}" == "mom" ]; then
250255
fn_info_parms_mom
251256
elif [ "${shortname}" == "pz" ]; then
252257
fn_info_parms_projectzomboid
258+
elif [ "${shortname}" == "pvr" ]; then
259+
fn_info_parms_pavlovvr
253260
elif [ "${shortname}" == "qw" ]; then
254261
fn_info_parms_quakeworld
255262
elif [ "${shortname}" == "q2" ]||[ "${shortname}" == "q3" ]; then

lgsm/functions/install_config.sh

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -576,6 +576,13 @@ elif [ "${shortname}" == "mumble" ]; then
576576
fn_fetch_default_config
577577
fn_default_config_remote
578578
fn_list_config_locations
579+
elif [ "${gamename}" == "Pavlov VR" ]; then
580+
gamedirname="PavlovVR"
581+
fn_check_cfgdir
582+
array_configs+=( Game.ini )
583+
fn_fetch_default_config
584+
fn_default_config_remote
585+
fn_set_config_vars
579586
elif [ "${shortname}" == "pvkii" ]; then
580587
gamedirname="PiratesVikingandKnightsII"
581588
array_configs+=( server.cfg )

0 commit comments

Comments
 (0)