From fa1e27994dd1284f6fefbe08c47a5c4145ccf00d Mon Sep 17 00:00:00 2001 From: Patric Stout Date: Wed, 5 May 2021 10:47:01 +0200 Subject: Feature: allow the use of TURN to connect client and server together TURN is a last resort, used only if all other methods failed. TURN is a relay approach to connect client and server together, where openttd.org (by default) is the middleman. It is very unlikely either the client or server cannot connect to the STUN server, as they are both already connected to the Game Coordinator. But in the odd case it does fail, estabilishing the connection fails without any further possibility to recover. --- src/settings_type.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/settings_type.h') diff --git a/src/settings_type.h b/src/settings_type.h index 8db0febad..ababe718b 100644 --- a/src/settings_type.h +++ b/src/settings_type.h @@ -59,6 +59,13 @@ enum IndustryDensity { ID_END, ///< Number of industry density settings. }; +/** Possible values for "userelayservice" setting. */ +enum UseRelayService { + URS_NEVER = 0, + URS_ASK, + URS_ALLOW, +}; + /** Settings related to the difficulty of the game */ struct DifficultySettings { byte competitor_start_time; ///< Unused value, used to load old savegames. @@ -290,6 +297,7 @@ struct NetworkSettings { bool reload_cfg; ///< reload the config file before restarting std::string last_joined; ///< Last joined server bool no_http_content_downloads; ///< do not do content downloads over HTTP + UseRelayService use_relay_service; ///< Use relay service? }; /** Settings related to the creation of games. */ -- cgit v1.2.3-54-g00ecf