sudo apt install curl
curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
sudo apt install git nodejs npm
This includes the ioq3 repository sub-module.
Change directory to the home directory:
cd ~
NOTE: This is to ensure that the home directory is being used.
git clone --recurse-submodules https://github.com/begleysm/quakejs.git
or
git clone --recurse-submodules https://github.com/inolen/quakejs.git
Move into the newly created quakejs directory:
cd quakejs
Install the necessary node.js packages:
npm install
NOTE: Accept the warnings about deprecated packages and vulnerabilities.
Run the server for the 1st time by executing the following command.
node build/ioq3ded.js +set fs_game baseq3 +set dedicated 1
NOTE: Hold down enter to get through the EULA.
node build/ioq3ded.js +set fs_game cpma +set dedicated 1
NOTE: This will download files.
Edit or Create base/baseq3/server.cfg.
seta sv_hostname "QuakeJS Server" seta sv_maxclients 12 seta g_motd "Welcome to the Local baseq3 QuakeJS Server" seta g_quadfactor 3 seta g_gametype 0 seta timelimit 15 seta fraglimit 25 seta g_weaponrespawn 3 seta g_inactivity 3000 seta g_forcerespawn 0 seta rconpassword "quakejs" set d1 "map q3dm7 ; set nextmap vstr d2" set d2 "map q3dm17 ; set nextmap vstr d1" vstr d1
NOTE: Pay special attention to seta sv_hostname, seta g_motd, and especially seta rconpassword.
Edit or Create base/cpma/server.cfg.
seta sv_hostname "QuakeJS Server" seta sv_maxclients 12 seta g_motd "Welcome to the Local cpma QuakeJS Server" seta g_quadfactor 3 seta g_gametype 0 seta timelimit 15 seta fraglimit 25 seta g_weaponrespawn 3 seta g_inactivity 3000 seta g_forcerespawn 0 seta rconpassword "quakejs" set d1 "map q3dm7 ; set nextmap vstr d2" set d2 "map q3dm17 ; set nextmap vstr d1" vstr d1
NOTE: Pay special attention to seta sv_hostname, seta g_motd, and especially seta rconpassword.
The quake server needs to run as a non-root user.
Therefore the quakejs directory will be placed under the quake user created earlier.
cp -R /root/quakejs /home/quake
Set permissions to belong to the quake user created earlier.
chown -R quake:quake /home/quake/quakejs
cd ~/quakejs node build/ioq3ded.js +set fs_game baseq3 set dedicated 1 +exec server.cfg
NOTE: The final line with say something like Hitch warning: 5584 msec frame time.
Continue Setup a Local Content Server