Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Oct 13, 2009, 5:05:17 PM (15 years ago)
Author:
dafrick
Message:

Hopefully merged trunk successfully into pickup branch.

Location:
code/branches/pickup
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/pickup

  • code/branches/pickup/src/orxonox/pickup/PickupSpawner.cc

    r5902 r5935  
    103103            asItem->addTemplate(this->itemTemplate_);
    104104            PickupInventory::getImageForItem(asItem);
    105             delete newObject;
     105            newObject->destroy();
    106106        }
    107107
     
    148148        if (this->isActive())
    149149        {
    150             for (ObjectList<Pawn>::iterator it = ObjectList<Pawn>::begin(); it != ObjectList<Pawn>::end(); it++)
     150            for (ObjectList<Pawn>::iterator it = ObjectList<Pawn>::begin(); it != ObjectList<Pawn>::end(); ++it)
    151151            {
    152152                Vector3 distance = it->getWorldPosition() - this->getWorldPosition();
     
    189189                    if (this->respawnTime_ > 0.0f)
    190190                    {
    191                         ExecutorMember<PickupSpawner>* executor = createExecutor(createFunctor(&PickupSpawner::respawnTimerCallback));
    192                         this->respawnTimer_.setTimer(this->respawnTime_, false, this, executor);
     191                        this->respawnTimer_.setTimer(this->respawnTime_, false, createExecutor(createFunctor(&PickupSpawner::respawnTimerCallback, this)));
    193192
    194193                        this->setActive(false);
     
    197196                }
    198197                else
    199                     delete newObject;
     198                    newObject->destroy();
    200199            }
    201200        }
Note: See TracChangeset for help on using the changeset viewer.