Changeset 459 for code/branches/FICN/src/network
- Timestamp:
- Dec 12, 2007, 12:35:52 AM (17 years ago)
- Location:
- code/branches/FICN/src/network
- Files:
-
- 6 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/FICN/src/network/Client.cc
r448 r459 151 151 * Performs a GameState update 152 152 */ 153 void Client:: update(){153 void Client::tick(float time){ 154 154 ENetPacket *packet; 155 155 // stop if the packet queue is empty -
code/branches/FICN/src/network/Client.h
r438 r459 20 20 #include "GameStateClient.h" 21 21 #include "orxonox/core/IdentifierIncludes.h" 22 //#include "NetworkFrameListener.h" 22 23 23 24 24 25 namespace network{ 25 26 27 28 26 29 /** 30 network::Client *client; 27 31 * The network/Client class 28 32 * This class implements all necessary function for the network communication … … 48 52 bool sendPackets(); 49 53 50 void update();54 void tick(float time); 51 55 52 56 private: … … 62 66 }; 63 67 68 64 69 } 65 70 -
code/branches/FICN/src/network/Server.cc
r444 r459 95 95 * Run this function once every tick 96 96 * calls processQueue and updateGamestate 97 * @param time time since last tick 97 98 */ 98 void Server::tick( ){99 void Server::tick(float time){ 99 100 processQueue(); 100 101 updateGamestate(); -
code/branches/FICN/src/network/Server.h
r440 r459 21 21 #include "enet/enet.h" 22 22 #include "ClientInformation.h" 23 //#include "NetworkFrameListener.h" 24 23 25 24 26 namespace network{ 25 27 28 26 29 /** 27 30 * This class is the root class of the network module for a server. … … 37 40 bool sendMSG(std::string msg); 38 41 bool sendMSG(const char *msg); 39 void tick( );42 void tick(float time); 40 43 protected: 41 44 void processQueue(); … … 49 52 ClientInformation *clients; 50 53 }; 51 52 54 53 55 54 56 -
code/branches/FICN/src/network/Synchronisable.h
r346 r459 17 17 18 18 #include "orxonox/core/IdentifierIncludes.h" 19 #include "orxonox/core/OrxonoxClass.h" 19 20 20 21 namespace network { … … 39 40 * @author Oliver Scheuss 40 41 */ 41 class Synchronisable {42 class Synchronisable : public orxonox::OrxonoxClass{ 42 43 public: 43 44 Synchronisable(); -
code/branches/FICN/src/network/dummyclient3.cc
r448 r459 23 23 24 24 while (true) { 25 client. update();25 client.tick(0); 26 26 std::cout << "your message: "; 27 27 std::getline( std::cin, str ); … … 50 50 51 51 while (true) { 52 client. update();52 client.tick(0); 53 53 usleep(100); 54 54 }
Note: See TracChangeset
for help on using the changeset viewer.