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

Method readClassId

Engine/source/core/stream/bitStream.cpp:211–224  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

209}
210
211S32 BitStream::readClassId(U32 classType, U32 classGroup)
212{
213 AssertFatal(classType < NetClassTypesCount, "Out of range class type.");
214 AssertFatal(classGroup < NetClassGroupsCount, "Out of range class group.");
215 AssertFatal(AbstractClassRep::NetClassCount[classGroup][classType] < (1 << AbstractClassRep::NetClassBitSize[classGroup][classType]),
216 "NetClassBitSize too small!");
217
218 S32 ret = readInt(AbstractClassRep::NetClassBitSize[classGroup][classType]);
219
220 AssertFatal(ret < AbstractClassRep::NetClassCount[classGroup][classType], "BitStream::readClassId - unexpected class ID!");
221 if(ret >= AbstractClassRep::NetClassCount[classGroup][classType])
222 return -1;
223 return ret;
224}
225
226void BitStream::writeBits(S32 bitCount, const void *bitPtr)
227{

Callers 6

unpackMethod · 0.80
ghostReadPacketMethod · 0.80
ghostReadStartBlockMethod · 0.80
eventReadPacketMethod · 0.80
eventReadStartBlockMethod · 0.80
unpackMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected