MCPcopy Create free account
hub / github.com/OpenTTD/OpenTTD / NetworkStunConnectionString

Function NetworkStunConnectionString

src/network/core/config.cpp:33–36  ·  view source on GitHub ↗

* Get the connection string for the STUN server from the environment variable OTTD_STUN_CS, * or when it has not been set a hard coded default DNS hostname of the production server. * @return The STUN server's connection string. */

Source from the content-addressed store, hash-verified

31 * @return The STUN server's connection string.
32 */
33std::string_view NetworkStunConnectionString()
34{
35 return GetEnv("OTTD_STUN_CS").value_or("stun.openttd.org");
36}
37
38/**
39 * Get the connection string for the content server from the environment variable OTTD_CONTENT_SERVER_CS,

Callers 1

ConnectMethod · 0.85

Calls 1

GetEnvFunction · 0.85

Tested by

no test coverage detected