Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 29, 2006, 1:57:48 PM (19 years ago)
Author:
rennerc
Message:

new network system implemented. yet with a lot of empty function bodys

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/world_entities/terrain.cc

    r7221 r7444  
    423423}
    424424
    425 int Terrain::writeBytes( const byte * data, int length, int sender )
    426 {
    427   setRequestedSync( false );
    428   setIsOutOfSync( false );
    429 
    430   SYNCHELP_READ_BEGIN();
    431   SYNCHELP_READ_FKT( WorldEntity::writeState, NWT_TER_WE_STATE );
    432 
    433   return SYNCHELP_READ_N;
    434 }
    435 
    436 int Terrain::readBytes( byte * data, int maxLength, int * reciever )
    437 {
    438   if ( isOutOfSync() && !requestedSync() && this->getHostID()!=this->getOwner() )
    439   {
    440     (NetworkGameManager::getInstance())->sync( this->getUniqueID(), this->getOwner() );
    441     setRequestedSync( true );
    442   }
    443 
    444   int rec = this->getRequestSync();
    445   if ( rec > 0 )
    446   {
    447     *reciever = rec;
    448 
    449     SYNCHELP_WRITE_BEGIN();
    450     SYNCHELP_WRITE_FKT( WorldEntity::readState, NWT_TER_WE_STATE );
    451     return SYNCHELP_WRITE_N;
    452 
    453   }
    454 
    455   *reciever = 0;
    456   return 0;
    457 }
    458 
    459 void Terrain::writeDebug( ) const
    460   {}
    461 
    462 void Terrain::readDebug( ) const
    463   {}
    464 
    465425float Terrain::getHeight(float x, float y)
    466426{
Note: See TracChangeset for help on using the changeset viewer.