Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3215 in orxonox.OLD


Ignore:
Timestamp:
Dec 18, 2004, 4:10:05 AM (19 years ago)
Author:
patrick
Message:

/orxonox/trunk: discovered a minor bug and fixed some code style issues…

Location:
orxonox/trunk/src
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/camera.cc

    r3213 r3215  
    3030{
    3131  this->world = world;
    32   bound = NULL;
     32  this->bound = NULL;
    3333  /* give it some physical live */
    34   m = 10;
    35   a = new Vector(0.0, 0.0, 0.0);
    36   v = new Vector(0.0, 0.0, 0.0);
    37   fs = new Vector(0.0, 0.0, 0.0);
    38   cameraMode = NORMAL;
    39   deltaTime = 3000.0;
    40   cameraOffset = 1.0;
    41   cameraOffsetZ = 10.0;
    42   t = 0.0;
    43 
    44   actual_place.r.x = 0.0;
    45   actual_place.r.y = 10.0;
    46   actual_place.r.z = -5.0;
     34  this->m = 10;
     35  this->a = new Vector(0.0, 0.0, 0.0);
     36  this->v = new Vector(0.0, 0.0, 0.0);
     37  this->fs = new Vector(0.0, 0.0, 0.0);
     38  this->cameraMode = NORMAL;
     39  this->deltaTime = 3000.0;
     40  this->cameraOffset = 1.0;
     41  this->cameraOffsetZ = 10.0;
     42  this->t = 0.0;
     43
     44  this->actual_place.r.x = 0.0;
     45  this->actual_place.r.y = 10.0;
     46  this->actual_place.r.z = -5.0;
    4747}
    4848
     
    6363void Camera::time_slice (Uint32 deltaT)
    6464{
    65   if(t <= deltaTime)
    66     {t += deltaT;}
     65  if( this->t <= deltaTime)
     66    {this->t += deltaT;}
    6767  //printf("time is: t=%f\n", t );
    68   update_desired_place ();
    69   jump (NULL);
     68  update_desired_place();
     69  jump(NULL);
    7070}
    7171
     
    242242  /*  translation */
    243243  glTranslatef (-actual_place.r.x, -actual_place.r.y,- actual_place.r.z);
    244   //Placement *plBound = bound->get_placement();
     244//Placement *plBound = bound->get_placement();
    245245
    246246  // ===== second camera control calculation option
    247247  /*
    248     gluLookAt(actual_place.r.x, actual_place.r.y, actual_place.r.z,
     248   gluLookAt(actual_place.r.x, actual_place.r.y, actual_place.r.z,
    249249              plBound->r.x, plBound->r.y, plBound->r.z,
    250250              0.0, 0.0, 1.0);
  • orxonox/trunk/src/command_node.cc

    r3214 r3215  
    248248void CommandNode::relay (Command* cmd)
    249249{
    250  
     250
    251251  Orxonox *orx = Orxonox::getInstance();
    252252  if( orx->system_command (cmd)) return;
  • orxonox/trunk/src/game_loader.cc

    r2636 r3215  
    119119
    120120
    121 
    122 
    123 
    124121Campaign* GameLoader::fileToCampaign(char *name)
    125122{
  • orxonox/trunk/src/orxonox.cc

    r3214 r3215  
    321321    }
    322322 
    323   //(*orx).mainLoop();
    324 
    325323  orx->start();
    326324 
  • orxonox/trunk/src/world.cc

    r3213 r3215  
    7575{
    7676  this->bQuitCurrentGame = true;
    77   this->localCamera->setWorld(NULL);
     77  //this->localCamera->setWorld(NULL);
     78  this->localPlayer->destroy();
    7879  this->localCamera->destroy();
    7980
     
    569570  this->bQuitCurrentGame = false;
    570571  printf("World|Entering main loop\n");
    571   while(!this->bQuitOrxonox && !this->bQuitCurrentGame) /* pause pause pause ?!?!?*/
     572  while( !this->bQuitOrxonox && !this->bQuitCurrentGame) /* \todo implement pause */
    572573    {
    573574      //debug routine
     
    577578      // Process input
    578579      handle_input();
     580      if( this->bQuitCurrentGame || this->bQuitOrxonox)
     581        {
     582          printf("World::mainLoop() - leaving loop earlier...\n");
     583          break;
     584        }
    579585      // Process time
    580586      time_slice();
     
    586592      for(int i = 0; i < 10000000; i++) {}
    587593    }
    588   printf("World|Exiting the main loop\n");
     594  printf("World::mainLoop() - Exiting the main loop\n");
    589595}
    590596
     
    655661    {
    656662      if( !cmd->bUp) this->bQuitOrxonox = true;
    657       return true;
     663      {
     664        printf("World::system_command() - rescv quit command\n");
     665        return true;
     666      }
    658667    }
    659668  return false;
Note: See TracChangeset for help on using the changeset viewer.