1
0
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-18 19:29:09 +00:00

Replace port constants with a single port variable

- Remove really old deprecated constants
- Remove some Cyanic server code as well
This commit is contained in:
2014-12-26 15:46:46 -05:00
parent 990f42c780
commit e8d317bd92
8 changed files with 24 additions and 54 deletions

View File

@ -52,10 +52,6 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
//============================================================================
// Network constants
//============================================================================
const unsigned kNetLegacyClientPort = 80;
const unsigned kNetDefaultClientPort = 14617;
const unsigned kNetDefaultServerPort = 14618;
const unsigned kNetDefaultSimpleNetPort = 14620;
const unsigned kMaxTcpPacketSize = 1460;
//============================================================================

View File

@ -70,6 +70,8 @@ static const char* s_gateKeeperAddrs[] = {
s_gateKeeperAddrConsole
};
static unsigned s_clientPort = 14617;
/*****************************************************************************
*
@ -121,6 +123,18 @@ void SetGateKeeperSrvHostname (const char addr[]) {
strncpy(s_gateKeeperAddrConsole, addr, arrsize(s_gateKeeperAddrConsole));
}
//============================================================================
// Client Port
//============================================================================
unsigned GetClientPort() {
return s_clientPort;
}
//============================================================================
void SetClientPort(unsigned port) {
s_clientPort = port;
}
//============================================================================
// User-visible Server

View File

@ -93,6 +93,9 @@ void SetFileSrvHostname (const char addr[]);
unsigned GetGateKeeperSrvHostnames (const char*** addrs); // returns addrCount
void SetGateKeeperSrvHostname (const char addr[]);
unsigned GetClientPort();
void SetClientPort(unsigned port);
const char *GetServerStatusUrl ();
void SetServerStatusUrl (const char url[]);