mirror of
https://github.com/overte-org/overte.git
synced 2025-08-09 11:07:07 +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) {
|
if (customAssignmentServerHostname) {
|
||||||
const char* customAssignmentServerPortString = getCmdOption(argc, argv, CUSTOM_ASSIGNMENT_SERVER_PORT_OPTION);
|
const char* customAssignmentServerPortString = getCmdOption(argc, argv, CUSTOM_ASSIGNMENT_SERVER_PORT_OPTION);
|
||||||
unsigned short assignmentServerPort = customAssignmentServerPortString
|
unsigned short assignmentServerPort = customAssignmentServerPortString
|
||||||
? atoi(customAssignmentServerPortString) : ASSIGNMENT_SERVER_PORT;
|
? atoi(customAssignmentServerPortString) : DEFAULT_DOMAINSERVER_PORT;
|
||||||
|
|
||||||
::customAssignmentSocket = socketForHostnameAndHostOrderPort(customAssignmentServerHostname, assignmentServerPort);
|
::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_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 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 silentNodeThreadStopFlag = false;
|
||||||
bool pingUnknownNodeThreadStopFlag = false;
|
bool pingUnknownNodeThreadStopFlag = false;
|
||||||
|
@ -382,9 +382,9 @@ int NodeList::processDomainServerList(unsigned char* packetData, size_t dataByte
|
||||||
return readNodes;
|
return readNodes;
|
||||||
}
|
}
|
||||||
|
|
||||||
const char GLOBAL_ASSIGNMENT_SERVER_HOSTNAME[] = "assignment.highfidelity.io";
|
const char LOCAL_ASSIGNMENT_SERVER_HOSTNAME[] = "localhost";
|
||||||
const sockaddr_in GLOBAL_ASSIGNMENT_SOCKET = socketForHostnameAndHostOrderPort(GLOBAL_ASSIGNMENT_SERVER_HOSTNAME,
|
const sockaddr_in DEFAULT_LOCAL_ASSIGNMENT_SOCKET = socketForHostnameAndHostOrderPort(LOCAL_ASSIGNMENT_SERVER_HOSTNAME,
|
||||||
ASSIGNMENT_SERVER_PORT);
|
DEFAULT_DOMAINSERVER_PORT);
|
||||||
void NodeList::sendAssignment(Assignment& assignment) {
|
void NodeList::sendAssignment(Assignment& assignment) {
|
||||||
unsigned char assignmentPacket[MAX_PACKET_SIZE];
|
unsigned char assignmentPacket[MAX_PACKET_SIZE];
|
||||||
|
|
||||||
|
@ -396,7 +396,7 @@ void NodeList::sendAssignment(Assignment& assignment) {
|
||||||
int numAssignmentBytes = assignment.packToBuffer(assignmentPacket + numHeaderBytes);
|
int numAssignmentBytes = assignment.packToBuffer(assignmentPacket + numHeaderBytes);
|
||||||
|
|
||||||
sockaddr* assignmentServerSocket = (_assignmentServerSocket == NULL)
|
sockaddr* assignmentServerSocket = (_assignmentServerSocket == NULL)
|
||||||
? (sockaddr*) &GLOBAL_ASSIGNMENT_SOCKET
|
? (sockaddr*) &DEFAULT_LOCAL_ASSIGNMENT_SOCKET
|
||||||
: _assignmentServerSocket;
|
: _assignmentServerSocket;
|
||||||
|
|
||||||
_nodeSocket.send(assignmentServerSocket, assignmentPacket, numHeaderBytes + numAssignmentBytes);
|
_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_HOSTNAME[MAX_HOSTNAME_BYTES];
|
||||||
extern const char DEFAULT_DOMAIN_IP[INET_ADDRSTRLEN]; // IP Address will be re-set by lookup on startup
|
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;
|
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 ADD_SCENE_COMMAND "add scene"
|
||||||
#define TEST_COMMAND "a message"
|
#define TEST_COMMAND "a message"
|
||||||
|
|
||||||
const unsigned short ASSIGNMENT_SERVER_PORT = 7007;
|
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue