mirror of
https://github.com/overte-org/overte.git
synced 2025-04-20 11:45:36 +02:00
changed to EC2 domain server by default in interface, increased domain server keep alive timeout to 5 seconds.
This commit is contained in:
parent
4ed1971276
commit
ecc7eee161
2 changed files with 17 additions and 11 deletions
|
@ -5,8 +5,17 @@
|
|||
// Created by Philip Rosedale on 11/20/12.
|
||||
// Copyright (c) 2012 High Fidelity, Inc. All rights reserved.
|
||||
//
|
||||
// The Domain Server
|
||||
//
|
||||
// The Domain Server keeps a list of agents that have connected to it, and echoes that list of
|
||||
// agents out to agents when they check in.
|
||||
//
|
||||
// The connection is stateless... the domain server will set you inactive if it does not hear from
|
||||
// you in LOGOFF_CHECK_INTERVAL milliseconds, meaning your info will not be sent to other users.
|
||||
//
|
||||
// Each packet from an agent has as first character the type of server:
|
||||
//
|
||||
// I - Interactive Agent
|
||||
// M - Audio Mixer
|
||||
//
|
||||
|
||||
#include <iostream>
|
||||
#include <math.h>
|
||||
|
@ -19,10 +28,8 @@
|
|||
#include <fcntl.h>
|
||||
#include <sys/time.h>
|
||||
|
||||
// Domain server listens for packets on this port number
|
||||
|
||||
const int LISTENING_UDP_PORT = 40102;
|
||||
|
||||
|
||||
const char DESTINATION_IP[] = "127.0.0.1";
|
||||
sockaddr_in address, dest_address;
|
||||
socklen_t destLength = sizeof( dest_address );
|
||||
|
@ -32,7 +39,7 @@ const int MAX_PACKET_SIZE = 1500;
|
|||
char packet_data[MAX_PACKET_SIZE];
|
||||
|
||||
const int MAX_AGENTS = 1000;
|
||||
const int LOGOFF_CHECK_INTERVAL = 2000;
|
||||
const int LOGOFF_CHECK_INTERVAL = 5000;
|
||||
|
||||
struct AgentList {
|
||||
char agentType;
|
||||
|
|
|
@ -56,7 +56,7 @@ int simulate_on = 1;
|
|||
//
|
||||
|
||||
const int MAX_PACKET_SIZE = 1500;
|
||||
char DOMAINSERVER_IP[] = "127.0.0.1";
|
||||
char DOMAINSERVER_IP[] = "54.241.92.53";
|
||||
const int DOMAINSERVER_PORT = 40102;
|
||||
UDPSocket agentSocket(AGENT_UDP_PORT);
|
||||
|
||||
|
@ -73,7 +73,7 @@ int target_x, target_y;
|
|||
int target_display = 0;
|
||||
|
||||
int head_mirror = 1; // Whether to mirror own head when viewing it
|
||||
int sendToSelf = 0;
|
||||
int sendToSelf = 1;
|
||||
|
||||
int WIDTH = 1200;
|
||||
int HEIGHT = 800;
|
||||
|
@ -129,9 +129,6 @@ GLfloat start_location[] = {6.1, 0, 1.4};
|
|||
GLfloat location[] = {start_location[0], start_location[1], start_location[2]};
|
||||
float fwd_vel = 0.0f;
|
||||
|
||||
|
||||
#define MAX_FILE_CHARS 100000 // Biggest file size that can be read to the system
|
||||
|
||||
int stats_on = 0; // Whether to show onscreen text overlay with stats
|
||||
|
||||
int noise_on = 0; // Whether to add random noise
|
||||
|
@ -941,6 +938,8 @@ int main(int argc, char** argv)
|
|||
// Create network socket and buffer
|
||||
incoming_packet = new char[MAX_PACKET_SIZE];
|
||||
|
||||
|
||||
//gethostbyname(hostname);
|
||||
// Send one test packet to detect own IP, port:
|
||||
char selfTest[] = "T";
|
||||
agentSocket.send((char *)"127.0.0.1", AGENT_UDP_PORT, selfTest, 1);
|
||||
|
|
Loading…
Reference in a new issue