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

Method unpack

Engine/source/scene/pathManager.cpp:128–150  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

126}
127
128void PathManagerEvent::unpack(NetConnection*, BitStream* stream)
129{
130 // Read in the modified path...
131
132 stream->read(&modifiedPath);
133 clearPaths = stream->readFlag();
134 stream->read(&path.totalTime);
135 stream->read(&path.looping);
136
137 U32 numPoints;
138 stream->read(&numPoints);
139 path.positions.setSize(numPoints);
140 path.rotations.setSize(numPoints);
141 path.msToNext.setSize(numPoints);
142 path.smoothingType.setSize(numPoints);
143 for (U32 j = 0; j < path.positions.size(); j++)
144 {
145 mathRead(*stream, &path.positions[j]);
146 mathRead(*stream, &path.rotations[j]);
147 stream->read(&path.msToNext[j]);
148 stream->read(&path.smoothingType[j]);
149 }
150}
151
152void PathManagerEvent::process(NetConnection*)
153{

Callers

nothing calls this directly

Calls 5

mathReadFunction · 0.85
readFlagMethod · 0.80
readMethod · 0.45
setSizeMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected