Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
May 20, 2010, 10:23:22 AM (14 years ago)
Author:
scheusso
Message:

merging lod branch into presentation3 merger branch

Location:
code/branches/presentation3
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/branches/presentation3

  • code/branches/presentation3/src/libraries/core/BaseObject.h

    r6800 r6926  
    5151    class Scene;
    5252    class Gametype;
     53    class Level;
    5354
    5455    //! The BaseObject is the parent of all classes representing an instance in the game.
     
    153154            inline Gametype* getOldGametype() const { return this->oldGametype_; }
    154155            virtual void changedGametype() {}
     156           
     157            inline void setLevel(const SmartPtr<Level>& level)
     158            {
     159                if (level != this->level_)
     160                {
     161                    this->level_ = level;
     162                    this->changedLevel();
     163                }
     164            }
     165            inline const SmartPtr<Level>& getLevel() const { return this->level_; }
     166            virtual void changedLevel() {}
    155167
    156168            void addEventSource(BaseObject* source, const std::string& state);
     
    209221            SmartPtr<Gametype>     gametype_;
    210222            Gametype*              oldGametype_;
     223            SmartPtr<Level>        level_;
    211224            std::set<Template*>    templates_;
    212225
Note: See TracChangeset for help on using the changeset viewer.