Please update comments in code
by Phil Flesher · in Torque Game Engine · 08/18/2004 (11:55 am) · 1 replies
TnlNetObject.h:
/// U32 packUpdate(NetConnection *, U32 mask, BitStream *stream)
/// {
/// // check which states need to be updated, and write updates
/// if(stream->writeFlag(mask & Message1Mask))
/// stream->writeString(message1);
/// if(stream->writeFlag(mask & Message2Mask))
/// stream->writeString(message2);
///
/// // the return value from packUpdate can set which states still
/// // need to be updated for this object.
/// return 0;
/// }
This section has incorrect method signatures. packUpdate() and unpackUpdate() take GhostConnection pointers, not NetConnection.
I blew about an hour today trying to figure out why my pack/unpackUpdate() functions weren't being called. :)
/// U32 packUpdate(NetConnection *, U32 mask, BitStream *stream)
/// {
/// // check which states need to be updated, and write updates
/// if(stream->writeFlag(mask & Message1Mask))
/// stream->writeString(message1);
/// if(stream->writeFlag(mask & Message2Mask))
/// stream->writeString(message2);
///
/// // the return value from packUpdate can set which states still
/// // need to be updated for this object.
/// return 0;
/// }
This section has incorrect method signatures. packUpdate() and unpackUpdate() take GhostConnection pointers, not NetConnection.
I blew about an hour today trying to figure out why my pack/unpackUpdate() functions weren't being called. :)
Associate Mark Frohnmayer