Skip to main content

TavernServer

A class in TavernLib, TavernLib.Backend.Server.Configs.

The contents of tavern_server.json: the game, auth, web and console ports. Use the checked properties (Game, Auth, Web, Console), which fall back to the defaults.

Constructors​

MemberWhat it is
TavernServer()Created by TavernLib; mods don't make one.

Fields​

MemberWhat it is
const int DefaultAuthPort1762.
const int DefaultConsolePort1760.
const int DefaultGamePort1757.
const int DefaultWebPort1761.

Properties​

MemberWhat it is
int Auth { get; }The auth (login) port, or 1762 if missing or out of range.
int AuthPort { get; private set; }auth_port as written.
int Console { get; }The websocket console port, or 1760 if missing or out of range.
int ConsolePort { get; private set; }console_port as written.
int Game { get; }The game port, or 1757 if missing or out of range.
int ServerPort { get; private set; }server_port as written: the game port. 0 if the file leaves it out.
int Web { get; }The game's web server port, or 1761 if missing or out of range.
int WebPort { get; private set; }web_port as written.
1 private and internal property
MemberWhat it is
private IDictionary<string, JToken> Extra { get; set; }Holds JSON keys TavernLib doesn't model, so they are written back unchanged.

Methods​

MemberWhat it is
static int Valid(int port, int fallback)The port when it's 1 to 65535, otherwise the fallback.

Used in​

Members of other types that take, return or hold a TavernServer: