- Timestamp:
- Jul 17, 2006, 1:54:36 PM (18 years ago)
- Location:
- branches/proxy/src
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/proxy/src/lib/coord/p_node.h
r9304 r9305 73 73 74 74 //! Patent Node is a Engine to calculate the position of an Object in respect to the position of its parent. 75 class PNode : virtual public BaseObject, public Synchronizeable {75 class PNode : virtual public BaseObject, virtual public Synchronizeable { 76 76 public: 77 77 PNode (PNode* parent = PNode::getNullParent(), long nodeFlags = PNODE_PARENT_MODE_DEFAULT); -
branches/proxy/src/lib/util/ip.cc
r9304 r9305 7 7 8 8 #include "ip.h" 9 #include "multi_type.h" 9 10 10 11 IP::IP() … … 23 24 24 25 26 27 25 28 int IP::stringToIP(const std::string& ip) 26 29 { 27 30 28 29 31 } 30 32 31 const std::string& IP::ipToString(int ip)33 std::string IP::ipToString(const IPaddress& ipaddr) 32 34 { 33 std::string ipaddr; 34 35 number = SDLNet_Read32 (&addr.host); 36 printf ("Host-Reihenfolge: %d.%d.%d.%d\n", 37 (number & 0xFF000000)>>24, (number & 0x00FF0000)>>16, 38 (number & 0x0000FF00)>>8, (number & 0x000000FF)); 35 int ip = SDLNet_Read32 (ipaddr.host); 36 return ipToString(ip); 39 37 } 40 38 39 40 std::string IP::ipToString(int ip) 41 { 42 MultiType part0( (ip & 0xFF000000) >> 24); 43 MultiType part1( (ip & 0x00FF0000) >> 16); 44 MultiType part2( (ip & 0x0000FF00) >> 8); 45 MultiType part3( (ip & 0x000000FF) ); 46 47 48 return part0.getString() + "." + part1.getString() + "." + 49 part2.getString() + "." + part3.getString(); 50 } 51 -
branches/proxy/src/lib/util/ip.h
r9304 r9305 24 24 25 25 26 float ip() const;27 float ip(unsigned int part) const;26 int ip() const { return this->_ip; }; 27 short port() const { return this->_port; }; 28 28 29 int ip(unsigned int part) const; 29 30 std::string& ipString() const; 30 31 … … 33 34 public: 34 35 static int stringToIP(const std::string& ip); 35 static const std::string& ipToString(int ip); 36 static std::string ipToString(const IPaddress& ipaddr); 37 static std::string ipToString(int ip); 36 38 37 39 private: 38 40 int _ip; //!< the IP in int form. 39 41 short _port; 40 42 41 43 }; -
branches/proxy/src/world_entities/camera.cc
r9235 r9305 17 17 #include "camera.h" 18 18 #include "key_mapper.h" 19 #include "glincl.h" 19 20 20 21 /**
Note: See TracChangeset
for help on using the changeset viewer.