Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 4, 2015, 10:25:42 PM (9 years ago)
Author:
landauf
Message:

replace 'NULL' by 'nullptr'

Location:
code/branches/cpp11_v2/src/orxonox/items
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • code/branches/cpp11_v2/src/orxonox/items/Engine.cc

    r9667 r10765  
    155155    void Engine::run(float dt)
    156156    {
    157         if (this->ship_ == NULL)
     157        if (this->ship_ == nullptr)
    158158        {
    159159            if (this->shipID_ != 0)
     
    161161                this->networkcallback_shipID();
    162162
    163                 if (this->ship_ == NULL)
     163                if (this->ship_ == nullptr)
    164164                    return;
    165165            }
  • code/branches/cpp11_v2/src/orxonox/items/Engine.h

    r9667 r10765  
    6767            /**
    6868            @brief Get the SpaceShip this Engine is mounted on.
    69             @return Returns a pointer to the SpaceShip. NULL if it isn't mounted on any ship.
     69            @return Returns a pointer to the SpaceShip. nullptr if it isn't mounted on any ship.
    7070            */
    7171            inline SpaceShip* getShip() const
  • code/branches/cpp11_v2/src/orxonox/items/MultiStateEngine.cc

    r9939 r10765  
    205205    void MultiStateEngine::addEffectContainer(EffectContainer* effect)
    206206    {
    207         if (effect == NULL)
     207        if (effect == nullptr)
    208208            return;
    209209        effect->setLuaState(this->lua_, 'f' + multi_cast<std::string>(this->effectContainers_.size()));
     
    224224                return (*it);
    225225        }
    226         return NULL;
     226        return nullptr;
    227227    }
    228228
  • code/branches/cpp11_v2/src/orxonox/items/ShipPart.cc

    r10624 r10765  
    5050
    5151    ShipPart::ShipPart(Context* context)
    52         : Item(context), parent_(NULL)
     52        : Item(context), parent_(nullptr)
    5353    {
    5454        RegisterObject(ShipPart);
     
    122122    void ShipPart::addEntity(StaticEntity* entity)
    123123    {
    124         OrxAssert(entity != NULL, "The Entity cannot be NULL.");
     124        OrxAssert(entity != nullptr, "The Entity cannot be nullptr.");
    125125        this->entityList_.push_back(entity);
    126126    }
     
    130130        Get the i-th StaticEntity of the ShipPart.
    131131    @return
    132         Returns a pointer to the i-the StaticEntity. NULL if there is no StaticEntity with that index.
     132        Returns a pointer to the i-the StaticEntity. nullptr if there is no StaticEntity with that index.
    133133    */
    134134    StaticEntity* ShipPart::getEntity(unsigned int index)
    135135    {
    136136        if(this->entityList_.size() >= index)
    137             return NULL;
     137            return nullptr;
    138138        else
    139139            return this->entityList_[index];
     
    164164    void ShipPart::addDestructionEvent(PartDestructionEvent* event)
    165165    {
    166         OrxAssert(event != NULL, "The PartDestructionEvent cannot be NULL.");
     166        OrxAssert(event != nullptr, "The PartDestructionEvent cannot be nullptr.");
    167167        event->setParent(this);
    168168        this->eventList_.push_back(event);
     
    173173        Get the i-th PartDestructionEvent of the ShipPart.
    174174    @return
    175         Returns a pointer to the i-the PartDestructionEvent. NULL if there is no PartDestructionEvent with that index.
     175        Returns a pointer to the i-the PartDestructionEvent. nullptr if there is no PartDestructionEvent with that index.
    176176    */
    177177    PartDestructionEvent* ShipPart::getDestructionEvent(unsigned int index)
    178178    {
    179179        if(this->eventList_.size() <= index)
    180             return NULL;
     180            return nullptr;
    181181        else
    182182            return this->eventList_[index];
Note: See TracChangeset for help on using the changeset viewer.