Changeset 9360 in orxonox.OLD for branches/proxy/src/lib/network/handshake.h
- Timestamp:
- Jul 20, 2006, 3:49:57 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/proxy/src/lib/network/handshake.h
r9350 r9360 14 14 #include "ip.h" 15 15 #include "synchronizeable.h" 16 #include "shared_network_data.h" 16 17 17 18 //!< a struct to save the handshakes to … … 35 36 //additional data 36 37 std::string preferedNickName; //!< prefered nick name 37 38 int redirectProxy; //!< true if the client should reconnect to a proxy server (either 1 or 2 )39 IP proxy1; //!< ip address of the first proxy (0.0.0.0 of not available)40 IP proxy2; //!< ip address of the second proxy (0.0.0.0 of not available)41 38 }; 42 39 … … 81 78 82 79 /** @returns if true the local client should reconnect to a proxy server from the proxy server list */ 83 inline bool redirect() { return this->re moteState.redirectProxy;}80 inline bool redirect() { return this->redirectProxy;} 84 81 /** @param flag: indicating if the client should be redirected */ 85 inline void setRedirect(bool flag) { this-> localState.redirectProxy = flag; }82 inline void setRedirect(bool flag) { this->redirectProxy = flag; } 86 83 87 84 /** @param address: the address of the proxy server 1 if any */ 88 inline void setProxy1Address(IP address) { this->localState.proxy1 = address; }85 inline void setProxy1Address(IP address) { if( !SharedNetworkData::getInstance()->isMasterServer()) return; this->proxy1 = address; } 89 86 /** @returns the address of the proxy server 1 if any */ 90 inline IP getProxy1Address() { return this-> remoteState.proxy1; }87 inline IP getProxy1Address() { return this->proxy1; } 91 88 /** @param address: the address of the proxy server 2 if any */ 92 inline void setProxy2Address(IP address) { this-> localState.proxy2 = address; }89 inline void setProxy2Address(IP address) { this->proxy2 = address; } 93 90 /** @returns the address of the proxy server 2 if any */ 94 inline IP getProxy2Address() { return this-> remoteState.proxy2; }91 inline IP getProxy2Address() { return this->proxy2; } 95 92 96 93 … … 119 116 120 117 int proxyAddressesSynched; //!< number of addresses synched 121 118 int redirectProxy; //!< true if the client should reconnect to a proxy server 119 IP proxy1; //!< ip address of the first proxy (0.0.0.0 of not available) 120 IP proxy2; //!< ip address of the second proxy (0.0.0.0 of not available) 122 121 }; 123 122
Note: See TracChangeset
for help on using the changeset viewer.