Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 26, 2011, 3:56:04 PM (13 years ago)
Author:
dafrick
Message:

Some cleanup.

Location:
code/branches/portals2/src/modules/portals
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/portals2/src/modules/portals/PortalEndPoint.cc

    r8599 r8600  
    3232#include "portals/PortalLink.h"
    3333#include "worldentities/MobileEntity.h"
    34 
     34#include <ctime>
    3535
    3636namespace orxonox
     
    4242    std::map<unsigned int, PortalEndPoint *> PortalEndPoint::idMap_s;
    4343
    44     PortalEndPoint::PortalEndPoint(BaseObject* creator) : StaticEntity(creator), id_(0), trigger_(new DistanceMultiTrigger(this)), reenterDelay_(0)
     44    PortalEndPoint::PortalEndPoint(BaseObject* creator) : StaticEntity(creator), id_(0), trigger_(NULL), reenterDelay_(0)
    4545    {
    4646        RegisterObject(PortalEndPoint);
     47       
     48        this->trigger_ = new DistanceMultiTrigger(this);
    4749        this->trigger_->setName("portal");
    4850        this->attach(trigger_);
     
    5153    PortalEndPoint::~PortalEndPoint()
    5254    {
    53    
     55        if(this->isInitialized() && this->trigger_ != NULL)
     56            delete this->trigger_;
    5457    }
    5558
     
    134137        this->recentlyJumpedOut_.insert(entity);
    135138
    136                 // adjust
     139        // adjust
    137140        entity->setPosition(this->getWorldPosition());
    138141        entity->rotate(this->getWorldOrientation());
  • code/branches/portals2/src/modules/portals/PortalLink.cc

    r8599 r8600  
    4545    PortalLink::~PortalLink()
    4646    {
     47       
    4748    }
    4849   
Note: See TracChangeset for help on using the changeset viewer.