Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 6097 in orxonox.OLD for branches/network


Ignore:
Timestamp:
Dec 14, 2005, 2:29:44 AM (19 years ago)
Author:
patrick
Message:

network: the network core is almost finished

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/network/src/story_entities/network_world.cc

    r6096 r6097  
    341341  // find WorldEntities //
    342342  ////////////////////////
    343   if( /*NetworkManager::getInstance()->isGameServer()*/1)
    344   {
    345     element = root->FirstChildElement("WorldEntities");
    346     if( element == NULL)
    347     {
    348       PRINTF(1)("NetworkWorld is missing 'WorldEntities'\n");
    349     }
    350     else
    351     {
    352       element = element->FirstChildElement();
     343  if( NetworkManager::getInstance()->isGameServer())
     344  {}
     345
     346  element = root->FirstChildElement("WorldEntities");
     347  if( element == NULL)
     348  {
     349    PRINTF(1)("NetworkWorld is missing 'WorldEntities'\n");
     350  }
     351  else
     352  {
     353    element = element->FirstChildElement();
    353354      // load Players/Objects/Whatever
    354       PRINTF(4)("Loading NetworkWorldEntities\n");
    355       while( element != NULL)
     355    PRINTF(4)("Loading NetworkWorldEntities\n");
     356    while( element != NULL)
     357    {
     358      if( NetworkManager::getInstance()->isGameServer() || !strcmp( element->Value(), "SkyBox") || !strcmp( element->Value(), "Terrain"))
    356359      {
    357360        BaseObject* created = Factory::fabricate(element);
     
    374377          CDEngine::getInstance()->setTerrain(terrain);
    375378        }
    376         element = element->NextSiblingElement();
    377         glmis->step(); //! @todo temporary
     379
    378380      }
     381      element = element->NextSiblingElement();
     382      glmis->step(); //! @todo temporary
    379383      PRINTF(4)("Done loading NetworkWorldEntities\n");
    380384    }
    381385  }
     386
    382387
    383388    //////////////////////////////
Note: See TracChangeset for help on using the changeset viewer.