Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4397 in orxonox.OLD for orxonox/trunk/src/story_entities/world.cc


Ignore:
Timestamp:
May 30, 2005, 4:57:04 PM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: ok… forces now apply to the right objects, but i don't really like the way it works…. we will see….

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/story_entities/world.cc

    r4396 r4397  
    477477
    478478  Field* gravity = new Gravity();
    479   gravity->setMagnitude(1000);
     479  gravity->setMagnitude(10.0);
    480480  //  gravity->setParent(this->localCamera->getTarget());
    481481 
     
    484484
    485485  new PhysicsConnection(system, gravity);
    486     new PhysicsConnection(this->localPlayer, gravity);
    487  
    488 
    489   WorldEntity* testEntity = new TestEntity();
    490   //testEntity->setRelCoor(Vector(570, 10, -15));
    491   testEntity->setRelCoor(Vector(25, -10, -20));
     486  //    new PhysicsConnection(this->localPlayer, gravity);
     487 
     488
     489  TestEntity* testEntity = new TestEntity();
     490  testEntity->setRelCoor(Vector(570, 10, -15));
     491  //testEntity->setRelCoor(Vector(25, -10, -20));
    492492  testEntity->setRelDir(Quaternion(M_PI, Vector(0, 1, 0)));
    493493  this->spawn(testEntity);
    494   this->localPlayer->addChild(testEntity);
     494  //  this->localPlayer->addChild(testEntity);
     495
     496  new PhysicsConnection(testEntity, gravity);
    495497}
    496498
     
    585587        this->localPlayer->setName ("player");
    586588        this->spawn (this->localPlayer);
     589        this->localPlayer->setRelCoor(Vector(5,0,0));
    587590        /*monitor progress*/
    588591        this->glmis->step();
     592
     593        Field* testField = new Gravity();
     594        testField->setMagnitude(10);
     595        new PhysicsConnection(this->localPlayer, testField);
    589596
    590597        // bind camera
     
    10101017      this->localCamera->tick(this->dt);
    10111018      AnimationPlayer::getInstance()->tick(this->dtS);
    1012 
    10131019      PhysicsEngine::getInstance()->tick(this->dtS);
    10141020
Note: See TracChangeset for help on using the changeset viewer.