mirror of
https://github.com/overte-org/overte.git
synced 2025-04-23 03:53:34 +02:00
default AC to point to DS on localhost and default port
This commit is contained in:
parent
32b507d2ac
commit
7220643fe9
4 changed files with 7 additions and 9 deletions
|
@ -199,7 +199,7 @@ int main(int argc, const char* argv[]) {
|
|||
if (customAssignmentServerHostname) {
|
||||
const char* customAssignmentServerPortString = getCmdOption(argc, argv, CUSTOM_ASSIGNMENT_SERVER_PORT_OPTION);
|
||||
unsigned short assignmentServerPort = customAssignmentServerPortString
|
||||
? atoi(customAssignmentServerPortString) : ASSIGNMENT_SERVER_PORT;
|
||||
? atoi(customAssignmentServerPortString) : DEFAULT_DOMAINSERVER_PORT;
|
||||
|
||||
::customAssignmentSocket = socketForHostnameAndHostOrderPort(customAssignmentServerHostname, assignmentServerPort);
|
||||
}
|
||||
|
|
|
@ -33,7 +33,7 @@ const char SOLO_NODE_TYPES[2] = {
|
|||
|
||||
const char DEFAULT_DOMAIN_HOSTNAME[MAX_HOSTNAME_BYTES] = "root.highfidelity.io";
|
||||
const char DEFAULT_DOMAIN_IP[INET_ADDRSTRLEN] = ""; // IP Address will be re-set by lookup on startup
|
||||
const int DEFAULT_DOMAINSERVER_PORT = 40102;
|
||||
const unsigned short DEFAULT_DOMAINSERVER_PORT = 40102;
|
||||
|
||||
bool silentNodeThreadStopFlag = false;
|
||||
bool pingUnknownNodeThreadStopFlag = false;
|
||||
|
@ -382,9 +382,9 @@ int NodeList::processDomainServerList(unsigned char* packetData, size_t dataByte
|
|||
return readNodes;
|
||||
}
|
||||
|
||||
const char GLOBAL_ASSIGNMENT_SERVER_HOSTNAME[] = "assignment.highfidelity.io";
|
||||
const sockaddr_in GLOBAL_ASSIGNMENT_SOCKET = socketForHostnameAndHostOrderPort(GLOBAL_ASSIGNMENT_SERVER_HOSTNAME,
|
||||
ASSIGNMENT_SERVER_PORT);
|
||||
const char LOCAL_ASSIGNMENT_SERVER_HOSTNAME[] = "localhost";
|
||||
const sockaddr_in DEFAULT_LOCAL_ASSIGNMENT_SOCKET = socketForHostnameAndHostOrderPort(LOCAL_ASSIGNMENT_SERVER_HOSTNAME,
|
||||
DEFAULT_DOMAINSERVER_PORT);
|
||||
void NodeList::sendAssignment(Assignment& assignment) {
|
||||
unsigned char assignmentPacket[MAX_PACKET_SIZE];
|
||||
|
||||
|
@ -396,7 +396,7 @@ void NodeList::sendAssignment(Assignment& assignment) {
|
|||
int numAssignmentBytes = assignment.packToBuffer(assignmentPacket + numHeaderBytes);
|
||||
|
||||
sockaddr* assignmentServerSocket = (_assignmentServerSocket == NULL)
|
||||
? (sockaddr*) &GLOBAL_ASSIGNMENT_SOCKET
|
||||
? (sockaddr*) &DEFAULT_LOCAL_ASSIGNMENT_SOCKET
|
||||
: _assignmentServerSocket;
|
||||
|
||||
_nodeSocket.send(assignmentServerSocket, assignmentPacket, numHeaderBytes + numAssignmentBytes);
|
||||
|
|
|
@ -38,7 +38,7 @@ const int MAX_HOSTNAME_BYTES = 256;
|
|||
|
||||
extern const char DEFAULT_DOMAIN_HOSTNAME[MAX_HOSTNAME_BYTES];
|
||||
extern const char DEFAULT_DOMAIN_IP[INET_ADDRSTRLEN]; // IP Address will be re-set by lookup on startup
|
||||
extern const int DEFAULT_DOMAINSERVER_PORT;
|
||||
extern const unsigned short DEFAULT_DOMAINSERVER_PORT;
|
||||
|
||||
const int UNKNOWN_NODE_ID = 0;
|
||||
|
||||
|
|
|
@ -58,6 +58,4 @@ const int MAX_PACKET_HEADER_BYTES = sizeof(PACKET_TYPE) + sizeof(PACKET_VERSION)
|
|||
#define ADD_SCENE_COMMAND "add scene"
|
||||
#define TEST_COMMAND "a message"
|
||||
|
||||
const unsigned short ASSIGNMENT_SERVER_PORT = 7007;
|
||||
|
||||
#endif
|
||||
|
|
Loading…
Reference in a new issue