#include <multiplay.h>
Collaboration diagram for MULTIPLAY:

Public Member Functions | |
| MULTIPLAY () | |
| ~MULTIPLAY () | |
| void | UpdateSettings () |
| bool | Connect (string host) |
| void | Disconnect () |
| bool | Host () |
| void | Update (double inc) |
| void | Send (double inc) |
| int | NumConnected () |
| int | MyNum () |
| bool | Server () |
| void | AddRecord (string newdofunction, float newval, int newstate) |
| CARSTATE * | GetCurState (int idx) |
| double | GetTime (int idx) |
| bool | StateToLoad (int idx) |
| void | ClearStateToLoad (int idx) |
| CARSTATE * | GetLoadState (int idx) |
| void | ReceiveState () |
| bool | TickCar (int idx) |
| bool | NOOPTick (int idx) |
| int | NumFuncs (int idx) |
| FUNCTION_MEMORY * | GetFuncMem (int i) |
| int | GetTxRate () |
| int | GetRxRate () |
| float | GetLatency (int player) |
Public Attributes | |
| bool | in_menu |
Private Member Functions | |
| bool | Connected () |
| bool | ExchangeWorldInfo () |
| int | AddToData (void *dest, void *source, int len, int start) |
| int | GetFromData (void *source, void *dest, int len, int start) |
| REPLAY_PACKET * | GetPacketArray (int idx) |
| bool | PacketArrayValid (int idx) |
| double | GetPacketArrayTime (int idx) |
| void | QueuePacket () |
| void | SendPacketArray () |
| void | ReceivePacketArray () |
| void | UpdateFuncmem (int idx) |
| void | ProcessPacket (PBUFFER *p) |
| void | SendState () |
| void | ReadState (Uint8 *s, int slot) |
| int | WriteVector (Vamos_Geometry::Three_Vector wv, Uint8 *dest, int start) |
| int | WriteMatrix (Vamos_Geometry::Three_Matrix wv, Uint8 *dest, int start) |
| int | ReadVector (Vamos_Geometry::Three_Vector &wv, Uint8 *source, int start) |
| int | ReadMatrix (Vamos_Geometry::Three_Matrix &wv, Uint8 *source, int start) |
| void | UpdateStats () |
Private Attributes | |
| int | remote_players |
| int | remote_playernum |
| FUNCTION_MEMORY * | funcmems [MAX_PLAYERS] |
| int | fnums [MAX_PLAYERS] |
| double | timeindex [MAX_PLAYERS] |
| CARSTATE | curstates [MAX_PLAYERS] |
| CARSTATE | loadstates [MAX_PLAYERS] |
| bool | loadstatenow [MAX_PLAYERS] |
| REPLAY_PACKET * | packetarrays [MAX_PLAYERS] |
| int | numpackets [MAX_PLAYERS] |
| double | nooptime [MAX_PLAYERS] |
| bool | noopvalid [MAX_PLAYERS] |
| bool | tickthisframe [MAX_PLAYERS] |
| bool | nooptick [MAX_PLAYERS] |
| int | curpackets [MAX_PLAYERS] |
| int | tx |
| int | rx |
| int | port |
| CARSTATE | dbgstate [MAX_STATES] |
| int | dbgnumstates |
| REPLAY_PACKET | dbgpacket [MAX_PACKETS] |
| int | dbgnumpackets |
Definition at line 84 of file multiplay.h.
|
|
Definition at line 27 of file multiplay.cpp. References fnums, funcmems, MAX_PLAYERS, NULL, remote_playernum, and remote_players. |
|
|
Definition at line 314 of file multiplay.cpp. References funcmems, MAX_PLAYERS, NULL, and packetarrays. |
|
||||||||||||||||
|
Definition at line 575 of file multiplay.cpp. References FUNCTION_MEMORY::active, fnums, GetFuncMem(), FUNCTION_MEMORY::held, MP_DISABLEADDRECORD, FUNCTION_MEMORY::newval, NULL, NumConnected(), and timeindex. |
|
||||||||||||||||||||
|
Definition at line 552 of file multiplay.cpp. Referenced by ExchangeWorldInfo(), SendPacketArray(), WriteMatrix(), and WriteVector(). |
|
|
Definition at line 166 of file multiplay.h. References loadstatenow. |
|
|
Definition at line 73 of file multiplay.cpp. References MESSAGEQ::AddMessage(), REPLAY::BuildFuncMem(), MESSAGEQ::Clear(), NET::Connect(), dbgnumpackets, dbgnumstates, Disconnect(), ExchangeWorldInfo(), fnums, funcmems, loadstatenow, loadstates, MAX_PLAYERS, mq1, net, nooptick, nooptime, noopvalid, numpackets, port, remote_players, replay, Server(), tickthisframe, CARSTATE::time, and timeindex. |
|
|
Definition at line 87 of file multiplay.h. References NET::Connected(), and net. Referenced by Disconnect(), and Send(). |
|
|
Definition at line 276 of file multiplay.cpp. References Connected(), dbgnumpackets, dbgnumstates, dbgpacket, dbgstate, NET::Disconnect(), GetFuncMem(), MAX_PLAYERS, MP_RECORD, MP_REMOTE_RECORD, net, NumFuncs(), remote_playernum, remote_players, replay, timeindex, REPLAY::WriteHeader(), and REPLAY::WritePackets(). |
|
|
Definition at line 331 of file multiplay.cpp. References AddToData(), CONTROL_WORLDINFO, FUNCTION_CHARS, REPLAY::Get_FuncNetControl(), GAMESTATE::GetCarName(), GAMESTATE::GetCarPaint(), GetFuncMem(), GAMESTATE::GetTrackName(), NumConnected(), replay, and state. Referenced by Connect(). |
|
|
Definition at line 161 of file multiplay.h. References curstates. Referenced by SendState(). |
|
||||||||||||||||||||
|
Definition at line 564 of file multiplay.cpp. Referenced by ProcessPacket(), ReadMatrix(), ReadState(), ReadVector(), ReceivePacketArray(), and ReceiveState(). |
|
|
Definition at line 175 of file multiplay.h. References funcmems. Referenced by AddRecord(), Disconnect(), ExchangeWorldInfo(), QueuePacket(), ReceiveState(), SendState(), and UpdateFuncmem(). |
|
|
Definition at line 1379 of file multiplay.cpp. References NumConnected(), and timeindex. |
|
|
Definition at line 167 of file multiplay.h. References loadstates. |
|
|
Definition at line 107 of file multiplay.h. References packetarrays. Referenced by GetPacketArrayTime(), QueuePacket(), ReceivePacketArray(), SendPacketArray(), and UpdateFuncmem(). |
|
|
Definition at line 1305 of file multiplay.cpp. References FrameTime(), GetPacketArray(), MP_DEBUG, numpackets, PACKET_ARRAY_FREQUENCY, and REPLAY_PACKET::time. Referenced by SendPacketArray(). |
|
|
Definition at line 1374 of file multiplay.cpp. References NETSTAT_UPDATE_FREQUENCY, and rx. Referenced by VAMOSWORLD::DrawHUD(). |
|
|
Definition at line 162 of file multiplay.h. References timeindex. |
|
|
Definition at line 1369 of file multiplay.cpp. References NETSTAT_UPDATE_FREQUENCY, and tx. Referenced by VAMOSWORLD::DrawHUD(). |
|
|
Definition at line 111 of file multiplay.cpp. References REPLAY::BuildFuncMem(), NET::Connect(), Disconnect(), fnums, funcmems, net, port, remote_playernum, and replay. |
|
|
Definition at line 158 of file multiplay.h. References remote_playernum. Referenced by SelectCar(). |
|
|
Definition at line 172 of file multiplay.h. References nooptick. |
|
|
Definition at line 546 of file multiplay.cpp. References remote_players. Referenced by AddRecord(), VAMOSWORLD::DrawHUD(), ExchangeWorldInfo(), GetLatency(), MainPause(), SelectCar(), and Update(). |
|
|
Definition at line 174 of file multiplay.h. References fnums. Referenced by Disconnect(). |
|
|
Definition at line 109 of file multiplay.h. References numpackets. |
|
|
Definition at line 618 of file multiplay.cpp. References PBUFFER::data, REPLAY::Get_FuncStateInfo(), GetFromData(), PBUFFER::len, NET_DEBUG, and replay. |
|
|
Definition at line 1044 of file multiplay.cpp. References CHAR_FUNCNUM, CHAR_STATE, REPLAY_PACKET::chardata, GetFuncMem(), GetPacketArray(), FUNCTION_MEMORY::newval, numpackets, timeindex, and REPLAY_PACKET::val. Referenced by Send(). |
|
||||||||||||||||
|
Definition at line 854 of file multiplay.cpp. References GetFromData(). |
|
||||||||||||
|
Definition at line 773 of file multiplay.cpp. References CARSTATE::fnum, CARSTATE::funcmem, REPLAY::Get_FuncStateInfo(), GetFromData(), loadstates, NET_DEBUG, NULL, and replay. Referenced by ReceiveState(). |
|
||||||||||||||||
|
Definition at line 841 of file multiplay.cpp. References GetFromData(). |
|
|
Definition at line 1160 of file multiplay.cpp. References PBUFFER::Clear(), curpackets, PBUFFER::data, dbgnumpackets, dbgpacket, FrameTime(), REPLAY::Get_FuncPacketArray(), NET::GetBuffer(), GetFromData(), NET::GetMaxBuffers(), GetPacketArray(), MP_RECORD, MP_REMOTE_RECORD, net, NET_DEBUG, numpackets, PACKET_ARRAY_FREQUENCY, replay, REPLAY_PACKET::time, timeindex, and PBUFFER::Valid(). |
|
|
|
Definition at line 875 of file multiplay.cpp. References Connected(), in_menu, MP_DBGDEEP, MP_DISABLESEND, QueuePacket(), SendPacketArray(), SendState(), and timeindex. Referenced by Update(). |
|
|
Definition at line 1095 of file multiplay.cpp. References AddToData(), dbgnumpackets, dbgpacket, FrameTime(), REPLAY::Get_FuncNoop(), REPLAY::Get_FuncPacketArray(), GetPacketArray(), GetPacketArrayTime(), MAX_PACKET_SIZE, MP_RECORD, MP_REMOTE_RECORD, net, NET_DEBUG, numpackets, PACKET_ARRAY_FREQUENCY, replay, NET::Send(), and timeindex. Referenced by Send(). |
|
|
Definition at line 654 of file multiplay.cpp. References FUNCTION_MEMORY::active, FUNCTION_MEMORY_SYNC::active, curstates, CARSTATE::fnum, fnums, FrameTime(), CARSTATE::funcmem, GetCurState(), GetFuncMem(), FUNCTION_MEMORY::held, FUNCTION_MEMORY_SYNC::held, FUNCTION_MEMORY::lastupdateat, FUNCTION_MEMORY_SYNC::lastupdateat, net, NET_DEBUG, FUNCTION_MEMORY::newval, FUNCTION_MEMORY_SYNC::newval, NULL, NET::NumBufferedPackets(), STATE_FREQUENCY, CARSTATE::time, and timeindex. Referenced by Send(). |
|
|
Definition at line 68 of file multiplay.cpp. References net, and NET::Server(). Referenced by Connect(). |
|
|
Definition at line 165 of file multiplay.h. References loadstatenow. |
|
|
Definition at line 171 of file multiplay.h. References MP_DISABLETICK, and tickthisframe. Referenced by VAMOSWORLD::PhysUpdate(). |
|
|
Definition at line 123 of file multiplay.cpp. References MP_DBGDEEP, NULL, NumConnected(), PACKET_ARRAY_SIZE, and packetarrays. |
|
|
Definition at line 1326 of file multiplay.cpp. References FUNCTION_MEMORY::active, CHAR_FUNCNUM, CHAR_STATE, REPLAY_PACKET::chardata, curpackets, FrameTime(), FUNCTION_MEMORY::func_name, GetFuncMem(), GetPacketArray(), FUNCTION_MEMORY::held, FUNCTION_MEMORY::newval, NULL, numpackets, timeindex, and REPLAY_PACKET::val. |
|
|
Definition at line 63 of file multiplay.cpp. References SETTINGS::Get(), port, and settings. |
|
|
Definition at line 1389 of file multiplay.cpp. References NET::ClearStats(), FrameTime(), NET::GetRxBytes(), NET::GetTxBytes(), net, NETSTAT_UPDATE_FREQUENCY, rx, timeindex, and tx. |
|
||||||||||||||||
|
Definition at line 751 of file multiplay.cpp. References AddToData(). |
|
||||||||||||||||
|
Definition at line 738 of file multiplay.cpp. References AddToData(). |
|
|
Definition at line 117 of file multiplay.h. Referenced by ReceivePacketArray(), and UpdateFuncmem(). |
|
|
Definition at line 99 of file multiplay.h. Referenced by GetCurState(), and SendState(). |
|
|
Definition at line 146 of file multiplay.h. Referenced by Connect(), Disconnect(), ReceivePacketArray(), and SendPacketArray(). |
|
|
Definition at line 144 of file multiplay.h. Referenced by Connect(), Disconnect(), and ReceiveState(). |
|
|
Definition at line 145 of file multiplay.h. Referenced by Disconnect(), ReceivePacketArray(), and SendPacketArray(). |
|
|
Definition at line 143 of file multiplay.h. Referenced by Disconnect(), and ReceiveState(). |
|
|
Definition at line 93 of file multiplay.h. Referenced by AddRecord(), Connect(), Host(), MULTIPLAY(), NumFuncs(), and SendState(). |
|
|
Definition at line 92 of file multiplay.h. Referenced by Connect(), GetFuncMem(), Host(), MULTIPLAY(), and ~MULTIPLAY(). |
|
|
Definition at line 163 of file multiplay.h. Referenced by Send(). |
|
|
Definition at line 104 of file multiplay.h. Referenced by ClearStateToLoad(), Connect(), ReceiveState(), and StateToLoad(). |
|
|
Definition at line 100 of file multiplay.h. Referenced by Connect(), GetLoadState(), ReadState(), and ReceiveState(). |
|
|
Definition at line 116 of file multiplay.h. Referenced by Connect(), and NOOPTick(). |
|
|
Definition at line 113 of file multiplay.h. Referenced by Connect(). |
|
|
Definition at line 114 of file multiplay.h. Referenced by Connect(). |
|
|
Definition at line 112 of file multiplay.h. Referenced by Connect(), GetPacketArrayTime(), PacketArrayValid(), QueuePacket(), ReceivePacketArray(), SendPacketArray(), and UpdateFuncmem(). |
|
|
Definition at line 106 of file multiplay.h. Referenced by GetPacketArray(), Update(), and ~MULTIPLAY(). |
|
|
Definition at line 140 of file multiplay.h. Referenced by Connect(), Host(), and UpdateSettings(). |
|
|
Definition at line 90 of file multiplay.h. Referenced by Disconnect(), Host(), MULTIPLAY(), and MyNum(). |
|
|
Definition at line 89 of file multiplay.h. Referenced by Connect(), Disconnect(), MULTIPLAY(), and NumConnected(). |
|
|
Definition at line 138 of file multiplay.h. Referenced by GetRxRate(), and UpdateStats(). |
|
|
Definition at line 115 of file multiplay.h. |
|
|
Definition at line 98 of file multiplay.h. Referenced by AddRecord(), Connect(), Disconnect(), GetLatency(), GetTime(), QueuePacket(), ReceivePacketArray(), ReceiveState(), Send(), SendPacketArray(), SendState(), UpdateFuncmem(), and UpdateStats(). |
|
|
Definition at line 138 of file multiplay.h. Referenced by GetTxRate(), and UpdateStats(). |
1.4.6