Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 29, 2005, 2:10:40 AM (19 years ago)
Author:
bensch
Message:

orxonox/trunk: ok, Gravity, and PhysicalConnection loadable

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/physics/physics_connection.cc

    r4728 r4731  
    3737  this->setClassID(CL_PHYSICS_CONNECTION, "PhysicsConnection");
    3838  this->type = PCON_PhysIField;
     39
    3940  this->subject = subject;
    4041  this->field = field;
     
    5556  LoadParam<PhysicsConnection>(root, "field", this, &PhysicsConnection::setField)
    5657      .describe("set the field by name");
     58
     59  PhysicsEngine::getInstance()->addConnection(this);
    5760}
    5861
     
    7376  this->subject = PhysicsEngine::getInstance()->getPhysicsInterfaceByName(subjectName);
    7477  if (this->subject == NULL)
     78  {
    7579    PRINTF(2)("subject: (%s) not found for PhysicsConnection\n", subjectName);
     80  }
     81  else
     82    PRINTF(5)("subject::%s\n", this->subject->getName());
    7683}
    7784
     
    8390  this->field = PhysicsEngine::getInstance()->getFieldByName(fieldName);
    8491  if (this->field == NULL)
    85     PRINTF(2)("field: (%s) not found for PhysicsConnection\n", fieldName);
     92  {
     93        PRINTF(2)("field: (%s) not found for PhysicsConnection\n", fieldName);
     94  }
     95  else
     96    PRINTF(5)("field::%s\n", this->field->getName());
     97
    8698}
    8799
Note: See TracChangeset for help on using the changeset viewer.