Changeset 6340 in orxonox.OLD for branches/network_merged/src/lib/lang/base_object.cc
- Timestamp:
- Dec 30, 2005, 1:52:26 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/network_merged/src/lib/lang/base_object.cc
r6282 r6340 22 22 #include "compiler.h" 23 23 #include "class_list.h" 24 25 #include "synchronizeable.h" 24 26 25 27 using namespace std; … … 180 182 181 183 } 184 185 /** 186 * Writes data from network containing information about the state 187 * @param data pointer to data 188 * @param length length of data 189 * @param sender hostID of sender 190 */ 191 int BaseObject::writeState( const byte * data, int length, int sender ) 192 { 193 SYNCHELP_READ_BEGIN(); 194 195 if ( objectName ) 196 { 197 delete[] objectName; 198 objectName = NULL; 199 } 200 SYNCHELP_READ_STRINGM( this->objectName ); 201 202 return SYNCHELP_READ_N; 203 } 204 205 /** 206 * data copied in data will bee sent to another host 207 * @param data pointer to data 208 * @param maxLength max length of data 209 * @return the number of bytes writen 210 */ 211 int BaseObject::readState( byte * data, int maxLength ) 212 { 213 SYNCHELP_WRITE_BEGIN(); 214 215 SYNCHELP_WRITE_STRING( this->objectName ); 216 217 return SYNCHELP_WRITE_N; 218 }
Note: See TracChangeset
for help on using the changeset viewer.