Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Sep 3, 2010, 11:54:30 PM (14 years ago)
Author:
scheusso
Message:

fixed a bug in gamestate diff which wasted bandwidth

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/network3/src/libraries/network/packet/Gamestate.cc

    r7337 r7344  
    373373  uint32_t objectOffset = SynchronisableHeader::getSize(); // offset inside the object in the origData and baseData
    374374  // Check whether the whole object stayed the same
    375   if( memcmp( origData+objectOffset, newData+objectOffset, objectHeader.getDataSize()) == 0 )
     375  if( memcmp( origData+objectOffset, baseData+objectOffset, objectHeader.getDataSize()) == 0 )
    376376  {
    377377    //         COUT(4) << "skip object" << Synchronisable::getSynchronisable(h.getObjectID())->getIdentifier()->getName() << endl;
     
    430430    h2.setDataSize(newObjectOffset-SynchronisableHeaderLight::getSize());
    431431    assert(objectOffset == objectHeader.getDataSize()+SynchronisableHeader::getSize());
     432    assert(h2.getDataSize()>0);
    432433    origData += objectOffset;
    433434    //         baseOffset += temp + h.getDataSize()+SynchronisableHeader::getSize() - baseData;
Note: See TracChangeset for help on using the changeset viewer.