Panda3D
Loading...
Searching...
No Matches
config_distributed.cxx
Go to the documentation of this file.
1/**
2 * PANDA 3D SOFTWARE
3 * Copyright (c) Carnegie Mellon University. All rights reserved.
4 *
5 * All use of this software is subject to the terms of the revised BSD
6 * license. You should have received a copy of this license along
7 * with this source code in a file named "LICENSE."
8 *
9 * @file config_distributed.cxx
10 * @author drose
11 * @date 2004-05-19
12 */
13
14#include "config_distributed.h"
15#include "dconfig.h"
16
17#if !defined(CPPPARSER) && !defined(LINK_ALL_STATIC) && !defined(BUILDING_DIRECT_DISTRIBUTED)
18 #error Buildsystem error: BUILDING_DIRECT_DISTRIBUTED not defined
19#endif
20
21Configure(config_distributed);
22NotifyCategoryDef(distributed, "");
23
24ConfigureFn(config_distributed) {
26}
27
28ConfigVariableInt game_server_timeout_ms
29("game-server-timeout-ms", 20000,
30 PRC_DESC("This represents the amount of time to block waiting for the TCP "
31 "connection to the game server. It is only used when the connection "
32 "method is NSPR."));
33
35("min-lag", 0.0,
36 PRC_DESC("This represents the time in seconds by which to artificially lag "
37 "inbound messages. It is useful to test a game's tolerance of "
38 "network latency."));
39
41("max-lag", 0.0,
42 PRC_DESC("This represents the time in seconds by which to artificially lag "
43 "inbound messages. It is useful to test a game's tolerance of "
44 "network latency."));
45
46ConfigVariableBool handle_datagrams_internally
47("handle-datagrams-internally", true,
48 PRC_DESC("When this is true, certain datagram types can be handled "
49 "directly by the C++ cConnectionRepository implementation, "
50 "for performance reasons. When it is false, all datagrams "
51 "are handled by the Python implementation."));
52
53/**
54 * Initializes the library. This must be called at least once before any of
55 * the functions or classes in this library can be used. Normally it will be
56 * called by the static initializers and need not be called explicitly, but
57 * special cases exist.
58 */
59void
61 static bool initialized = false;
62 if (initialized) {
63 return;
64 }
65 initialized = true;
66
67}
This is a convenience class to specialize ConfigVariable as a boolean type.
This is a convenience class to specialize ConfigVariable as a floating- point type.
This is a convenience class to specialize ConfigVariable as an integer type.
void init_libdistributed()
Initializes the library.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.