Changeset 9656 in orxonox.OLD for trunk/src/world_entities/spawning_point.cc
- Timestamp:
- Aug 4, 2006, 11:01:28 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/spawning_point.cc
r9494 r9656 207 207 void SpawningPoint::sendRespawnMessage( int uniqueId ) 208 208 { 209 #warning this byte array is not being deleted according to valginrd 210 byte * buf = new byte[2*INTSIZE]; 209 byte buf[2*INTSIZE]; 211 210 212 211 assert( Converter::intToByteArray( this->getUniqueID(), buf, INTSIZE ) == INTSIZE ); 213 212 assert( Converter::intToByteArray( uniqueId, buf + INTSIZE, INTSIZE ) == INTSIZE ); 214 213 215 MessageManager::getInstance()->sendMessage( MSGID_RESPAWN, buf, 2*INTSIZE, RT_ALL_BUT_ME, 0, MP_HIGHBANDWIDTH ); 216 } 217 218 bool SpawningPoint::respawnMessageHandler( MessageId messageId, byte * data, int dataLength, void * someData, int userId ) 214 MessageManager::getInstance()->sendMessage( MSGID_RESPAWN, buf, 2*INTSIZE, RT_ALL_BUT_ME, NET_UNASSIGNED, MP_HIGHBANDWIDTH ); 215 } 216 217 /** 218 * message handler for respawn message 219 */ 220 bool SpawningPoint::respawnMessageHandler( MessageType messageType, byte * data, int dataLength, void * someData, int senderId, int destinationId ) 219 221 { 220 222 if ( SharedNetworkData::getInstance()->isMasterServer() /*|| SharedNetworkData::getInstance()->isProxyServerActive()*/)
Note: See TracChangeset
for help on using the changeset viewer.