Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 16, 2008, 6:01:13 PM (16 years ago)
Author:
landauf
Message:

Merged objecthierarchy2 into presentation branch

Couln't merge 2 lines in Gamestate.cc and a whole block of code in GSDedicated.cc (it seems like oli implemented in both branches something like a network-tick-limiter but with different approaches)

Not yet tested in network mode and with bots
The SpaceShips movement is also not yet fully adopted to the new physics (see Engine class)

Location:
code/branches/presentation
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation

  • code/branches/presentation/src/network/packet/Gamestate.cc

    r2476 r2485  
    3131#include "../synchronisable/Synchronisable.h"
    3232#include "../TrafficControl.h"
     33#include "core/Core.h"
    3334#include "core/CoreIncludes.h"
    3435#include "core/Iterator.h"
     
    151152    if(!s)
    152153    {
    153       Synchronisable::fabricate(mem, mode);
     154      if (!Core::isMaster())
     155        Synchronisable::fabricate(mem, mode);
     156      else
     157        mem += objectheader->size;
    154158//         COUT(0) << "could not fabricate synchronisable: " << objectheader->objectID << " classid: " << objectheader->classID << " creator: " << objectheader->creatorID << endl;
    155159//       else
     
    170174      if (it->objectMode_ != 0x0) {
    171175        COUT(0) << "Found object with OBJECTID_UNKNOWN on the client with objectMode != 0x0!" << std::endl;
     176        COUT(0) << "Possible reason for this error: Client created a synchronized object without the Server's approval." << std::endl;
    172177        assert(false);
    173178      }
     
    384389  //call TrafficControl
    385390  TrafficControl::getInstance()->processObjectList( clientID, HEADER->id, &dataMap_ );
    386  
     391
    387392  //copy in the zeros
    388393  for(it=dataMap_.begin(); it!=dataMap_.end();){
    389394//    if((*it).objSize==0)
    390395//      continue;
     396//    if(it->second->getSize(HEADER->id)==0) // merged from objecthierarchy2, doesn't work anymore; TODO: change this
     397//      continue;                            // merged from objecthierarchy2, doesn't work anymore; TODO: change this
    391398    oldobjectheader = (synchronisableHeader*)origdata;
    392399    newobjectheader = (synchronisableHeader*)newdata;
Note: See TracChangeset for help on using the changeset viewer.