Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 28, 2009, 1:47:57 PM (16 years ago)
Author:
rgrieder
Message:

Improved exception-safety in the Game class and fixed some issues and bugs resulting from the changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • code/branches/core4/src/core/GameState.h

    r3196 r3238  
    7777
    7878    public:
    79         GameState(const std::string& name, bool countTicktime = true);
     79        GameState(const std::string& name, bool ignoreTicktime = false);
    8080        virtual ~GameState();
    8181
     
    8484        GameState* getParent()       const { return this->parent_; }
    8585
    86         bool getCountTickTime()      const { return this->bCountTickTime_; }
     86        bool ignoreTickTime()        const { return this->bIgnoreTickTime_; }
    8787
    8888        void addChild(GameState* state);
     
    9090
    9191    protected:
    92         virtual void activate() = 0;
    93         virtual void deactivate() = 0;
    94         virtual void update(const Clock& time) = 0;
     92        virtual void activate() { }
     93        virtual void deactivate() { }
     94        virtual void update(const Clock& time) { }
    9595
    9696    private:
     
    103103        const std::string                        name_;
    104104        State                                    activity_;
    105         const bool                               bCountTickTime_;
     105        const bool                               bIgnoreTickTime_;
    106106        GameState*                               parent_;
    107107        std::map<std::string, GameState*>        children_;
Note: See TracChangeset for help on using the changeset viewer.