Adding a password to a dedicated server

Discussion about the game and its default mods.
Post Reply
graphite
Posts: 2
Joined: Fri Mar 07, 2014 9:33 pm

Adding a password to a dedicated server

Post by graphite »

Hi all,

I did a search but couldn't find anything so sorry if this has been asked before.

Is it possible to add a password to the dedicated server .sh script?

If so could someone give me the command(s) to add?
Thanks.

hausmarke
Posts: 2
Joined: Wed Feb 26, 2014 10:43 pm

Post by hausmarke »

#!/bin/bash
Name="xaionaro_hetzner_$2"
Mod="ra"
Dedicated="True"
DedicatedLoop="True"
ListenPort="$1"
ExternalPort="$1"
AdvertiseOnline="True"
Password="yourpassword"
#Map="ba403f6bcb4cae934335b78be42f714992b3a71a"
#Map="399372de425c9e8e9d49df90fbbc467dcfc52ac7"

# Haos Ridges
Map="3bc995f925d5b1a894513fb3e570ce22784adcf1"


while true; do
cd "/usr/local/openra/$2/current/usr/share/openra" 2>/dev/null ||
cd "/usr/local/openra/$2/current/usr/local/share/openra" 2>/dev/null ||
cd "/usr/local/openra/$2/current/usr/share/openra-bleed" 2>/dev/null ||
cd "/usr/local/openra/$2/current/usr/local/share/openra-bleed"
if [ "$2" = "release" ]; then
mono OpenRA.Game.exe Game.Mod=$Mod Server.Dedicated=$Dedicated Server.DedicatedLoop=$DedicatedLoop \
Server.Name=$Name Server.ListenPort=$ListenPort Server.ExternalPort=$ExternalPort \
Server.AdvertiseOnline=$AdvertiseOnline Server.Map=$Map Server.Password=$Password
else
mono OpenRA.Game.exe Game.Mod=$Mod Server.Dedicated=$Dedicated Server.DedicatedLoop=$DedicatedLoop \
Server.Name=$Name Server.ListenPort=$ListenPort Server.ExternalPort=$ExternalPort \
Server.AdvertiseOnline=$AdvertiseOnline Server.Map=$Map Server.Password=$Password
fi
done

graphite
Posts: 2
Joined: Fri Mar 07, 2014 9:33 pm

Post by graphite »

Thank you very much for the reply, that worked a treat.

Many regards.

Post Reply