MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / readDemoStartBlock

Method readDemoStartBlock

Engine/source/sim/netConnection.cpp:951–979  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

949}
950
951bool NetConnection::readDemoStartBlock(BitStream* stream)
952{
953 ConnectionProtocol::readDemoStartBlock(stream);
954
955 stream->read(&mRoundTripTime);
956 stream->read(&mPacketLoss);
957
958#ifndef TORQUE_TGB_ONLY
959 // Read
960 gClientPathManager->readState(stream);
961#endif
962
963 mStringTable->readDemoStartBlock(stream);
964 U32 pos;
965 stream->read(&pos); // notify count
966 for(U32 i = 0; i < pos; i++)
967 {
968 PacketNotify *note = allocNotify();
969 note->nextPacket = NULL;
970 if(!mNotifyQueueHead)
971 mNotifyQueueHead = note;
972 else
973 mNotifyQueueTail->nextPacket = note;
974 mNotifyQueueTail = note;
975 }
976 eventReadStartBlock(stream);
977 ghostReadStartBlock(stream);
978 return true;
979}
980
981bool NetConnection::startDemoRecord(const char *fileName)
982{

Callers

nothing calls this directly

Calls 2

readStateMethod · 0.80
readMethod · 0.45

Tested by

no test coverage detected