Guides

Your own server

Host games for your friends, or for everybody.

Two ways to host

Players with VisionJK and players with the original game can both join. Those with the original game play as they always did, just without the voice chat.

Start a dedicated server

  1. Install VisionJK on the machine as in First steps. The game data has to be there too.
  2. Open the file server.cfg in the folder japlus with a text editor. It is a ready example. Give your server a name (sv_hostname) and set the passwords described below.
  3. Start it from the GameData folder:
    ./visionjkded.x86_64 +set dedicated 2 +exec server.cfg

With dedicated 2 the server shows up in the public server list. With dedicated 1 it stays private: people join by typing your address.

Open the doors

Two ports have to reach your server from outside, both UDP. In a home network that means forwarding them in your router.

PortFor
29070The game. This is the usual port, you can choose another with net_port.
29071The voice chat. It is the game port plus one, unless you set another with g_voicePort.

Passwords and admins

The example config comes with empty passwords. Set your own before anybody else can reach the server.

SettingWhat it protects
rconpasswordFull control of the server from the console.
jp_councilPassThe highest admin rank.
jp_knightPassThe middle admin rank.
jp_instructorPassThe lowest admin rank.

An admin logs in during a game by typing amlogin and the password of his rank into the console. What each rank may do is set in the same config. Admins can kick and ban, put a player to sleep, protect or silence him, teleport, rename, change the map and start polls. aminfo lists the commands.

The server page

VisionJK servers come with a page for the owner. You open it in a browser and see the level with everybody on it, live.

  1. Put two lines into your server.cfg:
    seta g_webPassword "a long password"
    seta g_webPort 8080
  2. Start the server, or change the map if it already runs.
  3. Open http://your-server:8080/ in a browser. Any name works, the password is the one you set.

The page has two modes. In Administration you see the players, change their health, team or size, move them with a right click on the map, kick or ban, read the chat and edit the config. In Editor you move, turn, copy and remove the things in a level, and place new ones.

The page is not encrypted. Use it inside your own network, or put it behind HTTPS before you open it to the internet. With seta g_webBind "127.0.0.1" it only answers on the server machine itself. As long as no password is set, the page is off.

Voice chat on your server

Voice chat is on from the start, you do not have to do anything except keep the voice port open. Three settings you may want:

SettingWhat it does
g_voiceRangeHow far a voice carries. 1024 from the start. With 0 everybody hears everybody.
g_voiceTeamOnly 1In team games only the own team hears a player.
g_voice 0No voice chat on this server.