Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8306 for code


Ignore:
Timestamp:
Apr 22, 2011, 9:51:25 PM (14 years ago)
Author:
dafrick
Message:

Fixing bug introduced just a few commits prior to this one.
Also made some output more verbose.

Location:
code/trunk/src/orxonox/interfaces
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk/src/orxonox/interfaces/PickupCarrier.cc

    r8303 r8306  
    111111        delete children;
    112112
    113         return false;
     113        return isTarget;
    114114    }
    115115
  • code/trunk/src/orxonox/interfaces/Pickupable.cc

    r7547 r8306  
    126126            return false;
    127127
    128         COUT(4) << "Pickupable (&" << this << ") set to used " << used << "." << std::endl;
     128        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") set to used " << used << "." << std::endl;
    129129
    130130        this->used_ = used;
     
    201201            return false;
    202202
    203         COUT(4) << "Target " << target->getName() << " added to Pickupable (&" << this << ")." << std::endl;
     203        COUT(4) << "Target " << target->getName() << " added to Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ")." << std::endl;
    204204        this->targets_.push_back(target);
    205205        return true;
     
    221221        if(!this->setCarrier(carrier))
    222222        {
    223             COUT(3) << "A Pickupable (&" << this << ") was trying to be added to a PickupCarrier, but was already present." << std::endl;
     223            COUT(3) << "A Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") was trying to be added to a PickupCarrier, but was already present." << std::endl;
    224224            return false;
    225225        }
    226226
    227227        this->setPickedUp(true);
    228         COUT(4) << "Pickupable (&" << this << ") got picked up by a PickupCarrier (&" << carrier << ")." << std::endl;
     228        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") got picked up by a PickupCarrier (&" << carrier << ")." << std::endl;
    229229        return true;
    230230    }
     
    247247            COUT(2) << "Pickupable (&" << this << ", " << this->getIdentifier()->getName() << ") is being dropped, but it was not present in the PickupCarriers list of pickups." << std::endl;
    248248
    249         COUT(4) << "Pickupable (&" << this << ") got dropped up by a PickupCarrier (&" << this->getCarrier() << ")." << std::endl;
     249        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") got dropped up by a PickupCarrier (&" << this->getCarrier() << ")." << std::endl;
    250250        this->setUsed(false);
    251251        this->setPickedUp(false);
     
    276276            return false;
    277277
    278         COUT(4) << "Pickupable (&" << this << ") set to pickedUp " << pickedUp << "." << std::endl;
     278        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") set to pickedUp " << pickedUp << "." << std::endl;
    279279
    280280        this->pickedUp_ = pickedUp;
     
    305305            return false;
    306306
    307         COUT(4) << "Pickupable (&" << this << ") changed Carrier (& " << carrier << ")." << std::endl;
     307        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") changed Carrier (& " << carrier << ")." << std::endl;
    308308
    309309        if(carrier != NULL && tell)
     
    340340        Pickupable* pickup = dynamic_cast<Pickupable*>(item);
    341341
    342         COUT(4) << "Pickupable (&" << this << ") cloned. Clone is new Pickupable (&" << pickup << ")." << std::endl;
     342        COUT(4) << "Pickupable (" << this->getIdentifier()->getName() << ") (&" << this << ") cloned. Clone is new Pickupable (&" << pickup << ")." << std::endl;
    343343        return pickup;
    344344    }
Note: See TracChangeset for help on using the changeset viewer.