Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 1083


Ignore:
Timestamp:
Apr 16, 2008, 7:09:07 PM (17 years ago)
Author:
scheusso
Message:

found that fucking bug

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/network/src/network/GameStateClient.cc

    r1016 r1083  
    2828
    2929#include "core/CoreIncludes.h"
     30#include "core/BaseObject.h"
    3031#include "Synchronisable.h"
    3132#include "GameStateClient.h"
     
    3940 
    4041  GameStateClient::GameStateClient() {
     42    COUT(5) << "this: " << this << std::endl;
    4143  }
    4244
     
    110112        if(!it){
    111113          COUT(4) << "loadSnapshot:\tclassid: " << sync.classID << ", name: " << ID((unsigned int) sync.classID)->getName() << std::endl;
    112           Synchronisable *no = (Synchronisable*)(ID((unsigned int) sync.classID)->fabricate());
     114          Synchronisable *no = dynamic_cast<Synchronisable *>(ID((unsigned int) sync.classID)->fabricate());
    113115          no->objectID=sync.objectID;
    114116          no->classID=sync.classID;
     
    117119          if( !no->updateData(sync) && !no->create() )
    118120            COUT(1) << "We couldn't create/update the object: " << sync.objectID << std::endl;
    119           ++it;
    120121        }
    121122      } else {
Note: See TracChangeset for help on using the changeset viewer.