#include <net.h>
Collaboration diagram for NET:

Public Member Functions | |
| NET () | |
| ~NET () | |
| void | Init () |
| bool | Connect (string host, int port) |
| void | Update () |
| bool | Server () |
| bool | Connected () |
| void | Disconnect () |
| void | Send (void *data, int size) |
| int | RecvBlock (void *dest, int destsize, int timeout) |
| int | NumBufferedPackets () |
| PBUFFER * | GetBuffer (int idx) |
| int | GetMaxBuffers () |
| int | GetTxBytes () |
| int | GetRxBytes () |
| int | ClearStats () |
Private Member Functions | |
| void | WriteToPacket (UDPpacket *p, Uint8 control, void *data, int size) |
| bool | IsEqualToPacket (UDPpacket *p, Uint8 control, void *data, int size) |
| int | UDPSend (UDPpacket *p, int channel) |
| int | UDPRecv (UDPpacket *p, int channel, int timeout) |
| bool | ClientHandshake () |
| bool | ServerHandshake () |
| int | BufferPacket (UDPpacket *newp) |
Private Attributes | |
| IPaddress | remote_ip |
| UDPsocket | remote_socket |
| UDPpacket * | pout |
| UDPpacket * | pin |
| bool | server |
| bool | connected |
| PBUFFER | buffer [PACKET_BUFFER_LEN] |
| unsigned int | datacounter_tx |
| unsigned int | datacounter_rx |
Definition at line 88 of file net.h.
|
|
Definition at line 8 of file net.cpp. References datacounter_rx, datacounter_tx, NULL, pin, pout, remote_socket, and server. |
|
|
Definition at line 17 of file net.cpp. References Disconnect(). |
|
|
Definition at line 396 of file net.cpp. References buffer, datacounter_rx, and PACKET_BUFFER_LEN. Referenced by Update(). |
|
|
Definition at line 129 of file net.h. References datacounter_rx, and datacounter_tx. Referenced by MULTIPLAY::UpdateStats(). |
|
|
Definition at line 233 of file net.cpp. References connected, CONTROL_HANDSHAKE, HANDSHAKEREPLYSTR, HANDSHAKESTR, HANDSHAKETIMEOUT, IsEqualToPacket(), NET_DEBUG, pin, pout, UDP_FAILURE, UDP_SUCCESS, UDP_TIMEOUT, UDPRecv(), UDPSend(), and WriteToPacket(). Referenced by Connect(). |
|
||||||||||||
|
Definition at line 23 of file net.cpp. References ClientHandshake(), MAX_PACKET_SIZE, NET_DEBUG, NULL, pin, pout, remote_ip, remote_socket, and server. Referenced by MULTIPLAY::Connect(), and MULTIPLAY::Host(). |
|
|
Definition at line 94 of file net.cpp. References connected. Referenced by MULTIPLAY::Connected(). |
|
|
Definition at line 104 of file net.cpp. References connected, NULL, and remote_socket. Referenced by MULTIPLAY::Disconnect(), and ~NET(). |
|
|
Definition at line 125 of file net.h. References buffer. Referenced by MULTIPLAY::ReceivePacketArray(), and MULTIPLAY::ReceiveState(). |
|
|
Definition at line 126 of file net.h. References PACKET_BUFFER_LEN. Referenced by MULTIPLAY::ReceivePacketArray(), and MULTIPLAY::ReceiveState(). |
|
|
Definition at line 128 of file net.h. References datacounter_rx. Referenced by MULTIPLAY::UpdateStats(). |
|
|
Definition at line 127 of file net.h. References datacounter_tx. Referenced by MULTIPLAY::UpdateStats(). |
|
|
Definition at line 3 of file net.cpp. Referenced by InitGameData(). |
|
||||||||||||||||||||
|
Definition at line 114 of file net.cpp. References REPLAY::Get_FuncNetControl(), NET_DEBUG, NULL, and replay. Referenced by ClientHandshake(), and ServerHandshake(). |
|
|
Definition at line 424 of file net.cpp. References buffer, and PACKET_BUFFER_LEN. Referenced by MULTIPLAY::SendState(). |
|
||||||||||||||||
|
Definition at line 346 of file net.cpp. References NET_DEBUG, pin, UDP_SUCCESS, and UDPRecv(). |
|
||||||||||||
|
Definition at line 313 of file net.cpp. References NET_DEBUG, NULL, and pout. Referenced by MULTIPLAY::SendPacketArray(). |
|
|
Definition at line 119 of file net.h. References server. Referenced by MULTIPLAY::Server(). |
|
|
Definition at line 276 of file net.cpp. References connected, CONTROL_HANDSHAKE, HANDSHAKEREPLYSTR, HANDSHAKESTR, IsEqualToPacket(), NET_DEBUG, pin, pout, remote_socket, UDPSend(), and WriteToPacket(). Referenced by Update(). |
|
||||||||||||||||
|
Definition at line 199 of file net.cpp. References datacounter_rx, remote_socket, UDP_FAILURE, UDP_SUCCESS, and UDP_TIMEOUT. Referenced by ClientHandshake(), and RecvBlock(). |
|
||||||||||||
|
Definition at line 189 of file net.cpp. References datacounter_tx, remote_socket, UDP_FAILURE, and UDP_SUCCESS. Referenced by ClientHandshake(), and ServerHandshake(). |
|
|
Definition at line 76 of file net.cpp. References BufferPacket(), connected, NULL, pin, remote_socket, and ServerHandshake(). |
|
||||||||||||||||||||
|
Definition at line 155 of file net.cpp. References REPLAY::Get_FuncNetControl(), NET_DEBUG, NULL, and replay. Referenced by ClientHandshake(), and ServerHandshake(). |
|
|
Definition at line 98 of file net.h. Referenced by BufferPacket(), GetBuffer(), and NumBufferedPackets(). |
|
|
Definition at line 96 of file net.h. Referenced by ClientHandshake(), Connected(), Disconnect(), ServerHandshake(), and Update(). |
|
|
Definition at line 111 of file net.h. Referenced by BufferPacket(), ClearStats(), GetRxBytes(), NET(), and UDPRecv(). |
|
|
Definition at line 110 of file net.h. Referenced by ClearStats(), GetTxBytes(), NET(), and UDPSend(). |
|
|
Definition at line 93 of file net.h. Referenced by ClientHandshake(), Connect(), NET(), RecvBlock(), ServerHandshake(), and Update(). |
|
|
Definition at line 93 of file net.h. Referenced by ClientHandshake(), Connect(), NET(), Send(), and ServerHandshake(). |
|
|
Definition at line 91 of file net.h. Referenced by Connect(). |
|
|
Definition at line 92 of file net.h. Referenced by Connect(), Disconnect(), NET(), ServerHandshake(), UDPRecv(), UDPSend(), and Update(). |
|
|
|
1.4.6