Changeset 3015 for code/branches/netp3/src/network/packet
- Timestamp:
- May 22, 2009, 9:46:53 AM (16 years ago)
- Location:
- code/branches/netp3/src/network/packet
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/branches/netp3/src/network/packet/Gamestate.cc
r3003 r3015 111 111 tempsize = it->getData(mem, id, mode); 112 112 if ( it->doSync( id, mode ) ) 113 data Map_.push_back( obj(it->getObjectID(), it->getCreatorID(), tempsize, mem-data_) );113 dataVector_.push_back( obj(it->getObjectID(), it->getCreatorID(), tempsize, mem-data_) ); 114 114 115 115 #ifndef NDEBUG … … 364 364 Gamestate* Gamestate::doSelection(unsigned int clientID, unsigned int targetSize){ 365 365 assert(data_); 366 std:: list<obj>::iterator it;366 std::vector<obj>::iterator it; 367 367 368 368 // allocate memory for new data … … 383 383 384 384 //call TrafficControl 385 TrafficControl::getInstance()->processObjectList( clientID, header_->getID(), &dataMap_ );385 TrafficControl::getInstance()->processObjectList( clientID, header_->getID(), dataVector_ ); 386 386 387 387 //copy in the zeros 388 for(it=data Map_.begin(); it!=dataMap_.end();){388 for(it=dataVector_.begin(); it!=dataVector_.end();){ 389 389 SynchronisableHeader oldobjectheader(origdata); 390 390 SynchronisableHeader newobjectheader(newdata); -
code/branches/netp3/src/network/packet/Gamestate.h
r2896 r3015 37 37 #include <string.h> 38 38 #include <map> 39 #include < list>39 #include <vector> 40 40 #include <cassert> 41 41 #ifndef NDEBUG … … 129 129 private: 130 130 uint32_t calcGamestateSize(int32_t id, uint8_t mode=0x0); 131 std:: list<obj> dataMap_;131 std::vector<obj> dataVector_; 132 132 GamestateHeader* header_; 133 133 };
Note: See TracChangeset
for help on using the changeset viewer.