Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Apr 29, 2012, 5:22:56 PM (13 years ago)
Author:
mentzerf
Message:

+ Tried to create waypoints programmatically, succeeded, BUT: the spaceship does not follow them!!

  • Changed WaypointController to log some debug info
File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/newlevel2012/src/orxonox/controllers/WaypointController.cc

    r8891 r9142  
    6262    void WaypointController::tick(float dt)
    6363    {
    64         if (!this->isActive())
     64                if (!this->isActive())
    6565            return;
     66
     67                orxout() << "(" << this->waypoints_.size() << ") entity: " << this->getControllableEntity() << endl;
     68
    6669
    6770        if (this->waypoints_.size() == 0 || !this->getControllableEntity())
    6871            return;
    6972
     73                printf("3");
     74
    7075        if (this->waypoints_[this->currentWaypoint_]->getWorldPosition().squaredDistance(this->getControllableEntity()->getPosition()) <= this->squaredaccuracy_)
    7176            this->currentWaypoint_ = (this->currentWaypoint_ + 1) % this->waypoints_.size();
     77
     78                printf("4");
    7279
    7380        this->moveToPosition(this->waypoints_[this->currentWaypoint_]->getWorldPosition());
Note: See TracChangeset for help on using the changeset viewer.