Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 14, 2005, 11:06:20 PM (18 years ago)
Author:
hdavid
Message:

orxonox/branches/network: updated network_socket.h and network_socket.cc

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/lib/network/network_socket.h

    r5533 r5565  
    88#define _NETWORK_SOCKET
    99
     10/* include this file, it contains some default definitions */
     11#include "netdefs.h"
     12
     13/* include SDL_net header */
     14#include "SDL_net.h"
     15
     16/* using namespace std is default, this needs to be here */
     17using namespace std;
    1018
    1119class NetworkSocket
    1220{
     21
     22private:
     23        IPaddress serverAddress;
     24        unsigned int port;
     25        TCPsocket tcpSocket;
     26        UDPsocket udpSocket;
    1327
    1428public:
     
    1731  ~NetworkSocket();
    1832
    19   void connectToServer();
    20   void listen();
     33  void connectToServer(IPaddress ip, unsigned int port);
     34  void listen(unsigned int port);
    2135  void disconnectServer();
    22   void writeBytes();
    23         void readBytes();
     36  void writeBytes(byte* data);
     37  byte* readBytes();
    2438
    2539};
Note: See TracChangeset for help on using the changeset viewer.