mirror of
https://github.com/overte-org/overte.git
synced 2025-08-06 18:50:00 +02:00
Merge pull request #445 from ZappoMan/local_option
add --local option to avatar-mixer
This commit is contained in:
commit
82463260e4
1 changed files with 12 additions and 0 deletions
|
@ -51,7 +51,19 @@ void attachAvatarDataToAgent(Agent* newAgent) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool wantLocalDomain = false;
|
||||||
|
|
||||||
int main(int argc, const char* argv[]) {
|
int main(int argc, const char* argv[]) {
|
||||||
|
|
||||||
|
// Handle Local Domain testing with the --local command line
|
||||||
|
const char* local = "--local";
|
||||||
|
::wantLocalDomain = cmdOptionExists(argc, argv,local);
|
||||||
|
if (::wantLocalDomain) {
|
||||||
|
printf("Local Domain MODE!\n");
|
||||||
|
int ip = getLocalAddress();
|
||||||
|
sprintf(DOMAIN_IP,"%d.%d.%d.%d", (ip & 0xFF), ((ip >> 8) & 0xFF),((ip >> 16) & 0xFF), ((ip >> 24) & 0xFF));
|
||||||
|
}
|
||||||
|
|
||||||
AgentList* agentList = AgentList::createInstance(AGENT_TYPE_AVATAR_MIXER, AVATAR_LISTEN_PORT);
|
AgentList* agentList = AgentList::createInstance(AGENT_TYPE_AVATAR_MIXER, AVATAR_LISTEN_PORT);
|
||||||
setvbuf(stdout, NULL, _IOLBF, 0);
|
setvbuf(stdout, NULL, _IOLBF, 0);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue